diff --git a/common/src/main/java/com/yunbao/common/event/SendBlindGiftEvent.java b/common/src/main/java/com/yunbao/common/event/SendBlindGiftEvent.java index 6b0fd0b22..f39d62344 100644 --- a/common/src/main/java/com/yunbao/common/event/SendBlindGiftEvent.java +++ b/common/src/main/java/com/yunbao/common/event/SendBlindGiftEvent.java @@ -1,5 +1,7 @@ package com.yunbao.common.event; +import android.text.TextUtils; + import com.google.gson.annotations.SerializedName; import com.yunbao.common.bean.BaseModel; @@ -21,6 +23,8 @@ public class SendBlindGiftEvent extends BaseModel { private String totalcoin; @SerializedName("giftname") private String giftname; + @SerializedName("giftname_en") + private String giftname_en; @SerializedName("giftnameen") private String giftnameen; @SerializedName("gifticon") @@ -69,6 +73,8 @@ public class SendBlindGiftEvent extends BaseModel { private String needcoin; @SerializedName("gift_msg") private String giftMsg; + @SerializedName("gift_msg_en") + private String giftMsgen; @SerializedName("gift_colour") private String giftColour; @SerializedName("box_type") @@ -119,6 +125,15 @@ public class SendBlindGiftEvent extends BaseModel { return this; } + public String getGiftMsgen() { + return giftMsgen; + } + + public SendBlindGiftEvent setGiftMsgen(String giftMsgen) { + this.giftMsgen = giftMsgen; + return this; + } + public SendBlindGiftEvent setUserNiceName(String userNiceName) { this.userNiceName = userNiceName; return this; @@ -556,4 +571,13 @@ public class SendBlindGiftEvent extends BaseModel { this.liveGiftNotify = liveGiftNotify; return this; } + + public String getGiftname_en() { + return TextUtils.isEmpty(giftname_en)?giftnameen:giftname_en; + } + + public SendBlindGiftEvent setGiftname_en(String giftname_en) { + this.giftname_en = giftname_en; + return this; + } } diff --git a/common/src/main/java/com/yunbao/common/utils/WordsTypeUtil.java b/common/src/main/java/com/yunbao/common/utils/WordsTypeUtil.java index 0598af1c0..3ba779675 100644 --- a/common/src/main/java/com/yunbao/common/utils/WordsTypeUtil.java +++ b/common/src/main/java/com/yunbao/common/utils/WordsTypeUtil.java @@ -36,23 +36,22 @@ public class WordsTypeUtil { /** * @param {*} num - * @returns ---汉字 - */ + * @returns ---汉字 */ // 转换数字为大写 public static String numberConvertToUppercase(int number) { String[] upperCaseNumber = {"零", "一", "二", "三", "四", "五", "六", "七", "八", "九", "十"}; int length = String.valueOf(number).length(); if (length == 1) { - return upperCaseNumber[number]; + return WordUtil.isNewZh() ? upperCaseNumber[number] : String.valueOf(number); } else if (length == 2) { if (number == 10) { - return upperCaseNumber[number]; + return WordUtil.isNewZh() ? upperCaseNumber[number] : String.valueOf(number); } else if (number > 10 && number < 20) { - return upperCaseNumber[10] + upperCaseNumber[number - 10]; + return WordUtil.isNewZh() ? upperCaseNumber[10] : "1" + (WordUtil.isNewZh() ? upperCaseNumber[number - 10] : String.valueOf(number - 10)); } else { int num1 = number / 10; int num2 = number - (num1 * 10); - return upperCaseNumber[num1] + upperCaseNumber[10] + upperCaseNumber[num2]; + return (WordUtil.isNewZh() ? upperCaseNumber[num1] : String.valueOf(num1)) + (WordUtil.isNewZh() ? upperCaseNumber[10] : "") + (WordUtil.isNewZh() ? upperCaseNumber[num2] : String.valueOf(num2)); } } else { return String.valueOf(number); diff --git a/common/src/main/res/layout/view_tsak_center_child.xml b/common/src/main/res/layout/view_tsak_center_child.xml index 0299b3c4c..ce661659c 100644 --- a/common/src/main/res/layout/view_tsak_center_child.xml +++ b/common/src/main/res/layout/view_tsak_center_child.xml @@ -18,7 +18,9 @@