记得上下班打卡 | git大法好,push需谨慎

Commit dfe272cc authored by jiangxiulong's avatar jiangxiulong

sweet 增加type6 小家伙小程序

parent 620432d0
...@@ -46,7 +46,7 @@ public class SweetAppletUsersVo implements Serializable, Cloneable { ...@@ -46,7 +46,7 @@ public class SweetAppletUsersVo implements Serializable, Cloneable {
private String countryCode; private String countryCode;
/** /**
* 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 * 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙
*/ */
private Integer type; private Integer type;
......
...@@ -192,6 +192,9 @@ liquidnet: ...@@ -192,6 +192,9 @@ liquidnet:
airship: airship:
appid: wxefc896f987d72d32 appid: wxefc896f987d72d32
secret: 24c80a734c1fdb316a31a5be1f3606d5 secret: 24c80a734c1fdb316a31a5be1f3606d5
smile:
appid: wx4956704fe769112c
secret: 645919ab4a4c48eb8e73aea38752adfa
umeng: umeng:
ios: ios:
appkey: 54fe819bfd98c546b50004f0 appkey: 54fe819bfd98c546b50004f0
......
...@@ -184,6 +184,9 @@ liquidnet: ...@@ -184,6 +184,9 @@ liquidnet:
airship: airship:
appid: wxefc896f987d72d32 appid: wxefc896f987d72d32
secret: 24c80a734c1fdb316a31a5be1f3606d5 secret: 24c80a734c1fdb316a31a5be1f3606d5
smile:
appid: wx4956704fe769112c
secret: 645919ab4a4c48eb8e73aea38752adfa
umeng: umeng:
ios: ios:
appkey: 54fe819bfd98c546b50004f0 appkey: 54fe819bfd98c546b50004f0
......
...@@ -46,7 +46,7 @@ public class SweetAppletSubMsg implements Serializable, Cloneable { ...@@ -46,7 +46,7 @@ public class SweetAppletSubMsg implements Serializable, Cloneable {
private String targetId; private String targetId;
/** /**
* 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 * 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙
*/ */
private Integer appletType; private Integer appletType;
......
...@@ -60,7 +60,7 @@ public class SweetAppletUsers implements Serializable { ...@@ -60,7 +60,7 @@ public class SweetAppletUsers implements Serializable {
private String countryCode; private String countryCode;
/** /**
* 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 * 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙
*/ */
private Integer type; private Integer type;
......
...@@ -7,7 +7,7 @@ CREATE TABLE `sweet_applet_sub_msg` ...@@ -7,7 +7,7 @@ CREATE TABLE `sweet_applet_sub_msg`
`open_id` varchar(255) NOT NULL DEFAULT '' COMMENT 'open_id', `open_id` varchar(255) NOT NULL DEFAULT '' COMMENT 'open_id',
`template_id` varchar(255) NOT NULL DEFAULT '' COMMENT 'template_id', `template_id` varchar(255) NOT NULL DEFAULT '' COMMENT 'template_id',
`target_id` varchar(255) NOT NULL DEFAULT '' COMMENT '目标id 显示是演出id', `target_id` varchar(255) NOT NULL DEFAULT '' COMMENT '目标id 显示是演出id',
`applet_type` tinyint NOT NULL DEFAULT 0 COMMENT '1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节', `applet_type` tinyint NOT NULL DEFAULT 0 COMMENT ' 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙',
`activity_type` tinyint NOT NULL DEFAULT 0 COMMENT '活动类型', `activity_type` tinyint NOT NULL DEFAULT 0 COMMENT '活动类型',
`is_push` tinyint NOT NULL DEFAULT 1 COMMENT '是否推送 1未推送 2已推送', `is_push` tinyint NOT NULL DEFAULT 1 COMMENT '是否推送 1未推送 2已推送',
`created_at` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', `created_at` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
......
...@@ -455,7 +455,7 @@ CREATE TABLE `sweet_applet_users` ...@@ -455,7 +455,7 @@ CREATE TABLE `sweet_applet_users`
`phone_number` varchar(200) NOT NULL DEFAULT '' COMMENT '手机号', `phone_number` varchar(200) NOT NULL DEFAULT '' COMMENT '手机号',
`pure_phone_number` varchar(200) NOT NULL DEFAULT '' COMMENT '手机号', `pure_phone_number` varchar(200) NOT NULL DEFAULT '' COMMENT '手机号',
`country_code` varchar(200) NOT NULL DEFAULT '' COMMENT '地区码', `country_code` varchar(200) NOT NULL DEFAULT '' COMMENT '地区码',
`type` tinyint NOT NULL DEFAULT 0 COMMENT '1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节', `type` tinyint NOT NULL DEFAULT 0 COMMENT ' 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙',
`created_at` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', `created_at` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`updated_at` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '更新时间', `updated_at` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '更新时间',
PRIMARY KEY (`mid`), PRIMARY KEY (`mid`),
......
...@@ -35,6 +35,9 @@ public class WechatMaConfigure { ...@@ -35,6 +35,9 @@ public class WechatMaConfigure {
private static String appletAppidAirship; private static String appletAppidAirship;
private static String appletSecretAirship; private static String appletSecretAirship;
private static String appletAppidSmile;
private static String appletSecretSmile;
@Value("${liquidnet.wechat.applet.strawberry.appid}") @Value("${liquidnet.wechat.applet.strawberry.appid}")
public void setAppletAppidStrawberry(String appletAppidStrawberry) { public void setAppletAppidStrawberry(String appletAppidStrawberry) {
WechatMaConfigure.appletAppidStrawberry = appletAppidStrawberry; WechatMaConfigure.appletAppidStrawberry = appletAppidStrawberry;
...@@ -80,17 +83,28 @@ public class WechatMaConfigure { ...@@ -80,17 +83,28 @@ public class WechatMaConfigure {
WechatMaConfigure.appletSecretAirship = appletSecretAirship; WechatMaConfigure.appletSecretAirship = appletSecretAirship;
} }
@Value("${liquidnet.wechat.applet.smile.appid}")
public void setAppletAppidSmile(String appletAppidSmile) {
WechatMaConfigure.appletAppidSmile = appletAppidSmile;
}
@Value("${liquidnet.wechat.applet.smile.secret}")
public void setAppletSecretSmile(String appletSecretSmile) {
WechatMaConfigure.appletSecretSmile = appletSecretSmile;
}
private WxMaService wxMaAppletStrawberryService; private WxMaService wxMaAppletStrawberryService;
private WxMaService wxMaAppletFiveService; private WxMaService wxMaAppletFiveService;
private WxMaService wxMaAppletMdskService; private WxMaService wxMaAppletMdskService;
private WxMaService wxMaAppletZhengzaiService; private WxMaService wxMaAppletZhengzaiService;
private WxMaService wxMaAppletAirshipService; private WxMaService wxMaAppletAirshipService;
private WxMaService wxMaAppletSmileService;
private WxMaMessageRouter wxMaStrawberryMessageRouter; private WxMaMessageRouter wxMaStrawberryMessageRouter;
private WxMaMessageRouter wxMaFiveMessageRouter; private WxMaMessageRouter wxMaFiveMessageRouter;
private WxMaMessageRouter wxMaMdskMessageRouter; private WxMaMessageRouter wxMaMdskMessageRouter;
private WxMaMessageRouter wxMaZhengzaiMessageRouter; private WxMaMessageRouter wxMaZhengzaiMessageRouter;
private WxMaMessageRouter wxMaAirshipMessageRouter; private WxMaMessageRouter wxMaAirshipMessageRouter;
private WxMaMessageRouter wxMaSmileMessageRouter;
@Autowired @Autowired
private StringRedisTemplate stringRedisTemplate; private StringRedisTemplate stringRedisTemplate;
...@@ -158,11 +172,23 @@ public class WechatMaConfigure { ...@@ -158,11 +172,23 @@ public class WechatMaConfigure {
this.setWxMaConfig(wxMaDefaultConfig); this.setWxMaConfig(wxMaDefaultConfig);
} }
}; };
wxMaAppletSmileService = new WxMaServiceImpl() {
{
RedisTemplateWxRedisOps redisTemplateWxRedisOps = new RedisTemplateWxRedisOps(stringRedisTemplate);
WxMaRedisBetterConfigImpl wxMaDefaultConfig = new WxMaRedisBetterConfigImpl(redisTemplateWxRedisOps, "sweet:accessToken:applet:smile");
wxMaDefaultConfig.setAppid(appletAppidSmile);
wxMaDefaultConfig.setSecret(appletSecretSmile);
wxMaDefaultConfig.setMsgDataFormat("JSON");
this.setWxMaConfig(wxMaDefaultConfig);
}
};
wxMaStrawberryMessageRouter = new WxMaMessageRouter(wxMaAppletStrawberryService); wxMaStrawberryMessageRouter = new WxMaMessageRouter(wxMaAppletStrawberryService);
wxMaFiveMessageRouter = new WxMaMessageRouter(wxMaAppletFiveService); wxMaFiveMessageRouter = new WxMaMessageRouter(wxMaAppletFiveService);
wxMaMdskMessageRouter = new WxMaMessageRouter(wxMaAppletMdskService); wxMaMdskMessageRouter = new WxMaMessageRouter(wxMaAppletMdskService);
wxMaZhengzaiMessageRouter = new WxMaMessageRouter(wxMaAppletZhengzaiService); wxMaZhengzaiMessageRouter = new WxMaMessageRouter(wxMaAppletZhengzaiService);
wxMaAirshipMessageRouter = new WxMaMessageRouter(wxMaAppletAirshipService); wxMaAirshipMessageRouter = new WxMaMessageRouter(wxMaAppletAirshipService);
wxMaSmileMessageRouter = new WxMaMessageRouter(wxMaAppletSmileService);
} }
public WxMaService getWxMaService(Integer anum) { public WxMaService getWxMaService(Integer anum) {
...@@ -177,6 +203,8 @@ public class WechatMaConfigure { ...@@ -177,6 +203,8 @@ public class WechatMaConfigure {
return wxMaAppletZhengzaiService; return wxMaAppletZhengzaiService;
case 5: case 5:
return wxMaAppletAirshipService; return wxMaAppletAirshipService;
case 6:
return wxMaAppletSmileService;
} }
return null; return null;
} }
...@@ -193,6 +221,8 @@ public class WechatMaConfigure { ...@@ -193,6 +221,8 @@ public class WechatMaConfigure {
return appletAppidZhengzai; return appletAppidZhengzai;
case 5: case 5:
return appletAppidAirship; return appletAppidAirship;
case 6:
return appletAppidSmile;
} }
return ""; return "";
} }
...@@ -209,6 +239,8 @@ public class WechatMaConfigure { ...@@ -209,6 +239,8 @@ public class WechatMaConfigure {
return wxMaZhengzaiMessageRouter; return wxMaZhengzaiMessageRouter;
case 5: case 5:
return wxMaAirshipMessageRouter; return wxMaAirshipMessageRouter;
case 6:
return wxMaSmileMessageRouter;
} }
return null; return null;
} }
......
...@@ -82,7 +82,7 @@ public class SweetAppletSubMsgController { ...@@ -82,7 +82,7 @@ public class SweetAppletSubMsgController {
@ApiImplicitParam(type = "form", dataType = "String", name = "unionId", value = "对应小程序的unionId"), @ApiImplicitParam(type = "form", dataType = "String", name = "unionId", value = "对应小程序的unionId"),
@ApiImplicitParam(type = "form", dataType = "String", name = "templateId", value = "模版消息ID,多个用英文逗号分割", required = true), @ApiImplicitParam(type = "form", dataType = "String", name = "templateId", value = "模版消息ID,多个用英文逗号分割", required = true),
@ApiImplicitParam(type = "form", dataType = "String", name = "targetId", value = "演出id", required = true), @ApiImplicitParam(type = "form", dataType = "String", name = "targetId", value = "演出id", required = true),
@ApiImplicitParam(type = "form", dataType = "Integer", name = "appletType", value = "小程序类型 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节", required = true), @ApiImplicitParam(type = "form", dataType = "Integer", name = "appletType", value = "小程序类型 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙", required = true),
@ApiImplicitParam(type = "form", dataType = "Integer", name = "activityType", value = "活动类型", required = true), @ApiImplicitParam(type = "form", dataType = "Integer", name = "activityType", value = "活动类型", required = true),
}) })
public ResponseDto<Boolean> create( public ResponseDto<Boolean> create(
......
...@@ -28,7 +28,7 @@ public class SweetWechatLoginController { ...@@ -28,7 +28,7 @@ public class SweetWechatLoginController {
@ApiImplicitParam(type = "query", dataType = "String", name = "code", value = "微信code", required = true), @ApiImplicitParam(type = "query", dataType = "String", name = "code", value = "微信code", required = true),
@ApiImplicitParam(type = "query", dataType = "String", name = "encryptedData", value = "encryptedData", required = true), @ApiImplicitParam(type = "query", dataType = "String", name = "encryptedData", value = "encryptedData", required = true),
@ApiImplicitParam(type = "query", dataType = "String", name = "iv", value = "iv", required = true), @ApiImplicitParam(type = "query", dataType = "String", name = "iv", value = "iv", required = true),
@ApiImplicitParam(type = "query", dataType = "Integer", name = "type", value = "1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节"), @ApiImplicitParam(type = "query", dataType = "Integer", name = "type", value = "1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙"),
}) })
public ResponseDto userInfo( public ResponseDto userInfo(
@RequestParam() String code, @RequestParam() String code,
...@@ -43,7 +43,7 @@ public class SweetWechatLoginController { ...@@ -43,7 +43,7 @@ public class SweetWechatLoginController {
@GetMapping(value = {"maOpenId"}) @GetMapping(value = {"maOpenId"})
@ApiImplicitParams({ @ApiImplicitParams({
@ApiImplicitParam(type = "query", dataType = "String", name = "jsCode", value = "微信jsCode", required = true), @ApiImplicitParam(type = "query", dataType = "String", name = "jsCode", value = "微信jsCode", required = true),
@ApiImplicitParam(type = "query", dataType = "Integer", name = "type", value = "1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节", required = true) @ApiImplicitParam(type = "query", dataType = "Integer", name = "type", value = " 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙", required = true)
}) })
public ResponseDto<String> wxaCode2Session(@RequestParam String jsCode, @RequestParam Integer type) { public ResponseDto<String> wxaCode2Session(@RequestParam String jsCode, @RequestParam Integer type) {
return sweetLoginService.wxaCode2Session(jsCode, type); return sweetLoginService.wxaCode2Session(jsCode, type);
...@@ -53,7 +53,7 @@ public class SweetWechatLoginController { ...@@ -53,7 +53,7 @@ public class SweetWechatLoginController {
@GetMapping(value = {"userInfoMa"}) @GetMapping(value = {"userInfoMa"})
@ApiImplicitParams({ @ApiImplicitParams({
@ApiImplicitParam(type = "query", dataType = "String", name = "jsCode", value = "微信jsCode", required = true), @ApiImplicitParam(type = "query", dataType = "String", name = "jsCode", value = "微信jsCode", required = true),
@ApiImplicitParam(type = "query", dataType = "Integer", name = "type", value = "1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节", required = true) @ApiImplicitParam(type = "query", dataType = "Integer", name = "type", value = " 1草莓 2五百里 3mdsk 4正在 5跳飞船音乐节 6小家伙", required = true)
}) })
public ResponseDto<AdamLoginInfoVo> userInfoMa(@RequestParam String jsCode, @RequestParam Integer type) { public ResponseDto<AdamLoginInfoVo> userInfoMa(@RequestParam String jsCode, @RequestParam Integer type) {
return sweetLoginService.userInfoMa(jsCode, type); return sweetLoginService.userInfoMa(jsCode, type);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment