Commit 1cca0c79 authored by renjintao's avatar renjintao

processcheck/produce/technology

parent 2da73cb6
<template>
<div class="wu_bg">
<!-- <div class="wu_top">
<div class="wu_bg">
<!-- <div class="wu_top">
工艺查看 /technology/details/setup/setupDetails
to="/produce/execute/ProcessCheck/setupDetails"
</div> -->
<Layout class="tech_box">
<Header>
<div class="tech_body">
<Menu mode="horizontal" theme="light" active-name="1" @on-select="openSaveTip">
<MenuItem name="1" >工艺规程</MenuItem>
<MenuItem name="2" >作业指导书</MenuItem>
<MenuItem name="3" >工步导航</MenuItem>
<MenuItem name="4" >工艺提醒</MenuItem>
</Menu>
</div>
</Header>
<Layout class="bottom_box" >
<!-- <nuxt-child keep-alive></nuxt-child> -->
<component :is="detail" :eid="id" />
</Layout>
</Layout>
</div>
</div>-->
<Layout class="tech_box">
<Header>
<div class="tech_body">
<Menu mode="horizontal" theme="light" active-name="1" @on-select="openSaveTip">
<MenuItem name="1">工艺规程</MenuItem>
<MenuItem name="2">作业指导书</MenuItem>
<MenuItem name="3">工步导航</MenuItem>
<MenuItem name="4">工艺提醒</MenuItem>
</Menu>
</div>
</Header>
<Layout class="bottom_box">
<!-- <nuxt-child keep-alive></nuxt-child> -->
<component :is="detail" :eid="id" :uid="uId" :isoutpdf="false" style="padding:10px 30px;" />
</Layout>
</Layout>
</div>
</template>
<script>
import ApiProcess from "../../../technology/api";
export default {
name:'starOrder',
data(){
return{
id: "1",
detail: null,
name: "starOrder",
data() {
return {
id: "1",
detail: null,
uId: ""
};
},
created() {
this.id = Number(this.$route.query.headid); //工艺规程id
//this.uId = ""; //工艺规程文件id
ApiProcess.get({ id: this.id }).then(r => {
if (r.success && r.result) {
if (r.result.fileId != "") {
this.uId = r.result.fileId;
} else {
this.uId = this.$u.guid();
}
},
created() {
this.detail = () => import("./components/setupDetails");
},
async fetch({ store, params }) {
await store.dispatch("loadDictionary"); // 加载数据字典
},
mounted() {
// this.detail = () => import("./components/setupDetails");
},
methods: {
openSaveTip(key){
this.id = key
if(this.id == "1"){ this.detail = () => import("./components/setupDetails");}
if(this.id == "2"){ this.detail = () => import("./components/remind");}
if(this.id == "3"){ this.detail = () => import("./components/workSteps");}
if(this.id == "4"){ this.detail = () => import("./components/guidance");}
},
},
}
}
});
this.detail = () => import("../../../technology/processview");
},
async fetch({ store, params }) {
await store.dispatch("loadDictionary"); // 加载数据字典
},
mounted() {
// this.detail = () => import("./components/setupDetails");
},
methods: {
openSaveTip(key) {
this.id = key;
if (this.id == "1") {
this.id = Number(this.$route.query.headid); //工艺规程id
//this.uId = ""; //工艺规程文件id
this.detail = () => import("../../../technology/processview");
}
//if(this.id == "1"){ this.detail = () => import("./components/setupDetails");}
if (this.id == "2") {
this.detail = () => import("./components/remind");
}
if (this.id == "3") {
this.detail = () => import("./components/workSteps");
}
if (this.id == "4") {
this.detail = () => import("./components/guidance");
}
}
}
};
</script>
<style scoped>
.wu_bg .bottom_box {
padding: 5px 20px;
background: white;
border: 1px solid #ccc;
border-top: 0;
height: 100px;
overflow-y: auto;
}
</style>
......@@ -29,7 +29,7 @@
<Button :icon="iconInfo" shape="circle" :title="titleInfo" @click="changeShwo"></Button>
</template>
<template slot="card" slot-scope="{row}">
<div class="body" @click="toExecute(row.id)">
<div class="body" @click="toExecute(row.id,row.routingHeaderId)">
<Row class="title-i">
<Col :span="10" class="order-code">{{row.productName}}</Col>
<Col :span="10" class="order-code">{{row.mesCode}}</Col>
......@@ -176,7 +176,7 @@ export default {
"op",
{
attrs: { oprate: "edit" },
on: { click: () => this.toExecute(params.row.id) }
on: { click: () => this.toExecute(params.row.id,params.row.routingHeaderId) }
},
"查看"
)
......@@ -209,9 +209,9 @@ export default {
search() {
this.$refs.grid.reload(this.easySearch);
},
toExecute(id) {
toExecute(id,headid) {
//跳转到对应操作页面 获取id:this.$route.query.id
this.$router.push({ path:"/produce/execute",query: { id:id}});
this.$router.push({ path:"/produce/execute",query: { id:id,headid:headid}});
},
tdStyle(val) {
//动态根据状态值加载状态值对应的颜色
......
......@@ -323,7 +323,13 @@ export default {
if (v != 0) {
this.load(v);
}
}
},
uid(v) {
if (v != 0) {
this.parms.eid=v
}
},
}
};
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment