shish пре 3 дана
родитељ
комит
00334208fe
2 измењених фајлова са 41 додато и 16 уклоњено
  1. 1 1
      ghsApp/src/admin/billing/freeRefundList.vue
  2. 40 15
      hdApp/src/admin/ghs/pay.vue

+ 1 - 1
ghsApp/src/admin/billing/freeRefundList.vue

@@ -246,7 +246,7 @@ export default {
     init(){},
     init(){},
     fundText(item) {
     fundText(item) {
       if (Number(item.sameDay) !== 0) {
       if (Number(item.sameDay) !== 0) {
-        return '常规售后'
+        return '原路退回'
       }
       }
       const t = Number(item.fundType)
       const t = Number(item.fundType)
       if (t === 2) return '返充余额'
       if (t === 2) return '返充余额'

+ 40 - 15
hdApp/src/admin/ghs/pay.vue

@@ -19,15 +19,20 @@
 				<view class="pay-welcome-text">
 				<view class="pay-welcome-text">
 					<text class="pay-welcome-name">您好,{{ displayCustomName }}</text>
 					<text class="pay-welcome-name">您好,{{ displayCustomName }}</text>
 				</view>
 				</view>
+				<!-- 待结/余额各自独立:大于 0 才展示,为 0 不占位 -->
 				<view v-if="hasOutstanding" class="pay-debt-box">
 				<view v-if="hasOutstanding" class="pay-debt-box">
 					<view class="pay-debt-label">待结金额(元)</view>
 					<view class="pay-debt-label">待结金额(元)</view>
 					<view class="pay-debt-value">{{ outstandingAmount }}</view>
 					<view class="pay-debt-value">{{ outstandingAmount }}</view>
 				</view>
 				</view>
-				<!-- 次级入口:有待结时双按钮等宽,无待结时仅余额明细 -->
-				<view class="pay-entry-row" :class="{ 'pay-entry-row--single': !showGatheringBtn }">
+				<view v-if="hasBalance" class="pay-balance-box">
+					<view class="pay-balance-label">余额(元)</view>
+					<view class="pay-balance-value">{{ balanceAmount }}</view>
+				</view>
+				<!-- 次级入口:待结订单 / 余额明细始终并排等宽展示 -->
+				<view class="pay-entry-row">
 					<view
 					<view
-						v-if="showGatheringBtn"
 						class="pay-entry-btn"
 						class="pay-entry-btn"
+						:class="{ 'pay-entry-btn--disabled': !id }"
 						@click="goGathering">
 						@click="goGathering">
 						<text class="pay-entry-btn__text">查看待结订单</text>
 						<text class="pay-entry-btn__text">查看待结订单</text>
 					</view>
 					</view>
@@ -148,16 +153,17 @@
 			hasOutstanding() {
 			hasOutstanding() {
 				return this.outstandingAmount > 0
 				return this.outstandingAmount > 0
 			},
 			},
-			// 净 balance 为负时才展示待结明细入口
-			showGatheringBtn() {
-				if (!this.id || this.ghsDataLoading || this.loadError) {
-					return false
-				}
+			/** 可用余额:净 balance > 0 时展示,为 0 不显示 */
+			balanceAmount() {
 				const info = this.customInfo
 				const info = this.customInfo
 				if (!info || this.$util.isEmpty(info)) {
 				if (!info || this.$util.isEmpty(info)) {
-					return false
+					return 0
 				}
 				}
-				return parseFloat(info.balance || 0) < 0
+				const bal = parseFloat(info.balance || 0)
+				return bal > 0 ? bal : 0
+			},
+			hasBalance() {
+				return this.balanceAmount > 0
 			}
 			}
 		},
 		},
 		onLoad() {
 		onLoad() {
@@ -494,11 +500,6 @@
 		margin-top: 24upx;
 		margin-top: 24upx;
 	}
 	}
 
 
-	/* 单按钮时行宽约半行,按钮长度与双按钮场景下单个一致 */
-	.pay-entry-row--single {
-		width: 50%;
-	}
-
 	.pay-entry-btn {
 	.pay-entry-btn {
 		flex: 1;
 		flex: 1;
 		height: 72upx;
 		height: 72upx;
@@ -563,6 +564,30 @@
 		line-height: 60upx;
 		line-height: 60upx;
 	}
 	}
 
 
+	/* 余额卡片:样式对齐待结区,蓝色区分「有余」 */
+	.pay-balance-box {
+		margin-top: 24upx;
+		padding: 24upx 28upx;
+		background-color: #f5f9ff;
+		border: 1upx solid #d0e3ff;
+		border-radius: 12upx;
+		text-align: center;
+	}
+
+	.pay-balance-label {
+		font-size: 24upx;
+		color: $fontColor3;
+		line-height: 34upx;
+	}
+
+	.pay-balance-value {
+		margin-top: 8upx;
+		font-size: 52upx;
+		font-weight: bold;
+		color: #3385ff;
+		line-height: 60upx;
+	}
+
 	.pay-card--input {
 	.pay-card--input {
 		padding: 40upx 30upx 36upx;
 		padding: 40upx 30upx 36upx;
 	}
 	}