Browse Source

2024-3-18 增加工序名称查询

master_hella_20240701
zhousq 8 months ago
parent
commit
6e6de6c3c1
  1. 6
      src/api/mes/processroute/index.ts
  2. 50
      src/views/mes/processroute/components/configDialog.vue

6
src/api/mes/processroute/index.ts

@ -61,15 +61,15 @@ export const importTemplate = () => {
}
// 获取工序工序列表-
export const getProcessList =async (params) => {
return request.get({ url: `/wms/process/page`,params })
return await request.get({ url: `/wms/process/page`, params })
}
// 获取工序工序信息-
export const getProcesInfo = async(code:String) => {
return request.get({ url: `/wms/process/getByCode?code=`,code })
return await request.get({ url: `/wms/process/getByCode?code=`,code })
}
// 获取产品信息列表-
export const getProductInfo =async (code:String) => {
return request.get({ url: `/wms/itembasic/getProduct?code=`+code})
return await request.get({ url: `/wms/itembasic/getProduct?code=`+code})
}
// 获取设备列表-参数为工序编码

50
src/views/mes/processroute/components/configDialog.vue

@ -26,42 +26,12 @@
<el-row :gutter="10" style="height: calc(100vh - 300px)">
<el-col :span="6">
<!-- <el-form>
<el-form-item label="车间选择">
<el-select
:v-model="processListParmas.workshopCode"
value-key="code"
placeholder="Select"
style="width: 240px"
>
<el-option
v-for="item in workshopCodeOptions"
:key="item.code"
:label="item.name"
:value="item"
/>
</el-select>
</el-form-item>
<el-form-item label="产线选择">
<el-select
:v-model="processListParmas.productionLineCode"
value-key="code"
placeholder="Select"
style="width: 240px"
>
<el-option
v-for="item in productionLineCodeOptions"
:key="item.code"
:label="item.name"
:value="item"
/>
</el-select>
</el-form-item>
<el-form-item label="">
<el-button type="primary" @click="getProcessList">搜索</el-button>
</el-form-item>
<el-input v-model="processListParmas.name" placeholder="工序名称">
<template #append>
<el-button @click="getProcessList" >查询</el-button>
</template>
</el-input>
</el-form> -->
<el-table :data="processData" ref="tableProcess" style="width: 100%; height: 80%">
<el-table-column prop="name" label="工序名称">
<template #default="scope">
@ -126,9 +96,8 @@
<script lang="ts" setup>
import { start_node, end_node, createGraph, registerNodes, getNewNode } from './graphbase.data'
import * as ProcessrouteApi from '@/api/mes/processroute'
import { Search } from '@/components/Search'
import { Graph } from '@antv/x6'
import { table } from 'console'
//import { async } from '@antv/x6/lib/registry/marker/async'
//import { object } from 'vue-types'
const graphContainer = ref<HTMLElement | null>(null)
@ -180,7 +149,6 @@ const handleDrawerClose = () => {
if (graph && graph.value != undefined) {
//console.log(graph.value.toJSON())
}
}
//** */
const getProcessInfo = async (id: number) => {
@ -213,6 +181,7 @@ const getWorkerList = async (code: String) => {
//console.log(productData.value)
}
const processListParmas = ref({
name: '',
workshopCode: '',
productionLineCode:'',
pageNum: 1,
@ -220,6 +189,7 @@ const processListParmas = ref({
})
/**获取工序列表 */
const getProcessList = async () => {
//console.log(processListParmas.value)
const res = await ProcessrouteApi.getProcessList(processListParmas.value)
processData.value = res.list
@ -306,9 +276,7 @@ const saveResult = async () => {
}
//
onUnmounted(() => {})
const emit = defineEmits([
'close',
])
const emit = defineEmits(['close'])
</script>
<style lang="scss">
.el-drawer__body {

Loading…
Cancel
Save