saas:支持社交应用的多租户配置(mp)
parent
d256275099
commit
6f757e5297
@ -0,0 +1,31 @@
|
|||||||
|
package cn.iocoder.yudao.module.member.controller.app.auth.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
@Schema(description = "用户 APP - 微信公众号 JSAPI 签名 Response VO")
|
||||||
|
@Data
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
@Builder
|
||||||
|
public class AuthWeixinJsapiSignatureRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "微信公众号的 appId", requiredMode = Schema.RequiredMode.REQUIRED, example = "hello")
|
||||||
|
private String appId;
|
||||||
|
|
||||||
|
@Schema(description = "匿名串", requiredMode = Schema.RequiredMode.REQUIRED, example = "world")
|
||||||
|
private String nonceStr;
|
||||||
|
|
||||||
|
@Schema(description = "时间戳", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024")
|
||||||
|
private Long timestamp;
|
||||||
|
|
||||||
|
@Schema(description = "URL", requiredMode = Schema.RequiredMode.REQUIRED, example = "https://www.iocoder.cn")
|
||||||
|
private String url;
|
||||||
|
|
||||||
|
@Schema(description = "签名", requiredMode = Schema.RequiredMode.REQUIRED, example = "阿巴阿巴")
|
||||||
|
private String signature;
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,34 @@
|
|||||||
|
package cn.iocoder.yudao.module.system.api.social.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 微信公众号 JSAPI 签名 Response DTO
|
||||||
|
*
|
||||||
|
* @author 芋道源码
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class SocialWxJsapiSignatureRespDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 微信公众号的 appId
|
||||||
|
*/
|
||||||
|
private String appId;
|
||||||
|
/**
|
||||||
|
* 匿名串
|
||||||
|
*/
|
||||||
|
private String nonceStr;
|
||||||
|
/**
|
||||||
|
* 时间戳
|
||||||
|
*/
|
||||||
|
private Long timestamp;
|
||||||
|
/**
|
||||||
|
* URL
|
||||||
|
*/
|
||||||
|
private String url;
|
||||||
|
/**
|
||||||
|
* 签名
|
||||||
|
*/
|
||||||
|
private String signature;
|
||||||
|
|
||||||
|
}
|
||||||
@ -1,4 +0,0 @@
|
|||||||
### 请求 /login 接口 => 成功
|
|
||||||
POST {{appApi}}/system/wx-mp/create-jsapi-signature?url=http://www.iocoder.cn
|
|
||||||
Authorization: Bearer {{appToken}}
|
|
||||||
tenant-id: {{appTenentId}}
|
|
||||||
@ -0,0 +1,15 @@
|
|||||||
|
package cn.iocoder.yudao.module.system.convert.social;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.system.api.social.dto.SocialWxJsapiSignatureRespDTO;
|
||||||
|
import me.chanjar.weixin.common.bean.WxJsapiSignature;
|
||||||
|
import org.mapstruct.Mapper;
|
||||||
|
import org.mapstruct.factory.Mappers;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface SocialClientConvert {
|
||||||
|
|
||||||
|
SocialClientConvert INSTANCE = Mappers.getMapper(SocialClientConvert.class);
|
||||||
|
|
||||||
|
SocialWxJsapiSignatureRespDTO convert(WxJsapiSignature bean);
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue