获取openId 失败

This commit is contained in:
2025-03-26 10:46:02 +08:00
parent 8e03d269fb
commit eef5e3c768

View File

@@ -56,6 +56,9 @@ public class UserAuthorizationController {
@GetMapping("/openId")
public CzgResult<Map<String, String>> getOpenId(@RequestParam String code, @RequestParam String source, @RequestParam Long shopId) {
String openId = userAuthorizationService.getOpenId(code, source);
if (openId == null){
return CzgResult.failure("获取openId失败");
}
ShopInfo shopInfo = shopInfoService.getById(shopId);
if (shopInfo == null){
return CzgResult.failure("店铺信息不存在");