计划调整
This commit is contained in:
parent
f7c2160050
commit
8879cd1472
@ -123,6 +123,9 @@ public class ProgressPanoramaNodePlanTemplate implements Serializable {
|
||||
@ApiModelProperty(value = "里程碑类型ID")
|
||||
private Long milepostId;
|
||||
|
||||
@ApiModelProperty(value = "项目性质")
|
||||
private Integer nature;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "子级模版信息")
|
||||
private List<ProgressPanoramaNodePlanTemplate> children;
|
||||
|
||||
@ -37,6 +37,7 @@ import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.util.ReflectionUtils;
|
||||
|
||||
import javax.jnlp.IntegrationService;
|
||||
import java.lang.reflect.Field;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.text.SimpleDateFormat;
|
||||
@ -94,6 +95,7 @@ public class ProgressPanoramaNodePlanServiceImpl extends ServiceImpl<ProgressPan
|
||||
@Override
|
||||
public void importAdd(Map<String, Object> map) {
|
||||
String projectSn = MapUtils.getString(map, "projectSn");
|
||||
Integer nature = MapUtils.getInteger(map, "nature");
|
||||
Project project = projectService.getOne(Wrappers.<Project>lambdaQuery().eq(Project::getProjectSn, projectSn));
|
||||
Integer type = MapUtils.getInteger(map, "type");
|
||||
if (type == 1) {
|
||||
@ -103,6 +105,7 @@ public class ProgressPanoramaNodePlanServiceImpl extends ServiceImpl<ProgressPan
|
||||
String projectType = project.getProjectLx();
|
||||
QueryWrapper<ProgressPanoramaNodePlanTemplate> queryWrapper = Wrappers.<ProgressPanoramaNodePlanTemplate>query();
|
||||
queryWrapper.lambda().eq(ProgressPanoramaNodePlanTemplate::getProjectType, projectType);
|
||||
queryWrapper.lambda().eq(ProgressPanoramaNodePlanTemplate::getNature, nature);
|
||||
List<ProgressPanoramaNodePlanTemplate> templateList = progressPanoramaNodePlanTemplateService.list(queryWrapper);
|
||||
if (templateList.size() == 0) {
|
||||
return;
|
||||
@ -195,7 +198,9 @@ public class ProgressPanoramaNodePlanServiceImpl extends ServiceImpl<ProgressPan
|
||||
updateState(progressPanoramaNodePlan.getProjectSn());
|
||||
progressPanoramaNodePlanMapper.insert(progressPanoramaNodePlan);
|
||||
draftInfo(progressPanoramaNodePlan, 1);
|
||||
if (StringUtils.isNotBlank(progressPanoramaNodePlan.getPlanStartDate())) {
|
||||
sendPlan(progressPanoramaNodePlan.getProjectSn());
|
||||
}
|
||||
return progressPanoramaNodePlan.getId();
|
||||
|
||||
}
|
||||
@ -512,7 +517,7 @@ public class ProgressPanoramaNodePlanServiceImpl extends ServiceImpl<ProgressPan
|
||||
value = value.substring(value.indexOf("[") + 1, value.indexOf("]"));
|
||||
newVal = value;
|
||||
}
|
||||
if (!Objects.equals(oldVal, newVal)) {
|
||||
if (!Objects.equals(oldVal, newVal) && field.getType().getName().equals("String")) {
|
||||
// todo 差异
|
||||
System.out.println("fiwName" + field.getName());
|
||||
System.out.println("value" + oldVal + "[" + newVal + "]");
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.zhgd.xmgl.util;
|
||||
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.core.util.CharsetUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.hutool.crypto.asymmetric.KeyType;
|
||||
@ -46,6 +47,7 @@ import java.security.NoSuchAlgorithmException;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
@Slf4j
|
||||
@Component
|
||||
@ -143,7 +145,7 @@ public class JiuzhuDateUtil {
|
||||
}
|
||||
|
||||
public void getContract() {
|
||||
String url = "/api/cube/restful/interface/getModeDataPageList/cghtlb";
|
||||
String url = "/api/cube/restful/interface/getModeDataPageList/CGHTTZ";
|
||||
String systemid = "cghtlb";
|
||||
String d_password = "BAF2C273E784483EA3B865B7BA3A4B6B";
|
||||
JSONObject mainTable = new JSONObject();
|
||||
@ -241,6 +243,7 @@ public class JiuzhuDateUtil {
|
||||
|
||||
private JSONArray convert(List<ProgressPanoramaNodePlanDto> progressPanoramaNodePlans) {
|
||||
JSONArray array = new JSONArray();
|
||||
List<Company> list = companyService.list(Wrappers.<Company>lambdaQuery());
|
||||
for (ProgressPanoramaNodePlanDto progressPanoramaNodePlan : progressPanoramaNodePlans) {
|
||||
JSONObject main = new JSONObject();
|
||||
main.put("rwid", progressPanoramaNodePlan.getId());
|
||||
@ -262,6 +265,13 @@ public class JiuzhuDateUtil {
|
||||
main.put("ndjhlx ", 1);
|
||||
main.put("zt", progressPanoramaNodePlan.getApprovalStatue());
|
||||
main.put("xmid", progressPanoramaNodePlan.getProjectId());
|
||||
List<Company> companyList = list.stream().filter(l -> l.getCompanyType() == 4 && l.getCompanySn().equals(progressPanoramaNodePlan.getChargerDeptId())).collect(Collectors.toList());
|
||||
if (companyList.size() > 0) {
|
||||
List<Company> companyStream = list.stream().filter(l -> l.getCompanyId().toString().equals(companyList.get(0).getParentId().toString())).collect(Collectors.toList());
|
||||
main.put("zzdw", companyStream.get(0).getCompanySn());
|
||||
|
||||
}
|
||||
main.put("nd", DateUtil.year(DateUtil.parseDate(progressPanoramaNodePlan.getPlanStartDate())));
|
||||
// main.put("rwid", "123");
|
||||
// main.put("rwlx", "");
|
||||
// main.put("rwlb", "");
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user