From a66b2a41f265cc9526781e39c1d6c6d5f5d7c013 Mon Sep 17 00:00:00 2001
From: peter <14100000001@qq.com>
Date: Thu, 01 Jan 2026 02:29:08 +0800
Subject: [PATCH] 新增港股
---
src/main/resources/application.properties | 5 +
src/main/java/com/nq/vo/user/UserInfoVO.java | 5 +
src/main/java/com/nq/vo/position/PositionVO.java | 18 ++++
src/main/java/com/nq/pojo/User.java | 2
src/main/java/com/nq/service/impl/UserPositionServiceImpl.java | 137 ++++++++++++++++++++--------------
src/main/resources/application.yml | 10 +-
src/main/java/com/nq/service/impl/UserServiceImpl.java | 29 +++++-
7 files changed, 138 insertions(+), 68 deletions(-)
diff --git a/src/main/java/com/nq/pojo/User.java b/src/main/java/com/nq/pojo/User.java
index f3faa37..c3e9b28 100644
--- a/src/main/java/com/nq/pojo/User.java
+++ b/src/main/java/com/nq/pojo/User.java
@@ -84,6 +84,8 @@
private BigDecimal djzj;
+ private BigDecimal enaleWithdrawAmtHk;
+
public User(Integer id, Integer agentId, String agentName, String phone, String userPwd, String withPwd, String nickName, String realName, String idCard, Integer accountType, BigDecimal userAmt, BigDecimal enableAmt, BigDecimal enaleWithdrawAmt, BigDecimal hkAmt, BigDecimal sumChargeAmt, BigDecimal sumBuyAmt, String recomPhone, Integer isLock, Integer isLogin, Date regTime, String regIp, String regAddress, String img1Key, String img2Key, String img3Key, Integer isActive, String authMsg, BigDecimal userIndexAmt, BigDecimal enableIndexAmt, BigDecimal userFutAmt, BigDecimal enableFutAmt, String withdrawalPwd, BigDecimal tradingAmount, Integer isAuthorize, BigDecimal sgzj, BigDecimal djzj) {
this.id = id;
this.agentId = agentId;
diff --git a/src/main/java/com/nq/service/impl/UserPositionServiceImpl.java b/src/main/java/com/nq/service/impl/UserPositionServiceImpl.java
index 719fdfd..901e9ea 100644
--- a/src/main/java/com/nq/service/impl/UserPositionServiceImpl.java
+++ b/src/main/java/com/nq/service/impl/UserPositionServiceImpl.java
@@ -129,6 +129,7 @@
return ServerResponse.createByErrorMsg("下单失败,请先实名认证");
}
BigDecimal user_enable_amt = user.getEnableAmt();
+
BigDecimal user_enable_withdraw_amt = user.getEnaleWithdrawAmt();
log.info("用户 {} 下单,股票id = {} ,数量 = {} , 方向 = {} , 杠杆 = {}", new Object[]{user
.getId(), stockId, buyNum, buyType, lever});
@@ -185,7 +186,7 @@
boolean am_flag = BuyAndSellUtils.isTransTime(am_begin, am_end);
boolean pm_flag = BuyAndSellUtils.isTransTime(pm_begin, pm_end);
log.info("是否在上午交易时间 = {} 是否在下午交易时间 = {}", Boolean.valueOf(am_flag), Boolean.valueOf(pm_flag));
-
+ //TODO
if (!am_flag && !pm_flag) {
return ServerResponse.createByErrorMsg("下单失败,不在交易时段内");
}
@@ -222,7 +223,6 @@
}
BigDecimal now_price;
StockListVO stockListVO = new StockListVO();
- StockCoin stockCoin = new StockCoin();
//股票类型 现价 数据源的处理
stockListVO = SinaStockApi.assembleLideStockListVO(LiDeDataUtils.getStock(stock.getStockCode()));
if (ObjectUtils.isEmpty(stockListVO)) {
@@ -232,6 +232,7 @@
stockListVO = SinaStockApi.assembleStockListVO(SinaStockApi.getSinaStock(stock.getStockGid()));
}
}
+
now_price = new BigDecimal(stockListVO.getNowPrice());
if (now_price.compareTo(new BigDecimal("0")) == 0) {
@@ -351,7 +352,9 @@
.getBuyMinAmt() + "元");
}
-
+ if(StockType.HK.getCode().equals(stock.getStockType())){
+ user_enable_amt = user.getHkAmt();
+ }
BigDecimal max_buy_amt = user_enable_amt.multiply(siteSetting.getBuyMaxAmtPercent());
int compareCwInt = buy_amt_autual.compareTo(max_buy_amt);
if (compareCwInt == 1) {
@@ -459,7 +462,7 @@
//修改用户可用余额= 当前余额-下单金额-买入手续费-印花税-点差费
//BigDecimal reckon_enable = user_enable_amt.subtract(buy_amt_autual).subtract(buy_fee_amt).subtract(buy_yhs_amt).subtract(spread_rate_amt);
//修改用户可用余额= 当前余额-下单总金额
- BigDecimal reckon_enable = user_enable_amt.subtract(buy_amt_autual);
+ BigDecimal reckon_enable = user_enable_amt.subtract(buy_amt_autual);;
//修改用户可取余额=当前可取余额-下单总金额
int compareUserWithdrawAmtInt = user_enable_withdraw_amt.compareTo(buy_amt_autual);
if (compareUserWithdrawAmtInt == -1) {
@@ -469,7 +472,12 @@
user_enable_withdraw_amt = user_enable_withdraw_amt.subtract(buy_amt_autual);
user.setEnaleWithdrawAmt(user_enable_withdraw_amt);
}
- user.setEnableAmt(reckon_enable);
+ if(StockType.HK.getCode().equals(stock.getStockType())){
+ user.setHkAmt(reckon_enable);
+ }else {
+ user.setEnableAmt(reckon_enable);
+ }
+
int updateUserCount = this.userMapper.updateByPrimaryKeySelective(user);
if (updateUserCount > 0) {
log.info("【用户交易下单】修改用户金额成功");
@@ -575,6 +583,7 @@
boolean am_flag = BuyAndSellUtils.isTransTime(am_begin, am_end);
boolean pm_flag = BuyAndSellUtils.isTransTime(pm_begin, pm_end);
log.info("是否在上午交易時間 = {} 是否在下午交易時間 = {}", Boolean.valueOf(am_flag), Boolean.valueOf(pm_flag));
+ //TODO
if (!am_flag && !pm_flag) {
return ServerResponse.createByErrorMsg("平仓失败,不在交易时段内");
}
@@ -682,7 +691,12 @@
}
log.info("買入總金額 = {} , 賣出總金額 = {} , 盈虧 = {}", new Object[]{all_buy_amt, all_sell_amt, profitLoss});
- BigDecimal user_all_amt = user.getUserAmt();
+ BigDecimal user_all_amt = BigDecimal.ZERO;
+ if(StockType.HK.getCode().equals(userPosition.getStockType())){
+ user_all_amt = user.getHkAmt();
+ }else {
+ user_all_amt = user.getUserAmt();
+ }
BigDecimal user_enable_amt = user.getEnableAmt();
log.info("用戶原本總資金 = {} , 可用 = {}", user_all_amt, user_enable_amt);
@@ -727,14 +741,17 @@
BigDecimal freez_amt = all_buy_amt.divide(new BigDecimal(userPosition.getOrderLever().intValue()), 2, 4);
//BigDecimal freez_amt = all_buy_amt;
-
BigDecimal reckon_all = user_all_amt.add(all_profit);
//修改用戶可用余額=當前可用余額+總盈虧+買入總金額+追加保證金
BigDecimal reckon_enable = user_enable_amt.add(all_profit).add(freez_amt).add(userPosition.getMarginAdd());
-
log.info("用戶平倉後的總資金 = {} , 可用資金 = {}", reckon_all, reckon_enable);
- user.setUserAmt(reckon_all);
- user.setEnableAmt(reckon_enable);
+
+ if(StockType.HK.getCode().equals(userPosition.getStockType())){
+ user.setHkAmt(reckon_enable);
+ }else {
+ user.setUserAmt(reckon_all);
+ user.setEnableAmt(reckon_enable);
+ }
int updateUserCount = this.userMapper.updateByPrimaryKeySelective(user);
if (updateUserCount > 0) {
log.info("【用戶平倉】修改用戶金額成功");
@@ -1171,62 +1188,67 @@
BigDecimal allProfitAndLose = new BigDecimal("0");
BigDecimal allFreezAmt = new BigDecimal("0");
+ BigDecimal allProfitAndLoseHk = new BigDecimal("0");
+ BigDecimal allFreezAmtHk = new BigDecimal("0");
for (UserPosition position : userPositions) {
-
StockListVO stockListVO = SinaStockApi.assembleLideStockListVO(LiDeDataUtils.getStock(position.getStockCode()));
if (ObjectUtils.isEmpty(stockListVO)) {
if(StockType.HK.getCode().equals(position.getStockType())){
stockListVO = SinaStockApi.assembleStockListVOHk(SinaStockApi.getSinaStock(position.getStockType()+position.getStockGid()));
+ if (stockListVO.getNowPrice() == null || new BigDecimal(stockListVO.getNowPrice()).compareTo(BigDecimal.ZERO) <= 0) {
+ stockListVO.setNowPrice(String.valueOf(position.getBuyOrderIdIndex()));
+ }
+ BigDecimal nowPrice = new BigDecimal(stockListVO.getNowPrice());
+ if (nowPrice.compareTo(new BigDecimal("0")) != 0) {
+ BigDecimal buyPrice = position.getBuyOrderPrice();
+ BigDecimal subPrice = nowPrice.subtract(buyPrice);
+ BigDecimal profit_and_lose = subPrice.multiply(new BigDecimal(position.getOrderNum().intValue()));
+ if ("买跌".equals(position.getOrderDirection())) {
+ profit_and_lose = profit_and_lose.negate();
+ }
+ BigDecimal total_fee = position.getOrderFee().add(position.getOrderSpread()).add(position.getOrderStayFee());
+ BigDecimal position_profit = profit_and_lose.subtract(total_fee);
+ allProfitAndLoseHk = allProfitAndLoseHk.add(position_profit);
+ BigDecimal position_freez = position.getOrderTotalPrice().divide(new BigDecimal(position.getOrderLever().intValue()), 2, 4);
+ allFreezAmtHk = allFreezAmtHk.add(position_freez).add(position.getMarginAdd());
+ continue;
+ }
+ log.info("查询所有持仓单的总盈亏,现价返回0,当前为集合竞价");
}else {
stockListVO = SinaStockApi.assembleStockListVO(SinaStockApi.getSinaStock(position.getStockGid()));
+ if (stockListVO.getNowPrice() == null || new BigDecimal(stockListVO.getNowPrice()).compareTo(BigDecimal.ZERO) <= 0) {
+ stockListVO.setNowPrice(String.valueOf(position.getBuyOrderIdIndex()));
+ }
+ BigDecimal nowPrice = new BigDecimal(stockListVO.getNowPrice());
+ if (nowPrice.compareTo(new BigDecimal("0")) != 0) {
+ BigDecimal buyPrice = position.getBuyOrderPrice();
+ BigDecimal subPrice = nowPrice.subtract(buyPrice);
+ BigDecimal profit_and_lose = subPrice.multiply(new BigDecimal(position.getOrderNum().intValue()));
+ if ("买跌".equals(position.getOrderDirection())) {
+ profit_and_lose = profit_and_lose.negate();
+ }
+ BigDecimal total_fee = position.getOrderFee().add(position.getOrderSpread()).add(position.getOrderStayFee());
+ BigDecimal position_profit = profit_and_lose.subtract(total_fee);
+ allProfitAndLose = allProfitAndLose.add(position_profit);
+ BigDecimal position_freez = position.getOrderTotalPrice().divide(new BigDecimal(position.getOrderLever().intValue()), 2, 4);
+ allFreezAmt = allFreezAmt.add(position_freez).add(position.getMarginAdd());
+ continue;
+ }
+ log.info("查询所有持仓单的总盈亏,现价返回0,当前为集合竞价");
}
}
-
- if (stockListVO.getNowPrice() == null || new BigDecimal(stockListVO.getNowPrice()).compareTo(BigDecimal.ZERO) <= 0) {
- stockListVO.setNowPrice(String.valueOf(position.getBuyOrderIdIndex()));
- }
-
-
- BigDecimal nowPrice = new BigDecimal(stockListVO.getNowPrice());
-
-
- if (nowPrice.compareTo(new BigDecimal("0")) != 0) {
-
- BigDecimal buyPrice = position.getBuyOrderPrice();
- BigDecimal subPrice = nowPrice.subtract(buyPrice);
-
- BigDecimal profit_and_lose = subPrice.multiply(new BigDecimal(position.getOrderNum().intValue()));
- if ("买跌".equals(position.getOrderDirection())) {
- profit_and_lose = profit_and_lose.negate();
- }
-
-
- BigDecimal total_fee = position.getOrderFee().add(position.getOrderSpread()).add(position.getOrderStayFee());
-
-
- BigDecimal position_profit = profit_and_lose.subtract(total_fee);
-
-
- allProfitAndLose = allProfitAndLose.add(position_profit);
-
-
- BigDecimal position_freez = position.getOrderTotalPrice().divide(new BigDecimal(position.getOrderLever().intValue()), 2, 4);
- allFreezAmt = allFreezAmt.add(position_freez).add(position.getMarginAdd());
- continue;
- }
- log.info("查询所有持仓单的总盈亏,现价返回0,当前为集合竞价");
}
//加上分仓交易保证金
- List<FundsApply> fundsApplyList = fundsApplyMapper.getUserMarginList(userId);
- for (FundsApply fundsApply : fundsApplyList) {
- allFreezAmt = allFreezAmt.add(fundsApply.getMargin());
- }
-
-
+// List<FundsApply> fundsApplyList = fundsApplyMapper.getUserMarginList(userId);
+// for (FundsApply fundsApply : fundsApplyList) {
+// allFreezAmt = allFreezAmt.add(fundsApply.getMargin());
+// }
PositionVO positionVO = new PositionVO();
positionVO.setAllProfitAndLose(allProfitAndLose);
positionVO.setAllFreezAmt(allFreezAmt);
+ positionVO.setAllProfitAndLoseHk(allProfitAndLoseHk);
+ positionVO.setAllFreezAmtHk(allFreezAmtHk);
return positionVO;
}
@@ -1850,14 +1872,17 @@
BigDecimal subPrice = (new BigDecimal(nowPrice)).subtract(position.getBuyOrderPrice());
// profitAndLose = subPrice.multiply(new BigDecimal(position.getOrderNum().intValue())).multiply(new BigDecimal(position.getOrderLever())).setScale(2,4);
profitAndLose = subPrice.multiply(new BigDecimal(position.getOrderNum().intValue())).setScale(2,4);
- if ("买跌".equals(position.getOrderDirection())) {
- profitAndLose = profitAndLose.negate();
- }
- //总盈亏= 浮动盈亏 – 手续费 – 印花税 – 留仓费 – 点差费
- allProfitAndLose = profitAndLose.subtract(position.getOrderFee()).subtract(position.getOrderSpread()).subtract(position.getOrderStayFee()).subtract(position.getSpreadRatePrice());
//改成盈亏百分比
BigDecimal allProfitAndLoseStrTemp = new BigDecimal(nowPrice).subtract(position.getBuyOrderPrice()).divide(position.getBuyOrderPrice(), 4, RoundingMode.HALF_UP).multiply(new BigDecimal(100)).setScale(2,4);
allProfitAndLoseStr = allProfitAndLoseStrTemp.toString() + "%";
+ if ("买跌".equals(position.getOrderDirection())) {
+ profitAndLose = profitAndLose.negate();
+ allProfitAndLoseStr = allProfitAndLoseStrTemp.negate() + "%";
+ }
+ //总盈亏= 浮动盈亏 – 手续费 – 印花税 – 留仓费 – 点差费
+ allProfitAndLose = profitAndLose.subtract(position.getOrderFee()).subtract(position.getOrderSpread()).subtract(position.getOrderStayFee()).subtract(position.getSpreadRatePrice());
+
+
}
PositionProfitVO positionProfitVO = new PositionProfitVO();
positionProfitVO.setProfitAndLose(profitAndLose);
diff --git a/src/main/java/com/nq/service/impl/UserServiceImpl.java b/src/main/java/com/nq/service/impl/UserServiceImpl.java
index 5cbab4a..f90f3ef 100644
--- a/src/main/java/com/nq/service/impl/UserServiceImpl.java
+++ b/src/main/java/com/nq/service/impl/UserServiceImpl.java
@@ -1842,10 +1842,12 @@
PositionVO positionVO = this.iUserPositionService.findUserPositionAllProfitAndLose(user.getId());
userInfoVO.setAllFreezAmt(positionVO.getAllFreezAmt());
+ userInfoVO.setAllFreezAmtHk(positionVO.getAllFreezAmtHk());
BigDecimal allProfitAndLose = positionVO.getAllProfitAndLose();
+ BigDecimal allProfitAndLosehk = positionVO.getAllProfitAndLoseHk();
userInfoVO.setAllProfitAndLose(allProfitAndLose);
+ userInfoVO.setAllProfitAndLoseHk(allProfitAndLosehk);
-// BigDecimal userAllAmt = user.getUserAmt();
BigDecimal userAllAmt = user.getEnableAmt();
userAllAmt = userAllAmt.add(allProfitAndLose);
@@ -1856,13 +1858,21 @@
BigDecimal historyProfitLoss = new BigDecimal(0);
BigDecimal buyAmtAutual = new BigDecimal(0);
+ BigDecimal historyProfitLossHk = new BigDecimal(0);
+ BigDecimal buyAmtAutualHk = new BigDecimal(0);
List<UserPosition> userPositionscc = this.userPositionMapper.findMyPositionByCodeAndSpell(user.getId(), "", "", 0);
if (userPositionscc.size() > 0) {
for (UserPosition position : userPositionscc) {
- buyAmtAutual = buyAmtAutual.add(position.getBuyOrderPrice()
- .multiply(new BigDecimal(position.getOrderNum()))
- .divide(new BigDecimal(position.getOrderLever()), 2, RoundingMode.HALF_UP));
+ if(StockType.HK.getCode().equals(position.getStockType())){
+ buyAmtAutualHk = buyAmtAutualHk.add(position.getBuyOrderPrice()
+ .multiply(new BigDecimal(position.getOrderNum()))
+ .divide(new BigDecimal(position.getOrderLever()), 2, RoundingMode.HALF_UP));
+ }else {
+ buyAmtAutual = buyAmtAutual.add(position.getBuyOrderPrice()
+ .multiply(new BigDecimal(position.getOrderNum()))
+ .divide(new BigDecimal(position.getOrderLever()), 2, RoundingMode.HALF_UP));
+ }
}
}
userInfoVO.setBuyAmtAutual(buyAmtAutual);
@@ -1873,11 +1883,18 @@
if (userPositions.size() > 0) {
for (UserPosition position : userPositions) {
- UserPositionVO userPositionVO = assembleUserPositionVO(position);
- historyProfitLoss = historyProfitLoss.add(userPositionVO.getAllProfitAndLose());
+ if(StockType.HK.getCode().equals(position.getStockType())){
+ UserPositionVO userPositionVO = assembleUserPositionVO(position);
+ historyProfitLossHk = historyProfitLossHk.add(userPositionVO.getAllProfitAndLose());
+ }else {
+ UserPositionVO userPositionVO = assembleUserPositionVO(position);
+ historyProfitLoss = historyProfitLoss.add(userPositionVO.getAllProfitAndLose());
+ }
+
}
}
userInfoVO.setHistoryProfitLoss(historyProfitLoss);
+ userInfoVO.setHistoryProfitLossHk(historyProfitLossHk);
userInfoVO.setDjzj(user.getDjzj());
return userInfoVO;
}
diff --git a/src/main/java/com/nq/vo/position/PositionVO.java b/src/main/java/com/nq/vo/position/PositionVO.java
index ea03680..e532eea 100644
--- a/src/main/java/com/nq/vo/position/PositionVO.java
+++ b/src/main/java/com/nq/vo/position/PositionVO.java
@@ -5,7 +5,9 @@
public class PositionVO {
private BigDecimal allProfitAndLose;
+ private BigDecimal allProfitAndLoseHk;
private BigDecimal allFreezAmt;
+ private BigDecimal allFreezAmtHk;
public void setAllProfitAndLose(BigDecimal allProfitAndLose) {
this.allProfitAndLose = allProfitAndLose;
@@ -31,6 +33,14 @@
return other instanceof PositionVO;
}
+ public BigDecimal getAllProfitAndLoseHk() {
+ return allProfitAndLoseHk;
+ }
+
+ public void setAllProfitAndLoseHk(BigDecimal allProfitAndLoseHk) {
+ this.allProfitAndLoseHk = allProfitAndLoseHk;
+ }
+
public int hashCode() {
int PRIME = 59;
int result = 1;
@@ -53,4 +63,12 @@
public BigDecimal getAllFreezAmt() {
return this.allFreezAmt;
}
+
+ public BigDecimal getAllFreezAmtHk() {
+ return allFreezAmtHk;
+ }
+
+ public void setAllFreezAmtHk(BigDecimal allFreezAmtHk) {
+ this.allFreezAmtHk = allFreezAmtHk;
+ }
}
diff --git a/src/main/java/com/nq/vo/user/UserInfoVO.java b/src/main/java/com/nq/vo/user/UserInfoVO.java
index cfbc60e..2128d2e 100644
--- a/src/main/java/com/nq/vo/user/UserInfoVO.java
+++ b/src/main/java/com/nq/vo/user/UserInfoVO.java
@@ -40,14 +40,18 @@
private String authMsg;
private BigDecimal userAmt;
private BigDecimal enableAmt;
+ private BigDecimal enableAmtHk;
private BigDecimal enaleWithdrawAmt;
+ private BigDecimal enaleWithdrawAmtHk;
private BigDecimal hkAmt;
private BigDecimal userIndexAmt;
private BigDecimal enableIndexAmt;
private BigDecimal userFuturesAmt;
private BigDecimal enableFuturesAmt;
private BigDecimal allProfitAndLose;
+ private BigDecimal allProfitAndLoseHk;
private BigDecimal allFreezAmt;
+ private BigDecimal allFreezAmtHk;
private BigDecimal allIndexProfitAndLose;
private BigDecimal allIndexFreezAmt;
private BigDecimal allFuturesProfitAndLose;
@@ -76,6 +80,7 @@
private BigDecimal djzj;
private BigDecimal historyProfitLoss;
+ private BigDecimal historyProfitLossHk;
public void setAgentId(Integer agentId) {
this.agentId = agentId;
diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties
index b5479fb..6dc6e30 100644
--- a/src/main/resources/application.properties
+++ b/src/main/resources/application.properties
@@ -10,6 +10,7 @@
ftp.pass=ftp_red
ftp.server.http.prefix=https://ftp.htzjgj.com/
loca.images.dir=/www/wwwroot/ftp.htzjgj.com/
+
#ftp.server.ip=47.56.200.145
#ftp.user=ofsuccess
#ftp.pass=fdymdM34HHsS8iB6
@@ -78,6 +79,9 @@
sina.market.url=https://hq.sinajs.cn/rn=1520407404627&list=s_sh000001,s_sz399001,s_sz399006,s_sz399300,s_sz399005,s_sz399673,s_sz399106,s_sz399004,s_sz399100
sina.single.market.url=https://hq.sinajs.cn/rn=1520407404627&list=s_
sina.single.market.hkurl=https://hq.sinajs.cn/rn=1520407404627&list=rt_
+
+sina.data.proxy.list.url=http://171.80.4.102:7001/crypto/getSinaStock?stockGid=
+#sina.data.proxy.list.url=http://localhost:7001/crypto/getSinaStock?stockGid=
sina.index.market.url=https://ws.api.cnyes.com/ws/api/v4/universal/quote?type=LITQ&column=L
@@ -160,7 +164,6 @@
sina.TwMarket.list.url=http://b.workingman.icu/stock/api/stock/getStockType?exchange=TAI
sina.StockType.list.url=http://b.workingman.icu/stock/api/stock/getStockType?exchange=
sina.StockCategory.list.url=http://b.workingman.icu/stock/api/stock/getWapStocks
-sina.data.proxy.list.url=http://localhost:7001/crypto/getSinaStock?stockGid=
http.proxyHost =
http.proxyPort =
diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml
index 79ceb3f..c421fc5 100644
--- a/src/main/resources/application.yml
+++ b/src/main/resources/application.yml
@@ -2,7 +2,7 @@
# 开发环境配置
server:
# 服务器的HTTP端口,默认为8090
- port: 8092
+ port: 8091
tomcat:
# tomcat的URI编码
uri-encoding: UTF-8
@@ -104,12 +104,12 @@
datasource:
type: com.alibaba.druid.pool.DruidDataSource
driverClassName: com.mysql.cj.jdbc.Driver
+ url: jdbc:mysql://127.0.0.1:3306/stock_hongta?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
+ username: stock_hongta
+ password: P7d8b6Xhs6Xfkkxf
# url: jdbc:mysql://127.0.0.1:3306/stock_hongta_1226?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
# username: root
-# password: PsRwRm5nGbtS22Xp
- url: jdbc:mysql://127.0.0.1:3306/stock_hongta_1226?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
- username: root
- password: 123456
+# password: 123456
druid:
# 初始连接数
initialSize: 5
--
Gitblit v1.9.3