Commit e18c06c3 by xieshixiang

修改BUG

parent f302218e
...@@ -218,12 +218,12 @@ public class BindServiceImpl extends ServiceImpl<BindInfoMapper, BindInfo> imple ...@@ -218,12 +218,12 @@ public class BindServiceImpl extends ServiceImpl<BindInfoMapper, BindInfo> imple
/** /**
* 查询违章信息 * 查询违章信息
*/ */
ViolationPlateNumAndTypeQueryReq req = new ViolationPlateNumAndTypeQueryReq(); ViolationPlateNumAndTypeQueryReq queryReq = new ViolationPlateNumAndTypeQueryReq();
req.setPlateNum(bindInfo.getPlateNum()); queryReq.setPlateNum(bindInfo.getPlateNum());
req.setPlateType(bindInfo.getPlateType()); queryReq.setPlateType(bindInfo.getPlateType());
req.setTimeEnd(new Date()); queryReq.setTimeEnd(new Date());
req.setTimeStart(DateUtil.offsetMonth(new Date(),-12)); queryReq.setTimeStart(DateUtil.offsetMonth(new Date(),-12));
List<ViolationRes> byPlateNumAndType = violationCache.getByPlateNumAndType(req); List<ViolationRes> byPlateNumAndType = violationCache.getByPlateNumAndType(queryReq);
/** /**
* 构建违章信息返回列表 * 构建违章信息返回列表
......
...@@ -25,7 +25,7 @@ public class ViolationCache { ...@@ -25,7 +25,7 @@ public class ViolationCache {
* @param req 号牌+号牌类型,时间开始-结束 * @param req 号牌+号牌类型,时间开始-结束
* @return * @return
*/ */
@Cacheable(value = "violations", key = "'plateNum:'+#req.plateNum+':plateType:'+req.plateType+':timeStart:'+#req" + @Cacheable(value = "violations", key = "'plateNum:'+#req.plateNum+':plateType:'+#req.plateType+':timeStart:'+#req" +
".timeStart.toString()+':timeEnd:'+#req.timeEnd.toString()", unless = "#result==null or #result.size()==0") ".timeStart.toString()+':timeEnd:'+#req.timeEnd.toString()", unless = "#result==null or #result.size()==0")
public List<ViolationRes> getByPlateNumAndType(ViolationPlateNumAndTypeQueryReq req) { public List<ViolationRes> getByPlateNumAndType(ViolationPlateNumAndTypeQueryReq req) {
return violatio.getByPlateNumAndType(req); return violatio.getByPlateNumAndType(req);
......
...@@ -14,7 +14,7 @@ import java.util.List; ...@@ -14,7 +14,7 @@ import java.util.List;
* @author: xieshixiang * @author: xieshixiang
* @time:2020/6/19 15:26 * @time:2020/6/19 15:26
**/ **/
@FeignClient(name = "dcp-service-vehicle", path = "violation", contextId = "dcp" + @FeignClient(url="http://10.197.236.100:40204",name = "dcp-service-vehicle",path = "dcp/violation", contextId = "dcp" +
"-service-vehicle-violation") "-service-vehicle-violation")
public interface ViolationFeign { public interface ViolationFeign {
/** /**
......
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