|
|
|
@ -50,7 +50,7 @@
|
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
|
/>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="创建时间">
|
|
|
|
|
<el-form-item label="工单生产日期" label-width="100px">
|
|
|
|
|
<el-date-picker
|
|
|
|
|
v-model="dateRange"
|
|
|
|
|
style="width: 240px"
|
|
|
|
@ -69,6 +69,28 @@
|
|
|
|
|
|
|
|
|
|
<el-row :gutter="10" class="mb8">
|
|
|
|
|
<el-col :span="1.5">
|
|
|
|
|
<!-- <el-button-->
|
|
|
|
|
<!-- type="success"-->
|
|
|
|
|
<!-- plain-->
|
|
|
|
|
<!-- icon="el-icon-edit"-->
|
|
|
|
|
<!-- size="mini"-->
|
|
|
|
|
<!-- :disabled="single"-->
|
|
|
|
|
<!-- @click="handleUpdate"-->
|
|
|
|
|
<!-- v-hasPermi="['unitPriceReport:report:edit']"-->
|
|
|
|
|
<!-- >修改-->
|
|
|
|
|
<!-- </el-button>-->
|
|
|
|
|
<el-button
|
|
|
|
|
type="success"
|
|
|
|
|
plain
|
|
|
|
|
icon="el-icon-edit"
|
|
|
|
|
size="mini"
|
|
|
|
|
:disabled="single"
|
|
|
|
|
@click="handleUpdate"
|
|
|
|
|
v-hasPermi="['unitPriceReport:report:edit']"
|
|
|
|
|
>修改</el-button>
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
<el-col :span="1.5">
|
|
|
|
|
<el-button
|
|
|
|
|
type="warning"
|
|
|
|
|
plain
|
|
|
|
@ -81,57 +103,47 @@
|
|
|
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-table v-loading="loading" :data="unitPriceList" @selection-change="handleSelectionChange">
|
|
|
|
|
<!-- <el-table-column type="selection" width="55" align="center" />-->
|
|
|
|
|
<el-table-column type="selection" width="55" align="center"/>
|
|
|
|
|
<el-table-column fixed="left" label="工单号" align="center" width="180" prop="workorderCode" />
|
|
|
|
|
<el-table-column fixed="left" label="工单生产日期" width="110" align="center" prop="workOrderProductDate" />
|
|
|
|
|
<el-table-column fixed="left" label="SAP订单号" align="center" width="120" prop="workorderCodeSap" />
|
|
|
|
|
<el-table-column label="物料码" align="center" width="110">
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
{{ scope.row.productCode.slice(-11) }}
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column label="物料描述" align="center" width="250" prop="productName" />
|
|
|
|
|
<el-table-column label="产品描述" align="center" width="250" prop="productName" />
|
|
|
|
|
<el-table-column label="产线编码" align="center" prop="lineCode" />
|
|
|
|
|
<el-table-column label="产线名称" align="center" width="250" prop="equipmentName" />
|
|
|
|
|
<el-table-column label="工号" width="110" align="center" prop="userName" />
|
|
|
|
|
<el-table-column label="操作者" width="110" align="center" prop="nickName" />
|
|
|
|
|
<el-table-column label="职位" width="110" align="center" prop="post" />
|
|
|
|
|
<el-table-column label="子工序名称" width="110" align="center" prop="childprocessName" />
|
|
|
|
|
<el-table-column label="当日工单报工总数" width="110" align="center" prop="orderQuantityP" />
|
|
|
|
|
<el-table-column label="规格" width="50" align="center" prop="umrez" />
|
|
|
|
|
<el-table-column label="全组数量" width="110" align="center" prop="orderQuantity" />
|
|
|
|
|
<el-table-column label="工序单价" width="110" align="center" prop="attr1" />
|
|
|
|
|
<el-table-column label="个人产量" width="100" align="center" prop="totalQuantity" />
|
|
|
|
|
<el-table-column label="计件薪酬(元)" width="110" align="center" prop="result" />
|
|
|
|
|
<el-table-column label="工时" width="110" align="center" prop="attr2" />
|
|
|
|
|
<el-table-column label="工时工资" width="100" align="center" prop="realWages" />
|
|
|
|
|
<el-table-column label="件数(PC)" width="100" align="center" prop="totalQuantity" />
|
|
|
|
|
<el-table-column label="薪酬(元)" width="110" align="center" prop="result" />
|
|
|
|
|
<el-table-column label="创建时间" width="110" align="center" prop="createTime" />
|
|
|
|
|
<!-- <el-table-column label="人数" align="center" prop="headCount" />-->
|
|
|
|
|
<!--<!– <el-table-column label="平均工资(元)" width="110" align="center" prop="avgResult" />–>-->
|
|
|
|
|
<!-- <el-table-column label="实际工资(元)" width="110" align="center" prop="realWages" />-->
|
|
|
|
|
<!-- <el-table-column label="备注" align="center" prop="remark">-->
|
|
|
|
|
<!-- <template slot-scope="scope">-->
|
|
|
|
|
<!-- <dict-tag :options="dict.type.unit_price" :value="scope.row.remark"/>-->
|
|
|
|
|
<!-- </template>-->
|
|
|
|
|
<!-- </el-table-column>-->
|
|
|
|
|
<!--<!– <el-table-column label="实际工资" align="center" prop="realWages">–>-->
|
|
|
|
|
<!--<!– <template slot-scope="scope">–>-->
|
|
|
|
|
<!--<!– <el-input type="text" size="small" v-model="scope.row.realWages" @change="handleEdit(scope.$index,scope.row)"></el-input>–>-->
|
|
|
|
|
<!--<!– </template>–>-->
|
|
|
|
|
<!--<!– </el-table-column>–>-->
|
|
|
|
|
<!--<!– <el-table-column label="实际工资" align="center" prop="realWages" />–>-->
|
|
|
|
|
<!-- <el-table-column fixed="right" label="操作" align="center" class-name="small-padding fixed-width">-->
|
|
|
|
|
<!-- <template slot-scope="scope">-->
|
|
|
|
|
<!-- <el-button-->
|
|
|
|
|
<!-- size="mini"-->
|
|
|
|
|
<!-- type="text"-->
|
|
|
|
|
<!-- icon="el-icon-edit"p-->
|
|
|
|
|
<!-- @click="handleUpdate(scope.row)"-->
|
|
|
|
|
<!-- v-hasPermi="['unitPriceReport:report:edit']"-->
|
|
|
|
|
<!-- >工资修改</el-button>-->
|
|
|
|
|
<!--<!– <el-button–>-->
|
|
|
|
|
<!--<!– size="mini"–>-->
|
|
|
|
|
<!--<!– type="text"–>-->
|
|
|
|
|
<!--<!– icon="el-icon-delete"–>-->
|
|
|
|
|
<!--<!– @click="handleDelete(scope.row)"–>-->
|
|
|
|
|
<!--<!– v-hasPermi="['system:unitPrice:remove']"–>-->
|
|
|
|
|
<!--<!– >删除</el-button>–>-->
|
|
|
|
|
<!-- </template>-->
|
|
|
|
|
<!-- </el-table-column>-->
|
|
|
|
|
|
|
|
|
|
<el-table-column label="扣款" width="110" align="center" prop="kk" />
|
|
|
|
|
<el-table-column label="保底" width="110" align="center" prop="bd" />
|
|
|
|
|
<el-table-column label="转岗" width="110" align="center" prop="zg" />
|
|
|
|
|
<el-table-column label="返工费用" width="110" align="center" prop="fg" />
|
|
|
|
|
<el-table-column label="试产" width="110" align="center" prop="sc" />
|
|
|
|
|
<el-table-column label="试机" width="110" align="center" prop="sj" />
|
|
|
|
|
<el-table-column label="特殊费用" width="110" align="center" prop="tsfy" />
|
|
|
|
|
<el-table-column label="夜班补贴" width="110" align="center" prop="ybbt" />
|
|
|
|
|
<el-table-column label="协产补贴" width="110" align="center" prop="xcbt" />
|
|
|
|
|
|
|
|
|
|
<el-table-column label="合计" width="110" align="center" prop="hj" />
|
|
|
|
|
<el-table-column label="时薪" width="100" align="center" prop="realWages" />
|
|
|
|
|
<el-table-column prop="remark" label="备注" width="110">
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
<dict-tag :options="dict.type.unit_price" :value="scope.row.remark"/>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
</el-table>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -147,41 +159,103 @@
|
|
|
|
|
<!-- 添加或修改unitPrice对话框 -->
|
|
|
|
|
<el-dialog :title="title" :visible.sync="open" width="680px" append-to-body>
|
|
|
|
|
<el-form ref="form" :model="form" label-width="100px">
|
|
|
|
|
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="实际工资" prop="attr2" >
|
|
|
|
|
<el-input v-model="form.attr2" />
|
|
|
|
|
<el-form-item label="工序" prop="childprocessName">
|
|
|
|
|
<el-input v-model="form.childprocessName" style="width: 440px" readonly />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="工时" prop="attr2" >
|
|
|
|
|
<el-input v-model="form.attr2" >
|
|
|
|
|
<template #suffix>小时</template>
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="产量" prop="attr1" >
|
|
|
|
|
<el-input v-model="form.attr1" >
|
|
|
|
|
<template #suffix>PC</template>
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="子工序" prop="childprocessName">
|
|
|
|
|
<el-select
|
|
|
|
|
v-model="form.childprocessName"
|
|
|
|
|
placeholder="子工序"
|
|
|
|
|
clearable
|
|
|
|
|
@change="handleChildprocessChange"
|
|
|
|
|
>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in MesUnitPriceInfo"
|
|
|
|
|
:key="dict.childprocessName"
|
|
|
|
|
:label="dict.childprocessName"
|
|
|
|
|
:value="dict.childprocessCode"
|
|
|
|
|
/>
|
|
|
|
|
</el-select>
|
|
|
|
|
<el-form-item label="扣款" prop="kk" >
|
|
|
|
|
<el-input v-model="form.kk" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="子工序编码" prop="childprocessCode" >
|
|
|
|
|
<el-input v-model="form.childprocessCode" :readonly="true" />
|
|
|
|
|
<el-form-item label="保底" prop="bd" >
|
|
|
|
|
<el-input v-model="form.bd" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="转岗" prop="zg" >
|
|
|
|
|
<el-input v-model="form.zg" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="返工费用" prop="fg" >
|
|
|
|
|
<el-input v-model="form.fg" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="试产" prop="sc" >
|
|
|
|
|
<el-input v-model="form.sc" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="试机" prop="sj" >
|
|
|
|
|
<el-input v-model="form.sj" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="特殊费用" prop="tsfy" >
|
|
|
|
|
<el-input v-model="form.tsfy" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="夜班补贴" prop="ybbt" >
|
|
|
|
|
<el-input v-model="form.ybbt" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="协产补贴" prop="xcbt" >
|
|
|
|
|
<el-input v-model="form.xcbt" >
|
|
|
|
|
</el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-col :span="24">
|
|
|
|
|
<el-form-item label="备注">
|
|
|
|
|
<!-- <el-input v-model="form.remark" type="textarea" placeholder="请输入内容"></el-input>-->
|
|
|
|
@ -200,7 +274,7 @@
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
</el-form>
|
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
|
|
|
@ -270,8 +344,56 @@ export default {
|
|
|
|
|
timeout: null,
|
|
|
|
|
productCode:'',
|
|
|
|
|
tableData: [],
|
|
|
|
|
MesUnitPriceInfo: []
|
|
|
|
|
MesUnitPriceInfo: [],
|
|
|
|
|
// 表单校验
|
|
|
|
|
// rules: {
|
|
|
|
|
// attr2: [
|
|
|
|
|
// { required: true, message: "工时不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// attr1: [
|
|
|
|
|
// { required: true, message: "生产数量不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// bd: [
|
|
|
|
|
// { required: true, message: "保底不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// zg: [
|
|
|
|
|
// { required: true, message: "转岗不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// fg: [
|
|
|
|
|
// { required: true, message: "返工费用不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// sc: [
|
|
|
|
|
// { required: true, message: "试产不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// sj: [
|
|
|
|
|
// { required: true, message: "试机不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// tsfy: [
|
|
|
|
|
// { required: true, message: "特殊费用不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// ybbt: [
|
|
|
|
|
// { required: true, message: "夜班补贴不能为空", trigger: "blur" },
|
|
|
|
|
// { validator: validateNumberOrDecimal, trigger: "blur" }
|
|
|
|
|
// ],
|
|
|
|
|
// }
|
|
|
|
|
};
|
|
|
|
|
// 自定义验证函数,确保输入的是数字或小数
|
|
|
|
|
// const validateNumberOrDecimal = (rule, value, callback) => {
|
|
|
|
|
// const regex = /^(\d+(\.\d{1,2})?)?$/;
|
|
|
|
|
// if (!regex.test(value)) {
|
|
|
|
|
// callback(new Error('请输入有效的数字'));
|
|
|
|
|
// } else {
|
|
|
|
|
// callback();
|
|
|
|
|
// }
|
|
|
|
|
// };
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
this.getList();
|
|
|
|
@ -333,7 +455,7 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
// 多选框选中数据
|
|
|
|
|
handleSelectionChange(selection) {
|
|
|
|
|
this.ids = selection.map(item => item.picId)
|
|
|
|
|
this.ids = selection.map(item => item.id)
|
|
|
|
|
this.single = selection.length !== 1
|
|
|
|
|
this.multiple = !selection.length
|
|
|
|
|
},
|
|
|
|
@ -343,17 +465,30 @@ export default {
|
|
|
|
|
this.open = true;
|
|
|
|
|
this.title = "添加计件薪酬信息";
|
|
|
|
|
},
|
|
|
|
|
/** 修改按钮操作 */
|
|
|
|
|
// handleUpdate(row) {
|
|
|
|
|
// console.log(row)
|
|
|
|
|
// this.reset();
|
|
|
|
|
// const picId = row.id || this.ids
|
|
|
|
|
// getReport(picId).then(response => {
|
|
|
|
|
// this.form = response.data.MesUnitpriceReport;
|
|
|
|
|
// this.open = true;
|
|
|
|
|
// this.MesUnitPriceInfo=response.data.MesUnitPriceInfo;
|
|
|
|
|
// });
|
|
|
|
|
// },
|
|
|
|
|
|
|
|
|
|
/** 修改按钮操作 */
|
|
|
|
|
handleUpdate(row) {
|
|
|
|
|
console.log(row)
|
|
|
|
|
this.reset();
|
|
|
|
|
const picId = row.id || this.ids
|
|
|
|
|
getReport(picId).then(response => {
|
|
|
|
|
this.form = response.data.MesUnitpriceReport;
|
|
|
|
|
const id = row.id || this.ids
|
|
|
|
|
console.log(id)
|
|
|
|
|
getReport(id).then(response => {
|
|
|
|
|
this.form = response.data;
|
|
|
|
|
this.open = true;
|
|
|
|
|
this.MesUnitPriceInfo=response.data.MesUnitPriceInfo;
|
|
|
|
|
this.title = "修改【产量/工时】";
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
handleChildprocessChange(value){
|
|
|
|
|
console.log(value)
|
|
|
|
|
// 当子工序选择发生变化时,更新子工序编码
|
|
|
|
@ -375,13 +510,6 @@ export default {
|
|
|
|
|
this.getList();
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
// else {
|
|
|
|
|
// addUnitPrice(this.form).then(response => {
|
|
|
|
|
// this.$modal.msgSuccess("新增成功");
|
|
|
|
|
// this.open = false;
|
|
|
|
|
// this.getList();
|
|
|
|
|
// });
|
|
|
|
|
// }
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|