|
@@ -90,7 +90,14 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
- <view class="title">审核详情</view>
|
|
|
+ <view class="title"
|
|
|
+ >审核详情
|
|
|
+ <uni-steps
|
|
|
+ :options="nodeList.list"
|
|
|
+ :active="nodeList.currentIndex"
|
|
|
+ direction="column"
|
|
|
+ ></uni-steps>
|
|
|
+ </view>
|
|
|
|
|
|
<view class="group">
|
|
|
<button v-if="canAuth()" @click="onHandleAudit(0)" class="commit">
|
|
@@ -110,20 +117,46 @@
|
|
|
|
|
|
<script>
|
|
|
import { mapState } from "vuex";
|
|
|
+import { queryFlow } from "@/services/project";
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
auth: false,
|
|
|
status: ["售前", "转执行", "转运营", "转质保"],
|
|
|
+ flowList: [],
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
|
...mapState(["currentProject"]),
|
|
|
+ nodeList() {
|
|
|
+ if (!this.flowList) return [];
|
|
|
+ let flowInfo = this.flowList.find(
|
|
|
+ (item) => item.id == this.currentProject.flow_id
|
|
|
+ );
|
|
|
+ if (!flowInfo) return [];
|
|
|
+ let currentIndex = flowInfo.Nodes.findIndex(
|
|
|
+ (item) => item.id == this.currentProject.node_id
|
|
|
+ );
|
|
|
+ return {
|
|
|
+ currentIndex,
|
|
|
+ list: flowInfo.Nodes.map((item) => ({
|
|
|
+ title: item.node,
|
|
|
+ desc: `审批人:${this.getAudits(item)}`,
|
|
|
+ })),
|
|
|
+ };
|
|
|
+ },
|
|
|
},
|
|
|
onLoad(options) {
|
|
|
this.auth = Boolean(options.auth);
|
|
|
+ this.init();
|
|
|
},
|
|
|
methods: {
|
|
|
+ async init() {
|
|
|
+ let res;
|
|
|
+ res = await queryFlow();
|
|
|
+ this.flowList = res.data;
|
|
|
+ console.log(this.nodeList);
|
|
|
+ },
|
|
|
canAuth() {
|
|
|
return this.auth;
|
|
|
},
|
|
@@ -131,6 +164,22 @@ export default {
|
|
|
if (value) console.log("审核通过");
|
|
|
else console.log("审核拒绝");
|
|
|
},
|
|
|
+ getAudits(nodeInfo) {
|
|
|
+ switch (nodeInfo.id) {
|
|
|
+ case 11:
|
|
|
+ return "执行项目经理";
|
|
|
+ case 12:
|
|
|
+ return "运营经理";
|
|
|
+ case 13:
|
|
|
+ return "执行项目经理";
|
|
|
+ case 14:
|
|
|
+ return "质保经理";
|
|
|
+ default:
|
|
|
+ return (nodeInfo.NodeAudits || [])
|
|
|
+ .map((item) => item.AuthorRoleInfo.Name)
|
|
|
+ .join(",");
|
|
|
+ }
|
|
|
+ },
|
|
|
},
|
|
|
};
|
|
|
</script>
|
|
@@ -163,6 +212,16 @@ export default {
|
|
|
width: 70%;
|
|
|
}
|
|
|
}
|
|
|
+::v-deep {
|
|
|
+ .uni-steps__column-title {
|
|
|
+ font-size: 18px;
|
|
|
+ line-height: 24px;
|
|
|
+ }
|
|
|
+ .uni-steps__column-desc {
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 18px;
|
|
|
+ }
|
|
|
+}
|
|
|
|
|
|
.group {
|
|
|
width: 100%;
|