import { longOptions } from "./_options";
import { ModalConfig } from "/@/components/PageModal/src/types";

const modalConfig: ModalConfig = {
  title: "品牌支持",
  colLayout: { span: 24 },
  itemStyle: {},
  labelWidth:'120px',
  formItems: [
    {
      field: "gyscode",
      type: "supplier-query",
      label: "供应商",
      labelWidth: "120px",
      placeholder: "请选择供应商",
      rules: [{ required: true, trigger: "change", message: "请选择供应商" }]
    },
    {
      field: "brand_id",
      type: "brand-query",
      label: "支持品牌",
      labelWidth: "120px",
      placeholder: "请选择支持品牌",
      rules: [{ required: true, trigger: "change", message: "请选择支持品牌" }]
    },
    {
      field:'long',
      type: 'radio',
      label: '授权类型',
      options: longOptions,
      rules: [{ required: true, trigger: "change", message: "请选择授权类型" }]
    },
    {
      field: "create_timer",
      type: "date_picker",
      label: '授权时间',
      otherOptions: {
        type: "daterange",
        startProp: "starttime",
        endProp: "endtime",
        startPlaceholder: "开始时间",
        endPlaceholder: "结束时间"
      }
    },
    {
      field:'brand_book',
      type: 'img_upload',
      label: '授权图片',
      options: longOptions,
      rules: [{ required: true, trigger: "change", message: "请选择授权图片" }],
      otherOptions: { size: 'small' }
    },
    {
      field: 'remark',
      type: 'input',
      label: '备注',
      placeholder:'备注',
      otherOptions: {
        type: 'textarea'
      }
    }
  ]
};

export default modalConfig;
