This commit is contained in:
wangliwen 2022-04-26 17:52:18 +08:00
parent e0c38aca8e
commit d533df53c0
11 changed files with 402 additions and 391 deletions

View File

@ -47,7 +47,8 @@ public class TDemandDataController {
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataType = "String"),
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataType = "String"),
@ApiImplicitParam(name = "creator", value = "创建者id", paramType = "query", dataType = "Long"),
@ApiImplicitParam(name = "flag", value = "状态", paramType = "query", dataType = "Int")
@ApiImplicitParam(name = "flag", value = "状态", paramType = "query", dataType = "Int"),
@ApiImplicitParam(name = "detailsType", value = "需求类型", paramType = "query", dataType = "String")
})
// @RequiresPermissions("demanData:tdemanddata:page")
public Result<PageData<TDemandDataDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params) {

View File

@ -63,7 +63,7 @@ public class DemandDataListener implements TaskListener, ExecutionListener, Acti
@Override
public void notify(DelegateTask delegateTask) {
logger.error("----------------------进入能力需求受理者1节点---------------------------");
logger.info("事件类型:" + delegateTask.getEventName());
logger.error("事件类型:" + delegateTask.getEventName());
SysRoleDTO roleDTO = sysRoleService.getByName(roleName);
logger.error("roleDTOId:" + roleDTO.getId());
final String eventName = delegateTask.getEventName();
@ -75,7 +75,7 @@ public class DemandDataListener implements TaskListener, ExecutionListener, Acti
complete(delegateTask);
break;
default:
logger.info("未处理该事件:" + eventName);
logger.error("未处理该事件:" + eventName);
}
logger.error("----------------------结束能力需求受理者1节点---------------------------");
}
@ -114,7 +114,7 @@ public class DemandDataListener implements TaskListener, ExecutionListener, Acti
TDemandDataDTO demandDataDTO = gson.fromJson(jsonElement, TDemandDataDTO.class);
if (demandDataDTO != null) {
logger.info(JSONObject.toJSONString(demandDataDTO));
logger.error(JSONObject.toJSONString(demandDataDTO));
SysDeptDTO deptDTO =
sysDeptService.get(Long.valueOf(demandDataDTO.getApplyUserDeptId()));
SysUserDTO userDTO = null;
@ -129,25 +129,24 @@ public class DemandDataListener implements TaskListener, ExecutionListener, Acti
taskService.setAssignee(delegateTask.getId(), "1513432847327199233");
}
} else { // 填入大数据审批人
logger.info("大数据局名称:" + bigDateDeptName);
logger.error("大数据局名称:" + bigDateDeptName);
SysDeptDTO deptDTO = sysDeptService.getByName(bigDateDeptName);
logger.info("roleDTOId:" + roleDTO.getId());
logger.error("roleDTOId:" + roleDTO.getId());
SysUserDTO userDTO = sysUserService.getByDeptIdAndRoleId(deptDTO.getId(), roleDTO.getId());
if (userDTO != null) {
logger.info("大数据审批人id:" + userDTO.getId());
logger.error("大数据审批人id:" + userDTO.getId());
taskService.setAssignee(delegateTask.getId(), userDTO.getId().toString());
} else {
taskService.setAssignee(delegateTask.getId(), "1513432847327199233");
logger.info("未查到大数据部门对应 " + roleName);
logger.error("未查到大数据部门对应 " + roleName);
}
}
}
private void complete(DelegateTask delegateTask) {
logger.info("---------------------------流程节点完成---------------------------------");
logger.error("---------------------------流程节点完成---------------------------------");
Map<String, Object> kv = delegateTask.getVariables();
GsonBuilder builder = new GsonBuilder();
builder.registerTypeAdapter(Date.class, new JsonDeserializer<Date>() {
@ -161,9 +160,17 @@ public class DemandDataListener implements TaskListener, ExecutionListener, Acti
TDemandDataDTO demandDataDTO = gson.fromJson(jsonElement, TDemandDataDTO.class);
if (demandDataDTO != null) {
logger.info(JSONObject.toJSONString(demandDataDTO));
tDemandDataService.updateFlag(3, demandDataDTO.getId());// 更新状态为已审批通过
logger.info("---------------------------更新状态为已审批通过---------------------------------");
logger.error(JSONObject.toJSONString(demandDataDTO));
SysUserDTO userDTO = sysUserService.get(Long.valueOf(delegateTask.getAssignee()));
taskService.getTaskComments(delegateTask.getId());
// tDemandDataService.updateFlag(3, demandDataDTO.getId());// 更新状态为已审批通过
demandDataDTO.setFlag(3);
demandDataDTO.setApprovalUserDeptName(userDTO != null ? userDTO.getDeptName() : null);
demandDataDTO.setApprovalUserName(userDTO != null ? userDTO.getRealName() : null);
demandDataDTO.setApprovalOpinions(taskService.getTaskComments(delegateTask.getId()).stream().findFirst().get().getFullMessage());
logger.error("---------------------------更新状态为已审批通过---------------------------------");
logger.error("demandDataDTO:" + demandDataDTO);
tDemandDataService.update(demandDataDTO);
}
}
}

View File

@ -31,6 +31,9 @@ public class TDemandDataServiceImpl extends CrudServiceImpl<TDemandDataDao, TDem
case "flag":
wrapper.eq("flag", params.get("flag"));
break;
case "detailsType":
wrapper.eq("detailsType", params.get("detailsType"));
break;
}
});
if (!params.containsKey("creator")) {
@ -47,6 +50,6 @@ public class TDemandDataServiceImpl extends CrudServiceImpl<TDemandDataDao, TDem
@Override
public void updateFlag(Integer flag, Long id) {
baseDao.updateFlag(flag, id);
}
}

View File

@ -1,126 +1,126 @@
package io.renren.modules.processForm.controller;
import io.renren.common.annotation.LogOperation;
import io.renren.common.constant.Constant;
import io.renren.common.page.PageData;
import io.renren.common.utils.ExcelUtils;
import io.renren.common.utils.Result;
import io.renren.common.validator.AssertUtils;
import io.renren.common.validator.ValidatorUtils;
import io.renren.common.validator.group.AddGroup;
import io.renren.common.validator.group.DefaultGroup;
import io.renren.common.validator.group.UpdateGroup;
import io.renren.modules.processForm.dto.TAbilityApplicationDTO;
import io.renren.modules.processForm.excel.TAbilityApplicationExcel;
import io.renren.modules.processForm.service.TAbilityApplicationService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;
import javax.servlet.http.HttpServletResponse;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@RestController
@RequestMapping("processForm/tabilityapplication")
@Api(tags="能力申请表单")
public class TAbilityApplicationController {
@Autowired
private TAbilityApplicationService tAbilityApplicationService;
@GetMapping("page")
@ApiOperation("分页")
@ApiImplicitParams({
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码从1开始", paramType = "query", required = true, dataType="int") ,
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataType="int") ,
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataType="String") ,
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataType="String")
})
public Result<PageData<TAbilityApplicationDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
PageData<TAbilityApplicationDTO> page = tAbilityApplicationService.page(params);
return new Result<PageData<TAbilityApplicationDTO>>().ok(page);
}
@GetMapping("{id}")
@ApiOperation("信息")
public Result<TAbilityApplicationDTO> get(@PathVariable("id") Long id){
TAbilityApplicationDTO data = tAbilityApplicationService.get(id);
return new Result<TAbilityApplicationDTO>().ok(data);
}
@PostMapping
@ApiOperation("保存")
@LogOperation("保存")
public Result save(@RequestBody TAbilityApplicationDTO dto){
//效验数据
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
tAbilityApplicationService.save(dto);
Map<String, Object> map = new HashMap<>();
map.put("businessKey", dto.getId().toString());
return new Result().ok(map);
}
@PutMapping
@ApiOperation("修改")
@LogOperation("修改")
public Result update(@RequestBody TAbilityApplicationDTO dto){
//效验数据
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
tAbilityApplicationService.update(dto);
return new Result();
}
@DeleteMapping
@ApiOperation("删除")
@LogOperation("删除")
public Result delete(@RequestBody Long[] ids){
//效验数据
AssertUtils.isArrayEmpty(ids, "id");
tAbilityApplicationService.delete(ids);
return new Result();
}
@PostMapping("updateInstanceId")
@ApiOperation("更新实例ID")
@LogOperation("更新实例ID")
@ApiImplicitParams({
@ApiImplicitParam(name = "businessKey", value = "业务KEY", paramType = "query", required = true, dataType="String"),
@ApiImplicitParam(name = "processInstanceId", value = "实例ID", paramType = "query",required = true, dataType="String")
})
public Result updateInstanceId(String businessKey, String processInstanceId){
Long id = Long.valueOf(businessKey);
tAbilityApplicationService.updateInstanceId(processInstanceId, id);
return new Result();
}
@GetMapping("export")
@ApiOperation("导出")
@LogOperation("导出")
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
List<TAbilityApplicationDTO> list = tAbilityApplicationService.list(params);
ExcelUtils.exportExcelToTarget(response, null, "能力申请表单", list, TAbilityApplicationExcel.class);
}
package io.renren.modules.processForm.controller;
import io.renren.common.annotation.LogOperation;
import io.renren.common.constant.Constant;
import io.renren.common.page.PageData;
import io.renren.common.utils.ExcelUtils;
import io.renren.common.utils.Result;
import io.renren.common.validator.AssertUtils;
import io.renren.common.validator.ValidatorUtils;
import io.renren.common.validator.group.AddGroup;
import io.renren.common.validator.group.DefaultGroup;
import io.renren.common.validator.group.UpdateGroup;
import io.renren.modules.processForm.dto.TAbilityApplicationDTO;
import io.renren.modules.processForm.excel.TAbilityApplicationExcel;
import io.renren.modules.processForm.service.TAbilityApplicationService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;
import javax.servlet.http.HttpServletResponse;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@RestController
@RequestMapping("processForm/tabilityapplication")
@Api(tags="能力申请表单")
public class TAbilityApplicationController {
@Autowired
private TAbilityApplicationService tAbilityApplicationService;
@GetMapping("page")
@ApiOperation("分页")
@ApiImplicitParams({
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码从1开始", paramType = "query", required = true, dataType="int") ,
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataType="int") ,
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataType="String") ,
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataType="String")
})
public Result<PageData<TAbilityApplicationDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
PageData<TAbilityApplicationDTO> page = tAbilityApplicationService.page(params);
return new Result<PageData<TAbilityApplicationDTO>>().ok(page);
}
@GetMapping("{id}")
@ApiOperation("信息")
public Result<TAbilityApplicationDTO> get(@PathVariable("id") Long id){
TAbilityApplicationDTO data = tAbilityApplicationService.get(id);
return new Result<TAbilityApplicationDTO>().ok(data);
}
@PostMapping
@ApiOperation("保存")
@LogOperation("保存")
public Result save(@RequestBody TAbilityApplicationDTO dto){
//效验数据
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
tAbilityApplicationService.save(dto);
Map<String, Object> map = new HashMap<>();
map.put("businessKey", dto.getId().toString());
return new Result().ok(map);
}
@PutMapping
@ApiOperation("修改")
@LogOperation("修改")
public Result update(@RequestBody TAbilityApplicationDTO dto){
//效验数据
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
tAbilityApplicationService.update(dto);
return new Result();
}
@DeleteMapping
@ApiOperation("删除")
@LogOperation("删除")
public Result delete(@RequestBody Long[] ids){
//效验数据
AssertUtils.isArrayEmpty(ids, "id");
tAbilityApplicationService.delete(ids);
return new Result();
}
@PostMapping("updateInstanceId")
@ApiOperation("更新实例ID")
@LogOperation("更新实例ID")
@ApiImplicitParams({
@ApiImplicitParam(name = "businessKey", value = "业务KEY", paramType = "query", required = true, dataType="String"),
@ApiImplicitParam(name = "processInstanceId", value = "实例ID", paramType = "query",required = true, dataType="String")
})
public Result updateInstanceId(String businessKey, String processInstanceId){
Long id = Long.valueOf(businessKey);
tAbilityApplicationService.updateInstanceId(processInstanceId, id);
return new Result();
}
@GetMapping("export")
@ApiOperation("导出")
@LogOperation("导出")
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
List<TAbilityApplicationDTO> list = tAbilityApplicationService.list(params);
ExcelUtils.exportExcelToTarget(response, null, "能力申请表单", list, TAbilityApplicationExcel.class);
}
}

View File

@ -1,20 +1,20 @@
package io.renren.modules.processForm.dao;
import io.renren.common.dao.BaseDao;
import io.renren.modules.processForm.entity.TAbilityApplicationEntity;
import org.apache.ibatis.annotations.Mapper;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Mapper
public interface TAbilityApplicationDao extends BaseDao<TAbilityApplicationEntity> {
void updateInstanceId(String instanceId, Long id);
TAbilityApplicationEntity getByInstanceId(String instanceId);
TAbilityApplicationEntity getByBusinessKey(String businessKey);
package io.renren.modules.processForm.dao;
import io.renren.common.dao.BaseDao;
import io.renren.modules.processForm.entity.TAbilityApplicationEntity;
import org.apache.ibatis.annotations.Mapper;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Mapper
public interface TAbilityApplicationDao extends BaseDao<TAbilityApplicationEntity> {
void updateInstanceId(String instanceId, Long id);
TAbilityApplicationEntity getByInstanceId(String instanceId);
TAbilityApplicationEntity getByBusinessKey(String businessKey);
}

View File

@ -1,45 +1,45 @@
package io.renren.modules.processForm.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.io.Serializable;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Data
@ApiModel(value = "能力申请表单")
public class TAbilityApplicationDTO implements Serializable {
private static final long serialVersionUID = 1L;
private Long id;
@ApiModelProperty(value = "申请人")
private String user;
@ApiModelProperty(value = "申请人电话")
private String phone;
@ApiModelProperty(value = "申请人单位")
private String unit;
@ApiModelProperty(value = "申请人所在地区")
private String area;
@ApiModelProperty(value = "申请应用系统")
private String system;
@ApiModelProperty(value = "申请场景")
private String scene;
@ApiModelProperty(value = "申请依据")
private String basis;
@ApiModelProperty(value = "申请附件")
private String attachment;
@ApiModelProperty(value = "实例ID")
private String instanceId;
@ApiModelProperty(value = "资源id")
private String resourceId;
@ApiModelProperty(value = "用户id")
private String userId;
package io.renren.modules.processForm.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.io.Serializable;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Data
@ApiModel(value = "能力申请表单")
public class TAbilityApplicationDTO implements Serializable {
private static final long serialVersionUID = 1L;
private Long id;
@ApiModelProperty(value = "申请人")
private String user;
@ApiModelProperty(value = "申请人电话")
private String phone;
@ApiModelProperty(value = "申请人单位")
private String unit;
@ApiModelProperty(value = "申请人所在地区")
private String area;
@ApiModelProperty(value = "申请应用系统")
private String system;
@ApiModelProperty(value = "申请场景")
private String scene;
@ApiModelProperty(value = "申请依据")
private String basis;
@ApiModelProperty(value = "申请附件")
private String attachment;
@ApiModelProperty(value = "实例ID")
private String instanceId;
@ApiModelProperty(value = "资源id")
private String resourceId;
@ApiModelProperty(value = "用户id")
private String userId;
}

View File

@ -1,69 +1,69 @@
package io.renren.modules.processForm.entity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import com.baomidou.mybatisplus.annotation.*;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("t_ability_application")
public class TAbilityApplicationEntity {
private static final long serialVersionUID = 1L;
@TableId
private Long id;
/**
* 申请人
*/
private String user;
/**
* 申请人电话
*/
private String phone;
/**
* 申请人单位
*/
private String unit;
/**
* 申请人所在地区
*/
private String area;
/**
* 申请应用系统
*/
private String system;
/**
* 申请场景
*/
private String scene;
/**
* 申请依据
*/
private String basis;
/**
* 申请附件
*/
private String attachment;
/**
* 实例ID
*/
private String instanceId;
/**
* 资源id
*/
private String resourceId;
/**
* 用户id
*/
private String userId;
package io.renren.modules.processForm.entity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import com.baomidou.mybatisplus.annotation.*;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("t_ability_application")
public class TAbilityApplicationEntity {
private static final long serialVersionUID = 1L;
@TableId
private Long id;
/**
* 申请人
*/
private String user;
/**
* 申请人电话
*/
private String phone;
/**
* 申请人单位
*/
private String unit;
/**
* 申请人所在地区
*/
private String area;
/**
* 申请应用系统
*/
private String system;
/**
* 申请场景
*/
private String scene;
/**
* 申请依据
*/
private String basis;
/**
* 申请附件
*/
private String attachment;
/**
* 实例ID
*/
private String instanceId;
/**
* 资源id
*/
private String resourceId;
/**
* 用户id
*/
private String userId;
}

View File

@ -1,38 +1,38 @@
package io.renren.modules.processForm.excel;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.ContentRowHeight;
import com.alibaba.excel.annotation.write.style.HeadRowHeight;
import lombok.Data;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Data
@ContentRowHeight(20)
@HeadRowHeight(20)
@ColumnWidth(25)
public class TAbilityApplicationExcel {
@ExcelProperty(value = "Long", index = 0)
private Long id;
@ExcelProperty(value = "申请人", index = 1)
private String user;
@ExcelProperty(value = "申请人电话", index = 2)
private String phone;
@ExcelProperty(value = "申请人单位", index = 3)
private String unit;
@ExcelProperty(value = "申请人所在地区", index = 4)
private String area;
@ExcelProperty(value = "申请应用系统", index = 5)
private String system;
@ExcelProperty(value = "申请场景", index = 6)
private String scene;
@ExcelProperty(value = "申请依据", index = 7)
private String basis;
@ExcelProperty(value = "申请附件", index = 8)
private String attachment;
package io.renren.modules.processForm.excel;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.ContentRowHeight;
import com.alibaba.excel.annotation.write.style.HeadRowHeight;
import lombok.Data;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Data
@ContentRowHeight(20)
@HeadRowHeight(20)
@ColumnWidth(25)
public class TAbilityApplicationExcel {
@ExcelProperty(value = "Long", index = 0)
private Long id;
@ExcelProperty(value = "申请人", index = 1)
private String user;
@ExcelProperty(value = "申请人电话", index = 2)
private String phone;
@ExcelProperty(value = "申请人单位", index = 3)
private String unit;
@ExcelProperty(value = "申请人所在地区", index = 4)
private String area;
@ExcelProperty(value = "申请应用系统", index = 5)
private String system;
@ExcelProperty(value = "申请场景", index = 6)
private String scene;
@ExcelProperty(value = "申请依据", index = 7)
private String basis;
@ExcelProperty(value = "申请附件", index = 8)
private String attachment;
}

View File

@ -65,18 +65,18 @@ public class CorrectionListener implements TaskListener, ExecutionListener, Acti
@Override
public void notify(DelegateExecution delegateExecution) throws Exception {
// logger.info("事件:" + delegateExecution.getEventName());
// delegateExecution.getVariableNames().stream().forEach(index -> logger.info("variable:" + index));
// delegateExecution.getVariables().values().stream().filter(index -> index != null).forEach(value -> logger.info(value.toString()));
// logger.error("事件:" + delegateExecution.getEventName());
// delegateExecution.getVariableNames().stream().forEach(index -> logger.error("variable:" + index));
// delegateExecution.getVariables().values().stream().filter(index -> index != null).forEach(value -> logger.error(value.toString()));
// // taskService.setAssignee(delegateExecution.getProcessInstanceId(), "1516307964617076737");// 可以设置
//
// logger.info("修改审批人成功!" + delegateExecution.getCurrentActivityId() + " " + delegateExecution.getProcessInstanceId() + " " + delegateExecution.getProcessBusinessKey());
// logger.error("修改审批人成功!" + delegateExecution.getCurrentActivityId() + " " + delegateExecution.getProcessInstanceId() + " " + delegateExecution.getProcessBusinessKey());
}
@Override
public void onEvent(ActivitiEvent activitiEvent) { // 事件回调
logger.info("事件类型:" + activitiEvent.getType().toString());
logger.info("" + activitiEvent.getProcessDefinitionId());
logger.error("事件类型:" + activitiEvent.getType().toString());
logger.error("" + activitiEvent.getProcessDefinitionId());
}
@Override
@ -86,7 +86,7 @@ public class CorrectionListener implements TaskListener, ExecutionListener, Acti
@Override
public void execute(DelegateExecution delegateExecution) throws Exception {
logger.info("异常", delegateExecution);
logger.error("异常", delegateExecution);
}
/**

View File

@ -1,23 +1,23 @@
package io.renren.modules.processForm.service;
import io.renren.common.service.CrudService;
import io.renren.modules.processForm.dto.TAbilityApplicationDTO;
import io.renren.modules.processForm.entity.TAbilityApplicationEntity;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
public interface TAbilityApplicationService extends CrudService<TAbilityApplicationEntity, TAbilityApplicationDTO> {
void updateInstanceId(String instanceId, Long id);
/** 根据instanceId 获取申请内容
* @param instanceId
* @return
*/
TAbilityApplicationDTO getByInstanceId(String instanceId);
TAbilityApplicationDTO getByBusinessKey(String businessKey);
package io.renren.modules.processForm.service;
import io.renren.common.service.CrudService;
import io.renren.modules.processForm.dto.TAbilityApplicationDTO;
import io.renren.modules.processForm.entity.TAbilityApplicationEntity;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
public interface TAbilityApplicationService extends CrudService<TAbilityApplicationEntity, TAbilityApplicationDTO> {
void updateInstanceId(String instanceId, Long id);
/** 根据instanceId 获取申请内容
* @param instanceId
* @return
*/
TAbilityApplicationDTO getByInstanceId(String instanceId);
TAbilityApplicationDTO getByBusinessKey(String businessKey);
}

View File

@ -1,56 +1,56 @@
package io.renren.modules.processForm.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import io.renren.common.service.impl.CrudServiceImpl;
import io.renren.common.utils.ConvertUtils;
import io.renren.modules.processForm.dao.TAbilityApplicationDao;
import io.renren.modules.processForm.dto.TAbilityApplicationDTO;
import io.renren.modules.processForm.entity.TAbilityApplicationEntity;
import io.renren.modules.processForm.service.TAbilityApplicationService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import java.util.Map;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Service
public class TAbilityApplicationServiceImpl extends CrudServiceImpl<TAbilityApplicationDao, TAbilityApplicationEntity, TAbilityApplicationDTO> implements TAbilityApplicationService {
@Override
public QueryWrapper<TAbilityApplicationEntity> getWrapper(Map<String, Object> params) {
QueryWrapper<TAbilityApplicationEntity> wrapper = new QueryWrapper<>();
return wrapper;
}
@Override
public void updateInstanceId(String instanceId, Long id) {
baseDao.updateInstanceId(instanceId, id);
}
@Override
public TAbilityApplicationDTO getByInstanceId(String instanceId) {
if (StringUtils.isEmpty(instanceId)) {
return null;
}
TAbilityApplicationEntity entity = baseDao.getByInstanceId(instanceId);
return ConvertUtils.sourceToTarget(entity, TAbilityApplicationDTO.class);
}
@Override
public TAbilityApplicationDTO getByBusinessKey(String businessKey) {
if (StringUtils.isEmpty(businessKey)) {
return null;
}
TAbilityApplicationEntity entity = baseDao.getByBusinessKey(businessKey);
return ConvertUtils.sourceToTarget(entity, TAbilityApplicationDTO.class);
}
package io.renren.modules.processForm.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import io.renren.common.service.impl.CrudServiceImpl;
import io.renren.common.utils.ConvertUtils;
import io.renren.modules.processForm.dao.TAbilityApplicationDao;
import io.renren.modules.processForm.dto.TAbilityApplicationDTO;
import io.renren.modules.processForm.entity.TAbilityApplicationEntity;
import io.renren.modules.processForm.service.TAbilityApplicationService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import java.util.Map;
/**
* 能力申请表单
*
* @author Mark sunlightcs@gmail.com
* @since 3.0 2022-04-13
*/
@Service
public class TAbilityApplicationServiceImpl extends CrudServiceImpl<TAbilityApplicationDao, TAbilityApplicationEntity, TAbilityApplicationDTO> implements TAbilityApplicationService {
@Override
public QueryWrapper<TAbilityApplicationEntity> getWrapper(Map<String, Object> params) {
QueryWrapper<TAbilityApplicationEntity> wrapper = new QueryWrapper<>();
return wrapper;
}
@Override
public void updateInstanceId(String instanceId, Long id) {
baseDao.updateInstanceId(instanceId, id);
}
@Override
public TAbilityApplicationDTO getByInstanceId(String instanceId) {
if (StringUtils.isEmpty(instanceId)) {
return null;
}
TAbilityApplicationEntity entity = baseDao.getByInstanceId(instanceId);
return ConvertUtils.sourceToTarget(entity, TAbilityApplicationDTO.class);
}
@Override
public TAbilityApplicationDTO getByBusinessKey(String businessKey) {
if (StringUtils.isEmpty(businessKey)) {
return null;
}
TAbilityApplicationEntity entity = baseDao.getByBusinessKey(businessKey);
return ConvertUtils.sourceToTarget(entity, TAbilityApplicationDTO.class);
}
}