0610chengpinbanchengpinjianchabiao

This commit is contained in:
shijing 2022-06-10 17:15:54 +08:00
parent 44d6523049
commit 38ca0424e3
7 changed files with 68 additions and 21 deletions

View File

@ -32,8 +32,8 @@
required required
> >
<el-input-number <el-input-number
style="width: 100%;"
v-model="checkForm[item.field_key]" v-model="checkForm[item.field_key]"
style="width: 100%;"
step-strictly step-strictly
placeholder="请输入" placeholder="请输入"
:min="0" :min="0"
@ -46,8 +46,8 @@
required required
> >
<el-input-number <el-input-number
style="width: 100%;"
v-model="checkForm[item.field_key]" v-model="checkForm[item.field_key]"
style="width: 100%;"
:precision="2" :precision="2"
:step="0.1" :step="0.1"
placeholder="请输入" placeholder="请输入"
@ -229,7 +229,7 @@
that.is_save = true; that.is_save = true;
} else { } else {
that.checkForm[key] = ''; that.checkForm[key] = '';
that.$set(that.checkForm, key, null) that.$set(that.checkForm, key, '')
} }
} }
let listJudge = this.formData.filter(item => { let listJudge = this.formData.filter(item => {
@ -337,7 +337,7 @@
that.formData[index].is_hidden = false; that.formData[index].is_hidden = false;
} else { } else {
that.formData[index].is_hidden = true; that.formData[index].is_hidden = true;
that.checkForm[field_key] = null; that.checkForm[field_key] = '';
} }
return rea; return rea;
} else { } else {
@ -350,7 +350,7 @@
that.formData[index].is_hidden = false; that.formData[index].is_hidden = false;
} else { } else {
that.formData[index].is_hidden = true; that.formData[index].is_hidden = true;
that.checkForm[field_key] = null; that.checkForm[field_key] = '';
} }
return eval(eval(a)); return eval(eval(a));
} }

View File

@ -429,7 +429,7 @@
that.formData[index].is_hidden = false; that.formData[index].is_hidden = false;
}else{ }else{
that.formData[index].is_hidden = true; that.formData[index].is_hidden = true;
that.checkForm[field_key] = null; that.checkForm[field_key] = '';
} }
return rea; return rea;
}else{ }else{
@ -442,7 +442,7 @@
that.formData[index].is_hidden = false; that.formData[index].is_hidden = false;
}else{ }else{
that.formData[index].is_hidden = true; that.formData[index].is_hidden = true;
that.checkForm[field_key] = null; that.checkForm[field_key] = '';
} }
return eval(eval(a)); return eval(eval(a));
} }

View File

@ -360,12 +360,19 @@
//检查表 //检查表
handlebind(scope) { handlebind(scope) {
let materialItem = sessionStorage.getItem('materialItem'); let materialItem = sessionStorage.getItem('materialItem');
let materialType = sessionStorage.getItem('materialType');
if(materialItem){ if(materialItem){
sessionStorage.removeItem('materialItem'); sessionStorage.removeItem('materialItem');
sessionStorage.setItem('materialItem',JSON.stringify(scope.row)); sessionStorage.setItem('materialItem',JSON.stringify(scope.row));
}else{ }else{
sessionStorage.setItem('materialItem',JSON.stringify(scope.row)); sessionStorage.setItem('materialItem',JSON.stringify(scope.row));
} }
if(materialType){
sessionStorage.removeItem('materialType');
sessionStorage.setItem('materialType','30');
}else{
sessionStorage.setItem('materialType','30');
}
this.$router.push({name: "MaterialDO", params: {id: scope.row.id}}) this.$router.push({name: "MaterialDO", params: {id: scope.row.id}})
}, },
handleFilter() { handleFilter() {

View File

@ -596,7 +596,7 @@
}, },
listQueryrecordform: { listQueryrecordform: {
page: 1, page: 1,
page_size: 20, page_size: 99,
}, },
recordformList: { recordformList: {
count: 0, count: 0,
@ -694,10 +694,10 @@
], ],
typeOptions_:{ typeOptions_:{
10 : "生产记录表", 10 : "生产记录表",
20 : "工序检查表", 20 : "工序检查表",//wp p
30 : "入厂检验表", 30 : "入厂检验表",//wuliao
40 : "成品检验表", 40 : "成品检验表",//p
50 : "首件检查表", 50 : "首件检查表",//wp
}, },
materialTypes: { materialTypes: {
"1": '成品', "1": '成品',
@ -723,12 +723,19 @@
judgeList: [], judgeList: [],
limitedPhoto: false, limitedPhoto: false,
isDisabled: true, isDisabled: true,
type:null,
}; };
}, },
computed: {}, computed: {},
watch: {}, watch: {},
mounted(){ mounted(){
this.item = JSON.parse(sessionStorage.getItem('materialItem')) ; this.item = JSON.parse(sessionStorage.getItem('materialItem')) ;
let type = sessionStorage.getItem('materialType') ;
if(type.indexOf(','>0)){
this.type = type.split(',');
}else{
this.type = parseInt(type);
}
this.material = this.item.id; this.material = this.item.id;
this.recordformLists(); this.recordformLists();
getrecordformList({page:0}).then((response) => { getrecordformList({page:0}).then((response) => {
@ -896,13 +903,32 @@
this.fieldLists1(); this.fieldLists1();
}, },
recordformLists() { recordformLists() {
this.listQueryrecordform.material = this.material; debugger;
// this.listQueryrecordform.type = 2; let that = this;
getrecordformList(this.listQueryrecordform).then((response) => { that.listQueryrecordform.material = that.material;
if (response.data) { if(that.type===10){
this.recordformList = response.data; debugger;
} that.listQueryrecordform.type = 10;
}); getrecordformList(that.listQueryrecordform).then((response) => {
if (response.data) {
that.recordformList = response.data;
}
});
}else{
debugger;
that.listQueryrecordform.type = that.type[0];
getrecordformList(that.listQueryrecordform).then((response) => {
if (response.data) {
that.recordformList = response.data;
that.listQueryrecordform.type = that.type[1];
getrecordformList(that.listQueryrecordform).then((response) => {
if (response.data) {
that.recordformList.results = that.recordformList.results.concat(response.data.results);
}
});
}
});
}
}, },
fieldLists() { fieldLists() {
let that = this; let that = this;

View File

@ -286,12 +286,19 @@
//检查表 //检查表
handlebind(scope) { handlebind(scope) {
let materialItem = sessionStorage.getItem('materialItem'); let materialItem = sessionStorage.getItem('materialItem');
let materialType = sessionStorage.getItem('materialType');
if(materialItem){ if(materialItem){
sessionStorage.removeItem('materialItem'); sessionStorage.removeItem('materialItem');
sessionStorage.setItem('materialItem',JSON.stringify(scope.row)); sessionStorage.setItem('materialItem',JSON.stringify(scope.row));
}else{ }else{
sessionStorage.setItem('materialItem',JSON.stringify(scope.row)); sessionStorage.setItem('materialItem',JSON.stringify(scope.row));
} }
if(materialType){
sessionStorage.removeItem('materialType');
sessionStorage.setItem('materialType','20,40');
}else{
sessionStorage.setItem('materialType','20,40');
}
this.$router.push({name: "MaterialDO", params: {id: scope.row.id}}) this.$router.push({name: "MaterialDO", params: {id: scope.row.id}})
}, },
handleFilter() { handleFilter() {

View File

@ -259,12 +259,19 @@
//检查表 //检查表
handlebind(scope) { handlebind(scope) {
let materialItem = sessionStorage.getItem('materialItem'); let materialItem = sessionStorage.getItem('materialItem');
let materialType = sessionStorage.getItem('materialType');
if(materialItem){ if(materialItem){
sessionStorage.removeItem('materialItem'); sessionStorage.removeItem('materialItem');
sessionStorage.setItem('materialItem',JSON.stringify(scope.row)); sessionStorage.setItem('materialItem',JSON.stringify(scope.row));
}else{ }else{
sessionStorage.setItem('materialItem',JSON.stringify(scope.row)); sessionStorage.setItem('materialItem',JSON.stringify(scope.row));
} }
if(materialType){
sessionStorage.removeItem('materialType');
sessionStorage.setItem('materialType','20,50');
}else{
sessionStorage.setItem('materialType','20,50');
}
this.$router.push({name: "MaterialDO", params: {id: scope.row.id}}) this.$router.push({name: "MaterialDO", params: {id: scope.row.id}})
}, },
handleFilter() { handleFilter() {

View File

@ -119,7 +119,7 @@
</el-col> </el-col>
</el-row> </el-row>
<div style="width: 90%;margin: auto;"> <div style="width: 90%;margin: auto;">
<svg height=1000 id="mySvg" style="width:100%!important;"> <svg height=1500 id="mySvg" style="width:100%!important;">
</svg> </svg>
</div> </div>
</div> </div>
@ -356,7 +356,7 @@
var g = new dagreD3.graphlib.Graph().setGraph({ var g = new dagreD3.graphlib.Graph().setGraph({
rankdir: 'DL', rankdir: 'DL',
nodesep: 100, nodesep: 100,
edgesep: 10,//两条线之间的距离 edgesep: 50,//两条线之间的距离
ranksep: 50,//节点之间的距离 ranksep: 50,//节点之间的距离
marginx: 160, marginx: 160,
marginy: 20, marginy: 20,