|
|
|
json.extract! @module, :id, :name, :position, :url, :md_edit
|
|
|
|
|
|
|
|
md = @module.competition_module_md_content
|
|
|
|
if md.present?
|
|
|
|
json.md_name md.name
|
|
|
|
json.md_content md.content
|
|
|
|
json.created_at md.created_at.strftime('%Y-%m-%d %H:%M:%S')
|
|
|
|
json.attachments do
|
|
|
|
json.array! md.attachments, partial: 'attachments/attachment_simple', as: :attachment
|
|
|
|
end
|
|
|
|
end
|