fix(recharge): correct Aslan gold USD conversion

This commit is contained in:
zhx 2026-07-15 12:02:48 +08:00
parent f8d7e3d723
commit 08d4e4fe4a
3 changed files with 25 additions and 3 deletions

View File

@ -96,8 +96,9 @@ public enum MonthlyRechargeType {
* 个人充值.
*/
public static List<MonthlyRechargeType> getPersonalRecharge() {
return List.of(UNDEFINED, HUAWEI, GOOGLE, APPLE, PAYER_MAX, SHIPPING_AGENT, STRIPE,
SALARY_EXCHANGE,
// MiFaPay Aslan 的真实现金充值渠道必须纳入累计充值和充值奖励口径
return List.of(UNDEFINED, HUAWEI, GOOGLE, APPLE, PAYER_MAX, MIFA_PAY, SHIPPING_AGENT,
STRIPE, SALARY_EXCHANGE,
PAY_PAL, CLIPSPAY, SELLER_AGENT);
}

View File

@ -0,0 +1,20 @@
package com.red.circle.wallet.app.command.freight;
import com.red.circle.order.inner.model.enums.MonthlyRechargeType;
import com.red.circle.wallet.infra.enums.FreightGoldToUsdRatioEnum;
import org.junit.Assert;
import org.junit.Test;
public class RechargeConversionConfigTest {
@Test
public void aslanConvertsEightyThousandGoldToOneUsd() {
Assert.assertEquals(80000, FreightGoldToUsdRatioEnum.getRatio("ATYOU"));
}
@Test
public void personalRechargeIncludesMifaPay() {
Assert.assertTrue(MonthlyRechargeType.getPersonalRecharge()
.contains(MonthlyRechargeType.MIFA_PAY));
}
}

View File

@ -24,7 +24,8 @@ public enum FreightGoldToUsdRatioEnum {
*/
YOLO(6000),
LIKEI(10000),
ATYOU(10000),
/** Aslan 统一按 80,000 金币折算 1 美元。 */
ATYOU(80000),
LOTFUN(6000);
private final int ratio;