diff options
author | Winnie Hellmann <winnie@gitlab.com> | 2017-05-05 22:47:32 +0000 |
---|---|---|
committer | Jacob Schatz <jschatz@gitlab.com> | 2017-05-05 22:47:32 +0000 |
commit | b51f2a60800829ee7585f10451a41bc4db0359a9 (patch) | |
tree | 2ea7ea74e3fa867b2eadf5ffc8652022b25b2321 /app/serializers/label_serializer.rb | |
parent | 9e041f2185ecb957e1f3d1205ea3bac54a5eb803 (diff) | |
download | gitlab-ce-b51f2a60800829ee7585f10451a41bc4db0359a9.tar.gz |
Colorize labels in issue search field
Diffstat (limited to 'app/serializers/label_serializer.rb')
-rw-r--r-- | app/serializers/label_serializer.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/serializers/label_serializer.rb b/app/serializers/label_serializer.rb new file mode 100644 index 00000000000..ad6ba8c46c9 --- /dev/null +++ b/app/serializers/label_serializer.rb @@ -0,0 +1,7 @@ +class LabelSerializer < BaseSerializer + entity LabelEntity + + def represent_appearance(resource) + represent(resource, { only: [:id, :title, :color, :text_color] }) + end +end |