|
|
@@ -11,6 +11,7 @@ import com.ydtech.modules.admin.service.SysUserService;
|
|
|
import com.ydtech.modules.admin.service.WechatCustomerService;
|
|
|
import com.ydtech.modules.base.controller.BaseController;
|
|
|
import com.ydtech.modules.protocol.utils.AssertionUtils;
|
|
|
+import com.ydtech.utils.StringUtils;
|
|
|
import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
@@ -87,8 +88,11 @@ public class SysQyWeChatController {
|
|
|
sysQyWeChat = list.get(new Random().nextInt(list.size()));
|
|
|
}
|
|
|
String s = wechatCustomerService.addContactWay(sysQyWeChat.getOpenKfId());
|
|
|
- String url = s + "&scene_param=" + userId;
|
|
|
- return HttpResult.ok(url);
|
|
|
+ if(StringUtils.isNotEmpty(s)){
|
|
|
+ String url = s + "&scene_param=" + userId;
|
|
|
+ return HttpResult.ok(url);
|
|
|
+ }
|
|
|
+ return HttpResult.ok(sysQyWeChat.getSupportStaffUrl());
|
|
|
}
|
|
|
|
|
|
}
|