From abce02c7a61820f5d580f87364d542e817be429c Mon Sep 17 00:00:00 2001
From: admin <weikou2014>
Date: 星期二, 06 七月 2021 15:22:11 +0800
Subject: [PATCH] 1.1.1完善

---
 app/src/main/java/com/tejia/lijin/app/ui/goods/GoodsDetailHongBaoListAdapter.java |   22 ++++++++++++++++++++--
 1 files changed, 20 insertions(+), 2 deletions(-)

diff --git a/app/src/main/java/com/tejia/lijin/app/ui/goods/GoodsDetailHongBaoListAdapter.java b/app/src/main/java/com/tejia/lijin/app/ui/goods/GoodsDetailHongBaoListAdapter.java
index 0c682cd..1239de1 100644
--- a/app/src/main/java/com/tejia/lijin/app/ui/goods/GoodsDetailHongBaoListAdapter.java
+++ b/app/src/main/java/com/tejia/lijin/app/ui/goods/GoodsDetailHongBaoListAdapter.java
@@ -23,6 +23,7 @@
 import com.tejia.lijin.app.entity.goods.GoodsDetailVO;
 import com.tejia.lijin.app.ui.invite.ShareBrowserActivity;
 import com.tejia.lijin.app.util.GlideRoundTransform;
+import com.tejia.lijin.app.util.ui.GoodsDetailUtil;
 import com.wpc.library.util.common.DimenUtils;
 import com.wpc.library.util.common.StringUtils;
 
@@ -69,6 +70,8 @@
             }
         });
 
+
+
         boolean fanli = hongBaoInfo.getType() == 4;
 
         //鍒濆鍖朧iew鏄剧ず
@@ -103,15 +106,25 @@
         viewHolder.tv_sub_money.setText(hbMoney);
         viewHolder.tv_sub_money.setCompoundDrawablePadding(DimenUtils.dip2px(mContext, 8));
         if (hongBao) {
+            String finalMoneyStr = null;
             if (fanli) {
+                viewHolder.tv_actual_name.setText("鍒版墜浠�");
+                finalMoneyStr = "鍒版墜浠� " + hongBaoInfo.getFinalMoney();
                 viewHolder.tv_sub_money.setCompoundDrawablesWithIntrinsicBounds(R.drawable.icon_goods_detail_hongbao_fanli, 0, 0, 0);
             } else {
+                viewHolder.tv_actual_name.setText("绔嬪噺浠�");
+                finalMoneyStr = "绔嬪噺浠� " + hongBaoInfo.getFinalMoney();
                 viewHolder.tv_sub_money.setCompoundDrawablesWithIntrinsicBounds(R.drawable.icon_goods_detail_hongbao_hb, 0, 0, 0);
             }
             viewHolder.tv_sub_money_desc.setTextSize(9);
-            SpannableString finalMoney = new SpannableString(hongBaoInfo.getFinalMoney());
-            finalMoney.setSpan(new RelativeSizeSpan(1.77f), 1, (hongBaoInfo.getFinalMoney().indexOf(".") > -1 ? hongBaoInfo.getFinalMoney().indexOf(".") : hongBaoInfo.getFinalMoney().length()), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
+
+            SpannableString finalMoney = new SpannableString(finalMoneyStr);
+            finalMoney.setSpan(new RelativeSizeSpan(1.77f), 4 + 1, (finalMoneyStr.indexOf(".") > -1 ? finalMoneyStr.indexOf(".") : finalMoneyStr.length()), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
             viewHolder.tv_final_money.setText(finalMoney);
+            //璁剧疆鏄惁鑷姩灞曞紑璇︽儏
+            if (GoodsDetailUtil.spreadHoneBaoOrFanLiDetail(mContext)) {
+                viewHolder.fl_more.performClick();
+            }
         } else {
             viewHolder.tv_sub_money.setCompoundDrawablesWithIntrinsicBounds(R.drawable.icon_goods_detail_hongbao_coupon, 0, 0, 0);
             viewHolder.tv_sub_money_desc.setTextSize(12);
@@ -147,6 +160,8 @@
                 }
             }
         });
+
+
 
     }
 
@@ -233,6 +248,7 @@
         TextView tv_sub_money;
         TextView tv_sub_money_desc;
         TextView tv_final_money;
+        TextView tv_actual_name;
         ImageView iv_more;
         FrameLayout fl_more;
         TextView tv_desc;
@@ -284,6 +300,8 @@
             v_hongbao_cut_1 = itemView.findViewById(R.id.v_hongbao_cut_1);
             v_hongbao_cut_2 = itemView.findViewById(R.id.v_hongbao_cut_2);
 
+            tv_actual_name= itemView.findViewById(R.id.tv_actual_name);
+
 
             tv_actual_money = itemView.findViewById(R.id.tv_actual_money);
             ll_level_info = itemView.findViewById(R.id.ll_level_info);

--
Gitblit v1.8.0