| | |
| | | |
| | | String FLOW_CATEGORY_CODE = "flow_category"; |
| | | |
| | | String HOTEL_SECURITY= "旅馆安全"; |
| | | |
| | | String DA_JIN_DIAN= "打金店"; |
| | | |
| | | String USED_MOBILE_PHONES= "二手手机"; |
| | | |
| | | String USED_CAR= "二手汽车"; |
| | | |
| | | String BAIL_PENDING_TRIAL= "取保候审"; |
| | | |
| | | } |
| | |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入taskBailReportingEvent") |
| | | public R save(@Valid @RequestBody TaskBailReportingEventEntity taskBailReportingEvent) { |
| | | return R.status(taskBailReportingEventService.save(taskBailReportingEvent)); |
| | | return R.status(taskBailReportingEventService.saveBailReporting(taskBailReportingEvent)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入taskBailReportingEvent") |
| | | public R update(@Valid @RequestBody TaskBailReportingEventEntity taskBailReportingEvent) { |
| | | return R.status(taskBailReportingEventService.updateById(taskBailReportingEvent)); |
| | | return R.status(taskBailReportingEventService.updateBailReporting(taskBailReportingEvent)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入taskHotelReporting") |
| | | public R save(@Valid @RequestBody TaskHotelReportingEntity taskHotelReporting) { |
| | | return R.status(taskHotelReportingService.save(taskHotelReporting)); |
| | | return R.status(taskHotelReportingService.saveHotelReporting(taskHotelReporting)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入taskHotelReporting") |
| | | public R update(@Valid @RequestBody TaskHotelReportingEntity taskHotelReporting) { |
| | | return R.status(taskHotelReportingService.updateById(taskHotelReporting)); |
| | | return R.status(taskHotelReportingService.updateHotelReporting(taskHotelReporting)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入taskLabelReportingEvent") |
| | | public R save(@Valid @RequestBody TaskLabelReportingEventEntity taskLabelReportingEvent) { |
| | | return R.status(taskLabelReportingEventService.save(taskLabelReportingEvent)); |
| | | return R.status(taskLabelReportingEventService.saveReportingEven(taskLabelReportingEvent)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入taskLabelReportingEvent") |
| | | public R update(@Valid @RequestBody TaskLabelReportingEventEntity taskLabelReportingEvent) { |
| | | return R.status(taskLabelReportingEventService.updateById(taskLabelReportingEvent)); |
| | | return R.status(taskLabelReportingEventService.updateLabelReporting(taskLabelReportingEvent)); |
| | | } |
| | | |
| | | /** |
| | |
| | | package org.springblade.modules.task.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import java.util.Date; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.core.tenant.mp.TenantEntity; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | /** |
| | | * 取保候审任务 实体类 |
| | |
| | | * 自查人姓名 |
| | | */ |
| | | @ApiModelProperty(value = "自查人姓名") |
| | | private Integer checkUserId; |
| | | private Long checkUserId; |
| | | /** |
| | | * 自查人姓名 |
| | | */ |
| | |
| | | * 确认时间 |
| | | */ |
| | | @ApiModelProperty(value = "确认时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date confirmTime; |
| | | /** |
| | | * 确认用户ID |
| | |
| | | * 申请时间 |
| | | */ |
| | | @ApiModelProperty(value = "申请时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date applyTime; |
| | | /** |
| | | * 外出原因 |
| | |
| | | * 出发-当前时间 |
| | | */ |
| | | @ApiModelProperty(value = "出发-当前时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date startTime; |
| | | /** |
| | | * 出发-报备位置 |
| | |
| | | * 到达-当前时间 |
| | | */ |
| | | @ApiModelProperty(value = "到达-当前时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date reachTime; |
| | | /** |
| | | * 到达-报备位置 |
| | |
| | | * 返回-当前时间 |
| | | */ |
| | | @ApiModelProperty(value = "返回-当前时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date returnTime; |
| | | /** |
| | | * 返回-报备位置 |
| | |
| | | package org.springblade.modules.task.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import java.util.Date; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.core.tenant.mp.TenantEntity; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | /** |
| | | * 旅馆安全自查任务 实体类 |
| | |
| | | * 自查时间 |
| | | */ |
| | | @ApiModelProperty(value = "自查时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date checkTime; |
| | | /** |
| | | * 自查人姓名 |
| | | */ |
| | | @ApiModelProperty(value = "自查人姓名") |
| | | private Integer checkUserId; |
| | | private Long checkUserId; |
| | | /** |
| | | * 自查人姓名 |
| | | */ |
| | |
| | | * 确认时间 |
| | | */ |
| | | @ApiModelProperty(value = "确认时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date confirmTime; |
| | | /** |
| | | * 确认用户ID |
| | |
| | | package org.springblade.modules.task.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | |
| | | import java.lang.Double; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.core.tenant.mp.TenantEntity; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | /** |
| | | * 打金店报事 实体类 |
| | |
| | | * 发生时间 |
| | | */ |
| | | @ApiModelProperty(value = "发生时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date happenTime; |
| | | /** |
| | | * 用户ID |
| | | */ |
| | | @ApiModelProperty(value = "用户ID") |
| | | private Integer userId; |
| | | private Long userId; |
| | | /** |
| | | * 身份证图片URLS |
| | | */ |
| | |
| | | * 确认时间 |
| | | */ |
| | | @ApiModelProperty(value = "确认时间") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date confirmTime; |
| | | /** |
| | | * 位置 |
| | |
| | | */ |
| | | package org.springblade.modules.task.service; |
| | | |
| | | import liquibase.pro.packaged.B; |
| | | import org.springblade.modules.task.entity.TaskBailReportingEventEntity; |
| | | import org.springblade.modules.task.vo.TaskBailReportingEventVO; |
| | | import org.springblade.core.mp.base.BaseService; |
| | |
| | | IPage<TaskBailReportingEventVO> selectTaskBailReportingEventPage(IPage<TaskBailReportingEventVO> page, TaskBailReportingEventVO taskBailReportingEvent); |
| | | |
| | | |
| | | Boolean saveBailReporting(TaskBailReportingEventEntity taskBailReportingEvent); |
| | | |
| | | Boolean updateBailReporting(TaskBailReportingEventEntity taskBailReportingEvent); |
| | | } |
| | |
| | | */ |
| | | IPage<TaskHotelReportingVO> selectTaskHotelReportingPage(IPage<TaskHotelReportingVO> page, TaskHotelReportingVO taskHotelReporting); |
| | | |
| | | /** |
| | | * 保存酒店自查任务 |
| | | * @param taskHotelReporting |
| | | * @return |
| | | */ |
| | | boolean saveHotelReporting(TaskHotelReportingEntity taskHotelReporting); |
| | | |
| | | Boolean updateHotelReporting(TaskHotelReportingEntity taskHotelReporting); |
| | | } |
| | |
| | | IPage<TaskLabelReportingEventVO> selectTaskLabelReportingEventPage(IPage<TaskLabelReportingEventVO> page, TaskLabelReportingEventVO taskLabelReportingEvent); |
| | | |
| | | |
| | | Boolean saveReportingEven(TaskLabelReportingEventEntity taskLabelReportingEvent); |
| | | |
| | | Boolean updateLabelReporting(TaskLabelReportingEventEntity taskLabelReportingEvent); |
| | | } |
| | |
| | | */ |
| | | package org.springblade.modules.task.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.core.mp.base.BaseService; |
| | | import org.springblade.modules.task.entity.TaskEntity; |
| | | import org.springblade.modules.task.vo.TaskVO; |
| | | import org.springblade.core.mp.base.BaseService; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 任务表 服务类 |
| | |
| | | */ |
| | | IPage<TaskVO> selectTaskPage(IPage<TaskVO> page, TaskVO task); |
| | | |
| | | /** |
| | | * 新增任务 |
| | | * |
| | | * @param type |
| | | * @param name |
| | | * @param frequency |
| | | * @param remark |
| | | * @param createUser |
| | | * @return |
| | | */ |
| | | Long saveTask(Integer type, String name, Integer frequency, String remark, Long createUser); |
| | | |
| | | /** |
| | | * @param type |
| | | * @param name |
| | | * @param frequency |
| | | * @param remark |
| | | * @param updateUser |
| | | * @param id |
| | | * @return |
| | | */ |
| | | public Long updateTask(Integer type, String name, Integer frequency, String remark, Long updateUser, Long id, Integer status); |
| | | |
| | | } |
| | |
| | | */ |
| | | package org.springblade.modules.task.service.impl; |
| | | |
| | | import org.springblade.common.constant.DictConstant; |
| | | import org.springblade.core.secure.utils.AuthUtil; |
| | | import org.springblade.modules.task.entity.TaskBailReportingEventEntity; |
| | | import org.springblade.modules.task.service.ITaskService; |
| | | import org.springblade.modules.task.vo.TaskBailReportingEventVO; |
| | | import org.springblade.modules.task.mapper.TaskBailReportingEventMapper; |
| | | import org.springblade.modules.task.service.ITaskBailReportingEventService; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * 取保候审任务 服务实现类 |
| | |
| | | @Service |
| | | public class TaskBailReportingEventServiceImpl extends BaseServiceImpl<TaskBailReportingEventMapper, TaskBailReportingEventEntity> implements ITaskBailReportingEventService { |
| | | |
| | | @Resource |
| | | private ITaskService taskService; |
| | | @Override |
| | | public IPage<TaskBailReportingEventVO> selectTaskBailReportingEventPage(IPage<TaskBailReportingEventVO> page, TaskBailReportingEventVO taskBailReportingEvent) { |
| | | return page.setRecords(baseMapper.selectTaskBailReportingEventPage(page, taskBailReportingEvent)); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public Boolean saveBailReporting(TaskBailReportingEventEntity taskBailReportingEvent) { |
| | | Long aLong = taskService.saveTask(1, DictConstant.BAIL_PENDING_TRIAL, 3, "", AuthUtil.getUserId()); |
| | | if (aLong > 0) { |
| | | taskBailReportingEvent.setTaskId(aLong); |
| | | taskBailReportingEvent.setCheckUserId(AuthUtil.getUserId()); |
| | | return baseMapper.insert(taskBailReportingEvent) > 0 ? true : false; |
| | | } |
| | | return false; |
| | | } |
| | | |
| | | @Override |
| | | public Boolean updateBailReporting(TaskBailReportingEventEntity taskBailReportingEvent) { |
| | | Long aLong = taskService.updateTask(null, null, null, "", AuthUtil.getUserId(), taskBailReportingEvent.getTaskId(), taskBailReportingEvent.getStatus()); |
| | | if (aLong > 0) { |
| | | return baseMapper.updateById(taskBailReportingEvent) > 0 ? true : false; |
| | | } |
| | | return false; |
| | | } |
| | | } |
| | |
| | | */ |
| | | package org.springblade.modules.task.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.common.constant.DictConstant; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.core.secure.utils.AuthUtil; |
| | | import org.springblade.modules.task.entity.TaskHotelReportingEntity; |
| | | import org.springblade.modules.task.vo.TaskHotelReportingVO; |
| | | import org.springblade.modules.task.mapper.TaskHotelReportingMapper; |
| | | import org.springblade.modules.task.service.ITaskHotelReportingService; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.modules.task.service.ITaskService; |
| | | import org.springblade.modules.task.vo.TaskHotelReportingVO; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * 旅馆安全自查任务 服务实现类 |
| | |
| | | @Service |
| | | public class TaskHotelReportingServiceImpl extends BaseServiceImpl<TaskHotelReportingMapper, TaskHotelReportingEntity> implements ITaskHotelReportingService { |
| | | |
| | | @Resource |
| | | private ITaskService taskService; |
| | | |
| | | @Override |
| | | public IPage<TaskHotelReportingVO> selectTaskHotelReportingPage(IPage<TaskHotelReportingVO> page, TaskHotelReportingVO taskHotelReporting) { |
| | | return page.setRecords(baseMapper.selectTaskHotelReportingPage(page, taskHotelReporting)); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public boolean saveHotelReporting(TaskHotelReportingEntity taskHotelReporting) { |
| | | Long aLong = taskService.saveTask(1, DictConstant.HOTEL_SECURITY, 2, "", AuthUtil.getUserId()); |
| | | if (aLong > 0) { |
| | | taskHotelReporting.setTaskId(aLong); |
| | | taskHotelReporting.setCheckUserId(AuthUtil.getUserId()); |
| | | return baseMapper.insert(taskHotelReporting) > 0 ? true : false; |
| | | } |
| | | return false; |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public Boolean updateHotelReporting(TaskHotelReportingEntity taskHotelReporting) { |
| | | Long aLong = taskService.updateTask(null, null, null, "", AuthUtil.getUserId(), taskHotelReporting.getTaskId(), taskHotelReporting.getStatus()); |
| | | if (aLong > 0) { |
| | | return baseMapper.updateById(taskHotelReporting) > 0 ? true : false; |
| | | } |
| | | return false; |
| | | } |
| | | } |
| | |
| | | */ |
| | | package org.springblade.modules.task.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.common.constant.DictConstant; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.core.secure.utils.AuthUtil; |
| | | import org.springblade.modules.task.entity.TaskLabelReportingEventEntity; |
| | | import org.springblade.modules.task.vo.TaskLabelReportingEventVO; |
| | | import org.springblade.modules.task.mapper.TaskLabelReportingEventMapper; |
| | | import org.springblade.modules.task.service.ITaskLabelReportingEventService; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.modules.task.service.ITaskService; |
| | | import org.springblade.modules.task.vo.TaskLabelReportingEventVO; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * 打金店报事 服务实现类 |
| | |
| | | @Service |
| | | public class TaskLabelReportingEventServiceImpl extends BaseServiceImpl<TaskLabelReportingEventMapper, TaskLabelReportingEventEntity> implements ITaskLabelReportingEventService { |
| | | |
| | | @Resource |
| | | private ITaskService taskService; |
| | | |
| | | @Override |
| | | public IPage<TaskLabelReportingEventVO> selectTaskLabelReportingEventPage(IPage<TaskLabelReportingEventVO> page, TaskLabelReportingEventVO taskLabelReportingEvent) { |
| | | return page.setRecords(baseMapper.selectTaskLabelReportingEventPage(page, taskLabelReportingEvent)); |
| | | } |
| | | |
| | | @Override |
| | | public Boolean saveReportingEven(TaskLabelReportingEventEntity taskLabelReportingEvent) { |
| | | String name; |
| | | switch (taskLabelReportingEvent.getEventType()) { |
| | | case "1": |
| | | name = DictConstant.DA_JIN_DIAN; |
| | | break; |
| | | case "2": |
| | | name = DictConstant.USED_MOBILE_PHONES; |
| | | break; |
| | | case "3": |
| | | name = DictConstant.USED_CAR; |
| | | break; |
| | | default: |
| | | name = ""; |
| | | } |
| | | Long aLong = taskService.saveTask(1, name, 1, "", AuthUtil.getUserId()); |
| | | if (aLong > 0) { |
| | | taskLabelReportingEvent.setTaskId(aLong); |
| | | taskLabelReportingEvent.setUserId(AuthUtil.getUserId()); |
| | | return baseMapper.insert(taskLabelReportingEvent) > 0 ? true : false; |
| | | } |
| | | return false; |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public Boolean updateLabelReporting(TaskLabelReportingEventEntity taskLabelReportingEvent) { |
| | | Long aLong = taskService.updateTask(null, null, null, "", AuthUtil.getUserId(), |
| | | taskLabelReportingEvent.getTaskId(), taskLabelReportingEvent.getStatus()); |
| | | if (aLong > 0) { |
| | | return baseMapper.updateById(taskLabelReportingEvent) > 0 ? true : false; |
| | | } |
| | | return false; |
| | | } |
| | | } |
| | |
| | | */ |
| | | package org.springblade.modules.task.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.modules.task.entity.TaskEntity; |
| | | import org.springblade.modules.task.vo.TaskVO; |
| | | import org.springblade.modules.task.mapper.TaskMapper; |
| | | import org.springblade.modules.task.service.ITaskService; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.modules.task.vo.TaskVO; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * 任务表 服务实现类 |
| | |
| | | return page.setRecords(baseMapper.selectTaskPage(page, task)); |
| | | } |
| | | |
| | | /** |
| | | * 新增任务 |
| | | * |
| | | * @param type |
| | | * @param name |
| | | * @param frequency |
| | | * @param remark |
| | | * @param createUser |
| | | * @return |
| | | */ |
| | | @Override |
| | | public Long saveTask(Integer type, String name, Integer frequency, String remark, Long createUser) { |
| | | TaskEntity taskEntity = new TaskEntity(); |
| | | taskEntity.setType(type); |
| | | taskEntity.setName(name); |
| | | taskEntity.setFrequency(frequency); |
| | | taskEntity.setRemark(remark); |
| | | taskEntity.setCreateTime(new Date()); |
| | | taskEntity.setCreateUser(createUser); |
| | | return baseMapper.insert(taskEntity) > 0 ? taskEntity.getId() : 0; |
| | | } |
| | | |
| | | @Override |
| | | public Long updateTask(Integer type, String name, Integer frequency, String remark, Long updateUser, Long id, Integer status) { |
| | | TaskEntity taskEntity = new TaskEntity(); |
| | | taskEntity.setId(id); |
| | | taskEntity.setType(type); |
| | | taskEntity.setName(name); |
| | | taskEntity.setFrequency(frequency); |
| | | taskEntity.setRemark(remark); |
| | | taskEntity.setUpdateTime(new Date()); |
| | | taskEntity.setUpdateUser(updateUser); |
| | | taskEntity.setStatus(status); |
| | | return baseMapper.updateById(taskEntity) > 0 ? 1L : 0; |
| | | } |
| | | } |