2019-11-18 17:29:51 +01:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
json.extract! @availability, :id, :title, :lock, :is_recurrent, :occurrence_id, :period, :nb_periods, :end_date
|
2016-03-23 18:39:41 +01:00
|
|
|
json.start_at @availability.start_at.iso8601
|
|
|
|
json.end_at @availability.end_at.iso8601
|
2020-04-15 18:08:02 +02:00
|
|
|
json.slot_duration @availability.slot_duration
|
2016-03-23 18:39:41 +01:00
|
|
|
json.available_type @availability.available_type
|
|
|
|
json.machine_ids @availability.machine_ids
|
2020-02-12 12:58:17 +01:00
|
|
|
json.plan_ids @availability.plan_ids
|
2016-03-23 18:39:41 +01:00
|
|
|
json.backgroundColor 'white'
|
2016-06-28 12:45:41 +02:00
|
|
|
json.borderColor availability_border_color(@availability)
|
2016-03-23 18:39:41 +01:00
|
|
|
json.tag_ids @availability.tag_ids
|
|
|
|
json.tags @availability.tags do |t|
|
|
|
|
json.id t.id
|
|
|
|
json.name t.name
|
2020-02-12 12:58:17 +01:00
|
|
|
end
|