Browse Source

fix:[试验管理]表单落笔留痕

master
15881625488@163.com 3 months ago
parent
commit
7f92377237
22 changed files with 814 additions and 326 deletions
  1. +30
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormApplyController.java
  2. +4
    -4
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormFillController.java
  3. +29
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPlanController.java
  4. +27
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPreController.java
  5. +29
    -6
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormApply.java
  6. +1
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormFill.java
  7. +28
    -6
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormPlan.java
  8. +28
    -6
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormPre.java
  9. +1
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/form/study/StudyFormUpdateForm.java
  10. +1
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormApplyJcgjService.java
  11. +16
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormApplyService.java
  12. +4
    -9
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormFillService.java
  13. +17
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormPlanService.java
  14. +16
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormPreService.java
  15. +131
    -31
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormApplyServiceImpl.java
  16. +73
    -76
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormFillServiceImpl.java
  17. +124
    -21
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormPlanServiceImpl.java
  18. +119
    -19
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormPreServiceImpl.java
  19. +8
    -8
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/utils/GyzjJcnrUtil.java
  20. +10
    -9
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/utils/MjyJcnrUtil.java
  21. +25
    -25
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/utils/StudyFormUtil.java

+ 30
- 2
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormApplyController.java View File

@ -8,6 +8,7 @@ import com.hxhq.business.dto.study.StudyFormApplyListDto;
import com.hxhq.business.form.study.StudyFormApplyGcForm;
import com.hxhq.business.form.study.StudyFormApplyShfzForm;
import com.hxhq.business.form.study.StudyFormApplySearchForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.service.*;
import com.hxhq.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
@ -124,8 +125,7 @@ public class StudyFormApplyController extends BaseController {
@PostMapping("/bc")
@RequiresPermissions({"business:drugFormApply:bj","business:drugFormApply:xz"})
public AjaxResult bc(@RequestBody StudyFormApply studyFormApply) {
studyFormApplyService.bc(studyFormApply);
return AjaxResult.success("操作成功");
return AjaxResult.success(studyFormApplyService.bc(studyFormApply));
}
@ -189,4 +189,32 @@ public class StudyFormApplyController extends BaseController {
studyFormApplyService.shjj(studyFormApply);
return AjaxResult.success("操作成功");
}
/**
* 保存复核意见
*/
@PostMapping("/updateFhyjjl")
public AjaxResult updateFhyjjl(@RequestBody StudyFormUpdateForm form) {
studyFormApplyService.updateFhyjjl(form);
return AjaxResult.success("操作成功");
}
/**
* 保存表单内容
*/
@PostMapping("/updateBdnr")
public AjaxResult updateBdnr(@RequestBody StudyFormUpdateForm form) {
studyFormApplyService.updateBdnr(form);
return AjaxResult.success("操作成功");
}
/**
* 保存字段勾选记录
*/
@PostMapping("/updateZdgxjl")
public AjaxResult updateZdgxjl(@RequestBody StudyFormUpdateForm form) {
studyFormApplyService.updateZdgxjl(form);
return AjaxResult.success("操作成功");
}
}

+ 4
- 4
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormFillController.java View File

@ -8,7 +8,7 @@ import com.hxhq.business.dto.study.StudyFormFillListDto;
import com.hxhq.business.form.study.StudyFormFillGcForm;
import com.hxhq.business.form.study.StudyFormFillShfzForm;
import com.hxhq.business.form.study.StudyFormFillSearchForm;
import com.hxhq.business.form.study.StudyFormFillUpdateForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.service.*;
import com.hxhq.common.security.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
@ -199,7 +199,7 @@ public class StudyFormFillController extends BaseController {
* 保存复核意见
*/
@PostMapping("/updateFhyjjl")
public AjaxResult updateFhyjjl(@RequestBody StudyFormFillUpdateForm form) {
public AjaxResult updateFhyjjl(@RequestBody StudyFormUpdateForm form) {
studyFormFillService.updateFhyjjl(form);
return AjaxResult.success("操作成功");
}
@ -208,7 +208,7 @@ public class StudyFormFillController extends BaseController {
* 保存表单内容
*/
@PostMapping("/updateBdnr")
public AjaxResult updateBdnr(@RequestBody StudyFormFillUpdateForm form) {
public AjaxResult updateBdnr(@RequestBody StudyFormUpdateForm form) {
studyFormFillService.updateBdnr(form);
return AjaxResult.success("操作成功");
}
@ -217,7 +217,7 @@ public class StudyFormFillController extends BaseController {
* 保存字段勾选记录
*/
@PostMapping("/updateZdgxjl")
public AjaxResult updateZdgxjl(@RequestBody StudyFormFillUpdateForm form) {
public AjaxResult updateZdgxjl(@RequestBody StudyFormUpdateForm form) {
studyFormFillService.updateZdgxjl(form);
return AjaxResult.success("操作成功");
}

+ 29
- 2
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPlanController.java View File

@ -6,6 +6,7 @@ import com.hxhq.business.domain.StudyFormPlanJcgj;
import com.hxhq.business.domain.StudyFormPlanQmxx;
import com.hxhq.business.dto.study.StudyFormPlanListDto;
import com.hxhq.business.form.study.StudyFormPlanSearchForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.service.IStudyFormPlanJcgjService;
import com.hxhq.business.service.IStudyFormPlanQmxxService;
import com.hxhq.common.security.annotation.RequiresPermissions;
@ -93,8 +94,7 @@ public class StudyFormPlanController extends BaseController
@PostMapping("/bc")
@RequiresPermissions({"business:studyFormPre:bj","business:nonTrialFormPre:xz"})
public AjaxResult bc(@RequestBody StudyFormPlan studyFormPlan) {
studyFormPlanService.bc(studyFormPlan);
return AjaxResult.success("操作成功");
return AjaxResult.success(studyFormPlanService.bc(studyFormPlan));
}
@ -139,4 +139,31 @@ public class StudyFormPlanController extends BaseController
studyFormPlanService.sy(studyFormPlan);
return AjaxResult.success("操作成功");
}
/**
* 保存复核意见
*/
@PostMapping("/updateFhyjjl")
public AjaxResult updateFhyjjl(@RequestBody StudyFormUpdateForm form) {
studyFormPlanService.updateFhyjjl(form);
return AjaxResult.success("操作成功");
}
/**
* 保存表单内容
*/
@PostMapping("/updateBdnr")
public AjaxResult updateBdnr(@RequestBody StudyFormUpdateForm form) {
studyFormPlanService.updateBdnr(form);
return AjaxResult.success("操作成功");
}
/**
* 保存字段勾选记录
*/
@PostMapping("/updateZdgxjl")
public AjaxResult updateZdgxjl(@RequestBody StudyFormUpdateForm form) {
studyFormPlanService.updateZdgxjl(form);
return AjaxResult.success("操作成功");
}
}

+ 27
- 2
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPreController.java View File

@ -7,6 +7,7 @@ import com.hxhq.business.domain.*;
import com.hxhq.business.dto.study.StudyFormPreListDto;
import com.hxhq.business.form.study.StudyFormPreAuditForm;
import com.hxhq.business.form.study.StudyFormPreSearchForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.service.IStudyFormPreJcgjService;
import com.hxhq.business.service.IStudyFormPreQmxxService;
import com.hxhq.common.security.annotation.RequiresPermissions;
@ -91,8 +92,7 @@ public class StudyFormPreController extends BaseController
"business:drugFormPre:bj","business:drugFormPre:xz"})
public AjaxResult bc(@RequestBody StudyFormPre studyFormPre)
{
studyFormPreService.bc(studyFormPre);
return AjaxResult.success("操作成功");
return AjaxResult.success(studyFormPreService.bc(studyFormPre));
}
/**
@ -138,5 +138,30 @@ public class StudyFormPreController extends BaseController
studyFormPreService.jj(form);
return AjaxResult.success("操作成功");
}
/**
* 保存复核意见
*/
@PostMapping("/updateFhyjjl")
public AjaxResult updateFhyjjl(@RequestBody StudyFormUpdateForm form) {
studyFormPreService.updateFhyjjl(form);
return AjaxResult.success("操作成功");
}
/**
* 保存表单内容
*/
@PostMapping("/updateBdnr")
public AjaxResult updateBdnr(@RequestBody StudyFormUpdateForm form) {
studyFormPreService.updateBdnr(form);
return AjaxResult.success("操作成功");
}
/**
* 保存字段勾选记录
*/
@PostMapping("/updateZdgxjl")
public AjaxResult updateZdgxjl(@RequestBody StudyFormUpdateForm form) {
studyFormPreService.updateZdgxjl(form);
return AjaxResult.success("操作成功");
}
}

+ 29
- 6
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormApply.java View File

@ -63,8 +63,14 @@ public class StudyFormApply extends MpBaseEntity
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date tjsj;
/** 使用物资信息 */
private String resource;
/** 字段修改记录 */
private String zdxgjl;
/** 复核意见记录 */
private String fhyjjl;
/** 字段勾选记录 */
private String zdgxjl;
/** 签名意义 */
@TableField(exist = false)
@ -103,13 +109,30 @@ public class StudyFormApply extends MpBaseEntity
this.userMcEn = userMcEn;
}
public String getResource() {
return resource;
public String getZdxgjl() {
return zdxgjl;
}
public void setZdxgjl(String zdxgjl) {
this.zdxgjl = zdxgjl;
}
public String getFhyjjl() {
return fhyjjl;
}
public void setResource(String resource) {
this.resource = resource;
public void setFhyjjl(String fhyjjl) {
this.fhyjjl = fhyjjl;
}
public String getZdgxjl() {
return zdgxjl;
}
public void setZdgxjl(String zdgxjl) {
this.zdgxjl = zdgxjl;
}
public String getStudySn() {
return studySn;
}

+ 1
- 1
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormFill.java View File

@ -51,7 +51,7 @@ public class StudyFormFill extends MpBaseEntity
private String userMcEn;
/** 是否补录 */
@Compare(name = "是否补录",nameEn = "Concentration")
@Compare(name = "是否补录",nameEn = "是否补录")
private String sfbl;
/** 表单状态:1:填报中;3:已提交;5:已完成(经复核);7:已完成;9:待废止;11:已废止 */

+ 28
- 6
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormPlan.java View File

@ -67,9 +67,14 @@ public class StudyFormPlan extends MpBaseEntity
/** 复核人员名称-英文(通知用) */
private String fhryMcEn;
/** 物资信息 */
private String resource;
/** 字段修改记录 */
private String zdxgjl;
/** 复核意见记录 */
private String fhyjjl;
/** 字段勾选记录 */
private String zdgxjl;
/** 签名意义 */
@TableField(exist = false)
@ -112,13 +117,30 @@ public class StudyFormPlan extends MpBaseEntity
this.fhryMcEn = fhryMcEn;
}
public String getResource() {
return resource;
public String getZdxgjl() {
return zdxgjl;
}
public void setZdxgjl(String zdxgjl) {
this.zdxgjl = zdxgjl;
}
public String getFhyjjl() {
return fhyjjl;
}
public void setResource(String resource) {
this.resource = resource;
public void setFhyjjl(String fhyjjl) {
this.fhyjjl = fhyjjl;
}
public String getZdgxjl() {
return zdgxjl;
}
public void setZdgxjl(String zdgxjl) {
this.zdgxjl = zdgxjl;
}
public Long getFhryId() {
return fhryId;
}

+ 28
- 6
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormPre.java View File

@ -77,8 +77,14 @@ public class StudyFormPre extends MpBaseEntity
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date tjsj;
/** 物资信息 */
private String resource;
/** 字段修改记录 */
private String zdxgjl;
/** 复核意见记录 */
private String fhyjjl;
/** 字段勾选记录 */
private String zdgxjl;
/** 签名人密码 */
@TableField(exist = false)
@ -121,12 +127,28 @@ public class StudyFormPre extends MpBaseEntity
this.shryMcEn = shryMcEn;
}
public String getResource() {
return resource;
public String getZdxgjl() {
return zdxgjl;
}
public void setZdxgjl(String zdxgjl) {
this.zdxgjl = zdxgjl;
}
public String getFhyjjl() {
return fhyjjl;
}
public void setFhyjjl(String fhyjjl) {
this.fhyjjl = fhyjjl;
}
public String getZdgxjl() {
return zdgxjl;
}
public void setResource(String resource) {
this.resource = resource;
public void setZdgxjl(String zdgxjl) {
this.zdgxjl = zdgxjl;
}
public String getStudySn() {

hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/form/study/StudyFormFillUpdateForm.java → hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/form/study/StudyFormUpdateForm.java View File

@ -3,7 +3,7 @@ package com.hxhq.business.form.study;
/**
* @author tanfei
*/
public class StudyFormFillUpdateForm {
public class StudyFormUpdateForm {
/** id */
private Long id;

+ 1
- 2
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormApplyJcgjService.java View File

@ -6,8 +6,7 @@ import java.util.Map;
import com.hxhq.business.domain.StudyFormApplyJcgj;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hxhq.business.domain.StudyFormApplyJcgj;
import com.hxhq.business.domain.StudyFormPreJcgj;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.system.api.domain.SysUser;
/**

+ 16
- 1
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormApplyService.java View File

@ -8,6 +8,7 @@ import com.hxhq.business.dto.study.StudyFormApplyListDto;
import com.hxhq.business.form.study.StudyFormApplyGcForm;
import com.hxhq.business.form.study.StudyFormApplySearchForm;
import com.hxhq.business.form.study.StudyFormApplyShfzForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
/**
* 试验-填报单Service接口
@ -63,7 +64,7 @@ public interface IStudyFormApplyService extends IService
* 保存
* @param studyFormApply
*/
public void bc(StudyFormApply studyFormApply);
public StudyFormApply bc(StudyFormApply studyFormApply);
/**
* 提交
@ -101,4 +102,18 @@ public interface IStudyFormApplyService extends IService
*/
public void shjj(StudyFormApply studyFormApply);
/**
* 更新表单内容
*/
public void updateBdnr(StudyFormUpdateForm form);
/**
* 更新复核意见
*/
public void updateFhyjjl(StudyFormUpdateForm form);
/**
* 更新字段勾选记录
*/
public void updateZdgxjl(StudyFormUpdateForm form);
}

+ 4
- 9
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormFillService.java View File

@ -3,16 +3,11 @@ package com.hxhq.business.service;
import java.util.List;
import com.hxhq.business.domain.StudyFormFill;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hxhq.business.dto.mjy.DetailDto;
import com.hxhq.business.dto.study.StudyFormFillListDto;
import com.hxhq.business.form.study.StudyFormFillGcForm;
import com.hxhq.business.form.study.StudyFormFillSearchForm;
import com.hxhq.business.form.study.StudyFormFillShfzForm;
import com.hxhq.business.form.study.StudyFormFillUpdateForm;
import com.hxhq.common.core.web.domain.AjaxResult;
import com.hxhq.common.security.annotation.RequiresPermissions;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import com.hxhq.business.form.study.StudyFormUpdateForm;
/**
* 试验-填报单Service接口
@ -113,16 +108,16 @@ public interface IStudyFormFillService extends IService
/**
* 更新表单内容
*/
public void updateBdnr(StudyFormFillUpdateForm form);
public void updateBdnr(StudyFormUpdateForm form);
/**
* 更新复核意见
*/
public void updateFhyjjl(StudyFormFillUpdateForm form);
public void updateFhyjjl(StudyFormUpdateForm form);
/**
* 更新字段勾选记录
*/
public void updateZdgxjl(StudyFormFillUpdateForm form);
public void updateZdgxjl(StudyFormUpdateForm form);
}

+ 17
- 1
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormPlanService.java View File

@ -4,6 +4,7 @@ import java.util.List;
import com.hxhq.business.domain.StudyFormPlan;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hxhq.business.dto.study.StudyFormPlanListDto;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.form.study.StudyFormPlanSearchForm;
/**
@ -41,7 +42,7 @@ public interface IStudyFormPlanService extends IService
* 保存
* @param studyFormPlan
*/
public void bc(StudyFormPlan studyFormPlan);
public StudyFormPlan bc(StudyFormPlan studyFormPlan);
/**
@ -69,4 +70,19 @@ public interface IStudyFormPlanService extends IService
*/
public void sy(StudyFormPlan studyFormPlan);
/**
* 更新表单内容
*/
public void updateBdnr(StudyFormUpdateForm form);
/**
* 更新复核意见
*/
public void updateFhyjjl(StudyFormUpdateForm form);
/**
* 更新字段勾选记录
*/
public void updateZdgxjl(StudyFormUpdateForm form);
}

+ 16
- 1
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormPreService.java View File

@ -8,6 +8,7 @@ import com.baomidou.mybatisplus.extension.service.IService;
import com.hxhq.business.dto.study.StudyFormPreListDto;
import com.hxhq.business.form.study.StudyFormPreAuditForm;
import com.hxhq.business.form.study.StudyFormPreSearchForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.common.core.web.domain.AjaxResult;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
@ -40,7 +41,7 @@ public interface IStudyFormPreService extends IService
* 保存
* @param studyFormPre
*/
public void bc(StudyFormPre studyFormPre);
public StudyFormPre bc(StudyFormPre studyFormPre);
/**
* 提交
@ -66,4 +67,18 @@ public interface IStudyFormPreService extends IService
*/
public StudyFormFill tb(StudyFormPre studyFormPre);
/**
* 更新表单内容
*/
public void updateBdnr(StudyFormUpdateForm form);
/**
* 更新复核意见
*/
public void updateFhyjjl(StudyFormUpdateForm form);
/**
* 更新字段勾选记录
*/
public void updateZdgxjl(StudyFormUpdateForm form);
}

+ 131
- 31
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormApplyServiceImpl.java View File

@ -2,6 +2,7 @@ package com.hxhq.business.service.impl;
import java.util.*;
import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.hxhq.business.domain.*;
@ -13,14 +14,13 @@ import com.hxhq.business.enums.study.StudyFormApplyBdztEnum;
import com.hxhq.business.enums.zykgl.JcgjlxEnum;
import com.hxhq.business.enums.zykgl.JcmcysEnum;
import com.hxhq.business.enums.zykgl.JlztEnum;
import com.hxhq.business.form.study.StudyFormApplyGcForm;
import com.hxhq.business.form.study.StudyFormApplySearchForm;
import com.hxhq.business.form.study.StudyFormApplyShfzForm;
import com.hxhq.business.form.study.*;
import com.hxhq.business.form.study.StudyFormApplySearchForm;
import com.hxhq.business.service.IStudyFormApplyJcgjService;
import com.hxhq.business.service.IStudyFormApplyQmxxService;
import com.hxhq.business.utils.JctUtil;
import com.hxhq.business.utils.ObjectCompareUtil;
import com.hxhq.business.utils.StudyFormUtil;
import com.hxhq.common.core.exception.ServiceException;
import com.hxhq.common.core.utils.StringUtils;
import com.hxhq.common.security.utils.SecurityUtils;
@ -117,7 +117,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void jq(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -131,7 +131,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
throw new ServiceException("表单不是申请状态,不能加签");
}
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.bj.getValue(), studyFormApply.getQmyy(), JcmcysEnum.orange.getValue(), null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.bj.getValue(), studyFormApply.getQmyy(), JcmcysEnum.orange.getValue(), null, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(), studyFormApply.getQmyy(), qmr, studyFormApply.getRemark());
@ -144,7 +144,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void fz(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -160,7 +160,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.dfz.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "申请废止", JcmcysEnum.orange.getValue(), null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "申请废止", JcmcysEnum.orange.getValue(), null, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(), "申请废止", qmr, studyFormApply.getRemark());
@ -174,7 +174,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void qrfz(StudyFormApplyShfzForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, form.getQmrmm());
if (form.getId() == null || form.getId().longValue() < 0) {
@ -191,14 +191,14 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.yfz.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "废止通过", JcmcysEnum.green.getValue(),null, qmr, form.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "废止通过", JcmcysEnum.green.getValue(), null, qmr, form.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "废止通过", qmr, form.getRemark());
} else {
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.tbz.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "废止拒绝", JcmcysEnum.red.getValue(), null, qmr, form.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "废止拒绝", JcmcysEnum.red.getValue(), null, qmr, form.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "废止拒绝", qmr, form.getRemark());
@ -214,7 +214,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void ghgsr(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -237,7 +237,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
formData.put("新归属人", studyFormApply.getUserMc());
formData.put("原归属人", studyFormApplyOld.getUserMc());
formData.put("原因", studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "更换归属人", JcmcysEnum.orange.getValue(),formData, qmr, null,null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "更换归属人", JcmcysEnum.orange.getValue(), formData, qmr, null, null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "更换归属人", qmr, studyFormApply.getRemark());
@ -249,8 +249,9 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
* @param studyFormApply
*/
@Override
public void bc(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
public StudyFormApply bc(StudyFormApply studyFormApply) {
StudyFormApply result = null;
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
if (studyFormApply.getId() != null) {
StudyFormApply studyFormApplyOld = this.queryInfo(studyFormApply.getId());
if (studyFormApplyOld == null) {
@ -273,6 +274,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
}
studyFormApplyJcgjService.saveBatch(studyFormApplyJcgjs);
}
result = studyFormApplyOld;
} else {
studyFormApply.setBdzt(StudyFormApplyBdztEnum.tbz.getValue());
studyFormApply.setUserId(qmr.getUserId());
@ -282,11 +284,12 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注", studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApply.getId(), JcgjlxEnum.lc.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApply.getId(), JcgjlxEnum.lc.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(), null);
result = studyFormApply;
}
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(), "填写并保存记录", qmr, studyFormApply.getRemark());
return result;
}
@ -297,7 +300,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void tj(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null) {
@ -308,9 +311,9 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
studyFormApply.setTjsj(new Date());
this.saveOrUpdate(studyFormApply);
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApply.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApply.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(), "填写并提交记录", qmr, studyFormApply.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(), "填写并提交记录", qmr, studyFormApply.getRemark());
}
@ -321,7 +324,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void fhtg(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -337,7 +340,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.yfh.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "复核通过", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "复核通过", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "复核通过", qmr, studyFormApply.getRemark());
}
@ -350,7 +353,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void fhjj(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -368,9 +371,9 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "复核拒绝", JcmcysEnum.red.getValue(), formData, qmr, null,null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "复核拒绝", JcmcysEnum.red.getValue(), formData, qmr, null, null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "复核拒绝", qmr, studyFormApply.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "复核拒绝", qmr, studyFormApply.getRemark());
}
@ -381,7 +384,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void sy(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -399,7 +402,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注", studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "已审阅", qmr, studyFormApply.getRemark());
@ -413,7 +416,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void shtg(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -429,7 +432,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.ywc.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "审核通过", JcmcysEnum.green.getValue(),null, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "审核通过", JcmcysEnum.green.getValue(), null, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "审核通过", qmr, studyFormApply.getRemark());
}
@ -442,7 +445,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void shjj(StudyFormApply studyFormApply) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormApply.getQmrmm());
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
@ -460,9 +463,9 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "审核拒绝", JcmcysEnum.red.getValue(), formData, qmr, studyFormApply.getRemark(),null);
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "审核拒绝", JcmcysEnum.red.getValue(), formData, qmr, studyFormApply.getRemark(), null);
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "审核拒绝", qmr, studyFormApply.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(), "审核拒绝", qmr, studyFormApply.getRemark());
}
@ -479,4 +482,101 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
sysUserService.checkPassword(user, qmrmm, false);
}
/**
* 更新表单内容
*/
@Override
public void updateBdnr(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//更新表单内容
StudyFormApply studyFormApplyOld = this.queryInfo(form.getId());
studyFormApplyOld.setBdnr(form.getBdnr());
studyFormApplyOld.setZdxgjl(form.getZdxgjl());
this.updateById(studyFormApplyOld);
// baseMapper.updateBdnr(form.getId(), form.getBdnr(),form.getZdxgjl());
// {"type":"fieldChanged","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0333","title":"修改记录","time":"2026-01-14 19:44:02"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0","title":"修改记录","time":"2026-01-14 19:43:57"}]}
//稽查轨迹 todo
if (StringUtils.isNoneBlank(form.getFiledValue())) {
JSONObject jsonObject = JSONObject.parseObject(form.getFiledValue());
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormApplyJcgj> studyFormApplyJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(jsonObject.getString("oldValue"))) {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("原值", jsonObject.getString("oldValue"));
formData.put("新值", jsonObject.getString("value"));
formData.put("原因", jsonObject.getString("reason"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("原值", jsonObject.getString("oldValue"));
formDataEn.put("新值", jsonObject.getString("value"));
formDataEn.put("原因", jsonObject.getString("reason"));
studyFormApplyJcgjs.add(studyFormApplyJcgjService.getJcgj(form.getId(), JcgjlxEnum.xg.getValue(), "修改记录", JcmcysEnum.orange.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("填入值", jsonObject.getString("value"));
formData.put("填写人", qmr.getNickName());
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("填入值", jsonObject.getString("value"));
formDataEn.put("填写人", qmr.getNickName());
studyFormApplyJcgjs.add(studyFormApplyJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "填写", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), null, null));
}
studyFormApplyJcgjService.saveBatch(studyFormApplyJcgjs);
}
}
/**
* 更新复核意见
*/
@Override
public void updateFhyjjl(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
// {"type":"reply","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
// {"type":"content","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
//更新复核意见 todo
// baseMapper.updateFhyjjl(form.getId(), form.getFhyjjl());
StudyFormApply studyFormApplyOld = this.queryInfo(form.getId());
studyFormApplyOld.setFhyjjl(form.getFhyjjl());
this.updateById(studyFormApplyOld);
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormApplyJcgj> studyFormApplyJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(form.getContent())) {
JSONObject jsonObject = JSONObject.parseObject(form.getContent());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("意见回复", jsonObject.getString("content"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("意见回复", jsonObject.getString("content"));
studyFormApplyJcgjs.add(studyFormApplyJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "意见回复", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
JSONObject jsonObject = JSONObject.parseObject(form.getReplay());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("复核意见", jsonObject.getString("content"));
//en
formData.put("字段名", jsonObject.getString("fieldEn"));
formData.put("复核意见", jsonObject.getString("content"));
studyFormApplyJcgjs.add(studyFormApplyJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "复核意见", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
}
studyFormApplyJcgjService.saveBatch(studyFormApplyJcgjs);
}
/**
* 更新字段勾选记录
*/
@Override
public void updateZdgxjl(StudyFormUpdateForm form) {
//更新勾选记录 todo
StudyFormApply studyFormApplyOld = this.queryInfo(form.getId());
studyFormApplyOld.setZdxgjl(form.getZdgxjl());
this.updateById(studyFormApplyOld);
// baseMapper.updateZdgxjl(form.getId(), form.getZdgxjl());
}
}

+ 73
- 76
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormFillServiceImpl.java View File

@ -2,21 +2,16 @@ package com.hxhq.business.service.impl;
import java.util.*;
import com.alibaba.fastjson2.JSONArray;
import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.hxhq.business.domain.*;
import com.hxhq.business.dto.mjy.DetailDto;
import com.hxhq.business.dto.study.StudyFormFillListDto;
import com.hxhq.business.enums.NormalEnum;
import com.hxhq.business.enums.study.StudyFormApplyBdztEnum;
import com.hxhq.business.enums.study.StudyFormFillBdztEnum;
import com.hxhq.business.enums.study.StudyFormFillBdztEnum;
import com.hxhq.business.enums.template.ProductEnum;
import com.hxhq.business.enums.zykgl.JcgjlxEnum;
import com.hxhq.business.enums.zykgl.JcmcysEnum;
import com.hxhq.business.enums.zykgl.JlztEnum;
import com.hxhq.business.form.study.*;
import com.hxhq.business.form.study.StudyFormFillSearchForm;
import com.hxhq.business.service.*;
@ -112,7 +107,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
if (id == null || id.longValue() < 0) {
throw new ServiceException("参数id不正确");
}
StudyFormFill studyFormFill=baseMapper.queryInfo(id);
StudyFormFill studyFormFill = baseMapper.queryInfo(id);
return studyFormFill;
}
@ -123,7 +118,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void jq(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -137,9 +132,9 @@ public class StudyFormFillServiceImpl extends ServiceImpl
throw new ServiceException("表单不是填报状态,不能加签");
}
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.bj.getValue(), studyFormFill.getQmyy(), JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null);
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.bj.getValue(), studyFormFill.getQmyy(), JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(), studyFormFill.getQmyy(),qmr, studyFormFill.getRemark());
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(), studyFormFill.getQmyy(), qmr, studyFormFill.getRemark());
}
@ -150,7 +145,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void fz(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -166,7 +161,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
studyFormFillOld.setBdzt(StudyFormFillBdztEnum.dfz.getValue());
this.updateById(studyFormFillOld);
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "申请废止", JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null,null);
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "申请废止", JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null, null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(), "申请废止", qmr, studyFormFill.getRemark());
@ -180,7 +175,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void qrfz(StudyFormFillShfzForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, form.getQmrmm());
if (form.getId() == null || form.getId().longValue() < 0) {
@ -199,7 +194,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", form.getRemark());
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "废止通过", JcmcysEnum.green.getValue(), formData, SecurityUtils.getLoginUser().getSysUser(), null,null);
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "废止通过", JcmcysEnum.green.getValue(), formData, SecurityUtils.getLoginUser().getSysUser(), null, null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "废止通过", qmr, form.getRemark());
@ -209,7 +204,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", form.getRemark());
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "废止拒绝", JcmcysEnum.red.getValue(), formData, SecurityUtils.getLoginUser().getSysUser(), null,null);
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "废止拒绝", JcmcysEnum.red.getValue(), formData, SecurityUtils.getLoginUser().getSysUser(), null, null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "废止拒绝", qmr, form.getRemark());
@ -225,7 +220,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void ghgsr(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -248,7 +243,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
studyFormFillOld.setUserId(studyFormFill.getUserId());
studyFormFillOld.setUserMc(studyFormFill.getUserMc());
this.updateById(studyFormFillOld);
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "更换归属人", JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null,null);
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "更换归属人", JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null, null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "更换归属人", qmr, studyFormFill.getRemark());
@ -261,7 +256,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public StudyFormFill bc(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
StudyFormFill result = null;
if (studyFormFill.getId() != null) {
StudyFormFill studyFormFillOld = this.queryInfo(studyFormFill.getId());
@ -286,7 +281,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
studyFormFillJcgjService.saveBatch(studyFormFillJcgjs);
}
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
} else {
studyFormFill.setBdzt(StudyFormFillBdztEnum.tbz.getValue());
studyFormFill.setUserId(SecurityUtils.getUserId());
@ -295,7 +290,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
this.save(studyFormFill);
result = studyFormFill;
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
}
//签名信息
@ -311,7 +306,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void tj(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getQmrmm());
if (studyFormFill.getId() != null) {
@ -339,7 +334,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
studyFormFillJcgjService.saveBatch(studyFormFillJcgjs);
}
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
} else {
studyFormFill.setBdzt(StudyFormFillBdztEnum.ytj.getValue());
studyFormFill.setUserId(SecurityUtils.getUserId());
@ -349,7 +344,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//生成物资
genResource(studyFormFill);
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
}
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(), "填写并提交记录", qmr, studyFormFill.getRemark());
@ -385,7 +380,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void gc(StudyFormFillGcForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, form.getQmrmm());
if (form.getId() == null || form.getId().longValue() < 0) {
@ -401,7 +396,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("生长情况", form.getQmyy());
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), form.getQmyy(), JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), form.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), form.getQmyy(), JcmcysEnum.orange.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), form.getRemark(), null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), form.getQmyy(), qmr, form.getRemark());
@ -415,7 +410,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void fhtg(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -432,7 +427,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
studyFormFillOld.setBdnr(studyFormFill.getBdnr());
this.updateById(studyFormFillOld);
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "复核通过", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "复核通过", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "复核通过", qmr, studyFormFill.getRemark());
}
@ -445,7 +440,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void fhjj(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -464,7 +459,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", studyFormFill.getRemark());
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "复核拒绝", JcmcysEnum.red.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null,null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "复核拒绝", JcmcysEnum.red.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null, null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "复核拒绝", qmr, studyFormFill.getRemark());
@ -478,7 +473,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void tg(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -497,7 +492,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", studyFormFill.getRemark());
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "免复核通过", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null,null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "免复核通过", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), null, null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "免复核通过", qmr, studyFormFill.getRemark());
@ -511,7 +506,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
*/
@Override
public void sy(StudyFormFill studyFormFill) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormFill.getQmrmm());
if (studyFormFill.getId() == null || studyFormFill.getId().longValue() < 0) {
@ -527,7 +522,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
studyFormFillOld.setBdnr(studyFormFill.getBdnr());
this.updateById(studyFormFillOld);
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(),null );
studyFormFillJcgjService.saveJcgj(studyFormFillOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), null, SecurityUtils.getLoginUser().getSysUser(), studyFormFill.getRemark(), null);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFillOld.getId(), "已审阅", qmr, studyFormFill.getRemark());
@ -550,52 +545,55 @@ public class StudyFormFillServiceImpl extends ServiceImpl
* 更新表单内容
*/
@Override
public void updateBdnr(StudyFormFillUpdateForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
public void updateBdnr(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//更新表单内容
StudyFormFill studyFormFillOld = this.queryInfo(form.getId());
studyFormFillOld.setBdnr(form.getBdnr());
studyFormFillOld.setZdxgjl(form.getZdxgjl());
this.updateById(studyFormFillOld);
// baseMapper.updateBdnr(form.getId(), form.getBdnr(),form.getZdxgjl());
// {"type":"fieldChanged","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0333","title":"修改记录","time":"2026-01-14 19:44:02"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0","title":"修改记录","time":"2026-01-14 19:43:57"}]}
// {"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","fieldCn":"试验基本信息-版本号",
// "fieldEn":"Test Basic Information-Version Number","oldValue":"2.0","value":"2.0333","title":"修改记录","time":"2026-01-15 19:51:46","reason":"555"}
//稽查轨迹 todo
JSONObject jsonObject=JSONObject.parseObject(form.getFiledValue());
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormFillJcgj> studyFormFillJcgjs = new ArrayList<>();
if(StringUtils.isNoneBlank(jsonObject.getString("oldValue"))){
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("原值", jsonObject.getString("oldValue"));
formData.put("新值", jsonObject.getString("value"));
formData.put("原因", jsonObject.getString("reason"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("原值", jsonObject.getString("oldValue"));
formDataEn.put("新值", jsonObject.getString("value"));
formDataEn.put("原因", jsonObject.getString("reason"));
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.xg.getValue(), "修改记录", JcmcysEnum.orange.getValue(), JSONObject.toJSONString(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
}else{
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("填入值", jsonObject.getString("value"));
formData.put("填写人", qmr.getNickName());
//en
formData.put("字段名", jsonObject.getString("fieldEn"));
formData.put("填入值", jsonObject.getString("value"));
formData.put("填写人", qmr.getNickName());
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "填写", JcmcysEnum.green.getValue(), JSONObject.toJSONString(formData), StudyFormUtil.getJcnrEn(formDataEn), null, null));
if (StringUtils.isNoneBlank(form.getFiledValue())) {
JSONObject jsonObject = JSONObject.parseObject(form.getFiledValue());
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormFillJcgj> studyFormFillJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(jsonObject.getString("oldValue"))) {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("原值", jsonObject.getString("oldValue"));
formData.put("新值", jsonObject.getString("value"));
formData.put("原因", jsonObject.getString("reason"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("原值", jsonObject.getString("oldValue"));
formDataEn.put("新值", jsonObject.getString("value"));
formDataEn.put("原因", jsonObject.getString("reason"));
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.xg.getValue(), "修改记录", JcmcysEnum.orange.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("填入值", jsonObject.getString("value"));
formData.put("填写人", qmr.getNickName());
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("填入值", jsonObject.getString("value"));
formDataEn.put("填写人", qmr.getNickName());
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "填写", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), null, null));
}
studyFormFillJcgjService.saveBatch(studyFormFillJcgjs);
}
studyFormFillJcgjService.saveBatch(studyFormFillJcgjs);
}
/**
* 更新复核意见
*/
@Override
public void updateFhyjjl(StudyFormFillUpdateForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
public void updateFhyjjl(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
// {"type":"reply","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
// {"type":"content","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
//更新复核意见 todo
@ -606,24 +604,24 @@ public class StudyFormFillServiceImpl extends ServiceImpl
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormFillJcgj> studyFormFillJcgjs = new ArrayList<>();
if(StringUtils.isNoneBlank(form.getContent())){
JSONObject jsonObject=JSONObject.parseObject(form.getContent());
if (StringUtils.isNoneBlank(form.getContent())) {
JSONObject jsonObject = JSONObject.parseObject(form.getContent());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("意见回复", jsonObject.getString("content"));
formData.put("意见回复", jsonObject.getString("content"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("意见回复", jsonObject.getString("content"));
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "意见回复", JcmcysEnum.blue.getValue(), JSONObject.toJSONString(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
}else{
JSONObject jsonObject=JSONObject.parseObject(form.getReplay());
formDataEn.put("意见回复", jsonObject.getString("content"));
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "意见回复", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
JSONObject jsonObject = JSONObject.parseObject(form.getReplay());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("复核意见", jsonObject.getString("content"));
formData.put("复核意见", jsonObject.getString("content"));
//en
formData.put("字段名", jsonObject.getString("fieldEn"));
formData.put("复核意见", jsonObject.getString("content"));
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "复核意见", JcmcysEnum.blue.getValue(), JSONObject.toJSONString(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
formData.put("复核意见", jsonObject.getString("content"));
studyFormFillJcgjs.add(studyFormFillJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "复核意见", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
}
studyFormFillJcgjService.saveBatch(studyFormFillJcgjs);
}
@ -632,7 +630,7 @@ public class StudyFormFillServiceImpl extends ServiceImpl
* 更新字段勾选记录
*/
@Override
public void updateZdgxjl(StudyFormFillUpdateForm form) {
public void updateZdgxjl(StudyFormUpdateForm form) {
//更新勾选记录 todo
StudyFormFill studyFormFillOld = this.queryInfo(form.getId());
studyFormFillOld.setZdxgjl(form.getZdgxjl());
@ -641,5 +639,4 @@ public class StudyFormFillServiceImpl extends ServiceImpl
}
}

+ 124
- 21
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormPlanServiceImpl.java View File

@ -2,22 +2,23 @@ package com.hxhq.business.service.impl;
import java.util.*;
import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.hxhq.business.domain.*;
import com.hxhq.business.domain.StudyFormPlan;
import com.hxhq.business.domain.StudyFormFillJcgj;
import com.hxhq.business.domain.StudyFormPlan;
import com.hxhq.business.domain.StudyFormPlanJcgj;
import com.hxhq.business.dto.study.StudyFormPlanListDto;
import com.hxhq.business.enums.study.StudyFormPlanBdztEnum;
import com.hxhq.business.enums.study.StudyFormPlanBdztEnum;
import com.hxhq.business.enums.zykgl.JcgjlxEnum;
import com.hxhq.business.enums.zykgl.JcmcysEnum;
import com.hxhq.business.form.study.StudyFormPlanSearchForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.service.IStudyFormPlanJcgjService;
import com.hxhq.business.service.IStudyFormPlanQmxxService;
import com.hxhq.business.utils.JctUtil;
import com.hxhq.business.utils.ObjectCompareUtil;
import com.hxhq.business.utils.StudyFormUtil;
import com.hxhq.common.core.exception.ServiceException;
import com.hxhq.common.core.utils.StringUtils;
import com.hxhq.common.security.utils.SecurityUtils;
@ -99,7 +100,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
*/
@Override
public void ghgsr(StudyFormPlan studyFormPlan) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormPlan.getQmrmm());
if (studyFormPlan.getId() == null || studyFormPlan.getId().longValue() < 0) {
@ -119,9 +120,9 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
formData.put("新归属人", studyFormPlan.getUserMc());
formData.put("原归属人", studyFormPlanOld.getUserMc());
formData.put("原因", studyFormPlan.getRemark());
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "更换归属人", JcmcysEnum.orange.getValue(), formData, qmr, null,null);
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "更换归属人", JcmcysEnum.orange.getValue(), formData, qmr, null, null);
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlanOld.getId(), "更换归属人", qmr, studyFormPlan.getRemark());
studyFormPlanQmxxService.saveQmxx(studyFormPlanOld.getId(), "更换归属人", qmr, studyFormPlan.getRemark());
}
@ -131,8 +132,9 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
* @param studyFormPlan
*/
@Override
public void bc(StudyFormPlan studyFormPlan) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
public StudyFormPlan bc(StudyFormPlan studyFormPlan) {
StudyFormPlan result = null;
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
if (studyFormPlan.getId() != null) {
StudyFormPlan studyFormPlanOld = this.queryInfo(studyFormPlan.getId());
if (studyFormPlanOld == null) {
@ -155,6 +157,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
}
studyFormPlanJcgjService.saveBatch(studyFormPlanJcgjs);
}
result = studyFormPlanOld;
} else {
studyFormPlan.setBdzt(StudyFormPlanBdztEnum.tbz.getValue());
studyFormPlan.setUserId(qmr.getUserId());
@ -164,11 +167,12 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注", studyFormPlan.getRemark());
studyFormPlanJcgjService.saveJcgj(studyFormPlan.getId(), JcgjlxEnum.lc.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), null,qmr,studyFormPlan.getRemark(),null);
studyFormPlanJcgjService.saveJcgj(studyFormPlan.getId(), JcgjlxEnum.lc.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), null, qmr, studyFormPlan.getRemark(), null);
result = studyFormPlan;
}
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlan.getId(), "填写并保存记录", qmr,studyFormPlan.getRemark());
studyFormPlanQmxxService.saveQmxx(studyFormPlan.getId(), "填写并保存记录", qmr, studyFormPlan.getRemark());
return result;
}
@ -179,7 +183,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
*/
@Override
public void tj(StudyFormPlan studyFormPlan) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormPlan.getQmrmm());
if (studyFormPlan.getId() == null) {
@ -193,9 +197,9 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注", studyFormPlan.getRemark());
studyFormPlanJcgjService.saveJcgj(studyFormPlan.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, qmr,studyFormPlan.getRemark(),null);
studyFormPlanJcgjService.saveJcgj(studyFormPlan.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), null, qmr, studyFormPlan.getRemark(), null);
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlan.getId(), "填写并提交记录", qmr,studyFormPlan.getRemark());
studyFormPlanQmxxService.saveQmxx(studyFormPlan.getId(), "填写并提交记录", qmr, studyFormPlan.getRemark());
}
@ -207,7 +211,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
*/
@Override
public void fhtg(StudyFormPlan studyFormPlan) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormPlan.getQmrmm());
if (studyFormPlan.getId() == null || studyFormPlan.getId().longValue() < 0) {
@ -223,9 +227,9 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
studyFormPlanOld.setBdzt(StudyFormPlanBdztEnum.ywcfh.getValue());
this.updateById(studyFormPlanOld);
//稽查轨迹
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "复核通过", JcmcysEnum.green.getValue(), null, qmr, studyFormPlan.getRemark(),null);
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "复核通过", JcmcysEnum.green.getValue(), null, qmr, studyFormPlan.getRemark(), null);
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlanOld.getId(), "复核通过", qmr,studyFormPlan.getRemark());
studyFormPlanQmxxService.saveQmxx(studyFormPlanOld.getId(), "复核通过", qmr, studyFormPlan.getRemark());
}
@ -236,7 +240,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
*/
@Override
public void fhjj(StudyFormPlan studyFormPlan) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormPlan.getQmrmm());
if (studyFormPlan.getId() == null || studyFormPlan.getId().longValue() < 0) {
@ -254,7 +258,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", studyFormPlan.getRemark());
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "复核拒绝", JcmcysEnum.red.getValue(), formData, qmr, null,null);
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "复核拒绝", JcmcysEnum.red.getValue(), formData, qmr, null, null);
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlanOld.getId(), "复核拒绝", qmr, studyFormPlan.getRemark());
@ -268,7 +272,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
*/
@Override
public void sy(StudyFormPlan studyFormPlan) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证签名人密码
checkPassword(qmr, studyFormPlan.getQmrmm());
if (studyFormPlan.getId() == null || studyFormPlan.getId().longValue() < 0) {
@ -284,7 +288,7 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
studyFormPlanOld.setBdnr(studyFormPlan.getBdnr());
this.updateById(studyFormPlanOld);
//稽查轨迹
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), null, qmr, studyFormPlan.getRemark(),null);
studyFormPlanJcgjService.saveJcgj(studyFormPlanOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), null, qmr, studyFormPlan.getRemark(), null);
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlanOld.getId(), "已审阅", qmr, studyFormPlan.getRemark());
@ -304,4 +308,103 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
sysUserService.checkPassword(user, qmrmm, false);
}
/**
* 更新表单内容
*/
@Override
public void updateBdnr(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//更新表单内容
StudyFormPlan studyFormPlanOld = this.queryInfo(form.getId());
studyFormPlanOld.setBdnr(form.getBdnr());
studyFormPlanOld.setZdxgjl(form.getZdxgjl());
this.updateById(studyFormPlanOld);
// baseMapper.updateBdnr(form.getId(), form.getBdnr(),form.getZdxgjl());
// {"type":"fieldChanged","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0333","title":"修改记录","time":"2026-01-14 19:44:02"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0","title":"修改记录","time":"2026-01-14 19:43:57"}]}
//稽查轨迹 todo
if (StringUtils.isNoneBlank(form.getFiledValue())) {
JSONObject jsonObject = JSONObject.parseObject(form.getFiledValue());
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormPlanJcgj> studyFormPlanJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(jsonObject.getString("oldValue"))) {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("原值", jsonObject.getString("oldValue"));
formData.put("新值", jsonObject.getString("value"));
formData.put("原因", jsonObject.getString("reason"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("原值", jsonObject.getString("oldValue"));
formDataEn.put("新值", jsonObject.getString("value"));
formDataEn.put("原因", jsonObject.getString("reason"));
studyFormPlanJcgjs.add(studyFormPlanJcgjService.getJcgj(form.getId(), JcgjlxEnum.xg.getValue(), "修改记录", JcmcysEnum.orange.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("填入值", jsonObject.getString("value"));
formData.put("填写人", qmr.getNickName());
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("填入值", jsonObject.getString("value"));
formDataEn.put("填写人", qmr.getNickName());
studyFormPlanJcgjs.add(studyFormPlanJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "填写", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), null, null));
}
studyFormPlanJcgjService.saveBatch(studyFormPlanJcgjs);
}
}
/**
* 更新复核意见
*/
@Override
public void updateFhyjjl(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
// {"type":"reply","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
// {"type":"content","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
//更新复核意见 todo
// baseMapper.updateFhyjjl(form.getId(), form.getFhyjjl());
StudyFormPlan studyFormPlanOld = this.queryInfo(form.getId());
studyFormPlanOld.setFhyjjl(form.getFhyjjl());
this.updateById(studyFormPlanOld);
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormPlanJcgj> studyFormPlanJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(form.getContent())) {
JSONObject jsonObject = JSONObject.parseObject(form.getContent());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("意见回复", jsonObject.getString("content"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("意见回复", jsonObject.getString("content"));
studyFormPlanJcgjs.add(studyFormPlanJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "意见回复", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
JSONObject jsonObject = JSONObject.parseObject(form.getReplay());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("复核意见", jsonObject.getString("content"));
//en
formData.put("字段名", jsonObject.getString("fieldEn"));
formData.put("复核意见", jsonObject.getString("content"));
studyFormPlanJcgjs.add(studyFormPlanJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "复核意见", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
}
studyFormPlanJcgjService.saveBatch(studyFormPlanJcgjs);
}
/**
* 更新字段勾选记录
*/
@Override
public void updateZdgxjl(StudyFormUpdateForm form) {
//更新勾选记录 todo
StudyFormPlan studyFormPlanOld = this.queryInfo(form.getId());
studyFormPlanOld.setZdxgjl(form.getZdgxjl());
this.updateById(studyFormPlanOld);
// baseMapper.updateZdgxjl(form.getId(), form.getZdgxjl());
}
}

+ 119
- 19
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormPreServiceImpl.java View File

@ -2,11 +2,10 @@ package com.hxhq.business.service.impl;
import java.util.*;
import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.hxhq.business.domain.StudyFormFill;
import com.hxhq.business.domain.StudyFormPlanJcgj;
import com.hxhq.business.domain.StudyFormPreJcgj;
import com.hxhq.business.domain.*;
import com.hxhq.business.dto.study.StudyFormPreListDto;
import com.hxhq.business.enums.NormalEnum;
import com.hxhq.business.enums.study.StudyFormPreBdztEnum;
@ -16,9 +15,11 @@ import com.hxhq.business.enums.zykgl.JcmcysEnum;
import com.hxhq.business.form.common.SignForm;
import com.hxhq.business.form.study.StudyFormPreAuditForm;
import com.hxhq.business.form.study.StudyFormPreSearchForm;
import com.hxhq.business.form.study.StudyFormUpdateForm;
import com.hxhq.business.service.*;
import com.hxhq.business.utils.JctUtil;
import com.hxhq.business.utils.ObjectCompareUtil;
import com.hxhq.business.utils.StudyFormUtil;
import com.hxhq.common.core.exception.ServiceException;
import com.hxhq.common.core.utils.StringUtils;
import com.hxhq.common.security.utils.SecurityUtils;
@ -27,7 +28,6 @@ import com.hxhq.system.service.ISysUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.hxhq.business.mapper.StudyFormPreMapper;
import com.hxhq.business.domain.StudyFormPre;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.web.bind.annotation.PostMapping;
@ -110,8 +110,9 @@ public class StudyFormPreServiceImpl extends ServiceImpl
* @param studyFormPre
*/
@Override
public void bc(StudyFormPre studyFormPre) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
public StudyFormPre bc(StudyFormPre studyFormPre) {
StudyFormPre result = null;
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
if (studyFormPre.getId() != null) {
StudyFormPre studyFormPreOld = this.getById(studyFormPre.getId());
if (studyFormPreOld == null) {
@ -133,6 +134,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
}
studyFormPreJcgjService.saveBatch(studyFormPreJcgjs);
}
result = studyFormPreOld;
} else {
studyFormPre.setBdbh("todo");
studyFormPre.setUserId(qmr.getUserId());
@ -141,11 +143,12 @@ public class StudyFormPreServiceImpl extends ServiceImpl
studyFormPre.setBdzt(StudyFormPreBdztEnum.tbz.getValue());
this.save(studyFormPre);
//稽查轨迹
studyFormPreJcgjService.saveJcgj(studyFormPre.getId(), JcgjlxEnum.lc.getValue(), "制作保存预制表单", JcmcysEnum.green.getValue(), null, qmr, studyFormPre.getRemark(),null);
studyFormPreJcgjService.saveJcgj(studyFormPre.getId(), JcgjlxEnum.lc.getValue(), "制作保存预制表单", JcmcysEnum.green.getValue(), null, qmr, studyFormPre.getRemark(), null);
result = studyFormPre;
}
//签名信息
studyFormPreQmxxService.saveQmxx(studyFormPre.getId(), "制作保存预制表单", qmr, studyFormPre.getRemark());
return result;
}
/**
@ -155,7 +158,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
*/
@Override
public void tj(StudyFormPre studyFormPre) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证密码
checkPassword(qmr, studyFormPre.getQmrmm());
if (studyFormPre.getId() != null) {
@ -180,7 +183,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注", studyFormPre.getRemark());
studyFormPreJcgjService.saveJcgj(studyFormPre.getId(), JcgjlxEnum.lc.getValue(), "制作提交预制表单", JcmcysEnum.green.getValue(), null, qmr, studyFormPre.getRemark(),null);
studyFormPreJcgjService.saveJcgj(studyFormPre.getId(), JcgjlxEnum.lc.getValue(), "制作提交预制表单", JcmcysEnum.green.getValue(), null, qmr, studyFormPre.getRemark(), null);
//签名信息
studyFormPreQmxxService.saveQmxx(studyFormPre.getId(), "制作提交预制表单", qmr, studyFormPre.getRemark());
@ -193,7 +196,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
*/
@Override
public void tg(StudyFormPreAuditForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证密码
checkPassword(qmr, form.getQmrmm());
StudyFormPre studyFormPreOld = this.getById(form.getId());
@ -210,7 +213,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
studyFormPreOld.setFzrshzt(StudyFormPreFzrshztEnum.ysh.getValue());
} else {
//权限审核
String yes="是";
String yes = "是";
if (studyFormPreOld.getFzrsh().equals(yes)) {
//是否需要负责人审核
studyFormPreOld.setFzrshzt(StudyFormPreFzrshztEnum.shz.getValue());
@ -220,7 +223,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
}
this.updateById(studyFormPreOld);
//稽查轨迹
studyFormPreJcgjService.saveJcgj(studyFormPreOld.getId(), JcgjlxEnum.lc.getValue(), "审核通过", JcmcysEnum.green.getValue(), null, qmr, form.getRemark(),null);
studyFormPreJcgjService.saveJcgj(studyFormPreOld.getId(), JcgjlxEnum.lc.getValue(), "审核通过", JcmcysEnum.green.getValue(), null, qmr, form.getRemark(), null);
//签名信息
studyFormPreQmxxService.saveQmxx(studyFormPreOld.getId(), "审核通过", qmr, form.getRemark());
}
@ -232,7 +235,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
*/
@Override
public void jj(StudyFormPreAuditForm form) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证密码
checkPassword(qmr, form.getQmrmm());
StudyFormPre studyFormPreOld = this.getById(form.getId());
@ -247,7 +250,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因", form.getRemark());
studyFormPreJcgjService.saveJcgj(studyFormPreOld.getId(), JcgjlxEnum.lc.getValue(), "审核拒绝", JcmcysEnum.red.getValue(), formData, qmr, null,null);
studyFormPreJcgjService.saveJcgj(studyFormPreOld.getId(), JcgjlxEnum.lc.getValue(), "审核拒绝", JcmcysEnum.red.getValue(), formData, qmr, null, null);
//签名信息
studyFormPreQmxxService.saveQmxx(studyFormPreOld.getId(), "审核拒绝", qmr, form.getRemark());
}
@ -259,7 +262,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
*/
@Override
public StudyFormFill tb(StudyFormPre studyFormPre) {
SysUser qmr=SecurityUtils.getLoginUser().getSysUser();
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//验证密码
checkPassword(qmr, studyFormPre.getQmrmm());
StudyFormPre studyFormPreOld = this.getById(studyFormPre.getId());
@ -269,9 +272,9 @@ public class StudyFormPreServiceImpl extends ServiceImpl
if (!studyFormPreOld.getBdzt().equals(StudyFormPreBdztEnum.ytg.getValue())) {
throw new ServiceException("不是已通过状态,不能填报");
}
Date time=new Date();
Date time = new Date();
//稽查轨迹
studyFormPreJcgjService.saveJcgj(studyFormPreOld.getId(), JcgjlxEnum.lc.getValue(), "创建记录", JcmcysEnum.green.getValue(), null, qmr, null,null);
studyFormPreJcgjService.saveJcgj(studyFormPreOld.getId(), JcgjlxEnum.lc.getValue(), "创建记录", JcmcysEnum.green.getValue(), null, qmr, null, null);
//签名信息
studyFormPreQmxxService.saveQmxx(studyFormPreOld.getId(), "创建记录", qmr, studyFormPre.getRemark());
//生成填报表单
@ -289,7 +292,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
studyFormFill.setTemplateId(studyFormPreOld.getTemplateId());
studyFormFillService.bc(studyFormFill);
//稽查轨迹
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.lc.getValue(), "创建记录", JcmcysEnum.green.getValue(), null, qmr, studyFormFill.getRemark(),time);
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.lc.getValue(), "创建记录", JcmcysEnum.green.getValue(), null, qmr, studyFormFill.getRemark(), time);
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(), "创建记录", qmr, studyFormFill.getRemark());
return studyFormFill;
@ -308,4 +311,101 @@ public class StudyFormPreServiceImpl extends ServiceImpl
sysUserService.checkPassword(user, qmrmm, false);
}
/**
* 更新表单内容
*/
@Override
public void updateBdnr(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
//更新表单内容
StudyFormPre studyFormPreOld = this.queryInfo(form.getId());
studyFormPreOld.setBdnr(form.getBdnr());
studyFormPreOld.setZdxgjl(form.getZdxgjl());
this.updateById(studyFormPreOld);
// baseMapper.updateBdnr(form.getId(), form.getBdnr(),form.getZdxgjl());
// {"type":"fieldChanged","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0333","title":"修改记录","time":"2026-01-14 19:44:02"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","oldValue":"1.0","value":"1.0","title":"修改记录","time":"2026-01-14 19:43:57"}]}
//稽查轨迹 todo
if (StringUtils.isNoneBlank(form.getFiledValue())) {
JSONObject jsonObject = JSONObject.parseObject(form.getFiledValue());
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormPreJcgj> studyFormPreJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(jsonObject.getString("oldValue"))) {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("原值", jsonObject.getString("oldValue"));
formData.put("新值", jsonObject.getString("value"));
formData.put("原因", jsonObject.getString("reason"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("原值", jsonObject.getString("oldValue"));
formDataEn.put("新值", jsonObject.getString("value"));
formDataEn.put("原因", jsonObject.getString("reason"));
studyFormPreJcgjs.add(studyFormPreJcgjService.getJcgj(form.getId(), JcgjlxEnum.xg.getValue(), "修改记录", JcmcysEnum.orange.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("填入值", jsonObject.getString("value"));
formData.put("填写人", qmr.getNickName());
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("填入值", jsonObject.getString("value"));
formDataEn.put("填写人", qmr.getNickName());
studyFormPreJcgjs.add(studyFormPreJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "填写", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), null, null));
}
studyFormPreJcgjService.saveBatch(studyFormPreJcgjs);
}
}
/**
* 更新复核意见
*/
@Override
public void updateFhyjjl(StudyFormUpdateForm form) {
SysUser qmr = SecurityUtils.getLoginUser().getSysUser();
// {"type":"reply","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
// {"type":"content","newRecord":{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},"resourceList":[{"userNameCn":"谭飞","userNameEn":"tf","key":"_versionNum","field":"试验基本信息-版本号","title":"复核意见","time":"2026-01-14 20:23:30","content":"qweqe"},{"userNameCn":"谭飞","userNameEn":"tf","key":"_methodCode","field":"试验基本信息-方法编号","title":"复核意见","time":"2026-01-14 20:23:28","content":"qweqw"}]}
//更新复核意见 todo
// baseMapper.updateFhyjjl(form.getId(), form.getFhyjjl());
StudyFormPre studyFormPreOld = this.queryInfo(form.getId());
studyFormPreOld.setFhyjjl(form.getFhyjjl());
this.updateById(studyFormPreOld);
Map<String, String> formData = new LinkedHashMap<>();
Map<String, String> formDataEn = new LinkedHashMap<>();
List<StudyFormPreJcgj> studyFormPreJcgjs = new ArrayList<>();
if (StringUtils.isNoneBlank(form.getContent())) {
JSONObject jsonObject = JSONObject.parseObject(form.getContent());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("意见回复", jsonObject.getString("content"));
//en
formDataEn.put("字段名", jsonObject.getString("fieldEn"));
formDataEn.put("意见回复", jsonObject.getString("content"));
studyFormPreJcgjs.add(studyFormPreJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "意见回复", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
} else {
JSONObject jsonObject = JSONObject.parseObject(form.getReplay());
//zh
formData.put("字段名", jsonObject.getString("fieldCn"));
formData.put("复核意见", jsonObject.getString("content"));
//en
formData.put("字段名", jsonObject.getString("fieldEn"));
formData.put("复核意见", jsonObject.getString("content"));
studyFormPreJcgjs.add(studyFormPreJcgjService.getJcgj(form.getId(), JcgjlxEnum.lc.getValue(), "复核意见", JcmcysEnum.blue.getValue(), JctUtil.formatStr(formData), StudyFormUtil.getJcnrEn(formDataEn), qmr, null));
}
studyFormPreJcgjService.saveBatch(studyFormPreJcgjs);
}
/**
* 更新字段勾选记录
*/
@Override
public void updateZdgxjl(StudyFormUpdateForm form) {
//更新勾选记录 todo
StudyFormPre studyFormPreOld = this.queryInfo(form.getId());
studyFormPreOld.setZdxgjl(form.getZdgxjl());
this.updateById(studyFormPreOld);
// baseMapper.updateZdgxjl(form.getId(), form.getZdgxjl());
}
}

+ 8
- 8
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/utils/GyzjJcnrUtil.java View File

@ -44,9 +44,9 @@ public class GyzjJcnrUtil {
mapJcnr.put("入库净重","Check-in Net Weight");
mapJcnr.put("入库量","Total Amount");
mapJcnr.put("目的","todo");
mapJcnr.put("申请备注","todo");
mapJcnr.put("审核备注","todo");
mapJcnr.put("目的","目的");
mapJcnr.put("申请备注","申请备注");
mapJcnr.put("审核备注","审核备注");
//endregion
//region 稽查名称
@ -69,11 +69,11 @@ public class GyzjJcnrUtil {
mapQmyy.put("确认归还","Confirm Check-in");
mapQmyy.put("领取发放","Distribution");
mapQmyy.put("锁定发放记录","todo");
mapQmyy.put("解锁发放记录","todo");
mapQmyy.put("给药制剂入库","todo");
mapQmyy.put("同意入库","todo");
mapQmyy.put("拒绝入库","todo");
mapQmyy.put("锁定发放记录","锁定发放记录");
mapQmyy.put("解锁发放记录","解锁发放记录");
mapQmyy.put("给药制剂入库","给药制剂入库");
mapQmyy.put("同意入库","同意入库");
mapQmyy.put("拒绝入库","拒绝入库");
//endregion

+ 10
- 9
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/utils/MjyJcnrUtil.java View File

@ -40,13 +40,13 @@ public class MjyJcnrUtil {
mapJcnr.put("库管员2","Warehouse Keeper 2");
mapJcnr.put("签名人1","Signed By 1");
mapJcnr.put("签名人2","Signed By 2");
mapJcnr.put("申请备注","Apply Comment");
mapJcnr.put("审核备注","Approve Comment");
mapJcnr.put("目的","todo");
mapJcnr.put("申请备注","todo");
mapJcnr.put("审核备注","todo");
mapJcnr.put("入库位置","todo");
mapJcnr.put("入库条件","todo");
mapJcnr.put("减少量","todo");
mapJcnr.put("目的","目的");
mapJcnr.put("入库位置","入库位置");
mapJcnr.put("入库条件","入库条件");
mapJcnr.put("减少量","减少量");
//endregion
@ -68,9 +68,10 @@ public class MjyJcnrUtil {
mapQmyy.put("拒绝修改库存","Reject Change Inventory");
mapQmyy.put("归还","Return");
mapQmyy.put("领取发放","Distribution");
mapQmyy.put("锁定发放记录","todo");
mapQmyy.put("解锁发放记录","todo");
mapQmyy.put("麻精药入库","todo");
mapQmyy.put("锁定发放记录","锁定发放记录");
mapQmyy.put("解锁发放记录","解锁发放记录");
mapQmyy.put("麻精药入库","麻精药入库");

+ 25
- 25
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/utils/StudyFormUtil.java View File

@ -25,10 +25,10 @@ public class StudyFormUtil {
mapJcnr.put("新归属人","New Owner");
mapJcnr.put("原归属人","Old Owner");
mapJcnr.put("填入值","todo");
mapJcnr.put("填写人","todo");
mapJcnr.put("意见回复","todo");
mapJcnr.put("复核意见","todo");
mapJcnr.put("填入值","填入值");
mapJcnr.put("填写人","填写人");
mapJcnr.put("意见回复","意见回复");
mapJcnr.put("复核意见","复核意见");
//endregion
//region 稽查名称
@ -38,27 +38,27 @@ public class StudyFormUtil {
mapQmyy.put("差","Bad");
mapQmyy.put("修改","Edit");
mapQmyy.put("修改记录","todo");
mapQmyy.put("填写","todo");
mapQmyy.put("意见回复","todo");
mapQmyy.put("复核意见","todo");
mapQmyy.put("免复核通过","todo");
mapQmyy.put("复核拒绝","todo");
mapQmyy.put("复核通过","todo");
mapQmyy.put("填写并提交记录","todo");
mapQmyy.put("废止拒绝","todo");
mapQmyy.put("废止通过","todo");
mapQmyy.put("申请废止","todo");
mapQmyy.put("开始现场复核","todo");
mapQmyy.put("结束现场复核","todo");
mapQmyy.put("申明协作","todo");
mapQmyy.put("已审阅","todo");
mapQmyy.put("审核通过","todo");
mapQmyy.put("补充说明","todo");
mapQmyy.put("审核拒绝","todo");
mapQmyy.put("制作保存预制表单","todo");
mapQmyy.put("制作提交预制表单","todo");
mapQmyy.put("创建记录","todo");
mapQmyy.put("修改记录","修改记录");
mapQmyy.put("填写","填写");
mapQmyy.put("意见回复","意见回复");
mapQmyy.put("复核意见","复核意见");
mapQmyy.put("免复核通过","免复核通过");
mapQmyy.put("复核拒绝","复核拒绝");
mapQmyy.put("复核通过","复核通过");
mapQmyy.put("填写并提交记录","填写并提交记录");
mapQmyy.put("废止拒绝","废止拒绝");
mapQmyy.put("废止通过","废止通过");
mapQmyy.put("申请废止","申请废止");
mapQmyy.put("开始现场复核","开始现场复核");
mapQmyy.put("结束现场复核","结束现场复核");
mapQmyy.put("申明协作","申明协作");
mapQmyy.put("已审阅","已审阅");
mapQmyy.put("审核通过","审核通过");
mapQmyy.put("补充说明","补充说明");
mapQmyy.put("审核拒绝","审核拒绝");
mapQmyy.put("制作保存预制表单","制作保存预制表单");
mapQmyy.put("制作提交预制表单","制作提交预制表单");
mapQmyy.put("创建记录","创建记录");
//endregion

Loading…
Cancel
Save