shish 11 месяцев назад
Родитель
Сommit
890dad458a
3 измененных файлов с 28 добавлено и 25 удалено
  1. 3 3
      mallApp/src/pages.json
  2. 2 21
      mallApp/src/pages/home/recent.vue
  3. 23 1
      mallApp/src/pages/user/edit.vue

+ 3 - 3
mallApp/src/pages.json

@@ -99,7 +99,7 @@
         {
             "root": "pages/interest",
             "pages": [
-                { "path": "invite", "style": { "navigationBarTitleText": "邀请排行", "enablePullDownRefresh": true } },
+                { "path": "invite", "style": { "navigationBarTitleText": "邀请排行", "enablePullDownRefresh": false } },
                 { "path": "level", "style": { "navigationBarTitleText": "会员等级" } }
             ]
         },
@@ -112,13 +112,13 @@
         {
             "root": "pages/billing",
             "pages": [
-                { "path": "affirmGhs", "style": { "navigationBarTitleText": "订单结算", "enablePullDownRefresh": true } }
+                { "path": "affirmGhs", "style": { "navigationBarTitleText": "订单结算", "enablePullDownRefresh": false } }
             ]
         },
         {
             "root": "pages/recharge",
             "pages": [
-                { "path": "list", "style": { "navigationBarTitleText": "充值记录", "enablePullDownRefresh": true } },
+                { "path": "list", "style": { "navigationBarTitleText": "充值记录", "enablePullDownRefresh": false } },
                 { "path": "detail", "style": { "navigationBarTitleText": "充值详情" } }
             ]
         }

+ 2 - 21
mallApp/src/pages/home/recent.vue

@@ -47,7 +47,7 @@
               </view>
               <view class="message-badge">9</view>
             </view>
-             <view class="function-item" @click="logout">
+             <view class="function-item" @click="">
                <text class="function-icon">📱</text>
                <text class="function-text">改号码</text>
              </view>
@@ -171,7 +171,7 @@ import { getList } from "@/api/hd";
 import { share } from "@/mixins";
 import AppAvatarModule from "@/components/module/app-avatar";
 import { mapGetters } from 'vuex'
-import { clearLogin,currentInfo } from "@/api/user";
+import { currentInfo } from "@/api/user";
 import { list } from "@/mixins";
 import { APIHOST } from '@/config'
 export default {
@@ -236,25 +236,6 @@ export default {
         uni.stopPullDownRefresh()
       }
     },
-    logout(){
-      let that = this
-      that.$util.confirmModal({content:'确认退出?'},() => {
-        // #ifdef APP-PLUS
-        uni.clearStorage()
-        that.$store.commit("setLoginInfo", {})
-        plus.runtime.restart()
-        // #endif
-        // #ifdef MP-WEIXIN
-        clearLogin().then(res=>{
-          if(res.code == 1){
-            uni.clearStorage()
-            that.$store.commit("setLoginInfo", {})
-            uni.reLaunch({url:'/pages/home/recent'})
-          }
-        })
-        // #endif
-      })
-    },
     getSettleList(item){
       this.pageTo({ url:'/pages/settle/list?id='+item.id+'&account='+item.shopId})
     },

+ 23 - 1
mallApp/src/pages/user/edit.vue

@@ -21,6 +21,9 @@
 				<div class="btn-wrap">
 					<button class="button-com red big" formType="submit">确认</button>
 				</div>
+				<div class="btn-wrap">
+					<button class="button-com default big" @click="logout">退出</button>
+				</div>
 			</div>
 		</form>
 	</div>
@@ -28,7 +31,7 @@
 <script>
 import TuiListCell from '@/components/plugin/list-cell'
 const form = require('@/utils/formValidation.js')
-import { currentInfo,updateInfo } from "@/api/user";
+import { currentInfo,updateInfo,clearLogin } from "@/api/user";
 export default {
 	name: 'edit',
 	components: {
@@ -49,6 +52,25 @@ export default {
       prevPage.$vm.pageAction = {refresh:1}
 	},
 	methods: {
+		logout(){
+			let that = this
+			that.$util.confirmModal({content:'确认退出?'},() => {
+				// #ifdef APP-PLUS
+				uni.clearStorage()
+				that.$store.commit("setLoginInfo", {})
+				plus.runtime.restart()
+				// #endif
+				// #ifdef MP-WEIXIN
+				clearLogin().then(res=>{
+					if(res.code == 1){
+						uni.clearStorage()
+						that.$store.commit("setLoginInfo", {})
+						uni.reLaunch({url:'/pages/home/recent'})
+					}
+				})
+				// #endif
+			})
+		},
 		init(){
 			this.getLoginInfo();
 		},