Browse Source

待整改首页

zyj 1 year ago
parent
commit
5205bfdc18
1 changed files with 11 additions and 5 deletions
  1. 11 5
      pages/ypczk/djfk/index/djfkIndex.vue

+ 11 - 5
pages/ypczk/djfk/index/djfkIndex.vue

@@ -5,7 +5,7 @@
 		<view class="djfkIndex_header">
 			<view class="info">
 				<view class="info_img">
-					<image :src="pageData.headImg" class="headImg"></image>
+					<image :src="pageData.headImg" mode="center" class="headImg"></image>
 				</view>
 				<text class="userName">{{pageData.userName}}</text>
 				<!-- <image :src="eyeIcon.nowIcon" class="eyeIcon" @click="changeState('header')"></image> -->
@@ -192,10 +192,16 @@ const getUserInfo=()=>{
 // 获取待整改任务数量
 const getZgNumber=()=>{
 	http.get("app-api/rectify/getZgNumber").then(res=>{
-		uni.setTabBarBadge({
-			index:3,
-			text:res.toString()
-		})
+		if(res==0){
+			uni.removeTabBarBadge({
+				index:3
+			})
+		}else{
+			uni.setTabBarBadge({
+				index:3,
+				text:res.toString()
+			})
+		}
 	})
 }