mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 11:05:18 +08:00
update 电单车
This commit is contained in:
@@ -87,7 +87,13 @@ public class IdUtils {
|
||||
public static String generateTransactionCode(String pileConnectorCode) {
|
||||
String timeNow = DateUtils.dateTimeNow(DateUtils.YYMMDDHHMMSS);
|
||||
// 随机生成一个四位整数
|
||||
String randomNumber = RandomUtil.getRandomNumberStr(4);
|
||||
String randomNumber = null;
|
||||
if (pileConnectorCode.length() < 14) {
|
||||
randomNumber = RandomUtil.getRandomNumberStr(8);
|
||||
} else {
|
||||
randomNumber = RandomUtil.getRandomNumberStr(4);
|
||||
}
|
||||
|
||||
return pileConnectorCode + timeNow + randomNumber;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user