فهرست منبع

出入库相关页面

cz 2 سال پیش
والد
کامیت
578a8a8b98
36فایلهای تغییر یافته به همراه4524 افزوده شده و 220 حذف شده
  1. 13 0
      src/api/inbound-outbound/inbound/manualInbound.js
  2. 26 0
      src/api/inbound-outbound/inbound/purchaseInbound.js
  3. 23 0
      src/api/inbound-outbound/manualOutbound.js
  4. 33 0
      src/api/inbound-outbound/transfer.js
  5. 57 0
      src/api/order-management/afterSales/index.js
  6. 30 4
      src/api/purchase-management/deliver-goods/index.js
  7. 9 0
      src/api/purchase-management/purchase/index.js
  8. 8 1
      src/api/system/common.js
  9. 61 21
      src/components/inbound-outbound/addOutbound.vue
  10. 94 0
      src/components/order/details.vue
  11. 116 11
      src/router/page/index.js
  12. 183 0
      src/views/inbound-outbound/abnormalManage/addInspection.vue
  13. 258 0
      src/views/inbound-outbound/abnormalManage/index.vue
  14. 219 0
      src/views/inbound-outbound/arrivalInspection/addInspection.vue
  15. 243 0
      src/views/inbound-outbound/arrivalInspection/index.vue
  16. 0 0
      src/views/inbound-outbound/cgInbound.vue
  17. 22 20
      src/views/inbound-outbound/inbound/cgInbound/index.vue
  18. 237 0
      src/views/inbound-outbound/inbound/cgInbound/purchaseInbound.vue
  19. 262 0
      src/views/inbound-outbound/inbound/manualInbound/addManualInbound.vue
  20. 213 0
      src/views/inbound-outbound/inbound/manualInbound/index.vue
  21. 202 0
      src/views/inbound-outbound/outbound/manualOutbound/addManualOutbound.vue
  22. 218 0
      src/views/inbound-outbound/outbound/manualOutbound/index.vue
  23. 0 0
      src/views/inbound-outbound/outbound/salesOutbound/addOutbound.vue
  24. 20 29
      src/views/inbound-outbound/outbound/salesOutbound/index.vue
  25. 274 0
      src/views/inbound-outbound/transfer/index.vue
  26. 247 0
      src/views/inbound-outbound/transfer/sendTransfer.vue
  27. 64 33
      src/views/inventory-management/query/index.vue
  28. 282 0
      src/views/order-management/afterSales/addAfterSales.vue
  29. 331 0
      src/views/order-management/afterSales/index.vue
  30. 101 0
      src/views/process/backlog/index.vue
  31. 210 0
      src/views/process/examinationApproval/approvalRecords.vue
  32. 216 0
      src/views/process/examinationApproval/index.vue
  33. 6 1
      src/views/product-material/product/addProduct.vue
  34. 187 57
      src/views/purchase-management/deliver-goods/index.vue
  35. 46 27
      src/views/purchase-management/deliver-goods/sendGoods.vue
  36. 13 16
      src/views/purchase-management/purchase/index.vue

+ 13 - 0
src/api/inbound-outbound/inbound/manualInbound.js

@@ -0,0 +1,13 @@
+import request from '@/router/axios'
+
+// 手动入库 
+export function manualAdd(data = {}) {
+  return request({
+    url: '/api/victoriatourist/manual/in/stock/add',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+

+ 26 - 0
src/api/inbound-outbound/inbound/purchaseInbound.js

@@ -0,0 +1,26 @@
+import request from '@/router/axios'
+
+// 采购入库列表 
+export function purchaseInboundList(data = {}) {
+  return request({
+    url: '/api/victoriatourist/applyIn/page',
+    method: 'post',
+    data: data,
+  })
+}
+
+// 采购入库 
+export function purchaseAdd(data = {}) {
+  return request({
+    url: '/api/victoriatourist/purchase/in/stock/add',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+
+
+
+
+

+ 23 - 0
src/api/inbound-outbound/manualOutbound.js

@@ -0,0 +1,23 @@
+import request from '@/router/axios'
+
+// 销售出库列表 
+export function manualList(data = {}) {
+  return request({
+    url: '/api/victoriatourist/manualOut/page',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+// 手动出库 
+export function manualOutbound(data = {}) {
+  return request({
+    url: '/api/victoriatourist/manualOut/add',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+

+ 33 - 0
src/api/inbound-outbound/transfer.js

@@ -0,0 +1,33 @@
+import request from '@/router/axios'
+
+// 调仓列表 
+export function transferList(data = {}) {
+  return request({
+    url: '/api/victoriatourist/stockTransfer/page',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+
+// 调仓
+export function sendTransfer(data = {}) {
+  return request({
+    url: '/api/victoriatourist/stockTransfer/add',
+    method: 'post',
+    data: data,
+  })
+}
+
+// 接收
+export function receive(data = {}) {
+  return request({
+    url: '/api/victoriatourist/stockTransfer/receive',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+

+ 57 - 0
src/api/order-management/afterSales/index.js

@@ -0,0 +1,57 @@
+import request from '@/router/axios'
+
+// 售后列表 
+export function afterSalesList(data = {}) {
+  return request({
+    url: '/api/victoriatourist/afterSales/page',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+
+// 添加afterSales 
+export function afterSalesAdd(data = {}) {
+  return request({
+    url: '/api/victoriatourist/afterSales/add',
+    method: 'post',
+    data: data,
+  })
+}
+// 客户下拉框
+export function customerSelectData(data = {}) {
+  return request({
+    url: '/api/victoriatourist/customerInfo/list',
+    method: 'post',
+    data: data,
+  })
+}
+
+// 根据客户id查询订单编号 
+export function getOrderCode(data = {}) {
+  return request({
+    url: '/api/victoriatourist/orderSales/getOrderByCustomerId',
+    method: 'post',
+    data: data,
+  })
+}
+
+// 根据订单id查询订单详情 
+export function getOrderDetails(data = {}) {
+  return request({
+    url: '/api/victoriatourist/orderSales/getDetails',
+    method: 'post',
+    data: data,
+  })
+}
+
+//跟进
+export function afterSalesFollow(data = {}) {
+  return request({
+    url: '/api/victoriatourist/afterSales/followUp',
+    method: 'post',
+    data: data,
+  })
+}
+

+ 30 - 4
src/api/purchase-management/deliver-goods/index.js

@@ -9,8 +9,8 @@ export function deliveryList(data = {}) {
   })
 }
 
-// 发货
-export function deliveryAdd(data = {}) {
+// 发货通知
+export function deliveryNotice(data = {}) {
   return request({
     url: '/api/victoriatourist/logisticsInfo/add',
     method: 'post',
@@ -18,11 +18,19 @@ export function deliveryAdd(data = {}) {
   })
 }
 
+// 到货通知
+export function arrivalNotice(data = {}) {
+  return request({
+    url: '/api/victoriatourist/logisticsInfo/arrival/notice',
+    method: 'post',
+    data: data,
+  })
+}
 
 // 完成采购
-export function completePurchase(data = {}) {
+export function purchaseEnd(data = {}) {
   return request({
-    url: '/api/victoriatourist/purchase/complete',
+    url: '/api/victoriatourist/purchase/end',
     method: 'post',
     data: data,
   })
@@ -37,5 +45,23 @@ export function purchaseDetails(data = {}) {
   })
 }
 
+// 取消
+export function purchaseCancel(data = {}) {
+  return request({
+    url: '/api/victoriatourist/purchase/cancel',
+    method: 'post',
+    data: data,
+  })
+}
+
+//物流单号下拉框
+export function logisticsSelectData(data = {}) {
+  return request({
+    url: '/api/victoriatourist/logisticsInfo/code/select',
+    method: 'post',
+    data: data,
+  })
+}
+
 
 

+ 9 - 0
src/api/purchase-management/purchase/index.js

@@ -46,3 +46,12 @@ export function purchaseDetails(data = {}) {
   })
 }
 
+// purchase 物流单号下拉框
+export function logisticsSelectData(data = {}) {
+  return request({
+    url: '/api/victoriatourist/logisticsInfo/code/select',
+    method: 'post',
+    data: data,
+  })
+}
+

+ 8 - 1
src/api/system/common.js

@@ -15,6 +15,13 @@ export function getRegionData(data) {
     data: data
   })
 }
-
+//物流公司
+export function getLogisticsData(data) {
+  return request({
+    url: '/api/victoriatourist/logistics/company/select',
+    method: 'post',
+    data: data
+  })
+}
 
 

+ 61 - 21
src/components/inbound-outbound/addOutbound.vue

@@ -17,7 +17,7 @@
           <el-col :span="4">
             <el-form-item label="订单类型" required>
               <el-select
-                v-model="form.type"
+                v-model="form.orderType"
                 :placeholder="$t('pleaseSelect')"
                 style="width: 100%"
                 disabled
@@ -34,7 +34,7 @@
           </el-col>
         </el-row>
 
-        <el-row>
+        <el-row :gutter="10">
           <el-col :span="6">
             <el-form-item label="仓库名称" prop="warehouseId">
               <el-select
@@ -58,6 +58,23 @@
               </el-select>
             </el-form-item>
           </el-col>
+          <el-col :span="6">
+            <el-form-item label="出库类型" prop="type">
+              <el-select
+                v-model="form.type"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in outboundTypeList"
+                  :key="item.id"
+                  :label="item.dictValue"
+                  :value="item.dictKey"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
         </el-row>
 
         <div style="margin-bottom: 20px">
@@ -91,7 +108,7 @@
               </template>
             </el-table-column>
 
-            <el-table-column
+            <!-- <el-table-column
               :label="$t('operation')"
               width="100"
               align="center"
@@ -101,7 +118,7 @@
                   $t("delete")
                 }}</el-button>
               </template>
-            </el-table-column>
+            </el-table-column> -->
           </el-table>
         </el-form-item>
         <div style="margin-bottom: 20px">
@@ -109,30 +126,26 @@
         </div>
         <el-row :gutter="10">
           <el-col :span="6">
-            <el-form-item label="物流/快递公司">
+            <el-form-item label="物流/快递公司" prop="logisticsCompanyCode">
               <el-select
-                v-model="form.id"
+                v-model="form.logisticsCompanyCode"
                 :placeholder="$t('pleaseSelect')"
                 style="width: 100%"
               >
                 <el-option
-                  v-for="item in orderTypeList"
-                  :key="item.id"
-                  :label="item.dictValue"
-                  :value="item.dictKey"
+                  v-for="item in logisticsData"
+                  :key="item.code"
+                  :label="item.name"
+                  :value="item.code"
                 >
                 </el-option>
               </el-select>
             </el-form-item>
           </el-col>
           <el-col :span="6">
-            <el-form-item
-              label="物流/快递单号"
-              prop="logisticsCompanyCode"
-              required
-            >
+            <el-form-item label="物流/快递单号" prop="logisticsCode" required>
               <el-input
-                v-model="form.logisticsCompanyCode"
+                v-model="form.logisticsCode"
                 placeholder="请输入"
               ></el-input>
             </el-form-item>
@@ -155,6 +168,7 @@
 import labelTitle from "@/components/label-title/index.vue";
 
 import { getToken } from "@/util/auth";
+import { getLogisticsData } from "@/api/system/common.js";
 
 export default {
   name: "addOutbound",
@@ -168,6 +182,10 @@ export default {
       type: Array,
       default: () => [],
     },
+    outboundTypeList: {
+      type: Array,
+      default: () => [],
+    },
     warehouseSelectList: {
       type: Array,
       default: () => [],
@@ -183,6 +201,7 @@ export default {
         Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
         "Blade-Auth": "bearer " + getToken(),
       },
+      logisticsData: [],
       loading: false,
       formRules: {
         changeQuantity: [
@@ -199,19 +218,40 @@ export default {
             trigger: "change",
           },
         ],
-        planArrivalTime: [
+        type: [
+          {
+            required: true,
+            message: "请选择出库类型",
+            trigger: "change",
+          },
+        ],
+        logisticsCompanyCode: [
           {
             required: true,
-            message:
-              this.$t("pleaseSelect") +
-              this.$t("purchase_management.subscribe.askArrivalTime"),
+            message: "请选择物流/快递公司",
             trigger: "change",
           },
         ],
+        logisticsCode: [
+          {
+            required: true,
+            message: "请输入快递单号",
+            trigger: "blur",
+          },
+        ],
       },
     };
   },
-  created() {},
+  created() {
+    getLogisticsData({ keyword: "" }).then(
+      (res) => {
+        this.logisticsData = res.data.data.filter((x, y) => y < 100);
+      },
+      (err) => {
+        console.log("getDeptData:" + err);
+      }
+    );
+  },
   methods: {
     handleSubmit() {
       this.$refs.form.validate((valid) => {

+ 94 - 0
src/components/order/details.vue

@@ -0,0 +1,94 @@
+<template>
+  <div>
+    <el-form :model="form" label-position="left" v-loading="loading">
+      <el-row :gutter="10">
+        <el-col :span="12">
+          <el-form-item label="客户:" prop="customerName">
+            <span>{{ form.customerName }}</span>
+          </el-form-item>
+        </el-col>
+        <el-col :span="10">
+          <el-form-item label="订单类型:" prop="type">
+            <span>
+              {{ dictDataEcho(form.type, orderTypeList) }}
+            </span>
+          </el-form-item>
+        </el-col>
+      </el-row>
+      <div style="margin-bottom: 20px">
+        <labelTitle content="订单明细"></labelTitle>
+      </div>
+      <el-table :data="form.orderDetailsList">
+        <el-table-column label="物品编码" prop="productCode"> </el-table-column>
+        <el-table-column label="物品名称" prop="productName"> </el-table-column>
+        <el-table-column label="物品单位" prop="productUnit"> </el-table-column>
+        <el-table-column label="数量" prop="quantity"> </el-table-column>
+      </el-table>
+      <el-row>
+        <el-col :span="10">
+          <el-form-item label="订单总金额:" prop="amountMoney">
+            {{ form.amountMoney }}
+          </el-form-item>
+        </el-col>
+      </el-row>
+      <div style="margin-bottom: 20px">
+        <labelTitle content="收货信息"></labelTitle>
+      </div>
+      <el-form-item label="收件人:">
+        {{ form.contacts }} , {{ form.phone }}
+      </el-form-item>
+      <el-form-item label="收件地址:">
+        {{ form.countryName }} , {{ form.provinceName }} , {{ form.cityName }} ,
+        {{ form.detailedAddress }}
+      </el-form-item>
+    </el-form>
+  </div>
+</template>
+
+<script>
+import { getOrderDetails } from "@/api/order-management/afterSales/index.js";
+import labelTitle from "@/components/label-title/index.vue";
+
+export default {
+  props: {
+    orderId: {
+      type: String,
+      default: "",
+    },
+  },
+  components: {
+    labelTitle,
+  },
+  data() {
+    return {
+      loading: true,
+      form: {},
+      orderTypeList: [],
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.orderTypeList = businessDictData.find(
+      (item) => item.code === "orderType"
+    ).children;
+  },
+  mounted() {
+    if (this.orderId) {
+      getOrderDetails({ id: this.orderId }).then((res) => {
+        this.form = res.data.data;
+        this.loading = false;
+      });
+    }
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+::v-deep {
+  .el-form-item {
+    margin-bottom: 5px;
+  }
+}
+</style>

+ 116 - 11
src/router/page/index.js

@@ -274,7 +274,7 @@ export default [
     children: [
       {
         path: 'index',
-        name: '采购管理',
+        name: '采购',
         component: () => import(/* webpackChunkName: "page" */ '@/views/purchase-management/purchase/index'),
         props: true,
       },
@@ -287,7 +287,7 @@ export default [
     children: [
       {
         path: 'index',
-        name: '发货管理',
+        name: '已采购',
         component: () => import(/* webpackChunkName: "page" */ '@/views/purchase-management/deliver-goods/index'),
         props: true,
       },
@@ -333,6 +333,19 @@ export default [
     ],
   },
   {
+    path: '/order-management/afterSales',
+    component: Layout,
+    redirect: '/order-management/afterSales/index',
+    children: [
+      {
+        path: 'index',
+        name: '售后管理',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/order-management/afterSales/index'),
+        props: true,
+      },
+    ],
+  },
+  {
     path: '/inventory-management/query',
     component: Layout,
     redirect: '/inventory-management/query/index',
@@ -372,19 +385,33 @@ export default [
     ],
   },
   {
-    path: '/inbound-outbound/cgInbound',
+    path: '/inbound-outbound/inbound/cgInbound',
     component: Layout,
-    redirect: '/inbound-outbound/cgInbound/index',
+    redirect: '/inbound-outbound/inbound/cgInbound/index',
     children: [
       {
         path: 'index',
         name: '采购入库',
-        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/cgInbound/index'),
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/inbound/cgInbound/index'),
         props: true,
       },
     ],
   },
   {
+    path: '/inbound-outbound/inbound/manualInbound',
+    component: Layout,
+    redirect: '/inbound-outbound/inbound/manualInbound/index',
+    children: [
+      {
+        path: 'index',
+        name: '手动入库',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/inbound/manualInbound/index'),
+        props: true,
+      },
+    ],
+  },
+
+  {
     path: '/inbound-outbound/inbound',
     component: Layout,
     redirect: '/inbound-outbound/inbound/qualityTesting',
@@ -398,6 +425,32 @@ export default [
     ],
   },
   {
+    path: '/inbound-outbound/arrivalInspection',
+    component: Layout,
+    redirect: '/inbound-outbound/arrivalInspection/index',
+    children: [
+      {
+        path: 'index',
+        name: '到货质检',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/arrivalInspection/index'),
+        props: true,
+      },
+    ],
+  },
+  {
+    path: '/inbound-outbound/abnormalManage',
+    component: Layout,
+    redirect: '/inbound-outbound/abnormalManage/index',
+    children: [
+      {
+        path: 'index',
+        name: '异常管理',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/abnormalManage/index'),
+        props: true,
+      },
+    ],
+  },
+  {
     path: '/inbound-outbound/outbound',
     component: Layout,
     redirect: '/inbound-outbound/outbound/index',
@@ -411,22 +464,22 @@ export default [
     ],
   },
   {
-    path: '/inbound-outbound/salesOutbound',
+    path: '/inbound-outbound/outbound/salesOutbound',
     component: Layout,
-    redirect: '/inbound-outbound/salesOutbound/index',
+    redirect: '/inbound-outbound/outbound/salesOutbound/index',
     children: [
       {
         path: 'index',
         name: '销售订单出库',
-        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/salesOutbound/index'),
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/outbound/salesOutbound/index'),
         props: true,
       },
     ],
   },
   {
-    path: '/inbound-outbound/JDoutbound',
+    path: '/inbound-outbound/outbound/JDoutbound',
     component: Layout,
-    redirect: '/inbound-outbound/JDoutbound/index',
+    redirect: '/inbound-outbound/outbound/JDoutbound/index',
     children: [
       {
         path: 'index',
@@ -436,7 +489,59 @@ export default [
       },
     ],
   },
-
+  {
+    path: '/inbound-outbound/outbound/manualOutbound',
+    component: Layout,
+    redirect: '/inbound-outbound/outbound/manualOutbound/index',
+    children: [
+      {
+        path: 'index',
+        name: '手动出库',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/outbound/manualOutbound/index'),
+        props: true,
+      },
+    ],
+  },
+  {
+    path: '/inbound-outbound/transfer',
+    component: Layout,
+    redirect: '/inbound-outbound/transfer/index',
+    children: [
+      {
+        path: 'index',
+        name: '调仓',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/inbound-outbound/transfer/index'),
+        props: true,
+      },
+    ],
+  },
+  {
+    path: '/process/backlog',
+    component: Layout,
+    redirect: '/process/backlog/index',
+    children: [
+      {
+        path: 'index',
+        name: '流程审批',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/process/backlog/index'),
+        props: true,
+      },
+    ],
+  },
+  {
+    path: '/process/examinationApproval',
+    component: Layout,
+    redirect: '/process/examinationApproval/index',
+    children: [
+      {
+        path: 'index',
+        name: '办理',
+        component: () => import(/* webpackChunkName: "page" */ '@/views/process/examinationApproval/index'),
+        props: true,
+      },
+    ],
+  },
+  //```````````````````````````````````````````````````````````````````` 
   {
     path: '/equipment',
     component: Layout,

+ 183 - 0
src/views/inbound-outbound/abnormalManage/addInspection.vue

@@ -0,0 +1,183 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-form-item label="跟进结果" prop="code">
+          <el-radio-group v-model="form.code" size="medium">
+            <el-radio-button label="1">完成</el-radio-button>
+            <el-radio-button label="2">跟进中</el-radio-button>
+          </el-radio-group>
+        </el-form-item>
+
+        <el-row>
+          <el-col :span="8">
+            <el-form-item label="跟进人" prop="code">
+              <el-select
+                v-model="form.inWarehouseId"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in warehouseSelectList"
+                  :key="item.id"
+                  :label="item.name"
+                  :value="item.id"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="10">
+            <el-form-item label="跟进时间" prop="clearancePeriod">
+              <el-date-picker
+                v-model="form.clearancePeriod"
+                type="datetime"
+                :placeholder="$t('pleaseSelect')"
+                value-format="yyyy-MM-dd HH:mm:ss"
+              >
+              </el-date-picker>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-form-item label="跟进记录" prop="remark">
+          <el-input
+            v-model="form.remark"
+            placeholder="请输入"
+            type="textarea"
+            :rows="3"
+          >
+          </el-input>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+    <!-- <el-dialog
+      :title="$t('goodsSelect')"
+      v-if="selectDialog"
+      :visible.sync="selectDialog"
+      width="80%"
+      top="60px"
+    >
+      <selectProduct @select="handleSelect"></selectProduct>
+    </el-dialog> -->
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+import selectProduct from "@/components/select-product/index.vue";
+
+import { getToken } from "@/util/auth";
+
+export default {
+  name: "addManualOutbound",
+  components: { labelTitle, selectProduct },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    warehouseSelectList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      uploadHeader: {
+        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
+        "Blade-Auth": "bearer " + getToken(),
+      },
+      loading: false,
+      selectDialog: false,
+      formRules: {
+        quantity: [
+          {
+            required: true,
+            message: "请输入质检合格数量",
+            trigger: "blur",
+          },
+        ],
+        outWarehouseId: [
+          {
+            required: true,
+            message: "请选择调出仓库",
+            trigger: "change",
+          },
+        ],
+        inWarehouseId: [
+          {
+            required: true,
+            message: "请选择调入仓库",
+            trigger: "change",
+          },
+        ],
+      },
+    };
+  },
+  created() {},
+  methods: {
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          if (!this.form.changeProductList.length > 0)
+            return this.msgInfo("请添加调仓明细");
+          this.loading = true;
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+    handleAddProduct() {
+      if (this.form.outWarehouseId === this.form.inWarehouseId)
+        return this.msgInfo("调出和调入仓库不可一致");
+      if (!(this.form.outWarehouseId && this.form.inWarehouseId))
+        return this.msgInfo("请先选择要调的仓库");
+      this.selectDialog = true;
+    },
+    handleSelect(row) {
+      const flag = this.form.changeProductList.some(
+        (x) => x.productId === row.id
+      );
+      if (flag) return this.msgInfo("该物品已经选择");
+      const product = {
+        productCode: row.code,
+        productName: row.name,
+        productId: row.id,
+        quantity: "",
+      };
+      this.form.changeProductList.push(product);
+    },
+    deleteRow(index) {
+      this.form.changeProductList.splice(index, 1);
+      this.msgSuccess(this.$t("deleteSuccess"));
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 258 - 0
src/views/inbound-outbound/abnormalManage/index.vue

@@ -0,0 +1,258 @@
+
+
+<script>
+import test from "@/components/form-test/index.vue";
+import query from "@/components/query/index.vue";
+
+import * as API from "@/api/inbound-outbound/transfer.js";
+
+import { warehouseSelectList } from "@/api/product-material/warehouse/index.js";
+import addInspection from "./addInspection.vue";
+
+export default {
+  components: {
+    test,
+    query,
+    addInspection,
+  },
+  data() {
+    return {
+      warehouseSelectList: [],
+      warehouseTypeList: [],
+      btnForm: {
+        otherButton: {
+          list: [
+            {
+              name: "发起调仓",
+              methodsText: "send",
+              type: "primary",
+              send: () => {
+                this.handleSend();
+              },
+            },
+          ],
+        },
+      },
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        keyword: "",
+        outWarehouseId: "",
+        inWarehouseId: "",
+        inStatus: "",
+      },
+      selectConfig: [
+        {
+          label: "异常来源",
+          prop: "outWarehouseId",
+          data: [],
+        },
+        {
+          label: "处理状态",
+          prop: "outWarehouseId",
+          data: [],
+        },
+      ],
+      tableList: [],
+      total: 0,
+      loading: false,
+      titleText: "异常跟进",
+      open: false,
+      form: {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      },
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.warehouseTypeList = businessDictData.find(
+      (item) => item.code === "warehouseType"
+    ).children;
+    warehouseSelectList().then((res) => {
+      this.warehouseSelectList = res.data.data;
+      this.selectConfig[0].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+      this.selectConfig[1].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+    });
+    this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      API.transferList(this.queryParams).then(
+        (res) => {
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("transferList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleQuery() {
+      this.getList();
+    },
+    handleSend() {
+      this.form = {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      };
+      this.open = true;
+    },
+    handleCancel() {
+      this.form = {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      };
+      this.open = false;
+    },
+
+    handleSubmit() {
+      API.addInspection(this.form).then(
+        () => {
+          this.msgSuccess(this.$t("addSuccess"));
+          this.$refs.addInspection.loading = false;
+          this.open = false;
+          this.getList();
+        },
+        (err) => {
+          console.log("addInspection: " + err);
+          this.$refs.addInspection.loading = false;
+        }
+      );
+    },
+    handleReceive(row) {
+      this.open = true;
+      // this.$confirm("是否确认接收 ?", {
+      //   confirmButtonText: this.$t("submitText"),
+      //   cancelButtonText: this.$t("cancelText"),
+      //   type: "warning",
+      // }).then(() => {
+      //   API.receive({ id: row.id, inQuantity: row.outQuantity }).then(() => {
+      //     this.msgSuccess("接收成功");
+      //     this.getList();
+      //   });
+      // });
+    },
+
+    showAddress(row) {
+      return (
+        <div>
+          {row.countryName} , {row.provinceName} , {row.cityName}
+        </div>
+      );
+    },
+  },
+};
+</script>
+
+
+<template>
+  <div class="box-card">
+    <el-card class="body-main">
+      <query
+        :selectConfig="selectConfig"
+        :req="queryParams"
+        :isShowMore="true"
+        @handleQuery="handleQuery"
+        @handleMore="
+          () => {
+            queryDialog = true;
+          }
+        "
+      ></query>
+      <el-table :data="tableList" v-loading="loading">
+        <el-table-column
+          label="异常来源"
+          align="left"
+          prop="code"
+          width="120"
+        />
+        <el-table-column label="异常说明" align="left" prop="name" />
+        <el-table-column
+          label="处理状态"
+          align="left"
+          prop="specs"
+          width="100"
+        />
+
+        <el-table-column
+          label="最近操作人"
+          align="left"
+          prop="outQuantity"
+          width="120"
+        />
+        <el-table-column
+          label="最近操作时间"
+          align="left"
+          prop="outUserName"
+          width="160"
+        />
+
+        <el-table-column label="操作" align="center" width="120">
+          <template slot-scope="scope">
+            <el-button type="text" @click="handleReceive(scope.row)"
+              >跟进
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <pagination
+        v-show="total > 0"
+        :total="total"
+        :page.sync="queryParams.pageNum"
+        :limit.sync="queryParams.pageSize"
+        @pagination="getList"
+      />
+    </el-card>
+
+    <el-dialog
+      :title="titleText"
+      :visible.sync="open"
+      v-if="open"
+      width="30%"
+      top="60px"
+    >
+      <add-inspection
+        :form="form"
+        @submit="handleSubmit"
+        @cancel="handleCancel"
+        ref="addInspection"
+      ></add-inspection>
+    </el-dialog>
+  </div>
+</template>
+
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+  display: flex;
+  flex-direction: column;
+  .header {
+    // height: 100px;
+    margin-bottom: 10px;
+    box-sizing: border-box;
+  }
+  .body-main {
+    flex: 1;
+  }
+}
+</style>

+ 219 - 0
src/views/inbound-outbound/arrivalInspection/addInspection.vue

@@ -0,0 +1,219 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-row :gutter="10">
+          <el-col :span="4">
+            <el-form-item label="采购单号" prop="code">
+              <el-input v-model="form.code" disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="10">
+            <el-form-item label="供应商" prop="supplyName">
+              <el-input v-model="form.supplyName" disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="10">
+          <el-col :span="4">
+            <el-form-item label="物流公司" prop="code">
+              <el-input v-model="form.code" disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="8">
+            <el-form-item label="物流/快递单号" prop="supplyName">
+              <el-input v-model="form.supplyName" disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <div style="margin-bottom: 20px">
+          <labelTitle content="质检明细"></labelTitle>
+        </div>
+
+        <el-form-item>
+          <el-table :data="form.changeProductList">
+            <el-table-column label="物品编码" prop="productCode">
+            </el-table-column>
+            <el-table-column label="物品名称" prop="productName">
+            </el-table-column>
+            <el-table-column label="待质检数量" prop="name"> </el-table-column>
+
+            <el-table-column label="质检合格" prop="quantity">
+              <template slot-scope="scope">
+                <el-form-item
+                  :prop="'changeProductList.' + scope.$index + '.quantity'"
+                  :rules="formRules.quantity"
+                  :inline-message="true"
+                  label-width="0"
+                >
+                  <el-input
+                    v-model="scope.row.quantity"
+                    :placeholder="$t('pleaseInput')"
+                    size="mini"
+                  >
+                  </el-input>
+                </el-form-item>
+              </template>
+            </el-table-column>
+            <el-table-column label="质检不合格" prop="quantity">
+              <template slot-scope="scope">
+                <el-form-item
+                  :prop="'changeProductList.' + scope.$index + '.quantity'"
+                  :rules="formRules.quantity"
+                  :inline-message="true"
+                  label-width="0"
+                >
+                  <el-input
+                    v-model="scope.row.quantity"
+                    :placeholder="$t('pleaseInput')"
+                    size="mini"
+                  >
+                  </el-input>
+                </el-form-item>
+              </template>
+            </el-table-column>
+
+            <!-- <el-table-column
+              :label="$t('operation')"
+              width="100"
+              align="center"
+            >
+              <template slot-scope="scope">
+                <el-button type="text" @click="deleteRow(scope.$index)">{{
+                  $t("delete")
+                }}</el-button>
+              </template>
+            </el-table-column> -->
+          </el-table>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+    <!-- <el-dialog
+      :title="$t('goodsSelect')"
+      v-if="selectDialog"
+      :visible.sync="selectDialog"
+      width="80%"
+      top="60px"
+    >
+      <selectProduct @select="handleSelect"></selectProduct>
+    </el-dialog> -->
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+import selectProduct from "@/components/select-product/index.vue";
+
+import { getToken } from "@/util/auth";
+
+export default {
+  name: "addManualOutbound",
+  components: { labelTitle, selectProduct },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    warehouseSelectList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      uploadHeader: {
+        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
+        "Blade-Auth": "bearer " + getToken(),
+      },
+      loading: false,
+      selectDialog: false,
+      formRules: {
+        quantity: [
+          {
+            required: true,
+            message: "请输入质检合格数量",
+            trigger: "blur",
+          },
+        ],
+        outWarehouseId: [
+          {
+            required: true,
+            message: "请选择调出仓库",
+            trigger: "change",
+          },
+        ],
+        inWarehouseId: [
+          {
+            required: true,
+            message: "请选择调入仓库",
+            trigger: "change",
+          },
+        ],
+      },
+    };
+  },
+  created() {},
+  methods: {
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          if (!this.form.changeProductList.length > 0)
+            return this.msgInfo("请添加调仓明细");
+          this.loading = true;
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+    handleAddProduct() {
+      if (this.form.outWarehouseId === this.form.inWarehouseId)
+        return this.msgInfo("调出和调入仓库不可一致");
+      if (!(this.form.outWarehouseId && this.form.inWarehouseId))
+        return this.msgInfo("请先选择要调的仓库");
+      this.selectDialog = true;
+    },
+    handleSelect(row) {
+      const flag = this.form.changeProductList.some(
+        (x) => x.productId === row.id
+      );
+      if (flag) return this.msgInfo("该物品已经选择");
+      const product = {
+        productCode: row.code,
+        productName: row.name,
+        productId: row.id,
+        quantity: "",
+      };
+      this.form.changeProductList.push(product);
+    },
+    deleteRow(index) {
+      this.form.changeProductList.splice(index, 1);
+      this.msgSuccess(this.$t("deleteSuccess"));
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 243 - 0
src/views/inbound-outbound/arrivalInspection/index.vue

@@ -0,0 +1,243 @@
+
+
+<script>
+import test from "@/components/form-test/index.vue";
+import query from "@/components/query/index.vue";
+
+import * as API from "@/api/inbound-outbound/transfer.js";
+
+import { warehouseSelectList } from "@/api/product-material/warehouse/index.js";
+import addInspection from "./addInspection.vue";
+
+export default {
+  components: {
+    test,
+    query,
+    addInspection,
+  },
+  data() {
+    return {
+      warehouseSelectList: [],
+      warehouseTypeList: [],
+      btnForm: {
+        otherButton: {
+          list: [
+            {
+              name: "发起调仓",
+              methodsText: "send",
+              type: "primary",
+              send: () => {
+                this.handleSend();
+              },
+            },
+          ],
+        },
+      },
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        keyword: "",
+        outWarehouseId: "",
+        inWarehouseId: "",
+        inStatus: "",
+      },
+      selectConfig: [
+        {
+          label: "质检状态",
+          prop: "outWarehouseId",
+          data: [],
+        },
+      ],
+      tableList: [],
+      total: 0,
+      loading: false,
+      titleText: "到货质检",
+      open: false,
+      form: {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      },
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.warehouseTypeList = businessDictData.find(
+      (item) => item.code === "warehouseType"
+    ).children;
+    warehouseSelectList().then((res) => {
+      this.warehouseSelectList = res.data.data;
+      this.selectConfig[0].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+      this.selectConfig[1].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+    });
+    this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      API.transferList(this.queryParams).then(
+        (res) => {
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("transferList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleQuery() {
+      this.getList();
+    },
+    handleSend() {
+      this.form = {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      };
+      this.open = true;
+    },
+    handleCancel() {
+      this.form = {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      };
+      this.open = false;
+    },
+
+    handleSubmit() {
+      API.addInspection(this.form).then(
+        () => {
+          this.msgSuccess(this.$t("addSuccess"));
+          this.$refs.addInspection.loading = false;
+          this.open = false;
+          this.getList();
+        },
+        (err) => {
+          console.log("addInspection: " + err);
+          this.$refs.addInspection.loading = false;
+        }
+      );
+    },
+    handleReceive(row) {
+      this.open = true;
+      // this.$confirm("是否确认接收 ?", {
+      //   confirmButtonText: this.$t("submitText"),
+      //   cancelButtonText: this.$t("cancelText"),
+      //   type: "warning",
+      // }).then(() => {
+      //   API.receive({ id: row.id, inQuantity: row.outQuantity }).then(() => {
+      //     this.msgSuccess("接收成功");
+      //     this.getList();
+      //   });
+      // });
+    },
+
+    showAddress(row) {
+      return (
+        <div>
+          {row.countryName} , {row.provinceName} , {row.cityName}
+        </div>
+      );
+    },
+  },
+};
+</script>
+
+
+<template>
+  <div class="box-card">
+    <el-card class="body-main">
+      <query
+        :selectConfig="selectConfig"
+        :req="queryParams"
+        :isShowMore="true"
+        @handleQuery="handleQuery"
+        @handleMore="
+          () => {
+            queryDialog = true;
+          }
+        "
+      ></query>
+      <el-table :data="tableList" v-loading="loading">
+        <el-table-column label="采购单号" align="center" prop="code" />
+        <el-table-column label="供应商" align="center" prop="name" />
+        <el-table-column label="物流公司" align="center" prop="specs" />
+        <el-table-column
+          label="物流/快递单号"
+          align="center"
+          prop="outWarehouseName"
+        />
+        <el-table-column label="采购员" align="center" prop="outQuantity" />
+        <el-table-column label="采购时间" align="center" prop="outUserName" />
+        <el-table-column
+          label="调入仓库"
+          align="center"
+          prop="inWarehouseName"
+        />
+        <el-table-column label="状态" align="center" prop="inQuantity" />
+
+        <el-table-column :label="$t('operation')" align="center" width="120">
+          <template slot-scope="scope">
+            <el-button type="text" @click="handleReceive(scope.row)"
+              >质检
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <pagination
+        v-show="total > 0"
+        :total="total"
+        :page.sync="queryParams.pageNum"
+        :limit.sync="queryParams.pageSize"
+        @pagination="getList"
+      />
+    </el-card>
+
+    <el-dialog
+      :title="titleText"
+      :visible.sync="open"
+      v-if="open"
+      width="80%"
+      top="60px"
+    >
+      <add-inspection
+        :form="form"
+        @submit="handleSubmit"
+        @cancel="handleCancel"
+        ref="addInspection"
+      ></add-inspection>
+    </el-dialog>
+  </div>
+</template>
+
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+  display: flex;
+  flex-direction: column;
+  .header {
+    // height: 100px;
+    margin-bottom: 10px;
+    box-sizing: border-box;
+  }
+  .body-main {
+    flex: 1;
+  }
+}
+</style>

+ 0 - 0
src/views/inbound-outbound/cgInbound.vue


+ 22 - 20
src/views/inbound-outbound/cgInbound/index.vue → src/views/inbound-outbound/inbound/cgInbound/index.vue

@@ -3,7 +3,7 @@
 <script>
 import test from "@/components/form-test/index.vue";
 import query from "@/components/query/index.vue";
-import addInbound from "@/components/inbound-outbound/addInbound.vue";
+import purchaseInbound from "./purchaseInbound.vue";
 import * as API from "@/api/inbound-outbound/inbound/index.js";
 import { warehouseSelectList } from "@/api/product-material/warehouse/index.js";
 
@@ -11,7 +11,7 @@ export default {
   components: {
     test,
     query,
-    addInbound,
+    purchaseInbound,
   },
   data() {
     return {
@@ -67,7 +67,7 @@ export default {
           ],
         },
       ],
-      tableList: [],
+      tableList: [{}],
       loading: false,
       inboundType: 10, // 入库类型  10 采购入库  20 手动入库
       titleText: "",
@@ -113,7 +113,7 @@ export default {
     handleQuery() {
       this.getList();
     },
-    handleAdd() {
+    handleInbound() {
       this.form = {
         id: "",
         changeDetailsList: [],
@@ -198,9 +198,9 @@ export default {
 
 <template>
   <div class="box-card">
-    <el-card class="header">
+    <!-- <el-card class="header">
       <test :form-config="btnForm"></test>
-    </el-card>
+    </el-card> -->
     <el-card class="body-main">
       <query
         :selectConfig="selectConfig"
@@ -215,14 +215,19 @@ export default {
       ></query>
       <el-table :data="tableList" v-loading="loading">
         <el-table-column label="采购单号" align="center" prop="code" />
-        <el-table-column label="申购数量" align="center" prop="name" />
-        <el-table-column label="已入库数量" align="center" />
-        <el-table-column label="未入库数量" align="center" prop="contacts" />
-        <el-table-column label="收获仓库" align="center" prop="phone" />
-        <el-table-column label="入库日期" align="center" prop="phone" />
-        <el-table-column label="申购人" align="center" prop="phone" />
-
-        <el-table-column label="入库状态" align="center" prop="phone" />
+        <el-table-column label="供应商" align="center" prop="name" />
+        <el-table-column label="物流公司" align="center" />
+        <el-table-column label="物流/快递单号" align="center" prop="contacts" />
+        <el-table-column label="采购员" align="center" prop="phone" />
+        <el-table-column label="采购时间" align="center" prop="phone" />
+        <el-table-column label="状态" align="center" prop="phone" />
+        <el-table-column label="状态" align="center" prop="phone">
+          <template slot-scope="scope">
+            <el-button type="text" @click="handleInbound(scope.row)">
+              入库
+            </el-button>
+          </template>
+        </el-table-column>
       </el-table>
       <pagination
         v-show="total > 0"
@@ -240,15 +245,12 @@ export default {
       width="80%"
       top="60px"
     >
-      <add-inbound
+      <purchase-inbound
         :form="form"
-        :warehouseSelectList="warehouseSelectList"
-        :warehouseTypeList="warehouseTypeList"
-        :inboundType="inboundType"
         @submit="handleSubmit"
         @cancel="handleCancel"
-        ref="addInbound"
-      ></add-inbound>
+        ref="purchaseInbound"
+      ></purchase-inbound>
     </el-dialog>
   </div>
 </template>

+ 237 - 0
src/views/inbound-outbound/inbound/cgInbound/purchaseInbound.vue

@@ -0,0 +1,237 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-row :gutter="10">
+          <el-col :span="4">
+            <el-form-item label="采购单号" prop="code">
+              <el-input v-model="form.code" disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="8">
+            <el-form-item label="供应商" prop="code">
+              <el-input v-model="form.code" disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="10">
+          <el-col :span="4">
+            <el-form-item label="物流公司" prop="logisticsCompanyCode">
+              <el-input v-model="form.logisticsCode" disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="6">
+            <el-form-item label="物流/快递单号" prop="logisticsCode">
+              <el-input v-model="form.logisticsCode" disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+
+        <div style="margin-bottom: 20px">
+          <labelTitle content="到货明细"></labelTitle>
+        </div>
+        <el-form-item>
+          <el-table :data="form.changeDetailsList">
+            <el-table-column label="物品编码" prop="productCode">
+            </el-table-column>
+            <el-table-column label="物品名称" prop="productName">
+            </el-table-column>
+            <el-table-column label="采购数量" prop="productType">
+            </el-table-column>
+            <el-table-column label="本次发货" prop="warehouseName">
+            </el-table-column>
+
+            <el-table-column label="本次入库" prop="changeQuantity">
+              <template slot-scope="scope">
+                <el-form-item
+                  :prop="
+                    'changeDetailsList.' + scope.$index + '.changeQuantity'
+                  "
+                  :rules="formRules1.changeQuantity"
+                  :inline-message="true"
+                  label-width="0"
+                >
+                  <el-input
+                    v-model="scope.row.changeQuantity"
+                    :placeholder="$t('pleaseInput')"
+                    size="mini"
+                  >
+                  </el-input>
+                </el-form-item>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+
+import * as API from "@/api/inbound-outbound/inbound/index.js";
+
+export default {
+  name: "addInbound",
+  components: { labelTitle },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    warehouseSelectList: {
+      type: Array,
+      default: () => [],
+    },
+    warehouseTypeList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      selectLit: [],
+      loading: false,
+      formRules: {
+        id: [
+          {
+            required: true,
+            message: "请选择物流单号",
+            trigger: "change",
+          },
+        ],
+        changeQuantity: [
+          {
+            required: true,
+            message: "请输入到货数量",
+            trigger: "blur",
+          },
+        ],
+      },
+      formRules1: {
+        id: [
+          {
+            required: true,
+            message: "请选择收货仓库",
+            trigger: "change",
+          },
+        ],
+        changeQuantity: [
+          {
+            required: true,
+            message: "请输入入库数量",
+            trigger: "blur",
+          },
+        ],
+      },
+      selectDialog: false,
+      warehouseName: "",
+    };
+  },
+  created() {
+    this.getSelectList();
+  },
+  methods: {
+    getSelectList() {
+      this.loading = true;
+      API.saleOrdersList().then(
+        (res) => {
+          this.selectLit = res.data.data.records;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("saleOrdersList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          this.form.changeDetailsList = this.form.changeDetailsList.map(
+            (x) => ({
+              goodsId: x.goodsId,
+              warehouseId: this.form.id,
+              changeQuantity: x.changeQuantity,
+            })
+          );
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+    handleChange(id) {
+      this.loading = true;
+      API.inboundDetails({ id }).then(
+        (res) => {
+          this.form.changeDetailsList = res.data.data.map((x) => ({
+            ...x,
+            changeQuantity: "",
+          }));
+          this.loading = false;
+        },
+        (err) => {
+          console.log("inboundDetails: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleChangeWarehouse(id) {
+      const current = this.warehouseSelectList.find((x) => x.id === id);
+      if (current) {
+        this.warehouseName = current.name;
+      }
+      this.form.changeDetailsList = [];
+    },
+    handleAddProduct() {
+      if (!this.form.id) return this.msgInfo("请先选择收获仓库");
+      this.selectDialog = true;
+    },
+    handleSelect(row) {
+      const flag = this.form.changeDetailsList.some(
+        (x) => x.goodsId === row.id
+      );
+      if (flag) return this.msgInfo("该物品已经选择");
+      const product = {
+        productCode: row.code,
+        productName: row.name,
+        productType: row.type,
+        warehouseName: this.warehouseName,
+        goodsId: row.id,
+        changeQuantity: "",
+      };
+      this.form.changeDetailsList.push(product);
+    },
+    deleteRow(index) {
+      this.form.changeDetailsList.splice(index, 1);
+      this.msgSuccess(this.$t("deleteSuccess"));
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 262 - 0
src/views/inbound-outbound/inbound/manualInbound/addManualInbound.vue

@@ -0,0 +1,262 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-row>
+          <el-col :span="6">
+            <el-form-item label="仓库名称" prop="id">
+              <el-select
+                v-model="form.id"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+                @change="handleChangeWarehouse"
+              >
+                <el-option
+                  v-for="item in warehouseSelectList"
+                  :key="item.id"
+                  :label="item.name"
+                  :value="item.id"
+                >
+                  <span style="float: left">{{
+                    `${item.name}(${dictDataEcho(
+                      item.type,
+                      warehouseTypeList
+                    )})`
+                  }}</span>
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="10">
+            <el-form-item label="备注" prop="aa">
+              <el-input
+                placeholder="请输入"
+                v-model="form.aa"
+                type="textarea"
+                :rows="4"
+              >
+              </el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <div style="margin-bottom: 20px">
+          <labelTitle content="入库明细"></labelTitle>
+        </div>
+        <el-form-item label-width="0px">
+          <el-button type="primary" size="mini" @click="handleAddProduct">
+            添加明细</el-button
+          >
+        </el-form-item>
+        <el-form-item>
+          <el-table :data="form.changeDetailsList">
+            <el-table-column label="物品编码" prop="productCode">
+            </el-table-column>
+            <el-table-column label="物品名称" prop="productName">
+            </el-table-column>
+            <el-table-column label="规格" prop="productType"> </el-table-column>
+
+            <el-table-column label="本次入库" prop="changeQuantity">
+              <template slot-scope="scope">
+                <el-form-item
+                  :prop="
+                    'changeDetailsList.' + scope.$index + '.changeQuantity'
+                  "
+                  :rules="formRules1.changeQuantity"
+                  :inline-message="true"
+                  label-width="0"
+                >
+                  <el-input
+                    v-model="scope.row.changeQuantity"
+                    :placeholder="$t('pleaseInput')"
+                    size="mini"
+                  >
+                  </el-input>
+                </el-form-item>
+              </template>
+            </el-table-column>
+            <el-table-column
+              :label="$t('operation')"
+              width="100"
+              align="center"
+            >
+              <template slot-scope="scope">
+                <el-button type="text" @click="deleteRow(scope.$index)">{{
+                  $t("delete")
+                }}</el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+
+    <el-dialog
+      :title="$t('goodsSelect')"
+      v-if="selectDialog"
+      :visible.sync="selectDialog"
+      width="80%"
+      top="60px"
+    >
+      <selectProduct @select="handleSelect"></selectProduct>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+import selectProduct from "@/components/select-product/index.vue";
+
+import * as API from "@/api/inbound-outbound/inbound/index.js";
+
+export default {
+  name: "addInbound",
+  components: { labelTitle, selectProduct },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    warehouseSelectList: {
+      type: Array,
+      default: () => [],
+    },
+    warehouseTypeList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      selectLit: [],
+      loading: false,
+      formRules: {
+        id: [
+          {
+            required: true,
+            message: "请选择物流单号",
+            trigger: "change",
+          },
+        ],
+        changeQuantity: [
+          {
+            required: true,
+            message: "请输入到货数量",
+            trigger: "blur",
+          },
+        ],
+      },
+      formRules1: {
+        id: [
+          {
+            required: true,
+            message: "请选择收货仓库",
+            trigger: "change",
+          },
+        ],
+        changeQuantity: [
+          {
+            required: true,
+            message: "请输入入库数量",
+            trigger: "blur",
+          },
+        ],
+      },
+      selectDialog: false,
+      warehouseName: "",
+    };
+  },
+  created() {
+    this.getSelectList();
+  },
+  methods: {
+    getSelectList() {
+      this.loading = true;
+      API.saleOrdersList().then(
+        (res) => {
+          this.selectLit = res.data.data.records;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("saleOrdersList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          this.loading = true;
+          this.form.changeDetailsList = this.form.changeDetailsList.map(
+            (x) => ({
+              goodsId: x.goodsId,
+              warehouseId: this.form.id,
+              changeQuantity: x.changeQuantity,
+            })
+          );
+          delete this.form.id;
+          delete this.form.aa;
+
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+
+    handleChangeWarehouse(id) {
+      // const current = this.warehouseSelectList.find((x) => x.id === id);
+      // if (current) {
+      //   this.warehouseName = current.name;
+      // }
+      this.form.changeDetailsList = [];
+    },
+    handleAddProduct() {
+      if (!this.form.id) return this.msgInfo("请先选择仓库");
+      this.selectDialog = true;
+    },
+    handleSelect(row) {
+      const flag = this.form.changeDetailsList.some(
+        (x) => x.goodsId === row.id
+      );
+      if (flag) return this.msgInfo("该物品已经选择");
+      const product = {
+        productCode: row.code,
+        productName: row.name,
+        goodsId: row.id,
+        changeQuantity: "",
+      };
+      this.form.changeDetailsList.push(product);
+    },
+    deleteRow(index) {
+      this.form.changeDetailsList.splice(index, 1);
+      this.msgSuccess(this.$t("deleteSuccess"));
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 213 - 0
src/views/inbound-outbound/inbound/manualInbound/index.vue

@@ -0,0 +1,213 @@
+
+
+<script>
+import test from "@/components/form-test/index.vue";
+import query from "@/components/query/index.vue";
+import addManualInbound from "./addManualInbound.vue";
+import * as API from "@/api/inbound-outbound/inbound/manualInbound.js";
+import { warehouseSelectList } from "@/api/product-material/warehouse/index.js";
+
+export default {
+  components: {
+    test,
+    query,
+    addManualInbound,
+  },
+  data() {
+    return {
+      warehouseTypeList: [],
+      warehouseSelectList: [],
+      btnForm: {
+        otherButton: {
+          list: [
+            {
+              name: "手动入库",
+              methodsText: "add",
+              type: "primary",
+              add: () => {
+                this.handleInbound();
+              },
+            },
+          ],
+        },
+      },
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        keyword: "",
+        warehouseId: "",
+        status: "",
+        code: "",
+        goodsCode: "",
+        goodsName: "",
+        applyUserId: "",
+        startTime: "",
+        endTime: "",
+      },
+      selectConfig: [
+        {
+          label: "仓库名称",
+          prop: "type",
+          data: [],
+        },
+      ],
+      tableList: [{}],
+      total: 0,
+      loading: false,
+      inboundType: 10, // 入库类型  10 采购入库  20 手动入库
+      titleText: "",
+      open: false,
+      form: {
+        id: "",
+        changeDetailsList: [],
+      },
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.warehouseTypeList = businessDictData.find(
+      (item) => item.code === "warehouseType"
+    ).children;
+    // this.selectConfig[0].data = this.warehouseTypeList.map((item) => ({
+    //   label: item.dictValue,
+    //   value: item.dictKey,
+    // }));
+    warehouseSelectList().then((res) => {
+      this.warehouseSelectList = res.data.data;
+      this.selectConfig[0].data = this.warehouseSelectList.map((x) => ({
+        label: x.name,
+        value: x.id,
+      }));
+    });
+
+    // this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      API.outboundList(this.queryParams).then(
+        (res) => {
+          console.log(res, "qq");
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("outboundList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleQuery() {
+      this.getList();
+    },
+    handleInbound() {
+      this.form = {
+        id: "",
+        changeDetailsList: [],
+      };
+      this.open = true;
+    },
+    handleCancel() {
+      this.open = false;
+    },
+    handleSubmit() {
+      API.manualAdd(this.form).then(
+        () => {
+          this.msgSuccess(this.$t("addSuccess"));
+          this.$refs.addManualInbound.loading = false;
+          this.open = false;
+          this.getList();
+        },
+        (err) => {
+          console.log("purchaseAdd: " + err);
+          this.$refs.addManualInbound.loading = false;
+        }
+      );
+    },
+    showAddress(row) {
+      return (
+        <div>
+          {row.countryName} , {row.provinceName} , {row.cityName}
+        </div>
+      );
+    },
+  },
+};
+</script>
+
+
+<template>
+  <div class="box-card">
+    <el-card class="header">
+      <test :form-config="btnForm"></test>
+    </el-card>
+    <el-card class="body-main">
+      <query
+        :selectConfig="selectConfig"
+        :req="queryParams"
+        :isShowMore="true"
+        @handleQuery="handleQuery"
+        @handleMore="
+          () => {
+            queryDialog = true;
+          }
+        "
+      ></query>
+      <el-table :data="tableList" v-loading="loading">
+        <el-table-column label="仓库名称" align="center" prop="code" />
+        <el-table-column label="物品编码" align="center" prop="name" />
+        <el-table-column label="物品名称" align="center" />
+        <el-table-column label="物流/规格" align="center" prop="contacts" />
+        <el-table-column label="单位" align="center" prop="phone" />
+        <el-table-column label="入库数量" align="center" prop="phone" />
+        <el-table-column label="操作人" align="center" prop="phone" />
+        <el-table-column label="操作时间" align="center" prop="phone" />
+      </el-table>
+      <pagination
+        v-show="total > 0"
+        :total="total"
+        :page.sync="queryParams.pageNum"
+        :limit.sync="queryParams.pageSize"
+        @pagination="getList"
+      />
+    </el-card>
+
+    <el-dialog
+      title="手动入库"
+      :visible.sync="open"
+      v-if="open"
+      width="80%"
+      top="60px"
+    >
+      <add-manual-inbound
+        :form="form"
+        :warehouseSelectList="warehouseSelectList"
+        :warehouseTypeList="warehouseTypeList"
+        @submit="handleSubmit"
+        @cancel="handleCancel"
+        ref="addManualInbound"
+      ></add-manual-inbound>
+    </el-dialog>
+  </div>
+</template>
+
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+  display: flex;
+  flex-direction: column;
+  .header {
+    // height: 100px;
+    margin-bottom: 10px;
+    box-sizing: border-box;
+  }
+  .body-main {
+    flex: 1;
+  }
+}
+</style>

+ 202 - 0
src/views/inbound-outbound/outbound/manualOutbound/addManualOutbound.vue

@@ -0,0 +1,202 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-row>
+          <el-col :span="6">
+            <el-form-item label="仓库名称" prop="warehouseId">
+              <el-select
+                v-model="form.warehouseId"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in warehouseSelectList"
+                  :key="item.id"
+                  :label="item.name"
+                  :value="item.id"
+                >
+                  <span style="float: left">{{
+                    `${item.name}(${dictDataEcho(
+                      item.type,
+                      warehouseTypeList
+                    )})`
+                  }}</span>
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+
+        <div style="margin-bottom: 20px">
+          <labelTitle content="出库明细"></labelTitle>
+        </div>
+        <el-form-item label-width="0px">
+          <el-button type="primary" size="mini" @click="handleAddProduct">
+            添加明细</el-button
+          >
+        </el-form-item>
+        <el-form-item>
+          <el-table :data="form.changeProductList">
+            <el-table-column label="产品编码" prop="productCode">
+            </el-table-column>
+            <el-table-column label="产品名称" prop="productName">
+            </el-table-column>
+            <el-table-column label="规格" prop="name"> </el-table-column>
+
+            <el-table-column label="本次出库" prop="quantity">
+              <template slot-scope="scope">
+                <el-form-item
+                  :prop="'changeProductList.' + scope.$index + '.quantity'"
+                  :rules="formRules.quantity"
+                  :inline-message="true"
+                  label-width="0"
+                >
+                  <el-input
+                    v-model="scope.row.quantity"
+                    :placeholder="$t('pleaseInput')"
+                    size="mini"
+                  >
+                  </el-input>
+                </el-form-item>
+              </template>
+            </el-table-column>
+
+            <el-table-column
+              :label="$t('operation')"
+              width="100"
+              align="center"
+            >
+              <template slot-scope="scope">
+                <el-button type="text" @click="deleteRow(scope.$index)">{{
+                  $t("delete")
+                }}</el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+    <el-dialog
+      :title="$t('goodsSelect')"
+      v-if="selectDialog"
+      :visible.sync="selectDialog"
+      width="80%"
+      top="60px"
+    >
+      <selectProduct @select="handleSelect"></selectProduct>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+import selectProduct from "@/components/select-product/index.vue";
+
+import { getToken } from "@/util/auth";
+
+export default {
+  name: "addManualOutbound",
+  components: { labelTitle, selectProduct },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    warehouseSelectList: {
+      type: Array,
+      default: () => [],
+    },
+    warehouseTypeList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      uploadHeader: {
+        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
+        "Blade-Auth": "bearer " + getToken(),
+      },
+      loading: false,
+      selectDialog: false,
+      formRules: {
+        quantity: [
+          {
+            required: true,
+            message: "请输入本次出库数量",
+            trigger: "blur",
+          },
+        ],
+        warehouseId: [
+          {
+            required: true,
+            message: "请选择仓库",
+            trigger: "change",
+          },
+        ],
+      },
+    };
+  },
+  created() {},
+  methods: {
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          if (!this.form.changeProductList.length > 0)
+            return this.msgInfo("请添加出库明细");
+          this.loading = true;
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+    handleAddProduct() {
+      if (!this.form.warehouseId) return this.msgInfo("请先选择要出库的仓库");
+      this.selectDialog = true;
+    },
+    handleSelect(row) {
+      const flag = this.form.changeProductList.some(
+        (x) => x.productId === row.id
+      );
+      if (flag) return this.msgInfo("该物品已经选择");
+      const product = {
+        productCode: row.code,
+        productName: row.name,
+        productId: row.id,
+        quantity: "",
+      };
+      this.form.changeProductList.push(product);
+    },
+    deleteRow(index) {
+      this.form.changeProductList.splice(index, 1);
+      this.msgSuccess(this.$t("deleteSuccess"));
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 218 - 0
src/views/inbound-outbound/outbound/manualOutbound/index.vue

@@ -0,0 +1,218 @@
+
+
+<script>
+import test from "@/components/form-test/index.vue";
+import query from "@/components/query/index.vue";
+
+import * as API from "@/api/inbound-outbound/manualOutbound.js";
+
+import { warehouseSelectList } from "@/api/product-material/warehouse/index.js";
+import addManualOutbound from "./addManualOutbound.vue";
+
+export default {
+  components: {
+    test,
+    query,
+    addManualOutbound,
+  },
+  data() {
+    return {
+      warehouseSelectList: [],
+      warehouseTypeList: [],
+      btnForm: {
+        otherButton: {
+          list: [
+            {
+              name: "手动出库",
+              methodsText: "add",
+              type: "primary",
+              add: () => {
+                this.handleAdd();
+              },
+            },
+          ],
+        },
+      },
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        keyword: "",
+        warehouseId: "",
+        type: "",
+        code: "",
+        createUser: "",
+        startTime: "",
+        endTime: "",
+      },
+      selectConfig: [
+        {
+          label: "仓库名称",
+          prop: "type",
+          data: [],
+        },
+      ],
+      tableList: [],
+      total: 0,
+      loading: false,
+      titleText: "手动出库",
+      open: false,
+      form: {
+        warehouseId: "",
+        remarks: "",
+        type: "",
+        changeProductList: [],
+      },
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.warehouseTypeList = businessDictData.find(
+      (item) => item.code === "warehouseType"
+    ).children;
+    warehouseSelectList().then((res) => {
+      this.warehouseSelectList = res.data.data;
+      this.selectConfig[0].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+    });
+    this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      API.manualList(this.queryParams).then(
+        (res) => {
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("manualList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleQuery() {
+      this.getList();
+    },
+    handleAdd() {
+      this.form = {
+        warehouseId: "",
+        remarks: "",
+        type: "",
+        changeProductList: [],
+      };
+      this.open = true;
+    },
+    handleCancel() {
+      this.form = {
+        warehouseId: "",
+        remarks: "",
+        type: "",
+        changeProductList: [],
+      };
+      this.open = false;
+    },
+
+    handleSubmit() {
+      API.manualOutbound(this.form).then(
+        () => {
+          this.msgSuccess(this.$t("addSuccess"));
+          this.$refs.addManualOutbound.loading = false;
+          this.open = false;
+          this.getList();
+        },
+        (err) => {
+          console.log("manualOutbound: " + err);
+          this.$refs.addManualOutbound.loading = false;
+        }
+      );
+    },
+
+    showAddress(row) {
+      return (
+        <div>
+          {row.countryName} , {row.provinceName} , {row.cityName}
+        </div>
+      );
+    },
+  },
+};
+</script>
+
+
+<template>
+  <div class="box-card">
+    <el-card class="header">
+      <test :form-config="btnForm"></test>
+    </el-card>
+    <el-card class="body-main">
+      <query
+        :selectConfig="selectConfig"
+        :req="queryParams"
+        :isShowMore="true"
+        @handleQuery="handleQuery"
+        @handleMore="
+          () => {
+            queryDialog = true;
+          }
+        "
+      ></query>
+      <el-table :data="tableList" v-loading="loading">
+        <el-table-column label="仓库名称" align="center" prop="code" />
+        <el-table-column label="物品编码" align="center" />
+        <el-table-column label="物品名称" align="center" prop="contacts" />
+        <el-table-column label="规格" align="center" prop="phone" />
+        <el-table-column label="单位" align="center" prop="phone" />
+        <el-table-column label="入库数量" align="center" prop="phone" />
+        <el-table-column label="操作人" align="center" prop="phone" />
+        <el-table-column label="操作时间" align="center" prop="phone" />
+      </el-table>
+      <pagination
+        v-show="total > 0"
+        :total="total"
+        :page.sync="queryParams.pageNum"
+        :limit.sync="queryParams.pageSize"
+        @pagination="getList"
+      />
+    </el-card>
+
+    <el-dialog
+      :title="titleText"
+      :visible.sync="open"
+      v-if="open"
+      width="80%"
+      top="60px"
+    >
+      <add-manual-outbound
+        :form="form"
+        :warehouseSelectList="warehouseSelectList"
+        :warehouseTypeList="warehouseTypeList"
+        @submit="handleSubmit"
+        @cancel="handleCancel"
+        ref="addManualOutbound"
+      ></add-manual-outbound>
+    </el-dialog>
+  </div>
+</template>
+
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+  display: flex;
+  flex-direction: column;
+  .header {
+    // height: 100px;
+    margin-bottom: 10px;
+    box-sizing: border-box;
+  }
+  .body-main {
+    flex: 1;
+  }
+}
+</style>

+ 0 - 0
src/views/inbound-outbound/salesOutbound/addOutbound.vue → src/views/inbound-outbound/outbound/salesOutbound/addOutbound.vue


+ 20 - 29
src/views/inbound-outbound/salesOutbound/index.vue → src/views/inbound-outbound/outbound/salesOutbound/index.vue

@@ -20,6 +20,7 @@ export default {
       orderTypeList: [],
       warehouseTypeList: [],
       warehouseSelectList: [],
+      outboundTypeList: [],
       queryParams: {
         pageNum: 1,
         pageSize: 10,
@@ -71,6 +72,9 @@ export default {
     this.warehouseTypeList = businessDictData.find(
       (item) => item.code === "warehouseType"
     ).children;
+    this.outboundTypeList = businessDictData.find(
+      (item) => item.code === "outboundType"
+    ).children;
     warehouseSelectList().then((res) => {
       this.warehouseSelectList = res.data.data;
     });
@@ -98,7 +102,7 @@ export default {
       this.open = true;
       this.$nextTick(() => {
         this.$refs.addOutbound.loading = true;
-        API.getOrderDetails({ orderId: row.id }).then(
+        API.getOrderDetails({ id: row.id }).then(
           (res) => {
             const productDetailsList = res.data.data.map((x) => ({
               productCode: x.productCode,
@@ -110,7 +114,8 @@ export default {
             }));
             this.form = {
               customerName: row.customerName,
-              type: String(row.type),
+              orderType: String(row.type),
+              type: "",
               orderId: row.id,
               warehouseId: "",
               logisticsCode: "",
@@ -137,33 +142,18 @@ export default {
       this.open = false;
     },
     handleSubmit() {
-      if (!this.form.id) {
-        API.outboundAdd(this.form).then(
-          () => {
-            this.msgSuccess(this.$t("addSuccess"));
-            this.$refs.addCustomer.loading = false;
-            this.open = false;
-            this.getList();
-          },
-          (err) => {
-            console.log("outboundAdd: " + err);
-            this.$refs.addCustomer.loading = false;
-          }
-        );
-      } else {
-        API.outboundEdit(this.form).then(
-          () => {
-            this.msgSuccess(this.$t("editSuccess"));
-            this.open = false;
-            this.$refs.addCustomer.loading = false;
-            this.getList();
-          },
-          (err) => {
-            console.log("outboundEdit: " + err);
-            this.$refs.addCustomer.loading = false;
-          }
-        );
-      }
+      API.salesOutbound(this.form).then(
+        () => {
+          this.msgSuccess(this.$t("addSuccess"));
+          this.$refs.addOutbound.loading = false;
+          this.open = false;
+          this.getList();
+        },
+        (err) => {
+          console.log("outboundAdd: " + err);
+          this.$refs.addOutbound.loading = false;
+        }
+      );
     },
 
     showAddress(row) {
@@ -250,6 +240,7 @@ export default {
         :orderTypeList="orderTypeList"
         :warehouseSelectList="warehouseSelectList"
         :warehouseTypeList="warehouseTypeList"
+        :outboundTypeList="outboundTypeList"
         @submit="handleSubmit"
         @cancel="handleCancel"
         ref="addOutbound"

+ 274 - 0
src/views/inbound-outbound/transfer/index.vue

@@ -0,0 +1,274 @@
+
+
+<script>
+import test from "@/components/form-test/index.vue";
+import query from "@/components/query/index.vue";
+
+import * as API from "@/api/inbound-outbound/transfer.js";
+
+import { warehouseSelectList } from "@/api/product-material/warehouse/index.js";
+import sendTransfer from "./sendTransfer.vue";
+
+export default {
+  components: {
+    test,
+    query,
+    sendTransfer,
+  },
+  data() {
+    return {
+      warehouseSelectList: [],
+      warehouseTypeList: [],
+      btnForm: {
+        otherButton: {
+          list: [
+            {
+              name: "发起调仓",
+              methodsText: "send",
+              type: "primary",
+              send: () => {
+                this.handleSend();
+              },
+            },
+          ],
+        },
+      },
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        keyword: "",
+        outWarehouseId: "",
+        inWarehouseId: "",
+        inStatus: "",
+      },
+      selectConfig: [
+        {
+          label: "调出仓库",
+          prop: "outWarehouseId",
+          data: [],
+        },
+        {
+          label: "调入仓库",
+          prop: "inWarehouseId",
+          data: [],
+        },
+        {
+          label: "调仓状态",
+          prop: "inStatus",
+          data: [],
+        },
+      ],
+      tableList: [],
+      total: 0,
+      loading: false,
+      titleText: "手动出库",
+      open: false,
+      form: {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      },
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.warehouseTypeList = businessDictData.find(
+      (item) => item.code === "warehouseType"
+    ).children;
+    warehouseSelectList().then((res) => {
+      this.warehouseSelectList = res.data.data;
+      this.selectConfig[0].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+      this.selectConfig[1].data = this.warehouseSelectList.map((item) => ({
+        label: item.name,
+        value: item.id,
+      }));
+    });
+    this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      API.transferList(this.queryParams).then(
+        (res) => {
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("transferList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleQuery() {
+      this.getList();
+    },
+    handleSend() {
+      this.form = {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      };
+      this.open = true;
+    },
+    handleCancel() {
+      this.form = {
+        outWarehouseId: "",
+        inWarehouseId: "",
+        remark: "",
+        changeProductList: [],
+      };
+      this.open = false;
+    },
+
+    handleSubmit() {
+      API.sendTransfer(this.form).then(
+        () => {
+          this.msgSuccess(this.$t("addSuccess"));
+          this.$refs.sendTransfer.loading = false;
+          this.open = false;
+          this.getList();
+        },
+        (err) => {
+          console.log("sendTransfer: " + err);
+          this.$refs.sendTransfer.loading = false;
+        }
+      );
+    },
+    handleReceive(row) {
+      this.$confirm("是否确认接收 ?", {
+        confirmButtonText: this.$t("submitText"),
+        cancelButtonText: this.$t("cancelText"),
+        type: "warning",
+      }).then(() => {
+        API.receive({ id: row.id, inQuantity: row.outQuantity }).then(() => {
+          this.msgSuccess("接收成功");
+          this.getList();
+        });
+      });
+    },
+
+    showAddress(row) {
+      return (
+        <div>
+          {row.countryName} , {row.provinceName} , {row.cityName}
+        </div>
+      );
+    },
+  },
+};
+</script>
+
+
+<template>
+  <div class="box-card">
+    <el-card class="header">
+      <test :form-config="btnForm"></test>
+    </el-card>
+    <el-card class="body-main">
+      <query
+        :selectConfig="selectConfig"
+        :req="queryParams"
+        :isShowMore="true"
+        @handleQuery="handleQuery"
+        @handleMore="
+          () => {
+            queryDialog = true;
+          }
+        "
+      ></query>
+      <el-table :data="tableList" v-loading="loading">
+        <el-table-column label="物品编码" align="center" prop="code" />
+        <el-table-column label="物品名称" align="center" prop="name" />
+        <el-table-column label="规格" align="center" prop="specs" />
+        <el-table-column
+          label="调出仓库"
+          align="center"
+          prop="outWarehouseName"
+        />
+        <el-table-column label="调出数量" align="center" prop="outQuantity" />
+        <el-table-column label="操作人" align="center" prop="outUserName" />
+        <el-table-column
+          label="调入仓库"
+          align="center"
+          prop="inWarehouseName"
+        />
+        <el-table-column label="接收数量" align="center" prop="inQuantity" />
+        <el-table-column label="接收人" align="center" prop="inUserName" />
+        <el-table-column
+          label="状态"
+          align="center"
+          prop="inStatus"
+          :formatter="
+            (row) => {
+              if (row.inStatus === 0) {
+                return '待接收';
+              } else {
+                return '已接收';
+              }
+            }
+          "
+        />
+        <el-table-column :label="$t('operation')" align="center" width="120">
+          <template slot-scope="scope">
+            <el-button
+              type="text"
+              v-if="scope.row.inStatus === 0"
+              @click="handleReceive(scope.row)"
+              >接收
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <pagination
+        v-show="total > 0"
+        :total="total"
+        :page.sync="queryParams.pageNum"
+        :limit.sync="queryParams.pageSize"
+        @pagination="getList"
+      />
+    </el-card>
+
+    <el-dialog
+      :title="titleText"
+      :visible.sync="open"
+      v-if="open"
+      width="80%"
+      top="60px"
+    >
+      <send-transfer
+        :form="form"
+        :warehouseSelectList="warehouseSelectList"
+        :warehouseTypeList="warehouseTypeList"
+        @submit="handleSubmit"
+        @cancel="handleCancel"
+        ref="sendTransfer"
+      ></send-transfer>
+    </el-dialog>
+  </div>
+</template>
+
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+  display: flex;
+  flex-direction: column;
+  .header {
+    // height: 100px;
+    margin-bottom: 10px;
+    box-sizing: border-box;
+  }
+  .body-main {
+    flex: 1;
+  }
+}
+</style>

+ 247 - 0
src/views/inbound-outbound/transfer/sendTransfer.vue

@@ -0,0 +1,247 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-row :gutter="10">
+          <el-col :span="6">
+            <el-form-item label="调出仓库" prop="outWarehouseId">
+              <el-select
+                v-model="form.outWarehouseId"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in warehouseSelectList"
+                  :key="item.id"
+                  :label="item.name"
+                  :value="item.id"
+                >
+                  <span style="float: left">{{
+                    `${item.name}(${dictDataEcho(
+                      item.type,
+                      warehouseTypeList
+                    )})`
+                  }}</span>
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="6">
+            <el-form-item label="调入仓库" prop="inWarehouseId">
+              <el-select
+                v-model="form.inWarehouseId"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in warehouseSelectList"
+                  :key="item.id"
+                  :label="item.name"
+                  :value="item.id"
+                >
+                  <span style="float: left">{{
+                    `${item.name}(${dictDataEcho(
+                      item.type,
+                      warehouseTypeList
+                    )})`
+                  }}</span>
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="12">
+            <el-form-item label="备注" prop="remark">
+              <el-input
+                v-model="form.remark"
+                placeholder="请输入"
+                type="textarea"
+                :rows="3"
+              >
+              </el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <div style="margin-bottom: 20px">
+          <labelTitle content="调仓明细"></labelTitle>
+        </div>
+        <el-form-item label-width="0px">
+          <el-button type="primary" size="mini" @click="handleAddProduct">
+            添加明细</el-button
+          >
+        </el-form-item>
+        <el-form-item>
+          <el-table :data="form.changeProductList">
+            <el-table-column label="产品编码" prop="productCode">
+            </el-table-column>
+            <el-table-column label="产品名称" prop="productName">
+            </el-table-column>
+            <el-table-column label="规格" prop="name"> </el-table-column>
+
+            <el-table-column label="调仓数量" prop="quantity">
+              <template slot-scope="scope">
+                <el-form-item
+                  :prop="'changeProductList.' + scope.$index + '.quantity'"
+                  :rules="formRules.quantity"
+                  :inline-message="true"
+                  label-width="0"
+                >
+                  <el-input
+                    v-model="scope.row.quantity"
+                    :placeholder="$t('pleaseInput')"
+                    size="mini"
+                  >
+                  </el-input>
+                </el-form-item>
+              </template>
+            </el-table-column>
+
+            <el-table-column
+              :label="$t('operation')"
+              width="100"
+              align="center"
+            >
+              <template slot-scope="scope">
+                <el-button type="text" @click="deleteRow(scope.$index)">{{
+                  $t("delete")
+                }}</el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+    <el-dialog
+      :title="$t('goodsSelect')"
+      v-if="selectDialog"
+      :visible.sync="selectDialog"
+      width="80%"
+      top="60px"
+    >
+      <selectProduct @select="handleSelect"></selectProduct>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+import selectProduct from "@/components/select-product/index.vue";
+
+import { getToken } from "@/util/auth";
+
+export default {
+  name: "addManualOutbound",
+  components: { labelTitle, selectProduct },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    warehouseSelectList: {
+      type: Array,
+      default: () => [],
+    },
+    warehouseTypeList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      uploadHeader: {
+        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
+        "Blade-Auth": "bearer " + getToken(),
+      },
+      loading: false,
+      selectDialog: false,
+      formRules: {
+        quantity: [
+          {
+            required: true,
+            message: "请输入本次出库数量",
+            trigger: "blur",
+          },
+        ],
+        outWarehouseId: [
+          {
+            required: true,
+            message: "请选择调出仓库",
+            trigger: "change",
+          },
+        ],
+        inWarehouseId: [
+          {
+            required: true,
+            message: "请选择调入仓库",
+            trigger: "change",
+          },
+        ],
+      },
+    };
+  },
+  created() {},
+  methods: {
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          if (!this.form.changeProductList.length > 0)
+            return this.msgInfo("请添加调仓明细");
+          this.loading = true;
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+    handleAddProduct() {
+      if (this.form.outWarehouseId === this.form.inWarehouseId)
+        return this.msgInfo("调出和调入仓库不可一致");
+      if (!(this.form.outWarehouseId && this.form.inWarehouseId))
+        return this.msgInfo("请先选择要调的仓库");
+      this.selectDialog = true;
+    },
+    handleSelect(row) {
+      const flag = this.form.changeProductList.some(
+        (x) => x.productId === row.id
+      );
+      if (flag) return this.msgInfo("该物品已经选择");
+      const product = {
+        productCode: row.code,
+        productName: row.name,
+        productId: row.id,
+        quantity: "",
+      };
+      this.form.changeProductList.push(product);
+    },
+    deleteRow(index) {
+      this.form.changeProductList.splice(index, 1);
+      this.msgSuccess(this.$t("deleteSuccess"));
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 64 - 33
src/views/inventory-management/query/index.vue

@@ -93,15 +93,15 @@ export default {
 </script>
   <template>
   <div>
-    <el-tabs v-model="activeName" @tab-click="handleClick">
-      <el-tab-pane label="仓库库存" name="first"> </el-tab-pane>
-      <el-tab-pane label="产品库存" name="second"> </el-tab-pane>
-      <el-tab-pane label="组合库存" name="third"> </el-tab-pane>
-    </el-tabs>
     <el-card class="box-card">
+      <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
+        <el-tab-pane label="按仓库" name="first"> </el-tab-pane>
+        <el-tab-pane label="按产品" name="second"> </el-tab-pane>
+        <el-tab-pane label="按组合" name="third"> </el-tab-pane>
+      </el-tabs>
       <div v-show="activeName === 'first'">
         <query
-          :selectConfig="selectConfigOne"
+          :selectConfig="selectConfigTwo"
           :req="queryParams"
           :isShowMore="false"
           @handleQuery="handleQuery"
@@ -112,22 +112,40 @@ export default {
           "
         ></query>
         <el-table :data="tableList" v-loading="loading">
-          <el-table-column
+          <!-- <el-table-column
             label="产品类型"
             align="center"
             :formatter="(row) => dictDataEcho(row.type, productTypeList)"
+          /> -->
+          <el-table-column
+            label="仓库名称"
+            align="center"
+            prop="customerName"
           />
-          <el-table-column label="SPU编码" align="center" prop="customerName" />
           <el-table-column label="产品编码" align="center" prop="amountMoney" />
           <el-table-column label="产品名称" align="center" />
+          <el-table-column label="规格" align="center" prop="orderTime" />
           <el-table-column label="单位" align="center" prop="orderTime" />
-          <el-table-column label="现有库存" align="center" />
+          <el-table-column label="库存数量" align="center" />
+          <el-table-column label="查看" align="center">
+            <template>
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >出库记录</el-button
+              >
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >入库记录</el-button
+              >
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >调仓记录</el-button
+              >
+            </template>
+          </el-table-column>
         </el-table>
       </div>
 
       <div v-show="activeName === 'second'">
         <query
-          :selectConfig="selectConfigTwo"
+          :selectConfig="selectConfigOne"
           :req="queryParams"
           :isShowMore="false"
           @handleQuery="handleQuery"
@@ -138,19 +156,24 @@ export default {
           "
         ></query>
         <el-table :data="tableList" v-loading="loading">
-          <el-table-column
-            label="仓库类型"
-            align="center"
-            :formatter="(row) => dictDataEcho(row.type, warehouseTypeList)"
-          />
-          <el-table-column
-            label="产品名称"
-            align="center"
-            prop="customerName"
-          />
-
-          <el-table-column label="现有库存" align="center" />
-          <el-table-column label="仓管员" align="center" prop="orderTime" />
+          <el-table-column label="产品编码" align="center" prop="amountMoney" />
+          <el-table-column label="产品名称" align="center" />
+          <el-table-column label="规格" align="center" prop="orderTime" />
+          <el-table-column label="单位" align="center" prop="orderTime" />
+          <el-table-column label="库存数量" align="center" />
+          <el-table-column label="查看" align="center">
+            <template>
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >出库记录</el-button
+              >
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >入库记录</el-button
+              >
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >调仓记录</el-button
+              >
+            </template>
+          </el-table-column>
         </el-table>
       </div>
 
@@ -168,20 +191,28 @@ export default {
         ></query>
         <el-table :data="tableList" v-loading="loading">
           <el-table-column
-            label="产品类型"
-            align="center"
-            :formatter="(row) => dictDataEcho(row.type, productTypeList)"
-          />
-          <el-table-column
-            label="产品编码"
+            label="组合编码"
             align="center"
             prop="customerName"
           />
-
-          <el-table-column label="产品名称" align="center" />
+          <el-table-column label="组合名称" align="center" />
+          <el-table-column label="规格" align="center" />
           <el-table-column label="单位" align="center" />
-
           <el-table-column label="库存数量" align="center" />
+          <el-table-column label="可组合数量" align="center" />
+          <el-table-column label="查看" align="center">
+            <template>
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >出库记录</el-button
+              >
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >入库记录</el-button
+              >
+              <el-button type="text" @click="deleteRow(scope.$index)"
+                >调仓记录</el-button
+              >
+            </template>
+          </el-table-column>
         </el-table>
       </div>
       <pagination
@@ -196,7 +227,7 @@ export default {
 </template>
 <style lang="scss" scoped>
 .box-card {
-  height: calc(100vh - 110px - 60px);
+  height: calc(100vh - 110px);
   overflow-y: auto;
 }
 </style>

+ 282 - 0
src/views/order-management/afterSales/addAfterSales.vue

@@ -0,0 +1,282 @@
+<template>
+  <div v-loading="loading">
+    <div class="form-box">
+      <el-form
+        label-position="top"
+        :model="form"
+        ref="form"
+        :rules="formRules"
+        label-width="100px"
+      >
+        <el-form-item label="客户名称" prop="customerInfoId">
+          <el-select
+            v-model="form.customerInfoId"
+            :disabled="!isAdd"
+            placeholder="请选择"
+            style="width: 100%"
+            @change="handleCustomerChange"
+          >
+            <el-option
+              v-for="item in customerSelectList"
+              :key="item.id"
+              :label="item.name"
+              :value="item.id"
+            >
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-row :gutter="10">
+          <el-col :span="8">
+            <el-form-item label="订单编号" prop="id">
+              <el-select
+                v-model="form.id"
+                placeholder="请选择"
+                :disabled="!isAdd"
+                style="width: 100%"
+                @change="handleOrderChange"
+              >
+                <el-option
+                  v-for="item in orderList"
+                  :key="item.id"
+                  :label="item.code"
+                  :value="item.id"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="10">
+            <div style="line-height: 40px; margin-top: 50px" v-if="form.id">
+              <el-button type="text" @click="detailsDialog = true">
+                查看订单
+              </el-button>
+            </div>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="8">
+            <el-form-item label="售后类型" prop="type">
+              <el-select
+                v-model="form.type"
+                placeholder="请选择"
+                :disabled="!isAdd"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in afterSalesTypeList"
+                  :key="item.id"
+                  :label="item.dictValue"
+                  :value="item.dictKey"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-form-item label="售后原因" prop="remark" v-if="isAdd">
+          <el-input
+            v-model="form.remark"
+            :disabled="!isAdd"
+            placeholder="请输入"
+            type="textarea"
+            :rows="3"
+          >
+          </el-input>
+        </el-form-item>
+        <el-form-item label="售后原因" prop="remarkOne" v-else>
+          <el-input
+            v-model="form.remarkOne"
+            :disabled="!isAdd"
+            placeholder="请输入"
+            type="textarea"
+            :rows="3"
+          >
+          </el-input>
+        </el-form-item>
+
+        <div style="margin-bottom: 20px" v-if="!isAdd">
+          <labelTitle content="跟进记录"></labelTitle>
+        </div>
+        <el-form-item label="售后状态" prop="afterSalesStatus" v-if="!isAdd">
+          <el-select
+            v-model="form.afterSalesStatus"
+            placeholder="请选择"
+            style="width: 100%"
+          >
+            <el-option
+              v-for="item in afterSalesStatusList"
+              :key="item.id"
+              :label="item.dictValue"
+              :value="item.dictKey"
+            >
+            </el-option>
+          </el-select>
+          <!-- <el-radio-group v-model="form.afterSalesStatus">
+            <el-radio-button
+              v-for="x in afterSalesStatusList"
+              x.id
+              :label="x.dictKey"
+            >
+              {{ x.dictValue }}</el-radio-button
+            >
+          </el-radio-group> -->
+        </el-form-item>
+        <el-form-item label="跟进说明" prop="remark" v-if="!isAdd">
+          <el-input
+            v-model="form.remark"
+            placeholder="请输入"
+            type="textarea"
+            :rows="3"
+          >
+          </el-input>
+        </el-form-item>
+      </el-form>
+    </div>
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+    <el-dialog
+      title="订单详情"
+      v-if="detailsDialog"
+      :visible.sync="detailsDialog"
+      width="50%"
+      top="60px"
+    >
+      <OrderDetails :orderId="selectOrderId"></OrderDetails>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { getToken } from "@/util/auth";
+
+import labelTitle from "@/components/label-title/index.vue";
+import OrderDetails from "@/components/order/details.vue";
+
+import { getOrderCode } from "@/api/order-management/afterSales/index.js";
+
+export default {
+  name: "addAfterSales",
+  components: {
+    labelTitle,
+    OrderDetails,
+  },
+  props: {
+    form: {
+      type: Object,
+      default: () => {},
+    },
+    isAdd: {
+      type: Boolean,
+      default: true,
+    },
+    customerSelectList: {
+      type: Array,
+      default: () => [],
+    },
+    afterSalesTypeList: {
+      type: Array,
+      default: () => [],
+    },
+    afterSalesStatusList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      uploadHeader: {
+        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
+        "Blade-Auth": "bearer " + getToken(),
+      },
+
+      loading: false,
+
+      formRules: {
+        customerInfoId: [
+          {
+            required: true,
+            message: "请选择客户",
+            trigger: "change",
+          },
+        ],
+        id: [
+          {
+            required: true,
+            message: "请选择订单",
+            trigger: "change",
+          },
+        ],
+        type: [
+          {
+            required: true,
+            message: "请选择售后类型",
+            trigger: "change",
+          },
+        ],
+        afterSalesStatus: [
+          {
+            required: true,
+            message: "请选择售后状态",
+            trigger: "change",
+          },
+        ],
+
+        remark: [
+          {
+            required: true,
+            message: this.isAdd ? "请输入售后原因" : "请输入跟进说明",
+            trigger: "blur",
+          },
+        ],
+      },
+      orderList: [],
+      detailsDialog: false,
+      selectOrderId: "",
+    };
+  },
+  created() {},
+  mounted() {
+    if (this.form.oredrInfoId) {
+      this.selectOrderId = this.form.oredrInfoId;
+    }
+  },
+  methods: {
+    handleSubmit() {
+      this.$refs.form.validate((valid) => {
+        if (valid) {
+          this.loading = true;
+          this.$emit("submit");
+        }
+      });
+    },
+    handleCancel() {
+      this.$emit("cancel");
+    },
+    handleCustomerChange(val) {
+      this.loading = true;
+      getOrderCode({ customerInfoId: val }).then((res) => {
+        this.orderList = res.data.data;
+        this.loading = false;
+      });
+    },
+    handleOrderChange(val) {
+      this.selectOrderId = val;
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.form-box {
+  height: calc(100vh - 280px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 10px;
+}
+</style>

+ 331 - 0
src/views/order-management/afterSales/index.vue

@@ -0,0 +1,331 @@
+
+
+<script>
+import test from "@/components/form-test/index.vue";
+import query from "@/components/query/index.vue";
+
+import byTable from "@/components/by-table/index.js";
+import addAfterSales from "./addAfterSales.vue";
+
+import * as API from "@/api/order-management/afterSales/index.js";
+// import { customerList } from "@/api/product-material/customer/index.js";
+
+export default {
+  components: {
+    test,
+    byTable,
+    query,
+    addAfterSales,
+  },
+  data() {
+    return {
+      afterSalesTypeList: [],
+      orderStatusList: [],
+      afterSalesStatusList: [],
+      customerSelectList: [],
+      btnForm: {
+        otherButton: {
+          list: [
+            {
+              name: "tiann",
+              methodsText: "add",
+              type: "primary",
+              add: () => {
+                this.handleAdd();
+              },
+            },
+          ],
+        },
+      },
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        keyword: "",
+        type: "",
+        afterSalesStatus: "",
+      },
+      selectConfig: [
+        {
+          label: "售后类型",
+          prop: "type",
+          data: [],
+        },
+        {
+          label: "状态",
+          prop: "afterSalesStatus",
+          data: [],
+        },
+      ],
+      tableList: [],
+      total: 0,
+      loading: false,
+      titleText: "",
+      open: false,
+      form: {
+        id: "",
+        type: "",
+        remark: "",
+      },
+      isAdd: false,
+    };
+  },
+  created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.afterSalesTypeList = businessDictData.find(
+      (item) => item.code === "afterSalesType"
+    ).children;
+    this.selectConfig[0].data = this.afterSalesTypeList.map((item) => ({
+      label: item.dictValue,
+      value: item.dictKey,
+    }));
+    this.orderStatusList = businessDictData.find(
+      (item) => item.code === "orderStatus"
+    ).children;
+    this.afterSalesStatusList = businessDictData.find(
+      (item) => item.code === "afterSalesStatus"
+    ).children;
+    this.selectConfig[1].data = this.afterSalesStatusList.map((item) => ({
+      label: item.dictValue,
+      value: item.dictKey,
+    }));
+    // customerList({ pageNum: 1, pageSize: 999 }).then((res) => {
+    //   this.customerSelectList = res.data.data.records;
+    // });
+    API.customerSelectData().then((res) => {
+      this.customerSelectList = res.data.data;
+    });
+    this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      API.afterSalesList(this.queryParams).then(
+        (res) => {
+          console.log(res, "ss");
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("afterSalesList: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    handleQuery() {
+      this.getList();
+    },
+    handleAdd() {
+      this.titleText = "添加售后记录";
+      this.form = {
+        id: "",
+        type: "",
+        remark: "",
+      };
+      this.isAdd = true;
+      this.open = true;
+    },
+    handleCancel() {
+      this.open = false;
+    },
+    handleFollow(row) {
+      this.titleText = "售后跟进";
+      this.form = {
+        customerInfoId: row.customerInfoId,
+        id: row.code,
+        type: String(row.type),
+        remarkOne: row.remark,
+        orderInfoId: row.id,
+        afterSalesStatus: "",
+        remark: "",
+      };
+      this.isAdd = false;
+      this.open = true;
+      // this.$confirm("是否确认进行该操作", {
+      //   confirmButtonText: this.$t("submitText"),
+      //   cancelButtonText: this.$t("cancelText"),
+      //   type: "warning",
+      // }).then(() => {
+      //   API.orderEdit({ id: row.id, status }).then(() => {
+      //     this.msgSuccess("操作成功");
+      //     this.getList();
+      //   });
+      // });
+    },
+    handleSubmit() {
+      if (this.isAdd) {
+        API.afterSalesAdd(this.form).then(
+          () => {
+            this.msgSuccess(this.$t("addSuccess"));
+            this.$refs.addAfterSales.loading = false;
+            this.open = false;
+            this.getList();
+          },
+          (err) => {
+            console.log("afterSalesAdd: " + err);
+            this.$refs.addAfterSales.loading = false;
+          }
+        );
+      } else {
+        delete this.form.customerInfoId;
+        delete this.form.remarkOne;
+        delete this.form.id;
+        delete this.form.type;
+        API.afterSalesFollow(this.form).then(
+          () => {
+            this.msgSuccess("操作成功");
+            this.$refs.addAfterSales.loading = false;
+            this.open = false;
+            this.getList();
+          },
+          (err) => {
+            console.log("afterSalesFollow: " + err);
+            this.$refs.addAfterSales.loading = false;
+          }
+        );
+      }
+    },
+
+    handleDelete(row) {
+      this.$confirm(this.$t("askDeleteData"), {
+        confirmButtonText: this.$t("submitText"),
+        cancelButtonText: this.$t("cancelText"),
+        type: "warning",
+      }).then(() => {
+        API.orderDel({ id: row.id }).then(() => {
+          this.msgSuccess(this.$t("deleteSuccess"));
+          this.getList();
+        });
+      });
+    },
+    showAddress(row) {
+      return (
+        <div>
+          {row.countryName} , {row.provinceName} , {row.cityName}
+        </div>
+      );
+    },
+  },
+};
+</script>
+
+
+<template>
+  <div class="box-card">
+    <el-card class="header">
+      <el-button type="primary" size="mini" @click="handleAdd">
+        添加售后记录
+      </el-button>
+    </el-card>
+    <el-card class="body-main">
+      <query
+        :selectConfig="selectConfig"
+        :req="queryParams"
+        :isShowMore="true"
+        @handleQuery="handleQuery"
+        @handleMore="
+          () => {
+            queryDialog = true;
+          }
+        "
+      ></query>
+      <el-table :data="tableList" v-loading="loading">
+        <el-table-column
+          label="售后类型"
+          align="center"
+          :formatter="(row) => dictDataEcho(row.type, afterSalesTypeList)"
+        />
+        <el-table-column label="订单编号" align="center" prop="code" />
+        <el-table-column label="客户名称" align="center" prop="customerName" />
+        <el-table-column label="订单金额" align="center" prop="amountMoney" />
+        <el-table-column
+          label="收件城市"
+          align="center"
+          :formatter="showAddress"
+        />
+        <el-table-column
+          label="详细地址"
+          align="center"
+          prop="detailedAddress"
+        />
+        <el-table-column
+          label="下单时间"
+          align="center"
+          prop="orderTime"
+          width="150"
+        />
+        <el-table-column
+          label="登记时间"
+          align="center"
+          prop="createTime"
+          width="150"
+        />
+        <el-table-column
+          label="状态"
+          align="center"
+          :formatter="
+            (row) => dictDataEcho(row.afterSalesStatus, afterSalesStatusList)
+          "
+        />
+        <el-table-column
+          label="订单状态"
+          align="center"
+          :formatter="(row) => dictDataEcho(row.status, orderStatusList)"
+        />
+        <el-table-column label="操作" align="center" width="120">
+          <template slot-scope="scope">
+            <el-button type="text" @click="handleFollow(scope.row)"
+              >跟进
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <pagination
+        v-show="total > 0"
+        :total="total"
+        :page.sync="queryParams.pageNum"
+        :limit.sync="queryParams.pageSize"
+        @pagination="getList"
+      />
+    </el-card>
+
+    <el-dialog
+      :title="titleText"
+      :visible.sync="open"
+      v-if="open"
+      width="30%"
+      top="60px"
+    >
+      <add-after-sales
+        :form="form"
+        :isAdd="isAdd"
+        :customerSelectList="customerSelectList"
+        :afterSalesTypeList="afterSalesTypeList"
+        :afterSalesStatusList="afterSalesStatusList"
+        @submit="handleSubmit"
+        @cancel="handleCancel"
+        ref="addAfterSales"
+      ></add-after-sales>
+    </el-dialog>
+  </div>
+</template>
+
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+  display: flex;
+  flex-direction: column;
+  .header {
+    // height: 100px;
+    margin-bottom: 10px;
+    box-sizing: border_management-box;
+  }
+  .body-main {
+    flex: 1;
+  }
+}
+</style>

+ 101 - 0
src/views/process/backlog/index.vue

@@ -0,0 +1,101 @@
+<template>
+  <el-card class="box-card">
+    <el-table :data="tableList" v-loading="loading">
+      <el-table-column label="待办类型" prop="moduleName" width="180" />
+      <el-table-column label="流程标题" prop="flowTitle" />
+      <el-table-column
+        label="发起人"
+        align="center"
+        prop="userName"
+        width="140"
+      />
+      <el-table-column
+        label="发起时间"
+        align="center"
+        prop="createTime"
+        width="200"
+      />
+      <el-table-column label="操作" align="center" width="120">
+        <template slot-scope="scope">
+          <el-button type="text" @click="clickManage(scope.row)" v-db-click
+            >办理</el-button
+          >
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total > 0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+  </el-card>
+</template>
+
+<script>
+// import { getWaitingProcessingPage } from '@/api/process/processNode.js'
+
+export default {
+  name: "processBacklog",
+  data() {
+    return {
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+      },
+      loading: false,
+      tableList: [{}],
+      total: 0,
+    };
+  },
+  created() {},
+  mounted() {
+    // this.getList();
+  },
+  methods: {
+    getList() {
+      this.loading = true;
+      getWaitingProcessingPage(this.queryParams).then(
+        (res) => {
+          this.tableList = res.data.data.records;
+          this.total = res.data.data.total;
+          this.loading = false;
+        },
+        (err) => {
+          console.log("getWaitingProcessingPage: " + err);
+          this.loading = false;
+        }
+      );
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    clickManage(row) {
+      this.$router.push({
+        path: "/process/examinationApproval/index",
+        query: {
+          id: row.flowLinkNo,
+          processInstanceId: row.flowId,
+          flowCode: row.flowCode,
+        },
+      });
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.box-card {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+}
+</style>

+ 210 - 0
src/views/process/examinationApproval/approvalRecords.vue

@@ -0,0 +1,210 @@
+<template>
+  <div>
+    <!-- <el-tabs v-model="activeName" @tab-click="handleClick"> -->
+    <el-tabs v-model="activeName">
+      <el-tab-pane label="审批记录" name="first">
+        <div v-for="(item, index) in recordsList" :key="index">
+          <el-row type="flex">
+            <el-col :span="4">
+              <div
+                :style="
+                  [97, 99].includes(item.type)
+                    ? 'width: 40px; height: 40px; border-radius: 10px; position: relative; background-color: #dcdfe6'
+                    : 'width: 40px; height: 40px; border-radius: 10px; position: relative; background-color: #0084FF'
+                "
+              >
+                <img
+                  v-if="item.nodeType === 1"
+                  src="/img/process/icon_begin.svg"
+                  style="width: 20px; position: absolute; top: 10px; left: 10px"
+                  fit="scale-down"
+                />
+                <img
+                  v-else-if="item.nodeType === 2"
+                  src="/img/process/icon_shenhe.svg"
+                  style="width: 20px; position: absolute; top: 10px; left: 10px"
+                  fit="scale-down"
+                />
+                <img
+                  v-else-if="item.nodeType === 3"
+                  src="/img/process/icon_audit.svg"
+                  style="width: 20px; position: absolute; top: 10px; left: 10px"
+                  fit="scale-down"
+                />
+                <img
+                  v-else-if="item.nodeType === 4"
+                  src="/img/process/icon_handle.svg"
+                  style="width: 20px; position: absolute; top: 10px; left: 10px"
+                  fit="scale-down"
+                />
+                <img
+                  v-else-if="item.nodeType === 5"
+                  src="/img/process/icon_handle.svg"
+                  style="width: 20px; position: absolute; top: 10px; left: 10px"
+                  fit="scale-down"
+                />
+                <img
+                  v-else-if="item.nodeType === 99"
+                  src="/img/process/icon_end.svg"
+                  style="width: 20px; position: absolute; top: 10px; left: 10px"
+                  fit="scale-down"
+                />
+                <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"
+                  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"
+                  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"
+                  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;"
+              ></div>
+            </el-col>
+            <el-col :span="20">
+              <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>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>发起人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 2">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #39c55a">(通过)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>审批人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 3">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #f84539">(不通过)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>审批人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 4">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #39c55a">(同意)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>审批人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 5">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #f84539">(驳回)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>审批人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 6">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #39c55a">(完成)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>审批人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 97">
+                  <div>
+                    <div style="line-height: 28px">
+                      <span>{{ item.nodeName }}</span>
+                      <span style="color: #999">(未开始)</span>
+                    </div>
+                    <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                      <div>发起人: {{ item.userName }}</div>
+                      <div>{{ item.createTime }}</div>
+                    </div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 98">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #ff9315">(进行中)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>审批人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div v-else-if="item.type === 99">
+                  <div style="line-height: 28px">
+                    <span>{{ item.nodeName }}</span>
+                    <span style="color: #999">(结束)</span>
+                  </div>
+                  <div style="line-height: 28px; display: flex; justify-content: space-between; color: #ccc">
+                    <div>发起人: {{ item.userName }}</div>
+                    <div>{{ item.createTime }}</div>
+                  </div>
+                </div>
+                <div style="line-height: 28px; color: #999">
+                  <div v-html="getStyle(item.remarks)"></div>
+                </div>
+              </div>
+            </el-col>
+          </el-row>
+          <br />
+        </div>
+      </el-tab-pane>
+    </el-tabs>
+  </div>
+</template>
+
+<script>
+export default {
+  name: 'ApprovalRecords',
+  props: {
+    transferParams: Object,
+    recordsList: Array,
+  },
+  data() {
+    return {
+      activeName: 'first',
+    }
+  },
+  created() {},
+  mounted() {},
+  methods: {
+    getStyle(text) {
+      if (text) {
+        return text.replace(/\n|\r\n/g, '<br>')
+      } else {
+        return ''
+      }
+    },
+  },
+}
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 216 - 0
src/views/process/examinationApproval/index.vue

@@ -0,0 +1,216 @@
+<template>
+  <div
+    v-loading="loadingStatus"
+    element-loading-text="提交数据中,请稍后"
+    element-loading-spinner="el-icon-loading"
+    element-loading-background="rgba(0, 0, 0, 0.2)"
+  >
+    <el-row>
+      <el-col :span="18" style="padding-right: 5px">
+        <el-card class="card-top"> </el-card>
+        <div style="height: 10px"></div>
+        <el-card class="card-bottom">
+          <labelTitle content="操作"></labelTitle>
+          <br />
+          <div style="padding-left: 1vw">
+            <el-form ref="ruleForm" :model="form" :rules="formRules">
+              <el-form-item prop="flowRemark">
+                <el-input
+                  type="textarea"
+                  :rows="3"
+                  placeholder="请输入办理说明"
+                  v-model="form.flowRemark"
+                >
+                </el-input>
+              </el-form-item>
+            </el-form>
+            <div
+              style="padding-top: 16px"
+              v-if="transferParams.processInstanceId && !transferParams.status"
+            >
+              <div
+                v-for="(item, index) in buttonList"
+                :key="index"
+                style="display: inline"
+              >
+                <el-button
+                  :type="[1, 2, 4, 6].includes(item.type) ? 'primary' : ''"
+                  size="small"
+                  :style="index !== 0 ? 'margin-left: 10px' : ''"
+                  @click="clickSubmit(item.id)"
+                  v-db-click
+                >
+                  {{ item.typeName }}
+                </el-button>
+              </div>
+            </div>
+            <div style="padding-top: 16px" v-else>
+              <el-button
+                size="small"
+                type="primary"
+                @click="clickSubmit('', false)"
+                v-db-click
+                >提 交</el-button
+              >
+              <el-button
+                size="small"
+                @click="clickSubmit('', true)"
+                v-if="transferParams.flowCode === 'FUNDS'"
+                v-db-click
+                >暂 存</el-button
+              >
+              <el-button size="small" @click="clickCancel">取 消</el-button>
+            </div>
+          </div>
+        </el-card>
+      </el-col>
+      <el-col :span="6" style="padding-left: 5px">
+        <el-card class="card-right">
+          <ApprovalRecords
+            :transferParams="transferParams"
+            :recordsList="recordsList"
+          ></ApprovalRecords>
+        </el-card>
+      </el-col>
+    </el-row>
+  </div>
+</template>
+
+<script>
+import labelTitle from "@/components/label-title/index.vue";
+import ApprovalRecords from "./approvalRecords";
+
+export default {
+  name: "examinationApproval",
+  components: {
+    labelTitle,
+    ApprovalRecords,
+  },
+  data() {
+    return {
+      transferParams: {
+        id: "",
+        processInstanceId: "",
+        flowCode: "",
+        status: "",
+      },
+      form: {
+        flowRemark: "",
+      },
+      formRules: {
+        flowRemark: [
+          { required: true, message: "请输入办理说明", trigger: "blur" },
+        ],
+      },
+      loadingStatus: false,
+      recordsList: [],
+      buttonList: [],
+      startStatus: false,
+    };
+  },
+  created() {
+    //接收页面参数
+    this.transferParams = this.$route.query;
+    if (this.transferParams.processInstanceId) {
+      exampleInfo({ flowLinkNo: this.transferParams.id }).then((res) => {
+        this.recordsList = res.data.data;
+        let ongoing = res.data.data.filter((item) => item.type === 98);
+        if (ongoing && ongoing.length > 0) {
+          this.buttonList = ongoing[0].buttonList;
+          if (ongoing[0].nodeType === 1 || this.transferParams.status) {
+            this.startStatus = true;
+          }
+        }
+      });
+    } else {
+      exampleInfoShowFlow({ code: this.transferParams.flowCode }).then(
+        (res) => {
+          this.recordsList = res.data.data;
+          this.startStatus = true;
+        }
+      );
+    }
+  },
+  mounted() {},
+  methods: {
+    conversion(data) {
+      var attachments = [];
+      if (data && data.length > 0) {
+        for (let i = 0; i < data.length; i++) {
+          if (
+            data[i].response &&
+            data[i].response.data &&
+            data[i].response.data.details
+          ) {
+            attachments.push(data[i].response.data.details);
+          } else {
+            attachments.push(data[i]);
+          }
+        }
+      }
+      return attachments;
+    },
+    clickSubmit(ID, draftStatus) {
+      if (this.startStatus) {
+        this.$refs.make.$refs.ruleForm.validate((valid) => {
+          if (valid) {
+          }
+        });
+      } else {
+      }
+    },
+    clickCancel() {
+      this.$store.dispatch("delView", this.$route);
+      if (
+        this.transferParams.processInstanceId &&
+        !this.transferParams.status
+      ) {
+        this.$router.replace({
+          path: "/process/backlog/index",
+        });
+      } else {
+        if (this.transferParams.flowCode === "FUNDS") {
+          this.$router.replace({
+            path: "/tenant/finance/funds/index",
+          });
+        } else if (this.transferParams.flowCode === "APPLY") {
+          this.$router.replace({
+            path: "/supplyChain/purchasingManagement/purchase/index",
+          });
+        } else if (this.transferParams.flowCode === "PURCHASE") {
+          this.$router.replace({
+            path: "/supplyChain/purchasingManagement/awaitPurchase/index",
+          });
+        } else if (this.transferParams.flowCode === "RETURN") {
+          this.$router.replace({
+            path: "/supplyChain/purchasingManagement/salesReturn/index",
+          });
+        } else if (this.transferParams.flowCode === "REPORT_PRICE") {
+          this.$router.replace({
+            path: "/tenant/trading/quotationManagement/index",
+          });
+        } else if (this.transferParams.flowCode === "PAYMENT_GOODS") {
+          this.$router.replace({
+            path: "/tenant/wms/cgPayment/index",
+          });
+        }
+      }
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.card-top {
+  height: calc(100vh - 110px - 10px - 235px);
+  overflow-y: auto;
+}
+.card-bottom {
+  height: 235px;
+  overflow-y: auto;
+}
+.card-right {
+  height: calc(100vh - 110px);
+  overflow-y: auto;
+}
+</style>

+ 6 - 1
src/views/product-material/product/addProduct.vue

@@ -139,7 +139,7 @@
         </el-row>
         <el-form-item label="产品照片">
           <el-upload
-            action="http://36.134.91.96:10001/api/service-file/uploadFile"
+            action="/api/service-file/uploadFile"
             :headers="uploadHeader"
             list-type="picture-card"
             :file-list="fileList"
@@ -289,6 +289,7 @@
 <script>
 import labelTitle from "@/components/label-title/index.vue";
 import selectProduct from "@/components/select-product/index.vue";
+import { getToken } from "@/util/auth";
 
 import * as API from "@/api/product-material/product/index.js";
 export default {
@@ -305,6 +306,10 @@ export default {
   },
   data() {
     return {
+      uploadHeader: {
+        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
+        "Blade-Auth": "bearer " + getToken(),
+      },
       loading: false,
       selectList: [],
       productTypeList: [],

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

@@ -1,6 +1,7 @@
 
 
 <script>
+import test from "@/components/form-test/index.vue";
 import query from "@/components/query/index.vue";
 import sendGoods from "./sendGoods.vue";
 import * as API from "@/api/purchase-management/deliver-goods/index.js";
@@ -9,6 +10,7 @@ export default {
   components: {
     query,
     sendGoods,
+    test,
   },
   data() {
     return {
@@ -50,18 +52,41 @@ export default {
           prop: "type",
           data: [],
         },
+        {
+          label: "付款状态",
+          prop: "type",
+          data: [],
+        },
       ],
       tableList: [{}],
+      total: 0,
       loading: false,
       titleText: "",
       open: false,
       form: {
+        businessId: "",
+        businessType: "1",
+        logisticsCompanyCode: "",
+        code: "",
+        details: [],
+        fileInfos: [],
+      },
+      openArrive: false,
+      arriveForm: {
+        name: "",
         id: "",
-        receiptWarehouseId: "",
-        planArrivalTime: "",
-        cause: "",
-        goodsId: [],
+        code: "",
       },
+      arriveFormRules: {
+        id: [
+          {
+            required: true,
+            message: "请选择物流/快递单号",
+            trigger: "change",
+          },
+        ],
+      },
+
       selectData: [],
     };
   },
@@ -96,7 +121,7 @@ export default {
           this.loading = false;
         },
         (err) => {
-          console.log("purchaseList: " + err);
+          console.log("deliveryList: " + err);
           this.loading = false;
         }
       );
@@ -109,35 +134,48 @@ export default {
     },
     handleSend(row) {
       this.form = {
-        purchaseId: "",
+        businessId: "",
+        businessType: "1",
+        logisticsCompanyCode: "",
         code: "",
-        details: [
-          { purchaseId: "", applyPurchaseId: "", shipmentQuantity: "" },
-        ],
+        details: [],
         fileInfos: [],
       };
-      this.titleText = "发货";
+      this.titleText = "发货通知";
       this.open = true;
+      this.$nextTick(() => {
+        this.$refs.sendGoods.loading = true;
+        API.logisticsSelectData({ id: row.id }).then(
+          (res) => {
+            console.log(res, "aa");
+            this.$refs.sendGoods.loading = false;
+          },
+          (err) => {
+            this.$refs.sendGoods.loading = false;
+          }
+        );
+      });
     },
 
     handleCancel() {
       this.form = {
-        purchaseId: "",
+        businessId: "",
+        businessType: "1",
+        logisticsCompanyCode: "",
         code: "",
-        details: [
-          { purchaseId: "", applyPurchaseId: "", shipmentQuantity: "" },
-        ],
+        details: [],
         fileInfos: [],
       };
       this.open = false;
     },
     handleSubmit() {
-      API.deliveryAdd(this.form).then(
+      API.deliveryNotice(this.form).then(
         () => {
           this.msgSuccess(this.$t("addSuccess"));
           this.$refs.sendGoods.loading = false;
           this.open = false;
           this.getList();
+          this.handleCancel();
         },
         (err) => {
           console.log("sendPurchase: " + err);
@@ -145,35 +183,63 @@ export default {
         }
       );
     },
-    handleComplete(row) {
-      this.$confirm(this.$t("askDeleteData"), {
+    handleArrive(row) {
+      this.titleText = "到货通知";
+      this.openArrive = true;
+      // this.$confirm(this.$t("askDeleteData"), {
+      //   confirmButtonText: this.$t("submitText"),
+      //   cancelButtonText: this.$t("cancelText"),
+      //   type: "warning",
+      // }).then(() => {
+      //   API.completePurchase({ id: row.id }).then(() => {
+      //     this.msgSuccess(this.$t("deleteSuccess"));
+      //     this.getList();
+      //   });
+      // });
+    },
+    handlePurchaseEnd(row) {
+      this.$confirm("是否确定此操作 ?", {
         confirmButtonText: this.$t("submitText"),
         cancelButtonText: this.$t("cancelText"),
         type: "warning",
       }).then(() => {
-        API.completePurchase({ id: row.id }).then(() => {
+        API.purchaseEnd({ id: row.id }).then(() => {
           this.msgSuccess(this.$t("deleteSuccess"));
           this.getList();
         });
       });
     },
-    handleSeeDeatils(row) {
-      API.purchaseDetails({ id: row.id }).then((res) => {
-        console.log(res, "ssde");
-      });
-    },
-    handleDelete(row) {
-      this.$confirm(this.$t("askDeleteData"), {
+    handlePurchaseCancel(row) {
+      this.$confirm("是否确定此操作 ?", {
         confirmButtonText: this.$t("submitText"),
         cancelButtonText: this.$t("cancelText"),
         type: "warning",
       }).then(() => {
-        API.purchaseDel({ id: row.id }).then(() => {
+        API.purchaseCancel({ id: row.id }).then(() => {
           this.msgSuccess(this.$t("deleteSuccess"));
           this.getList();
         });
       });
     },
+    handleSubmit1() {
+      this.$refs.arriveForm.validate((valid) => {
+        if (valid) {
+          API.arrivalNotice({ id: row.id }).then(() => {
+            this.msgSuccess("操作成功");
+            this.getList();
+            this.handleCancel1();
+          });
+        }
+      });
+    },
+    handleCancel1() {
+      this.openArrive = false;
+      this.arriveForm = {
+        id: "",
+        name: "",
+        code: "",
+      };
+    },
     isSelectable(row) {
       if (row.status != 30) {
         return false;
@@ -198,7 +264,7 @@ export default {
     <el-card class="box-card">
       <query
         :selectConfig="selectConfig"
-        :req="queryParams"
+        :req=" queryParams"
         :isShowMore="false"
         @handleQuery="handleQuery"
         @handleMore="
@@ -210,14 +276,8 @@ export default {
       <el-table
         :data="tableList"
         v-loading="loading"
-        @selection-change="handleSelectionChange"
       >
-        <el-table-column
-          type="selection"
-          width="50"
-          align="center"
-          :selectable="isSelectable"
-        >
+   
         </el-table-column>
         <el-table-column
           label="采购单号"
@@ -225,55 +285,53 @@ export default {
           prop="code"
           width="150"
         >
-          <template slot-scope="scope">
-            <span style="color: #0084ff; cursor: pointer">
-              {{ scope.row.code }}
-            </span>
-          </template>
+  
         </el-table-column>
-        <el-table-column label="总金额" align="center" prop="price" />
+        <el-table-column label="供应商" align="center" prop="price" />
+
+        <el-table-column label="采购总金额" align="center" prop="price" />
+        <el-table-column label="采购员" align="center" prop="createName" />
+
         <el-table-column
-          label="要求到货时间"
+          label="采购时间"
           align="center"
           prop="createTime"
           width="160"
         />
         <el-table-column
-          label="采购状态"
+          label="状态"
           align="center"
           :formatter="(row) => dictDataEcho(row.status, purchaseStatusList)"
         />
-        <el-table-column label="采购人" align="center" prop="createName" />
+        <el-table-column label="付款状态" align="center" prop="createName" />
 
-        <el-table-column :label="$t('operation')" align="center" width="120">
+        <el-table-column :label="$t('operation')" align="center" width="240">
           <!-- v-if="scope.row.status === 30" -->
           <template slot-scope="scope">
             <el-button type="text" @click="handleSend(scope.row)"
-              >发货
+              >  发货通知
+            </el-button>
+            <el-button type="text"   @click="handleArrive(scope.row)"
+              >到货通知
             </el-button>
-            <el-button
-              type="text"
-              v-if="scope.row.status === 40"
-              @click="handleComplete(scope.row)"
-              >完成采购
+            <el-button type="text" @click="handlePurchaseEnd(scope.row)"
+              >结束
             </el-button>
-            <el-button
-              type="text"
-              v-if="scope.row.status === 50"
-              @click="handleSeeDeatils(scope.row)"
-              >查看
+            <el-button type="text" @click="handlePurchaseCancel(scope.row)"
+              >取消
             </el-button>
           </template>
         </el-table-column>
       </el-table>
     </el-card>
 
-    <el-dialog
+    <el-dialog 
       :title="titleText"
       :visible.sync="open"
       v-if="open"
       width="80%"
-      top="60px"
+
+          top="60px"
     >
       <send-goods
         :form="form"
@@ -282,6 +340,78 @@ export default {
         ref="sendGoods"
       ></send-goods>
     </el-dialog>
+      
+    <el-dialog   title="到货通知"
+      :visible.sync="openArrive"
+      v-if="openArrive"
+      width="30%"
+
+          top="60px">
+         <el-form
+        label-position="top"
+        :model="arriveForm"
+        ref="arriveForm"
+        :rules="arriveFormRules"
+        label-width="100px"
+      >
+        <el-row >
+          <el-col :span="8">
+            <el-form-item label="采购单号" prop="code">
+              <el-input
+                v-model="arriveForm.code"
+                :placeholder="$t('pleaseInput')"
+                disabled
+              ></el-input>
+            </el-form-item>
+          </el-col>
+       
+        </el-row>
+           <el-form-item label="供应商" prop="name">
+              <el-input
+                v-model="arriveForm.name"
+                :placeholder="$t('pleaseInput')"
+                disabled
+              ></el-input>
+            </el-form-item>
+        <el-row >
+          <el-col :span="8">
+            <el-form-item label="物流/快递单号" prop="id">
+              <el-select
+                v-model="arriveForm.id"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in logisticsData"
+                  :key="item.code"
+                  :label="item.name"
+                  :value="item.code"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+   
+        </el-row>
+      
+
+      </el-form>
+ 
+    <div style="text-align: center; margin-top: 15px">
+      <el-button size="small" @click="handleCancel1"
+        >{{ $t("cancel") }}
+      </el-button>
+      <el-button type="primary" size="small" @click="handleSubmit1">
+        {{ $t("submit") }}</el-button
+      >
+    </div>
+    </el-dialog>
+
+
+
+
+    
+
   </div>
 </template>
 

+ 46 - 27
src/views/purchase-management/deliver-goods/sendGoods.vue

@@ -8,18 +8,57 @@
         :rules="formRules"
         label-width="100px"
       >
-        <el-row>
-          <el-col :span="6">
-            <el-form-item label="物流单号" prop="code">
+        <el-row :gutter="10">
+          <el-col :span="4">
+            <el-form-item label="采购单号" prop="code">
+              <el-input
+                v-model="form.code"
+                :placeholder="$t('pleaseInput')"
+                disabled
+              ></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="8">
+            <el-form-item label="供应商" prop="code">
               <el-input
                 v-model="form.code"
                 :placeholder="$t('pleaseInput')"
+                disabled
               ></el-input>
             </el-form-item>
           </el-col>
         </el-row>
-
-        <el-form-item label="上传附件">
+        <el-row :gutter="10">
+          <el-col :span="6">
+            <el-form-item label="物流信息" prop="logisticsCompanyCode">
+              <el-select
+                v-model="form.logisticsCompanyCode"
+                :placeholder="$t('pleaseSelect')"
+                style="width: 100%"
+              >
+                <el-option
+                  v-for="item in logisticsData"
+                  :key="item.code"
+                  :label="item.name"
+                  :value="item.code"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="6">
+            <el-form-item label=". " prop="logisticsCode">
+              <el-input
+                v-model="form.logisticsCode"
+                placeholder="物流/快递单号"
+              ></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <div style="margin-bottom: 20px">
+          <labelTitle content="发货明细"></labelTitle>
+        </div>
+        <!-- <el-form-item label="上传附件">
           <el-upload
             class="upload-demo"
             action="http://36.134.91.96:10001/api/service-file/uploadFile"
@@ -32,12 +71,10 @@
           >
             <el-button size="small" type="primary">点击上传</el-button>
           </el-upload>
-        </el-form-item>
+        </el-form-item> -->
 
         <el-form-item>
           <el-table :data="form.details">
-            <el-table-column label="申购单号" prop="goodsCode">
-            </el-table-column>
             <el-table-column
               :label="$t('purchase_management.purchase.goodCode')"
               prop="goodsCode"
@@ -50,17 +87,11 @@
             </el-table-column>
 
             <el-table-column
-              :label="$t('purchase_management.purchase.unit')"
-              prop="goodsUnit"
-            >
-            </el-table-column>
-            <el-table-column
               :label="$t('purchase_management.purchase.subscribeQuantity')"
               prop="quantity"
             >
             </el-table-column>
-            <el-table-column label="收货仓库" prop="stockQuantity">
-            </el-table-column>
+
             <el-table-column label="发货数量" prop="shipmentQuantity">
               <template slot-scope="scope">
                 <el-form-item
@@ -78,18 +109,6 @@
                 </el-form-item>
               </template>
             </el-table-column>
-
-            <el-table-column
-              :label="$t('operation')"
-              width="100"
-              align="center"
-            >
-              <template slot-scope="scope">
-                <el-button type="text" @click="deleteRow(scope.$index)">{{
-                  $t("delete")
-                }}</el-button>
-              </template>
-            </el-table-column>
           </el-table>
         </el-form-item>
       </el-form>

+ 13 - 16
src/views/purchase-management/purchase/index.vue

@@ -34,14 +34,6 @@ export default {
                 this.handlePurchases();
               },
             },
-            {
-              name: this.$t("purchase_management.purchase.deliverGoods"),
-              methodsText: "deliverGoods",
-              type: "primary",
-              deliverGoods: () => {
-                this.deliverGoods();
-              },
-            },
           ],
         },
       },
@@ -229,15 +221,17 @@ export default {
     },
 
     handleDelete(row) {
-      this.$confirm(this.$t("askDeleteData"), {
+      this.$confirm("你确定通过审批吗?", {
         confirmButtonText: this.$t("submitText"),
         cancelButtonText: this.$t("cancelText"),
         type: "warning",
       }).then(() => {
-        API.purchaseDel({ id: row.id }).then(() => {
-          this.msgSuccess(this.$t("deleteSuccess"));
-          this.getList();
-        });
+        API.purchaseApproval({ id: row.id, buttonId: "", flowRemark: "" }).then(
+          () => {
+            this.msgSuccess(this.$t("deleteSuccess"));
+            this.getList();
+          }
+        );
       });
     },
     isSelectable(row) {
@@ -368,9 +362,12 @@ export default {
               @click="handlePurchase(scope.row)"
               >{{ $t("purchase_management.purchase.purchase") }}
             </el-button>
-            <!-- <el-button type="text" @click="handleDelete(scope.row)"
-              >{{ $t("delete") }}
-            </el-button> -->
+            <el-button
+              type="text"
+              v-if="scope.row.status === 20"
+              @click="handleDelete(scope.row)"
+              >审批
+            </el-button>
           </template>
         </el-table-column>
       </el-table>