前端流程逻辑优化

This commit is contained in:
zzyuan 2025-01-09 15:07:22 +08:00
parent 1ac9bd125f
commit e29f79e1b3
12 changed files with 90 additions and 152 deletions

View File

@ -131,10 +131,10 @@
@click="handleSee(scope.row)" @click="handleSee(scope.row)"
>查看</el-button> >查看</el-button>
<el-button size="mini" type="primary" plain icon="el-icon-edit" <el-button size="mini" type="primary" plain icon="el-icon-edit"
v-if="scope.row.taskStatus!=2" @click="handleUpdate(scope.row)" v-if="scope.row.taskStatus!=2&&scope.row.taskStatus!=1" @click="handleUpdate(scope.row)"
>编辑</el-button> >编辑</el-button>
<el-button size="mini" type="success" plain icon="el-icon-refresh" <el-button size="mini" type="success" plain icon="el-icon-refresh"
v-if="scope.row.taskStatus!=2" @click="handleSubmit(scope.row)" v-if="scope.row.taskStatus!=2&&scope.row.taskStatus!=1" @click="handleSubmit(scope.row)"
>提交</el-button> >提交</el-button>
<el-button size="mini" type="danger" icon="el-icon-delete" <el-button size="mini" type="danger" icon="el-icon-delete"
v-if="scope.row.taskStatus!=2&&scope.row.taskStatus!=1" v-if="scope.row.taskStatus!=2&&scope.row.taskStatus!=1"

View File

@ -319,7 +319,7 @@ import printJS from 'print-js';
export default { export default {
name: "Home", name: "Home",
dicts: ["lease_task_status", "ma_type_manage_type"], dicts: ["lease_task_status", "ma_type_manage_type"],
// components: { vueEasyPrint }, components: { vueEasyPrint },
data() { data() {
return { return {
// //
@ -396,7 +396,6 @@ export default {
this.getList(); this.getList();
// this.getTypeList() // this.getTypeList()
}, },
components: { vueEasyPrint },
methods: { methods: {
// getTypeList() { // getTypeList() {
// getTypeList({ level: '3' }).then((response) => { // getTypeList({ level: '3' }).then((response) => {

View File

@ -448,7 +448,6 @@ export default {
this.queryParams.id = this.Id; this.queryParams.id = this.Id;
this.queryParams.taskId = this.taskId; this.queryParams.taskId = this.taskId;
this.queryParams.taskStage = 2; this.queryParams.taskStage = 2;
this.queryParams.statusList = [2, 12];
getPurchaseDetailsList(this.queryParams).then((response) => { getPurchaseDetailsList(this.queryParams).then((response) => {
this.tableList = response.data.purchaseCheckDetailsList; this.tableList = response.data.purchaseCheckDetailsList;
this.tableList.forEach((item) => { this.tableList.forEach((item) => {

View File

@ -43,7 +43,7 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
type="success" plain type="success" plain
size="mini" size="mini"
@ -52,7 +52,7 @@
> >
验收合格 验收合格
</el-button> </el-button>
</el-col> </el-col> -->
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -72,17 +72,17 @@
<span>{{ (queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1 }}</span> <span>{{ (queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1 }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="到货时间" align="center" prop="arrivalTime" width="150" :show-overflow-tooltip="true"/> <el-table-column label="到货时间" align="center" prop="arrivalTime" width="180" :show-overflow-tooltip="true"/>
<el-table-column label="采购单号" align="center" prop="code" width="150" :show-overflow-tooltip="true"/> <el-table-column label="采购单号" align="center" prop="code" width="150" :show-overflow-tooltip="true"/>
<el-table-column label="采购物资" align="center" prop="purchaseMaTypeName" :show-overflow-tooltip="true"/> <el-table-column label="采购物资" align="center" prop="purchaseMaTypeName" :show-overflow-tooltip="true"/>
<el-table-column label="采购数量" align="center" prop="purchaseMaNumber" :show-overflow-tooltip="true"/> <el-table-column label="采购数量" align="center" prop="purchaseMaNumber" width="100" :show-overflow-tooltip="true"/>
<el-table-column label="采购价格(元含税)" align="center" prop="purchaseTaxPrice" width="80" :show-overflow-tooltip="true"/> <el-table-column label="采购价格(元含税)" align="center" prop="purchaseTaxPrice" width="100" :show-overflow-tooltip="true"/>
<el-table-column label="采购价格(元不含税)" align="center" prop="purchasePrice" width="80" :show-overflow-tooltip="true"/> <el-table-column label="采购价格(元不含税)" align="center" prop="purchasePrice" width="100" :show-overflow-tooltip="true"/>
<el-table-column label="税率" align="center" prop="taxRate" :show-overflow-tooltip="true"/> <el-table-column label="税率" align="center" prop="taxRate" :show-overflow-tooltip="true"/>
<el-table-column label="物资厂家" align="center" prop="supplier" :show-overflow-tooltip="true"/> <el-table-column label="物资厂家" align="center" prop="supplier" :show-overflow-tooltip="true"/>
<el-table-column label="操作人" align="center" prop="createBy" :show-overflow-tooltip="true"/> <el-table-column label="操作人" align="center" prop="createBy" :show-overflow-tooltip="true"/>
<el-table-column label="操作时间" align="center" prop="createTime" width="150" :show-overflow-tooltip="true"/> <el-table-column label="操作时间" align="center" prop="createTime" width="180" :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" width="100">
<!-- <template slot-scope="scope">--> <!-- <template slot-scope="scope">-->
<!-- <dict-tag :options="dict.type.purchase_task_status" :value="scope.row.taskStatus"/>--> <!-- <dict-tag :options="dict.type.purchase_task_status" :value="scope.row.taskStatus"/>-->
<!-- </template>--> <!-- </template>-->
@ -124,156 +124,81 @@
/> />
<!-- 验收单弹窗 --> <!-- 验收单弹窗 -->
<el-dialog <el-dialog :title="title" :visible.sync="openPrint" width="1100px" append-to-body>
:title="title"
:visible.sync="openPrint"
width="1100px"
append-to-body
>
<div style="height: 500px; overflow-y: scroll"> <div style="height: 500px; overflow-y: scroll">
<vue-easy-print tableShow ref="remarksPrintRef" class="print"> <vue-easy-print tableShow ref="remarksPrintRef" class="print">
<div <div class="title" style="text-align: center;font-weight: 600;font-size: 16px;">
class="title"
style="
text-align: center;
font-weight: 600;
font-size: 16px;
"
>
机具设备到货验收单 机具设备到货验收单
</div> </div>
<div <div class="info" style="margin-top: 10px; display: flex; flex-wrap: wrap">
class="info" <div class="item" style="width: 100%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
style="margin-top: 10px; display: flex; flex-wrap: wrap"
>
<div
class="item"
style="
width: 100%;
flex-shrink: 0;
margin-bottom: 5px;
font-size: 14px;
"
>
<span>单据编号{{printData.code}}</span> <span>单据编号{{printData.code}}</span>
</div> </div>
<div <div
class="item" class="item"
style=" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
width: 50%;
flex-shrink: 0;
margin-bottom: 5px;
font-size: 14px;
"
>
<span>生产厂家供应商{{printData.supplierName}}</span> <span>生产厂家供应商{{printData.supplierName}}</span>
</div> </div>
<div <div
class="item" class="item"
style=" style="width: 50%;flex-shrink: 0;margin-bottom: 5px;font-size: 14px;">
width: 50%;
flex-shrink: 0;
margin-bottom: 5px;
font-size: 14px;
"
>
<span>到货日期{{printData.arrivalDate}}</span> <span>到货日期{{printData.arrivalDate}}</span>
</div> </div>
</div> </div>
<el-table <el-table :data="printTableData" class="table" style="margin-top: 20px;width: 1000px;padding-bottom: 1px;" border>
:data="printTableData"
class="table"
style="
margin-top: 20px;
width: 1000px;
padding-bottom: 1px;
"
border
>
<!-- <el-table-column type="selection" width="55" align="center" />--> <!-- <el-table-column type="selection" width="55" align="center" />-->
<el-table-column <el-table-column label="序号" align="center" type="index" row="2" />
label="序号" <el-table-column label="物资名称" align="center" prop="maTypeName"/>
align="center" <el-table-column label="规格型号" align="center" prop="typeName"/>
type="index" <el-table-column label="单位" align="center" prop="unitName"/>
row=2
/>
<el-table-column
label="物资名称"
align="center"
prop="maTypeName"
/>
<el-table-column
label="规格型号"
align="center"
prop="typeName"
/>
<el-table-column
label="单位"
align="center"
prop="unitName"
/>
<el-table-column label="配送信息" align="center"> <el-table-column label="配送信息" align="center">
<el-table-column <el-table-column label="采购数量" align="center" prop="purchaseNum"/>
label="采购数量" <el-table-column label="验收结论" align="center" prop="checkResult"/>
align="center"
prop="purchaseNum"
/>
<el-table-column
label="验收结论"
align="center"
prop="checkResult"
/>
<el-table-column label="质保质量" align="center"> <el-table-column label="质保质量" align="center">
<el-table-column <el-table-column label="实收份数" align="center" prop="checkNum"/>
label="实收份数" <el-table-column label="符合要求" align="center"/>
align="center"
prop="checkNum"
/>
<el-table-column
label="符合要求"
align="center"
/>
</el-table-column> </el-table-column>
</el-table-column> </el-table-column>
<el-table-column <el-table-column label="备注" align="center" prop="remark"/>
label="备注"
align="center"
prop="remark"
/>
<!-- <el-table-column-->
<!-- label="合格证及技术资料"-->
<!-- align="center"-->
<!-- prop=""-->
<!-- />-->
<!-- <el-table-column label="包装" align="center" prop="" />-->
</el-table> </el-table>
<div <div class="fillIn" style="margin-top: 20px;display: flex;justify-content: space-between;" >
class="fillIn" <div class="item" style="width: 33%;display: flex;align-items: center;">
style=" <div style="width: 25%;">供应科</div>
margin-top: 20px; <div style="width: 75%;display: flex;align-items: center;flex-wrap: wrap;" v-if="printData.signUrl">
display: flex; <div style="width: 80%;margin-left: 10px;">
justify-content: space-between; <img :src="printData.signUrl" :class="printData.signType=='0' ? 'image-type':'sign-type'" alt="">
" </div>
> </div>
<div class="item" style="width: 33%"> <!-- <div>
<div>
<span>供应科{{printData.supplyDept}}</span> <span>供应科{{printData.supplyDept}}</span>
</div> </div> -->
</div> </div>
<div class="item" style="width: 33%"> <div class="item" style="width: 33%;display: flex;align-items: center;">
<div> <div style="width: 30%;">生产技术科</div>
<div style="width: 70%;display: flex;align-items: center;flex-wrap: wrap;" v-if="printData.signUrl">
<div style="width: 80%;margin-left: 10px;">
<img :src="printData.signUrl" :class="printData.signType=='0' ? 'image-type':'sign-type'" alt="">
</div>
</div>
<!-- <div>
<span>生产技术科{{printData.productionTechDept}}</span> <span>生产技术科{{printData.productionTechDept}}</span>
</div> </div> -->
</div> </div>
<div class="item" style="width: 33%;display: flex;align-items: center;">
<div class="item" style="width: 33%"> <div style="width: 25%;">库管班</div>
<div> <div style="width: 75%;display: flex;align-items: center;flex-wrap: wrap;" v-if="printData.signUrl">
<span>库管班{{printData.warehouseTeam}}</span> <div style="width: 45%;">
<img :src="printData.signUrl" :class="printData.signType=='0' ? 'image-type':'sign-type'" alt="">
</div>
<div style="width: 45%;">
<img :src="printData.signUrl" :class="printData.signType=='0' ? 'image-type':'sign-type'" alt="">
</div>
</div> </div>
<!-- <div>
<span>库管班{{printData.warehouseTeam}}</span>
</div> -->
</div> </div>
</div> </div>
</vue-easy-print> </vue-easy-print>
@ -293,9 +218,11 @@
import { getPurchaseList,acceptOuterVerify,getPurchaseCheckFormByTaskId } from "@/api/purchase/goodsAccept"; import { getPurchaseList,acceptOuterVerify,getPurchaseCheckFormByTaskId } from "@/api/purchase/goodsAccept";
import { downloadFile } from '@/utils/download' import { downloadFile } from '@/utils/download'
import { getToken } from '@/utils/auth' import { getToken } from '@/utils/auth'
import vueEasyPrint from "vue-easy-print";
export default { export default {
name: "GoodsAcceptList", name: "GoodsAcceptList",
dicts: ['purchase_task_status'], dicts: ['purchase_task_status'],
components: { vueEasyPrint },
data() { data() {
return { return {
// //
@ -354,7 +281,6 @@
this.queryParams.endTime=undefined this.queryParams.endTime=undefined
} }
this.queryParams.taskStage= 2 this.queryParams.taskStage= 2
this.queryParams.statusList=[2,12]
getPurchaseList(this.queryParams).then(response => { getPurchaseList(this.queryParams).then(response => {
this.tableList = response.data.rows; this.tableList = response.data.rows;
this.total = response.data.total; this.total = response.data.total;
@ -444,7 +370,7 @@
handleExport() { handleExport() {
this.download( this.download(
"/material/purchase_check_info/export", "/material/purchase_check_info/export",
{ ...this.queryParams,statusList:[2,12],taskStage: 2 }, { ...this.queryParams,taskStage: 2 },
`新购到货验收_${new Date().getTime()}.xlsx` `新购到货验收_${new Date().getTime()}.xlsx`
); );
}, },
@ -454,6 +380,21 @@
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.image-type {
/* 旋转图片 */
transform: rotate(-90deg);
/* 确保旋转后的图片不会超出容器 */
max-width: 100%;
/* 保持图片的宽高比 */
width: 40px;
height: 100px;
}
.sign-type{
width: 100px;
height: 40px;
}
.uploadImg { .uploadImg {
padding-top: 20px; padding-top: 20px;
display: flex; display: flex;

View File

@ -792,7 +792,7 @@ export default {
//--- //---
async getTaskInfo() { async getTaskInfo() {
// this.loading = true; // this.loading = true;
await getPurchaseCheckInfo({ taskId: this.taskId, id: this.id, statusList: [1], taskStage: 1 }).then( await getPurchaseCheckInfo({ taskId: this.taskId, id: this.id, taskStage: 1 }).then(
response => { response => {
this.maForm = response.data.purchaseCheckInfo this.maForm = response.data.purchaseCheckInfo
this.maForm.id = response.data.purchaseCheckInfo.id this.maForm.id = response.data.purchaseCheckInfo.id

View File

@ -671,7 +671,6 @@ export default {
typeId: this.queryParams.typeId, typeId: this.queryParams.typeId,
pageSize: this.queryParams.pageSize, pageSize: this.queryParams.pageSize,
pageNum: this.queryParams.pageNum, pageNum: this.queryParams.pageNum,
statusList: [1],
taskStage: 1, taskStage: 1,
}; };
getListNewBuy(this.addDateRange(params)).then((response) => { getListNewBuy(this.addDateRange(params)).then((response) => {
@ -911,7 +910,7 @@ export default {
handleExport() { handleExport() {
this.download( this.download(
"/material/purchase_check_info/export", "/material/purchase_check_info/export",
{ ...this.queryParams,statusList: [1],taskStage: 1 }, { ...this.queryParams,taskStage: 1 },
`新购到货_${new Date().getTime()}.xlsx` `新购到货_${new Date().getTime()}.xlsx`
); );
}, },

View File

@ -210,7 +210,7 @@ export default {
//- //-
getTaskInfo() { getTaskInfo() {
this.loading = true this.loading = true
getPurchaseCheckInfo({taskId:this.taskId,id:this.id,statusList:[1],taskStage: 1}).then((response) => { getPurchaseCheckInfo({taskId:this.taskId,id:this.id,taskStage: 1}).then((response) => {
this.taskInfo = response.data this.taskInfo = response.data
this.equipmentList = response.data.purchaseCheckDetailsList this.equipmentList = response.data.purchaseCheckDetailsList
this.equipmentList.forEach((item) => { this.equipmentList.forEach((item) => {

View File

@ -157,7 +157,7 @@
<svg-icon icon-class="bind-icon" /> <svg-icon icon-class="bind-icon" />
绑定 绑定
</el-button> </el-button>
<el-button <!-- <el-button
size="mini" size="mini"
type="danger" type="danger"
icon="el-icon-close" icon="el-icon-close"
@ -165,7 +165,7 @@
v-if="!isView&&row.manageType==0&&(row.status==3||row.status==14)" v-if="!isView&&row.manageType==0&&(row.status==3||row.status==14)"
> >
驳回 驳回
</el-button> </el-button> -->
<!-- 当从主列表点击查看时可显示二维码下载按钮 --> <!-- 当从主列表点击查看时可显示二维码下载按钮 -->
<el-button <el-button
plain plain

View File

@ -179,14 +179,14 @@
<svg-icon icon-class="bind-icon" /> <svg-icon icon-class="bind-icon" />
编码绑定 编码绑定
</el-button> </el-button>
<el-button <!-- <el-button
plain plain
size="mini" size="mini"
type="danger" v-if="row.taskStatusName=='未完成'" type="danger" v-if="row.taskStatusName=='未完成'"
icon="el-icon-close" icon="el-icon-close"
@click="handleReject(row)" @click="handleReject(row)"
>驳回</el-button >驳回</el-button
> > -->
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

View File

@ -122,9 +122,9 @@
<el-button size="mini" type="success" @click="pass(scope.row)" v-if="scope.row.status!=14&&scope.row.status!=19"> <el-button size="mini" type="success" @click="pass(scope.row)" v-if="scope.row.status!=14&&scope.row.status!=19">
入库 入库
</el-button> </el-button>
<el-button size="mini" type="danger" @click="reject(scope.row)" v-if="scope.row.status!=14&&scope.row.status!=19"> <!-- <el-button size="mini" type="danger" @click="reject(scope.row)" v-if="scope.row.status!=14&&scope.row.status!=19">
驳回 驳回
</el-button> </el-button> -->
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

View File

@ -199,13 +199,13 @@
> >
入库 入库
</el-button> </el-button>
<el-button <!-- <el-button
size="mini" size="mini"
type="warning" type="warning"
@click="handlePrint(scope.row)" @click="handlePrint(scope.row)"
> >
入库单 入库单
</el-button> </el-button> -->
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

View File

@ -36,7 +36,7 @@ module.exports = {
// detail: https://cli.vuejs.org/config/#devserver-proxy // detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
// target: `http://localhost:18080`, // target: `http://localhost:18080`,
target: `http://192.168.2.245:18080`,//马 target: `http://192.168.2.246:18080`,//马
// target: `http://192.168.0.244:18580`,//测试 // target: `http://192.168.0.244:18580`,//测试
// target: `http://192.168.2.223:18080`,//山 // target: `http://192.168.2.223:18080`,//山
// target: `http://192.168.0.110:18080`,//洪 // target: `http://192.168.0.110:18080`,//洪