Browse Source

wdly定制需求0.1

cz 2 years ago
parent
commit
393c125e8b

+ 28 - 0
src/views/WDLY/basic/product/index.vue

@@ -392,6 +392,25 @@ const selectConfig = computed(() => [
       },
     ],
   },
+  {
+    label: "是否组合",
+    prop: "combination",
+    data: [
+      {
+        label: "是",
+        value: "1",
+      },
+      {
+        label: "否",
+        value: "0",
+      },
+    ],
+  },
+  {
+    label: "销售状态",
+    prop: "salesStatus",
+    data: salesStatus.value,
+  },
 ]);
 const config = computed(() => {
   return [
@@ -428,6 +447,15 @@ const config = computed(() => {
     },
     {
       attrs: {
+        label: "销售状态",
+        prop: "salesStatus",
+      },
+      render(status) {
+        return proxy.dictValueLabel(status, salesStatus.value);
+      },
+    },
+    {
+      attrs: {
         label: "图片",
         prop: "unit",
         slot: "pic",

+ 30 - 2
src/views/WDLY/outInBound/waitInBound/index.vue

@@ -195,8 +195,8 @@ const config = computed(() => {
     {
       attrs: {
         label: "操作",
-        width: "100",
-        align: "right",
+        width: "140",
+        align: "center",
       },
       // 渲染 el-button,一般用在最后一列。
       renderHTML(row) {
@@ -214,6 +214,34 @@ const config = computed(() => {
                 },
               }
             : {},
+          {
+            attrs: {
+              label: "结束入库",
+              type: "primary",
+              text: true,
+            },
+            el: "button",
+            click() {
+              ElMessageBox.confirm("您确定结束入库吗?", "提示", {
+                confirmButtonText: "确定",
+                cancelButtonText: "取消",
+                type: "warning",
+              }).then(() => {
+                // 删除
+                proxy
+                  .post("/stockWait/endInStock", {
+                    id: row.id,
+                  })
+                  .then((res) => {
+                    ElMessage({
+                      message: "操作成功",
+                      type: "success",
+                    });
+                    getList();
+                  });
+              });
+            },
+          },
         ];
       },
     },

+ 2 - 2
vite.config.js

@@ -39,9 +39,9 @@ export default defineConfig(({
       proxy: {
         // https://cn.vitejs.dev/config/#server-proxy
         '/dev-api': {
-          target: 'http://36.134.91.96:9898/test-api',
+          target: 'http://139.9.102.170:10006/test-api',
           // 正式地址
-          // target:"http://139.159.251.109/prod-api",
+          // target:"http://139.9.102.170/prod-api",
           changeOrigin: true,
           rewrite: (p) => p.replace(/^\/dev-api/, '')
         }