浏览代码

编辑保存更新数据库各项目经营分析
资产档案刷新定时逻辑

fyz 2 月之前
父节点
当前提交
86e4232e78

文件差异内容过多而无法显示
+ 479 - 24
mjava-lanyun/src/main/java/com/malk/lanyun/service/impl/NCServiceImpl.java


+ 3 - 2
mjava-lanyun/src/main/java/com/malk/lanyun/service/impl/SyncAssetsImpl.java

@@ -68,7 +68,7 @@ public class SyncAssetsImpl implements SyncAssetsService {
                     //月折旧额
                     float depreciation = UtilMap.getFloat((Map) formMap,"numberField_lu2eb47d");
                     //已计提期数
-                    int count = UtilMap.getInt((Map) formMap,"numberField_lutjo2dt");
+                    long count = UtilMap.getInt((Map) formMap,"numberField_lutjo2dt");
                     long toMonth = DateUtil.beginOfMonth(new Date()).getTime();
                     //购入日期
                     if (ObjectUtil.isNotNull(formMap.get("dateField_lty0oyv9"))){
@@ -83,7 +83,8 @@ public class SyncAssetsImpl implements SyncAssetsService {
                                 String endDate = DateUtil.date(endTime).toString("yyyy-MM");
                                 long parseTime = DateUtil.beginOfMonth(DateUtil.parse(endDate, "yyyy-MM")).getTime();
                                 if (toMonth <= parseTime){
-                                    count = count + 1;
+                                    DateBetween dateBetween = new DateBetween(DateUtil.date(buyTime),DateUtil.date(toMonth));
+                                    count = dateBetween.betweenMonth(true) - 1;
                                 }
                             }
                             DateBetween dateBetween = new DateBetween(DateUtil.date(buyTime),DateUtil.date(toMonth));

+ 1 - 1
mjava-lanyun/src/main/java/com/malk/lanyun/service/impl/TimerServiceImpl.java

@@ -1046,7 +1046,7 @@ public class TimerServiceImpl implements TimerService {
     @Override
     public void updateAnalysis(Map<String,Object> map) {
         YDParam ydParam = YDParam.builder()
-                .formInstId(map.get("formInstId").toString())
+                .formInstanceId(map.get("formInstId").toString())
                 .build();
         Map data = ydClient.queryData(ydParam, YDConf.FORM_QUERY.retrieve_id).getFormData();
         log.info("修改数据:{}",data);