Browse Source

工作台

linwu 1 year ago
parent
commit
95ec056832
3 changed files with 35 additions and 13 deletions
  1. 20 6
      pages/broker/center.vue
  2. 14 6
      pages/broker/income.vue
  3. 1 1
      pages/my/my.vue

+ 20 - 6
pages/broker/center.vue

@@ -3,7 +3,7 @@
 		<image src="../../static/images/broker/topBg.png" class="header-image" mode="widthFix"></image>
 		<view class="cu-bar bg-white solid-bottom">
 			<view class="action">
-				<text class="cuIcon-title text-orange "></text> 我的收益
+				<text class="cuIcon-title text-orange "></text> {{income_title}}
 			</view>
 			<view class="action">
 				<button class="cu-btn bg-green shadow" @click="goNavPage('/pages/broker/income')">详情</button>
@@ -11,12 +11,12 @@
 		</view>
 		<view class="lw-table">
 			<view class="lw-table-item padding">
-				<view class="lw-table-value text-price text-bold text-red">{{statistics.income_total}}</view>
-				<view class="lw-table-title text-gray padding-top-xs">总收益</view>
+				<view :class="{'text-price':brokerinfo.type == 1}" class="lw-table-value text-bold text-red">{{statistics.income_total}}</view>
+				<view class="lw-table-title text-gray padding-top-xs">{{income_total_title}}</view>
 			</view>
 			<view class="lw-table-item padding">
-				<view class="lw-table-value text-price text-bold text-red">{{statistics.income}}</view>
-				<view class="lw-table-title text-gray padding-top-xs">当前收益</view>
+				<view :class="{'text-price':brokerinfo.type == 1}" class="lw-table-value text-bold text-red">{{statistics.income}}</view>
+				<view class="lw-table-title text-gray padding-top-xs">{{income_now_title}}</view>
 			</view>
 		</view>
 		<view class="cu-bar bg-white solid-bottom margin-top">
@@ -110,7 +110,21 @@
 					}
 				});
 			},
-		}
+		},
+		computed: {
+			income_title() {
+				return _this.brokerinfo.type == 1 ? '我的收益' : '我的积分';
+			},
+			income_total_title() {
+				return _this.brokerinfo.type == 1 ? '总收益' : '总积分';
+			},
+			income_now_title() {
+				return _this.brokerinfo.type == 1 ? '当前收益' : '剩余积分';
+			},
+			income_unit() {
+				return _this.brokerinfo.type == 1 ? '元' : '分';
+			},
+		},
 	}
 </script>
 

+ 14 - 6
pages/broker/income.vue

@@ -5,15 +5,15 @@
 			<view class="text-center padding-top">
 				<view class="text-sl padding-bottom-xs">{{brokerinfo.income}}</view>
 				<view>
-					当前收益
+					当前{{income_title}}
 				</view>
-				<view class="margin-top-sm">
+				<view class="margin-top-sm" v-if="brokerinfo.type == 1">
 					<button class="cu-btn round" data-name="cash" @tap="showModal" v-if="agentinfo.is_settle == 2">提现申请</button>
 				</view>
 			</view>
 			<view class="flex solid-bottom padding-top justify-between">
-				<view>上月获得:<text>{{month_income}}</text> </view>
-				<view>累计已获:<text>{{brokerinfo.income_total}}</text> </view>
+				<view>上月获得:<text>{{month_income}}</text> {{income_unit}}</view>
+				<view>累计已获:<text>{{brokerinfo.income_total}}</text> {{income_unit}}</view>
 			</view>
 		</view>
 		
@@ -31,7 +31,7 @@
 					</view>
 					<view class="action text-red">
 						<view :class="item.status == 2 ? 'text-blue' : 'text-red'">{{item.status_text}}</view>
-						<view class="text-red">{{item.value > 0 ? '+' : ''}}{{item.value}}</view>
+						<view class="text-red">{{item.value > 0 ? '+' : ''}}{{item.value}}{{income_unit}}</view>
 					</view>
 				</view>
 			</block>
@@ -232,7 +232,15 @@
 					url: pageurl
 				});
 			},
-		}
+		},
+		computed: {
+			income_title() {
+				return _this.brokerinfo.type == 1 ? '收益' : '积分';
+			},
+			income_unit() {
+				return _this.brokerinfo.type == 1 ? '元' : '分';
+			},
+		},
 	}
 </script>
 

+ 1 - 1
pages/my/my.vue

@@ -57,7 +57,7 @@
 				<image class="left-icon" :src="$getImageUrl('static/images/applet/index/topApplyIcon.png')"></image>
 			</view>
 			<view class="topApply-center" v-if="brokerall == null">经纪人福利多多</view>
-			<view class="topApply-center" v-if="brokerall != null">经纪人中心</view>
+			<view class="topApply-center" v-if="brokerall != null">{{brokerall[0].type == 1 ? '经纪人中心' : '红色合伙人'}}</view>
 			<view class="topApply-right" v-if="brokerall == null" @tap="goLPage('/pages/broker/brokerform')">立即开通</view>
 			<view class="topApply-right" v-if="brokerall != null" @tap="goLPage('/pages/broker/center')">进入工作台</view>
 		</view>