import {FilterGroupMap, MapValue} from '@components';
import {contextState} from '../context';

export const sourceMap: FilterGroupMap<typeof contextState> = new Map([
  ['1', {label: '库位名称', type: 'field', value: 'storageLocationName'}],
  [
    '2',
    {
      label: '供应商',
      type: 'keySelect',
      value: 'supplierId',
      selectKey: '供应商/客户',
    },
  ],
  ['3', {label: 'WBS编号', type: 'field', value: 'wbs'}],
  ['4', {label: '工号', type: 'field', value: 'userName'}],
  ['5', {label: '姓名', type: 'field', value: 'realName'}],
  ['6', {label: '入库时间', type: 'date', value: 'startTime'}],
  [
    '7',
    {
      label: '所属公司',
      type: 'keySelect',
      value: 'accountSleeve',
      selectKey: '公司',
    },
  ],
]);

export const fixedMap: MapValue<typeof contextState>[] = [
  {label: '入库单编号', type: 'field', value: 'storageCode'},
  {label: '采购订单号', type: 'field', value: 'orderCode'},
  {label: '物料编号', type: 'field', value: 'wllbCode'},
  {label: '物料名称', type: 'field', value: 'materialName'},
];
