Commit b61cfee0 authored by 康振飞's avatar 康振飞

工艺克隆ok

parent 8b5e1778
...@@ -201,8 +201,8 @@ export default { ...@@ -201,8 +201,8 @@ export default {
mounted() { mounted() {
this.parms.eid = this.$u.guid(); this.parms.eid = this.$u.guid();
this.$refs.refFile.intFiles(); this.$refs.refFile.intFiles();
console.log(this.title) // console.log(this.title)
console.log(this.eid) // console.log(this.eid)
if (this.eid > 0) { if (this.eid > 0) {
this.load(this.eid); this.load(this.eid);
} }
...@@ -245,10 +245,7 @@ export default { ...@@ -245,10 +245,7 @@ export default {
headerId: this.eid, headerId: this.eid,
code: this.entity.code code: this.entity.code
}; };
console.warn(parmese)
Api.getCloneHeader(parmese).then(r => { Api.getCloneHeader(parmese).then(r => {
debugger
console.log(r)
this.disabled = false; this.disabled = false;
if (r.success) { if (r.success) {
this.$Message.success("克隆成功"); this.$Message.success("克隆成功");
...@@ -262,7 +259,6 @@ export default { ...@@ -262,7 +259,6 @@ export default {
this.$Message.error("克隆失败"); this.$Message.error("克隆失败");
console.warn(err); console.warn(err);
}); });
// this.disabled = false;
}, },
handleClose() { handleClose() {
this.$emit("on-close"); this.$emit("on-close");
...@@ -294,6 +290,16 @@ export default { ...@@ -294,6 +290,16 @@ export default {
this.entity.isEffect = parseInt(r.result.isEffect); this.entity.isEffect = parseInt(r.result.isEffect);
this.entity.id = 0; this.entity.id = 0;
}); });
if(this.title=='克隆'){
Api.getCodeNumber({code:'GY',count:'1'}).then( r => {
// console.log(r)
if(r.success){
this.entity.code = r.result[0]
}else{
this.$Message.error("生成编号失败");
}
})
}
}, },
l(key) { l(key) {
key = "routingHeader" + "." + key; key = "routingHeader" + "." + key;
......
...@@ -16,6 +16,10 @@ export default { ...@@ -16,6 +16,10 @@ export default {
getCloneHeader(params){ getCloneHeader(params){
return Api.post(`${technologyUrl}routingheader/cloneheader`,params); return Api.post(`${technologyUrl}routingheader/cloneheader`,params);
}, },
getCodeNumber(params){
return Api.post(`${systemUrl}/cache/generate_serialcode`,params);
},
delete(id) { delete(id) {
return Api.delete(`${technologyUrl}routingheader/delete`, { return Api.delete(`${technologyUrl}routingheader/delete`, {
params: { params: {
......
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