import useSelectStore from '@/store/commonSelect/common'
import moment from 'moment';

export const assignCommonConfig = {
  title: '交办',
  formItems: [
    {
      field: 'code',
      type: 'hideType',
    },
    {
      required : true ,
      field: 'dealdept',
      type: 'treeSelect',
      label: '归属部门',
      required: true,
      placeholder: '请选择归属部门',
      options:useSelectStore().deptListData
    },
    {
        field: 'dealuser',
        type: 'select',
        label: '接收人',
        placeholder: '请选择接收人',
        options : []
    },
    {
      field: 'deadline',
      type: 'datepicker',
      label: '截止时间',
      required: false,
      placeholder: '请选择时间',
      otherOptions: {
        type: 'datetime',
        'value-format': 'yyyy-MM-dd HH:mm:ss',
      },
      resFormat: (time) => {
        return moment(time).format('YYYY-MM-DD HH:mm:ss');
      }
    },
    {
      field: 'reason',
      type: 'textarea',
      label: '备注',
      placeholder: '请输入备注'
    }
    
  ],
  colLayout: { span: 24 },
  subimitLoding : false,
  itemStyle: {}
}
