| | |
| | | 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 { erpPriceInputFormatter } from '../../../../packages/utils/src'; |
| | | |
| | | 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 { getSimpleUserList } from '#/api/system/user'; |
| | | import { getRangePickerDefaultProps } from '#/utils'; |
| | | |
| | |
| | | placeholder: '请选择客户', |
| | | allowClear: true, |
| | | showSearch: true, |
| | | api: getCustomerSimpleList, |
| | | api: getCrmCustomerSimpleList, |
| | | labelField: 'name', |
| | | valueField: 'id', |
| | | }, |
| | |
| | | slots: { default: 'productId' }, |
| | | }, |
| | | { |
| | | field: 'productSpecification', |
| | | title: '规格型号', |
| | | minWidth: 120, |
| | | }, |
| | | { |
| | | field: 'stockCount', |
| | | title: '库存', |
| | | minWidth: 80, |
| | |
| | | { |
| | | field: 'productUnitName', |
| | | title: '单位', |
| | | minWidth: 80, |
| | | }, |
| | | { |
| | | field: 'productUnitName2', |
| | | title: '辅单位1', |
| | | minWidth: 80, |
| | | }, |
| | | { |
| | | field: 'productUnitName3', |
| | | title: '辅单位2', |
| | | minWidth: 80, |
| | | }, |
| | | { |
| | |
| | | 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', |
| | | }, |
| | |
| | | placeholder: '请选择客户', |
| | | allowClear: true, |
| | | showSearch: true, |
| | | api: getCustomerSimpleList, |
| | | api: getCrmCustomerSimpleList, |
| | | labelField: 'name', |
| | | valueField: 'id', |
| | | }, |
| | |
| | | label: '状态', |
| | | component: 'Select', |
| | | componentProps: { |
| | | options: getDictOptions(DICT_TYPE.ERP_AUDIT_STATUS, 'number'), |
| | | options: [ |
| | | { label: '未审核', value: 10 }, |
| | | { label: '已审核', value: 20 }, |
| | | { label: '已作废', value: 30 }, |
| | | ], |
| | | placeholder: '请选择状态', |
| | | allowClear: true, |
| | | }, |
| | |
| | | title: '订单单号', |
| | | width: 200, |
| | | fixed: 'left', |
| | | slots: { default: 'no' }, |
| | | }, |
| | | { |
| | | field: 'productNames', |
| | |
| | | field: 'customerName', |
| | | title: '客户', |
| | | minWidth: 120, |
| | | }, |
| | | { |
| | | field: 'contractNo', |
| | | title: '关联合同', |
| | | minWidth: 150, |
| | | slots: { default: 'contractNo' }, |
| | | }, |
| | | { |
| | | field: 'orderTime', |
| | |
| | | { |
| | | field: 'status', |
| | | title: '状态', |
| | | minWidth: 120, |
| | | cellRender: { |
| | | name: 'CellDict', |
| | | props: { type: DICT_TYPE.ERP_AUDIT_STATUS }, |
| | | }, |
| | | minWidth: 100, |
| | | fixed: 'right', |
| | | slots: { default: 'status' }, |
| | | }, |
| | | { |
| | | title: '操作', |