diff --git a/src/api/erp/product/product/index.ts b/src/api/erp/product/product/index.ts index 226fc38c..1136282f 100644 --- a/src/api/erp/product/product/index.ts +++ b/src/api/erp/product/product/index.ts @@ -7,6 +7,7 @@ export interface ProductVO { barCode: string // 产品条码 categoryId: number // 产品类型编号 unitId: number // 单位编号 + unitName?: string // 单位名字 status: number // 产品状态 standard: string // 产品规格 remark: string // 产品备注 @@ -25,8 +26,8 @@ export const ProductApi = { }, // 查询产品精简列表 - getProductSimpleList: async (params: any) => { - return await request.get({ url: `/erp/product/simple-list`, params }) + getProductSimpleList: async () => { + return await request.get({ url: `/erp/product/simple-list` }) }, // 查询产品详情 diff --git a/src/api/erp/stock/stock/index.ts b/src/api/erp/stock/stock/index.ts index 9296efa0..4de86fb1 100644 --- a/src/api/erp/stock/stock/index.ts +++ b/src/api/erp/stock/stock/index.ts @@ -29,6 +29,11 @@ export const StockApi = { return await request.get({ url: `/erp/stock/get`, params: { productId, warehouseId } }) }, + // 获得产品库存数量 + getStockCount: async (productId: number) => { + return await request.get({ url: `/erp/stock/get-count`, params: { productId } }) + }, + // 导出产品库存 Excel exportStock: async (params) => { return await request.download({ url: `/erp/stock/export-excel`, params }) diff --git a/src/api/erp/stock/warehouse/index.ts b/src/api/erp/stock/warehouse/index.ts index 0f493f8e..598824bf 100644 --- a/src/api/erp/stock/warehouse/index.ts +++ b/src/api/erp/stock/warehouse/index.ts @@ -22,8 +22,8 @@ export const WarehouseApi = { }, // 查询仓库精简列表 - getWarehouseSimpleList: async (params: any) => { - return await request.get({ url: `/erp/warehouse/simple-list`, params }) + getWarehouseSimpleList: async () => { + return await request.get({ url: `/erp/warehouse/simple-list` }) }, // 查询仓库详情 diff --git a/src/views/erp/sale/order/SaleOrderForm.vue b/src/views/erp/sale/order/SaleOrderForm.vue index a19b43d9..59bd3137 100644 --- a/src/views/erp/sale/order/SaleOrderForm.vue +++ b/src/views/erp/sale/order/SaleOrderForm.vue @@ -10,17 +10,17 @@ > - + - + @@ -62,7 +62,7 @@ - + @@ -80,7 +80,7 @@ import { SaleOrderApi, SaleOrderVO } from '@/api/erp/sale/order' import SaleOrderItemForm from './components/SaleOrderItemForm.vue' import { CustomerApi, CustomerVO } from '@/api/erp/sale/customer' -/** ERP 其它出库单表单 */ +/** ERP 销售订单表单 */ defineOptions({ name: 'SaleOrderForm' }) const { t } = useI18n() // 国际化 @@ -96,10 +96,11 @@ const formData = ref({ orderTime: undefined, remark: undefined, fileUrl: '', - items: [] + items: [], + no: undefined // 订单单号,后端返回 }) const formRules = reactive({ - orderTime: [{ required: true, message: '出库时间不能为空', trigger: 'blur' }] + orderTime: [{ required: true, message: '订单时间不能为空', trigger: 'blur' }] }) const disabled = computed(() => formType.value === 'detail') const formRef = ref() // 表单 Ref diff --git a/src/views/erp/sale/order/components/SaleOrderItemForm.vue b/src/views/erp/sale/order/components/SaleOrderItemForm.vue index 8ac8b1ee..1c388c70 100644 --- a/src/views/erp/sale/order/components/SaleOrderItemForm.vue +++ b/src/views/erp/sale/order/components/SaleOrderItemForm.vue @@ -10,29 +10,6 @@ > - - -