json.id journal.id
json.is_journal_detail journal.is_journal_detail? 
json.created_at journal.created_on.strftime("%Y-%m-%d %H:%M")
json.updated_at journal.updated_on.strftime("%Y-%m-%d %H:%M")
json.user do 
  if journal.user.present? 
    json.partial! "api/v1/users/simple_user", user: journal.user
  else 
    json.nil! 
  end
end
if journal.is_journal_detail? 
  detail = journal.journal_details.take
  json.operate_category journal.pm_operate_category
  json.operate_content journal.is_journal_detail? ? journal.pm_operate_content : nil
  json.status_msg detail.status_msg
else
  json.notes journal.notes 
  json.comments_count journal.comments_count
  json.children_journals journal.first_ten_children_journals.each do |journal| 
    json.partial! "api/v1/issues/journals/children_detail", journal: journal
  end
  json.attachments journal.attachments do |attachment| 
    json.partial! "api/v1/attachments/simple_detail", locals: {attachment: attachment}
  end
end
