cz 2 роки тому
батько
коміт
ea84bd2d42

+ 1 - 0
public/img/process/icon_audit.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path fill="#ffffff" d="M898.304 206.7968l-139.0592-138.752A57.4464 57.4464 0 0 0 718.592 51.2h-494.592a115.2 115.2 0 0 0-115.2 115.2v691.2A115.2 115.2 0 0 0 224 972.8h576a115.2 115.2 0 0 0 115.2-115.2V247.552a57.6 57.6 0 0 0-16.896-40.7552z m-174.6944 500.3264a35.2256 35.2256 0 0 1-35.2768 35.2768H335.6672a35.2256 35.2256 0 0 1-35.2768-35.2768v-35.2768a70.5024 70.5024 0 0 1 70.5536-70.5024h3.1744a35.328 35.328 0 0 0 32.5632-21.76l32.9216-79.2576a35.84 35.84 0 0 0-8.448-39.168 105.7792 105.7792 0 1 1 152.8832-1.4848 35.84 35.84 0 0 0-6.912 39.8848l39.168 81.92a35.2768 35.2768 0 0 0 31.7952 20.0704h5.12a70.5024 70.5024 0 0 1 70.5536 70.5024z m37.9904-424.96a57.6 57.6 0 0 1-57.6-57.6v-115.2l172.8 172.8z"  /></svg>

+ 1 - 0
public/img/process/icon_begin.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path fill="#ffffff" d="M905.0112 629.3504l-474.368 273.8688a135.4752 135.4752 0 0 1-203.264-117.3504V238.08a135.4752 135.4752 0 0 1 203.264-117.3504l474.368 273.8688a135.4752 135.4752 0 0 1 0 234.752z"  /></svg>

+ 1 - 0
public/img/process/icon_delete_bian.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M512 512m-512 0a512 512 0 1 0 1024 0 512 512 0 1 0-1024 0Z" fill="#FFFFFF" /><path d="M221.8496 221.8496a410.8288 410.8288 0 0 0 0 579.2768 409.6 409.6 0 0 0 579.2768-579.2768 410.8288 410.8288 0 0 0-579.2768 0z m470.6816 181.0432l-108.6464 108.5952 108.6464 108.5952a51.2 51.2 0 1 1-72.448 72.448l-108.5952-108.6464-108.5952 108.6464a51.2 51.2 0 0 1-72.448-72.448l108.6464-108.5952-108.6464-108.5952a51.2 51.2 0 0 1 72.448-72.448l108.5952 108.6464 108.5952-108.6464a51.2 51.2 0 0 1 72.448 72.448z" fill="#F94539" /></svg>

+ 1 - 0
public/img/process/icon_end.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path fill="#ffffff" d="M819.2 51.2h-614.4a153.6 153.6 0 0 0-153.6 153.6v614.4a153.6 153.6 0 0 0 153.6 153.6h614.4a153.6 153.6 0 0 0 153.6-153.6v-614.4a153.6 153.6 0 0 0-153.6-153.6z m51.2 768a51.2 51.2 0 0 1-51.2 51.2h-614.4a51.2 51.2 0 0 1-51.2-51.2v-614.4a51.2 51.2 0 0 1 51.2-51.2h614.4a51.2 51.2 0 0 1 51.2 51.2z"  /><path fill="#ffffff" d="M256 256m102.4 0l307.2 0q102.4 0 102.4 102.4l0 307.2q0 102.4-102.4 102.4l-307.2 0q-102.4 0-102.4-102.4l0-307.2q0-102.4 102.4-102.4Z"  /></svg>

+ 1 - 0
public/img/process/icon_handle.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path fill="#ffffff" d="M759.6032 385.1264l-121.4464-121.4464a56.7808 56.7808 0 0 0-78.848-8.7552l-444.6208 444.5696a44.3904 44.3904 0 0 0-12.2368 33.3824l4.096 117.3504a72.7552 72.7552 0 0 0 66.56 66.56l117.3504 4.096a44.1856 44.1856 0 0 0 33.3312-12.2368l444.6208-444.6208a56.7808 56.7808 0 0 0-8.8064-78.8992zM884.1216 194.4064l-60.0576-60.0576a97.536 97.536 0 0 0-137.5232-6.656l-53.1456 53.1456 204.2368 204.2368 53.1456-53.1456a97.5872 97.5872 0 0 0-6.656-137.5232z"  /><path fill="#ffffff" d="M531.0464 824.9344m48.3328 0l290.048 0q48.3328 0 48.3328 48.3328l0 0q0 48.3328-48.3328 48.3328l-290.048 0q-48.3328 0-48.3328-48.3328l0 0q0-48.3328 48.3328-48.3328Z"  /></svg>

+ 1 - 0
public/img/process/icon_shenhe.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path fill="#ffffff" d="M898.304 206.7968l-139.0592-138.752A57.4464 57.4464 0 0 0 718.592 51.2h-494.592a115.2 115.2 0 0 0-115.2 115.2v691.2A115.2 115.2 0 0 0 224 972.8h576a115.2 115.2 0 0 0 115.2-115.2V247.552a57.6 57.6 0 0 0-16.896-40.7552z m-199.1168 488.8064H324.8128a43.2128 43.2128 0 0 1 0-86.4256h374.3744a43.2128 43.2128 0 0 1 0 86.4256z m0-206.3872H324.8128a43.2128 43.2128 0 0 1 0-86.4256h374.3744a43.2128 43.2128 0 0 1 0 86.4256z m62.4128-207.0528a57.6 57.6 0 0 1-57.6-57.6v-115.2l172.8 172.8z"  /></svg>

+ 1 - 0
public/img/process/icon_success_bian.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M512 512m-512 0a512 512 0 1 0 1024 0 512 512 0 1 0-1024 0Z" fill="#FFFFFF" /><path d="M512 102.4a409.6 409.6 0 1 0 409.6 409.6 409.6 409.6 0 0 0-409.6-409.6z m210.8928 312.0128l-253.2864 251.4944a56.832 56.832 0 0 1-80.2304 0l-20.224-20.48-68.4544-68.7616a42.6496 42.6496 0 0 1 0-60.16 42.6496 42.6496 0 0 1 60.3648 0l68.4544 68.864 233.0112-231.424a42.5984 42.5984 0 0 1 60.0576 60.4672z" fill="#39C55A" /></svg>

+ 1 - 0
public/img/process/icon_wait_bian.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="200px" height="200.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M512 512m-512 0a512 512 0 1 0 1024 0 512 512 0 1 0-1024 0Z" fill="#FFFFFF" /><path d="M512 102.4a409.6 409.6 0 1 0 409.6 409.6 409.6 409.6 0 0 0-409.6-409.6z m-204.8 460.8a51.2 51.2 0 1 1 51.2-51.2 51.2 51.2 0 0 1-51.2 51.2z m203.3152 0a51.2 51.2 0 1 1 51.2-51.2 51.2 51.2 0 0 1-51.2512 51.2z m206.3872 0a51.2 51.2 0 1 1 51.2-51.2 51.2 51.2 0 0 1-51.3024 51.2z" fill="#FF9315" /></svg>

+ 2 - 2
src/api/process/index.js

@@ -3,7 +3,7 @@ import request from '@/router/axios'
 // 流程记录
 export function exampleInfo(data = {}) {
   return request({
-    url: '/api/victoriatourist/service-flow/exampleInfo/record',
+    url: '/api/service-flow/exampleInfo/record',
     method: 'post',
     data: data,
   })
@@ -11,7 +11,7 @@ export function exampleInfo(data = {}) {
 
 export function exampleInfoShowFlow(data = {}) {
   return request({
-    url: '/api/victoriatourist/service-flow/exampleInfo/showFlow',
+    url: '/api/service-flow/exampleInfo/showFlow',
     method: 'post',
     data: data,
   })

+ 31 - 12
src/components/process/purchase/purchaseMake.vue

@@ -223,20 +223,39 @@ export default {
     });
   },
   methods: {
+    // handleSubmit() {
+    //   this.$refs.ruleForm.validate((valid) => {
+    //     if (valid) {
+    //       const data = [...this.form.goodsList];
+    //       for (let i = 0; i < data.length; i++) {
+    //         const e = data[i];
+    //         if (
+    //           Number(e.purchaseQuantity) + Number(e.quantity) >
+    //           Number(e.quantityOne)
+    //         ) {
+    //           this.msgInfo("此次采购数量和已采购数量合不可大于采购数量");
+    //           return false;
+    //         }
+    //       }
+    //       return true;
+    //       // this.loading = true;
+    //       // this.$emit("submit");
+    //     } else return false;
+    //   });
+    // },
     handleSubmit() {
-      this.$refs.form.validate((valid) => {
-        if (valid) {
-          const data = [...this.form.goodsList];
-          for (let i = 0; i < data.length; i++) {
-            const e = data[i];
-            if (Number(e.assw) + Number(e.quantity) > Number(e.quantity)) {
-              return this.msgInfo("此次采购数量和已采购数量合不可大于采购数量");
-            }
-          }
-          this.loading = true;
-          this.$emit("submit");
+      const data = [...this.form.goodsList];
+      for (let i = 0; i < data.length; i++) {
+        const e = data[i];
+        if (
+          Number(e.purchaseQuantity) + Number(e.quantity) >
+          Number(e.quantityOne)
+        ) {
+          this.msgInfo("此次采购数量和已采购数量合不可大于采购数量");
+          return false;
         }
-      });
+      }
+      return true;
     },
     handleCancel() {
       this.$emit("cancel");

+ 116 - 21
src/views/process/examinationApproval/approvalRecords.vue

@@ -52,35 +52,71 @@
                 <img
                   v-if="[1, 2, 4, 6].includes(item.type)"
                   src="/img/process/icon_success_bian.svg"
-                  style="width: 18px; height: 18px; position: absolute; left: 28px; top: 24px"
+                  style="
+                    width: 18px;
+                    height: 18px;
+                    position: absolute;
+                    left: 28px;
+                    top: 24px;
+                  "
                   fit="scale-down"
                 />
                 <img
                   v-else-if="[3, 5].includes(item.type)"
                   src="/img/process/icon_delete_bian.svg"
-                  style="width: 18px; height: 18px; position: absolute; left: 28px; top: 24px"
+                  style="
+                    width: 18px;
+                    height: 18px;
+                    position: absolute;
+                    left: 28px;
+                    top: 24px;
+                  "
                   fit="scale-down"
                 />
                 <img
                   v-else-if="item.type === 98"
                   src="/img/process/icon_wait_bian.svg"
-                  style="width: 18px; height: 18px; position: absolute; left: 28px; top: 24px"
+                  style="
+                    width: 18px;
+                    height: 18px;
+                    position: absolute;
+                    left: 28px;
+                    top: 24px;
+                  "
                   fit="scale-down"
                 />
               </div>
               <div
                 v-if="recordsList.length - 1 !== index"
-                style="margin-top: 8px; border-right: 2px solid #dcdfe6; height: calc(100% - 48px); width: 20px;"
+                style="
+                  margin-top: 8px;
+                  border-right: 2px solid #dcdfe6;
+                  height: calc(100% - 48px);
+                  width: 20px;
+                "
               ></div>
             </el-col>
             <el-col :span="20">
-              <div style="margin-bottom: 8px; background-color: #f2f2f2; padding: 8px">
+              <div
+                style="
+                  margin-bottom: 8px;
+                  background-color: #f2f2f2;
+                  padding: 8px;
+                "
+              >
                 <div v-if="item.type === 1">
                   <div style="line-height: 28px">
                     <span>{{ item.nodeName }}</span>
-                    <span style="color: #0084FF">(发起申请)</span>
+                    <span style="color: #0084ff">(发起申请)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>发起人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -90,7 +126,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #39c55a">(通过)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>审批人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -100,7 +143,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #f84539">(不通过)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>审批人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -110,7 +160,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #39c55a">(同意)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>审批人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -120,7 +177,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #f84539">(驳回)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>审批人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -130,7 +194,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #39c55a">(完成)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>审批人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -141,7 +212,14 @@
                       <span>{{ item.nodeName }}</span>
                       <span style="color: #999">(未开始)</span>
                     </div>
-                    <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div
+                      style="
+                        line-height: 28px;
+                        display: flex;
+                        justify-content: space-between;
+                        color: #ccc;
+                      "
+                    >
                       <div>发起人: {{ item.userName }}</div>
                       <div>{{ item.createTime }}</div>
                     </div>
@@ -152,7 +230,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #ff9315">(进行中)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>审批人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -162,7 +247,14 @@
                     <span>{{ item.nodeName }}</span>
                     <span style="color: #999">(结束)</span>
                   </div>
-                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                  <div
+                    style="
+                      line-height: 28px;
+                      display: flex;
+                      justify-content: space-between;
+                      color: #ccc;
+                    "
+                  >
                     <div>发起人: {{ item.userName }}</div>
                     <div>{{ item.createTime }}</div>
                   </div>
@@ -182,29 +274,32 @@
 
 <script>
 export default {
-  name: 'ApprovalRecords',
+  name: "ApprovalRecords",
   props: {
     transferParams: Object,
     recordsList: Array,
   },
   data() {
     return {
-      activeName: 'first',
-    }
+      activeName: "first",
+    };
   },
   created() {},
   mounted() {},
   methods: {
     getStyle(text) {
       if (text) {
-        return text.replace(/\n|\r\n/g, '<br>')
+        return text.replace(/\n|\r\n/g, "<br>");
       } else {
-        return ''
+        return "";
       }
     },
   },
-}
+};
 </script>
 
 <style lang="scss" scoped>
+* {
+  font-size: 12px;
+}
 </style>

+ 22 - 13
src/views/process/examinationApproval/index.vue

@@ -180,24 +180,33 @@ export default {
       if (this.startStatus) {
         this.$refs.make.$refs.ruleForm.validate((valid) => {
           if (valid) {
-            if (this.transferParams.flowCode === "PURCHASE_CONTRACT") {
-              const data = this.$refs.make.form;
-              sendPurchase(data).then(
-                () => {
-                  this.msgSuccess("发起成功");
-                  this.clickCancel();
-                },
-                (err) => {
-                  console.log("sendPurchase: " + err);
-                }
-              );
+            if (this.transferParams.flowCode === "PURCHASE") {
+              const flag = this.$refs.make.handleSubmit();
+              if (flag) {
+                const data = this.$refs.make.form;
+                const goodsList = data.goodsList.map((x) => ({
+                  id: x.id,
+                  unitPrice: x.unitPrice,
+                  quantity: x.quantity,
+                }));
+                data.goodsList = goodsList;
+                sendPurchase(data).then(
+                  () => {
+                    this.msgSuccess("发起成功");
+                    this.clickCancel();
+                  },
+                  (err) => {
+                    console.log("sendPurchase: " + err);
+                  }
+                );
+              }
             }
           }
         });
       } else {
         this.$refs.ruleForm.validate((valid) => {
           if (valid) {
-            if (this.transferParams.flowCode === "PURCHASE_CONTRACT") {
+            if (this.transferParams.flowCode === "PURCHASE") {
               purchaseApproval({
                 id: this.transferParams.id,
                 buttonId: ID,
@@ -217,7 +226,7 @@ export default {
       }
     },
     clickCancel() {
-      if (this.transferParams.flowCode === "PURCHASE_CONTRACT") {
+      if (this.transferParams.flowCode === "PURCHASE") {
         this.$router.replace({
           path: "/purchase-management/purchase/index",
         });

+ 1 - 1
src/views/purchase-management/deliver-goods/index.vue

@@ -307,7 +307,7 @@ export default {
         query: {
           id: row.id,
           processInstanceId: row.processInstanceId || "",
-          flowCode: "PURCHASE_CONTRACT",
+          flowCode: "PURCHASE",
         },
       });
     },

+ 4 - 1
src/views/purchase-management/purchase/addPurchase.vue

@@ -228,7 +228,10 @@ export default {
           const data = [...this.form.goodsList];
           for (let i = 0; i < data.length; i++) {
             const e = data[i];
-            if (Number(e.assw) + Number(e.quantity) > Number(e.quantity)) {
+            if (
+              Number(e.purchaseQuantity) + Number(e.quantity) >
+              Number(e.quantityOne)
+            ) {
               return this.msgInfo("此次采购数量和已采购数量合不可大于采购数量");
             }
           }

+ 1 - 1
src/views/purchase-management/purchase/index.vue

@@ -198,7 +198,7 @@ export default {
         query: {
           id: "",
           processInstanceId: "",
-          flowCode: "PURCHASE_CONTRACT",
+          flowCode: "PURCHASE",
           detailsData: JSON.stringify({ ...this.form }),
         },
       });