15 changed files with 554 additions and 7 deletions
@ -0,0 +1,58 @@ |
|||
package com.ccsens.signin.api; |
|||
|
|||
import cn.hutool.core.collection.CollectionUtil; |
|||
import cn.hutool.core.util.ObjectUtil; |
|||
import cn.hutool.core.util.StrUtil; |
|||
import cn.hutool.extra.servlet.ServletUtil; |
|||
import com.ccsens.signin.bean.dto.FiotDto; |
|||
import com.ccsens.signin.bean.dto.UserDto; |
|||
import com.ccsens.signin.bean.vo.FiotVo; |
|||
import com.ccsens.signin.bean.vo.UserVo; |
|||
import com.ccsens.signin.exception.UserLoginException; |
|||
import com.ccsens.util.JsonResponse; |
|||
import com.ccsens.util.WebConstant; |
|||
import com.ccsens.util.wx.WxXcxUtil; |
|||
import com.ccsens.wechatutil.bean.po.wxfiotexplorer.FiotSigninResponse; |
|||
import com.ccsens.wechatutil.wxfiotexplorer.FiotExplorerSigninUtil; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiImplicitParams; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import io.swagger.annotations.ApiParam; |
|||
import lombok.extern.slf4j.Slf4j; |
|||
import org.springframework.validation.annotation.Validated; |
|||
import org.springframework.web.bind.annotation.RequestBody; |
|||
import org.springframework.web.bind.annotation.RequestMapping; |
|||
import org.springframework.web.bind.annotation.RequestMethod; |
|||
import org.springframework.web.bind.annotation.RestController; |
|||
|
|||
import javax.servlet.http.HttpServletRequest; |
|||
import java.util.Map; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/30 10:42 |
|||
*/ |
|||
@Slf4j |
|||
@Api(tags = "物联网", description = "") |
|||
@RestController |
|||
@RequestMapping("/fiot") |
|||
public class FiotExplorerController { |
|||
|
|||
@ApiOperation(value = "物联网用户登录") |
|||
@ApiImplicitParams({ |
|||
}) |
|||
@RequestMapping(value = "/signin", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"}) |
|||
public JsonResponse<FiotVo.Signin> userSignin(@ApiParam @Validated @RequestBody(required = true)FiotDto.Signin signin) throws Exception { |
|||
log.info("物联网用户登录:{}", signin); |
|||
String type = "FIOT"; |
|||
WxXcxUtil.WechatUser wechatUser = WxXcxUtil.getUserInfo(signin.getCode(), "yanyuan"); |
|||
log.info("用户账号:{}", wechatUser); |
|||
FiotSigninResponse response = FiotExplorerSigninUtil.getToken(wechatUser.openid, signin.getNickName(), signin.getAvatar(), WxXcxUtil.appId(type)); |
|||
FiotVo.Signin vo = new FiotVo.Signin(); |
|||
vo.setToken(response.getToken()); |
|||
vo.setExpireAt(response.getExpireAt()); |
|||
log.info("物联网用户登录结果:{}", vo); |
|||
return JsonResponse.newInstance().ok(vo); |
|||
} |
|||
} |
@ -0,0 +1,31 @@ |
|||
package com.ccsens.signin.bean.dto; |
|||
|
|||
import io.swagger.annotations.ApiModel; |
|||
import io.swagger.annotations.ApiModelProperty; |
|||
import lombok.Data; |
|||
|
|||
import javax.validation.constraints.NotEmpty; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/30 10:45 |
|||
*/ |
|||
public class FiotDto { |
|||
|
|||
@Data |
|||
@ApiModel("登录-请求") |
|||
public static class Signin { |
|||
@NotEmpty |
|||
@ApiModelProperty("登录code") |
|||
private String code; |
|||
@NotEmpty |
|||
@ApiModelProperty("用户名") |
|||
private String nickName; |
|||
@NotEmpty |
|||
@ApiModelProperty("头像") |
|||
private String avatar; |
|||
} |
|||
|
|||
|
|||
} |
@ -0,0 +1,19 @@ |
|||
package com.ccsens.signin.bean.vo; |
|||
|
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/30 10:52 |
|||
*/ |
|||
public class FiotVo { |
|||
|
|||
@Data |
|||
@ApiModel("物联网登录-返回") |
|||
public static class Signin{ |
|||
private String token; |
|||
private long expireAt; |
|||
} |
|||
} |
@ -1,5 +1,5 @@ |
|||
spring: |
|||
profiles: |
|||
active: prod |
|||
include: util-prod,common |
|||
active: test |
|||
include: util-test,common |
|||
|
|||
|
@ -0,0 +1,85 @@ |
|||
package com.ccsens.wechatutil.bean.po.wxfiotexplorer; |
|||
|
|||
import cn.hutool.core.date.DatePattern; |
|||
import cn.hutool.core.date.DateUtil; |
|||
import cn.hutool.core.util.HexUtil; |
|||
import com.alibaba.fastjson.JSON; |
|||
import com.alibaba.fastjson.JSONObject; |
|||
import com.alibaba.fastjson.annotation.JSONField; |
|||
import com.ccsens.wechatutil.util.TC3Util; |
|||
import lombok.Data; |
|||
|
|||
import java.util.Calendar; |
|||
import java.util.Random; |
|||
import java.util.TimeZone; |
|||
import java.util.UUID; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/26 9:33 |
|||
*/ |
|||
@Data |
|||
public class FiotSignin { |
|||
/** |
|||
* 公共参数,本接口取值:AppGetTokenByWeiXin |
|||
*/ |
|||
@JSONField(name="Action") |
|||
private String Action = "AppGetTokenByWeiXin"; |
|||
/** |
|||
* 公共参数,唯一请求 ID,可自行生成,推荐使用 uuid。定位问题时,需提供该次请求的 RequestId |
|||
*/ |
|||
@JSONField(name="RequestId") |
|||
private String RequestId = UUID.randomUUID().toString(); |
|||
/** |
|||
* 公共参数,应用 AppKey ,用于标识对应的小程序或 App |
|||
*/ |
|||
@JSONField(name="AppKey") |
|||
private String AppKey = null; |
|||
/** |
|||
* 公共参数,请求签名,需用户自行生成,用于校验请求的合法性 |
|||
*/ |
|||
@JSONField(name="Signature") |
|||
private String Signature = null; |
|||
/** |
|||
* 公共参数,请求的 UINX 时间戳(秒级) |
|||
*/ |
|||
@JSONField(name="Timestamp") |
|||
private long Timestamp = System.currentTimeMillis() / 1000; |
|||
/** |
|||
* 公共参数,随机正整数,与 Timestamp 联合起来,防止重放攻击 |
|||
*/ |
|||
@JSONField(name="Nonce") |
|||
private int Nonce = new Random().nextInt(10000); |
|||
/** |
|||
* 微信用户的 OpenID 或 UnionID |
|||
*/ |
|||
@JSONField(name="WxOpenID") |
|||
private String WxOpenID; |
|||
/** |
|||
* 昵称 |
|||
*/ |
|||
@JSONField(name="NickName") |
|||
private String NickName; |
|||
/** |
|||
* 头像 |
|||
*/ |
|||
@JSONField(name="Avatar") |
|||
private String Avatar; |
|||
|
|||
public FiotSignin() { |
|||
} |
|||
|
|||
public FiotSignin(String openId, String nickName, String avatar, String appKey) throws Exception { |
|||
this(); |
|||
this.WxOpenID = openId; |
|||
this.NickName = nickName; |
|||
this.Avatar = avatar; |
|||
this.AppKey = appKey; |
|||
JSONObject json = JSONObject.parseObject(JSONObject.toJSONString(this)); |
|||
this.Signature = TC3Util.generateSignature(json); |
|||
|
|||
} |
|||
|
|||
|
|||
} |
@ -0,0 +1,20 @@ |
|||
package com.ccsens.wechatutil.bean.po.wxfiotexplorer; |
|||
|
|||
import com.alibaba.fastjson.annotation.JSONField; |
|||
import io.swagger.annotations.ApiModelProperty; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/30 10:25 |
|||
*/ |
|||
@Data |
|||
public class FiotSigninResponse { |
|||
@ApiModelProperty("截止时间,UINX 秒级时间戳") |
|||
@JSONField(name = "ExpireAt") |
|||
private Long ExpireAt; |
|||
@ApiModelProperty("开发平台返回的 AccessToken,通过该 Token 进行登录后的接口请求") |
|||
@JSONField(name = "Token") |
|||
private String Token; |
|||
} |
@ -0,0 +1,32 @@ |
|||
package com.ccsens.wechatutil.bean.po.wxfiotexplorer; |
|||
|
|||
import io.swagger.annotations.ApiModelProperty; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/30 10:17 |
|||
*/ |
|||
@Data |
|||
public class ResponseInfo<T> { |
|||
private int code; |
|||
private String msg; |
|||
private Info<T> data; |
|||
private String RequestId; |
|||
|
|||
|
|||
@Data |
|||
public static class Info<T>{ |
|||
@ApiModelProperty("数据,异常时,data为空") |
|||
private T Data; |
|||
@ApiModelProperty("错误码,正确返回时,error为空") |
|||
private ErrorInfo Error; |
|||
} |
|||
|
|||
@Data |
|||
public static class ErrorInfo{ |
|||
private String Code; |
|||
private String Message; |
|||
} |
|||
} |
@ -0,0 +1,180 @@ |
|||
package com.ccsens.wechatutil.util; |
|||
|
|||
import cn.hutool.core.codec.Base64Encoder; |
|||
import cn.hutool.core.util.StrUtil; |
|||
import com.alibaba.fastjson.JSONObject; |
|||
import com.ccsens.util.KCPlayerSignature; |
|||
|
|||
import javax.crypto.Mac; |
|||
import javax.crypto.spec.SecretKeySpec; |
|||
import javax.xml.bind.DatatypeConverter; |
|||
import java.nio.charset.Charset; |
|||
import java.nio.charset.StandardCharsets; |
|||
import java.security.MessageDigest; |
|||
import java.text.SimpleDateFormat; |
|||
import java.util.*; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/29 17:50 |
|||
*/ |
|||
public class TC3Util { |
|||
private final static Charset UTF8 = StandardCharsets.UTF_8; |
|||
private final static String SECRET_ID = "AKIDxhBRRAdplRpwnMfnfGaeRxDBsJTN0NTI"; |
|||
private final static String SECRET_KEY = "Zrte9MPFo68tMZU8WcXDeqnVx95rYzA6"; |
|||
private final static String APP_KEY = "mEulfDBBOFeOjGavy"; |
|||
private final static String APP_SECRET = "FaFKWiwVUWbJmfxVnSdd"; |
|||
private final static String CT_JSON = "application/json; charset=utf-8"; |
|||
//签名算法
|
|||
private static final String HMAC_ALGORITHM = "HmacSHA1"; |
|||
private static final String CONTENT_CHARSET = "UTF-8"; |
|||
|
|||
public static byte[] hmac256(byte[] key, String msg) throws Exception { |
|||
Mac mac = Mac.getInstance("HmacSHA256"); |
|||
SecretKeySpec secretKeySpec = new SecretKeySpec(key, mac.getAlgorithm()); |
|||
mac.init(secretKeySpec); |
|||
return mac.doFinal(msg.getBytes(UTF8)); |
|||
} |
|||
|
|||
public static String sha256Hex(String s) throws Exception { |
|||
MessageDigest md = MessageDigest.getInstance("SHA-256"); |
|||
byte[] d = md.digest(s.getBytes(UTF8)); |
|||
return DatatypeConverter.printHexBinary(d).toLowerCase(); |
|||
} |
|||
|
|||
public static Map<String, String> getHeaders(String service, long timestamp, String signature){ |
|||
Map<String, String> headMap = new HashMap<>(); |
|||
String algorithm = "TC3-HMAC-SHA256"; |
|||
String signedHeaders = "content-type;host"; |
|||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
|||
// 注意时区,否则容易出错
|
|||
sdf.setTimeZone(TimeZone.getTimeZone("UTC")); |
|||
String date = sdf.format(new Date(Long.valueOf(timestamp + "000"))); |
|||
String credentialScope = date + "/" + service + "/" + "tc3_request"; |
|||
String authorization = algorithm + " " + "Credential=" + SECRET_ID + "/" + credentialScope + ", " |
|||
+ "SignedHeaders=" + signedHeaders + ", " + "Signature=" + signature; |
|||
headMap.put("Authorization", authorization); |
|||
return headMap; |
|||
} |
|||
|
|||
public static void main(String[] args) throws Exception { |
|||
JSONObject json = new JSONObject(); |
|||
json.put("Action","AppGetTokenByWeiXin"); |
|||
json.put("RequestId","4c582f20-608a-41eb-8a04-b19cd341a328"); |
|||
json.put("AppKey","mEulfDBBOFeOjGavy"); |
|||
json.put("Timestamp","1638345578"); |
|||
json.put("Nonce","3493"); |
|||
json.put("WxOpenId","oOBSe5HAi885IlNeAAb3FQYxwExI"); |
|||
json.put("NickName","wu"); |
|||
json.put("Avatar","https://thirdwx.qlogo.cn/mmopen/vi_32/4KIkPtTLnuGdQPo1YqiaqRAgjyIPz4NyDzZVwwKJiatibWhszIH02XmWyqnl7LW1zYmRMbF2UYQG5o4N0cgyPH0qw/132"); |
|||
System.out.println(json); |
|||
String s = generateSignature(json); |
|||
System.out.println("s:" + s); |
|||
// String data = "Action=AppCreateCellphoneUser&AppKey=ahPxdK****TGrejd&CountryCode=86&Nonce=71087795&Password=My!P@ssword&PhoneNumber=13900000000&RequestId=8b8d499bbba1ac28b6da21b4&Timestamp=1546315200&VerificationCode=123456";
|
|||
// Mac mac = Mac.getInstance(HMAC_ALGORITHM);
|
|||
// SecretKeySpec secretKey = new SecretKeySpec("NcbHqk****TCGbKnQH".getBytes(), HMAC_ALGORITHM);
|
|||
// mac.init(secretKey);
|
|||
//
|
|||
// byte[] hash = mac.doFinal(data.getBytes());
|
|||
// String strSign = Base64Encoder.encode(hash);
|
|||
// System.out.println("strSign:" + strSign);
|
|||
} |
|||
|
|||
public static String generateSignature(Map<String, Object> param) throws Exception { |
|||
StringBuilder builder = new StringBuilder(); |
|||
Set<String> keys = param.keySet(); |
|||
Object[] keyArr = keys.toArray(); |
|||
|
|||
Arrays.sort(keyArr); |
|||
for (Object keyObj: keyArr) { |
|||
String key = (String) keyObj; |
|||
if (param.get(key) == null || "".equals(param.get(key))) { |
|||
continue; |
|||
} |
|||
builder.append(key.replaceAll("_",".")).append("=").append(param.get(key)).append("&"); |
|||
} |
|||
System.out.println("builder:" + builder.toString()); |
|||
String plaintext = builder.substring(0, builder.length() - 1); |
|||
|
|||
|
|||
|
|||
Mac mac = Mac.getInstance(HMAC_ALGORITHM); |
|||
SecretKeySpec secretKey = new SecretKeySpec(APP_SECRET.getBytes(), HMAC_ALGORITHM); |
|||
mac.init(secretKey); |
|||
|
|||
byte[] hash = mac.doFinal(plaintext.getBytes()); |
|||
// String strSign = KCPlayerSignature.base64Encode(hash);
|
|||
String strSign = Base64Encoder.encode(hash); |
|||
// strSign = strSign.replace(" ", "").replace("\n", "").replace("\r", "");
|
|||
return strSign; |
|||
} |
|||
public static String generateSignature(String service, String host, long timestamp, String payload) throws Exception { |
|||
//String service = "cvm";
|
|||
//String host = "cvm.tencentcloudapi.com";
|
|||
// String region = "ap-guangzhou";
|
|||
// String action = "DescribeInstances";
|
|||
// String version = "2017-03-12";
|
|||
String algorithm = "TC3-HMAC-SHA256"; |
|||
//String timestamp = "1551113065";
|
|||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
|||
// 注意时区,否则容易出错
|
|||
sdf.setTimeZone(TimeZone.getTimeZone("UTC")); |
|||
String date = sdf.format(new Date(Long.valueOf(timestamp + "000"))); |
|||
|
|||
// ************* 步骤 1:拼接规范请求串 *************
|
|||
String httpRequestMethod = "POST"; |
|||
String canonicalUri = "/"; |
|||
String canonicalQueryString = ""; |
|||
String canonicalHeaders = "content-type:application/json; charset=utf-8\n" + "host:" + host + "\n"; |
|||
String signedHeaders = "content-type;host"; |
|||
|
|||
// String payload = "{\"Limit\": 1, \"Filters\": [{\"Values\": [\"\\u672a\\u547d\\u540d\"], \"Name\": \"instance-name\"}]}";
|
|||
String hashedRequestPayload = StrUtil.isEmpty(payload) ? "" : sha256Hex(payload); |
|||
String canonicalRequest = httpRequestMethod + "\n" + canonicalUri + "\n" + canonicalQueryString + "\n" |
|||
+ canonicalHeaders + "\n" + signedHeaders + "\n" + hashedRequestPayload; |
|||
System.out.println(canonicalRequest); |
|||
|
|||
// ************* 步骤 2:拼接待签名字符串 *************
|
|||
String credentialScope = date + "/" + service + "/" + "tc3_request"; |
|||
String hashedCanonicalRequest = sha256Hex(canonicalRequest); |
|||
String stringToSign = algorithm + "\n" + timestamp + "\n" + credentialScope + "\n" + hashedCanonicalRequest; |
|||
System.out.println(stringToSign); |
|||
|
|||
// ************* 步骤 3:计算签名 *************
|
|||
byte[] secretDate = hmac256(("TC3" + SECRET_KEY).getBytes(UTF8), date); |
|||
byte[] secretService = hmac256(secretDate, service); |
|||
byte[] secretSigning = hmac256(secretService, "tc3_request"); |
|||
String signature = DatatypeConverter.printHexBinary(hmac256(secretSigning, stringToSign)).toLowerCase(); |
|||
return signature; |
|||
// System.out.println(signature);
|
|||
//
|
|||
// // ************* 步骤 4:拼接 Authorization *************
|
|||
// String authorization = algorithm + " " + "Credential=" + SECRET_ID + "/" + credentialScope + ", "
|
|||
// + "SignedHeaders=" + signedHeaders + ", " + "Signature=" + signature;
|
|||
//
|
|||
// TreeMap<String, String> headers = new TreeMap<String, String>();
|
|||
// headers.put("Authorization", authorization);
|
|||
// headers.put("Content-Type", CT_JSON);
|
|||
// headers.put("Host", host);
|
|||
//// headers.put("X-TC-Action", action);
|
|||
//// headers.put("X-TC-Timestamp", timestamp);
|
|||
//// headers.put("X-TC-Version", version);
|
|||
//// headers.put("X-TC-Region", region);
|
|||
//
|
|||
// StringBuilder sb = new StringBuilder();
|
|||
// sb.append("curl -X POST https://").append(host)
|
|||
// .append(" -H \"Authorization: ").append(authorization).append("\"")
|
|||
// .append(" -H \"Content-Type: application/json; charset=utf-8\"")
|
|||
// .append(" -H \"Host: ").append(host).append("\"");
|
|||
//// .append(" -H \"X-TC-Action: ").append(action).append("\"")
|
|||
//// .append(" -H \"X-TC-Timestamp: ").append(timestamp).append("\"")
|
|||
//// .append(" -H \"X-TC-Version: ").append(version).append("\"")
|
|||
//// .append(" -H \"X-TC-Region: ").append(region).append("\"")
|
|||
// if (StrUtil.isNotEmpty(payload)) {
|
|||
// sb.append(" -d '").append(payload).append("'");
|
|||
// }
|
|||
//
|
|||
// return sb.toString();
|
|||
} |
|||
} |
@ -0,0 +1,85 @@ |
|||
package com.ccsens.wechatutil.wxfiotexplorer; |
|||
|
|||
import cn.hutool.core.util.StrUtil; |
|||
import com.alibaba.fastjson.JSONObject; |
|||
import com.ccsens.util.CodeError; |
|||
import com.ccsens.util.RedisUtil; |
|||
import com.ccsens.util.RestTemplateUtil; |
|||
import com.ccsens.util.exception.BaseException; |
|||
import com.ccsens.wechatutil.bean.po.wxfiotexplorer.FiotSignin; |
|||
import com.ccsens.wechatutil.bean.po.wxfiotexplorer.FiotSigninResponse; |
|||
import com.ccsens.wechatutil.bean.po.wxfiotexplorer.ResponseInfo; |
|||
import com.ccsens.wechatutil.util.TC3Util; |
|||
import lombok.extern.slf4j.Slf4j; |
|||
import org.springframework.beans.factory.annotation.Value; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
import javax.annotation.PostConstruct; |
|||
import javax.annotation.Resource; |
|||
|
|||
/** |
|||
* @description: |
|||
* @author: whj |
|||
* @time: 2021/11/25 11:47 |
|||
*/ |
|||
@Slf4j |
|||
@Component |
|||
public class FiotExplorerSigninUtil { |
|||
|
|||
private final static String SIGN_URL = "https://iot.cloud.tencent.com/api/exploreropen/appapi"; |
|||
private final static String TOKEN_KEY = "FIOT_{}"; |
|||
@Value("${fiot.appId:}") |
|||
private String appKey; |
|||
@Value("${fiot.secret:}") |
|||
private String appSecret; |
|||
@Resource |
|||
private RedisUtil redisUtil; |
|||
private static FiotExplorerSigninUtil util; |
|||
|
|||
@PostConstruct |
|||
public void init(){ |
|||
util = this; |
|||
util.redisUtil = this.redisUtil; |
|||
util.appKey = this.appKey; |
|||
util.appSecret = this.appSecret; |
|||
} |
|||
|
|||
|
|||
|
|||
|
|||
public static FiotSigninResponse getToken(String openId, String nickName, String avatar, String appKey) throws Exception { |
|||
log.info("物联网查询token:{},{},{}", openId, nickName, avatar); |
|||
String key = StrUtil.format(TOKEN_KEY, openId); |
|||
Object o = util.redisUtil.get(key); |
|||
log.info("{}缓存的token:{}", key, o); |
|||
if (o != null) { |
|||
return (FiotSigninResponse) o; |
|||
} |
|||
// 查询token
|
|||
|
|||
FiotSignin fiotSignin = new FiotSignin(openId, nickName, avatar, appKey); |
|||
log.info("登录:{}", fiotSignin); |
|||
String s = RestTemplateUtil.postBody(SIGN_URL, fiotSignin); |
|||
log.info("登录结果:{}", s); |
|||
if (StrUtil.isEmpty(s)) { |
|||
log.info("登录结果为空"); |
|||
throw new BaseException(CodeError.THIRD_ERROR); |
|||
} |
|||
JSONObject json = JSONObject.parseObject(s); |
|||
log.info("json:{}", json); |
|||
String dataKey = "data"; |
|||
String realDataKey = "Data"; |
|||
if (json.get(dataKey) == null || json.getJSONObject(dataKey).get(realDataKey) == null) { |
|||
log.info("数据异常"); |
|||
throw new BaseException(CodeError.THIRD_ERROR.getCode(), json.getString("msg")); |
|||
} |
|||
|
|||
FiotSigninResponse data = JSONObject.parseObject(json.getJSONObject(dataKey).getString(realDataKey), FiotSigninResponse.class); |
|||
util.redisUtil.set(key, data, data.getExpireAt() - System.currentTimeMillis()/1000); |
|||
log.info("登录返回:{}", data); |
|||
return data; |
|||
} |
|||
|
|||
|
|||
|
|||
} |
@ -1,5 +1,5 @@ |
|||
spring: |
|||
profiles: |
|||
active: dev |
|||
include: util-dev,common |
|||
active: test |
|||
include: util-test,common |
|||
|
|||
|
Loading…
Reference in new issue