界面调整

yangwl
zhaoxiaolin 5 months ago
parent 52e26a4b28
commit 6767c1a1be

@ -147,10 +147,15 @@ export function delOrder(id) {
}); });
} }
// 同步SAP订单 // 同步SAP订单
export function syncSAP() { export function syncSAP(planDateStart,planDateEnd) {
const data = {
planDateStart,
planDateEnd
}
return request({ return request({
url: '/plan/order/syncSAP', url: '/plan/order/syncSAP',
method: 'post' method: 'post',
data: data
}); });
} }

@ -54,8 +54,8 @@
>导出</el-button> >导出</el-button>
</el-col> </el-col>
<el-col :span="20"> <el-col :span="20">
<div style="color:firebrick;font-size: small; text-align: center;">产量=规格*实际产量订单完成率=实际产量/计划产量标准工时=产量/产线标准效率产线效率=标准工时/实际工时 <div style="color:firebrick;font-size: small; text-align: center;">产量=规格*实际产量订单完成率=实际产量/计划产量标准工时=产量*规格/产线标准效率产线效率=标准工时/实际工时
总工时=实际用人*实际工时<br/>标准人均效率=实际产量/标准用人/标准工时实际人均效率=实际产量/总工时人均效率达成率=标准人均效率/实际人均效率</div> 总工时=实际用人*实际工时<br/>标准人均效率=实际产量/标准用人/标准工时实际人均效率=实际产量/总工时人均效率达成率=实际人均效率/标准人均效率</div>
</el-col> </el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row> </el-row>

@ -603,4 +603,10 @@ export default {
.my-print-foot { .my-print-foot {
margin-top: 20px; margin-top: 20px;
} }
@media print {
#printFrom{
font-family: Microsoft YaHei !important;
color: #000 !important;
}
}
</style> </style>

@ -1414,11 +1414,20 @@ export default {
// -SAP // -SAP
handleSyncSAP() { handleSyncSAP() {
this.loading = true; this.loading = true;
let planDateStart =null;
let planDateEnd =null;
if (this.queryParams.planDateArray != null) {
planDateStart = moment(this.queryParams.planDateArray[0]).format('YYYYMMDD')
planDateEnd = moment(this.queryParams.planDateArray[1]).format('YYYYMMDD')
}else{
this.$modal.msgError('请选择同步的时候范围')
return
}
let _this = this; let _this = this;
this.$modal.confirm('是否确认SAP同步操作步骤执行后需要一分钟后查看同步结果').then(function () { this.$modal.confirm('是否确认SAP同步操作步骤执行后需要一分钟后查看同步结果').then(function () {
_this.loading = false; _this.loading = false;
syncSAP() syncSAP(planDateStart,planDateEnd)
}).then(() => { }).then(() => {
//this.getList() //this.getList()
_this.loading = false; _this.loading = false;

@ -113,6 +113,10 @@
>维护样本量 >维护样本量
</el-button> </el-button>
</el-col> </el-col>
<el-col :span="10">
<div style="color:firebrick;font-size: small; text-align: center;">**温馨提示只供来料检验成品检验抽样使用**
</div>
</el-col>
<right-toolbar <right-toolbar
:showSearch.sync="showSearch" :showSearch.sync="showSearch"
@queryTable="getList" @queryTable="getList"
@ -130,7 +134,7 @@
label="样品量字码" label="样品量字码"
align="center" align="center"
prop="sampleCode" prop="sampleCode"
width="100" width="70"
> >
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag <dict-tag
@ -139,41 +143,39 @@
/> />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="样品量" align="center" prop="sampleAql" /> <el-table-column label="样品量" align="center" prop="sampleAql" width="50"/>
<el-table-column label="大节点" align="center" prop="typeCode" />
<el-table-column label="小节点" align="center" prop="checkType" />
<el-table-column label="接收质量限AQL" align="left"> <el-table-column label="接收质量限AQL" align="left">
<el-table-column label="0.010" align="center" prop="aql1" /> <el-table-column label="0.010" align="center" prop="aql1" width="60"/>
<el-table-column label="0.015" align="center" prop="aql2" /> <el-table-column label="0.015" align="center" prop="aql2" width="60"/>
<el-table-column label="0.025" align="center" prop="aql3" /> <el-table-column label="0.025" align="center" prop="aql3" width="60"/>
<el-table-column label="0.040" align="center" prop="aql4" /> <el-table-column label="0.040" align="center" prop="aql4" width="60"/>
<el-table-column label="0.065" align="center" prop="aql5" /> <el-table-column label="0.065" align="center" prop="aql5" width="60"/>
<el-table-column label="0.10" align="center" prop="aql6" /> <el-table-column label="0.10" align="center" prop="aql6" width="50"/>
<el-table-column label="0.15" align="center" prop="aql7" /> <el-table-column label="0.15" align="center" prop="aql7" width="50"/>
<el-table-column label="0.25" align="center" prop="aql8" /> <el-table-column label="0.25" align="center" prop="aql8" width="50"/>
<el-table-column label="0.40" align="center" prop="aql9" /> <el-table-column label="0.40" align="center" prop="aql9" width="50"/>
<el-table-column label="0.65" align="center" prop="aql10" /> <el-table-column label="0.65" align="center" prop="aql10" width="50"/>
<el-table-column label="1.0" align="center" prop="aql11" /> <el-table-column label="1.0" align="center" prop="aql11" width="50"/>
<el-table-column label="1.5" align="center" prop="aql12" /> <el-table-column label="1.5" align="center" prop="aql12" width="50"/>
<el-table-column label="2.5" align="center" prop="aql13" /> <el-table-column label="2.5" align="center" prop="aql13" width="50"/>
<el-table-column label="4.0" align="center" prop="aql14" /> <el-table-column label="4.0" align="center" prop="aql14" width="50"/>
<el-table-column label="6.5" align="center" prop="aql15" /> <el-table-column label="6.5" align="center" prop="aql15" width="50"/>
<el-table-column label="10" align="center" prop="aql16" /> <el-table-column label="10" align="center" prop="aql16" width="50"/>
<el-table-column label="15" align="center" prop="aql17" /> <el-table-column label="15" align="center" prop="aql17" width="50"/>
<el-table-column label="25" align="center" prop="aql18" /> <el-table-column label="25" align="center" prop="aql18" width="50"/>
<el-table-column label="40" align="center" prop="aql19" /> <el-table-column label="40" align="center" prop="aql19" width="50"/>
<el-table-column label="65" align="center" prop="aql20" /> <el-table-column label="65" align="center" prop="aql20" width="50"/>
<el-table-column label="100" align="center" prop="aql21" /> <el-table-column label="100" align="center" prop="aql21" width="50"/>
<el-table-column label="150" align="center" prop="aql22" /> <el-table-column label="150" align="center" prop="aql22" width="50"/>
<el-table-column label="250" align="center" prop="aql23" /> <el-table-column label="250" align="center" prop="aql23" width="50"/>
<el-table-column label="400" align="center" prop="aql24" /> <el-table-column label="400" align="center" prop="aql24" width="50"/>
<el-table-column label="650" align="center" prop="aql25" /> <el-table-column label="650" align="center" prop="aql25" width="50"/>
<el-table-column label="1000" align="center" prop="aql26" /> <el-table-column label="1000" align="center" prop="aql26" width="50"/>
</el-table-column> </el-table-column>
<el-table-column label="创建人" align="center" prop="createBy" width="100"/> <el-table-column label="创建人" align="center" prop="createBy" width="90"/>
<el-table-column label="创建时间" align="center" prop="createTime" width="300"/> <el-table-column label="创建时间" align="center" prop="createTime" width="180"/>
<el-table-column label="更新人" align="center" prop="updateBy" width="100"/> <el-table-column label="更新人" align="center" prop="updateBy" width="90"/>
<el-table-column label="更新时间" align="center" prop="updateTime" width="300"/> <el-table-column label="更新时间" align="center" prop="updateTime" width="180"/>
</el-table> </el-table>
<pagination <pagination
@ -212,10 +214,11 @@
<el-form-item label="大节点" prop="typeCode"> <el-form-item label="大节点" prop="typeCode">
<el-input v-model="form.typeCode" placeholder="请输入大节点"/> <el-input v-model="form.typeCode" placeholder="请输入大节点"/>
</el-form-item>--> </el-form-item>
<el-form-item label="样品量" prop="sampleAql"> <el-form-item label="样品量" prop="sampleAql">
<el-input v-model="form.sampleAql" placeholder="请输入样品量" /> <el-input v-model="form.sampleAql" placeholder="请输入样品量" />
</el-form-item> </el-form-item>
-->
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="0.010" prop="aql1"> <el-form-item label="0.010" prop="aql1">

@ -146,7 +146,8 @@
</el-row> </el-row>
<el-row> <el-row>
<el-col :offset="8" :span="8" class="center-text"> <el-col :offset="8" :span="8" class="center-text">
<h2>白坯检验报告</h2> <h2 v-if='form.orderType=="bp"'>白坯检验报告</h2>
<h2 v-else></h2>
</el-col> </el-col>
</el-row> </el-row>
<el-row> <el-row>
@ -235,11 +236,10 @@
<el-table v-loading="loading" :data="checkProjectList" > <el-table v-loading="loading" :data="checkProjectList" >
<el-table-column type="selection" width="50" align="center" /> <el-table-column type="selection" width="50" align="center" />
<el-table-column label="序号" align="center" type="index" width="50"/> <el-table-column label="序号" align="center" type="index" width="50"/>
<el-table-column label="检验项目" align="center" prop="ruleName" /> <el-table-column label="检验项目" align="center" prop="projectRuleName" />
<el-table-column label="标准要求" align="center" prop="checkStandard" width="160"/> <el-table-column label="标准要求" align="center" prop="checkStandard" width="160"/>
<el-table-column label="抽检数" align="center" prop="sampleNum" width="60"/> <el-table-column label="抽检数" align="center" prop="sampleNum" width="60"/>
<el-table-column label="单位" align="center" prop="unitCode" width="50"/> <el-table-column label="实测结果" align="center" prop="actualValue" width="180"/>
<el-table-column label="测量结果" align="center" prop="actualValue" width="160"/>
<el-table-column label="判定" align="center" prop="status" width="70"> <el-table-column label="判定" align="center" prop="status" width="70">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.check_result" :value="scope.row.status"/> <dict-tag :options="dict.type.check_result" :value="scope.row.status"/>
@ -264,13 +264,15 @@
</el-row> </el-row>
<el-row> <el-row>
<el-col> <el-col>
<el-form-item label="综合检验结论" prop="checkManName" label-width="100px"> <el-form-item label="综合检验结论" label-width="100px">
<el-col offset="6" span="6"> <el-checkbox-group v-model="form.checkedValues">
<el-checkbox disabled>合格</el-checkbox> <el-col offset="6" span="6">
<el-checkbox label="Y">合格</el-checkbox>
</el-col> </el-col>
<el-col offset="3" span="6"> <el-col offset="3" span="6">
<el-checkbox disabled>不合格</el-checkbox> <el-checkbox label="N">不合格</el-checkbox>
</el-col> </el-col>
</el-checkbox-group>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -379,7 +381,7 @@ export default {
factoryCode: null, factoryCode: null,
}, },
// //
form: {}, form: {checkedValues:[]},
checkTypes:[], checkTypes:[],
// //
rules: { rules: {
@ -469,7 +471,7 @@ export default {
updateTime: null, updateTime: null,
factoryCode: null, factoryCode: null,
delFlag: null, delFlag: null,
checkedValues:[],
}; };
this.resetForm("form"); this.resetForm("form");
}, },
@ -502,6 +504,11 @@ export default {
this.queryParams.recordId = recordId; this.queryParams.recordId = recordId;
getIncome(recordId).then(response => { getIncome(recordId).then(response => {
this.form = response.data; this.form = response.data;
let checkedValues0 =[];
checkedValues0.push(response.data.checkResult)
this.form.checkedValues = checkedValues0;
this.form.printable = 'printFrom'; // this.form.printable = 'printFrom'; //
this.form.ignore = ['no-print'];// this.form.ignore = ['no-print'];//
this.open = true; this.open = true;

@ -554,7 +554,7 @@
</el-row> </el-row>
<!-- 打印整个firstReportPrint区域 --> <!-- 打印整个firstReportPrint区域 -->
<div id="firstReportPrint"> <div id="firstReportPrint">
<el-form ref="form" :model="form" label-width="100px"> <el-form ref="form" :model="form" label-width="130px">
<el-row> <el-row>
<el-col :span="7"> <el-col :span="7">
<img src="@/assets/logo/lanjv.png" class="report-logo"/> <img src="@/assets/logo/lanjv.png" class="report-logo"/>
@ -889,8 +889,8 @@ export default {
delFlag: null, delFlag: null,
}; };
this.spanArr = [] this.spanArr = [];
this.position = 0 this.position = 0;
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
@ -924,6 +924,7 @@ export default {
if(row.checkType =='checkTypeSC') { if(row.checkType =='checkTypeSC') {
getProduce(recordId).then(response => { getProduce(recordId).then(response => {
this.form = response.data; this.form = response.data;
this.form.materialName = response.data.materialName+'/'+response.data.checkLoc;
// //
this.form.printable = 'firstReportPrint'; // this.form.printable = 'firstReportPrint'; //
this.form.ignore = ['no-print'];// this.form.ignore = ['no-print'];//

@ -157,9 +157,9 @@
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
<!-- 检验项目明细 --> <!-- 检验项目明细 -->
<el-table v-loading="loading" :data="checkProjectList" border> <el-table v-loading="loading" :data="checkProjectList" border :span-method="objectSpanMethod" >
<el-table-column label="序号" align="center" type="index" width="50"/> <el-table-column label="序号" align="center" type="index" width="50"/>
<el-table-column label="检验项目" align="center" prop="ruleName" width="100"/> <el-table-column label="检验项目" align="center" prop="projectRuleName" width="100"/>
<el-table-column label="标准要求" align="center" prop="checkStandard"/> <el-table-column label="标准要求" align="center" prop="checkStandard"/>
<el-table-column label="抽检数" align="center" prop="samplePlan" width="60"/> <el-table-column label="抽检数" align="center" prop="samplePlan" width="60"/>
<!--<el-table-column label="单位" align="center" prop="unitCode" width="50"/>--> <!--<el-table-column label="单位" align="center" prop="unitCode" width="50"/>-->
@ -194,7 +194,7 @@
<!-- 检验项目明细 --> <!-- 检验项目明细 -->
<el-table v-loading="loading" :data="checkProjectList0" border> <el-table v-loading="loading" :data="checkProjectList0" border>
<el-table-column label="序号" align="center" type="index" width="50"/> <el-table-column label="序号" align="center" type="index" width="50"/>
<el-table-column label="检验项目" align="center" prop="ruleName" width="100"/> <el-table-column label="检验项目" align="center" prop="projectRuleName" width="100"/>
<el-table-column label="标准要求" align="center" prop="checkStandard"/> <el-table-column label="标准要求" align="center" prop="checkStandard"/>
<el-table-column label="抽检数" align="center" prop="samplePlan" width="60"/> <el-table-column label="抽检数" align="center" prop="samplePlan" width="60"/>
<el-table-column label="实测结果及判定" align="center"> <el-table-column label="实测结果及判定" align="center">
@ -351,7 +351,9 @@ export default {
'background-color': '#d6dbe1', 'background-color': '#d6dbe1',
'min-width': '100px', 'min-width': '100px',
'word-break': 'keep-all' 'word-break': 'keep-all'
} },
spanArr: [],
position: 0
}; };
}, },
created() { created() {
@ -434,8 +436,9 @@ export default {
updateTime: null, updateTime: null,
factoryCode: null, factoryCode: null,
delFlag: null, delFlag: null,
}; };
this.spanArr = [];
this.position = 0;
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
@ -469,7 +472,7 @@ export default {
this.form = response.data; this.form = response.data;
let checkedValues0 =[]; let checkedValues0 =[];
checkedValues0.push(response.data.checkResult) checkedValues0.push(response.data.checkResult)
this.form.checkedValues = ['Y']; this.form.checkedValues = checkedValues0;
this.form.printable = 'printFrom'; // this.form.printable = 'printFrom'; //
this.form.ignore = ['no-print'];// this.form.ignore = ['no-print'];//
this.open = true; this.open = true;
@ -526,6 +529,14 @@ export default {
}else if(item.itemType == '0'){ }else if(item.itemType == '0'){
itemType0s.push(item); itemType0s.push(item);
} }
if(item.status == 'Y'){
item.status = '合格';
}else if(item.status == 'N'){
item.status = '不合格';
}else{
item.status = '/';
}
}) })
this.checkProjectList = itemType1s; this.checkProjectList = itemType1s;
@ -533,6 +544,8 @@ export default {
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
this.form.standardNo = this.checkProjectList[0].standardNo; this.form.standardNo = this.checkProjectList[0].standardNo;
this.rowspan()
}); });
}, },
// - // -
@ -559,7 +572,44 @@ export default {
getCodeValue(defectCode) { getCodeValue(defectCode) {
const foundDefect = this.defectList.find(defect => defect.defectCode === defectCode); const foundDefect = this.defectList.find(defect => defect.defectCode === defectCode);
return foundDefect.defectSubclass; return foundDefect.defectSubclass;
} },
/**
* 1. 若是objectSpanMethod不返回任何东西表格不会变化
* 2. 最外层的判断一般是先从第几列开始合并
* 3. 这次从第0行合并2个下次就要从第3行开始合并0行加俩就到3行了
* 4. 这种方式是有多少条数据合并多少条数据比如本案例中有7条数据从第0条合并到第7条
* 5. return { rowspan: 0, colspan: 0 } //
* */
rowspan() {
this.checkProjectList.forEach((item, index) => {
if (index === 0) {
this.spanArr.push(1);
this.position = 0;
} else {
if (
this.checkProjectList[index].projectRuleName ===
this.checkProjectList[index - 1].projectRuleName
) {
this.spanArr[this.position] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.position = index;
}
}
});
},
objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 1) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col,
};
}
},
} }
}; };
</script> </script>

@ -10,7 +10,7 @@
<el-col :span="24" :xs="24"> <el-col :span="24" :xs="24">
<el-form ref="form" :model="form" :rules="rules" label-width="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="8"> <el-col :span="6">
<el-form-item label="最终判定结果" prop="checkResult"> <el-form-item label="最终判定结果" prop="checkResult">
<el-radio-group v-model="form.checkResult" > <el-radio-group v-model="form.checkResult" >
<el-radio :label="'Y'">合格</el-radio> <el-radio :label="'Y'">合格</el-radio>
@ -18,7 +18,31 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="4" v-if="this.typeCode == 'material' || this.typeCode == 'product'">
<el-form-item label="检测水平" prop="checkLevel">
<el-select v-model="queryParams.checkLevel" placeholder="请选择检测水平类型" clearable>
<el-option
v-for="dict in dict.type.sample_level"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="4" v-if="this.typeCode == 'material' || this.typeCode == 'product'">
<el-form-item label="接受质量限" prop="checkAql">
<el-select v-model="queryParams.checkAql" placeholder="请选择检测水平类型" clearable>
<el-option
v-for="dict in dict.type.sample_aql"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item label="是否发起OA" prop="startOA"> <el-form-item label="是否发起OA" prop="startOA">
<el-radio-group v-model="form.startOA"> <el-radio-group v-model="form.startOA">
<el-radio :label="'1'"></el-radio> <el-radio :label="'1'"></el-radio>
@ -27,7 +51,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item v-if="form.startOA == '1'&& form.checkType == 'checkTypeLL'" label="来料类别" prop="materialType"> <el-form-item v-if="form.startOA == '1'&& this.typeCode == 'material'" label="来料类别" prop="materialType">
<el-select v-model="form.materialType" placeholder="请选择检验规则属性" clearable> <el-select v-model="form.materialType" placeholder="请选择检验规则属性" clearable>
<el-option <el-option
v-for="dict in dict.type.material_type_oa" v-for="dict in dict.type.material_type_oa"
@ -38,11 +62,9 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="8"> <el-col :span="8">
<el-form-item v-if="form.startOA == '1'&& form.checkType == 'checkTypeLL'" label="物料来源" prop="materialType"> <el-form-item v-if="form.startOA == '1'&& this.typeCode == 'material'" label="物料来源" prop="materialType">
<el-select v-model="form.materialFrom" placeholder="请选择检验规则属性" clearable> <el-select v-model="form.materialFrom" placeholder="请选择物料来源" clearable>
<el-option <el-option
v-for="dict in dict.type.material_from_oa" v-for="dict in dict.type.material_from_oa"
:key="dict.value" :key="dict.value"
@ -57,7 +79,6 @@
<el-input type='textarea' v-model="form.remark" placeholder="请输入不合格描述" /> <el-input type='textarea' v-model="form.remark" placeholder="请输入不合格描述" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>
@ -188,7 +209,7 @@ import { getCkeckProjectList,changeCheckDetailStatus,commitActualValue,commitChe
import { getDefectValue, commitDefectValue, updateDefectValue} from "@/api/quality/checkTaskDefect"; import { getDefectValue, commitDefectValue, updateDefectValue} from "@/api/quality/checkTaskDefect";
export default { export default {
name: "itemSelectUser", name: "itemSelectUser",
dicts: ["qc_rule_prop","material_type_oa","material_from_oa"], dicts: ["qc_rule_prop","material_type_oa","material_from_oa","sample_level","sample_aql"],
data() { data() {
return { return {
viewStatus : '0', viewStatus : '0',

@ -711,12 +711,10 @@ export default {
}, },
// //
handleCheckProject(row){ handleCheckProject(row){
if(row.checkStatus != '0'){
if(row.checkStatus != '0'){ this.$modal.msgSuccess("已经完成检验");
this.$modal.msgSuccess("已经完成检验");
return return
} }
this.$refs.itemSelectProject.showFlag = true; this.$refs.itemSelectProject.showFlag = true;
this.$refs.itemSelectProject.init(row,'material'); this.$refs.itemSelectProject.init(row,'material');
}, },
@ -727,7 +725,7 @@ export default {
}, },
// //
saveCheck(){ saveCheck(){
this.getList(); this.getList();
}, },
handleDefectType() { handleDefectType() {
const defectType = "material"; const defectType = "material";

Loading…
Cancel
Save