|
|
@ -145,7 +145,6 @@ import { start_node, end_node, createGraph, getNewNode } from './graphbase.data' |
|
|
|
import {ProcessSearch} from '../../publicUtil/processSearch.data' |
|
|
|
import * as ProcessrouteApi from '@/api/mes/processroute' |
|
|
|
import { Graph } from '@antv/x6' |
|
|
|
import { get } from 'http' |
|
|
|
const graphContainer = ref<HTMLElement | null>(null) |
|
|
|
defineOptions({ name: 'ProcessRouteConfig' }) |
|
|
|
const isShowDrawer = ref(false) |
|
|
@ -234,11 +233,12 @@ const openDetail = (row: any) => { |
|
|
|
materialData.value = [] |
|
|
|
mouldData.value = [] |
|
|
|
workStationList.value = [] |
|
|
|
graph.value.on('node:click', ({ e, x, y, node, view }) => { |
|
|
|
graph.value.on('node:dblclick', ({ e, x, y, node, view }) => { |
|
|
|
nodeClick(e, x, y, node, view) |
|
|
|
}) |
|
|
|
graph.value.fromJSON(graphJson.cells) |
|
|
|
}) |
|
|
|
getProcessList(rowData.value.processrouteCode) |
|
|
|
getItembasicInfo(rowData.value.productCode) |
|
|
|
getRemarkList() |
|
|
|
getFileList() |
|
|
@ -275,17 +275,24 @@ const getPatternPage = async (code) => { |
|
|
|
const getWorkstationPage = async (code) => { |
|
|
|
return await ProcessrouteApi.getWorkstationPage(code); |
|
|
|
} |
|
|
|
const processListParmas = ref({ |
|
|
|
name: '', |
|
|
|
workshopCode: '', |
|
|
|
productionLineCode:'', |
|
|
|
pageNum: 1, |
|
|
|
pageSize: 50 |
|
|
|
}) |
|
|
|
/**获取工序列表 */ |
|
|
|
const getProcessList = async () => { |
|
|
|
const res = await ProcessrouteApi.getProcessList(processListParmas.value) |
|
|
|
processData.value = res.list |
|
|
|
// const processListParmas = ref({ |
|
|
|
// name: '', |
|
|
|
// workshopCode: '', |
|
|
|
// productionLineCode:'', |
|
|
|
// pageNum: 1, |
|
|
|
// pageSize: 50 |
|
|
|
// }) |
|
|
|
// /**获取基础工序列表 */ |
|
|
|
// const getProcessList = async () => { |
|
|
|
// const res = await ProcessrouteApi.getProcessList(processListParmas.value) |
|
|
|
// processData.value = res.list |
|
|
|
// //return res |
|
|
|
// } |
|
|
|
/**获取工艺路线定义的工序列表 */ |
|
|
|
const getProcessList = async (code) => { |
|
|
|
console.log('code',code) |
|
|
|
const res = await ProcessrouteApi.getProcessrouteNodeList(code) |
|
|
|
processData.value = res |
|
|
|
//return res |
|
|
|
} |
|
|
|
// 并行执行所有异步操作 |
|
|
@ -353,7 +360,7 @@ defineExpose({ openDetail, createGraph }) // 提供 open 方法,用于打开 |
|
|
|
onMounted?.(() => { |
|
|
|
//registerNodes() |
|
|
|
|
|
|
|
getProcessList() |
|
|
|
//getProcessList() |
|
|
|
}) |
|
|
|
//保存图形 |
|
|
|
const saveResult = async () => { |
|
|
|