快乐的梦鱼 1 settimana fa
parent
commit
e290e0a2fe
2 ha cambiato i file con 4 aggiunte e 8 eliminazioni
  1. 2 2
      config/api.js
  2. 2 6
      pages/index/index.vue

+ 2 - 2
config/api.js

@@ -83,7 +83,7 @@ let methodsToken = ['profile', 'refreshUser', 'wxLogin', 'changeMobile', 'addCar
 	'getPatrolLog', 'claimCrList', 'claimCrDetails', 'editMainBodyUser', , 'contribute',
 	'getPatrolTaskDetails', 'getContentDetail', 'examineVolunteer', 'userManageRegionCrAuth', 'applyVolunteer',
 	'getPhoneNumber', 'editApplyVolunteer', 'mobileBindVolunteer', 'getTeamDetails', 'examineTask', 'removeMemberm',
-	'getScoreLog', 'rankingList', 'getMainBodyColumnContentList', 'regionData', 'cityData', 'checkIn', 'scanApplyVolunteer', 'scanApplyVolunteer',
+	'getScoreLog', 'getMainBodyColumnContentList', 'regionData', 'cityData', 'checkIn', 'scanApplyVolunteer', 'scanApplyVolunteer',
 	'getMainBodyUser', 'getUserContribute', 'getUserHonor', 'submitTask', 'exportPatrolRecord', 'userManageCrAuth',
 	'getDevices', 'submitIdentityInfo', 'submitActivitySignupInfo','getUserSignupActivity', 'getUserSignupActivityDetails'
 ];
@@ -103,7 +103,7 @@ const post = (method, data, callback, type, orgurl) => {
 		common.isLogin();
 		//新增用户判断是否登录逻辑end
 		if (!auth || auth.createtime + auth.expires_in < nowdate) {
-			//FUCK: common.toLogin();
+			common.toLogin();
 			return false;
 		} else {
 			userToken = auth.token;

+ 2 - 6
pages/index/index.vue

@@ -66,7 +66,7 @@
 			<view class="pm_tit" style="width: 145rpx">任务达标率</view>
 		</view>
 		<view class="xx_box">
-			<scroll-view v-if="user" style="height: 1000rpx" scroll-y="true" @scrolltolower="LoadMoress">
+			<scroll-view style="height: 1000rpx" scroll-y="true" @scrolltolower="LoadMoress">
 				<view @click="detailsBtn(item.id)" class="xx_item" v-for="(item, index) in information" :key="item.id">
 					<view style="width: 64rpx; height: 64rpx">{{ index + 1 }}</view>
 					<view style="width: 120rpx; font-size: 32rpx">{{ item.name }}</view>
@@ -75,10 +75,6 @@
 					<view>{{ item.completion_rate }}</view>
 				</view>
 			</scroll-view>
-      <span 
-        v-else style="text-align: center; display: block; margin-top: 200rpx;"
-        @click="$common.toLogin()"
-      >欢迎成为志愿者,请先登录</span>
 		</view>
 		<view class="map_tit" style="margin-left: 90rpx">
 			<image style="width: 211rpx; height: 52rpx" src="/static/img/right_img.png"></image>
@@ -202,7 +198,7 @@ export default {
 		this.user = this.$common.userInfo();
 		if (this.user === 'undefined' || this.user === '' || this.user === [] || this.user === null) {
 			/* 跳转到登录页 */
-			//this.$common.toLogin();
+			this.$common.toLogin();
 		} else {
 			// console.log(this.user);
 			// 如果登录自动打卡