|
|
@@ -102,6 +102,20 @@ public class WxRentContractController extends WxContractBaseController { |
|
|
return new ResultData(page); |
|
|
return new ResultData(page); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@GetMapping("getDateDiff") |
|
|
|
|
|
@ApiImplicitParams({ |
|
|
|
|
|
@ApiImplicitParam(name = "startDate", value = "开始时间", dataType = "string", paramType = "query", required = true), |
|
|
|
|
|
@ApiImplicitParam(name = "endtDate", value = "结束时间", dataType = "string", paramType = "query", required = true)}) |
|
|
|
|
|
@SystemControllerLog(description = "获取两个时间相差,返回n月零n天") |
|
|
|
|
|
public ResultData getDateDiff(String startDate, String endDate) throws Exception{ |
|
|
|
|
|
SimpleDateFormat sd = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
|
|
Map<String,Integer> map = new HashMap<>(); |
|
|
|
|
|
int[] array = DateUtils.getDiff(sd.parse(startDate),sd.parse(endDate)); |
|
|
|
|
|
map.put("month",array[0]); |
|
|
|
|
|
map.put("day",array[1]); |
|
|
|
|
|
return new ResultData(map); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 新增第一步 |
|
|
* 新增第一步 |
|
|
* @param wxRentContract |
|
|
* @param wxRentContract |
|
|
@@ -385,21 +399,6 @@ public class WxRentContractController extends WxContractBaseController { |
|
|
wxRentContractService.download(request,response); |
|
|
wxRentContractService.download(request,response); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@GetMapping("getDateDiff") |
|
|
|
|
|
@ApiImplicitParams({ |
|
|
|
|
|
@ApiImplicitParam(name = "startDate", value = "开始时间", dataType = "string", paramType = "query", required = true), |
|
|
|
|
|
@ApiImplicitParam(name = "endtDate", value = "结束时间", dataType = "string", paramType = "query", required = true)}) |
|
|
|
|
|
@SystemControllerLog(description = "获取两个时间相差,返回n月零n天") |
|
|
|
|
|
public ResultData getDateDiff(String startDate, String endDate) throws Exception{ |
|
|
|
|
|
SimpleDateFormat sd = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
|
|
Map<String,Integer> map = new HashMap<>(); |
|
|
|
|
|
int[] array = DateUtils.getDiff(sd.parse(startDate),sd.parse(endDate)); |
|
|
|
|
|
map.put("month",array[0]); |
|
|
|
|
|
map.put("day",array[1]); |
|
|
|
|
|
return new ResultData(map); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@PostMapping("effective") |
|
|
@PostMapping("effective") |
|
|
@ApiImplicitParams({}) |
|
|
@ApiImplicitParams({}) |
|
|
@SystemControllerLog(description = "租金合同-合同生效") |
|
|
@SystemControllerLog(description = "租金合同-合同生效") |
|
|
|