소스 검색

收藏列表 修改经纬度

743180155@qq.com 1 년 전
부모
커밋
98ae5c541a
4개의 변경된 파일53개의 추가작업 그리고 63개의 파일을 삭제
  1. 21 13
      package-lock.json
  2. 13 11
      src/pages/client/clientPackage/orderAll.vue
  3. 3 0
      src/pages/client/clientPackage/storeDetail.vue
  4. 16 39
      src/pages/client/clientUser/collectList.vue

+ 21 - 13
package-lock.json

@@ -4169,6 +4169,27 @@
         "whatwg-fetch": "^3.6.2"
       },
       "dependencies": {
+        "@vue/vue-loader-v15": {
+          "version": "npm:vue-loader@15.11.1",
+          "resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-15.11.1.tgz",
+          "integrity": "sha512-0iw4VchYLePqJfJu9s62ACWUXeSqM30SQqlIftbYWM3C+jpPcEHKSPUZBLjSF9au4HTHQ/naF6OGnO3Q/qGR3Q==",
+          "dev": true,
+          "requires": {
+            "@vue/component-compiler-utils": "^3.1.0",
+            "hash-sum": "^1.0.2",
+            "loader-utils": "^1.1.0",
+            "vue-hot-reload-api": "^2.3.0",
+            "vue-style-loader": "^4.1.0"
+          },
+          "dependencies": {
+            "hash-sum": {
+              "version": "1.0.2",
+              "resolved": "https://registry.npmmirror.com/hash-sum/-/hash-sum-1.0.2.tgz",
+              "integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
+              "dev": true
+            }
+          }
+        },
         "acorn": {
           "version": "8.8.2",
           "resolved": "https://registry.npmmirror.com/acorn/-/acorn-8.8.2.tgz",
@@ -4304,19 +4325,6 @@
       "resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.4.4.tgz",
       "integrity": "sha512-abSgiVRhfjfl3JALR/cSuBl74hGJ3SePgf1mKzodf1eMWLwHZbfEGxT2cNJSsNiw44jEgrO7bNkhchaWA7RwNw=="
     },
-    "@vue/vue-loader-v15": {
-      "version": "npm:vue-loader@15.11.1",
-      "resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-15.11.1.tgz",
-      "integrity": "sha512-0iw4VchYLePqJfJu9s62ACWUXeSqM30SQqlIftbYWM3C+jpPcEHKSPUZBLjSF9au4HTHQ/naF6OGnO3Q/qGR3Q==",
-      "dev": true,
-      "requires": {
-        "@vue/component-compiler-utils": "^3.1.0",
-        "hash-sum": "^1.0.2",
-        "loader-utils": "^1.1.0",
-        "vue-hot-reload-api": "^2.3.0",
-        "vue-style-loader": "^4.1.0"
-      }
-    },
     "@vue/web-component-wrapper": {
       "version": "1.3.0",
       "resolved": false,

+ 13 - 11
src/pages/client/clientPackage/orderAll.vue

@@ -1,7 +1,8 @@
 <template>
   <view class="container">
     <u-sticky style="margin-top: 15rpx; margin-left: 20rpx" bgColor="#fff">
-      <u-tabs lineWidth="40" :list="list" :current="current" @change="handlerChangeItem" />
+      <u-tabs lineWidth="40" :list="list" :current="current" @change="handlerChangeItem" 
+	   itemStyle="padding-left: 15px; padding-right: 15px; height: 34px;"/>
     </u-sticky>
 
     <!-- 订单 -->
@@ -54,8 +55,8 @@
 
           <view class="item-bottom">
             <button class="btn" v-if="current == 0" @click='handlerCancelOrder(item)'>取消订单</button>
-            <button class="btn" v-if='current == 1' @click='handlerOrderBtn(1)'>申请退款</button>
-            <button class="btn" v-if='current == 2' @click='handlerOrderBtn(2)'>售后</button>
+            <!-- <button class="btn" v-if='current == 1' @click='handlerOrderBtn(1)'>申请退款</button> -->
+            <!-- <button class="btn" v-if='current == 2' @click='handlerOrderBtn(2)'>售后</button> -->
           </view>
         </view>
       </view>
@@ -86,24 +87,25 @@
           },
           {
             name: '待发货',
-            type: 1,
-          },
-          {
-            name: '已发货',
             type: 2,
           },
           {
-            name: '已完成',
+            name: '已发货',
             type: 3,
           },
           {
-            name: '已关闭',
+            name: '已完成',
             type: 4,
           },
           {
-            name: '无效订单',
+            name: '已关闭',
             type: 5,
-          },
+          }
+		  // ,
+    //       {
+    //         name: '无效订单',
+    //         type: 5,
+    //       },
         ],
         init_list: [],
       };

+ 3 - 0
src/pages/client/clientPackage/storeDetail.vue

@@ -274,6 +274,9 @@
       },
       // 点击跳转到商品详情
       handlerSkipGoodsDetail(item, index) {
+		console.log("@@@@item",item.id)
+		console.log("this.queryParams.id",this.queryParams.id)
+		return 
         uni.navigateTo({
           url: `/pages/client/clientPackage/serviceDetail/index?id=${item.id}&shopId=${this.queryParams.id}`,
         });

+ 16 - 39
src/pages/client/clientUser/collectList.vue

@@ -25,14 +25,9 @@
 <script>
   import serviceItem from '@/components/service/index.vue';
   import goodsItem from "@/components/service/goodsItem.vue"
-  import {
-    maintainFavoritePaging,
-    getFavouriteGoods
-  } from '@/api/client/mine.js';
-  import {
-    getCurrentLocation
-  } from '@/api/client/home';
-
+  import { maintainFavoritePaging, getFavouriteGoods } from '@/api/client/mine.js';
+  import { getCurrentLocation } from '@/api/client/home';
+  import { mapGetters } from "vuex"
   export default {
     components: {
       serviceItem,
@@ -43,9 +38,9 @@
         queryParams: {
           size: 10,
           type: 'MERCHANT',
-          region: null || '370705', //地区编码
-          longitude: null || '119.13279', //经度
-          latitude: null || '36.70864', //纬度
+          region: null, //地区编码
+          longitude: null , //经度
+          latitude: null, //纬度
         },
         init_list: [],
         listCollect: [{
@@ -61,34 +56,17 @@
 
       };
     },
-    onLoad() {
-      this.handlerInitLocation();
-    },
+	mounted() {
+	  let { latitude , longitude , region } = this.location
+	  this.queryParams.latitude = latitude
+	  this.queryParams.longitude = longitude
+	  this.queryParams.region = region
+	  this.handlerInitList();
+	},
+	computed:{
+		  ...mapGetters(['location'])
+	},
     methods: {
-      // 获取当前经纬度
-      handlerInitLocation() {
-        // uni.getLocation({
-        //   type: 'gcj02',
-        //   success: res => {
-        //     this.queryParams.longitude = res.longitude;
-        //     this.queryParams.latitude = res.latitude;
-        //     let point = {
-        //       latitude: res.latitude,
-        //       longitude: res.longitude,
-        //     };
-        // getCurrentLocation(point).then(rc => {
-        //   this.queryParams.region = rc.data.id;
-        this.handlerInitList();
-        // });
-        //   },
-        //   fail: rs => {
-        //     uni.showToast({
-        //       title: rs,
-        //       icon: 'none',
-        //     });
-        //   },
-        // });
-      },
       // 初始化商家列表信息
       handlerInitList() {
         maintainFavoritePaging(this.queryParams).then(res => {
@@ -132,7 +110,6 @@
         }
       },
       uploadIniList(e) {
-        // console.log("@@@e", e);
         this.init_list = []
         if (e == 1) {
           this.handlerInitGoodsList()