mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-24 16:05:08 +08:00
【代码评审】SYSTEM:完善微信小程序码
This commit is contained in:
@ -233,9 +233,15 @@ public class SocialClientServiceImpl implements SocialClientService {
|
||||
public byte[] getWxaQrcode(SocialWxQrcodeReqDTO reqVO) {
|
||||
WxMaService service = getWxMaService(UserTypeEnum.MEMBER.getValue());
|
||||
try {
|
||||
return service.getQrcodeService().createWxaCodeUnlimitBytes(reqVO.getScene(), reqVO.getPath(),
|
||||
reqVO.getCheckPath(), reqVO.getEnvVersion(), reqVO.getWidth(), reqVO.getAutoColor(),
|
||||
null, reqVO.getHyaline());
|
||||
return service.getQrcodeService().createWxaCodeUnlimitBytes(
|
||||
ObjUtil.defaultIfEmpty(reqVO.getScene(), SocialWxQrcodeReqDTO.SCENE),
|
||||
reqVO.getPath(),
|
||||
ObjUtil.defaultIfNull(reqVO.getCheckPath(), SocialWxQrcodeReqDTO.CHECK_PATH),
|
||||
ObjUtil.defaultIfBlank(reqVO.getEnvVersion(), SocialWxQrcodeReqDTO.ENV_VERSION),
|
||||
ObjUtil.defaultIfNull(reqVO.getWidth(), SocialWxQrcodeReqDTO.WIDTH),
|
||||
ObjUtil.defaultIfNull(reqVO.getAutoColor(), SocialWxQrcodeReqDTO.AUTO_COLOR),
|
||||
null,
|
||||
ObjUtil.defaultIfNull(reqVO.getHyaline(), SocialWxQrcodeReqDTO.HYALINE));
|
||||
} catch (WxErrorException e) {
|
||||
log.error("[getWxQrcode][reqVO({})) 获得小程序码失败]", reqVO, e);
|
||||
throw exception(SOCIAL_CLIENT_WEIXIN_MINI_APP_QRCODE_ERROR);
|
||||
|
Reference in New Issue
Block a user