lxf 1 year ago
parent
commit
5df687bb9b

+ 15 - 1
src/views/group/order/management/index.vue

@@ -89,6 +89,7 @@
 import byTable from "/src/components/byTable/index";
 import { ElMessage, ElMessageBox } from "element-plus";
 import { copyText } from "vue3-clipboard";
+import { flowStatus } from "/src/utils/flowStatus";
 import DeliveryNote from "/src/components/order/deliveryNote/index";
 
 const { proxy } = getCurrentInstance();
@@ -180,11 +181,24 @@ const config = computed(() => {
     },
     {
       attrs: {
+        label: "流程状态",
+        prop: "flowStatus",
+        width: 120,
+      },
+      render(val) {
+        return proxy.dictKeyValue(val, flowStatus());
+      },
+    },
+    {
+      attrs: {
         label: "订单状态",
         prop: "status",
         width: 120,
       },
-      render(val) {
+      render(val, row) {
+        if (val == 0 && row.flowStatus !== 2) {
+          return "";
+        }
         return proxy.dictKeyValue(val, proxy.useUserStore().allDict["order_status"]);
       },
     },

+ 22 - 2
src/views/subsidiary/order/management/index.vue

@@ -62,6 +62,7 @@
 import byTable from "/src/components/byTable/index";
 import { ElMessage, ElMessageBox } from "element-plus";
 import refreshStore from "/src/store/modules/refresh";
+import { flowStatus } from "/src/utils/flowStatus";
 
 const { proxy } = getCurrentInstance();
 const sourceList = ref({
@@ -93,6 +94,12 @@ const searchConfig = computed(() => {
     },
     {
       type: "select",
+      prop: "flowStatus",
+      label: "流程状态",
+      data: flowStatus(),
+    },
+    {
+      type: "select",
       prop: "status",
       dictKey: "order_status",
       label: "订单状态",
@@ -137,11 +144,24 @@ const config = computed(() => {
     },
     {
       attrs: {
+        label: "流程状态",
+        prop: "flowStatus",
+        width: 120,
+      },
+      render(val) {
+        return proxy.dictKeyValue(val, flowStatus());
+      },
+    },
+    {
+      attrs: {
         label: "订单状态",
         prop: "status",
         width: 120,
       },
-      render(val) {
+      render(val, row) {
+        if (val == 0 && row.flowStatus !== 2) {
+          return "";
+        }
         return proxy.dictKeyValue(val, proxy.useUserStore().allDict["order_status"]);
       },
     },
@@ -320,7 +340,7 @@ const config = computed(() => {
                 },
               }
             : {},
-          row.status == 0
+          row.status == 0 && row.flowStatus !== 1 && row.flowStatus !== 2
             ? {
                 attrs: {
                   label: "编辑",