Commit c68b98ba authored by renjintao's avatar renjintao

technology/details/add/index/detailExamine/zhcn...

parent 20bb7d43
...@@ -611,7 +611,7 @@ export default { ...@@ -611,7 +611,7 @@ export default {
id: 'id', id: 'id',
productName: '产品名称', productName: '产品名称',
name: '工艺名称', name: '工艺名称',
routingType: '', routingType: '工艺类型',
routingTypeDesc: '工艺类型', routingTypeDesc: '工艺类型',
version: '文档版本', version: '文档版本',
code: '规程编号', code: '规程编号',
...@@ -1169,7 +1169,7 @@ export default { ...@@ -1169,7 +1169,7 @@ export default {
classId: '类id', classId: '类id',
unicode: 'unicode', unicode: 'unicode',
name: '工艺名称', name: '工艺名称',
code: '工艺编号', code: '工艺文件编号',
productId: '产品id', productId: '产品id',
productName:'产品名称', productName:'产品名称',
version: '版本', version: '版本',
...@@ -1188,7 +1188,7 @@ export default { ...@@ -1188,7 +1188,7 @@ export default {
auditUserId2: '审批人', auditUserId2: '审批人',
isDeleted: '是否删除', isDeleted: '是否删除',
platesnum: '板数', platesnum: '板数',
isEffect: '效', isEffect: '效',
versionnotes: '版本说明', versionnotes: '版本说明',
phase: '阶段', phase: '阶段',
versionid: '版本ID', versionid: '版本ID',
......
<template> <template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90"> <Form ref="form" :model="entity" :rules="rules" :label-width="110">
<Row> <Row>
<!-- <Col :span="12"> <!-- <Col :span="12">
<FormItem :label="l('classId')" prop="classId"> <FormItem :label="l('classId')" prop="classId">
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('productId')" prop="productId"> <FormItem :label="l('productName')" prop="productId">
<ProductSelect v-model="entity.productId" @on-change="proChange"></ProductSelect> <ProductSelect v-model="entity.productId" @on-change="proChange"></ProductSelect>
</FormItem> </FormItem>
</Col> </Col>
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('departmentId')" prop="departmentId"> <FormItem :label="l('departmentName')" prop="departmentId">
<departmentSelect v-model="entity.departmentId" @on-change="departChange"></departmentSelect> <departmentSelect v-model="entity.departmentId" @on-change="departChange"></departmentSelect>
</FormItem> </FormItem>
</Col> </Col>
...@@ -161,9 +161,11 @@ export default { ...@@ -161,9 +161,11 @@ export default {
name: "", name: "",
code: "", code: "",
productId: null, productId: null,
productName:'',
version: "", version: "",
author: null, author: null,
departmentId: null, departmentId: null,
departmentName:'',
isMain: 1, isMain: 1,
upId: null, upId: null,
upDetailId: null, upDetailId: null,
...@@ -197,7 +199,7 @@ export default { ...@@ -197,7 +199,7 @@ export default {
props: { props: {
v: Object, v: Object,
eid: Number, eid: Number,
title: String title: String,
}, },
mounted() { mounted() {
this.parms.eid = this.$u.guid(); this.parms.eid = this.$u.guid();
...@@ -308,11 +310,12 @@ export default { ...@@ -308,11 +310,12 @@ export default {
}, },
proChange(v,items) proChange(v,items)
{ {
alert(v+"__"+JSON.stringify(items)) this.entity.productName=items.name
}, },
departChange(v,items) departChange(v,items)
{ {
alert(v+"__"+JSON.stringify(items))
this.entity.departmentName=items.name
} }
}, },
watch: { watch: {
......
<template>
<div class="detail">
<Row>
<Filed :span="5" :name="l('productName')">{{info.productName}}</Filed>
<Filed :span="6" :name="l('name')">{{info.name}}</Filed>
<Filed :span="5" :name="l('code')">{{info.code}}</Filed>
<Filed :span="5" :name="l('routingType')"><state code="Process.Routing.routingType" :value="info.routingType" type="text"></state></Filed>
<Filed :span="3" :name="l('version')">{{info.version}}</Filed>
</Row>
</div>
</template>
<script>
export default {
name: 'detailExamine',
props: ['info'],
async fetch({ store, params }) {
await store.dispatch('loadDictionary') // 加载数据字典
},
data() {
return {}
},
methods: {
arry2Name(arryList, values) {
//预警类别转换
var codes = arryList
var name = ''
for (let i in codes) {
if (values == codes[i].value) {
name = codes[i].name
}
}
return name
},
l(key) {
key = 'processList' + '.' + key
return this.$t(key)
}
}
}
</script>
<style lang="less" scope>
.detail {
display: table;
border-collapse: collapse;
width: 100%;
.ivu-row {
display: table-row;
.filed-col {
display: table-cell;
margin: 0 0 -1px 0px;
line-height: 30px;
box-sizing: border-box;
.label {
background: #e8eaf1;
display: inline-block;
width: 120px;
text-align: right;
padding: 0 5px;
}
}
}
}
</style>
<template> <template>
<Form ref="form" :model="entity" :rules="rules" :label-width="100"> <div class="details">
<Row> <Form ref="form" :model="entity" :rules="rules" :label-width="110">
<!-- <Row>
<!--
<Col :span="12"> <Col :span="12">
<FormItem :label="l('routingHeaderId')" prop="routingHeaderId"> <FormItem :label="l('routingHeaderId')" prop="routingHeaderId">
<InputNumber v-model="entity.routingHeaderId"></InputNumber> <InputNumber v-model="entity.routingHeaderId"></InputNumber>
...@@ -71,99 +72,100 @@ ...@@ -71,99 +72,100 @@
<Input v-model="entity.remark" type="textarea" :rows="5"></Input> <Input v-model="entity.remark" type="textarea" :rows="5"></Input>
</FormItem> </FormItem>
</Col> </Col>
--> -->
<Col :span="8"> <Col :span="8">
<FormItem :label="l('taskSeq')" prop="taskSeq"> <FormItem :label="l('taskSeq')" prop="taskSeq">
<InputNumber v-model="entity.taskSeq"></InputNumber> <InputNumber v-model="maxNum" style="width:100%"></InputNumber>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('name')" prop="name"> <FormItem :label="l('name')" prop="name">
<Input v-model="entity.name"></Input> <Input v-model="entity.name"></Input>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('equipType')" prop="equipType"> <FormItem :label="l('equipType')" prop="equipType">
<EquipSelect v-model="entity.equipType"></EquipSelect> <EquipSelect v-model="entity.equipType"></EquipSelect>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('resourceType')" prop="resourceType"> <FormItem :label="l('resourceType')" prop="resourceType">
<Dictionary code="Process.routing_detail.resource_type" v-model="entity.resourceType"></Dictionary> <Dictionary code="Process.routing_detail.resource_type" v-model="entity.resourceType"></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('isImportant')" prop="isImportant"> <FormItem :label="l('isImportant')" prop="isImportant">
<Dictionary code="Process.state" v-model="entity.isImportant" type="radio"></Dictionary> <Dictionary code="Process.state" v-model="entity.isImportant" type="radio"></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('isImportantResources')" prop="isImportantResources"> <FormItem :label="l('isImportantResources')" prop="isImportantResources">
<Dictionary code="Process.state" v-model="entity.isImportantResources" type="radio"></Dictionary> <Dictionary code="Process.state" v-model="entity.isImportantResources" type="radio"></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('schedulingWorkingHours')" prop="schedulingWorkingHours"> <FormItem :label="l('schedulingWorkingHours')" prop="schedulingWorkingHours">
<InputTime v-model="entity.schedulingWorkingHours" /> <InputTime v-model="entity.schedulingWorkingHours" />
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('runtime')" prop="runtime"> <FormItem :label="l('runtime')" prop="runtime">
<InputTime v-model="entity.runtime" /> <InputTime v-model="entity.runtime" />
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('realRuntime')" prop="realRuntime"> <FormItem :label="l('realRuntime')" prop="realRuntime">
<InputTime v-model="entity.realRuntime" /> <InputTime v-model="entity.realRuntime" />
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('realWorkingHours')" prop="realWorkingHours"> <FormItem :label="l('realWorkingHours')" prop="realWorkingHours">
<InputTime v-model="entity.realWorkingHours" /> <InputTime v-model="entity.realWorkingHours" />
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8" > <Col :span="8">
<FormItem :label="l('isOutside')" prop="isOutside"> <FormItem :label="l('isOutside')" prop="isOutside">
<Dictionary code="Process.state" v-model="entity.isOutside" type="radio" style="height:20px"></Dictionary> <Dictionary
</FormItem> code="Process.state"
</Col> v-model="entity.isOutside"
<Col :span="8" v-show="entity.isOutside==1"> type="radio"
<FormItem :label="l('outsideTime')" prop="outsideTime"> style="height:20px"
<InputTime v-model="entity.outsideTime" /> ></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8" v-show="entity.isOutside==1">
<Col :span="8"> <FormItem :label="l('outsideTime')" prop="outsideTime">
<FormItem :label="l('isParticipateIntime')" prop="isParticipateIntime"> <InputTime v-model="entity.outsideTime" />
<Dictionary code="Process.state" v-model="entity.isParticipateIntime" type="radio"></Dictionary> </FormItem>
</FormItem> </Col>
</Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('efficiencyValue')" prop="efficiencyValue"> <FormItem :label="l('isParticipateIntime')" prop="isParticipateIntime">
<InputNumber v-model="entity.efficiencyValue"></InputNumber> <Dictionary code="Process.state" v-model="entity.isParticipateIntime" type="radio"></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('singleOut')" prop="singleOut"> <FormItem :label="l('efficiencyValue')" prop="efficiencyValue">
<InputNumber v-model="entity.singleOut"></InputNumber> <InputNumber v-model="entity.efficiencyValue" style="width:100%"></InputNumber>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="24"> <Col :span="8">
<FormItem :label="l('taskContent')" prop="taskContent"> <FormItem :label="l('singleOut')" prop="singleOut">
<i-quill <InputNumber v-model="entity.singleOut" style="width:100%"></InputNumber>
v-model="entity.taskContent" </FormItem>
:height="200" </Col>
v-paste="handleImg" <Col :span="24">
border <FormItem :label="l('taskContent')" prop="taskContent">
/> <i-quill v-model="entity.taskContent" :height="200" v-paste="handleImg" border />
</FormItem> </FormItem>
</Col> </Col>
</Row> </Row>
<FormItem> <FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button> <Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button @click="handleClose" class="ml20">取消</Button> <Button @click="handleClose" class="ml20">取消</Button>
</FormItem> </FormItem>
</Form> </Form>
</div>
</template> </template>
<script> <script>
import Api from "./api"; import Api from "./api";
...@@ -191,7 +193,7 @@ export default { ...@@ -191,7 +193,7 @@ export default {
realWorkingHours: 0, realWorkingHours: 0,
realRuntime: 0, realRuntime: 0,
isParticipateIntime: null, isParticipateIntime: null,
equipType: "", equipType: ""
}, },
rules: { rules: {
name: [{ required: true, message: "必填", trigger: "blur" }] name: [{ required: true, message: "必填", trigger: "blur" }]
...@@ -201,7 +203,8 @@ export default { ...@@ -201,7 +203,8 @@ export default {
props: { props: {
v: Object, v: Object,
eid: Number, eid: Number,
headid:Number, headid: Number,
maxNum:Number,
}, },
mounted() { mounted() {
if (this.eid > 0) { if (this.eid > 0) {
...@@ -213,7 +216,8 @@ export default { ...@@ -213,7 +216,8 @@ export default {
this.$refs.form.validate(v => { this.$refs.form.validate(v => {
if (v) { if (v) {
this.disabled = true; this.disabled = true;
this.entity.routingHeaderId=this.headid this.entity.routingHeaderId = this.headid;
this.entity.taskSeq=this.maxNum
Api.create(this.entity) Api.create(this.entity)
.then(r => { .then(r => {
this.disabled = false; this.disabled = false;
...@@ -278,4 +282,6 @@ export default { ...@@ -278,4 +282,6 @@ export default {
} }
} }
}; };
</script> </script>
\ No newline at end of file <style type="less">
</style>
\ No newline at end of file
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
:eid="curId" :eid="curId"
:headid="hid" :headid="hid"
:eName="curName" :eName="curName"
:maxNum="maxNum"
@on-close="cancel" @on-close="cancel"
@on-ok="ok" @on-ok="ok"
/> />
...@@ -70,18 +71,24 @@ export default { ...@@ -70,18 +71,24 @@ export default {
}); });
} }
}, },
{ key: "taskSeq", title: this.l("taskSeq"), align: "left",width:100,sortable:true }, {
key: "taskSeq",
title: this.l("taskSeq"),
align: "left",
width: 100,
sortable: true
},
{ {
key: "name", key: "name",
title: this.l("name"), title: this.l("name"),
align: "left", align: "left"
}, },
{ {
key: "equipType", key: "equipType",
title: this.l("equipType"), title: this.l("equipType"),
align: "left", align: "left",
easy: true, easy: true,
hide:true, hide: true
}, },
{ {
key: "resourceType", key: "resourceType",
...@@ -119,15 +126,15 @@ export default { ...@@ -119,15 +126,15 @@ export default {
title: this.l("isParticipateIntime"), title: this.l("isParticipateIntime"),
align: "center", align: "center",
code: "Process.state", code: "Process.state",
hide: true, hide: true
}, },
{ {
key: "isImportant", key: "isImportant",
title: this.l("isImportant"), title: this.l("isImportant"),
align: "center", align: "center",
code: "Process.state", code: "Process.state",
width:100, width: 100,
hide: true, hide: true
}, },
{ {
key: "isOutside", key: "isOutside",
...@@ -135,7 +142,7 @@ export default { ...@@ -135,7 +142,7 @@ export default {
align: "center", align: "center",
hide: true, hide: true,
code: "Process.state", code: "Process.state",
width:100 width: 100
}, },
{ {
...@@ -270,7 +277,7 @@ export default { ...@@ -270,7 +277,7 @@ export default {
{ {
attrs: { oprate: "detail" }, attrs: { oprate: "detail" },
on: { on: {
click: () => this.addStep(params.row.id, params.row.name) click: () => this.addStep(params.row.id, params.row.name,params.row.maxNumStep)
} }
}, },
"新增" "新增"
...@@ -304,17 +311,18 @@ export default { ...@@ -304,17 +311,18 @@ export default {
} }
} }
], ],
list: [] list: [],
maxNum: 0,
maxNumTemp:0,
}; };
}, },
created() { created() {
console.warn("dfadf:", this.headerid);
if (this.headerid != -1) { if (this.headerid != -1) {
this.easySearch.routingHeaderId.value = this.headerid; this.easySearch.routingHeaderId.value = this.headerid;
} else { } else {
this.easySearch.routingHeaderId.value = this.$route.query.id; this.easySearch.routingHeaderId.value = this.$route.query.id;
} }
this.hid = this.easySearch.routingHeaderId.value; this.hid =Number(this.easySearch.routingHeaderId.value);
}, },
mounted() { mounted() {
this.load(); this.load();
...@@ -337,7 +345,30 @@ export default { ...@@ -337,7 +345,30 @@ export default {
Api.getdetailsteps(params) Api.getdetailsteps(params)
.then(r => { .then(r => {
if (r.success) { if (r.success) {
this.list = r.result; this.list = [];
let tempNum = [];
let listTemp = r.result;
if (listTemp.length > 0) {
listTemp.forEach(data => {
tempNum.push(data.taskSeq);
let listStepTemp = [];
if (data.steps.length > 0) {
listStepTemp = data.steps;
let tempNum1 = [];
listStepTemp.forEach(dataStep => {
tempNum1.push(dataStep.stepSeq);
});
let maxNumStep = Math.max(...tempNum1) + 1;
data.maxNumStep = maxNumStep;
} else {
data.maxNumStep = 1;
}
});
this.maxNumTemp = Math.max(...tempNum) + 1;
} else {
this.maxNumTemp = 1;
}
this.list = listTemp;
} }
}) })
.catch(err => { .catch(err => {
...@@ -354,6 +385,7 @@ export default { ...@@ -354,6 +385,7 @@ export default {
}, },
add() { add() {
this.curId = 0; this.curId = 0;
this.maxNum=this.maxNumTemp
this.title = "新增"; this.title = "新增";
this.detail = () => import("./add"); this.detail = () => import("./add");
this.modal = true; this.modal = true;
...@@ -388,9 +420,10 @@ export default { ...@@ -388,9 +420,10 @@ export default {
this.curId = 0; this.curId = 0;
this.modal = false; this.modal = false;
}, },
addStep(detailId, detailName) { addStep(detailId, detailName,detailMaxNumStep) {
this.curId = detailId; this.curId = detailId;
this.curName = detailName; this.curName = detailName;
this.maxNum=detailMaxNumStep;
this.title = "新增工步"; this.title = "新增工步";
this.detail = () => import("./routingStep/add"); this.detail = () => import("./routingStep/add");
this.modal = true; this.modal = true;
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<Col :span="12"> <Col :span="12">
<FormItem :label="l('stepSeq')" prop="stepSeq"> <FormItem :label="l('stepSeq')" prop="stepSeq">
<!-- <InputNumber v-model="entity.stepSeq"></InputNumber> --> <!-- <InputNumber v-model="entity.stepSeq"></InputNumber> -->
<InputNumber v-model="entity.stepSeq"></InputNumber> <InputNumber v-model="maxNum"></InputNumber>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="12"> <Col :span="12">
...@@ -133,7 +133,7 @@ export default { ...@@ -133,7 +133,7 @@ export default {
eid: Number,//工序id eid: Number,//工序id
eName:String,//工序名称 eName:String,//工序名称
headid:Number,//工艺id headid:Number,//工艺id
maxNum:Number,
}, },
mounted() { mounted() {
...@@ -145,6 +145,7 @@ export default { ...@@ -145,6 +145,7 @@ export default {
this.disabled = true; this.disabled = true;
this.entity.routingHeaderId=this.headid this.entity.routingHeaderId=this.headid
this.entity.routingDetailId=this.eid this.entity.routingDetailId=this.eid
this.entity.stepSeq=this.maxNum
Api.create(this.entity) Api.create(this.entity)
.then(r => { .then(r => {
this.disabled = false; this.disabled = false;
......
<template> <template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90"> <Form ref="form" :model="entity" :rules="rules" :label-width="110">
<Row> <Row>
<!-- <Col :span="12"> <!-- <Col :span="12">
<FormItem :label="l('classId')" prop="classId"> <FormItem :label="l('classId')" prop="classId">
...@@ -27,8 +27,8 @@ ...@@ -27,8 +27,8 @@
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('productId')" prop="productId"> <FormItem :label="l('productName')" prop="productId">
<ProductSelect v-model="entity.productId"></ProductSelect> <ProductSelect v-model="entity.productId" @on-change="proChange"></ProductSelect>
</FormItem> </FormItem>
</Col> </Col>
...@@ -38,26 +38,21 @@ ...@@ -38,26 +38,21 @@
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('author')" prop="author"> <FormItem :label="l('departmentName')" prop="departmentId">
<UserSelect v-model="entity.author"></UserSelect> <departmentSelect v-model="entity.departmentId" @on-change="departChange"></departmentSelect>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="8"> <Col :span="8">
<FormItem :label="l('departmentId')" prop="departmentId">
<departmentSelect v-model="entity.departmentId"></departmentSelect>
</FormItem>
</Col>
<Col :span="5">
<FormItem :label="l('isMain')" prop="isMain"> <FormItem :label="l('isMain')" prop="isMain">
<Dictionary code="Process.state" v-model="entity.isMain" type="radio"></Dictionary> <Dictionary code="Process.state" v-model="entity.isMain" type="radio"></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="6"> <Col :span="8">
<FormItem :label="l('isSendPpm')" prop="isSendPpm"> <FormItem :label="l('isSendPpm')" prop="isSendPpm">
<Dictionary code="Process.Status" v-model="entity.isSendPpm" type="radio"></Dictionary> <Dictionary code="Process.Status" v-model="entity.isSendPpm" type="radio"></Dictionary>
</FormItem> </FormItem>
</Col> </Col>
<Col :span="5"> <Col :span="8">
<FormItem :label="l('isEffect')" prop="isEffect"> <FormItem :label="l('isEffect')" prop="isEffect">
<Dictionary code="Process.Status" v-model="entity.isEffect" type="radio"></Dictionary> <Dictionary code="Process.Status" v-model="entity.isEffect" type="radio"></Dictionary>
</FormItem> </FormItem>
...@@ -151,7 +146,9 @@ export default { ...@@ -151,7 +146,9 @@ export default {
data() { data() {
return { return {
disabled: false, disabled: false,
entity: {}, entity: {
},
rules: { rules: {
name: [{ required: true, message: "必填", trigger: "blur" }] name: [{ required: true, message: "必填", trigger: "blur" }]
}, },
...@@ -230,6 +227,15 @@ export default { ...@@ -230,6 +227,15 @@ export default {
l(key) { l(key) {
key = "routingHeader" + "." + key; key = "routingHeader" + "." + key;
return this.$t(key); return this.$t(key);
},
proChange(v,items)
{
this.entity.productName=items.name
},
departChange(v,items)
{
this.entity.departmentName=items.name
} }
}, },
watch: { watch: {
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
bottom: 0; bottom: 0;
right: 0; right: 0;
// bottom:100%; // bottom:100%;
// right: 100%; // right: 100%;
z-index: 898; z-index: 898;
background-color: white; background-color: white;
// background: red; // background: red;
...@@ -64,6 +64,22 @@ ...@@ -64,6 +64,22 @@
@on-ok="ok" @on-ok="ok"
/> />
</Modal> </Modal>
<Modal
v-model="documentShow"
title="送审"
:mask-closable="false"
:scrollable="true"
ok-text="确定"
cancel-text="取消"
fullscreen
>
<sendAudit ref="sendAudit"></sendAudit>
<div slot="footer">
<Button @click="documentShow = false">取消</Button>
<Button type="primary" @click="passDocument">工艺规程送审</Button>
</div>
</Modal>
<div class="fullWindow flex fd" v-if="viewModal"> <div class="fullWindow flex fd" v-if="viewModal">
<div class="top flex"> <div class="top flex">
<div v-width="200"> <div v-width="200">
...@@ -71,17 +87,17 @@ ...@@ -71,17 +87,17 @@
<Icon type="ios-undo-outline" size="24" />返回工艺规程 <Icon type="ios-undo-outline" size="24" />返回工艺规程
</a> </a>
</div> </div>
<div class="fg tc f14 fwBold blueTitle"> <div class="fg tc f14 fwBold blueTitle" style="padding-right:200px;">
{{l('code')}}: {{l('code')}}:
<span class="grayTitle mr10">{{titleObj.code}}</span> <span class="grayTitle mr10">{{titleObj.code}}</span>
{{l('name')}}: {{l('name')}}:
<span class="grayTitle mr10">{{titleObj.name}}</span> <span class="grayTitle mr10">{{titleObj.name}}</span>
{{l('routingType')}}: {{l('routingType')}}:
<span class="grayTitle mr10">{{titleObj.routingType}}</span> <span class="grayTitle mr10"><state code="Process.Routing.routingType" :value="titleObj.routingType" type="text"></state></span>
{{l('version')}}: {{l('version')}}:
<span class="grayTitle">{{titleObj.version}}</span> <span class="grayTitle">{{titleObj.version}}</span>
<!-- {{l('departmentId')}}: {{l('departmentName')}}:
<span class="grayTitle">{{titleObj.departmentId}}</span>--> <span class="grayTitle">{{titleObj.departmentName}}</span>
</div> </div>
</div> </div>
<div class="fg"> <div class="fg">
...@@ -96,8 +112,9 @@ ...@@ -96,8 +112,9 @@
import Api from "./api"; import Api from "./api";
import Search from "./search"; import Search from "./search";
import ProductTree from "@/components/page/productTree.vue"; import ProductTree from "@/components/page/productTree.vue";
import sendAudit from './sendAudit.vue'
export default { export default {
components: { ProductTree, Search }, components: { ProductTree, Search,sendAudit},
head: { head: {
title: "工艺规程", title: "工艺规程",
author: "henq", author: "henq",
...@@ -119,9 +136,10 @@ export default { ...@@ -119,9 +136,10 @@ export default {
detail: null, detail: null,
curId: 0, curId: 0,
uId: "", uId: "",
documentShow: false,
columns: [ columns: [
{ key: "id", title: this.$t("id"), hide: true, align: "left" }, { key: "id", title: this.$t("id"), hide: true, align: "left" },
{ key: "classId", title: this.l("classId"), align: "left", hide: true }, { key: "classId", title: this.l("classId"), align: "left", hide: true },
{ {
key: "unicode", key: "unicode",
...@@ -142,26 +160,31 @@ export default { ...@@ -142,26 +160,31 @@ export default {
key: "name", key: "name",
title: this.l("name"), title: this.l("name"),
align: "left", align: "left",
width: 200,
easy: true, easy: true,
high: true high: true
}, },
{ {
key: "productId", key: "productName",
title: this.l("productId"), title: this.l("productName"),
align: "left", align: "left",
high: true high: true
}, },
{ key: "version", title: this.l("version"), align: "left", high: true }, { key: "version", title: this.l("version"), align: "left", high: true },
{ key: "creatorUserId", title: this.l("author"), align: "left", high: true,type:"user" },
{ {
key: "departmentId", key: "creatorUserId",
title: this.l("departmentId"), title: this.l("author"),
align: "left",
high: true,
type: "user"
},
{
key: "departmentName",
title: this.l("departmentName"),
width: 100, width: 100,
align: "left", align: "left",
high: true high: true
}, },
// { key:"upId",title:this.l("upId") ,align:"left" ,high:true }, // { key:"upId",title:this.l("upId") ,align:"left" ,high:true },
// { key:"upDetailId",title:this.l("upDetailId") ,hide:true ,align:"left" ,high:true }, // { key:"upDetailId",title:this.l("upDetailId") ,hide:true ,align:"left" ,high:true },
{ {
...@@ -184,7 +207,6 @@ export default { ...@@ -184,7 +207,6 @@ export default {
align: "center", align: "center",
width: 80, width: 80,
high: true, high: true,
hide: true,
code: "Process.Status" code: "Process.Status"
}, },
{ {
...@@ -199,7 +221,7 @@ export default { ...@@ -199,7 +221,7 @@ export default {
title: this.l("phase"), title: this.l("phase"),
align: "left", align: "left",
high: true, high: true,
hide: true, hide: true,
code: "Process.Routing.phase" code: "Process.Routing.phase"
}, },
{ {
...@@ -225,7 +247,7 @@ export default { ...@@ -225,7 +247,7 @@ export default {
high: true, high: true,
code: "Process.Status" code: "Process.Status"
}, },
{ {
key: "creationTime", key: "creationTime",
title: this.$t("creationTime"), title: this.$t("creationTime"),
align: "left", align: "left",
...@@ -252,8 +274,8 @@ export default { ...@@ -252,8 +274,8 @@ export default {
{ {
title: "操作", title: "操作",
key: "action", key: "action",
width: 180, width: 210,
align: "center", align: "left",
render: (h, params) => { render: (h, params) => {
return h("div", { class: "action" }, [ return h("div", { class: "action" }, [
h( h(
...@@ -295,6 +317,16 @@ export default { ...@@ -295,6 +317,16 @@ export default {
on: { click: () => this.remove(params.row.id) } on: { click: () => this.remove(params.row.id) }
}, },
"删除" "删除"
),
h(
"op",
{
attrs: { oprate: "detail" },
on: { click: () => this.sendAuditFun(params.row) }
},
params.row.approvalStatus == 4
? "送审"
: ""
) )
]); ]);
} }
...@@ -305,7 +337,7 @@ export default { ...@@ -305,7 +337,7 @@ export default {
name: "", //工艺名称 name: "", //工艺名称
routingType: 0, //工艺类型 routingType: 0, //工艺类型
version: "", //工艺版本 version: "", //工艺版本
departmentId: null //车间 departmentName: null //车间
}, },
processviewModal: false processviewModal: false
}; };
...@@ -344,7 +376,7 @@ export default { ...@@ -344,7 +376,7 @@ export default {
name: row.name, name: row.name,
routingType: row.routingType, routingType: row.routingType,
version: row.version, version: row.version,
departmentId: row.departmentId departmentName: row.departmentName
}; };
// this.info=()=>import("./details") // this.info=()=>import("./details")
this.src = "/technology/details?id=" + row.id; this.src = "/technology/details?id=" + row.id;
...@@ -421,6 +453,29 @@ export default { ...@@ -421,6 +453,29 @@ export default {
l(key) { l(key) {
let vkey = "routingHeader" + "." + key; let vkey = "routingHeader" + "." + key;
return this.$t(vkey) || key; return this.$t(vkey) || key;
},
//送审
sendAuditFun(row) {
this.documentShow = true;
this.$refs.sendAudit.intData(row);
},
saveDocument() {
this.documentShow = true;
this.$refs.sendAudit.intData(this.headerInfo);
},
passDocument() {
this.dataListRetrun = [];
this.dataListRetrun = this.$refs.sendAudit.returnDataList();
this.$http.order.batchstart(this.dataListRetrun).then(res => {
if (res.success) {
this.$Message.success("工艺规程送审成功!");
this.loaddata();
//this.easySearch('')
} else {
this.$Message.error("工艺规程送审失败!");
}
});
this.documentShow = false;
} }
} }
}; };
......
<template>
<div style="width:80%;margin:0 auto">
<DetailExamine :info="info"></DetailExamine>
<Process
ref="userProcess"
schemaIdVal="2085025d-9c38-4834-846a-8f9d2f4c8553"
/>
</div>
</template>
<script>
import Process from '@/components/orderOperator/process'
import DetailExamine from './detailExamine'
export default {
name: 'sendAudit',
components: {
Process,
DetailExamine
},
data() {
return {
info: {},
dataList: {},
dataListRetrun: [], //确定后返回数据
dataListRetrunNew: {
schemaId: '2085025d-9c38-4834-846a-8f9d2f4c8553', //订单送审的schemaId
idList: [], //订单id List
codeList: [], //订单编号List
operatorIdList: [] //操作员id
} //确定后返回数据
}
},
created: function() {},
methods: {
intData(data) {
//打开modal层时给订单list赋值
this.dataList ={}
this.dataList = data
this.info = data
},
returnDataList() {
this.dataListRetrunNew.idList = []
this.dataListRetrunNew.codeList = []
this.dataListRetrunNew.operatorIdList = []
this.dataListRetrunNew.idList.push(this.dataList.id)
this.dataListRetrunNew.codeList.push(this.dataList.code)
let ues = this.$refs.userProcess
this.dataListRetrunNew.operatorIdList = ues.immutData
// alert(JSON.stringify( this.dataListRetrunNew))
//返回审批数据
return this.dataListRetrunNew
}
}
}
</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