1.微信公众号添加认证状态

master
星期八 6 years ago
parent 73313a28ae
commit 9ace146084
  1. 23
      src/main/java/com/lq/cms/emun/WechatInfoCertificationTypeEnum.java
  2. 12
      src/main/java/com/lq/entity/WechatInfo.java
  3. 12
      src/main/java/com/lq/wechat/util/CheckUtil.java

@ -0,0 +1,23 @@
package com.lq.cms.emun;
/**
* @Author: qi
* @Description:
* @Date: Create in 6:09 AM 2019/4/28
*/
public enum WechatInfoCertificationTypeEnum {
CERTIFICATION_YES(1,"认证"),
CERTIFICATION_NO(0,"未认证")
;
WechatInfoCertificationTypeEnum(Integer value, String desc) {
this.value = value;
this.desc = desc;
}
private Integer value;
private String desc;
}

@ -35,7 +35,8 @@ public class WechatInfo extends IdEntity {
*/
private String token;
/**
* 消息加密类型 @Link WechatInfoEncodingTypeEnum
* 消息加密类型
* @Link WechatInfoEncodingTypeEnum
*/
private String encodingType;
/**
@ -59,9 +60,16 @@ public class WechatInfo extends IdEntity {
*/
private Long updateUserId;
/**
* 微信公众号类型:@Link WechatInfoTypeEnum
* 微信公众号类型
* @Link WechatInfoTypeEnum
*/
private Integer wechatInfoType;
/**
* 认证状态
* 微信公众号在未认证状态下有需求功能接口受限
* @Link WechatInfoCertificationTypeEnum
*/
private Integer certification;
public String getWechatOpenId() {
return wechatOpenId;

@ -8,14 +8,22 @@ import java.util.Arrays;
public class CheckUtil {
private static final String TOKEN="qiLiang";
/**
*  已废弃
* @param signature
* @param timestamp
* @param nonce
* @return
*/
@Deprecated
public static boolean checkSingatue(String signature,String timestamp,String nonce){
return checkSingatue(signature,timestamp,nonce,TOKEN);
}
public static boolean checkSingatue(String signature,String timestamp,String nonce,String token){
public static boolean checkSingatue(String signature,String timestamp,String nonce,String token){
String []arr=new String[]{token,timestamp,nonce};

Loading…
Cancel
Save