入伍保留学籍、外宿申请-审批人修改成电子签名
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.srs.flowable.domain;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.srs.common.annotation.Excel;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
@@ -10,7 +11,6 @@ import lombok.*;
|
||||
import com.srs.common.core.domain.BaseEntity;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 保留学籍审批记录对象 rt_enlistment_reserve_approval
|
||||
*
|
||||
@@ -22,10 +22,10 @@ import com.srs.common.core.domain.BaseEntity;
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Builder
|
||||
@ApiModel(value = "RtEnlistmentReserveApproval对象" , description = "保留学籍审批记录")
|
||||
@ApiModel(value = "RtEnlistmentReserveApproval对象", description = "保留学籍审批记录")
|
||||
@TableName("rt_enlistment_reserve_approval")
|
||||
public class EnlistmentReserveApproval extends BaseEntity{
|
||||
private static final long serialVersionUID=1L;
|
||||
public class EnlistmentReserveApproval extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键
|
||||
@@ -63,7 +63,7 @@ public class EnlistmentReserveApproval extends BaseEntity{
|
||||
*/
|
||||
@ApiModelProperty("审批节点(辅导员/学务等)")
|
||||
@TableField("node_name")
|
||||
@Excel(name = "审批节点" , readConverterExp = "辅=导员/学务等")
|
||||
@Excel(name = "审批节点", readConverterExp = "辅=导员/学务等")
|
||||
private String nodeName;
|
||||
|
||||
/**
|
||||
@@ -71,7 +71,7 @@ public class EnlistmentReserveApproval extends BaseEntity{
|
||||
*/
|
||||
@ApiModelProperty("审批人ID(关联sys_user)")
|
||||
@TableField("approver_id")
|
||||
@Excel(name = "审批人ID" , readConverterExp = "关=联sys_user")
|
||||
@Excel(name = "审批人ID", readConverterExp = "关=联sys_user")
|
||||
private Long approverId;
|
||||
|
||||
/**
|
||||
@@ -95,7 +95,7 @@ public class EnlistmentReserveApproval extends BaseEntity{
|
||||
*/
|
||||
@ApiModelProperty("审批结果(1-通过")
|
||||
@TableField("approval_result")
|
||||
@Excel(name = "审批结果" , readConverterExp = "审批结果(1-通过")
|
||||
@Excel(name = "审批结果", readConverterExp = "审批结果(1-通过")
|
||||
private Long approvalResult;
|
||||
|
||||
/**
|
||||
@@ -104,7 +104,7 @@ public class EnlistmentReserveApproval extends BaseEntity{
|
||||
@ApiModelProperty("审批时间")
|
||||
@TableField("approval_time")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "审批时间" , width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@Excel(name = "审批时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date approvalTime;
|
||||
|
||||
/**
|
||||
@@ -123,5 +123,12 @@ public class EnlistmentReserveApproval extends BaseEntity{
|
||||
@Excel(name = "学号")
|
||||
private String studentNo;
|
||||
|
||||
/**
|
||||
* 签名
|
||||
*/
|
||||
@ApiModelProperty("签名")
|
||||
@TableField("signature")
|
||||
@Excel(name = "签名")
|
||||
private String signature;
|
||||
|
||||
}
|
||||
|
||||
@@ -14,7 +14,6 @@ import lombok.*;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 外宿申请审批记录对象 dms_outside_accommodation_approval
|
||||
*
|
||||
@@ -26,10 +25,10 @@ import java.util.Date;
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Builder
|
||||
@ApiModel(value = "DmsOutsideAccommodationApproval对象" , description = "外宿申请审批记录表")
|
||||
@ApiModel(value = "DmsOutsideAccommodationApproval对象", description = "外宿申请审批记录表")
|
||||
@TableName("dms_outside_accommodation_approval")
|
||||
public class OutsideAccommodationApproval extends BaseEntity{
|
||||
private static final long serialVersionUID=1L;
|
||||
public class OutsideAccommodationApproval extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
@@ -43,7 +42,7 @@ private static final long serialVersionUID=1L;
|
||||
*/
|
||||
@ApiModelProperty("外宿申请ID(关联申请表)")
|
||||
@TableField("apply_id")
|
||||
@Excel(name = "外宿申请ID" , readConverterExp = "关=联申请表")
|
||||
@Excel(name = "外宿申请ID", readConverterExp = "关=联申请表")
|
||||
private Long applyId;
|
||||
|
||||
/**
|
||||
@@ -99,7 +98,7 @@ private static final long serialVersionUID=1L;
|
||||
*/
|
||||
@ApiModelProperty("审批结果(1=同意,0=驳回)")
|
||||
@TableField("approval_result")
|
||||
@Excel(name = "审批结果" , readConverterExp = "1==同意,0=驳回")
|
||||
@Excel(name = "审批结果", readConverterExp = "1==同意,0=驳回")
|
||||
private Long approvalResult;
|
||||
|
||||
/**
|
||||
@@ -108,7 +107,7 @@ private static final long serialVersionUID=1L;
|
||||
@ApiModelProperty("审批时间")
|
||||
@TableField("approval_time")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "审批时间" , width = 30, dateFormat = "yyyy-MM-dd")
|
||||
@Excel(name = "审批时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date approvalTime;
|
||||
|
||||
/**
|
||||
@@ -136,4 +135,12 @@ private static final long serialVersionUID=1L;
|
||||
private String studentNo;
|
||||
|
||||
|
||||
/**
|
||||
* 签名
|
||||
*/
|
||||
@ApiModelProperty("签名")
|
||||
@TableField("signature")
|
||||
@Excel(name = "签名")
|
||||
private String signature;
|
||||
|
||||
}
|
||||
|
||||
@@ -61,6 +61,9 @@ public class ApprovalAssigneeListener implements ExecutionListener {
|
||||
// 获取审核意见
|
||||
String approvalOpinion = (String) execution.getVariable("approvalOpinion");
|
||||
|
||||
// 获取签名
|
||||
String signature = (String) execution.getVariable("signature");
|
||||
|
||||
// 获取审核状态(兼容Integer/Long类型)
|
||||
Object approvalResultObj = execution.getVariable("approvalResult");
|
||||
Long approvalResult = null;
|
||||
@@ -74,7 +77,7 @@ public class ApprovalAssigneeListener implements ExecutionListener {
|
||||
// 根据Id查询入伍申请记录
|
||||
EnlistmentReserve enlistmentReserve = rtEnlistmentReserveMapper.selectRtEnlistmentReserveById(enlistmentId);
|
||||
// 添加审批记录
|
||||
saveApprovalRecord(enlistmentReserve.getId(), enlistmentReserve.getProcessInstanceId(),currentActivityId,currentNodeName, enlistmentReserve.getStudentName(), enlistmentReserve.getStudentNo(), approvalOpinion, approvalResult);
|
||||
saveApprovalRecord(enlistmentReserve.getId(), enlistmentReserve.getProcessInstanceId(),currentActivityId,currentNodeName, enlistmentReserve.getStudentName(), enlistmentReserve.getStudentNo(), approvalOpinion, approvalResult, signature);
|
||||
|
||||
Long status = 1L;
|
||||
if (currentNodeName.equals("辅导员审批")) {
|
||||
@@ -120,7 +123,7 @@ public class ApprovalAssigneeListener implements ExecutionListener {
|
||||
/**
|
||||
* 通用审批记录保存方法
|
||||
*/
|
||||
private void saveApprovalRecord(Long ApplyId,String processInstanceId, String taskId, String nodeName, String studentName, String studentNo, String approvalOpinion, Long approvalResult) {
|
||||
private void saveApprovalRecord(Long ApplyId,String processInstanceId, String taskId, String nodeName, String studentName, String studentNo, String approvalOpinion, Long approvalResult, String signature) {
|
||||
EnlistmentReserveApproval enlistmentReserveApproval = new EnlistmentReserveApproval();
|
||||
// 赋值
|
||||
enlistmentReserveApproval.setApplyId(ApplyId);
|
||||
@@ -141,7 +144,9 @@ public class ApprovalAssigneeListener implements ExecutionListener {
|
||||
enlistmentReserveApproval.setApprovalTime(new Date());
|
||||
enlistmentReserveApproval.setStudentName(studentName);
|
||||
enlistmentReserveApproval.setStudentNo(studentNo);
|
||||
System.out.println(SecurityUtils.getLoginUser().getUser());
|
||||
// System.out.println(SecurityUtils.getLoginUser().getUser());
|
||||
// 设置签名
|
||||
enlistmentReserveApproval.setSignature(signature);
|
||||
EnlistmentReserveApprovalMapper rtEnlistmentReserveApprovalMapper = (EnlistmentReserveApprovalMapper) SpringUtils.getBean(EnlistmentReserveApprovalMapper.class);
|
||||
// 查询审批记录是否存在
|
||||
EnlistmentReserveApproval enlistmentReserveApproval1 = rtEnlistmentReserveApprovalMapper.selectRtEnlistmentReserveApprovalByStuName(studentName, studentNo, SecurityUtils.getLoginUser().getUser().getUserId());
|
||||
|
||||
@@ -48,6 +48,9 @@ public class OutsideAccommodationEndListener implements ExecutionListener {
|
||||
// 获取审核意见
|
||||
String approvalOpinion = (String) execution.getVariable("approvalOpinion");
|
||||
|
||||
// 获取签名
|
||||
String signature = (String) execution.getVariable("signature");
|
||||
|
||||
// 获取审核状态(兼容Integer/Long类型)
|
||||
Object approvalResultObj = execution.getVariable("approvalResult");
|
||||
Long approvalResult = null;
|
||||
@@ -62,7 +65,7 @@ public class OutsideAccommodationEndListener implements ExecutionListener {
|
||||
// 根据Id查询外宿申请记录
|
||||
OutsideAccommodationApply outsideAccommodationApply = outsideAccommodationApplyMapper.selectDmsOutsideAccommodationApplyById(accommodationId);
|
||||
// 添加审批记录
|
||||
saveApprovalRecord(outsideAccommodationApply.getId(), outsideAccommodationApply.getProcessInstanceId(),outsideAccommodationApply.getApplyNo(),currentNodeName, outsideAccommodationApply.getStudentName(), outsideAccommodationApply.getStudentNo(), approvalOpinion, approvalResult);
|
||||
saveApprovalRecord(outsideAccommodationApply.getId(), outsideAccommodationApply.getProcessInstanceId(),outsideAccommodationApply.getApplyNo(),currentNodeName, outsideAccommodationApply.getStudentName(), outsideAccommodationApply.getStudentNo(), approvalOpinion, approvalResult, signature);
|
||||
Long status = 1L;
|
||||
if (currentNodeName.equals("辅导员审批")) {
|
||||
status = 2L;
|
||||
@@ -105,7 +108,7 @@ public class OutsideAccommodationEndListener implements ExecutionListener {
|
||||
/**
|
||||
* 通用审批记录保存方法
|
||||
*/
|
||||
private void saveApprovalRecord(Long ApplyId,String processInstanceId, String applyNo, String nodeName, String studentName, String studentNo, String approvalOpinion, Long approvalResult) {
|
||||
private void saveApprovalRecord(Long ApplyId,String processInstanceId, String applyNo, String nodeName, String studentName, String studentNo, String approvalOpinion, Long approvalResult, String signature) {
|
||||
OutsideAccommodationApproval outsideAccommodationApproval = new OutsideAccommodationApproval();
|
||||
// 赋值
|
||||
outsideAccommodationApproval.setApplyId(ApplyId);
|
||||
@@ -126,6 +129,8 @@ public class OutsideAccommodationEndListener implements ExecutionListener {
|
||||
outsideAccommodationApproval.setApprovalTime(new Date());
|
||||
outsideAccommodationApproval.setStudentName(studentName);
|
||||
outsideAccommodationApproval.setStudentNo(studentNo);
|
||||
// 设置签名
|
||||
outsideAccommodationApproval.setSignature(signature);
|
||||
OutsideAccommodationApprovalMapper outsideAccommodationApprovalMapper = (OutsideAccommodationApprovalMapper) SpringUtils.getBean(OutsideAccommodationApprovalMapper.class);
|
||||
// 查询审批记录是否存在
|
||||
OutsideAccommodationApproval approval = outsideAccommodationApprovalMapper.selectOutsideAccommodationApprovalByStuName(studentName, studentNo, SecurityUtils.getLoginUser().getUser().getUserId());
|
||||
|
||||
Reference in New Issue
Block a user