content: import React from 'react'
  import { graphql } from 'react-apollo'
  import { Field } from 'redux-form'
  
  import { companyListQuery } from '../graphql'
  
  const SelectCompanyT1 = (props) => {
      const { data: { loading, error, allArCompanies } } = props
      const { options } = props
  
      if (loading) {
          return <p>Loading ...</p>;
      }
      if (error) {
          return <p>{error.message}</p>;
      }
  
      return <Field name={options.name} component="select" className="form-control">
          <option />
          {allArCompanies.map(record => <option key={record.id} value={record.id}>{record.completeName}</option>)}
      </Field>;
  }
  
  const SelectCompanyT1WithData = graphql(companyListQuery, {
      //   options: { pollInterval: 5000 },
  })(SelectCompanyT1)
  
  export default SelectT1WithData