json.total_count @apply_signatures.total_count
json.apply_signatures @apply_signatures do |signature|
  json.id signature.id 
  json.status signature.status
  json.phone signature&.phone
  json.name signature&.name
  json.remark signature&.remark
  json.company_name signature&.company_name
  json.position signature&.position
  json.email signature&.email
  
  if signature.user.present?
    json.user do 
      json.partial! 'members/member', user: signature.user
      json.is_owner @project.owner?(signature.user)
    end
  end
  if signature.attachments.present?
    attachment = signature.attachments.take
    json.attachment do 
      json.filename attachment.filename
      json.path attachment&.uuid.present? ? attachment_path(attachment.uuid) : attachment_path(attachment)
    end
  end
end
