import fa from "element-ui/src/locale/lang/fa";

export const tableOption = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  "searchMenuSpan": 6,
  menu: false,
  viewBtn: true,
  addBtn: false,
  editBtn: true,
  delBtn: true,
  "column": [
	  {
      "type": "input",
      "label": "",
      "prop": "id",
      hide:true,
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    },	  {
      "label": "所属机构",
      "prop": "deptId",
      dicUrl: '/admin/dept/convertToName',
      type: 'select',
      props: {
        label: 'name',
        value: 'deptId'
      },
      hide: true,
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    },	    {
      "label": "药企名称",
      "prop": "declareDept",
      dicUrl: '/admin/dept/convertToName',
      type: 'select',
      props: {
        label: 'name',
        value: 'deptId'
      },
      rules: [{
        required: true,
        message: '请选择药企名称'
      }]
    },	{
      "type": "month",
      "label": "预算月份",
      "prop": "belongDate",
      format: 'yyyy-MM',
      valueFormat: 'yyyy-MM',
      placeholder:"请选择月份",
      rules: [{
        required: true,
        message: '请选择月份'
      }]
    },	  {
      "type": "select",
      "label": "预算类型",
      "prop": "budgetType",
      dicUrl: '/admin/dict/type/budget_type',
      search: false,
      rules: [{
        required: true,
        message: '请选择预算类型'
      }]
    },	  {
      "type": "input",
      "label": "预算值",
      "prop": "budget",
      rules: [{
        required: true,
        message: '请输入预算值'
      }]
    },	  {
      "type": "input",
      "label": "提交日期",
      "prop": "createTime",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }  ]
}

export const viewOption = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  "searchMenuSpan": 6,
  "menuLeft": true,
  viewBtn: false,
  addBtn: true,
  editBtn: false,
  delBtn: false,
  "column": [
     {
      "label": "所属机构",
      "prop": "deptId",
      dicUrl: '/admin/dept/convertToName',
      type: 'select',
      props: {
        label: 'name',
        value: 'deptId'
      },
      hide: true,
     editDisplay: false,
     addDisplay: false,
     viewDisplay: false,

    },	 {
      "label": "药企名称",
      "prop": "declareDept",
      dicUrl: '/admin/dept/getParentDept',
      type: 'select',
      search: true,
      props: {
        label: 'name',
        value: 'deptId'
      },
      rules: [{
        required: true,
        message: '请选择药企名称'
      }],
    },{
      "type": "month",
      "label": "预算月份",
      "prop": "belongDate",
      format: 'yyyy-MM',
      valueFormat: 'yyyy-MM',
      placeholder:"请选择月份",
      search: true,
      rules: [{
        required: true,
        message: '请选择月份'
      }]
    },	 {
      "type": "select",
      "label": "预算类型",
      "prop": "budgetType",
      dicUrl: '/admin/dict/type/budget_type',
      rules: [{
        required: true,
        message: '请选择预算类型'
      }],
      hide:true
    },	  {
      "type": "input",
      "label": "预算值",
      "prop": "budget",
      rules: [{
        required: true,
        message: '请输入预算值'
      }],
      hide:true
    },  {
      "type": "input",
      "label": "积分值预算",
      "prop": "scoreBudget",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }, 	{
      "type": "input",
      "label": "已收到下发积分值",
      "prop": "scoreIssue",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }, {
      "type": "input",
      "label": "任务量预算",
      "prop": "taskBudget",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    },{
      "type": "input",
      "label": "已收到下发任务量",
      "prop": "taskIssue",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }
    ]
}

export const entviewOption = {
  "border": true,
  "index": true,
  "indexLabel": "序号",
  "stripe": true,
  "menuAlign": "center",
  "align": "center",
  "searchMenuSpan": 6,
  "menuLeft": true,
  viewBtn: false,
  addBtn: false,
  editBtn: false,
  delBtn: false,
  "column": [
    {
      "label": "CSO名称",
      "prop": "deptId",
      dicUrl: '/admin/dept/getChildDept',
      type: 'select',
      search: true,
      props: {
        label: 'name',
        value: 'deptId'
      },
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,

    },
    // {
    //   "label": "药企名称",
    //   "prop": "declareDept",
    //   dicUrl: '/admin/dept/convertToName',
    //   type: 'select',
    //   // hide: true,
    //   props: {
    //     label: 'name',
    //     value: 'deptId'
    //   },
    //   rules: [{
    //     required: true,
    //     message: '请选择药企名称'
    //   }],
    // },
    {
      "type": "month",
      "label": "预算月份",
      "prop": "belongDate",
      format: 'yyyy-MM',
      valueFormat: 'yyyy-MM',
      placeholder:"请选择月份",
      search: true,
      rules: [{
        required: true,
        message: '请选择月份'
      }]
    },	 {
      "type": "select",
      "label": "预算类型",
      "prop": "budgetType",
      dicUrl: '/admin/dict/type/budget_type',
      rules: [{
        required: true,
        message: '请选择预算类型'
      }],
      hide:true
    },	  {
      "type": "input",
      "label": "预算值",
      "prop": "budget",
      rules: [{
        required: true,
        message: '请输入预算值'
      }],
      hide:true
    },  {
      "type": "input",
      "label": "积分值预算",
      "prop": "scoreBudget",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }, 	{
      "type": "input",
      "label": "已下发积分值",
      "prop": "scoreIssue",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }, {
      "type": "input",
      "label": "任务量预算",
      "prop": "taskBudget",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    },{
      "type": "input",
      "label": "已下发任务量",
      "prop": "taskIssue",
      editDisplay: false,
      addDisplay: false,
      viewDisplay: false,
    }
  ]
}
