2018-07-19 18:43:13 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2016-11-22 10:46:02 +00:00
|
|
|
class AnalyticsSummaryEntity < Grape::Entity
|
2022-01-21 12:16:22 +00:00
|
|
|
expose :identifier
|
2016-11-22 10:46:02 +00:00
|
|
|
expose :value, safe: true
|
2017-05-04 02:05:38 +00:00
|
|
|
expose :title
|
2020-04-08 12:09:42 +00:00
|
|
|
expose :unit, if: { with_unit: true }
|
2021-10-29 12:14:45 +00:00
|
|
|
expose :links
|
2020-04-21 15:21:10 +00:00
|
|
|
|
|
|
|
private
|
|
|
|
|
|
|
|
def value
|
2020-05-12 15:10:33 +00:00
|
|
|
object.value.to_s
|
2020-04-21 15:21:10 +00:00
|
|
|
end
|
2016-11-22 10:46:02 +00:00
|
|
|
end
|