gaoluyang
97 分钟以前 787ccc59ba89bacc075562a161ecf02bc76ebadc
src/views/erp/sale/return/data.ts
@@ -1,14 +1,14 @@
import type { VbenFormSchema } from '#/adapter/form';
import type { VxeTableGridOptions } from '#/adapter/vxe-table';
import { DICT_TYPE } from '../../../../packages/constants/src';
import { getDictOptions } from '../../../../packages/effects/hooks/src';
import { erpNumberFormatter, erpPriceInputFormatter } from '../../../../packages/utils/src';
import { DICT_TYPE } from '@vben/constants';
import { getDictOptions } from '@vben/hooks';
import { erpNumberFormatter, erpPriceInputFormatter } from '@vben/utils';
import { z } from '#/adapter/form';
import { getAccountSimpleList } from '#/api/erp/finance/account';
import { getProductSimpleList } from '#/api/erp/product/product';
import { getCustomerSimpleList } from '#/api/erp/sale/customer';
import { getItemPage } from '#/api/mdm/item';
import { getCustomerSimpleList as getCrmCustomerSimpleList } from '#/api/crm/customer';
import { getWarehouseSimpleList } from '#/api/erp/stock/warehouse';
import { getSimpleUserList } from '#/api/system/user';
import { getRangePickerDefaultProps } from '#/utils';
@@ -69,7 +69,7 @@
        placeholder: '请选择客户',
        allowClear: true,
        showSearch: true,
        api: getCustomerSimpleList,
        api: getCrmCustomerSimpleList,
        labelField: 'name',
        valueField: 'id',
      },
@@ -100,23 +100,13 @@
      formItemClass: 'col-span-2',
    },
    {
      fieldName: 'fileUrl',
      fieldName: 'blobIds',
      label: '附件',
      component: 'FileUpload',
      componentProps: {
        maxNumber: 1,
        maxSize: 10,
        accept: [
          'pdf',
          'doc',
          'docx',
          'xls',
          'xlsx',
          'txt',
          'jpg',
          'jpeg',
          'png',
        ],
        valueKey: 'id',
        maxNumber: 10,
        multiple: true,
        showDescription: formType !== 'detail',
        disabled: formType === 'detail',
      },
@@ -343,7 +333,10 @@
        placeholder: '请选择产品',
        allowClear: true,
        showSearch: true,
        api: getProductSimpleList,
        api: async () => {
          const res = await getItemPage({ pageNo: 1, pageSize: 100, status: 0 });
          return res.list || [];
        },
        labelField: 'name',
        valueField: 'id',
      },
@@ -365,7 +358,7 @@
        placeholder: '请选择客户',
        allowClear: true,
        showSearch: true,
        api: getCustomerSimpleList,
        api: getCrmCustomerSimpleList,
        labelField: 'name',
        valueField: 'id',
      },
@@ -541,7 +534,10 @@
        placeholder: '请选择产品',
        allowClear: true,
        showSearch: true,
        api: getProductSimpleList,
        api: async () => {
          const res = await getItemPage({ pageNo: 1, pageSize: 100, status: 0 });
          return res.list || [];
        },
        labelField: 'name',
        valueField: 'id',
      },