阿拉蕾 1 year ago
parent
commit
aa5097e093
2 changed files with 17 additions and 1 deletions
  1. 9 0
      src/api/store/storeOrder.js
  2. 8 1
      src/views/store/components/productOrder.vue

+ 9 - 0
src/api/store/storeOrder.js

@@ -32,6 +32,15 @@ export function getStoreOrder(id) {
     method: 'get'
   })
 }
+
+// 查询订单详细
+export function getStoreOrderAddress(id) {
+  return request({
+    url: '/store/storeOrder/queryAddress/' + id,
+    method: 'get'
+  })
+}
+
 export function getExpress(id) {
   return request({
     url: '/store/storeOrder/getExpress/' + id,

+ 8 - 1
src/views/store/components/productOrder.vue

@@ -76,6 +76,7 @@
                 trigger="hover"
                 :content="order.userAddress">
                 <span slot="reference">{{order.userAddress}}</span>
+                <el-button icon="el-icon-search" size="mini" @click="handleAddress()" style="margin-left: 20px;" circle v-hasPermi="['store:storeOrder:queryAddress']"></el-button>
               </el-popover>
             </el-descriptions-item>
             <el-descriptions-item label="支付方式"  >
@@ -455,7 +456,7 @@ import { getTcmScheduleList } from "@/api/company/tcmScheduleReport";
 import {getCustomerListBySearch } from "@/api/crm/customer";
 import ImageUpload from '@/components/ImageUpload'
 import Material from '@/components/Material'
-import {bindCustomer,getExpress, listStoreOrder, getStoreOrder, delStoreOrder, addStoreOrder, updateStoreOrder, exportStoreOrder,uploadCredentials } from "@/api/store/storeOrder";
+import {bindCustomer,getExpress, listStoreOrder, getStoreOrder, delStoreOrder, addStoreOrder, updateStoreOrder, exportStoreOrder,uploadCredentials, getStoreOrderAddress} from "@/api/store/storeOrder";
 import {getAllList} from "@/api/store/city";
 import customerDetails from '../../crm/components/customerDetails.vue';
 export default {
@@ -576,6 +577,12 @@ export default {
     });
   },
   methods: {
+    handleAddress(){
+      const id = this.order.id;
+      getStoreOrderAddress(id).then(response =>{
+          this.order.userAddress = response.address;
+      }) 
+    },
     showImageDialog() {
       this.dialogVisible = true;
     },