Ver código fonte

异常管理和物流数据页接口对接

cz 2 anos atrás
pai
commit
c136205e22

+ 19 - 0
src/api/inbound-outbound/abnormalManage.js

@@ -0,0 +1,19 @@
+import request from '@/router/axios'
+
+// 异常管理列表
+export function unusualList(data = {}) {
+  return request({
+    url: '/api/victoriatourist/abnormalInfo/page',
+    method: 'post',
+    data: data,
+  })
+}
+
+// 异常管理列表
+export function addFollow(data = {}) {
+  return request({
+    url: '/api/victoriatourist/abnormalDetails/add',
+    method: 'post',
+    data: data,
+  })
+}

+ 20 - 1
src/api/order-management/JDReturnGoods/index.js

@@ -55,4 +55,23 @@ export function getLogisticsData(data = {}) {
     method: 'post',
     data: data,
   })
-}
+}
+
+//更新物流状态
+export function updateStatus(data = {}) {
+  return request({
+    url: '/api/victoriatourist/logisticsInfo/dataInfoEdit',
+    method: 'post',
+    data: data,
+  })
+}
+
+
+//查询物流状态
+export function queryStatus(data = {}) {
+  return request({
+    url: '/api/victoriatourist/logisticsInfo/getLogistics',
+    method: 'post',
+    data: data,
+  })
+}

+ 0 - 10
src/api/product-material/warehouse/index.js

@@ -55,13 +55,3 @@ export function warehouseDel(data = {}) {
     data: data,
   })
 }
-
-
-// 删除warehouse 
-export function getListByRole(data = {}) {
-  return request({
-    url: '/api/blade-user/getListByRole',
-    method: 'post',
-    data: data,
-  })
-}

+ 10 - 4
src/api/system/common.js

@@ -1,5 +1,5 @@
 import request from '@/router/axios';
-
+//获取附件
 export function getFileData(data) {
   return request({
     url: '/api/service-file/getFileList',
@@ -7,7 +7,7 @@ export function getFileData(data) {
     data: data
   })
 }
-
+//部门树
 export function getDeptData(data) {
   return request({
     url: '/api/victoriatourist/common/dept/tree',
@@ -31,5 +31,11 @@ export function getLogisticsData(data) {
     data: data
   })
 }
-
-
+//根据角色id获取用户列表
+export function getListByRole(data = {}) {
+  return request({
+    url: '/api/blade-user/getListByRole',
+    method: 'post',
+    data: data,
+  })
+}

+ 51 - 49
src/components/purchase/details.vue

@@ -2,68 +2,53 @@
   <div>
     <el-form :model="form" label-position="left" v-loading="loading">
       <div style="margin-bottom: 20px">
-        <labelTitle content="申购信息"></labelTitle>
+        <labelTitle content="基本信息"></labelTitle>
       </div>
       <div style="padding: 0px 20px">
         <el-row :gutter="10">
           <el-col :span="12">
-            <el-form-item label="收货仓库:" prop="customerName">
-              <span>{{ form.customerName ? form.customerName : "京东" }}</span>
+            <el-form-item label="供应商:" prop="supplierName">
+              <span>{{ form.supplierName }}</span>
             </el-form-item>
           </el-col>
           <el-col :span="12">
-            <el-form-item label="要求到货时间:" prop="type">
+            <el-form-item label="采购单号:" prop="code">
               <span>
-                {{ form.planArrivalTime }}
+                {{ form.code }}
               </span>
             </el-form-item>
           </el-col>
         </el-row>
       </div>
-      <div style="padding: 0px 20px">
-        <el-form-item label="申购说明:" prop="cause">
-          <span>{{ form.cause }}</span>
-        </el-form-item>
-      </div>
 
       <div style="margin-bottom: 20px">
-        <labelTitle content="购明细"></labelTitle>
+        <labelTitle content="采购明细"></labelTitle>
       </div>
       <div style="padding: 0px 20px">
-        <el-table :data="form.orderDetailsList">
-          <el-table-column label="物品编码" prop="goodsCode"> </el-table-column>
-          <el-table-column label="物品名称" prop="goodsName"> </el-table-column>
-          <el-table-column label="物品单位" prop="goodsUnit"> </el-table-column>
-          <el-table-column label="数量" prop="quantity"> </el-table-column>
+        <el-table :data="form.goodsList">
+          <el-table-column label="申购单号" prop="code" />
+          <el-table-column
+            label="要求到货时间"
+            prop="planArrivalTime"
+            width="150"
+          />
+          <el-table-column label="物品类型" prop="goodsType" :formatter="(row)
+          => dictDataEcho(row.goodsType, productTypeList)" / >
+          <el-table-column label="物品编码" prop="goodsCode" />
+          <el-table-column label="物品名称" prop="goodsName" />
+          <el-table-column label="物品单位" prop="goodsUnit" width="80" />
+          <el-table-column label="单价" prop="unitPrice" width="100" />
+          <el-table-column label="采购数量" prop="quantity" width="120" />
         </el-table>
-        <el-row>
-          <el-col :span="10">
-            <el-form-item label="订单总金额:" prop="amountMoney">
-              {{ form.amountMoney }}
-            </el-form-item>
-          </el-col>
-        </el-row>
-      </div>
-      <div style="margin-bottom: 20px">
-        <labelTitle content="收货信息"></labelTitle>
-      </div>
-      <div style="padding: 0px 20px">
-        <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>
       </div>
     </el-form>
   </div>
 </template>
 
 <script>
-import { subscribeDetails } from "@/api/purchase-management/subscribe/index.js";
 import labelTitle from "@/components/label-title/index.vue";
+import { purchaseDetails } from "@/api/purchase-management/purchase/index.js";
+import { supplySelect } from "@/api/product-material/supply/index.js";
 
 export default {
   props: {
@@ -78,26 +63,43 @@ export default {
     return {
       loading: true,
       form: {},
-      orderTypeList: [],
+      supplySelectList: [],
+      productTypeList: [],
     };
   },
   created() {
-    // const businessDictData = JSON.parse(
-    //   window.localStorage.getItem("businessDict")
-    // );
-    // this.orderTypeList = businessDictData.find(
-    //   (item) => item.code === "orderType"
-    // ).children;
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.productTypeList = businessDictData.find(
+      (item) => item.code === "productType"
+    ).children;
   },
   mounted() {
     if (this.rowData.id) {
-      subscribeDetails({ id: this.rowData.id }).then((res) => {
-        console.log(res, "ass");
-        // this.form = res.data.data;
-        this.loading = false;
-      });
+      this.getDetails();
     }
   },
+  methods: {
+    async getDetails() {
+      this.loading = true;
+      const { data } = await supplySelect({ name: "", code: "", type: "" });
+      this.supplySelectList = data.data;
+      purchaseDetails({ id: this.rowData.id }).then((res) => {
+        this.getSupplierName(res.data.data.supplierId, res.data.data);
+      });
+    },
+    getSupplierName(id, data) {
+      const current = this.supplySelectList.find((x) => x.id === id);
+      if (current) {
+        this.form = {
+          ...data,
+          supplierName: current.name,
+        };
+        this.loading = false;
+      }
+    },
+  },
 };
 </script>
 

+ 12 - 4
src/styles/common.scss

@@ -19,12 +19,20 @@
 //通用配置
 @import './normalize.scss';
 
-a{
+a {
   text-decoration: none;
-  color:#333;
+  color: #333;
 }
-*{
+
+* {
   outline: none;
 }
+
+.show_underline {
+  color: #0084ff;
+  cursor: pointer;
+  text-decoration: underline;
+}
+
 //滚动条样式
-@include scrollBar;
+@include scrollBar;

+ 33 - 65
src/views/inbound-outbound/abnormalManage/addInspection.vue → src/views/inbound-outbound/abnormalManage/addFollow.vue

@@ -8,23 +8,22 @@
         :rules="formRules"
         label-width="100px"
       >
-        <el-form-item label="跟进结果" prop="code">
-          <el-radio-group v-model="form.code" size="medium">
+        <el-form-item label="跟进结果" prop="status">
+          <el-radio-group v-model="form.status" size="medium">
             <el-radio-button label="1">完成</el-radio-button>
-            <el-radio-button label="2">跟进中</el-radio-button>
+            <el-radio-button label="0">跟进中</el-radio-button>
           </el-radio-group>
         </el-form-item>
-
         <el-row>
           <el-col :span="8">
-            <el-form-item label="跟进人" prop="code">
+            <el-form-item label="跟进人" prop="handleUser">
               <el-select
-                v-model="form.inWarehouseId"
+                v-model="form.handleUser"
                 placeholder="请选择"
                 style="width: 100%"
               >
                 <el-option
-                  v-for="item in warehouseSelectList"
+                  v-for="item in userList"
                   :key="item.id"
                   :label="item.name"
                   :value="item.id"
@@ -36,9 +35,9 @@
         </el-row>
         <el-row>
           <el-col :span="10">
-            <el-form-item label="跟进时间" prop="clearancePeriod">
+            <el-form-item label="跟进时间" prop="handleTime">
               <el-date-picker
-                v-model="form.clearancePeriod"
+                v-model="form.handleTime"
                 type="datetime"
                 placeholder="请选择"
                 value-format="yyyy-MM-dd HH:mm:ss"
@@ -47,9 +46,9 @@
             </el-form-item>
           </el-col>
         </el-row>
-        <el-form-item label="跟进记录" prop="remark">
+        <el-form-item label="跟进记录" prop="explain">
           <el-input
-            v-model="form.remark"
+            v-model="form.explain"
             placeholder="请输入"
             type="textarea"
             :rows="3"
@@ -64,77 +63,70 @@
         确定</el-button
       >
     </div>
-    <!-- <el-dialog
-      title="物品选择"
-      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 { getListByRole } from "@/api/system/common.js";
 
-import { getToken } from "@/util/auth";
+import { mapGetters } from "vuex";
 
 export default {
   name: "addManualOutbound",
-  components: { labelTitle, selectProduct },
+  components: { labelTitle },
   props: {
     form: {
       type: Object,
       default: () => {},
     },
-    warehouseSelectList: {
-      type: Array,
-      default: () => [],
-    },
   },
+  computed: mapGetters(["userInfo"]),
   data() {
     return {
-      uploadHeader: {
-        Authorization: "Basic c2FiZXI6c2FiZXJfc2VjcmV0",
-        "Blade-Auth": "bearer " + getToken(),
-      },
       loading: false,
-      selectDialog: false,
+      userList: [],
       formRules: {
-        quantity: [
+        explain: [
           {
             required: true,
-            message: "请输入质检合格数量",
+            message: "请输入跟进记录",
             trigger: "blur",
           },
         ],
-        outWarehouseId: [
+        status: [
+          {
+            required: true,
+            message: "请选择处理结果",
+            trigger: "change",
+          },
+        ],
+        handleUser: [
           {
             required: true,
-            message: "请选择调出仓库",
+            message: "请选择跟进人",
             trigger: "change",
           },
         ],
-        inWarehouseId: [
+        handleTime: [
           {
             required: true,
-            message: "请选择调入仓库",
+            message: "请选择跟进时间",
             trigger: "change",
           },
         ],
       },
     };
   },
-  created() {},
+  created() {
+    getListByRole({ roleId: this.userInfo.role_id }).then((res) => {
+      this.userList = res.data.data;
+    });
+  },
   methods: {
     handleSubmit() {
       this.$refs.form.validate((valid) => {
         if (valid) {
-          if (!this.form.changeProductList.length > 0)
-            return this.msgInfo("请添加调仓明细");
           this.loading = true;
           this.$emit("submit");
         }
@@ -143,30 +135,6 @@ export default {
     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("删除成功");
-    },
   },
 };
 </script>

+ 40 - 87
src/views/inbound-outbound/abnormalManage/index.vue

@@ -1,57 +1,35 @@
 
 
 <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";
+import * as API from "@/api/inbound-outbound/abnormalManage.js";
+import addFollow from "./addFollow.vue";
 
 export default {
   components: {
-    test,
     query,
-    addInspection,
+    addFollow,
   },
   data() {
     return {
-      warehouseSelectList: [],
-      warehouseTypeList: [],
       abnormalSourceList: [],
       handleStatusList: [],
-      btnForm: {
-        otherButton: {
-          list: [
-            {
-              name: "发起调仓",
-              methodsText: "send",
-              type: "primary",
-              send: () => {
-                this.handleSend();
-              },
-            },
-          ],
-        },
-      },
       queryParams: {
         pageNum: 1,
         pageSize: 10,
         keyword: "",
-        outWarehouseId: "",
-        inWarehouseId: "",
-        inStatus: "",
+        status: "",
+        type: "",
       },
       selectConfig: [
         {
           label: "异常来源",
-          prop: "outWarehouseId",
+          prop: "type",
           data: [],
         },
         {
           label: "处理状态",
-          prop: "outWarehouseId",
+          prop: "status",
           data: [],
         },
       ],
@@ -61,10 +39,11 @@ export default {
       titleText: "异常跟进",
       open: false,
       form: {
-        outWarehouseId: "",
-        inWarehouseId: "",
-        remark: "",
-        changeProductList: [],
+        abnormalInfoId: "",
+        explain: "",
+        status: "",
+        handleUser: "",
+        handleTime: "",
       },
     };
   },
@@ -78,9 +57,6 @@ export default {
     this.handleStatusList = businessDictData.find(
       (item) => item.code === "handleStatus"
     ).children;
-    warehouseSelectList().then((res) => {
-      this.warehouseSelectList = res.data.data;
-    });
     this.selectConfig[0].data = this.abnormalSourceList.map((item) => ({
       label: item.dictValue,
       value: item.dictKey,
@@ -94,14 +70,14 @@ export default {
   methods: {
     getList() {
       this.loading = true;
-      API.transferList(this.queryParams).then(
+      API.unusualList(this.queryParams).then(
         (res) => {
           this.tableList = res.data.data.records;
           this.total = res.data.data.total;
           this.loading = false;
         },
         (err) => {
-          console.log("transferList: " + err);
+          console.log("unusualList: " + err);
           this.loading = false;
         }
       );
@@ -109,59 +85,32 @@ export default {
     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(
+      API.addFollow(this.form).then(
         () => {
           this.msgSuccess("添加成功");
-          this.$refs.addInspection.loading = false;
+          this.$refs.addFollow.loading = false;
           this.open = false;
           this.getList();
         },
         (err) => {
-          console.log("addInspection: " + err);
-          this.$refs.addInspection.loading = false;
+          console.log("addFollow: " + err);
+          this.$refs.addFollow.loading = false;
         }
       );
     },
-    handleReceive(row) {
+    handleFollow(row) {
+      this.form = {
+        abnormalInfoId: row.id,
+        explain: "",
+        status: "",
+        handleUser: "",
+        handleTime: "",
+      };
       this.open = true;
-      // this.$confirm("是否确认接收 ?", {
-      //   confirmButtonText: '确定',
-      //   cancelButtonText: '取消',
-      //   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>
-      );
     },
   },
 };
@@ -186,33 +135,37 @@ export default {
         <el-table-column
           label="异常来源"
           align="left"
-          prop="code"
+          prop="type"
           width="120"
+          :formatter="(row) => dictDataEcho(row.type, abnormalSourceList)"
         />
-        <el-table-column label="异常说明" align="left" prop="name" />
+        <el-table-column label="异常说明" align="left" prop="title" />
         <el-table-column
           label="处理状态"
           align="left"
-          prop="specs"
+          prop="status"
           width="100"
+          :formatter="(row) => dictDataEcho(row.status, handleStatusList)"
         />
 
         <el-table-column
           label="最近操作人"
           align="left"
-          prop="outQuantity"
+          prop="handleUserName"
           width="120"
         />
         <el-table-column
           label="最近操作时间"
           align="left"
-          prop="outUserName"
+          prop="handleTime"
           width="160"
         />
-
         <el-table-column label="操作" align="left" width="120">
           <template slot-scope="scope">
-            <el-button type="text" @click="handleReceive(scope.row)"
+            <el-button
+              type="text"
+              v-if="scope.row.status !== 2"
+              @click="handleFollow(scope.row)"
               >跟进
             </el-button>
           </template>
@@ -234,12 +187,12 @@ export default {
       width="30%"
       top="60px"
     >
-      <add-inspection
+      <add-follow
         :form="form"
         @submit="handleSubmit"
         @cancel="handleCancel"
-        ref="addInspection"
-      ></add-inspection>
+        ref="addFollow"
+      ></add-follow>
     </el-dialog>
   </div>
 </template>

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

@@ -198,7 +198,6 @@ export default {
           label="物流/快递单号"
           align="left"
           prop="logisticsInfoCode"
-          width="140"
         />
         <el-table-column
           label="采购员"

+ 1 - 8
src/views/order-management/JDReturnGoods/index.vue

@@ -269,14 +269,7 @@ export default {
         <el-table-column label="导入时间" align="left" prop="createTime" />
         <el-table-column label="物流单号" align="left" prop="waybill">
           <template slot-scope="scope">
-            <div
-              style="
-                color: #0084ff;
-                cursor: pointer;
-                text-decoration: underline;
-              "
-              @click="handleLookDetails(scope.row)"
-            >
+            <div class="show_underline" @click="handleLookDetails(scope.row)">
               {{ scope.row.waybill }}
             </div>
           </template>

+ 152 - 21
src/views/order-management/JDReturnGoods/logisticsList.vue

@@ -1,29 +1,61 @@
 
 <script>
 import query from "@/components/query/index.vue";
+import OrderDetails from "@/components/order/details.vue";
+import PurchaseDetails from "@/components/purchase/details.vue";
 
 import * as API from "@/api/order-management/JDReturnGoods/index.js";
 
 export default {
   components: {
     query,
+    OrderDetails,
+    PurchaseDetails,
   },
   data() {
     return {
       loading: false,
-      selectConfig: [],
-
+      logisticsDataSourceList: [],
+      logisticsStatusList: [],
+      selectConfig: [
+        {
+          label: "数据来源",
+          prop: "businessType",
+          data: [],
+        },
+      ],
       queryParams: {
         pageNum: 1,
         pageSize: 10,
         keyword: "",
-        inStockStatus: "",
+        businessType: "",
       },
       tableList: [],
       total: 0,
+      open: false,
+      titleText: "",
+      activities: [],
+      message: "",
+      detailsDialog: false,
+      detailsText: "",
+      selectOrderId: "",
+      rowData: {},
     };
   },
   created() {
+    const businessDictData = JSON.parse(
+      window.localStorage.getItem("businessDict")
+    );
+    this.logisticsDataSourceList = businessDictData.find(
+      (item) => item.code === "logisticsDataSource"
+    ).children;
+    this.logisticsStatusList = businessDictData.find(
+      (item) => item.code === "logisticsStatus"
+    ).children;
+    this.selectConfig[0].data = this.logisticsDataSourceList.map((item) => ({
+      label: item.dictValue,
+      value: item.dictKey,
+    }));
     this.getList();
   },
   methods: {
@@ -41,6 +73,56 @@ export default {
         }
       );
     },
+    handleQuery() {
+      this.getList();
+    },
+    async lookProgress(row) {
+      this.titleText = "查看物流";
+      const { data } = await API.queryStatus({ id: row.id });
+      if (data.data.length > 0) {
+        this.activities = data.data;
+        this.open = true;
+      } else {
+        this.msgInfo(data.message);
+      }
+    },
+    lookDetails(row) {
+      this.rowData = {};
+      this.selectOrderId = "";
+      if (row.businessType === 1) {
+        // 采购出货
+        this.detailsText = "采购详情";
+        this.rowData = { id: row.businessId };
+      } else if (row.businessType === 2) {
+        // 京东订单出货
+        this.detailsText = "京东订单详情";
+        this.selectOrderId = row.businessId;
+      } else if (row.businessType === 3) {
+        // 销售订单出货
+        this.detailsText = "销售订单详情";
+        this.selectOrderId = row.businessId;
+      }
+      this.detailsDialog = true;
+    },
+    showStatus(row) {
+      if (row.logisticsStatus === -1) {
+        return "异常";
+      } else {
+        return this.dictDataEcho(row.logisticsStatus, logisticsStatusList);
+      }
+    },
+    handleUpdate(row) {
+      this.$confirm("确定更新状态?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      }).then(() => {
+        API.updateStatus({ id: row.id }).then((res) => {
+          this.msgSuccess("更新成功!");
+          this.handleQuery();
+        });
+      });
+    },
   },
 };
 </script>
@@ -58,34 +140,50 @@ export default {
       "
     ></query>
     <el-table :data="tableList" v-loading="loading">
-      <el-table-column label="物流单号" align="left" prop="code" />
       <el-table-column
-        label="物流公司编码"
+        label="来源"
         align="left"
-        prop="logisticsCompanyCode"
-        width="120"
+        prop="businessType"
+        :formatter="
+          (row) => dictDataEcho(row.businessType, logisticsDataSourceList)
+        "
       />
-      <el-table-column label="物流状态" align="left" prop="logisticsStatus" />
-      <el-table-column label="创建时间" align="left" prop="createTime" />
+      <el-table-column label="单号" align="left" prop="businessCode">
+        <template slot-scope="scope">
+          <div class="show_underline" @click="lookDetails(scope.row)">
+            {{ scope.row.businessCode }}
+          </div>
+        </template>
+      </el-table-column>
+      <el-table-column label="物流/快递公司" align="left" prop="companyName" />
+      <el-table-column label="物流/快递单号" align="left" prop="code">
+        <template slot-scope="scope">
+          <div class="show_underline" @click="lookProgress(scope.row)">
+            {{ scope.row.code }}
+          </div>
+        </template>
+      </el-table-column>
 
-      <!-- <el-table-column
-        label="状态"
-        align="left"
-        prop="status"
-        width="100"
-        :formatter="(row) => dictDataEcho(row.inStockStatus, inStockStatusList)"
-      /> -->
-      <!-- <el-table-column label="操作" align="left" width="100">
+      <el-table-column label="状态" align="left" prop="logisticsStatus">
+        <template slot-scope="scope">
+          <div
+            :style="{ color: scope.row.logisticsStatus === -1 ? 'red' : '' }"
+          >
+            {{ showStatus(scope.row) }}
+          </div>
+        </template></el-table-column
+      >
+      <el-table-column label="操作" align="center" width="100">
         <template slot-scope="scope">
           <el-button
             type="text"
-            @click="handleInbound(scope.row)"
-            v-if="scope.row.status < 30"
+            @click="handleUpdate(scope.row)"
+            v-if="scope.row.logisticsStatus === -1"
           >
-            入库
+            更新状态
           </el-button>
         </template>
-      </el-table-column> -->
+      </el-table-column>
     </el-table>
     <pagination
       v-show="total > 0"
@@ -94,6 +192,39 @@ export default {
       :limit.sync="queryParams.pageSize"
       @pagination="getList"
     />
+
+    <el-dialog
+      :title="titleText"
+      :visible.sync="open"
+      v-if="open"
+      width="40%"
+      top="100px"
+    >
+      <el-timeline :reverse="false">
+        <el-timeline-item
+          placement="top"
+          v-for="(activity, index) in activities"
+          :key="index"
+          :timestamp="activity.ftime"
+        >
+          {{ activity.content }}
+        </el-timeline-item>
+      </el-timeline>
+    </el-dialog>
+
+    <el-dialog
+      :title="detailsText"
+      v-if="detailsDialog"
+      :visible.sync="detailsDialog"
+      width="50%"
+      top="60px"
+    >
+      <OrderDetails
+        :orderId="selectOrderId"
+        v-if="selectOrderId"
+      ></OrderDetails>
+      <PurchaseDetails :rowData="rowData" v-if="rowData.id"></PurchaseDetails>
+    </el-dialog>
   </el-card>
 </template>
 

+ 1 - 7
src/views/order-management/afterSales/index.vue

@@ -217,13 +217,7 @@ export default {
         />
         <el-table-column label="订单编号" align="left" prop="code">
           <template slot-scope="scope">
-            <div
-              style="
-                color: #0084ff;
-                cursor: pointer;
-                text-decoration: underline;
-              "
-            >
+            <div class="show_underline">
               {{ scope.row.code }}
             </div>
           </template>

+ 1 - 8
src/views/order-management/order/JDorder.vue

@@ -214,14 +214,7 @@ export default {
       <el-table :data="tableList" v-loading="loading">
         <el-table-column label="订单编号" align="left" prop="code" width="150">
           <template slot-scope="scope">
-            <div
-              style="
-                color: #0084ff;
-                cursor: pointer;
-                text-decoration: underline;
-              "
-              @click="handleLookDetails(scope.row)"
-            >
+            <div class="show_underline" @click="handleLookDetails(scope.row)">
               {{ scope.row.code }}
             </div>
           </template>

+ 1 - 8
src/views/order-management/order/index.vue

@@ -246,14 +246,7 @@ export default {
         />
         <el-table-column label="订单编号" align="left" prop="code" width="140">
           <template slot-scope="scope">
-            <div
-              style="
-                color: #0084ff;
-                cursor: pointer;
-                text-decoration: underline;
-              "
-              @click="handleLookDetails(scope.row)"
-            >
+            <div class="show_underline" @click="handleLookDetails(scope.row)">
               {{ scope.row.code }}
             </div>
           </template>

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

@@ -5,12 +5,14 @@ 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";
+import PurchaseDetails from "@/components/purchase/details.vue";
 
 export default {
   components: {
     query,
     sendGoods,
     test,
+    PurchaseDetails,
   },
   data() {
     return {
@@ -67,6 +69,8 @@ export default {
 
       selectData: [],
       logisticsData: [],
+      rowData: {},
+      detailsDialog: false,
     };
   },
   created() {
@@ -126,7 +130,6 @@ export default {
       this.open = true;
       this.$nextTick(() => {
         this.$refs.sendGoods.loading = true;
-
         API.lookSendGoodsDetails({ id: row.id }).then(
           (res) => {
             this.form.details = res.data.data.map((x) => ({
@@ -251,26 +254,8 @@ export default {
       );
     },
     openDetails(row) {
-      this.open = true;
-      this.$nextTick(() => {
-        this.$refs.sendGoods.loading = true;
-        API.purchaseDetails({ id: row.id }).then(
-          (res) => {
-            this.form.details = res.data.data.goodsList.map((x) => ({
-              goodsCode: x.goodsCode,
-              goodsName: x.goodsName,
-              quantity: x.quantity,
-              purchaseId: row.id,
-              applyPurchaseId: x.id,
-              shipmentQuantity: Number(x.quantity),
-            }));
-            this.$refs.sendGoods.loading = false;
-          },
-          (err) => {
-            this.$refs.sendGoods.loading = false;
-          }
-        );
-      });
+      this.rowData = { ...row };
+      this.detailsDialog = true;
     },
   },
 };
@@ -294,14 +279,7 @@ export default {
       <el-table :data="tableList" v-loading="loading">
         <el-table-column label="采购单号" align="left" prop="code" width="150">
           <template slot-scope="scope">
-            <div
-              style="
-                color: #0084ff;
-                cursor: pointer;
-                text-decoration: underline;
-              "
-              @click="openDetails(scope.row)"
-            >
+            <div class="show_underline" @click="openDetails(scope.row)">
               {{ scope.row.code }}
             </div>
           </template>
@@ -440,6 +418,16 @@ export default {
         >
       </div>
     </el-dialog>
+
+    <el-dialog
+      title="采购详情"
+      v-if="detailsDialog"
+      :visible.sync="detailsDialog"
+      width="50%"
+      top="60px"
+    >
+      <PurchaseDetails :rowData="rowData"></PurchaseDetails>
+    </el-dialog>
   </div>
 </template>
 

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

@@ -256,13 +256,7 @@ export default {
       <el-table :data="tableList" v-loading="loading">
         <el-table-column label="申购单号" align="left" prop="code" width="140">
           <template slot-scope="scope">
-            <div
-              style="
-                color: #0084ff;
-                cursor: pointer;
-                text-decoration: underline;
-              "
-            >
+            <div class="show_underline">
               <!-- @click="handleLookDetails(scope.row)" -->
               {{ scope.row.code }}
             </div>