|
@@ -174,18 +174,21 @@ public class YBJServiceImpl implements YBJService {
|
|
|
ydParam.setCurrentPage(1);
|
|
|
ydParam.setPageSize((int) pageSize);
|
|
|
List<Map> dataList = new ArrayList<>();
|
|
|
+
|
|
|
+ LocalDate currentDate = LocalDate.now();
|
|
|
+ //获取下月1号的日期
|
|
|
+ LocalDate firstDayOfNextMonth = currentDate.plusMonths(1).with(TemporalAdjusters.firstDayOfMonth());
|
|
|
+ //获取日期是几号
|
|
|
+ int dayOfMonth = firstDayOfNextMonth .getDayOfMonth();
|
|
|
+ //获取月天数
|
|
|
+ int daysInMonth = firstDayOfNextMonth.lengthOfMonth();
|
|
|
+
|
|
|
for (int page = 1; page <= Math.ceil(totalCount / pageSize); page++) {
|
|
|
ydParam.setCurrentPage(page);
|
|
|
//创建护理计划 1次获取50条
|
|
|
dataList = (List<Map>) ydClient.queryData(ydParam, YDConf.FORM_QUERY.retrieve_search_form).getData();
|
|
|
log.info("dataList:{}-----page:"+page+"---",dataList.size());
|
|
|
- LocalDate currentDate = LocalDate.now();
|
|
|
- //获取下月1号的日期
|
|
|
- LocalDate firstDayOfNextMonth = currentDate.plusMonths(1).with(TemporalAdjusters.firstDayOfMonth());
|
|
|
- //获取日期是几号
|
|
|
- int dayOfMonth = firstDayOfNextMonth .getDayOfMonth();
|
|
|
- //获取月天数
|
|
|
- int daysInMonth = firstDayOfNextMonth.lengthOfMonth();
|
|
|
+
|
|
|
dataList.forEach(dataItem -> {
|
|
|
Map formMap = (Map) dataItem.get("formData");
|
|
|
List<Map> mapList = (List<Map>) formMap.get("tableField_lo3pmohx");
|
|
@@ -197,11 +200,6 @@ public class YBJServiceImpl implements YBJService {
|
|
|
List<Map> maps = mapList.stream().filter(items -> items.get("selectField_lo3pmohy").equals(dayOfWeek.replace("星期","周"))).collect(Collectors.toList());
|
|
|
for (Map map : maps) {
|
|
|
Map hashMap = new HashMap();
|
|
|
- try {
|
|
|
- Thread.sleep(100);
|
|
|
- } catch (InterruptedException e) {
|
|
|
- throw new RuntimeException(e);
|
|
|
- }
|
|
|
//通过护理时间 护理对象 护理人员验证数据是否已经存在
|
|
|
YDParam ydParam1 = YDParam.builder()
|
|
|
.formUuid("FORM-IY966L71PJ8FV10D61M1HBHU6FB320M2765OLM")
|
|
@@ -235,9 +233,9 @@ public class YBJServiceImpl implements YBJService {
|
|
|
hashMap.put("textField_lq9llmhl",formMap.get("textField_lop4v4qx")); //护理对象ID
|
|
|
|
|
|
try {
|
|
|
- Thread.sleep(100);
|
|
|
+ Thread.sleep(200);
|
|
|
} catch (InterruptedException e) {
|
|
|
- throw new RuntimeException(e);
|
|
|
+ log.info("睡眠异常");
|
|
|
}
|
|
|
try {
|
|
|
ydClient.operateData(YDParam.builder()
|