2016-03-23 18:39:41 +01:00
|
|
|
json.setting do
|
|
|
|
json.partial! 'api/settings/setting', setting: @setting
|
2019-01-14 15:00:33 +01:00
|
|
|
if @show_history
|
2022-01-17 12:38:53 +01:00
|
|
|
json.history @setting.history_values.includes(:invoicing_profile) do |value|
|
2019-04-18 15:57:56 +02:00
|
|
|
json.extract! value, :id, :value, :created_at
|
2019-06-03 16:51:43 +02:00
|
|
|
unless value.invoicing_profile.nil?
|
2019-01-16 17:06:41 +01:00
|
|
|
json.user do
|
2019-06-03 16:51:43 +02:00
|
|
|
json.id value.invoicing_profile.user_id
|
|
|
|
json.name value.invoicing_profile.full_name
|
2019-01-16 17:06:41 +01:00
|
|
|
end
|
2019-01-14 15:00:33 +01:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
2016-03-23 18:39:41 +01:00
|
|
|
end
|