diff --git a/hw-ui/src/api/board/fifthFloor.js b/hw-ui/src/api/board/fifthFloor.js index dd8f3cf4..b4964e5d 100644 --- a/hw-ui/src/api/board/fifthFloor.js +++ b/hw-ui/src/api/board/fifthFloor.js @@ -1,13 +1,6 @@ import request from '@/utils/request' -// 获取计划 -export function getProductPlans(query) { - return request({ - url: '/mes/api/getProductPlans', - method: 'get', - params: query - }) -} + // 开始/继续 export function startNextProductPlanDetail(query) { diff --git a/hw-ui/src/api/board/index.js b/hw-ui/src/api/board/index.js index 0c94995a..668e7d23 100644 --- a/hw-ui/src/api/board/index.js +++ b/hw-ui/src/api/board/index.js @@ -1,10 +1,155 @@ import request from '@/utils/request' -// 查询设备BOM信息列表 -export function listBom(query) { +/** + * 通用 + * */ + +// 获取生产派工计划 +export function getProductPlans(query) { return request({ - url: '/dms/bom/list', + url: '/mes/api/getProductPlans', method: 'get', params: query }) } + +// 完成生产计划明细 +export function completeProductPlanDetail(query) { + return request({ + url: '/mes/api/completeProductPlanDetail', + method: 'post', + data: query + }) +} + +export function getStockTotal(query) { + return request({ + url: '/wms/api/getStockTotal', + method: 'get', + params: query + }) +} + +/** + * 1、4楼装配 + * */ + + +// 获取生产计划明细 +export function getProductPlanDetails(query) { + return request({ + url: '/mes/api/getProductPlanDetails', + method: 'get', + params: query + }) +} + +// 获取仓库列表 +export function getWarehouses(query) { + return request({ + url: '/wms/api/getWarehouses', + method: 'get', + params: query + }) +} + +// 申请领料 +export function applyRawOutstock(query) { + return request({ + url: '/wms/api/applyRawOutstock', + method: 'post', + data: query + }) +} + +// 生成生产计划明细 +export function insertProductPlanDetails(query) { + return request({ + url: '/mes/api/insertProductPlanDetails', + method: 'post', + data: query + }) +} + +// 开始生产计划明细 +export function startProductPlanDetail(query) { + return request({ + url: '/mes/api/startProductPlanDetail', + method: 'post', + data: query + }) +} + +/** + * 4楼折弯、5楼 + * */ + +// 获取最新的生产计划明细 +export function getNewestProductPlanDetail(query) { + return request({ + url: '/mes/api/getNewestProductPlanDetail/', + method: 'get', + params: query + }) +} + +// 开始/继续生产派工计划 +export function startNextProductPlanDetail(query) { + return request({ + url: '/mes/api/startNextProductPlanDetail', + method: 'post', + data: query + }) +} + +/** + * 4楼激光 + * */ + + +// 获取最新的生产计划明细 +export function getNewestProductPlanDetailJoinAttach(query) { + return request({ + url: '/mes/api/getNewestProductPlanDetailJoinAttach', + method: 'get', + params: query + }) +} + + +// 开始/继续下一生产计划明细 +export function startNextProductPlanDetailAttach(query) { + return request({ + url: '/mes/api/startNextProductPlanDetailAttach', + method: 'post', + data: query + }) +} + + +// 获取生产派工图纸列表 +export function getPlanDrawings(query) { + return request({ + url: '/mes/api/getProductPlanDrawings', + method: 'get', + params: query + }) +} + +//激光切割工位板材入库 +export function addRawInstock(data) { + return request({ + url: '/wms/api/addRawInstock', + method: 'post', + data: data + }) +} + +//激光切割工位板材出库 +export function directRawOutstock(data) { + return request({ + url: '/wms/api/directRawOutstock', + method: 'post', + data: data + }) +} diff --git a/hw-ui/src/views/board/fifthFloor/index.vue b/hw-ui/src/views/board/fifthFloor/index.vue index 5e296687..9acd2a04 100644 --- a/hw-ui/src/views/board/fifthFloor/index.vue +++ b/hw-ui/src/views/board/fifthFloor/index.vue @@ -276,7 +276,7 @@ import { applyRawOutstock, getStockTotal, getWarehouses -} from "@/api/board/fifthFloor"; +} from "@/api/board"; const setState = (e) => { if (e === '1') { diff --git a/hw-ui/src/views/board/firstFloor/index.vue b/hw-ui/src/views/board/firstFloor/index.vue index fb8d78de..43de5a9b 100644 --- a/hw-ui/src/views/board/firstFloor/index.vue +++ b/hw-ui/src/views/board/firstFloor/index.vue @@ -467,7 +467,7 @@ import { getProductPlans, insertProductPlanDetails, getProductPlanDetails, startProductPlanDetail, completeProductPlanDetail -} from '@/api/board/firstFloor' +} from '@/api/board' const vw = (document.documentElement.clientWidth || document.body.clientWidth) / 100 export default { diff --git a/hw-ui/src/views/board/fourthFloor/laserLight.vue b/hw-ui/src/views/board/fourthFloor/laserLight.vue index 3347be89..2e6e11be 100644 --- a/hw-ui/src/views/board/fourthFloor/laserLight.vue +++ b/hw-ui/src/views/board/fourthFloor/laserLight.vue @@ -214,13 +214,13 @@ import Chart from '@/components/board/Chart' import * as echarts from 'echarts' import { completeProductPlanDetail, - getNewestProductPlanDetail, + getNewestProductPlanDetailJoinAttach, getProductPlans, - startNextProductPlanDetail, + startNextProductPlanDetailAttach, getPlanDrawings, addRawInstock, directRawOutstock, -} from "@/api/board/laserLight"; +} from "@/api/board"; const setState = (e) => { if (e === '1') { @@ -279,7 +279,7 @@ export default { this.totalNum1 = Math.ceil(e.total / 5) this.$refs.table1.setCurrentRow(e.rows[0]); this.getInfo(e.rows[0]) - getNewestProductPlanDetail({planId: e.rows[0].planId}).then(val => { + getNewestProductPlanDetailJoinAttach({planId: e.rows[0].planId}).then(val => { this.form = val.data || {} this.form.materialId = e.rows[0]?.materialId this.form.materialName = e.rows[0]?.materialName @@ -466,7 +466,7 @@ export default { }, getOrderInfo(e) { this.getInfo(e) - getNewestProductPlanDetail({planId: e.planId}).then(val => { + getNewestProductPlanDetailJoinAttach({planId: e.planId}).then(val => { this.form = val.data this.form.materialId = e.materialId this.form.materialName = e.materialName @@ -810,11 +810,11 @@ export default { const dataIndex = this.tableData.indexOf(val) const lineIndex = this.tableData[dataIndex].drawing.indexOf(e) this.$set(this.tableData?.[dataIndex]?.[lineIndex], 'dispatchFlag',false) - await startNextProductPlanDetail({planId: val.planId, attachId: e.attachId}) + await startNextProductPlanDetailAttach({planId: val.planId, attachId: e.attachId}) .catch(() => { this.$set(this.tableData?.[dataIndex]?.[lineIndex], 'dispatchFlag',true) }) - getNewestProductPlanDetail({planId: val.planId}).then(val => { + getNewestProductPlanDetailJoinAttach({planId: val.planId}).then(val => { this.form = val.data this.form.materialId = e.materialId this.form.materialName = e.materialName diff --git a/hw-ui/src/views/board/fourthFloor/weld.vue b/hw-ui/src/views/board/fourthFloor/weld.vue index 836540c5..35b95617 100644 --- a/hw-ui/src/views/board/fourthFloor/weld.vue +++ b/hw-ui/src/views/board/fourthFloor/weld.vue @@ -6,25 +6,25 @@