1、完善积分充值
2、升级积分扣除机制 3、优化部分代码
This commit is contained in:
@@ -10,14 +10,14 @@ public class MQConfig {
|
||||
public static final String GENERATE_EXCHANGE_FANOUT = "generate-exchange";
|
||||
// public static final String GENERATE_QUEUE = "generate-queue-prod";
|
||||
// public static final String GENERATE_QUEUE = "generate-queue-test";
|
||||
public static final String GENERATE_QUEUE = "generate-queue-dev";
|
||||
// public static final String GENERATE_QUEUE = "generate-queue";
|
||||
// public static final String GENERATE_QUEUE = "generate-queue-dev";
|
||||
public static final String GENERATE_QUEUE = "generate-queue-local";
|
||||
|
||||
public static final String SR_QUEUE = "SR-queue-dev";
|
||||
// public static final String SR_QUEUE = "SR-queue-local";
|
||||
// public static final String SR_QUEUE = "SR-queue-dev";
|
||||
public static final String SR_QUEUE = "SR-queue-local";
|
||||
|
||||
// public static final String SR_RESULT_QUEUE = "SuperResolution-local";
|
||||
public static final String SR_RESULT_QUEUE = "SuperResolution-dev";
|
||||
public static final String SR_RESULT_QUEUE = "SuperResolution-local";
|
||||
// public static final String SR_RESULT_QUEUE = "SuperResolution-dev";
|
||||
|
||||
public MQConfig() {
|
||||
}
|
||||
|
||||
10
src/main/java/com/ai/da/common/constant/CommonConstant.java
Normal file
10
src/main/java/com/ai/da/common/constant/CommonConstant.java
Normal file
@@ -0,0 +1,10 @@
|
||||
package com.ai.da.common.constant;
|
||||
|
||||
public class CommonConstant {
|
||||
// 单位 秒 一天过期
|
||||
public static final Long TASK_EXPIRE_TIME = 24 * 60 * 60L;
|
||||
// 单位 秒 两天过期
|
||||
public static final Long CREDITS_EXPIRE_TIME = 2 * 24 * 60 * 60L;
|
||||
// 单位 分钟
|
||||
public static final Integer MINIO_IMAGE_EXPIRE_TIME = 24 * 60;
|
||||
}
|
||||
@@ -2,9 +2,6 @@ package com.ai.da.common.constant;
|
||||
|
||||
public class PayPalCheckoutConstant {
|
||||
|
||||
// public static String MODE = "sandbox";
|
||||
public static String MODE = "live";
|
||||
|
||||
public static final String CAPTURE = "CAPTURE";
|
||||
/**
|
||||
* 该标签将覆盖PayPal网站上PayPal帐户中的公司名称
|
||||
@@ -168,12 +165,6 @@ public class PayPalCheckoutConstant {
|
||||
|
||||
public final static String CMD_NOTIFY_VALIDATE = "_notify-validate";
|
||||
|
||||
// public final static String WEBHOOK_ID = "31797347YC028794L";
|
||||
// kim-sandbox
|
||||
// public final static String WEBHOOK_ID = "1WH327112B602422N";
|
||||
// kim-live
|
||||
public final static String WEBHOOK_ID = "41L14847MC833625B";
|
||||
|
||||
public final static String PAYPAL_TOKEN_KEY = "PayPalAccessToken";
|
||||
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ public enum CreditsEventsEnum {
|
||||
|
||||
PRICE("price","1"),
|
||||
// 6USD -> 1000 points ==> 10HKD -> 215 points ==> 2HKD -> 43points
|
||||
BUY_CREDITS("Buy Credits","43"),
|
||||
BUY_CREDITS("Buy Credits","50"),
|
||||
|
||||
INIT("init", "1000"),
|
||||
|
||||
|
||||
@@ -136,6 +136,10 @@ public class RedisUtil {
|
||||
}
|
||||
|
||||
//- - - - - - - - - - - - - - - - - - - - - String类型 - - - - - - - - - - - - - - - - - - - -
|
||||
public void addToString(String key, String value){
|
||||
redisTemplate.opsForValue().set(key,value);
|
||||
}
|
||||
|
||||
public void addToString(String key, String value, Long expiresIn){
|
||||
redisTemplate.opsForValue().set(key,value,expiresIn, TimeUnit.SECONDS);
|
||||
}
|
||||
@@ -156,4 +160,8 @@ public class RedisUtil {
|
||||
return redisTemplate.getExpire(key);
|
||||
}
|
||||
|
||||
public void removeFromString(String key){
|
||||
redisTemplate.delete(key);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user