소스 검색

部分更新及优化

hwb0 3 년 전
부모
커밋
ace9a0d971
2개의 변경된 파일6개의 추가작업 그리고 4개의 파일을 삭제
  1. 1 1
      packageOther/about/index.vue
  2. 5 3
      pages/index/index.vue

+ 1 - 1
packageOther/about/index.vue

@@ -4,7 +4,7 @@
 		<view class="about">
 			<view class="flex about-logo">
 				<image src="../../static/public/logo.png" mode=""></image>
-				<view class="edition">v 2.0.0</view>
+				<view class="edition">v 2.0.1</view>
 			</view>
 			<view class="about-action">
 				<u-cell-group :border="false">

+ 5 - 3
pages/index/index.vue

@@ -254,9 +254,11 @@
 			// 活动
 			getActivityList() {
 				$http.post(`/api/v1/mp/user/marketing/recent`, {}).then(res => {
-					let data = res && res.data
-					let timestamp = parseInt(new Date().getTime())
-					this.activityTime = data.endTime - timestamp
+					if(res && res.data) {
+						let data = res && res.data
+						let timestamp = parseInt(new Date().getTime())
+						this.activityTime = data.endTime - timestamp
+					}
 				})
 			},