配件领料修改

This commit is contained in:
zzyuan 2025-01-22 09:59:42 +08:00
parent 5633a14764
commit a962b345fb
3 changed files with 117 additions and 8 deletions

View File

@ -214,7 +214,7 @@ export default {
this.loading = true; this.loading = true;
getPartLeaseByTaskIdApi({ taskId: this.taskId }).then((response) => { getPartLeaseByTaskIdApi({ taskId: this.taskId }).then((response) => {
this.maForm = this.paramTemp; this.maForm = this.paramTemp;
this.equipmentList = response.data; this.equipmentList = response.data.detailsList;
this.loading = false; this.loading = false;
}); });
}, },

View File

@ -116,9 +116,12 @@
</el-button> </el-button>
<el-button size="mini" style="margin-bottom: 10px" type="primary" <el-button size="mini" style="margin-bottom: 10px" type="primary"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-if="scope.row.status != '2'" v-if="scope.row.taskStatus == '0'"
>审核 >审核
</el-button> </el-button>
<el-button size="mini" type="warning"
v-if="scope.row.taskStatus == '1'" @click="handleLld(scope.row)"
>领料单</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -130,20 +133,107 @@
:limit.sync="queryParams.pageSize" :limit.sync="queryParams.pageSize"
@pagination="getList" @pagination="getList"
/> />
<!-- 领料单弹窗 -->
<el-dialog :visible.sync="open" width="800px" :title="title" append-to-body>
<div style="height: 500px; overflow-y: scroll; padding: 0 20px">
<vue-easy-print tableShow ref="remarksPrintRef" class="print">
<div class="title" style="text-align: center; font-weight: 600; font-size: 16px">
领料单
</div>
<div class="info" style="margin-top: 10px; display: flex; flex-wrap: wrap" >
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
<span>单位部门</span>
{{ leaseApplyData.deptName }}
</div>
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
<span>发料单位</span>
{{ leaseApplyData.sendDeptName }}
</div>
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
<span>时间</span>
<span v-if="leaseApplyData.createTime">{{ leaseApplyData.createTime.split(" ")[0] }}</span>
</div>
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
<span>编号</span>
{{ leaseApplyData.code }}
</div>
</div>
<div style="width: 100%;margin-top: 20px;">
<el-table :data="leaseApplyDetails" class="table" border style="padding: 2px;">
<el-table-column label="序号" align="center" type="index" />
<el-table-column label="配件类型" align="center" prop="partType" />
<el-table-column label="配件名称" align="center" prop="partName" />
<el-table-column label="规格型号" align="center" prop="partModel" />
<el-table-column label="预领数量" align="center" prop="preNum" />
<el-table-column label="审核状态" align="center" prop="status">
<template slot-scope="scope">
<div v-if="scope.row.status == '0'" style="color: #e6a23c">
{{ "未审核" }}
</div>
<div v-if="scope.row.status == '1'" style="color: #67c23a">
{{ "已审核" }}
</div>
<div v-if="scope.row.status == '2'" style="color: #f56c6c">
{{ "驳回" }}
</div>
<!-- <div v-else style="color: red;"></div> -->
</template>
</el-table-column>
<el-table-column label="备注" align="center" prop="remark" />
</el-table>
</div>
<div class="fillIn" style="margin-top: 30px;display: flex;justify-content: space-between;">
<div class="item" style="width: 24%;display: flex;align-items: center;flex-wrap: wrap;">
<div style="width: 30%;">审核</div>
<div style="width: 70%;display: flex;align-items: center;flex-wrap: wrap;">
<!-- <div style="width: 80%;margin-left: 20px;">
<img :src="leaseApplyData.directAuditSignUrl" style="width: 40px;height: 100px;transform: rotate(-90deg);max-width: 100%;" alt="">
</div> -->
</div>
<!-- <img :src="leaseApplyData.directAuditSignUrl" style="width: 40px;height: 100px;transform: rotate(-90deg);max-width: 100%;" alt=""> -->
</div>
<div class="item" style="width: 24%;display: flex;align-items: center;flex-wrap: wrap;">
<span>领料</span>
</div>
<div class="item" style="width: 24%;display: flex;align-items: center;flex-wrap: wrap;">
<span>制单</span>
</div>
<div class="item" style="width: 28%;display: flex;align-items: center;">
<div style="width: 25%;">库管</div>
<div style="width: 75%;display: flex;align-items: center;flex-wrap: wrap;">
<!-- <img src="../../../../../assets/signTemp.png" style="width: 45%;height: 30px;" alt=""> -->
</div>
</div>
</div>
</vue-easy-print>
</div>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button type="primary" @click="print"> </el-button>
<el-button @click="open = false"> </el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
import { import {
getPartLeaseInfoListApi, getPartLeaseInfoListApi,getPartLeaseByTaskIdApi
} from "@/api/part/partLease"; } from "@/api/part/partLease";
// import {
// outerAudit,
// } from "@/api/repair/repair";
import router from "@/router"; import router from "@/router";
import vueEasyPrint from "vue-easy-print";
import printJS from 'print-js';
export default { export default {
name: "Home", name: "Home",
dicts: [], dicts: [],
components: { vueEasyPrint },
data() { data() {
return { return {
// //
@ -176,12 +266,31 @@ export default {
form: {}, form: {},
passTemp: [], passTemp: [],
failTemp: [], failTemp: [],
//
open:false,
title:"",
leaseApplyDetails: [],
leaseApplyData: {},
}; };
}, },
created() { created() {
this.getList(); this.getList();
}, },
methods: { methods: {
//
async handleLld(row) {
this.title = "领料单";
this.open = true;
const res = await getPartLeaseByTaskIdApi({ taskId: row.taskId });
this.leaseApplyDetails = res.data.detailsList;
this.leaseApplyData = res.data.details;
this.leaseApplyData.createTime=row.createTime
this.leaseApplyData.code=row.code
},
//
print() {
this.$refs.remarksPrintRef.print();
},
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.passTemp = []; this.passTemp = [];

View File

@ -214,7 +214,7 @@ export default {
this.loading = true; this.loading = true;
getPartLeaseByTaskIdApi({ taskId: this.taskId }).then((response) => { getPartLeaseByTaskIdApi({ taskId: this.taskId }).then((response) => {
this.maForm = this.paramTemp; this.maForm = this.paramTemp;
this.equipmentList = response.data; this.equipmentList = response.data.detailsList;
this.loading = false; this.loading = false;
}); });
}, },