Browse Source

fix:[麻精药表单][申请单管理]

master
15881625488@163.com 4 days ago
parent
commit
4937c6af2d
10 changed files with 117 additions and 87 deletions
  1. +20
    -22
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormApplyController.java
  2. +1
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormApply.java
  3. +1
    -1
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/domain/StudyFormPre.java
  4. +8
    -3
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/enums/study/StudyFormApplyBdztEnum.java
  5. +7
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/enums/study/StudyFormPreBdztEnum.java
  6. +11
    -14
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/IStudyFormApplyService.java
  7. +62
    -37
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormApplyServiceImpl.java
  8. +2
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormFillServiceImpl.java
  9. +2
    -2
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormPlanServiceImpl.java
  10. +3
    -3
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/StudyFormPreServiceImpl.java

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

@ -141,17 +141,6 @@ public class StudyFormApplyController extends BaseController {
/**
* 观察
*/
@RequiresPermissions("business:drugFormApply:gc")
@PostMapping("/gc")
public AjaxResult gc(@RequestBody StudyFormApplyGcForm form) {
studyFormApplyService.gc(form);
return AjaxResult.success("操作成功");
}
/**
* 复核通过
*/
@RequiresPermissions("business:drugFormApply:fh")
@ -161,7 +150,6 @@ public class StudyFormApplyController extends BaseController {
return AjaxResult.success("操作成功");
}
/**
* 复核拒绝
*/
@ -173,16 +161,6 @@ public class StudyFormApplyController extends BaseController {
}
/**
* 通过
*/
@RequiresPermissions("business:drugFormApply:fh")
@PostMapping("/tg")
public AjaxResult tg(@RequestBody StudyFormApply studyFormApply) {
studyFormApplyService.tg(studyFormApply);
return AjaxResult.success("操作成功");
}
/**
* 审阅
*/
@RequiresPermissions("business:drugFormApply:sy")
@ -191,4 +169,24 @@ public class StudyFormApplyController extends BaseController {
studyFormApplyService.sy(studyFormApply);
return AjaxResult.success("操作成功");
}
/**
* 审核通过
*/
@RequiresPermissions("business:drugFormApply:sh")
@PostMapping("/shtg")
public AjaxResult shtg(@RequestBody StudyFormApply studyFormApply) {
studyFormApplyService.shtg(studyFormApply);
return AjaxResult.success("操作成功");
}
/**
* 审核拒绝
*/
@RequiresPermissions("business:drugFormApply:sh")
@PostMapping("/shjj")
public AjaxResult shjj(@RequestBody StudyFormApply studyFormApply) {
studyFormApplyService.shjj(studyFormApply);
return AjaxResult.success("操作成功");
}
}

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

@ -53,7 +53,7 @@ public class StudyFormApply extends MpBaseEntity
@Compare(name = "是否补录")
private Integer sfbl;
/** 表单状态:1:填报中;3:已提交;5:已完成(经复核);7:已完成;9:待废止;11:已废止 */
/** 表单状态:1:填报中;3:已提交;5:已复核;6:未通过;7:已完成;9:待废止;11:已废止 */
private Integer bdzt;
/** 提交时间 */

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

@ -50,7 +50,7 @@ public class StudyFormPre extends MpBaseEntity
/** 表单归属人名称 */
private String userMc;
/** 表单状态:1:填报中;3:已提交;5:已通过 */
/** 表单状态:1:填报中;3:已提交;5:已通过;7:未通过 */
private Integer bdzt;
/** 是否需要负责人审核:1:否;10:是 */

+ 8
- 3
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/enums/study/StudyFormApplyBdztEnum.java View File

@ -1,7 +1,7 @@
package com.hxhq.business.enums.study;
/**
* 表单状态1填报中3已提交5完成经复核7已完成9待废止11已废止
* 表单状态1填报中3已提交5复核6未通过7已完成9待废止11已废止
* @author tanfei
*/
public enum StudyFormApplyBdztEnum {
@ -17,9 +17,14 @@ public enum StudyFormApplyBdztEnum {
ytj(3, "已提交"),
/**
* 完成复核
* 已复核
*/
ywcfh(5, "已完成(经复核)"),
yfh(5, "已复核"),
/**
* 未通过
*/
wtg(6, "未通过"),
/**
* 已完成

+ 7
- 2
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/enums/study/StudyFormPreBdztEnum.java View File

@ -1,7 +1,7 @@
package com.hxhq.business.enums.study;
/**
* 表单状态1填报中3已提交5已通过
* 表单状态1填报中3已提交5已通过7未通过
* @author tanfei
*/
public enum StudyFormPreBdztEnum {
@ -19,7 +19,12 @@ public enum StudyFormPreBdztEnum {
/**
* 已通过
*/
ytg(5, "已通过");
ytg(5, "已通过"),
/**
* 未通过
*/
wtg(7, "未通过");
private int value;
private String text;

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

@ -65,28 +65,18 @@ public interface IStudyFormApplyService extends IService
*/
public void bc(StudyFormApply studyFormApply);
/**
* 提交
* @param studyFormApply
*/
public void tj(StudyFormApply studyFormApply);
/**
* 观察
* @param form
*/
public void gc(StudyFormApplyGcForm form);
/**
* 复核通过
* @param studyFormApply
*/
public void fhtg(StudyFormApply studyFormApply);
/**
* 复核拒绝
* @param studyFormApply
@ -94,14 +84,21 @@ public interface IStudyFormApplyService extends IService
public void fhjj(StudyFormApply studyFormApply);
/**
* 通过
* 审阅
* @param studyFormApply
*/
public void tg(StudyFormApply studyFormApply);
public void sy(StudyFormApply studyFormApply);
/**
*
* 核通过
* @param studyFormApply
*/
public void sy(StudyFormApply studyFormApply);
public void shtg(StudyFormApply studyFormApply);
/**
* 审核拒绝
* @param studyFormApply
*/
public void shjj(StudyFormApply studyFormApply);
}

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

@ -291,11 +291,11 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注",studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApply.getId(), JcgjlxEnum.bj.getValue(), "填写并保存", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
studyFormApplyJcgjService.saveJcgj(studyFormApply.getId(), JcgjlxEnum.bj.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
}
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(),"填写并保存",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApply.getId(),"填写并保存记录",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
}
@ -307,39 +307,34 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
*/
@Override
public void tj(StudyFormApply studyFormApply) {
//todo
}
/**
* 观察
*
* @param form
*/
@Override
public void gc(StudyFormApplyGcForm form) {
//验证签名人密码 todo
if (form.getId() == null || form.getId().longValue() < 0) {
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
throw new ServiceException("参数id不正确");
}
StudyFormApply studyFormApplyOld = this.getById(form.getId());
StudyFormApply studyFormApplyOld = this.getById(studyFormApply.getId());
if (studyFormApplyOld == null) {
throw new ServiceException("表单不存在或已删除");
}
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.tbz.getValue())) {
throw new ServiceException("表单不是申请状态,不能观察");
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.tbz.getValue()) ) {
throw new ServiceException("表单不是填报中状态,不能审核");
}
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.ytj.getValue());
studyFormApplyOld.setBdnr(studyFormApply.getBdnr());
studyFormApplyOld.setBdmc(studyFormApply.getBdmc());
studyFormApplyOld.setBdsm(studyFormApply.getBdsm());
this.updateById(studyFormApplyOld);
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("生长情况",form.getQmyy());
formData.put("备注",form.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), form.getQmyy(), JcmcysEnum.orange.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
formData.put("备注",studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "填写并提交记录", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),form.getQmyy(),SecurityUtils.getUserId(),SecurityUtils.getNickName(),form.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),"填写并提交记录",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
}
/**
* 复核通过
*
@ -358,7 +353,7 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.ytj.getValue()) ) {
throw new ServiceException("表单不是已提交状态,不能复核");
}
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.ywcfh.getValue());
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.yfh.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
@ -399,12 +394,12 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
}
/**
* 通过
* 审阅
*
* @param studyFormApply
*/
@Override
public void tg(StudyFormApply studyFormApply) {
public void sy(StudyFormApply studyFormApply) {
//验证签名人密码 todo
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
throw new ServiceException("参数id不正确");
@ -413,27 +408,26 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
if (studyFormApplyOld == null) {
throw new ServiceException("表单不存在或已删除");
}
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.ytj.getValue()) ) {
throw new ServiceException("表单不是已提交状态,不能复核");
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.ywc.getValue())) {
throw new ServiceException("表单不是已完成状态,不能审阅");
}
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.ywc.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因",studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "免复核通过", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
formData.put("备注",studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),"免复核通过",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),"已审阅",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
}
/**
*
* 核通过
*
* @param studyFormApply
*/
@Override
public void sy(StudyFormApply studyFormApply) {
public void shtg(StudyFormApply studyFormApply) {
//验证签名人密码 todo
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
throw new ServiceException("参数id不正确");
@ -442,15 +436,46 @@ public class StudyFormApplyServiceImpl extends ServiceImpl
if (studyFormApplyOld == null) {
throw new ServiceException("表单不存在或已删除");
}
if (!(studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.ywcfh.getValue())||studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.ywc.getValue())) ) {
throw new ServiceException("表单不是已完成状态,不能审阅");
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.yfh.getValue()) ) {
throw new ServiceException("表单不是已复核状态,不能审核");
}
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.ywc.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注",studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "已审阅", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "审核通过", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),"已审阅",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),"审核通过",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
}
/**
* 审核拒绝
*
* @param studyFormApply
*/
@Override
public void shjj(StudyFormApply studyFormApply) {
//验证签名人密码 todo
if (studyFormApply.getId() == null || studyFormApply.getId().longValue() < 0) {
throw new ServiceException("参数id不正确");
}
StudyFormApply studyFormApplyOld = this.getById(studyFormApply.getId());
if (studyFormApplyOld == null) {
throw new ServiceException("表单不存在或已删除");
}
if (!studyFormApplyOld.getBdzt().equals(StudyFormApplyBdztEnum.yfh.getValue()) ) {
throw new ServiceException("表单不是已复核状态,不能审核");
}
studyFormApplyOld.setBdzt(StudyFormApplyBdztEnum.wtg.getValue());
this.updateById(studyFormApplyOld);
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("原因",studyFormApply.getRemark());
studyFormApplyJcgjService.saveJcgj(studyFormApplyOld.getId(), JcgjlxEnum.lc.getValue(), "审核拒绝", JcmcysEnum.red.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
//签名信息
studyFormApplyQmxxService.saveQmxx(studyFormApplyOld.getId(),"审核拒绝",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormApply.getRemark());
}

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

@ -292,11 +292,11 @@ public class StudyFormFillServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注",studyFormFill.getRemark());
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.bj.getValue(), "填写并保存", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
studyFormFillJcgjService.saveJcgj(studyFormFill.getId(), JcgjlxEnum.bj.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
}
//签名信息
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(),"填写并保存",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormFill.getRemark());
studyFormFillQmxxService.saveQmxx(studyFormFill.getId(),"填写并保存记录",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormFill.getRemark());
}

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

@ -168,11 +168,11 @@ public class StudyFormPlanServiceImpl extends ServiceImpl
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();
formData.put("备注",studyFormPlan.getRemark());
studyFormPlanJcgjService.saveJcgj(studyFormPlan.getId(), JcgjlxEnum.bj.getValue(), "填写并保存", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
studyFormPlanJcgjService.saveJcgj(studyFormPlan.getId(), JcgjlxEnum.bj.getValue(), "填写并保存记录", JcmcysEnum.green.getValue(), JctUtil.formatStr(formData), SecurityUtils.getUserId(), SecurityUtils.getNickName());
}
//签名信息
studyFormPlanQmxxService.saveQmxx(studyFormPlan.getId(),"填写并保存",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormPlan.getRemark());
studyFormPlanQmxxService.saveQmxx(studyFormPlan.getId(),"填写并保存记录",SecurityUtils.getUserId(),SecurityUtils.getNickName(),studyFormPlan.getRemark());
}

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

@ -200,7 +200,7 @@ public class StudyFormPreServiceImpl extends ServiceImpl
throw new ServiceException("信息不存在或已删除");
}
if(!studyFormPreOld.getBdzt().equals(StudyFormPreBdztEnum.ytj.getValue())){
throw new ServiceException("不是填报状态,不能审核");
throw new ServiceException("不是已提交状态,不能审核");
}
//负责人审核
@ -237,9 +237,9 @@ public class StudyFormPreServiceImpl extends ServiceImpl
throw new ServiceException("信息不存在或已删除");
}
if(!studyFormPreOld.getBdzt().equals(StudyFormPreBdztEnum.ytj.getValue())){
throw new ServiceException("不是填报状态,不能审核");
throw new ServiceException("不是已提交状态,不能审核");
}
studyFormPreOld.setBdzt(StudyFormPreBdztEnum.tbz.getValue());
studyFormPreOld.setBdzt(StudyFormPreBdztEnum.wtg.getValue());
this.updateById(studyFormPreOld);
//稽查轨迹
Map<String, String> formData = new LinkedHashMap<>();

Loading…
Cancel
Save