text: import VoiceCampaignToken from '@apps/campaigns/admin/tokens/campaign/voice'
  import { Panel } from '@admin'
  import NewVoice from './new'
  import React from 'react'
  
  const mapPropsToPanel = (props, context) => ({
    title: 'voice Campaigns',
    collection: {
      endpoint: '/api/admin/campaigns/voice',
      table: [
        { label: 'ID', key: 'id', collapsing: true, visible: false },
        { label: 'Title', key: 'title', primary: true, format: (campaign) => (
          <VoiceCampaignToken campaign={ campaign } compact={ true } />
        ) }
      ],
      export: [
        { label: 'ID', key: 'id' },
        { label: 'Title', key: 'title' },
        { label: 'Program', key: 'program.title' },
        { label: 'Calls', key: 'calls_count' },
        { label: 'Active', key: 'active_count' },
        { label: 'Lost', key: 'lost_count' },
        { label: 'Converted', key: 'converted_count' },
        { label: 'Completed', key: 'completed_count' },
        { label: 'Status', key: 'status' }
      ],
      defaultFilter: {
        event_id: {
          $eq: props.event.id
        }
      },
      defaultSort: { key: 'created_at', order: 'desc' },
      empty: {
        icon: 'phone',
        title: 'No Voice Campaigns',
        text: 'You have not yet created any voice campaigns for this event',
        buttons: [
          { label: 'Create Campaign', modal: <NewVoice event={ props.event } /> }
        ]
      },
      entity: 'campaign',
      onClick: (record) => context.router.history.push(`/campaigns/voice/${record.id}`)
    },
    task: {
      icon: 'plus',
      modal: <NewVoice event={ props.event } />
    }
  })
  
  export default Panel(null, mapPropsToPanel)
  