| | |
| | | |
| | | @Override |
| | | public LoginUserBean loadUserByUsername(String username) throws UsernameNotFoundException { |
| | | log.info("#登陆账号:{}#", username); |
| | | //log.info("#登陆账号:{}#", username); |
| | | List<GrantedAuthority> grantedAuthorities = new ArrayList<>(); |
| | | // GrantedAuthority grantedAuthority = new SimpleGrantedAuthority("ROLE_ADMIN"); |
| | | // grantedAuthorities.add(grantedAuthority); |
| | |
| | | SecurityContextHolder.getContext().setAuthentication(authentication); |
| | | redisUtils.expire(redisKey, 36000); |
| | | } else { |
| | | log.info("token无法查询:{}", token); |
| | | //log.info("token无法查询:{}", token); |
| | | SecurityContextHolder.clearContext(); |
| | | } |
| | | } else { |
| | |
| | | } |
| | | // log.info("bearerToken---->{}", bearerToken); |
| | | } catch (Exception e) { |
| | | log.error("#解析token异常#", e); |
| | | //log.error("#解析token异常#", e); |
| | | return null; |
| | | } |
| | | return null; |
| | |
| | | } else {
|
| | | memberCoinAddress = memberMapper.selectBlockAddress(Long.parseLong(mId), symbol);
|
| | | }
|
| | | log.info("--->{}", memberCoinAddress);
|
| | | //log.info("--->{}", memberCoinAddress);
|
| | | if (memberCoinAddress != null) {
|
| | | map.put("address", memberCoinAddress.getAddress());
|
| | | map.put("lable", memberCoinAddress.getLabel());
|
| | |
| | | return result;
|
| | | }
|
| | |
|
| | | public static void main(String[] args) {
|
| | | String wallet = RocService.createWallet();
|
| | | System.out.println(wallet);
|
| | | }
|
| | | }
|
| | |
| | | @ApiOperation(value = "findUsdtCnyExchange", notes = "Cny|Usdt兑换")
|
| | | @GetMapping(value = "/findUsdtCnyExchange")
|
| | | public Result findUsdtCnyExchange(@ApiParam(name = "type", value = "类型", type="string", required=true) @RequestParam("type") String type) {
|
| | | log.info("type值----->{}", type);
|
| | | //log.info("type值----->{}", type);
|
| | | return platformCnyUsdtExchangeService.findUsdtCnyExchange(type);
|
| | | }
|
| | |
|
| | |
| | | */ |
| | | @RabbitListener(queues = RabbitMqConfig.QUEUE_ROC_ORDER_CANCEL) |
| | | public void doCancel(String content) { |
| | | //log.debug("#取消的订单---->{}#", content); |
| | | //log.info("#取消的订单---->{}#", content); |
| | | orderCoinService.cancelEntrustWalletCoinOrderForMatch(content); |
| | | } |
| | | |
| | |
| | | private static final String SECRET = "SECc0b73559742b950f07eabbd050c406a6abb3b67d112d3735289e90f58884c543"; |
| | | |
| | | public static void sendActionCard(int type) { |
| | | log.info("send dingtalk"); |
| | | //log.info("send dingtalk"); |
| | | String url = "https://oapi.dingtalk.com/robot/send?access_token=161d5e5b60ae5d6b4c80f2a9c35f9f212961a7c7154aa7e94b99503eca3886b0"; |
| | | Long timestamp = System.currentTimeMillis(); |
| | | try { |
| | |
| | | OapiRobotSendResponse response = client.execute(request); |
| | | //log.info(JSONObject.toJSONString(response)); |
| | | } catch (Exception e) { |
| | | log.error("#dingtalk send error#", e); |
| | | //log.error("#dingtalk send error#", e); |
| | | } finally { |
| | | log.error("#dingtalk finally#"); |
| | | //log.error("#dingtalk finally#"); |
| | | } |
| | | } |
| | | |