2
0

fix: 修复问题

This commit is contained in:
caiyuchao
2025-02-08 18:09:23 +08:00
parent faa8e0ad5e
commit 2ae7616fde
3 changed files with 8 additions and 7 deletions

View File

@@ -162,7 +162,7 @@ public class AliPayController extends AbstractAliPayApiController {
// String notifyUrl = aliPayBean.getDomain() + NOTIFY_URL;
String notifyUrl = aliPayBean.getDomain() + PRE_NOTIFY_URL + NOTIFY_URL;
if (StrUtil.isNotBlank(aliPayBean.getTestDomain())) {
notifyUrl = aliPayBean.getTestDomain() + TEST_PRE_NOTIFY_URL + NOTIFY_URL;
notifyUrl = aliPayBean.getTestDomain() + PRE_NOTIFY_URL + NOTIFY_URL;
}
@@ -203,7 +203,7 @@ public class AliPayController extends AbstractAliPayApiController {
String returnUrl = aliPayBean.getDomain() + RETURN_URL;
String notifyUrl = aliPayBean.getDomain() + PRE_NOTIFY_URL + NOTIFY_URL;
if (StrUtil.isNotBlank(aliPayBean.getTestDomain())) {
notifyUrl = aliPayBean.getTestDomain() + TEST_PRE_NOTIFY_URL + NOTIFY_URL;
notifyUrl = aliPayBean.getTestDomain() + PRE_NOTIFY_URL + NOTIFY_URL;
}
AlipayTradePagePayModel model = new AlipayTradePagePayModel();

View File

@@ -6,6 +6,7 @@ import cn.hutool.core.util.ObjectUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.wfc.common.core.constant.WifiConstants;
import org.wfc.omada.api.client.OmadaClientApi;
import org.wfc.omada.api.client.model.ClientRateLimitSetting;
import org.wfc.omada.api.client.model.CustomRateLimitEntity;
@@ -46,7 +47,7 @@ public class OmadaWifiApi extends AbstractOmadaWifiApi {
public boolean authClient(String siteId, String clientMac) {
ResponseEntity<org.wfc.omada.api.hotspot.model.OperationResponseWithoutResult> response = omadaAuthorizedClientApi.authClient(siteId, clientMac);
if (ObjectUtil.isNotNull(response.getBody())) {
if (response.getBody().getErrorCode() == 0) {
if (response.getBody().getErrorCode() == WifiConstants.ERROR_CODE_SUCCESS) {
log.info("authClient success,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
} else {
log.error("authClient error,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
@@ -59,7 +60,7 @@ public class OmadaWifiApi extends AbstractOmadaWifiApi {
public boolean cancelAuthClient(String siteId, String clientMac) {
ResponseEntity<org.wfc.omada.api.hotspot.model.OperationResponseWithoutResult> response = omadaAuthorizedClientApi.cancelAuthClient(siteId, clientMac);
if (ObjectUtil.isNotNull(response.getBody())) {
if (response.getBody().getErrorCode() == 0) {
if (response.getBody().getErrorCode() == WifiConstants.ERROR_CODE_SUCCESS) {
log.info("cancelAuthClient success,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
} else {
log.error("cancelAuthClient error,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
@@ -72,7 +73,7 @@ public class OmadaWifiApi extends AbstractOmadaWifiApi {
public boolean reconnectClient(String siteId, String clientMac) {
ResponseEntity<OperationResponseWithoutResult> response = omadaClientApi.reconnectClient(siteId, clientMac);
if (ObjectUtil.isNotNull(response.getBody())) {
if (response.getBody().getErrorCode() == 0) {
if (response.getBody().getErrorCode() == WifiConstants.ERROR_CODE_SUCCESS) {
log.info("reconnectClient success,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
} else {
log.error("reconnectClient error,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
@@ -159,7 +160,7 @@ public class OmadaWifiApi extends AbstractOmadaWifiApi {
}
ResponseEntity<OperationResponseWithoutResult> response = omadaClientApi.updateClientRateLimitSetting(siteId, clientMac, clientRateLimitSetting);
if (ObjectUtil.isNotNull(response.getBody())) {
if (response.getBody().getErrorCode() == 0) {
if (response.getBody().getErrorCode() == WifiConstants.ERROR_CODE_SUCCESS) {
log.info("updateClientRateLimitSetting success,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());
} else {
log.error("updateClientRateLimitSetting error,siteId={},clientMac={},errorCode={}, msg={}", siteId, clientMac, response.getBody().getErrorCode(), response.getBody().getMsg());

View File

@@ -51,7 +51,7 @@ public class UEmailController extends BaseController {
try {
MailUtils.sendText(email, "Your WANFI verification code", "Hi\nYour verification code is:\n" + code + "\nThis code will expire in " + Constants.MAIL_CAPTCHA_EXPIRATION + " minutes.\nFor your security, don't share it with anyone.");
} catch (Exception e) {
log.error("验证码短信发送异常 => {}", e.getMessage());
log.error("email verification code send failed => {}", e.getMessage());
return R.fail(e.getMessage());
}
return R.ok();