@RestController(value="admin-user-thirdpart-wxpub") @RequestMapping(value="/admin/user/wxpub") public class UserThirdpartWxPubController extends BaseController
request, response| 构造器和说明 |
|---|
UserThirdpartWxPubController() |
| 限定符和类型 | 方法和说明 |
|---|---|
ApiResult<String> |
getWxgzhCode()
获取微信公众号带参二维码票据并进行URL编码后返回
|
void |
getWxgzhManage(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
处理微信公众号服务器推送的消息(GET用于验证签名,POST用于处理扫码等事件)
|
ApiResult<String> |
sendWxPub(Map<String,Object> paramMap)
发送微信模板消息给指定用户
|
ApiResult<String> |
wxPublicUnbind()
解除当前登录用户的微信公众号绑定关系
|
error, error, fail, fail, fail, getLoginID, getLoginName, getLoginOrgID, getLoginOrgName, getLoginUser, getNickname, getTenantId, getUserName, getUserNo, i18n, i18n, isAdministrator, isDeveloper, limit, offset, ok, ok, response, success, success, success, success, validateToken@PostMapping(value="/getWxgzhCode") @Permission(value="") public ApiResult<String> getWxgzhCode() throws TokenAuthenticationException, UnsupportedEncodingException, SQLException, BusiException
TokenAuthenticationException - 认证失败异常UnsupportedEncodingException - 不支持的字符集编码异常SQLException - 数据库访问异常BusiException - 业务逻辑异常@RequestMapping(value="/wx/callback",
method={GET,POST})
public void getWxgzhManage(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
request - HTTP请求对象response - HTTP响应对象Exception - 各种可能发生的异常@PostMapping(value="/sendWxPub") @Permission(value="") @Transactional(rollbackFor=java.lang.Exception.class) public ApiResult<String> sendWxPub(@RequestBody Map<String,Object> paramMap) throws Exception
paramMap - 包含发送信息的参数映射表,必须包含 to_user_id 和 message 字段Exception - 可能抛出的各种异常@PostMapping(value="/unbind") @Permission(value="") public ApiResult<String> wxPublicUnbind() throws TokenAuthenticationException
TokenAuthenticationException - token认证失败时抛出此异常Copyright © 2026. All rights reserved.