feat: 审核开关

dev_ksck2.0
chenhc 1 year ago
parent b81dde75c8
commit e72c3871f0

@ -17,3 +17,11 @@ export function submitApprovalFlow(query) {
data: query data: query
}); });
} }
export function getSysApprovalFlowConfig(query) {
return axios({
url: BUSINESS_PRE+"/sysApprovalFlow/config",
method: "GET",
data: query
});
}

@ -138,7 +138,6 @@ export default {
}, },
getList() { getList() {
this.loading = true; this.loading = true;
console.log(this.idQuery.approvalFlowId)
getDetailList(this.idQuery.approvalFlowId) getDetailList(this.idQuery.approvalFlowId)
.then((response) => { .then((response) => {
this.activities = response.data || []; this.activities = response.data || [];

@ -417,10 +417,10 @@ export default {
update: "编辑领用单据", update: "编辑领用单据",
}, },
statusMap: { statusMap: {
0: "草稿", 1: "草稿",
1: "未审核", 2: "未审核",
2: "已审核", 3: "已审核",
3: "已拒绝" 4: "已拒绝"
}, },
idQuery: {}, idQuery: {},
corpList: [], corpList: [],

@ -366,7 +366,7 @@
<script> <script>
import {getOrderDetail, getReceiveOrder, printOrder} from "@/api/inout/receiveOrder"; import {getOrderDetail, getReceiveOrder, printOrder} from "@/api/inout/receiveOrder";
import auditDetail from "@/views/inout/receive/receiveAuditDetail" import auditDetail from "@/views/inout/receive/receiveAuditDetail";
import { import {
filterSub, filterSub,
filterSubAllOptimize, filterSubAllOptimize,
@ -395,10 +395,10 @@ export default {
targetInvCode: null, targetInvCode: null,
}, },
statusMap: { statusMap: {
0: "草稿", 1: "草稿",
1: "未审核", 2: "未审核",
2: "已审核", 3: "已审核",
3: "已拒绝" 4: "已拒绝"
}, },
idQuery: null, idQuery: null,
newSpDistributionVisible: false, newSpDistributionVisible: false,

@ -1,23 +1,27 @@
<script src="../../../api/basic/sysApprovalFlow.js"></script>
<template> <template>
<div> <div>
<el-form :model="formData" ref="dataForm" label-width="100px"> <el-form :model="formData" ref="dataForm" label-width="100px">
<el-row type="flex" justify="end"> <el-row type="flex" justify="end">
<el-button-group style="display: flex;margin-bottom: 15px; margin-right: 50px;margin-top: -5px"> <el-button-group style="display: flex;margin-bottom: 15px; margin-right: 50px;margin-top: -5px">
<!-- <el-button-->
<!-- type="primary"-->
<!-- @click.native="saveOrder('3')"-->
<!-- :loading="loading"-->
<!-- >审核通过-->
<!-- </el-button-->
<!-- >-->
<!-- <el-button-->
<!-- type="primary"-->
<!-- @click.native="saveOrder('4')"-->
<!-- :loading="loading"-->
<!-- >审核拒绝-->
<!-- </el-button-->
<!-- >-->
<el-button <el-button
v-show="!this.sysApprovalFlowConfig"
type="primary"
@click.native="saveOrder('3')"
:loading="loading"
>审核通过
</el-button
>
<el-button
v-show="!this.sysApprovalFlowConfig"
type="primary"
@click.native="saveOrder('4')"
:loading="loading"
>审核拒绝
</el-button
>
<el-button
v-show="this.sysApprovalFlowConfig"
type="primary" type="primary"
@click.native="showApprovalFlowDetail()" @click.native="showApprovalFlowDetail()"
>审核过程 >审核过程
@ -112,6 +116,7 @@
import approvalFlowDetail from "@/components/ApprovalFlow/index"; import approvalFlowDetail from "@/components/ApprovalFlow/index";
import dialogInvProduct from "../DialogSelectInvProduct"; import dialogInvProduct from "../DialogSelectInvProduct";
import {getAudit, getOrderDetail} from "@/api/inout/receiveOrder"; import {getAudit, getOrderDetail} from "@/api/inout/receiveOrder";
import {getSysApprovalFlowConfig} from "@/api/basic/sysApprovalFlow";
export default { export default {
name: "idQuery", name: "idQuery",
@ -137,6 +142,7 @@ export default {
data() { data() {
return { return {
idQuery: {}, idQuery: {},
sysApprovalFlowConfig: false,
approvalFlowDetailVisible: false, approvalFlowDetailVisible: false,
showSearch: true, showSearch: true,
code: "", code: "",
@ -151,9 +157,15 @@ export default {
dialogInvProduct,approvalFlowDetail dialogInvProduct,approvalFlowDetail
}, },
methods: { methods: {
closeDialog() { getConfig(){
this.approvalFlowDetailVisible = false; getSysApprovalFlowConfig().then((response) => {
this.sysApprovalFlowConfig = response.data;
}).catch(() => {
});
}, },
// closeDialog() {
// this.approvalFlowDetailVisible = false;
// },
handleClose() { handleClose() {
this.approvalFlowDetailVisible = false; this.approvalFlowDetailVisible = false;
}, },
@ -189,15 +201,17 @@ export default {
this.$message.error(res.message); this.$message.error(res.message);
} }
})) }))
this.closeDialog()
} }
}, },
filters: {}, filters: {},
mounted() { mounted() {
}, },
created() { created() {
console.log(this.idQuery) // console.log(this.idQuery)
this.formData = this.idQuery; this.formData = this.idQuery;
this.handleDetail(); this.handleDetail();
this.getConfig();
}, },
}; };
</script> </script>

@ -419,11 +419,27 @@
></dialogNewReceive> ></dialogNewReceive>
</el-dialog> </el-dialog>
<el-dialog
title="审批详情"
:visible.sync="approvalFlowDetailVisible"
width="80%"
v-if="approvalFlowDetailVisible"
@close='closeDialog'
:close-on-click-modal="false"
:close-on-press-escape="false"
:before-close="handleClose"
>
<approvalFlowDetail
:isChang="false"
:closeDialog="closeDialog"
:idQuery="idQuery"
></approvalFlowDetail>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
import approvalFlowDetail from "@/components/ApprovalFlow/index";
import {getOrderDetail, getReceiveOrder, printOrder} from "@/api/inout/receiveOrder"; import {getOrderDetail, getReceiveOrder, printOrder} from "@/api/inout/receiveOrder";
import auditDetail from "@/views/inout/receive/receiveAuditDetail" import auditDetail from "@/views/inout/receive/receiveAuditDetail"
import {delReceive} from "@/api/thrsys/thrOrderReceive"; import {delReceive} from "@/api/thrsys/thrOrderReceive";
@ -454,16 +470,17 @@ export default {
invCode: null invCode: null
}, },
statusMap: { statusMap: {
0: "草稿", 1: "草稿",
1: "未审核", 2: "未审核",
2: "已审核", 3: "已审核",
3: "已拒绝" 4: "已拒绝"
}, },
idQuery: {}, idQuery: {},
invList: [], invList: [],
invCodebe: null, invCodebe: null,
newSpDistributionVisible: false, newSpDistributionVisible: false,
pureApplyEditVisible: false, pureApplyEditVisible: false,
approvalFlowDetailVisible: false,
total: 0, total: 0,
tableHeader:[], tableHeader:[],
queryList:[], queryList:[],
@ -557,6 +574,13 @@ export default {
}, },
methods: { methods: {
handleClose() {
this.approvalFlowDetailVisible = false;
},
showApprovalFlowDetail(_this,row) {
_this.idQuery = row
_this.approvalFlowDetailVisible = true;
},
onReset() { onReset() {
this.$router.push({ this.$router.push({
path: "", path: "",
@ -739,6 +763,7 @@ export default {
closeDialog() { closeDialog() {
this.newSpDistributionVisible = false; this.newSpDistributionVisible = false;
this.pureApplyEditVisible = false; this.pureApplyEditVisible = false;
this.approvalFlowDetailVisible = false;
}, },
@ -754,7 +779,7 @@ export default {
}, },
components: { components: {
auditDetail, dialogNewReceive auditDetail, dialogNewReceive,approvalFlowDetail
}, },
mounted() { mounted() {
}, },

@ -460,10 +460,10 @@ export default {
targetInvCode: null, targetInvCode: null,
}, },
statusMap: { statusMap: {
0: "草稿", 1: "草稿",
1: "未审核", 2: "未审核",
2: "已审核", 3: "已审核",
3: "已拒绝" 4: "已拒绝"
}, },
idQuery: null, idQuery: null,
invList: [], invList: [],

@ -113,10 +113,10 @@ export default {
}, },
formName: null, formName: null,
statusMap: { statusMap: {
0: "草稿", 1: "草稿",
1: "未审核", 2: "未审核",
2: "已审核", 3: "已审核",
3: "已拒绝" 4: "已拒绝"
}, },
ids: [], ids: [],
idQuery: {}, idQuery: {},

Loading…
Cancel
Save