This commit is contained in:
parent
7758d128dc
commit
b406c7ddca
|
|
@ -65,8 +65,8 @@
|
||||||
<el-form :model="exitForm" label-width="80px" size="small" inline @submit.native.prevent>
|
<el-form :model="exitForm" label-width="80px" size="small" inline @submit.native.prevent>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div>
|
<div>
|
||||||
<vue-easy-print tableShow ref="remarksPrintRefPass" style="padding: 0 20px; font-size: 18px">
|
<vue-easy-print tableShow ref="remarksPrintRefPass">
|
||||||
<div id="passId" style="padding: 0 20px; font-size: 18px">
|
<div id="passId" style="margin: 20px;padding: 40px 60px; font-size: 18px;border: 2px solid #000; position: relative">
|
||||||
<div style="text-align: center; font-weight: 600; font-size: 36px; margin-bottom: 40px">
|
<div style="text-align: center; font-weight: 600; font-size: 36px; margin-bottom: 40px">
|
||||||
出 门 证
|
出 门 证
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -83,15 +83,15 @@
|
||||||
出门,请予放行。
|
出门,请予放行。
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin: 40px 100px 15px; text-align: end">(公章)</div>
|
<div style="margin: 40px 75px 15px; text-align: end">(公章)</div>
|
||||||
<div style="text-align: end;margin-right: 90px;">{{ exitForm.addDate }}</div>
|
<div style="text-align: end;margin-right: 50px;">{{ formatDate(exitForm.addDate) }}</div>
|
||||||
<div>此证盖章有效</div>
|
<div>此证盖章有效</div>
|
||||||
<div v-if="exitPermitDialogVisible" style="position: absolute; top: 160px; left: 500px">
|
<div v-if="exitPermitDialogVisible" style="position: absolute; top: 126px; left: 460px">
|
||||||
<canvas id="canvas" width="200" height="200"></canvas>
|
<canvas id="canvas" width="200" height="200"></canvas>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="showImg" style="position: absolute; top: 160px; left: 500px">
|
<!-- <div v-if="showImg" style="position: absolute; top: 126px; left: 460px">
|
||||||
<img :src="canvasImgUrl" width="200" height="200" />
|
<img :src="canvasImgUrl" width="200" height="200" />
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
</vue-easy-print>
|
</vue-easy-print>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -236,10 +236,11 @@ export default {
|
||||||
this.getList()
|
this.getList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 新增
|
// 处理时间 2025-08-20 转为 2025年08月20日
|
||||||
handleAdd() {
|
formatDate(date) {
|
||||||
this.resetForm();
|
if (!date) return '';
|
||||||
this.open = true;
|
const options = { year: 'numeric', month: 'long', day: 'numeric' };
|
||||||
|
return new Date(date).toLocaleDateString('zh-CN', options);
|
||||||
},
|
},
|
||||||
|
|
||||||
// 重置表单
|
// 重置表单
|
||||||
|
|
@ -343,7 +344,7 @@ export default {
|
||||||
printable: 'passId',
|
printable: 'passId',
|
||||||
type: 'html',
|
type: 'html',
|
||||||
style: `
|
style: `
|
||||||
@page { size: A5; margin: 0; }
|
@page { size: A4; margin: 0; }
|
||||||
body { margin: 0.5cm; font-family: SimSun; }
|
body { margin: 0.5cm; font-family: SimSun; }
|
||||||
#passId { font-size: 18px; padding: 0 20px; }
|
#passId { font-size: 18px; padding: 0 20px; }
|
||||||
`,
|
`,
|
||||||
|
|
|
||||||
|
|
@ -283,7 +283,7 @@
|
||||||
v-if="approveSignList.length > 0"
|
v-if="approveSignList.length > 0"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
style="width: 80%; margin-left: 20px; height: 40px;transform: translateY(-30px)"
|
style="width: 80%; margin-left: 20px; height: 40px; transform: translateY(-30px)"
|
||||||
v-for="(item, index) in approveSignList"
|
v-for="(item, index) in approveSignList"
|
||||||
:key="index"
|
:key="index"
|
||||||
>
|
>
|
||||||
|
|
@ -299,7 +299,7 @@
|
||||||
<div class="item" style="width: 24%; display: flex; align-items: flex-start; flex-wrap: wrap">
|
<div class="item" style="width: 24%; display: flex; align-items: flex-start; flex-wrap: wrap">
|
||||||
<div style="width: 30%">领料:</div>
|
<div style="width: 30%">领料:</div>
|
||||||
<div
|
<div
|
||||||
style="width: 70%; display: flex; align-items: center; flex-wrap: wrap;transform: translateY(-30px)"
|
style="width: 70%; display: flex; align-items: center; flex-wrap: wrap; transform: translateY(-30px)"
|
||||||
v-if="outSignList.length > 0"
|
v-if="outSignList.length > 0"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
|
|
@ -319,7 +319,7 @@
|
||||||
<div class="item" style="width: 24%; display: flex; align-items: flex-start; flex-wrap: wrap">
|
<div class="item" style="width: 24%; display: flex; align-items: flex-start; flex-wrap: wrap">
|
||||||
<div style="width: 30%">材料员:</div>
|
<div style="width: 30%">材料员:</div>
|
||||||
<div
|
<div
|
||||||
style="width: 70%; display: flex; align-items: center; flex-wrap: wrap;transform: translateY(-30px)"
|
style="width: 70%; display: flex; align-items: center; flex-wrap: wrap; transform: translateY(-30px)"
|
||||||
v-if="confirmSign && confirmSign.confirmSignUrl"
|
v-if="confirmSign && confirmSign.confirmSignUrl"
|
||||||
>
|
>
|
||||||
<div style="width: 80%; margin-left: 25px">
|
<div style="width: 80%; margin-left: 25px">
|
||||||
|
|
@ -334,7 +334,10 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 28%; display: flex; align-items: flex-start">
|
<div class="item" style="width: 28%; display: flex; align-items: flex-start">
|
||||||
<div style="width: 25%">库管:</div>
|
<div style="width: 25%">库管:</div>
|
||||||
<div style="width: 75%; display: flex; align-items: center; flex-wrap: wrap;transform: translateY(-30px)" v-if="kgSignList.length > 0">
|
<div
|
||||||
|
style="width: 75%; display: flex; align-items: center; flex-wrap: wrap; transform: translateY(-30px)"
|
||||||
|
v-if="kgSignList.length > 0"
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
style="width: 80%; margin-left: 20px; height: 40px"
|
style="width: 80%; margin-left: 20px; height: 40px"
|
||||||
v-for="(item, index) in kgSignList"
|
v-for="(item, index) in kgSignList"
|
||||||
|
|
@ -351,7 +354,10 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 25%; display: flex; align-items: flex-start">
|
<div class="item" style="width: 25%; display: flex; align-items: flex-start">
|
||||||
<div style="width: 25%">制单:</div>
|
<div style="width: 25%">制单:</div>
|
||||||
<div style="width: 75%;margin-left: 20px;transform: translateY(-30px)" v-if="leaseApplyData.leaseSignUrl">
|
<div
|
||||||
|
style="width: 75%; margin-left: 20px; transform: translateY(-30px)"
|
||||||
|
v-if="leaseApplyData.leaseSignUrl"
|
||||||
|
>
|
||||||
<img
|
<img
|
||||||
:src="leaseApplyData.leaseSignUrl"
|
:src="leaseApplyData.leaseSignUrl"
|
||||||
style="width: 40px; height: 90px; max-width: 100%"
|
style="width: 40px; height: 90px; max-width: 100%"
|
||||||
|
|
@ -417,33 +423,36 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div>
|
<div>
|
||||||
<vue-easy-print tableShow ref="remarksPrintRefPass" style="padding: 0 20px; font-size: 18px">
|
<vue-easy-print tableShow ref="remarksPrintRefPass">
|
||||||
<div id="passId" style="padding: 0 20px; font-size: 18px">
|
<div
|
||||||
|
id="passId"
|
||||||
|
style="margin: 20px; padding: 40px 60px; font-size: 18px; border: 2px solid #000; position: relative"
|
||||||
|
>
|
||||||
<div style="text-align: center; font-weight: 600; font-size: 36px; margin-bottom: 40px">
|
<div style="text-align: center; font-weight: 600; font-size: 36px; margin-bottom: 40px">
|
||||||
出 门 证
|
出 门 证
|
||||||
</div>
|
</div>
|
||||||
<div style="text-align: end">{{ passCode }}</div>
|
<div style="text-align: end">{{ passCode }}</div>
|
||||||
<div style="line-height: 1.96">
|
<div style="line-height: 1.96; margin-right: 65px">
|
||||||
<div>门卫:</div>
|
<div>门卫:</div>
|
||||||
<div>
|
<div>
|
||||||
<span style="margin-left: 25px">现有</span>
|
<span style="margin-left: 25px">现有 </span>
|
||||||
<span style="min-width: 80px; border-bottom: 1px solid #000; padding: 0 5px">
|
<span style="min-width: 80px; border-bottom: 1px solid #000; padding: 0 5px">
|
||||||
{{ passForm.carNumber }}
|
{{ passForm.carNumber }}
|
||||||
</span>
|
</span>
|
||||||
携带
|
,携带
|
||||||
<span style="min-width: 80px; border-bottom: 1px solid #000; padding: 0 5px">{{ passContent }}</span>
|
<span style="min-width: 80px; border-bottom: 1px solid #000; padding: 0 5px">{{ passContent }}</span>
|
||||||
出门,请予放行。
|
出门,请予放行。
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin: 60px 0 15px; text-align: end">(公章)</div>
|
<div style="margin: 40px 75px 15px; text-align: end">(公章)</div>
|
||||||
<div style="text-align: end">{{ passTime }}</div>
|
<div style="text-align: end; margin-right: 50px">{{ passTime }}</div>
|
||||||
<div>此证盖章有效</div>
|
<div>此证盖章有效</div>
|
||||||
<div v-if="showPass" style="position: absolute; top: 120px; left: 590px">
|
<div v-if="showPass" style="position: absolute; top: 126px; left: 460px">
|
||||||
<canvas id="canvas" width="200" height="200"></canvas>
|
<canvas id="canvas" width="200" height="200"></canvas>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="showImg" style="position: absolute; top: 110px; left: 590px">
|
<!-- <div v-if="showImg" style="position: absolute; top: 126px; left: 490px">
|
||||||
<img :src="canvasImgUrl" width="200" height="200" />
|
<img :src="canvasImgUrl" width="200" height="200" />
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
</vue-easy-print>
|
</vue-easy-print>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -728,20 +737,33 @@ export default {
|
||||||
},
|
},
|
||||||
printPass() {
|
printPass() {
|
||||||
this.showImg = true
|
this.showImg = true
|
||||||
const canvas = document.getElementById('canvas')
|
|
||||||
this.canvasImgUrl = canvas.toDataURL('image/png') // base64 图像
|
// 确保canvas已完成渲染
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.remarksPrintRefPass.print()
|
const canvas = document.getElementById('canvas')
|
||||||
|
if (canvas) {
|
||||||
|
this.canvasImgUrl = canvas.toDataURL('image/png')
|
||||||
|
|
||||||
|
// 再次等待DOM更新
|
||||||
|
this.$nextTick(() => {
|
||||||
|
// 使用printJS作为备选方案
|
||||||
|
printJS({
|
||||||
|
printable: 'passId',
|
||||||
|
type: 'html',
|
||||||
|
style: `
|
||||||
|
@page { size: A4; margin: 0; }
|
||||||
|
body { margin: 0.5cm; font-family: SimSun; }
|
||||||
|
#passId { font-size: 18px; padding: 0 20px; }
|
||||||
|
`,
|
||||||
|
scanStyles: false
|
||||||
|
})
|
||||||
|
|
||||||
|
// 或者继续使用vue-easy-print
|
||||||
|
// this.$refs.remarksPrintRefPass.print();
|
||||||
this.showImg = false
|
this.showImg = false
|
||||||
})
|
})
|
||||||
// /passId
|
}
|
||||||
// printJS({
|
})
|
||||||
// printable: 'passId',
|
|
||||||
// type: 'html',
|
|
||||||
// targetStyles: ['*'],
|
|
||||||
// scanStyles: true
|
|
||||||
// })
|
|
||||||
|
|
||||||
},
|
},
|
||||||
handleDialogClose() {
|
handleDialogClose() {
|
||||||
this.showPass = false
|
this.showPass = false
|
||||||
|
|
|
||||||
|
|
@ -10,8 +10,7 @@
|
||||||
start-placeholder="开始日期"
|
start-placeholder="开始日期"
|
||||||
end-placeholder="结束日期"
|
end-placeholder="结束日期"
|
||||||
style="width: 240px"
|
style="width: 240px"
|
||||||
>
|
></el-date-picker>
|
||||||
</el-date-picker>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item prop="keyWord">
|
<el-form-item prop="keyWord">
|
||||||
|
|
@ -26,33 +25,14 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item prop="taskStatus">
|
<el-form-item prop="taskStatus">
|
||||||
<el-select
|
<el-select v-model="queryParams.taskStatus" placeholder="请选择状态" clearable filterable style="width: 240px">
|
||||||
v-model="queryParams.taskStatus"
|
<el-option v-for="item in statusList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
||||||
placeholder="请选择状态"
|
|
||||||
clearable
|
|
||||||
filterable
|
|
||||||
style="width: 240px"
|
|
||||||
>
|
|
||||||
<el-option
|
|
||||||
v-for="item in statusList"
|
|
||||||
:key="item.id"
|
|
||||||
:label="item.name"
|
|
||||||
:value="item.id"
|
|
||||||
></el-option>
|
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
type="primary"
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
icon="el-icon-search"
|
|
||||||
size="mini"
|
|
||||||
@click="handleQuery"
|
|
||||||
>搜索
|
|
||||||
</el-button>
|
|
||||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
|
|
||||||
>重置
|
|
||||||
</el-button>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
|
|
||||||
|
|
@ -78,30 +58,32 @@
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-col> -->
|
</el-col> -->
|
||||||
<el-col :span="1.5">
|
<el-col :span="1.5">
|
||||||
<el-button
|
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport">导出</el-button>
|
||||||
type="warning"
|
|
||||||
plain
|
|
||||||
icon="el-icon-download"
|
|
||||||
size="mini"
|
|
||||||
@click="handleExport"
|
|
||||||
>导出
|
|
||||||
</el-button>
|
|
||||||
</el-col>
|
</el-col>
|
||||||
<right-toolbar
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
:showSearch.sync="showSearch"
|
|
||||||
@queryTable="getList"
|
|
||||||
></right-toolbar>
|
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-table v-loading="loading" :data="tableList" row-key="id" @selection-change="handleSelectionChange" border>
|
<el-table v-loading="loading" :data="tableList" row-key="id" @selection-change="handleSelectionChange" border>
|
||||||
<!-- <el-table-column type="selection" width="55" align="center" :selectable="selectable"/> -->
|
<!-- <el-table-column type="selection" width="55" align="center" :selectable="selectable"/> -->
|
||||||
<el-table-column width="60" align="center" label="序号" type="index" :index="indexContinuation(queryParams.pageNum, queryParams.pageSize)"/>
|
<el-table-column
|
||||||
<el-table-column label="申请人" align="center" prop="creator" :show-overflow-tooltip="true"/>
|
width="60"
|
||||||
<el-table-column label="申请时间" align="center" prop="createTime" width="110px" :show-overflow-tooltip="true"></el-table-column>
|
align="center"
|
||||||
<el-table-column label="申请配件" align="center" prop="partName" :show-overflow-tooltip="true"/>
|
label="序号"
|
||||||
<el-table-column label="单号" align="center" prop="code" :show-overflow-tooltip="true"/>
|
type="index"
|
||||||
<el-table-column label="审核人" align="center" prop="auditor" width="110px" :show-overflow-tooltip="true"/>
|
:index="indexContinuation(queryParams.pageNum, queryParams.pageSize)"
|
||||||
<el-table-column label="审核时间" align="center" prop="auditTime" :show-overflow-tooltip="true"/>
|
/>
|
||||||
|
<el-table-column label="申请人" align="center" prop="creator" :show-overflow-tooltip="true" />
|
||||||
|
<el-table-column
|
||||||
|
label="申请时间"
|
||||||
|
align="center"
|
||||||
|
prop="createTime"
|
||||||
|
width="110px"
|
||||||
|
:show-overflow-tooltip="true"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column label="申请配件" align="center" prop="partName" :show-overflow-tooltip="true" />
|
||||||
|
<el-table-column label="单号" align="center" prop="code" :show-overflow-tooltip="true" />
|
||||||
|
<el-table-column label="审核人" align="center" prop="auditor" width="110px" :show-overflow-tooltip="true" />
|
||||||
|
<el-table-column label="审核时间" align="center" prop="auditTime" :show-overflow-tooltip="true" />
|
||||||
<el-table-column label="状态" align="center" prop="taskStatusName" :show-overflow-tooltip="true">
|
<el-table-column label="状态" align="center" prop="taskStatusName" :show-overflow-tooltip="true">
|
||||||
<!-- <template slot-scope="scope">
|
<!-- <template slot-scope="scope">
|
||||||
<dict-tag :options="dict.type.repair_task_status":value="scope.row.taskStatus"/>
|
<dict-tag :options="dict.type.repair_task_status":value="scope.row.taskStatus"/>
|
||||||
|
|
@ -110,18 +92,21 @@
|
||||||
<!-- <el-table-column label="备注" align="center" width="100" prop="remark" :show-overflow-tooltip="true"/> -->
|
<!-- <el-table-column label="备注" align="center" width="100" prop="remark" :show-overflow-tooltip="true"/> -->
|
||||||
<el-table-column label="操作" align="center" width="300">
|
<el-table-column label="操作" align="center" width="300">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button size="mini" style="margin-bottom: 10px" type="normal"
|
<el-button size="mini" style="margin-bottom: 10px" type="normal" @click="handleView(scope.row)">
|
||||||
@click="handleView(scope.row)"
|
查看
|
||||||
>查看
|
|
||||||
</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.taskStatus == '0'"
|
v-if="scope.row.taskStatus == '0'"
|
||||||
>审核
|
>
|
||||||
|
审核
|
||||||
|
</el-button>
|
||||||
|
<el-button size="mini" type="warning" v-if="scope.row.taskStatus == '1'" @click="handleLld(scope.row)">
|
||||||
|
领料单
|
||||||
</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>
|
||||||
|
|
@ -135,34 +120,32 @@
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<!-- 领料单弹窗 -->
|
<!-- 领料单弹窗 -->
|
||||||
<el-dialog :visible.sync="open" width="800px" :title="title" append-to-body>
|
<el-dialog :visible.sync="open" width="1000px" :title="title" append-to-body>
|
||||||
<div style="height: 500px; overflow-y: scroll; padding: 0 20px">
|
<div style="height: 500px; overflow-y: scroll; padding: 0 20px">
|
||||||
<!-- <vue-easy-print tableShow ref="remarksPrintRef" class="print"> -->
|
<!-- <vue-easy-print tableShow ref="remarksPrintRef" class="print"> -->
|
||||||
<div id="checkId">
|
<div id="checkId">
|
||||||
<div class="title" style="text-align: center; font-weight: 600; font-size: 16px">
|
<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>
|
<div class="item" style="width: 50%; flex-shrink: 0; margin-bottom: 5px; font-size: 14px">
|
||||||
<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>
|
<span>领料:</span>
|
||||||
{{ leaseApplyData.deptName }}
|
{{ leaseApplyData.deptName }}
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
|
<div class="item" style="width: 50%; flex-shrink: 0; margin-bottom: 5px; font-size: 14px">
|
||||||
<span>发料单位:</span>
|
<span>发料单位:</span>
|
||||||
{{ leaseApplyData.sendDeptName }}
|
{{ leaseApplyData.sendDeptName }}
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
|
<div class="item" style="width: 50%; flex-shrink: 0; margin-bottom: 5px; font-size: 14px">
|
||||||
<span>时间:</span>
|
<span>时间:</span>
|
||||||
<span v-if="leaseApplyData.createTime">{{ leaseApplyData.createTime.split(" ")[0] }}</span>
|
<span v-if="leaseApplyData.createTime">{{ leaseApplyData.createTime.split(' ')[0] }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
|
<div class="item" style="width: 50%; flex-shrink: 0; margin-bottom: 5px; font-size: 14px">
|
||||||
<span>编号:</span>
|
<span>编号:</span>
|
||||||
{{ leaseApplyData.code }}
|
{{ leaseApplyData.code }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="width: 100%;margin-top: 20px;">
|
<div style="width: 100%; margin-top: 20px">
|
||||||
<el-table :data="leaseApplyDetails" class="table" border >
|
<!-- <el-table :data="leaseApplyDetails" class="table" border>
|
||||||
<el-table-column label="序号" align="center" type="index" width="60px"/>
|
<el-table-column label="序号" align="center" type="index" width="60px" />
|
||||||
<el-table-column label="配件类型" align="center" prop="partType" />
|
<el-table-column label="配件类型" align="center" prop="partType" />
|
||||||
<el-table-column label="配件名称" align="center" prop="partName" />
|
<el-table-column label="配件名称" align="center" prop="partName" />
|
||||||
<el-table-column label="规格型号" align="center" prop="partModel" />
|
<el-table-column label="规格型号" align="center" prop="partModel" />
|
||||||
|
|
@ -170,40 +153,120 @@
|
||||||
<el-table-column label="审核状态" align="center" prop="status">
|
<el-table-column label="审核状态" align="center" prop="status">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<div v-if="scope.row.status == '0'" style="color: #e6a23c">
|
<div v-if="scope.row.status == '0'" style="color: #e6a23c">
|
||||||
{{ "未审核" }}
|
{{ '未审核' }}
|
||||||
</div>
|
</div>
|
||||||
<div v-if="scope.row.status == '1'" style="color: #67c23a">
|
<div v-if="scope.row.status == '1'" style="color: #67c23a">
|
||||||
{{ "已审核" }}
|
{{ '已审核' }}
|
||||||
</div>
|
</div>
|
||||||
<div v-if="scope.row.status == '2'" style="color: #f56c6c">
|
<div v-if="scope.row.status == '2'" style="color: #f56c6c">
|
||||||
{{ "驳回" }}
|
{{ '驳回' }}
|
||||||
</div>
|
</div>
|
||||||
<!-- <div v-else style="color: red;"></div> -->
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="备注" align="center" prop="remark" />
|
<el-table-column label="备注" align="center" prop="remark" />
|
||||||
</el-table>
|
</el-table> -->
|
||||||
|
<table border="1.5" class="table" style="border-collapse: collapse; width: 100%">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th style="width: 60px; text-align: center">序号</th>
|
||||||
|
<th style="text-align: center">配件类型</th>
|
||||||
|
<th style="text-align: center">配件名称</th>
|
||||||
|
<th style="text-align: center">规格型号</th>
|
||||||
|
<th style="text-align: center">预领数量</th>
|
||||||
|
<th style="text-align: center">审核状态</th>
|
||||||
|
<th style="text-align: center">备注</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr v-for="(row, index) in leaseApplyDetails" :key="index">
|
||||||
|
<td style="text-align: center">{{ index + 1 }}</td>
|
||||||
|
<td style="text-align: center">{{ row.partType }}</td>
|
||||||
|
<td style="text-align: center">{{ row.partName }}</td>
|
||||||
|
<td style="text-align: center">{{ row.partModel }}</td>
|
||||||
|
<td style="text-align: center">{{ row.preNum }}</td>
|
||||||
|
<td style="text-align: center">
|
||||||
|
<span v-if="row.status == '0'" style="color: #e6a23c">未审核</span>
|
||||||
|
<span v-else-if="row.status == '1'" style="color: #67c23a">已审核</span>
|
||||||
|
<span v-else-if="row.status == '2'" style="color: #f56c6c">驳回</span>
|
||||||
|
</td>
|
||||||
|
<td style="text-align: center">{{ row.remark }}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
</div>
|
</div>
|
||||||
<div class="fillIn" style="margin-top: 30px;display: flex;justify-content: space-between;">
|
<div class="fillIn" style="margin-top: 50px; display: flex; justify-content: space-between">
|
||||||
<div class="item" style="width: 24%;display: flex;align-items: center;flex-wrap: wrap;">
|
<div class="item" style="width: 23%; display: flex; align-items: flex-start; flex-wrap: wrap">
|
||||||
<div style="width: 30%;">审核:</div>
|
<div style="width: 30%">审核:</div>
|
||||||
<div style="width: 70%;display: flex;align-items: center;flex-wrap: wrap;">
|
<div
|
||||||
<!-- <div style="width: 80%;margin-left: 20px;">
|
style="width: 70%; display: flex; align-items: center; flex-wrap: wrap"
|
||||||
<img :src="leaseApplyData.directAuditSignUrl" style="width: 40px;height: 100px;transform: rotate(-90deg);max-width: 100%;" alt="">
|
v-if="approveSignList.length > 0"
|
||||||
</div> -->
|
>
|
||||||
|
<div
|
||||||
|
style="width: 80%; margin-left: 20px; height: 40px; transform: translateY(-30px)"
|
||||||
|
v-for="(item, index) in approveSignList"
|
||||||
|
:key="index"
|
||||||
|
>
|
||||||
|
<img
|
||||||
|
:src="item.outSignUrl"
|
||||||
|
style="width: 40px; height: 90px; max-width: 100%"
|
||||||
|
:style="{ transform: item.outSignType == 0 ? 'rotate(-90deg)' : '' }"
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- <img :src="leaseApplyData.directAuditSignUrl" style="width: 40px;height: 100px;transform: rotate(-90deg);max-width: 100%;" alt=""> -->
|
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 24%;display: flex;align-items: center;flex-wrap: wrap;">
|
|
||||||
<span>领料:</span>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 24%;display: flex;align-items: center;flex-wrap: wrap;">
|
<div class="item" style="width: 24%; display: flex; align-items: flex-start; flex-wrap: wrap">
|
||||||
<span>制单:</span>
|
<div style="width: 30%">领料:</div>
|
||||||
|
<div
|
||||||
|
style="width: 70%; display: flex; align-items: center; flex-wrap: wrap; transform: translateY(-30px)"
|
||||||
|
v-if="outSignList.length > 0"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style="width: 80%; margin-left: 20px; height: 40px"
|
||||||
|
v-for="(item, index) in outSignList"
|
||||||
|
:key="index"
|
||||||
|
>
|
||||||
|
<img
|
||||||
|
:src="item.outSignUrl"
|
||||||
|
style="width: 40px; height: 90px; max-width: 100%"
|
||||||
|
:style="{ transform: item.outSignType == 0 ? 'rotate(-90deg)' : '' }"
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="item" style="width: 28%;display: flex;align-items: center;">
|
</div>
|
||||||
<div style="width: 25%;">库管:</div>
|
</div>
|
||||||
<div style="width: 75%;display: flex;align-items: center;flex-wrap: wrap;">
|
<div class="item" style="width: 28%; display: flex; align-items: flex-start">
|
||||||
<!-- <img src="../../../../../assets/signTemp.png" style="width: 45%;height: 30px;" alt=""> -->
|
<div style="width: 25%">库管:</div>
|
||||||
|
<div
|
||||||
|
style="width: 75%; display: flex; align-items: center; flex-wrap: wrap; transform: translateY(-30px)"
|
||||||
|
v-if="kgSignList.length > 0"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style="width: 80%; margin-left: 20px; height: 40px"
|
||||||
|
v-for="(item, index) in kgSignList"
|
||||||
|
:key="index"
|
||||||
|
>
|
||||||
|
<img
|
||||||
|
:src="item.outSignUrl"
|
||||||
|
style="width: 40px; height: 90px"
|
||||||
|
:style="{ transform: item.outSignType == 0 ? 'rotate(-90deg)' : '' }"
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="item" style="width: 25%; display: flex; align-items: flex-start">
|
||||||
|
<div style="width: 25%">制单:</div>
|
||||||
|
<div
|
||||||
|
style="width: 75%; margin-left: 20px; transform: translateY(-30px)"
|
||||||
|
v-if="leaseApplyData.leaseSignUrl"
|
||||||
|
>
|
||||||
|
<img
|
||||||
|
:src="leaseApplyData.leaseSignUrl"
|
||||||
|
style="width: 40px; height: 90px; max-width: 100%"
|
||||||
|
:style="{ transform: leaseApplyData.leaseSignType == 0 ? 'rotate(-90deg)' : '' }"
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -215,25 +278,16 @@
|
||||||
<el-button @click="open = false">关 闭</el-button>
|
<el-button @click="open = false">关 闭</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {
|
import { getPartLeaseInfoListApi, getPartLeaseByTaskIdApi } from '@/api/part/partLease'
|
||||||
getPartLeaseInfoListApi,getPartLeaseByTaskIdApi
|
import router from '@/router'
|
||||||
} from "@/api/part/partLease";
|
import vueEasyPrint from 'vue-easy-print'
|
||||||
import router from "@/router";
|
import printJS from 'print-js'
|
||||||
import vueEasyPrint from "vue-easy-print";
|
|
||||||
import printJS from 'print-js';
|
|
||||||
export default {
|
export default {
|
||||||
name: "Home",
|
name: 'Home',
|
||||||
dicts: [],
|
dicts: [],
|
||||||
components: { vueEasyPrint },
|
components: { vueEasyPrint },
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -251,7 +305,11 @@ export default {
|
||||||
// 总条数
|
// 总条数
|
||||||
total: 0,
|
total: 0,
|
||||||
//搜索下拉数据
|
//搜索下拉数据
|
||||||
statusList: [{id:"0",name:"待审核"},{id:"1",name:"已审核"},{id:"2",name:"已驳回"}],
|
statusList: [
|
||||||
|
{ id: '0', name: '待审核' },
|
||||||
|
{ id: '1', name: '已审核' },
|
||||||
|
{ id: '2', name: '已驳回' }
|
||||||
|
],
|
||||||
// 字典表格数据
|
// 字典表格数据
|
||||||
tableList: [],
|
tableList: [],
|
||||||
// 日期范围
|
// 日期范围
|
||||||
|
|
@ -262,32 +320,36 @@ export default {
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
time: null, //申请时间
|
time: null, //申请时间
|
||||||
taskStatus: "",
|
taskStatus: '',
|
||||||
keyWord: "",
|
keyWord: ''
|
||||||
},
|
},
|
||||||
form: {},
|
form: {},
|
||||||
passTemp: [],
|
passTemp: [],
|
||||||
failTemp: [],
|
failTemp: [],
|
||||||
//领料单
|
//领料单
|
||||||
open:false,
|
open: false,
|
||||||
title:"",
|
title: '',
|
||||||
leaseApplyDetails: [],
|
leaseApplyDetails: [],
|
||||||
leaseApplyData: {},
|
leaseApplyData: {}, // 领料单信息
|
||||||
};
|
approveSignList: [], // 审批签字列表
|
||||||
|
outSignList: [], // 领料签字列表
|
||||||
|
kgSignList: [] // 库管签字列表
|
||||||
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
//打开领料单
|
//打开领料单
|
||||||
async handleLld(row) {
|
async handleLld(row) {
|
||||||
this.title = "领料单";
|
this.title = '领料单'
|
||||||
this.open = true;
|
this.open = true
|
||||||
const res = await getPartLeaseByTaskIdApi({ taskId: row.taskId });
|
const res = await getPartLeaseByTaskIdApi({ taskId: row.taskId })
|
||||||
this.leaseApplyDetails = res.data.detailsList;
|
console.log('🚀 ~ handleLld ~ res:', res)
|
||||||
this.leaseApplyData = res.data.details;
|
this.leaseApplyDetails = res.data.detailsList
|
||||||
this.leaseApplyData.createTime=row.createTime
|
this.leaseApplyData = res.data.details
|
||||||
this.leaseApplyData.code=row.code
|
this.leaseApplyData.createTime = row.createTime
|
||||||
|
this.leaseApplyData.code = row.code
|
||||||
},
|
},
|
||||||
//打印
|
//打印
|
||||||
print() {
|
print() {
|
||||||
|
|
@ -296,68 +358,68 @@ export default {
|
||||||
printable: 'checkId',
|
printable: 'checkId',
|
||||||
type: 'html',
|
type: 'html',
|
||||||
targetStyles: ['*'],
|
targetStyles: ['*'],
|
||||||
maxWidth:'1400'
|
maxWidth: '1400'
|
||||||
// 其他配置选项
|
// 其他配置选项
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 多选框选中数据
|
// 多选框选中数据
|
||||||
handleSelectionChange(selection) {
|
handleSelectionChange(selection) {
|
||||||
this.passTemp = [];
|
this.passTemp = []
|
||||||
this.failTemp = [];
|
this.failTemp = []
|
||||||
this.ids = selection.map((item) => item.taskId);
|
this.ids = selection.map(item => item.taskId)
|
||||||
selection.forEach((item) => {
|
selection.forEach(item => {
|
||||||
this.passTemp.push({ status: "1",taskId:item.taskId, });
|
this.passTemp.push({ status: '1', taskId: item.taskId })
|
||||||
});
|
})
|
||||||
selection.forEach((item) => {
|
selection.forEach(item => {
|
||||||
this.failTemp.push({ status: "2",taskId:item.taskId, });
|
this.failTemp.push({ status: '2', taskId: item.taskId })
|
||||||
});
|
})
|
||||||
this.single = selection.length != 1;
|
this.single = selection.length != 1
|
||||||
this.multiple = !selection.length;
|
this.multiple = !selection.length
|
||||||
},
|
},
|
||||||
|
|
||||||
//是否可用勾选框
|
//是否可用勾选框
|
||||||
selectable(row) {
|
selectable(row) {
|
||||||
if (row.taskStatus == "10" || row.taskStatus == "6") {
|
if (row.taskStatus == '10' || row.taskStatus == '6') {
|
||||||
return true;
|
return true
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true
|
||||||
const params = {
|
const params = {
|
||||||
keyWord: this.queryParams.keyWord,
|
keyWord: this.queryParams.keyWord,
|
||||||
startTime: this.queryParams.time && this.queryParams.time[0],
|
startTime: this.queryParams.time && this.queryParams.time[0],
|
||||||
endTime: this.queryParams.time && this.queryParams.time[1],
|
endTime: this.queryParams.time && this.queryParams.time[1],
|
||||||
pageSize: this.queryParams.pageSize,
|
pageSize: this.queryParams.pageSize,
|
||||||
pageNum: this.queryParams.pageNum,
|
pageNum: this.queryParams.pageNum,
|
||||||
taskStatus: this.queryParams.taskStatus,
|
taskStatus: this.queryParams.taskStatus
|
||||||
};
|
}
|
||||||
getPartLeaseInfoListApi(params).then((response) => {
|
getPartLeaseInfoListApi(params).then(response => {
|
||||||
this.tableList = response.data.rows;
|
this.tableList = response.data.rows
|
||||||
this.total = response.data.total;
|
this.total = response.data.total
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
/** 搜索按钮操作 */
|
/** 搜索按钮操作 */
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
this.queryParams.pageNum = 1;
|
this.queryParams.pageNum = 1
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
/** 重置按钮操作 */
|
/** 重置按钮操作 */
|
||||||
resetQuery() {
|
resetQuery() {
|
||||||
this.queryParams.time = [];
|
this.queryParams.time = []
|
||||||
this.resetForm("queryForm");
|
this.resetForm('queryForm')
|
||||||
this.queryParams.keyWord = "";
|
this.queryParams.keyWord = ''
|
||||||
this.handleQuery();
|
this.handleQuery()
|
||||||
},
|
},
|
||||||
/** 通过按钮操作 */
|
/** 通过按钮操作 */
|
||||||
handlePassAll() {
|
handlePassAll() {
|
||||||
if (this.ids.length == 0) {
|
if (this.ids.length == 0) {
|
||||||
this.$alert("请至少勾选一条审核数据", "提示", {
|
this.$alert('请至少勾选一条审核数据', '提示', {
|
||||||
type: "warning",
|
type: 'warning',
|
||||||
confirmButtonText: "确定",
|
confirmButtonText: '确定'
|
||||||
});
|
})
|
||||||
} else {
|
} else {
|
||||||
// outerAudit(this.passTemp).then((response) => {
|
// outerAudit(this.passTemp).then((response) => {
|
||||||
// if (response.code == 200) {
|
// if (response.code == 200) {
|
||||||
|
|
@ -371,10 +433,10 @@ export default {
|
||||||
/** 驳回按钮操作 */
|
/** 驳回按钮操作 */
|
||||||
handleFailAll() {
|
handleFailAll() {
|
||||||
if (this.ids.length == 0) {
|
if (this.ids.length == 0) {
|
||||||
this.$alert("请至少勾选一条审核数据", "提示", {
|
this.$alert('请至少勾选一条审核数据', '提示', {
|
||||||
type: "warning",
|
type: 'warning',
|
||||||
confirmButtonText: "确定",
|
confirmButtonText: '确定'
|
||||||
});
|
})
|
||||||
} else {
|
} else {
|
||||||
// outerAudit(this.failTemp).then((response) => {
|
// outerAudit(this.failTemp).then((response) => {
|
||||||
// if (response.code == 200) {
|
// if (response.code == 200) {
|
||||||
|
|
@ -388,49 +450,49 @@ export default {
|
||||||
|
|
||||||
/** 查看按钮操作 */
|
/** 查看按钮操作 */
|
||||||
handleView(row) {
|
handleView(row) {
|
||||||
this.$emit("queryTools", row.taskId, row.id, row);
|
this.$emit('queryTools', row.taskId, row.id, row)
|
||||||
},
|
},
|
||||||
/** 修改按钮操作 */
|
/** 修改按钮操作 */
|
||||||
handleUpdate(row) {
|
handleUpdate(row) {
|
||||||
this.$emit("addTools", row.taskId, row.id,row);
|
this.$emit('addTools', row.taskId, row.id, row)
|
||||||
},
|
},
|
||||||
|
|
||||||
/** 导出按钮操作 */
|
/** 导出按钮操作 */
|
||||||
handleExport() {
|
handleExport() {
|
||||||
const formatTime = (date) => {
|
const formatTime = date => {
|
||||||
const year = date.getFullYear();
|
const year = date.getFullYear()
|
||||||
const month = String(date.getMonth() + 1).padStart(2, '0');
|
const month = String(date.getMonth() + 1).padStart(2, '0')
|
||||||
const day = String(date.getDate()).padStart(2, '0');
|
const day = String(date.getDate()).padStart(2, '0')
|
||||||
const hours = String(date.getHours()).padStart(2, '0');
|
const hours = String(date.getHours()).padStart(2, '0')
|
||||||
const minutes = String(date.getMinutes()).padStart(2, '0');
|
const minutes = String(date.getMinutes()).padStart(2, '0')
|
||||||
const seconds = String(date.getSeconds()).padStart(2, '0');
|
const seconds = String(date.getSeconds()).padStart(2, '0')
|
||||||
return `${year}${month}${day}_${hours}${minutes}${seconds}`;
|
return `${year}${month}${day}_${hours}${minutes}${seconds}`
|
||||||
};
|
}
|
||||||
|
|
||||||
const currentTime = formatTime(new Date());
|
const currentTime = formatTime(new Date())
|
||||||
this.download(
|
this.download(
|
||||||
"/material/part_lease/export",
|
'/material/part_lease/export',
|
||||||
{
|
{
|
||||||
...this.queryParams,
|
...this.queryParams,
|
||||||
startTime: this.queryParams.time && this.queryParams.time[0],
|
startTime: this.queryParams.time && this.queryParams.time[0],
|
||||||
endTime: this.queryParams.time && this.queryParams.time[1],
|
endTime: this.queryParams.time && this.queryParams.time[1]
|
||||||
},
|
},
|
||||||
`配件领用_${currentTime}.xlsx`
|
`配件领用_${currentTime}.xlsx`
|
||||||
);
|
)
|
||||||
},
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
$route: {
|
$route: {
|
||||||
handler(to) {
|
handler(to) {
|
||||||
if (to.query.keyWord) {
|
if (to.query.keyWord) {
|
||||||
this.queryParams.keyWord = to.query.keyWord;
|
this.queryParams.keyWord = to.query.keyWord
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
deep: true,
|
deep: true,
|
||||||
immediate: true,
|
immediate: true
|
||||||
},
|
}
|
||||||
},
|
}
|
||||||
};
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
::v-deep.el-table .fixed-width .el-button--mini {
|
::v-deep.el-table .fixed-width .el-button--mini {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue