Browse Source

2024-04-29 修改工艺路线配置界面,优化提示

master_hella_20240701
zhousq 7 months ago
parent
commit
2907ab45c0
  1. 38
      src/views/mes/orderDay/components/schedule.vue
  2. 4
      src/views/mes/orderDay/index.vue

38
src/views/mes/orderDay/components/schedule.vue

@ -36,24 +36,25 @@
<el-table :data="processData" ref="tableProcess" style="width: 100%; height: 80%" @cell-dblclick="userAddNode">
<el-table-column prop="code" label="工序编码" />
<el-table-column prop="name" label="工序名称" />
<el-table-column prop="opera" label="" width="60">
<!-- <el-table-column prop="opera" label="" width="60">
<template #header>
<span>操作</span>
</template>
<!-- <template #default="scope">
<template #default="scope">
<el-button type="danger" size="mini" text @click="deleteNode(scope.row)"
>移除</el-button
>
</template> -->
</el-table-column>
</template>
</el-table-column> -->
</el-table>
</el-card>
</el-aside>
<el-main style="height: 320px;width: calc(100% - 980px);padding: 0px; margin:0px 20px">
<el-main style="height: 480px; width: calc(100% - 980px);padding: 0px; margin:0px 20px">
<div ref="graphContainer"></div
></el-main>
<el-aside width="640px">
<el-tabs v-model="activeName">
<el-tag>工序编码{{currentNode.id}} -工序名称:{{currentNode.attrs.title.text }}</el-tag>
<el-tabs v-model="activeName" >
<el-tab-pane label="工序工位" name="workstation">
<el-table :data="workstationData" ref="tableWorkstations" style="width: 100%; height: 80%">
<el-table-column prop="stationName" label="工位名称" />
@ -76,7 +77,17 @@
<el-table-column prop="sourceMaterialCounts" label="需求物料数">
<template #default="scope">{{ getTotalcounts(scope.row.repMaterialCounts) }}</template>
</el-table-column>
<el-table-column prop="replaceFlag" label="是否替换" />
<el-table-column prop="replaceFlag" label="是否替换" >
<template #default="scope">
<el-switch
v-model="scope.row.replaceFlag"
active-color="#13ce66"
inactive-color="#ff4949"
active-text="是"
inactive-text="否"
/>
</template>
</el-table-column>
</el-table>
</el-tab-pane>
<el-tab-pane label="工序人员" name="workers">
@ -211,7 +222,7 @@ const graphContainer = ref<HTMLElement | null>(null)
const graph = ref<Graph>()
const message = useMessage() //
const { t } = useI18n() //
const activeName = ref('process')
const activeName = ref('workstation')
const formLoading = ref(false)
const dialogFormVisibleUser = ref(false)
const processData = ref([])
@ -249,6 +260,7 @@ const workstationData=ref([])
const dialogVisible = ref(false) //
const dialogTitle = ref('') //
const graphJson =ref()
const currentNode = ref({})
/*班组数据*/
const teamData = ref([])
/*班组弹窗搜索条件*/
@ -309,9 +321,9 @@ const open = async (type: string, row?: any, titleName?: any) => {
queryParams.batchCode=row.batchCode
//
if (titleName) {
dialogTitle.value = t('action.' + titleName)
dialogTitle.value = titleName
} else {
dialogTitle.value = t('action.' + type)
dialogTitle.value = type
}
nextTick?.(() => {
graph.value = createGraph(graphContainer.value as HTMLElement, true, 240, 320)
@ -388,6 +400,7 @@ const nodeClick = (e, x, y, node, view) => {
getConfigProcessWorker(node.id)
getConfigProcessEquipment(node.id)
processCode.value = node.id
currentNode.value=node
}
const searchTableRef = ref()
@ -453,9 +466,10 @@ const doPublishPlan= ()=>{
endTime: detailData.value.endTime,
taskMode: detailData.value.taskMode
}
//console.log("-------",data)
let res = OrderDayApi.publishPlan(data)
if(res.code==0){
console.log("---doPublishPlan-- 458--",res)
if(res.code===0){
message.success("计划发布成功")
}else {
message.error(res.msg)

4
src/views/mes/orderDay/index.vue

@ -264,7 +264,7 @@ const openForm = (type: string, row?: any) => {
const formsSuccess = async (formType,data) => {
if (formType === 'create') {
let ret=await OrderDayApi.createOrderDay(data)
let ret= OrderDayApi.createOrderDay(data)
if(ret===undefined || ret===null){
message.error(t('common.networkError'))
}else{
@ -272,7 +272,7 @@ const formsSuccess = async (formType,data) => {
}
} else {
let ret=await OrderDayApi.updateOrderDay(data)
let ret= OrderDayApi.updateOrderDay(data)
if(ret.code==0){
message.success(t('common.updateSuccess'))
}else{

Loading…
Cancel
Save