cz 2 жил өмнө
parent
commit
2bf833623a

+ 13 - 8
src/components/WDLY/process/SendPurchaseWDLY.vue

@@ -95,17 +95,17 @@
           style="margin: 10px 0"
           v-if="ids.length == 0"
         >
-          添加
+          添加
         </el-button>
         <el-table :data="formData.data.purchaseDetailList">
           <el-table-column
             prop="goodType"
-            label="品类型"
+            label="品类型"
             :formatter="(row) => (row.goodType == 1 ? '产品' : '物料')"
           />
-          <el-table-column prop="productCode" label="品编码" />
-          <el-table-column prop="productName" label="品名称" />
-          <el-table-column prop="productSpec" label="规格型号" />
+          <el-table-column prop="productCode" label="品编码" />
+          <el-table-column prop="productName" label="品名称" />
+          <!-- <el-table-column prop="productSpec" label="规格型号" /> -->
           <el-table-column prop="productUnit" label="单位" />
           <el-table-column
             prop="subscribeCount"
@@ -200,7 +200,6 @@
             <template #default="{ row, $index }">
               <el-form-item
                 :prop="'otherFeeList.' + $index + '.remark'"
-                :rules="rules.remark"
                 :inline-message="true"
               >
                 <el-input v-model="row.remark" placeholder="请输入" />
@@ -216,9 +215,10 @@
           </el-table-column>
         </el-table>
       </el-form-item>
+      <div class="_t" style="margin-bottom: 15px">采购总金额</div>
       <el-row>
         <el-col :span="4">
-          <el-form-item label="采购金额" prop="amount">
+          <el-form-item label="采购金额" prop="amount">
             <el-input
               v-model="formData.data.amount"
               placeholder="请输入"
@@ -228,7 +228,12 @@
         </el-col>
       </el-row>
     </el-form>
-    <el-dialog v-model="openProduct" title="选择货品" width="70%" append-to-body>
+    <el-dialog
+      v-model="openProduct"
+      title="选择物品"
+      width="70%"
+      append-to-body
+    >
       <SelectGoods
         @cancel="openProduct = false"
         @pushGoods="pushGoods"

+ 21 - 9
src/components/byTable/index.vue

@@ -23,7 +23,7 @@
       <div style="display: flex">
         <div
           class="by-dropdown"
-          v-for="(i,index) in selectConfigCopy"
+          v-for="(i, index) in selectConfigCopy"
           :key="i.prop"
           style="margin-right: 10px"
         >
@@ -36,9 +36,13 @@
           </div>
           <ul class="by-dropdown-lists">
             <li
-              @click="searchItemSelct('all', i,index)"
+              @click="searchItemSelct('all', i, index)"
               v-if="i.isShowAll === false ? i.isShowAll : true"
-              style="display: flex; align-items: center; justify-content: center;"
+              style="
+                display: flex;
+                align-items: center;
+                justify-content: center;
+              "
             >
               全部
             </li>
@@ -46,7 +50,11 @@
               v-for="j in i.data"
               :key="j.value"
               @click="searchItemSelct(j, i)"
-              style="display: flex; align-items: center; justify-content: center;"
+              style="
+                display: flex;
+                align-items: center;
+                justify-content: center;
+              "
             >
               {{ j.label }}
             </li>
@@ -270,7 +278,7 @@ export default defineComponent({
     const keywrod = ref("");
     const selectConfigCopy = computed(() => {
       return props.selectConfig.map((item) => {
-        if(!item.labelCopy) item.labelCopy = {...item}.label;
+        if (!item.labelCopy) item.labelCopy = { ...item }.label;
         return item;
       });
     });
@@ -385,9 +393,9 @@ export default defineComponent({
     };
     //下拉搜索相关
 
-    const searchItemSelct = (item, i,index) => {
+    const searchItemSelct = (item, i, index) => {
       if (item == "all") {
-        i.label = {...props.selectConfig[index]}.labelCopy
+        i.label = { ...props.selectConfig[index] }.labelCopy;
         proxy.$emit(
           "getList",
           Object.assign(props.filterParams, { [i.prop]: "" })
@@ -450,6 +458,10 @@ export default defineComponent({
   margin: 0 !important;
   padding: 8px 6px !important;
 }
+.el-checkbox__input.is-disabled .el-checkbox__inner {
+  background-color: #dee1e6;
+  border-color: #b2b4b9;
+}
 </style>
   <style lang="scss" scoped>
 .by-search {
@@ -473,7 +485,7 @@ export default defineComponent({
   ul {
     position: absolute;
     left: 0;
-    
+
     top: 32px;
     padding: 0;
     margin: 0;
@@ -553,6 +565,6 @@ export default defineComponent({
 .by-dropdown-lists {
   max-height: 50vh;
   overflow-y: auto;
-  line-height: 1
+  line-height: 1;
 }
 </style>

+ 1 - 4
src/components/product/SelectGoods.vue

@@ -107,10 +107,7 @@ const config = computed(() => {
     {
       attrs: {
         label: "所属分类",
-        prop: "",
-      },
-      render(type) {
-        return sourceList.value.pagination.definition == 1 ? "产品" : "物料";
+        prop: "classifyName",
       },
     },
     {

+ 5 - 2
src/utils/util.js

@@ -1,6 +1,9 @@
 import moment from "moment";
 
-import { post, get } from "@/utils/request";
+import {
+  post,
+  get
+} from "@/utils/request";
 import Cookies from "js-cookie";
 
 //根据value值回显字典label值
@@ -100,4 +103,4 @@ export function calculationWeek(val, format) {
   let index = new Date(moment(val, format).format("yyyy-MM-DD")).getDay();
   let week = weekArrayList[index];
   return week;
-}
+}

+ 40 - 49
src/views/WDLY/basic/product/index.vue

@@ -323,42 +323,31 @@ let rules = ref({
   ],
 });
 const { proxy } = getCurrentInstance();
-const selectConfig = computed(() => {
-  return [
-    {
-      label: "产品类型",
-      prop: "type",
-      data: [
-        {
-          label: "成品",
-          value: "1",
-        },
-        {
-          label: "半成品",
-          value: "2",
-        },
-      ],
-    },
-    {
-      label: "生命周期",
-      prop: "lifeCycle",
-      data: [
-        {
-          label: "新品",
-          value: "1",
-        },
-        {
-          label: "成长",
-          value: "2",
-        },
-        {
-          label: "成熟",
-          value: "3",
-        },
-      ],
-    },
-  ];
-});
+const selectConfig = reactive([
+  {
+    label: "产品类型",
+    prop: "type",
+    data: [],
+  },
+  {
+    label: "生命周期",
+    prop: "lifeCycle",
+    data: [
+      {
+        label: "新品",
+        value: "1",
+      },
+      {
+        label: "成长",
+        value: "2",
+      },
+      {
+        label: "成熟",
+        value: "3",
+      },
+    ],
+  },
+]);
 const config = computed(() => {
   return [
     {
@@ -367,7 +356,7 @@ const config = computed(() => {
         prop: "type",
       },
       render(type) {
-        return type == 1 ? "成品" : type == 2 ? "半成品" : "";
+        return proxy.dictDataEcho(type, productType.value);
       },
     },
     {
@@ -541,16 +530,7 @@ const formConfig = computed(() => {
       prop: "type",
       label: "产品类型",
       required: true,
-      data: [
-        {
-          label: "成品",
-          id: "1",
-        },
-        {
-          label: "半成品",
-          id: "2",
-        },
-      ],
+      data: [],
     },
     {
       type: "input",
@@ -716,7 +696,7 @@ const openModal = () => {
   modalType.value = "add";
   formData.data = {
     definition: "1",
-    type: "1",
+    // type: "1",
     fileList: [],
     combination: "1",
     victoriatouristJson: {
@@ -955,9 +935,20 @@ const submitMove = () => {
 };
 
 const productUnit = ref([]);
+const productType = ref([]);
+
 const getDict = () => {
-  proxy.getDict(["unit"]).then((res) => {
+  proxy.getDict(["unit", "product_type"]).then((res) => {
     productUnit.value = res["unit"];
+    productType.value = res["product_type"];
+    formConfig.value[1].data = productType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    selectConfig[0].data = productType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
   });
 };
 getDict();

+ 31 - 13
src/views/WDLY/basic/supplier/index.vue

@@ -34,6 +34,7 @@
       v-model="dialogVisible"
       width="800"
       v-loading="loading"
+      destroy-on-close
     >
       <byForm
         :formConfig="formConfig"
@@ -55,6 +56,7 @@
                     v-for="item in countryData"
                     :label="item.chineseName"
                     :value="item.id"
+                    :key="item.id"
                   >
                   </el-option>
                 </el-select>
@@ -71,6 +73,7 @@
                     v-for="item in provinceData"
                     :label="item.name"
                     :value="item.id"
+                    :key="item.id"
                   >
                   </el-option>
                 </el-select>
@@ -83,6 +86,7 @@
                     v-for="item in cityData"
                     :label="item.name"
                     :value="item.id"
+                    :key="item.id"
                   >
                   </el-option>
                 </el-select>
@@ -215,12 +219,16 @@ let rules = ref({
   countryId: [{ required: true, message: "请选择国家", trigger: "change" }],
   provinceId: [{ required: true, message: "请选择省/洲", trigger: "change" }],
   cityId: [{ required: true, message: "请选择城市", trigger: "change" }],
-  areaDetail: [{ required: true, message: "请输入详细地址", trigger: "blur" }],
+  // areaDetail: [{ required: true, message: "请输入详细地址", trigger: "blur" }],
   contactPerson: [{ required: true, message: "请输入联系人", trigger: "blur" }],
   // contactNumber: [{ validator: checkContactNumber, trigger: "blur" }],
   contactNumber: [
     { required: true, message: "请输入联系电话", trigger: "blur" },
   ],
+  accountPeriod: [{ required: true, message: "请输入账期", trigger: "blur" }],
+  returnPeriod: [
+    { required: true, message: "请输入退换货期限", trigger: "blur" },
+  ],
 });
 const { proxy } = getCurrentInstance();
 const selectConfig = reactive([
@@ -261,7 +269,7 @@ const config = computed(() => {
         prop: "type",
       },
       render(type) {
-        return type === 1 ? "贸易商" : "工厂";
+        return proxy.dictDataEcho(type, supplierType.value);
       },
     },
     {
@@ -393,10 +401,10 @@ const formConfig = computed(() => {
       label: "供应商类型",
       required: true,
       border: true,
-      data: [
-        { label: "贸易商", value: "1" },
-        { label: "工厂", value: "2" },
-      ],
+      data: supplierType.value.map((x) => ({
+        label: x.dictValue,
+        value: x.dictKey,
+      })),
     },
     {
       type: "input",
@@ -516,7 +524,6 @@ const openModal = () => {
   fileList.value = [];
   fileListCopy.value = [];
   formData.data = {
-    type: "1",
     countryId: "China",
     victoriatouristJson: {},
   };
@@ -555,6 +562,9 @@ const getDtl = (row) => {
     proxy
       .post("/fileInfo/getList", { businessIdList: [row.id] })
       .then((fileObj) => {
+        console.log(fileObj[row.id], "wss");
+        console.log(res, "wss11");
+
         fileList.value = fileObj[row.id] || [];
         fileListCopy.value = [...fileList.value];
         getCityData(res.countryId, "20");
@@ -594,12 +604,12 @@ const handleClickFile = (row) => {
 };
 
 const handleClose = (index) => {
-  if (fileListCopy.value.length === 1) {
-    return ElMessage({
-      message: "最后一个附件啦!",
-      type: "info",
-    });
-  }
+  // if (fileListCopy.value.length === 1) {
+  //   return ElMessage({
+  //     message: "最后一个附件啦!",
+  //     type: "info",
+  //   });
+  // }
   fileList.value.splice(index, 1);
   fileListCopy.value.splice(index, 1);
 };
@@ -626,6 +636,14 @@ const getCityData = (id, type, isChange) => {
     }
   });
 };
+const supplierType = ref([]);
+const getDict = () => {
+  proxy.getDict(["supplier_type"]).then((res) => {
+    supplierType.value = res["supplier_type"];
+    console.log(res, "qsss");
+  });
+};
+getDict();
 getCityData("0");
 getList();
 </script>

+ 54 - 46
src/views/WDLY/outInBound/logistics/index.vue

@@ -65,11 +65,11 @@
               <el-table-column
                 prop="productType"
                 label="货品类型"
-                :formatter="(row) => (row.productType == 1 ? '产品' : '物料')"
+                :formatter="(row) => '产品'"
               />
               <el-table-column prop="productCode" label="货品编码" />
               <el-table-column prop="productName" label="货品名称" />
-              <el-table-column prop="productSpec" label="规格型号" />
+              <!-- <el-table-column prop="productSpec" label="规格型号" /> -->
               <el-table-column prop="productUnit" label="单位" />
               <el-table-column prop="count" label="采购数量" />
               <el-table-column prop="transitQuantity" label="剩余在途" />
@@ -91,7 +91,13 @@
       </template>
     </el-dialog>
 
-    <el-dialog title="物流数据" v-model="openRecord" width="40%" top="50px">
+    <el-dialog
+      title="物流数据"
+      v-model="openRecord"
+      width="40%"
+      top="50px"
+      destroy-on-close
+    >
       <!-- <div style="padding-left: 40px; margin-bottom: 20px">
         <el-button size="mini" @click="handleAddRecord">
           添加物流记录
@@ -109,6 +115,9 @@
           </el-timeline-item>
         </el-timeline>
       </div>
+      <template #footer>
+        <el-button @click="openRecord = false" size="large">关闭</el-button>
+      </template>
     </el-dialog>
   </div>
 </template>
@@ -391,8 +400,9 @@ const formConfigOne = reactive([
   {
     type: "select",
     label: "物流/快递单号",
-    prop: "deliverGoodsId",
+    prop: "code",
     itemWidth: 50,
+    disabled: true,
     style: {
       width: "100%",
     },
@@ -523,63 +533,61 @@ const getLogisticsData = (row) => {
 const handleClickCode = (row) => {
   let id = row.id;
   proxy.post("/logisticsInfos/getLogistics", { id }).then((res) => {
-    activities.value = res.data ? res.data : [];
-    openRecord.value = true;
+    if (res.data && res.data.length > 0) {
+      activities.value = res.data;
+      openRecord.value = true;
+    } else {
+      return ElMessage({
+        message: res.message,
+        type: "info",
+      });
+    }
   });
 };
 const deliverData = ref([]);
 const handleArrival = (row) => {
   modalType.value = "other";
-  proxy.post("/deliverGoods/list", { id: row.businessId }).then((res) => {
-    deliverData.value = res;
-
-    formConfig[2].data = res.map((x) => ({
-      ...x,
-      label: x.code,
-      value: x.id,
-    }));
+  proxy.post("/deliverGoods/detail", { id: row.businessId }).then((res) => {
     formData.data = {
       businessId: row.id,
       supplyName: row.supplyName,
       purchaseCode: row.businessCode,
       supplyId: row.supplyId,
-      code: "",
-      logisticsCompanyCode: "",
-      deliverGoodsId: "",
-      arrivalDetailList: [],
+      code: row.code,
+      logisticsCompanyCode: row.logisticsCompanyCode,
+      deliverGoodsId: row.deliverGoodsId,
+      arrivalDetailList: res.map((x) => ({
+        count: x.count,
+        productName: x.name,
+        productSpec: x.spec,
+        productUnit: x.unit,
+        productType: x.type,
+        productCode: x.code,
+        bussinessId: x.id,
+        purchaseDetailId: x.purchaseDetailId,
+        deliverGoodsDetailsId: x.deliverGoodsId,
+        transitQuantity: x.transitQuantity,
+        deliverGoodsQuantity: x.deliverGoodsQuantity,
+      })),
     };
     dialogVisible.value = true;
   });
 };
 
-watch(
-  () => formData.data.deliverGoodsId,
-  (val) => {
-    if (val) {
-      const current = deliverData.value.find((x) => x.id === val);
-      formData.data.logisticsCompanyCode = current
-        ? current.logisticsCompanyCode
-        : "";
-      formData.data.code = current ? current.code : "";
-      // formData.data.logisticsCompanyName = current ? current.logisticsCompanyCode : "";
-      proxy.post("/deliverGoods/detail", { id: val }).then((res) => {
-        formData.data.arrivalDetailList = res.map((x) => ({
-          count: x.count,
-          productName: x.name,
-          productSpec: x.spec,
-          productUnit: x.unit,
-          productType: x.type,
-          productCode: x.code,
-          bussinessId: x.id,
-          purchaseDetailId: x.purchaseDetailId,
-          deliverGoodsDetailsId: x.deliverGoodsId,
-          transitQuantity: x.transitQuantity,
-          deliverGoodsQuantity: x.deliverGoodsQuantity,
-        }));
-      });
-    }
-  }
-);
+// watch(
+//   () => formData.data.deliverGoodsId,
+//   (val) => {
+//     if (val) {
+//       const current = deliverData.value.find((x) => x.id === val);
+//       formData.data.logisticsCompanyCode = current
+//         ? current.logisticsCompanyCode
+//         : "";
+//       formData.data.code = current ? current.code : "";
+//       // formData.data.logisticsCompanyName = current ? current.logisticsCompanyCode : "";
+
+//     }
+//   }
+// );
 
 getList();
 getLogisticsData();

+ 1 - 1
src/views/WDLY/outInBound/transfer/index.vue

@@ -478,7 +478,7 @@ const warehouseListData = () => {
   proxy
     .post("/warehouse/page", {
       pageNum: 1,
-      pageSize: 10,
+      pageSize: 999,
     })
     .then((message) => {
       warehouseList.value = message.rows;

+ 16 - 7
src/views/WDLY/purchaseManage/alreadyPurchase/index.vue

@@ -49,11 +49,11 @@
             >
               <el-table-column
                 prop="productType"
-                label="品类型"
+                label="品类型"
                 :formatter="(row) => (row.productType == 1 ? '产品' : '物料')"
               />
-              <el-table-column prop="productCode" label="品编码" />
-              <el-table-column prop="productName" label="品名称" />
+              <el-table-column prop="productCode" label="品编码" />
+              <el-table-column prop="productName" label="品名称" />
               <el-table-column prop="productSpec" label="规格型号" />
               <el-table-column prop="productUnit" label="单位" />
               <el-table-column prop="count" label="采购数量" />
@@ -220,8 +220,8 @@ const config = computed(() => {
     },
     {
       attrs: {
-        label: "收仓库",
-        prop: "supplyName",
+        label: "收仓库",
+        prop: "",
       },
     },
     {
@@ -334,6 +334,10 @@ let formConfig = reactive([]);
 const configData = [
   [
     {
+      type: "title",
+      title: "基础信息",
+    },
+    {
       type: "input",
       prop: "supplyName",
       label: "供应商",
@@ -360,6 +364,7 @@ const configData = [
       type: "input",
       label: " ",
       prop: "code",
+      placeholder: "物流/快递单号",
       itemWidth: 50,
     },
     {
@@ -370,6 +375,10 @@ const configData = [
   ],
   [
     {
+      type: "title",
+      title: "基础信息",
+    },
+    {
       type: "input",
       prop: "supplyName",
       label: "供应商",
@@ -537,7 +546,7 @@ const handleArrival = (row, type) => {
   modalType.value = type;
   if (type === "add") {
     formConfig = configData[0];
-    formConfig[2].data = logisticsData.value.map((x) => ({
+    formConfig[3].data = logisticsData.value.map((x) => ({
       label: x.name,
       value: x.code,
     }));
@@ -562,7 +571,7 @@ const handleArrival = (row, type) => {
     formConfig = configData[1];
     proxy.post("/deliverGoods/list", { id: row.id }).then((res) => {
       deliverData.value = res;
-      formConfig[2].data = res.map((x) => ({
+      formConfig[3].data = res.map((x) => ({
         ...x,
         label: x.code,
         value: x.id,

+ 25 - 21
src/views/WDLY/purchaseManage/purchase/index.vue

@@ -180,20 +180,11 @@ const selectConfig = reactive([
       },
     ],
   },
-  // {
-  //   label: "收获仓库",
-  //   prop: "status",
-  //   data: [
-  //     {
-  //       label: "待采购",
-  //       value: "15",
-  //     },
-  //     {
-  //       label: "部分采购",
-  //       value: "30",
-  //     },
-  //   ],
-  // },
+  {
+    label: "收获仓库",
+    prop: "receiptWarehouseName",
+    data: [],
+  },
 ]);
 const config = computed(() => {
   return [
@@ -233,12 +224,6 @@ const config = computed(() => {
     },
     {
       attrs: {
-        label: "规格",
-        prop: "productSpec",
-      },
-    },
-    {
-      attrs: {
         label: "单位",
         prop: "productUnit",
       },
@@ -257,7 +242,7 @@ const config = computed(() => {
     },
     {
       attrs: {
-        label: "收仓库",
+        label: "收仓库",
         prop: "receiptWarehouseName",
       },
     },
@@ -514,9 +499,28 @@ const start = (type) => {
     query: {
       flowKey: "wdly_purchase",
       ids,
+      flowName: "采购申请",
     },
   });
 };
+
+const warehouseList = ref([]);
+const warehouseListData = () => {
+  // // 币种数据
+  proxy
+    .post("/warehouse/page", {
+      pageNum: 1,
+      pageSize: 999,
+    })
+    .then((message) => {
+      warehouseList.value = message.rows;
+      selectConfig[1].data = message.rows.map((x) => ({
+        label: x.name,
+        value: x.id,
+      }));
+    });
+};
+warehouseListData();
 </script>
   
 <style lang="scss" scoped>

+ 12 - 6
src/views/WDLY/purchaseManage/subscribe/index.vue

@@ -253,6 +253,12 @@ const config = computed(() => {
     },
     {
       attrs: {
+        label: "审批状态",
+        prop: "count11",
+      },
+    },
+    {
+      attrs: {
         label: "状态",
         prop: "status",
       },
@@ -260,12 +266,12 @@ const config = computed(() => {
         return statusData.value.find((x) => x.value == status).label;
       },
     },
-    {
-      attrs: {
-        label: "申购原因",
-        prop: "subscribeContent",
-      },
-    },
+    // {
+    //   attrs: {
+    //     label: "申购原因",
+    //     prop: "subscribeContent",
+    //   },
+    // },
     {
       attrs: {
         label: "操作",

+ 8 - 2
src/views/WDLY/salesMange/afterSale/index.vue

@@ -134,7 +134,6 @@
                 <template #default="{ row, $index }">
                   <el-form-item
                     :prop="'afterSaleDetailList.' + $index + '.remark'"
-                    :rules="rules.remark"
                     :inline-message="true"
                   >
                     <el-input v-model="row.remark" placeholder="请输入" />
@@ -238,6 +237,9 @@
           </el-timeline-item>
         </el-timeline>
       </div>
+      <template #footer>
+        <el-button @click="dialogVisibleOne = false">关闭</el-button>
+      </template>
     </el-dialog>
   </div>
 </template>
@@ -302,7 +304,7 @@ let rules = ref({
   ],
   cause: [{ required: true, message: "请输入售后原因", trigger: "blur" }],
   quantity: [{ required: true, message: "请输入数量", trigger: "blur" }],
-  remark: [{ required: true, message: "请输入备注", trigger: "blur" }],
+  remark: [{ required: true, message: "请输入跟进记录", trigger: "blur" }],
 
   status: [{ required: true, message: "请选择售后状态", trigger: "change" }],
   handleTime: [
@@ -412,6 +414,10 @@ const byform = ref(null);
 const configData = [
   [
     {
+      type: "title",
+      title: "售后信息",
+    },
+    {
       type: "select",
       prop: "type",
       label: "售后类型",

+ 16 - 3
src/views/WDLY/salesMange/jdOrder/index.vue

@@ -37,7 +37,7 @@
         <template #address="{ item }">
           <div>
             {{ item.countryName }}, {{ item.provinceName }} ,
-            {{ item.cityName }}, {{ item.detailedAddress }}
+            {{ item.cityName }}
           </div>
         </template>
       </byTable>
@@ -260,6 +260,7 @@
         />
       </el-select>
       <div style="margin-top: 20px" v-show="importData.customerId">
+        <div style="margin-bottom: 10px">上传附件</div>
         <el-upload
           action="/dev-api/jdOrder/excelImport"
           :data="importData"
@@ -270,7 +271,7 @@
           :on-error="handleError"
           accept=".xlsx"
         >
-          <el-button type="primary">点击导入</el-button>
+          <el-button type="primary">选择</el-button>
         </el-upload>
       </div>
 
@@ -447,13 +448,19 @@ const config = computed(() => {
     },
     {
       attrs: {
-        label: "详细地址",
+        label: "所在城市",
         prop: "address",
         slot: "address",
       },
     },
     {
       attrs: {
+        label: "详细地址",
+        prop: "detailedAddress",
+      },
+    },
+    {
+      attrs: {
         label: "收货负责人",
         prop: "contactPerson",
       },
@@ -501,6 +508,10 @@ const byform = ref(null);
 const treeData = ref([]);
 const formConfig = reactive([
   {
+    type: "title",
+    title: "基础信息",
+  },
+  {
     type: "select",
     prop: "customerId",
     label: "客户名称",
@@ -534,12 +545,14 @@ const formConfig = reactive([
     prop: "contactPerson",
     label: "收货信息",
     itemWidth: 20,
+    placeholder: "收货负责人",
   },
   {
     type: "input",
     prop: "contactNumber",
     label: " ",
     itemWidth: 30,
+    placeholder: "收货电话",
   },
   {
     type: "slot",

+ 15 - 6
src/views/WDLY/salesMange/jdReGoods/index.vue

@@ -36,10 +36,17 @@
       </byTable>
     </div>
     <el-dialog
-      :title="modalType === 'add' ? '添加退货' : '到货通知'"
+      :title="
+        modalType === 'add'
+          ? '添加退货'
+          : modalType === 'edit'
+          ? '编辑退货'
+          : '退货详情'
+      "
       v-model="dialogVisible"
       width="800"
       v-loading="loading"
+      destroy-on-close
     >
       <byForm
         :formConfig="formConfig"
@@ -56,11 +63,11 @@
               style="margin-bottom: 10px"
               v-if="modalType != 'detail'"
             >
-              添加
+              添加
             </el-button>
             <el-table :data="formData.data.jdBackDetailsList">
-              <el-table-column prop="productCode" label="品编码" />
-              <el-table-column prop="productName" label="品名称" />
+              <el-table-column prop="productCode" label="品编码" />
+              <el-table-column prop="productName" label="品名称" />
               <el-table-column prop="quantity" label="退货数量" min-width="150">
                 <template #default="{ row, $index }">
                   <el-form-item
@@ -380,9 +387,10 @@ let formConfig = reactive([
   },
   {
     type: "select",
-    label: "物流信息",
+    label: "物流/快递信息",
     prop: "logisticsCompanyCode",
     itemWidth: 50,
+    placeholder: "物流/快递公司",
     style: {
       width: "100%",
     },
@@ -392,11 +400,12 @@ let formConfig = reactive([
     label: " ",
     prop: "logisticsCode",
     itemWidth: 50,
+    placeholder: "物流/快递单号",
   },
   {
     type: "slot",
     slotName: "detailSlot",
-    label: "货明细",
+    label: "退货明细",
   },
 ]);
 const configData = [

+ 1 - 1
src/views/WDLY/salesMange/order/index.vue

@@ -116,7 +116,7 @@
               @click="openProduct = true"
               style="margin-bottom: 10px"
             >
-              添加
+              添加
             </el-button>
             <el-table :data="formData.data.orderDetailsList">
               <el-table-column prop="productCode" label="产品编码" />

+ 1 - 0
src/views/connect/E-mail/personalConfig/index.vue

@@ -317,6 +317,7 @@ const getList = async (req) => {
 };
 const openModal = () => {
   modalType.value = "add";
+  formData.data = {};
   formData.data.type = "1";
   formData.data.receiveProtocol = "IMAP";
   formData.data.sendProtocol = "SMTP";

+ 1 - 1
src/views/process/processApproval/index.vue

@@ -3,7 +3,7 @@
     <div class="left-card">
       <div class="top">
         <div class="commons-title title">
-          {{ route.query.flowName || "流程标题" }}
+          {{ route.query.flowName || "流程标题(发起)" }}
         </div>
         <SendSubscribe
           ref="makeDom"

+ 24 - 67
src/views/product/material/index.vue

@@ -54,6 +54,7 @@
       v-model="dialogVisible"
       width="500"
       v-loading="loading"
+      destroy-on-close
     >
       <byForm
         :formConfig="formConfig"
@@ -148,36 +149,13 @@ let rules = ref({
   unit: [{ required: true, message: "请选择单位", trigger: "change" }],
 });
 const { proxy } = getCurrentInstance();
-const selectConfig = computed(() => {
-  return [
-    {
-      label: "物料类型",
-      prop: "type",
-      data: [
-        {
-          label: "原料",
-          value: "1",
-        },
-        {
-          label: "辅料",
-          value: "2",
-        },
-        {
-          label: "配件",
-          value: "3",
-        },
-        {
-          label: "包材",
-          value: "4",
-        },
-        {
-          label: "其他",
-          value: "5",
-        },
-      ],
-    },
-  ];
-});
+const selectConfig = reactive([
+  {
+    label: "物料类型",
+    prop: "type",
+    data: [],
+  },
+]);
 const config = computed(() => {
   return [
     {
@@ -186,7 +164,7 @@ const config = computed(() => {
         prop: "type",
       },
       render(type) {
-        return formConfig.value[1].data.find((x) => x.id == type).label;
+        return proxy.dictDataEcho(type, materialType.value);
       },
     },
     {
@@ -214,7 +192,7 @@ const config = computed(() => {
         prop: "unit",
       },
       render(unit) {
-        proxy.dictDataEcho(unit, materialUnit.value);
+        return proxy.dictDataEcho(unit, materialUnit.value);
       },
     },
     {
@@ -313,28 +291,7 @@ const formConfig = computed(() => {
       prop: "type",
       label: "物料类型",
       required: true,
-      data: [
-        {
-          label: "原料",
-          id: "1",
-        },
-        {
-          label: "辅料",
-          id: "2",
-        },
-        {
-          label: "配件",
-          id: "3",
-        },
-        {
-          label: "包材",
-          id: "4",
-        },
-        {
-          label: "其他",
-          id: "5",
-        },
-      ],
+      data: [],
     },
     {
       type: "input",
@@ -351,16 +308,7 @@ const formConfig = computed(() => {
       prop: "unit",
       label: "单位",
       required: true,
-      data: [
-        {
-          label: "个",
-          id: "个",
-        },
-        {
-          label: "双",
-          id: "双",
-        },
-      ],
+      data: [],
     },
     {
       type: "slot",
@@ -437,7 +385,7 @@ const openModal = () => {
   formData.data = {
     definition: "2",
     fileList: [],
-    type: "1",
+    // type: "1",
   };
   fileList.value = [];
   fileListCopy.value = [];
@@ -537,14 +485,23 @@ const handleClickFile = (file) => {
 };
 
 const materialUnit = ref([]);
+const materialType = ref([]);
 const getDict = () => {
-  proxy.getDict(["material_unit"]).then((res) => {
-    console.log(res, "wsss");
+  proxy.getDict(["material_unit", "material_type"]).then((res) => {
     materialUnit.value = res["material_unit"];
+    materialType.value = res["material_type"];
     formConfig.value[4].data = materialUnit.value.map((x) => ({
       label: x.dictValue,
       value: x.dictKey,
     }));
+    formConfig.value[1].data = materialType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    selectConfig[0].data = materialType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
   });
 };
 getDict();

+ 25 - 30
src/views/product/product/index.vue

@@ -149,24 +149,13 @@ let rules = ref({
   unit: [{ required: true, message: "请选择单位", trigger: "change" }],
 });
 const { proxy } = getCurrentInstance();
-const selectConfig = computed(() => {
-  return [
-    {
-      label: "产品类型",
-      prop: "type",
-      data: [
-        {
-          label: "成品",
-          value: "1",
-        },
-        {
-          label: "半成品",
-          value: "2",
-        },
-      ],
-    },
-  ];
-});
+const selectConfig = reactive([
+  {
+    label: "产品类型",
+    prop: "type",
+    data: [],
+  },
+]);
 const config = computed(() => {
   return [
     {
@@ -175,7 +164,7 @@ const config = computed(() => {
         prop: "type",
       },
       render(type) {
-        return type == 1 ? "成品" : type == 2 ? "半成品" : "";
+        return proxy.dictDataEcho(type, productType.value);
       },
     },
     {
@@ -303,16 +292,7 @@ const formConfig = computed(() => {
       prop: "type",
       label: "产品类型",
       required: true,
-      data: [
-        {
-          label: "成品",
-          id: "1",
-        },
-        {
-          label: "半成品",
-          id: "2",
-        },
-      ],
+      data: [],
     },
     {
       type: "input",
@@ -440,7 +420,7 @@ const openModal = () => {
   modalType.value = "add";
   formData.data = {
     definition: "1",
-    type: "1",
+    // type: "1",
     fileList: [],
     standardJson: {},
   };
@@ -542,6 +522,21 @@ const handleRemove = (file) => {
 const handleClickFile = (file) => {
   window.open(file.fileUrl, "_blank");
 };
+const productType = ref([]);
+const getDict = () => {
+  proxy.getDict(["product_type"]).then((res) => {
+    productType.value = res["product_type"];
+    formConfig.value[1].data = productType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    selectConfig[0].data = productType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+  });
+};
+getDict();
 </script>
   
 <style lang="scss" scoped>

+ 26 - 30
src/views/product/product/index2.vue

@@ -149,24 +149,13 @@ let rules = ref({
   unit: [{ required: true, message: "请选择单位", trigger: "change" }],
 });
 const { proxy } = getCurrentInstance();
-const selectConfig = computed(() => {
-  return [
-    {
-      label: "产品类型",
-      prop: "type",
-      data: [
-        {
-          label: "成品",
-          value: "1",
-        },
-        {
-          label: "半成品",
-          value: "2",
-        },
-      ],
-    },
-  ];
-});
+const selectConfig = reactive([
+  {
+    label: "产品类型",
+    prop: "type",
+    data: [],
+  },
+]);
 const config = computed(() => {
   return [
     {
@@ -175,7 +164,7 @@ const config = computed(() => {
         prop: "type",
       },
       render(type) {
-        return type == 1 ? "成品" : type == 2 ? "半成品" : "";
+        return proxy.dictDataEcho(type, productType.value);
       },
     },
     {
@@ -303,16 +292,7 @@ const formConfig = computed(() => {
       prop: "type",
       label: "产品类型",
       required: true,
-      data: [
-        {
-          label: "成品",
-          id: "1",
-        },
-        {
-          label: "半成品",
-          id: "2",
-        },
-      ],
+      data: [],
     },
     {
       type: "input",
@@ -414,7 +394,7 @@ const openModal = () => {
   modalType.value = "add";
   formData.data = {
     definition: "1",
-    type: "1",
+    // type: "1",
     fileList: [],
     standardJson: {},
   };
@@ -517,6 +497,22 @@ const handleRemove = (file) => {
 const handleClickFile = (file) => {
   window.open(file.fileUrl, "_blank");
 };
+
+const productType = ref([]);
+const getDict = () => {
+  proxy.getDict(["product_type"]).then((res) => {
+    productType.value = res["product_type"];
+    formConfig.value[1].data = productType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+    selectConfig[0].data = productType.value.map((x) => ({
+      label: x.dictValue,
+      value: x.dictKey,
+    }));
+  });
+};
+getDict();
 </script>
   
 <style lang="scss" scoped>

+ 6 - 0
src/views/purchaseManage/purchaseManage/subscribe/index.vue

@@ -234,6 +234,12 @@ const config = computed(() => {
     },
     {
       attrs: {
+        label: "审批状态",
+        prop: "count11",
+      },
+    },
+    {
+      attrs: {
         label: "状态",
         prop: "status",
       },

+ 19 - 11
src/views/purchaseManage/supplier/supplier/index.vue

@@ -247,7 +247,7 @@ const config = computed(() => {
         prop: "type",
       },
       render(type) {
-        return type === 1 ? "贸易商" : "工厂";
+        return proxy.dictDataEcho(type, supplierType.value);
       },
     },
     {
@@ -367,10 +367,10 @@ const formConfig = computed(() => {
       label: "供应商类型",
       required: true,
       border: true,
-      data: [
-        { label: "贸易商", value: "1" },
-        { label: "工厂", value: "2" },
-      ],
+      data: supplierType.value.map((x) => ({
+        label: x.dictValue,
+        value: x.dictKey,
+      })),
     },
     {
       type: "input",
@@ -499,12 +499,12 @@ const handleClickFile = (row) => {
 };
 
 const handleClose = (index) => {
-  if (fileListCopy.value.length === 1) {
-    return ElMessage({
-      message: "最后一个附件啦!",
-      type: "info",
-    });
-  }
+  // if (fileListCopy.value.length === 1) {
+  //   return ElMessage({
+  //     message: "最后一个附件啦!",
+  //     type: "info",
+  //   });
+  // }
   fileList.value.splice(index, 1);
   fileListCopy.value.splice(index, 1);
 };
@@ -531,6 +531,14 @@ const getCityData = (id, type, isChange) => {
     }
   });
 };
+const supplierType = ref([]);
+const getDict = () => {
+  proxy.getDict(["supplier_type"]).then((res) => {
+    supplierType.value = res["supplier_type"];
+    console.log(res, "qsss");
+  });
+};
+getDict();
 getCityData("0");
 getList();
 </script>

+ 107 - 30
src/views/purchaseSales/outAndInWarehouse/warehouseAdjustment/index.vue

@@ -14,32 +14,80 @@
             action: () => openModal(),
           },
         ]"
-        @get-list="getList">
+        @get-list="getList"
+      >
       </byTable>
     </div>
 
-    <el-dialog title="新增调仓" v-if="dialogVisible" v-model="dialogVisible" width="1000" v-loading="loadingDialog">
-      <byForm :formConfig="formConfig" :formOption="formOption" v-model="formData.data" :rules="rules" ref="submit">
+    <el-dialog
+      title="新增调仓"
+      v-if="dialogVisible"
+      v-model="dialogVisible"
+      width="1000"
+      v-loading="loadingDialog"
+    >
+      <byForm
+        :formConfig="formConfig"
+        :formOption="formOption"
+        v-model="formData.data"
+        :rules="rules"
+        ref="submit"
+      >
         <template #details>
           <div style="width: 100%">
-            <el-button type="primary" @click="openProduct = true">添加明细</el-button>
-            <el-table :data="formData.data.list" style="width: 100%; margin-top: 16px">
-              <el-table-column prop="productCode" label="产品编码" width="140" />
-              <el-table-column prop="productName" label="产品名称" min-width="220" />
-              <el-table-column prop="productSpec" label="规格型号" min-width="220" />
-              <el-table-column prop="productUnit" label="单位" width="100" />
-              <el-table-column label="入库数量" width="160">
+            <el-button type="primary" @click="openProduct = true"
+              >添加明细</el-button
+            >
+            <el-table
+              :data="formData.data.list"
+              style="width: 100%; margin-top: 16px"
+            >
+              <el-table-column
+                prop="productCode"
+                label="物品编码"
+                width="140"
+              />
+              <el-table-column
+                prop="productName"
+                label="物品名称"
+                min-width="220"
+              />
+              <el-table-column
+                prop="productSpec"
+                label="规格型号"
+                min-width="220"
+              />
+              <!-- <el-table-column prop="productUnit" label="单位" width="100" /> -->
+              <el-table-column label="调仓数量" width="160">
                 <template #default="{ row, $index }">
                   <div style="width: 100%">
-                    <el-form-item :prop="'list.' + $index + '.quantity'" :rules="rules.quantity" :inline-message="true">
-                      <el-input-number v-model="row.quantity" placeholder="请输入数量" style="width: 100%" :precision="0" :controls="false" :min="0" />
+                    <el-form-item
+                      :prop="'list.' + $index + '.quantity'"
+                      :rules="rules.quantity"
+                      :inline-message="true"
+                    >
+                      <el-input-number
+                        v-model="row.quantity"
+                        placeholder="请输入数量"
+                        style="width: 100%"
+                        :precision="0"
+                        :controls="false"
+                        :min="0"
+                      />
                     </el-form-item>
                   </div>
                 </template>
               </el-table-column>
-              <el-table-column align="center" label="操作" width="80" fixed="right">
+              <el-table-column
+                align="center"
+                label="操作"
+                width="80"
+                fixed="right"
+              >
                 <template #default="{ row, $index }">
-                  <el-button type="primary" link @click="handleDelete($index)">删除</el-button>
+                  <el-button type="primary" link @click="handleDelete($index)"
+                    >删除</el-button
+                  >
                 </template>
               </el-table-column>
             </el-table>
@@ -48,12 +96,22 @@
       </byForm>
       <template #footer>
         <el-button @click="dialogVisible = false" size="large">取 消</el-button>
-        <el-button type="primary" @click="submitForm()" size="large">确 定</el-button>
+        <el-button type="primary" @click="submitForm()" size="large"
+          >确 定</el-button
+        >
       </template>
     </el-dialog>
 
-    <el-dialog v-model="openProduct" title="选择商品" width="70%" append-to-body>
-      <SelectGoods @cancel="openProduct = false" @pushGoods="pushGoods"></SelectGoods>
+    <el-dialog
+      v-model="openProduct"
+      title="选择商品"
+      width="70%"
+      append-to-body
+    >
+      <SelectGoods
+        @cancel="openProduct = false"
+        @pushGoods="pushGoods"
+      ></SelectGoods>
     </el-dialog>
   </div>
 </template>
@@ -115,7 +173,7 @@ const config = computed(() => {
     },
     {
       attrs: {
-        label: "调仓库",
+        label: "调仓库",
         prop: "toWarehouseName",
         width: 220,
       },
@@ -189,13 +247,15 @@ const getDict = () => {
 const getList = async (req) => {
   sourceList.value.pagination = { ...sourceList.value.pagination, ...req };
   loading.value = true;
-  proxy.post("/stockJournalDetails/page", sourceList.value.pagination).then((res) => {
-    sourceList.value.data = res.rows;
-    sourceList.value.pagination.total = res.total;
-    setTimeout(() => {
-      loading.value = false;
-    }, 200);
-  });
+  proxy
+    .post("/stockJournalDetails/page", sourceList.value.pagination)
+    .then((res) => {
+      sourceList.value.data = res.rows;
+      sourceList.value.pagination.total = res.total;
+      setTimeout(() => {
+        loading.value = false;
+      }, 200);
+    });
 };
 getDict();
 getList();
@@ -215,7 +275,7 @@ const formData = reactive({
 const formConfig = computed(() => {
   return [
     {
-      label: "基本信息",
+      label: "调仓信息",
     },
     {
       type: "select",
@@ -236,18 +296,24 @@ const formConfig = computed(() => {
     {
       type: "input",
       prop: "remark",
-      label: "调说明",
+      label: "调说明",
       itemType: "textarea",
     },
     {
       type: "slot",
       slotName: "details",
-      label: "入库明细",
+      label: "调仓明细",
     },
   ];
 });
 const rules = ref({
-  warehouseId: [{ required: true, message: "请选择仓库", trigger: "change" }],
+  warehouseId: [
+    { required: true, message: "请选择调出仓库", trigger: "change" },
+  ],
+  toWarehouseId: [
+    { required: true, message: "请选择调入仓库", trigger: "change" },
+  ],
+  quantity: [{ required: true, message: "请输入调仓数量", trigger: "blur" }],
 });
 const openModal = () => {
   formData.data = {
@@ -277,11 +343,22 @@ const pushGoods = (goods) => {
     });
     openProduct.value = false;
   } else {
-    ElMessage("请选择至少一件品");
+    ElMessage("请选择至少一件品");
   }
 };
 const submitForm = () => {
   submit.value.handleSubmit(() => {
+    if (formData.data.warehouseId === formData.data.toWarehouseId)
+      return ElMessage({
+        message: "调出仓库和调入仓库不可一致!",
+        type: "info",
+      });
+
+    if (!formData.data.list.length > 0)
+      return ElMessage({
+        message: "请添加调仓明细",
+        type: "info",
+      });
     loadingDialog.value = true;
     proxy.post("/stock/stockTransfer", formData.data).then(
       () => {