Browse Source

需要先选择订单号,再选择订单

master
zhaoxuebing 11 months ago
parent
commit
5a7445b83f
  1. 20
      src/api/wms/purchaseDetail/index.ts
  2. 5
      src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts

20
src/api/wms/purchaseDetail/index.ts

@ -30,6 +30,8 @@ export interface PurchaseDetailVO {
available: string available: string
} }
const message = useMessage() // 消息弹窗
// 查询采购订单子列表 // 查询采购订单子列表
export const getPurchaseDetailPage = async (params) => { export const getPurchaseDetailPage = async (params) => {
if (params.isSearch) { if (params.isSearch) {
@ -41,6 +43,24 @@ export const getPurchaseDetailPage = async (params) => {
} }
} }
// 查询采购订单子列表
export const getPurchaseDetailPagePoNumber = async (params) => {
if (params.isSearch) {
if(params.number == ''){
return;
}
delete params.isSearch
const data = {...params}
return await request.post({ url: '/wms/purchase-detail/senior', data })
} else {
if(params.number == ''){
return;
}
return await request.get({ url: `/wms/purchase-detail/page`, params })
}
}
// 查询采购订单子详情 // 查询采购订单子详情
export const getPurchaseDetail = async (id: number) => { export const getPurchaseDetail = async (id: number) => {
return await request.get({ url: `/wms/purchase-detail/get?id=` + id }) return await request.get({ url: `/wms/purchase-detail/get?id=` + id })

5
src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts

@ -5,6 +5,7 @@ import { Supplier } from '@/views/wms/basicDataManage/supplierManage/supplier/su
import * as PurchaseMainApi from '@/api/wms/purchaseMain' import * as PurchaseMainApi from '@/api/wms/purchaseMain'
import * as PurchaseDetailApi from '@/api/wms/purchaseDetail' import * as PurchaseDetailApi from '@/api/wms/purchaseDetail'
import { PurchaseDetail, PurchaseMain } from '../purchaseMain/purchaseMain.data' import { PurchaseDetail, PurchaseMain } from '../purchaseMain/purchaseMain.data'
import {getPurchaseDetailPagePoNumber} from "@/api/wms/purchaseDetail";
const { t } = useI18n() // 国际化 const { t } = useI18n() // 国际化
/** /**
@ -316,7 +317,7 @@ export const PurchasePlanDetail = useCrudSchemas(reactive<CrudSchema[]>([
searchField: 'lineNumber', searchField: 'lineNumber',
searchTitle: '采购订单信息', searchTitle: '采购订单信息',
searchAllSchemas: PurchaseDetail.allSchemas, searchAllSchemas: PurchaseDetail.allSchemas,
searchPage: PurchaseDetailApi.getPurchaseDetailPage, searchPage: PurchaseDetailApi.getPurchaseDetailPagePoNumber,
searchCondition: [{ searchCondition: [{
key: 'number', key: 'number',
value: 'poNumber', value: 'poNumber',
@ -334,7 +335,7 @@ export const PurchasePlanDetail = useCrudSchemas(reactive<CrudSchema[]>([
searchField: 'lineNumber', searchField: 'lineNumber',
searchTitle: '采购订单信息', searchTitle: '采购订单信息',
searchAllSchemas: PurchaseDetail.allSchemas, searchAllSchemas: PurchaseDetail.allSchemas,
searchPage: PurchaseDetailApi.getPurchaseDetailPage, searchPage: PurchaseDetailApi.getPurchaseDetailPagePoNumber,
searchCondition: [{ searchCondition: [{
key: 'number', key: 'number',
value: 'poNumber', value: 'poNumber',

Loading…
Cancel
Save