规整规整项目
This commit is contained in:
parent
decfe18b9a
commit
2b43d8a7b7
21
pom.xml
21
pom.xml
@ -31,7 +31,7 @@
|
||||
|
||||
|
||||
<dependencies>
|
||||
<!-- 微信支付-->
|
||||
<!-- 微信支付 -->
|
||||
<dependency>
|
||||
<groupId>com.github.wechatpay-apiv3</groupId>
|
||||
<artifactId>wechatpay-java</artifactId>
|
||||
@ -53,17 +53,6 @@
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-data-redis</artifactId>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>io.lettuce</groupId>
|
||||
<artifactId>lettuce-core</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>redis.clients</groupId>
|
||||
<artifactId>jedis</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- 引入mysql连接 -->
|
||||
@ -96,7 +85,7 @@
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<!--<scope>provided</scope>-->
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<!-- hutool工具类 -->
|
||||
@ -160,12 +149,6 @@
|
||||
<version>1.1</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.redisson</groupId>
|
||||
<artifactId>redisson</artifactId>
|
||||
<version>3.22.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 阿里云对象存储 -->
|
||||
<dependency>
|
||||
<groupId>com.aliyun.oss</groupId>
|
||||
|
@ -85,44 +85,6 @@ public class CustomExceptionHandle {
|
||||
return ApiResponse.buildResult(BizCodeEnum.SERVER_UNKONWN_ERROR);
|
||||
}
|
||||
|
||||
public String getStackTrace(Throwable e) {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
StackTraceElement[] stackTrace = e.getStackTrace();
|
||||
sb.append(e.getClass().getName()).append(": ").append(e.getMessage()).append("\r\n");
|
||||
for (StackTraceElement stackTraceElement : stackTrace) {
|
||||
sb.append("\tat ").append(stackTraceElement.toString()).append("\r\n");
|
||||
}
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
public String getRequestAsText() {
|
||||
ServletRequestAttributes attributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
|
||||
if (attributes == null) {
|
||||
return "---";
|
||||
}
|
||||
HttpServletRequest request = attributes.getRequest();
|
||||
StringBuilder rawReq = new StringBuilder();
|
||||
rawReq.append(request.getMethod()).append(" ").append(request.getRequestURL());
|
||||
String queryString = request.getQueryString();
|
||||
if (queryString != null) {
|
||||
rawReq.append("?").append(queryString);
|
||||
}
|
||||
rawReq.append("\r\n");
|
||||
Enumeration<String> headerNames = request.getHeaderNames();
|
||||
while (headerNames.hasMoreElements()) {
|
||||
String headerName = headerNames.nextElement();
|
||||
rawReq.append(headerName).append(": ").append(request.getHeader(headerName)).append("\r\n");
|
||||
}
|
||||
rawReq.append("\r\n");
|
||||
// 获取body
|
||||
try {
|
||||
rawReq.append(request.getReader().lines().collect(Collectors.joining("\r\n")));
|
||||
rawReq.append("\r\n");
|
||||
} catch (IOException ignored) {
|
||||
}
|
||||
return rawReq.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 移动端自定义异常统一处理类
|
||||
*/
|
||||
|
@ -1,168 +0,0 @@
|
||||
package com.ycwl.basic.service;
|
||||
|
||||
import com.ycwl.basic.utils.HttpServiceUtil;
|
||||
import com.ycwl.basic.utils.SslUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.http.HttpEntity;
|
||||
import org.apache.http.NameValuePair;
|
||||
import org.apache.http.StatusLine;
|
||||
import org.apache.http.client.config.RequestConfig;
|
||||
import org.apache.http.client.entity.UrlEncodedFormEntity;
|
||||
import org.apache.http.client.methods.CloseableHttpResponse;
|
||||
import org.apache.http.client.methods.HttpGet;
|
||||
import org.apache.http.client.methods.HttpPost;
|
||||
import org.apache.http.entity.StringEntity;
|
||||
import org.apache.http.impl.client.CloseableHttpClient;
|
||||
import org.apache.http.message.BasicNameValuePair;
|
||||
import org.apache.http.util.EntityUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Http请求服务
|
||||
*
|
||||
* @author songmingsong
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class HttpService {
|
||||
|
||||
/**
|
||||
* @param requestUrl
|
||||
* 请求地址
|
||||
* @param params
|
||||
* 参数
|
||||
* @param encoding
|
||||
* 编码
|
||||
* @return String
|
||||
* @throws Exception
|
||||
* 抛出的异常新
|
||||
*/
|
||||
public String doHttpsPost(String requestUrl, Map<String, String> params, String encoding) throws Exception {
|
||||
String result = HttpServiceUtil.REQUEST_NO_RESULT;
|
||||
// build client 对象
|
||||
CloseableHttpClient httpClient = null;
|
||||
try {
|
||||
httpClient = SslUtil.sslHttpClientBuild();
|
||||
requestUrl = requestUrl.replaceAll("\\s*", "");
|
||||
HttpPost post = new HttpPost(requestUrl);
|
||||
RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(5000)
|
||||
.setConnectionRequestTimeout(1000).setSocketTimeout(5000).build();
|
||||
post.setConfig(requestConfig);
|
||||
// 请求首部--可选的,User-Agent对于一些服务器必选,不加可能不会返回正确结果
|
||||
post.setHeader("User-Agent",
|
||||
"Mozilla/5.0 (Linux; U; Android 5.0.2; zh-cn; PLK-UL00 Build/HONORPLK-UL00) AppleWebKit/533.1 (KHTML, like Gecko)Version/4.0 MQQBrowser/5.4 TBS/025483 Mobile Safari/533.1 MicroMessenger/6.3.8.56_re6b2553.680 NetType/");
|
||||
List<NameValuePair> parasList = new ArrayList<NameValuePair>();
|
||||
if (null != params && params.size() > 0) {
|
||||
for (String key : params.keySet()) {
|
||||
NameValuePair param = new BasicNameValuePair(key, params.get(key));
|
||||
parasList.add(param);
|
||||
}
|
||||
}
|
||||
// Exec Request
|
||||
HttpEntity paramsEntity = new UrlEncodedFormEntity(parasList, encoding);
|
||||
post.setEntity(paramsEntity);
|
||||
CloseableHttpResponse resp = httpClient.execute(post);
|
||||
|
||||
// 获得起始行
|
||||
StatusLine status = resp.getStatusLine();
|
||||
// 获取实体
|
||||
if (HttpServiceUtil.success(status)) {
|
||||
// 获取实体
|
||||
HttpEntity entity = resp.getEntity();
|
||||
// 编码格式
|
||||
result = EntityUtils.toString(entity, encoding);
|
||||
// 释放实体 response.close();//关闭响应
|
||||
EntityUtils.consume(entity);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("doHttpsPost", e);
|
||||
throw e;
|
||||
} finally {
|
||||
if (httpClient != null) {
|
||||
httpClient.close();
|
||||
}
|
||||
}
|
||||
return result;
|
||||
|
||||
}
|
||||
|
||||
public String doGet(String requestUrl, String encoding) throws Exception {
|
||||
String result = HttpServiceUtil.REQUEST_NO_RESULT;
|
||||
// build client 对象
|
||||
CloseableHttpClient httpClient = null;
|
||||
try {
|
||||
httpClient = SslUtil.sslHttpClientBuild();
|
||||
requestUrl = requestUrl.replaceAll("\\s*", "");
|
||||
HttpGet get = new HttpGet(requestUrl);
|
||||
// 请求首部--可选的,User-Agent对于一些服务器必选,不加可能不会返回正确结果
|
||||
get.setHeader("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64;rv:39.0) Gecko/20100101 Firefox/39.0");
|
||||
get.setHeader("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64;rv:39.0) Gecko/20100101 Firefox/39.0");
|
||||
// Exec Request
|
||||
CloseableHttpResponse resp = httpClient.execute(get);
|
||||
// 获得起始行
|
||||
StatusLine status = resp.getStatusLine();
|
||||
if (HttpServiceUtil.success(status)) {
|
||||
// 获取实体
|
||||
HttpEntity entity = resp.getEntity();
|
||||
// 编码格式
|
||||
result = EntityUtils.toString(entity, encoding);
|
||||
// 释放实体 response.close();//关闭响应
|
||||
EntityUtils.consume(entity);
|
||||
}
|
||||
} finally {
|
||||
if (httpClient != null) {
|
||||
httpClient.close();
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public String doPost(String requestUrl, String jsonData, Map<String, String> headers, String encoding) throws Exception {
|
||||
String result = HttpServiceUtil.REQUEST_NO_RESULT; // 默认返回值
|
||||
CloseableHttpClient httpClient = null;
|
||||
try {
|
||||
// 使用自定义 SSL 工具类创建支持 HTTPS 的 HttpClient
|
||||
httpClient = SslUtil.sslHttpClientBuild();
|
||||
|
||||
// 清理 URL 中的空格字符
|
||||
requestUrl = requestUrl.replaceAll("\\s*", "");
|
||||
HttpPost post = new HttpPost(requestUrl);
|
||||
|
||||
// 设置请求头
|
||||
if (headers != null && !headers.isEmpty()) {
|
||||
for (Map.Entry<String, String> header : headers.entrySet()) {
|
||||
post.setHeader(header.getKey(), header.getValue());
|
||||
}
|
||||
}
|
||||
|
||||
// 设置请求体
|
||||
if (jsonData != null) {
|
||||
StringEntity entity = new StringEntity(jsonData, encoding);
|
||||
entity.setContentType("application/json");
|
||||
post.setEntity(entity);
|
||||
}
|
||||
|
||||
// 执行请求
|
||||
CloseableHttpResponse response = httpClient.execute(post);
|
||||
|
||||
// 获取响应状态码及响应数据
|
||||
StatusLine status = response.getStatusLine();
|
||||
if (HttpServiceUtil.success(status)) {
|
||||
HttpEntity entity = response.getEntity();
|
||||
result = EntityUtils.toString(entity, encoding);
|
||||
EntityUtils.consume(entity); // 确保释放资源
|
||||
}
|
||||
response.close(); // 关闭响应对象
|
||||
} finally {
|
||||
if (httpClient != null) {
|
||||
httpClient.close(); // 关闭 HttpClient
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
}
|
@ -1,5 +1,7 @@
|
||||
package com.ycwl.basic.service.impl.mobile;
|
||||
package com.ycwl.basic.service.mobile.impl;
|
||||
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.ycwl.basic.config.WechatConfig;
|
||||
import com.ycwl.basic.constant.BaseContextHandler;
|
||||
@ -18,7 +20,6 @@ import com.ycwl.basic.model.pc.member.req.MemberReqQuery;
|
||||
import com.ycwl.basic.model.pc.member.resp.MemberRespVO;
|
||||
import com.ycwl.basic.model.pc.mp.MpConfigEntity;
|
||||
import com.ycwl.basic.repository.ScenicRepository;
|
||||
import com.ycwl.basic.service.HttpService;
|
||||
import com.ycwl.basic.service.mobile.AppMemberService;
|
||||
import com.ycwl.basic.utils.ApiResponse;
|
||||
import com.ycwl.basic.utils.BeanCopierUtils;
|
||||
@ -40,12 +41,6 @@ import java.util.Map;
|
||||
@Slf4j
|
||||
@Service
|
||||
public class AppMemberServiceImpl implements AppMemberService {
|
||||
@Autowired
|
||||
private WechatConfig config;
|
||||
|
||||
@Autowired
|
||||
private HttpService httpService;
|
||||
|
||||
@Autowired
|
||||
private MemberMapper memberMapper;
|
||||
|
||||
@ -57,19 +52,18 @@ public class AppMemberServiceImpl implements AppMemberService {
|
||||
|
||||
@Override
|
||||
public Map<String, Object> getOpenId(Long scenicId, String code) {
|
||||
Map<String, String> paramMap = new HashMap<>(NumberConstant.FOUR);
|
||||
Map<String, Object> paramMap = new HashMap<>(NumberConstant.FOUR);
|
||||
MpConfigEntity scenicMpConfig = scenicRepository.getScenicMpConfig(scenicId);
|
||||
paramMap.put("appid", scenicMpConfig.getAppId());
|
||||
paramMap.put("secret", scenicMpConfig.getAppSecret());
|
||||
paramMap.put("js_code", code);
|
||||
paramMap.put("grant_type", "authorization_code");
|
||||
try {
|
||||
String response = httpService.doHttpsPost(WeiXinConstant.GET_OPEN_ID, paramMap, "UTF-8");
|
||||
String response = HttpUtil.post(WeiXinConstant.GET_OPEN_ID, paramMap);
|
||||
if (StringUtils.isBlank(response)) {
|
||||
return null;
|
||||
}
|
||||
ObjectMapper mapper = new ObjectMapper();
|
||||
return mapper.readValue(response, Map.class);
|
||||
return JSONObject.parseObject(response);
|
||||
} catch (Exception e) {
|
||||
log.error("getOpenId", e);
|
||||
throw new AppException(BizCodeEnum.SERVER_INTERNAL_ERROR);
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.mobile;
|
||||
package com.ycwl.basic.service.mobile.impl;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.github.pagehelper.PageHelper;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.mobile;
|
||||
package com.ycwl.basic.service.mobile.impl;
|
||||
|
||||
import com.ycwl.basic.enums.StatisticEnum;
|
||||
import com.ycwl.basic.mapper.StatisticsMapper;
|
||||
@ -13,7 +13,6 @@ import com.ycwl.basic.service.mobile.AppStatisticsService;
|
||||
import com.ycwl.basic.utils.ApiResponse;
|
||||
import com.ycwl.basic.utils.DateUtils;
|
||||
import com.ycwl.basic.utils.JwtTokenUtil;
|
||||
import com.ycwl.basic.utils.SnowFlakeUtil;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.mobile;
|
||||
package com.ycwl.basic.service.mobile.impl;
|
||||
|
||||
import cn.hutool.extra.qrcode.QrCodeUtil;
|
||||
import cn.hutool.http.HttpUtil;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.mobile;
|
||||
package com.ycwl.basic.service.mobile.impl;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
@ -29,22 +29,15 @@ import com.ycwl.basic.enums.StatisticEnum;
|
||||
import com.ycwl.basic.exception.AppException;
|
||||
import com.ycwl.basic.mapper.OrderMapper;
|
||||
import com.ycwl.basic.mapper.PaymentMapper;
|
||||
import com.ycwl.basic.mapper.SourceMapper;
|
||||
import com.ycwl.basic.mapper.StatisticsMapper;
|
||||
import com.ycwl.basic.mapper.VideoMapper;
|
||||
import com.ycwl.basic.model.mobile.statistic.req.StatisticsRecordAddReq;
|
||||
import com.ycwl.basic.model.pc.order.entity.OrderEntity;
|
||||
import com.ycwl.basic.model.pc.order.entity.OrderItemEntity;
|
||||
import com.ycwl.basic.model.pc.order.req.OrderUpdateReq;
|
||||
import com.ycwl.basic.model.pc.order.resp.OrderRespVO;
|
||||
import com.ycwl.basic.model.pc.payment.entity.PaymentEntity;
|
||||
import com.ycwl.basic.model.pc.source.entity.MemberSourceEntity;
|
||||
import com.ycwl.basic.model.pc.video.entity.MemberVideoEntity;
|
||||
import com.ycwl.basic.model.wx.WXPayOrderReqVO;
|
||||
import com.ycwl.basic.model.wx.WxPayRespVO;
|
||||
import com.ycwl.basic.model.wx.WxchatCallbackSuccessData;
|
||||
import com.ycwl.basic.repository.OrderRepository;
|
||||
import com.ycwl.basic.service.HttpService;
|
||||
import com.ycwl.basic.service.mobile.WxPayService;
|
||||
import com.ycwl.basic.utils.SnowFlakeUtil;
|
||||
import com.ycwl.basic.utils.WXPayUtil;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import cn.hutool.crypto.digest.DigestUtil;
|
||||
import com.github.pagehelper.PageHelper;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
@ -7,7 +7,6 @@ import com.ycwl.basic.model.pc.broker.entity.BrokerEntity;
|
||||
import com.ycwl.basic.model.pc.broker.req.BrokerReqQuery;
|
||||
import com.ycwl.basic.model.pc.broker.resp.BrokerRespVO;
|
||||
import com.ycwl.basic.service.pc.BrokerService;
|
||||
import com.ycwl.basic.utils.SnowFlakeUtil;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ycwl.basic.mapper.CouponMapper;
|
||||
import com.ycwl.basic.model.pc.coupon.entity.CouponEntity;
|
@ -1,10 +1,9 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.ycwl.basic.model.pc.device.entity.DeviceEntity;
|
||||
import com.ycwl.basic.model.pc.device.req.DeviceBatchSortRequest;
|
||||
import com.ycwl.basic.model.pc.template.resp.TemplateRespVO;
|
||||
import com.ycwl.basic.model.wvp.WvpSyncReqVo;
|
||||
import com.ycwl.basic.repository.DeviceRepository;
|
||||
import com.ycwl.basic.mapper.DeviceMapper;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.ycwl.basic.mapper.MenuMapper;
|
||||
import com.ycwl.basic.model.pc.menu.MenuNode;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
@ -13,7 +13,6 @@ import com.ycwl.basic.model.mobile.order.IsBuyRespVO;
|
||||
import com.ycwl.basic.model.mobile.order.OrderAppPageReq;
|
||||
import com.ycwl.basic.model.mobile.order.PriceObj;
|
||||
import com.ycwl.basic.model.mobile.order.RefundOrderReq;
|
||||
import com.ycwl.basic.model.mobile.statistic.req.StatisticsRecordAddReq;
|
||||
import com.ycwl.basic.model.pc.face.entity.FaceEntity;
|
||||
import com.ycwl.basic.model.pc.member.resp.MemberRespVO;
|
||||
import com.ycwl.basic.model.pc.order.entity.OrderEntity;
|
||||
@ -29,19 +28,15 @@ import com.ycwl.basic.model.pc.orderOp.entity.OrderOperationEntity;
|
||||
import com.ycwl.basic.model.pc.price.entity.PriceConfigEntity;
|
||||
import com.ycwl.basic.model.pc.price.resp.GoodsListRespVO;
|
||||
import com.ycwl.basic.model.pc.source.entity.SourceEntity;
|
||||
import com.ycwl.basic.model.pc.video.entity.MemberVideoEntity;
|
||||
import com.ycwl.basic.model.pc.video.entity.VideoEntity;
|
||||
import com.ycwl.basic.model.pc.video.resp.VideoRespVO;
|
||||
import com.ycwl.basic.model.wx.WXPayOrderReqVO;
|
||||
import com.ycwl.basic.model.wx.WxPayRespVO;
|
||||
import com.ycwl.basic.repository.FaceRepository;
|
||||
import com.ycwl.basic.repository.PriceRepository;
|
||||
import com.ycwl.basic.repository.VideoRepository;
|
||||
import com.ycwl.basic.repository.VideoTaskRepository;
|
||||
import com.ycwl.basic.service.mobile.GoodsService;
|
||||
import com.ycwl.basic.service.mobile.WxPayService;
|
||||
import com.ycwl.basic.service.pc.OrderService;
|
||||
import com.ycwl.basic.service.task.impl.TaskTaskServiceImpl;
|
||||
import com.ycwl.basic.utils.ApiResponse;
|
||||
import com.ycwl.basic.utils.BigDecimalUtil;
|
||||
import com.ycwl.basic.utils.SnowFlakeUtil;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ycwl.basic.biz.PriceBiz;
|
||||
@ -7,9 +7,7 @@ import com.ycwl.basic.model.pc.price.entity.PriceConfigEntity;
|
||||
import com.ycwl.basic.model.pc.price.req.PriceConfigListReq;
|
||||
import com.ycwl.basic.model.pc.price.resp.GoodsListRespVO;
|
||||
import com.ycwl.basic.model.pc.price.resp.PriceConfigRespVO;
|
||||
import com.ycwl.basic.model.pc.scenic.entity.ScenicConfigEntity;
|
||||
import com.ycwl.basic.model.pc.template.resp.TemplateRespVO;
|
||||
import com.ycwl.basic.repository.ScenicRepository;
|
||||
import com.ycwl.basic.repository.TemplateRepository;
|
||||
import com.ycwl.basic.service.pc.PriceConfigService;
|
||||
import org.apache.commons.lang3.StringUtils;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,4 +1,4 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
@ -1,14 +1,12 @@
|
||||
package com.ycwl.basic.service.impl.pc;
|
||||
package com.ycwl.basic.service.pc.impl;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.ycwl.basic.mapper.VideoMapper;
|
||||
import com.ycwl.basic.model.pc.video.entity.VideoEntity;
|
||||
import com.ycwl.basic.model.pc.video.req.VideoReqQuery;
|
||||
import com.ycwl.basic.model.pc.video.resp.VideoRespVO;
|
||||
import com.ycwl.basic.service.pc.VideoService;
|
||||
import com.ycwl.basic.utils.ApiResponse;
|
||||
import com.ycwl.basic.utils.SnowFlakeUtil;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
@ -1,4 +0,0 @@
|
||||
package com.ycwl.basic.service.wvp;
|
||||
|
||||
public interface WvpService {
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
package com.ycwl.basic.service.wvp.impl;
|
||||
|
||||
import com.ycwl.basic.repository.DeviceRepository;
|
||||
import com.ycwl.basic.repository.ScenicRepository;
|
||||
import com.ycwl.basic.service.wvp.WvpService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Service
|
||||
public class WvpServiceImpl implements WvpService {
|
||||
@Autowired
|
||||
private RedisTemplate<String, String> redisTemplate;
|
||||
@Autowired
|
||||
private DeviceRepository deviceRepository;
|
||||
@Autowired
|
||||
private ScenicRepository scenicRepository;
|
||||
}
|
@ -6,7 +6,6 @@ import com.alibaba.fastjson.JSONObject;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.InputStream;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
|
||||
public class WxMpUtil {
|
||||
private static final String GET_WXA_CODE_URL = "https://api.weixin.qq.com/wxa/getwxacodeunlimit?access_token=%s";
|
||||
|
@ -18,14 +18,10 @@ spring:
|
||||
username: zt
|
||||
password: ZhEnTuAi2024zHeNtUaI
|
||||
hikari:
|
||||
connection-timeout: 30000 # 等待连接池分配连接的最大时长(毫秒),超过这个时长还没可用的连接则发生SQLException, 默认:30秒
|
||||
minimum-idle: 5 # 最小连接数
|
||||
maximum-pool-size: 20 # 最大连接数
|
||||
auto-commit: true # 事务自动提交
|
||||
idle-timeout: 60000 # 连接超时的最大时长(毫秒)
|
||||
pool-name: DateSourceHikariCP # 连接池名字
|
||||
max-lifetime: 180000 # 连接的生命时长(毫秒)
|
||||
connection-test-query: SELECT 1 # 连接测试语句
|
||||
pool-name: HikariCP # 连接池名字
|
||||
jackson:
|
||||
date-format: "yyyy-MM-dd HH:mm:ss"
|
||||
time-zone: GMT+8
|
||||
@ -34,11 +30,6 @@ spring:
|
||||
port: 6379
|
||||
# 密码过于复杂需要使用''引起来,要不可能导致项目无法启动,因为无法识别特殊字符
|
||||
password: ZhEnTuAi
|
||||
jedis:
|
||||
pool:
|
||||
max-active: -1 # 连接池最大连接数(使用负值表示没有限制)
|
||||
min-idle: 1 # 连接池中的最小空闲连接
|
||||
time-between-eviction-runs: 3000
|
||||
timeout: 40000
|
||||
# 配置用户头像存放静态资源文件夹
|
||||
resources:
|
||||
|
@ -34,10 +34,6 @@ spring:
|
||||
port: 6379
|
||||
# 密码过于复杂需要使用''引起来,要不可能导致项目无法启动,因为无法识别特殊字符
|
||||
password: ''
|
||||
jedis:
|
||||
pool:
|
||||
max-active: 64 # 连接池最大连接数(使用负值表示没有限制)
|
||||
min-idle: 2 # 连接池中的最小空闲连接
|
||||
timeout: 1000
|
||||
# 配置用户头像存放静态资源文件夹
|
||||
resources:
|
||||
|
@ -155,14 +155,15 @@
|
||||
<select id="countCompleteVideoOfMember" resultType="java.lang.Integer">
|
||||
select ifnull(count(1),0) as count
|
||||
from(
|
||||
select member_id
|
||||
from member_video
|
||||
where member_video.scenic_id = #{scenicId}
|
||||
select mv.member_id
|
||||
from member_video mv
|
||||
left join face f on f.id = mv.face_id
|
||||
where f.scenic_id = #{scenicId}
|
||||
<if test="startTime!= null">
|
||||
and member_video.create_time >= #{startTime}
|
||||
and f.create_time >= #{startTime}
|
||||
</if>
|
||||
<if test="endTime!= null">
|
||||
and member_video.create_time <= #{endTime}
|
||||
and f.create_time <= #{endTime}
|
||||
</if>
|
||||
group by member_id
|
||||
)a
|
||||
|
Loading…
x
Reference in New Issue
Block a user