Merge remote-tracking branch 'origin/jtdev' into jtdev
| | |
| | | */ |
| | | @ApiOperation(value="巡查记录-分页列表查询", notes="巡查记录-分页列表查询") |
| | | @GetMapping(value = "/list") |
| | | public R queryPageList(PatrolRecord patrolRecord, Query query) { |
| | | public R queryPageList(PatrolRecordVO patrolRecord, Query query) { |
| | | IPage<PatrolRecord> pageList = patrolRecordService.selectPatrolRecord(Condition.getPage(query),patrolRecord); |
| | | return R.data(pageList); |
| | | } |
| | |
| | | import java.util.List; |
| | | |
| | | public interface PatrolRecordMapper extends BaseMapper<PatrolRecord> { |
| | | List<PatrolRecord> selectPatrolRecord(IPage<PatrolRecord> page,@Param("patrolRecord") PatrolRecord patrolRecord); |
| | | List<PatrolRecord> selectPatrolRecord(IPage<PatrolRecord> page,@Param("patrolRecord") PatrolRecordVO patrolRecord); |
| | | |
| | | PatrolRecordVO getDetail(@Param("id") String id); |
| | | |
| | |
| | | record.id,record.patrol_type,record.device_ids,record.images,record.videos,record.content,record.status,record.item_id,record.task_id,record.patrol_route,record.create_time,record.update_time,record.solution, |
| | | task.route_coordinates taskRoute,task.title taskName, |
| | | item.items_name itemsName,item.description, |
| | | u.real_name |
| | | u.real_name,res."name" resName,res."guid" resGuid,res."res_reg_code" resRegCode,res."res_loc" resLoc |
| | | FROM SM_PATROL_RECORD record |
| | | LEFT JOIN sm_patrol_type type ON type.id = record.patrol_type |
| | | LEFT JOIN sm_patrol_task task ON task.id = record.task_id |
| | | LEFT JOIN sjzt_md."att_res_base" res ON task.project_id = res."guid" |
| | | LEFT JOIN sm_patrol_group_item item ON item.id = record.item_id |
| | | LEFT JOIN BLADE_USER u ON u.id = record.create_user |
| | | WHERE record.is_deleted = 0 |
| | |
| | | <if test="patrolRecord.taskId !=null and patrolRecord.taskId !=''"> |
| | | AND record.task_id = #{patrolRecord.taskId} |
| | | </if> |
| | | <if test="patrolRecord.resName != null and patrolRecord.resName !=''"> |
| | | AND res."name" LIKE CONCAT('%',#{patrolRecord.resName},'%') |
| | | </if> |
| | | ORDER BY record.create_time DESC |
| | | </select> |
| | | <select id="getDetail" resultMap="selectPatrolRecordList"> |
| | |
| | | * @param patrolRecord |
| | | * @return |
| | | */ |
| | | IPage<PatrolRecord> selectPatrolRecord(IPage<PatrolRecord> page, PatrolRecord patrolRecord); |
| | | IPage<PatrolRecord> selectPatrolRecord(IPage<PatrolRecord> page, PatrolRecordVO patrolRecord); |
| | | |
| | | /** |
| | | * 获取详情 |
| | |
| | | IPatrolGroupItemService patrolGroupItemService; |
| | | |
| | | @Override |
| | | public IPage<PatrolRecord> selectPatrolRecord(IPage<PatrolRecord> page, PatrolRecord patrolRecord) { |
| | | public IPage<PatrolRecord> selectPatrolRecord(IPage<PatrolRecord> page, PatrolRecordVO patrolRecord) { |
| | | return page.setRecords(baseMapper.selectPatrolRecord(page,patrolRecord)); |
| | | } |
| | | |
| | |
| | | |
| | | import cn.gistack.sm.patrol.entity.PatrolRecord; |
| | | import lombok.Data; |
| | | import org.springframework.data.annotation.Transient; |
| | | |
| | | @Data |
| | | public class PatrolRecordVO extends PatrolRecord { |
| | |
| | | * 任务名称 |
| | | */ |
| | | private String taskName; |
| | | |
| | | /** |
| | | * 水库编码 |
| | | */ |
| | | private String resGuid; |
| | | /** |
| | | * 水库名称 |
| | | */ |
| | | private String resName; |
| | | /** |
| | | * 水库注册登记码 |
| | | */ |
| | | private String resRegCode; |
| | | /** |
| | | * 水库所在位置 |
| | | */ |
| | | private String resLoc; |
| | | } |