glj-代码提交
This commit is contained in:
parent
60e0c3ed00
commit
2fdfc281e6
|
@ -235,7 +235,7 @@ public class RemoteSensingSourceData implements Serializable {
|
|||
|
||||
//标志灾前灾后字段 0-灾前,1-灾后
|
||||
@TableField(exist = false)
|
||||
private Integer beforeOrAfter =1;
|
||||
private Integer beforeOrAfter;
|
||||
|
||||
//多个Id
|
||||
@TableField(exist = false)
|
||||
|
|
|
@ -53,6 +53,8 @@ public class OtherDataController {
|
|||
return R.data(service.queryPage(Condition.getPage(query),params));
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 批量审批
|
||||
* @return
|
||||
|
|
|
@ -16,6 +16,7 @@ import org.springframework.web.multipart.MultipartFile;
|
|||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.Stream;
|
||||
|
@ -45,6 +46,13 @@ public class RemoteSensingSourceDataController {
|
|||
return R.data(remoteSensingSourceDataService.page(Condition.getPage(query), new QueryWrapper<RemoteSensingSourceData>().in("disaster_id", disasterIds)));
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("/getRemoteSensingSourceDataPage")
|
||||
public R<IPage<RemoteSensingSourceData>> getRemoteSensingSourceDataPage(RemoteSensingSourceData remoteSensingSourceData, Query query) {
|
||||
return R.data(remoteSensingSourceDataService.page(Condition.getPage(query), new QueryWrapper<RemoteSensingSourceData>().eq("disaster_id", remoteSensingSourceData.getDisasterId()).in("status",Arrays.asList(remoteSensingSourceData.getStatusListNew().split(",")))));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 实体数据列表信息
|
||||
*
|
||||
|
@ -62,6 +70,11 @@ public class RemoteSensingSourceDataController {
|
|||
return R.data(remoteSensingSourceDataService.getRemoteSensingSourceDataByCondition(Condition.getPage(query), remoteSensingSourceData));
|
||||
}
|
||||
|
||||
@GetMapping("/ConditionNew")
|
||||
public R<IPage<RemoteSensingSourceData>> getRemoteSensingSourceDataByConditionNew(RemoteSensingSourceData remoteSensingSourceData, Query query) {
|
||||
return R.data(remoteSensingSourceDataService.getRemoteSensingSourceDataByConditionNew(Condition.getPage(query), remoteSensingSourceData));
|
||||
}
|
||||
|
||||
/**
|
||||
* 实体数据列表信息
|
||||
*
|
||||
|
|
|
@ -24,4 +24,6 @@ public interface RemoteSensingSourceDataMapper extends BaseMapper<RemoteSensingS
|
|||
IPage<RemoteSensingSourceData> getRemoteSensingSourceDataByCondition(@Param("remoteSensingSourceData") RemoteSensingSourceData remoteSensingSourceData, IPage<Object> page);
|
||||
|
||||
List<Map<String, Long>> getStatisticsByUserId(@Param("id") Long id,@Param("year") String year);
|
||||
|
||||
IPage<RemoteSensingSourceData> getRemoteSensingSourceDataByConditionNew(@Param("remoteSensingSourceData") RemoteSensingSourceData remoteSensingSourceData, IPage<Object> page);
|
||||
}
|
||||
|
|
|
@ -77,25 +77,31 @@
|
|||
<if test="remoteSensingSourceData.status != null">
|
||||
and r.status = #{remoteSensingSourceData.status}
|
||||
</if>
|
||||
|
||||
<if test="remoteSensingSourceData.productResolutionMax != null and remoteSensingSourceData.productResolutionMin != null">
|
||||
and r.product_resolution >= #{remoteSensingSourceData.productResolutionMin} and r.product_resolution
|
||||
< #{remoteSensingSourceData.productResolutionMax}
|
||||
</if>
|
||||
|
||||
<if test="remoteSensingSourceData.productResolutionMax == null and remoteSensingSourceData.productResolutionMin != null">
|
||||
and r.product_resolution > #{remoteSensingSourceData.productResolutionMin}
|
||||
</if>
|
||||
/*卫星类型集合*/
|
||||
<if test="remoteSensingSourceData.satelliteCodeListNew != null and remoteSensingSourceData.satelliteCodeListNew != '' and remoteSensingSourceData.satelliteCodeListNew.size() != 0">
|
||||
and r.satellite_type_select in
|
||||
<foreach item="AList" index="index" collection="remoteSensingSourceData.satelliteCodeListNew"
|
||||
open="(" separator="," close=")">#{AList}
|
||||
</foreach>
|
||||
</if>
|
||||
/*状态集合*/
|
||||
<if test="remoteSensingSourceData.statusList != null and remoteSensingSourceData.statusList != '' and remoteSensingSourceData.statusList.size() != 0">
|
||||
and r.status in
|
||||
<foreach item="AList" index="index" collection="remoteSensingSourceData.statusList"
|
||||
open="(" separator="," close=")">#{AList}
|
||||
</foreach>
|
||||
</if>
|
||||
/*灾前还是灾后*/
|
||||
<if test="remoteSensingSourceData.beforeOrAfter != null and remoteSensingSourceData.beforeOrAfter != ''">
|
||||
<if test="remoteSensingSourceData.beforeOrAfter == 1">
|
||||
and r.product_time >= (select
|
||||
disaster_time
|
||||
|
@ -106,6 +112,7 @@
|
|||
disaster_time
|
||||
from disaster_info where id = #{remoteSensingSourceData.disasterId})
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
@ -188,4 +195,65 @@
|
|||
ORDER BY d.`key`
|
||||
</select>
|
||||
|
||||
<select id="getRemoteSensingSourceDataByConditionNew" resultType="com.kening.vordm.entity.RemoteSensingSourceData">
|
||||
select
|
||||
<include refid="Base_Column_List"/>
|
||||
from remote_sensing_source_data r
|
||||
<where>
|
||||
<if test="remoteSensingSourceData.disasterId != null and remoteSensingSourceData.disasterId != ''">
|
||||
r.disaster_id = #{remoteSensingSourceData.disasterId}
|
||||
</if>
|
||||
<if test="remoteSensingSourceData.status != null">
|
||||
and r.status = #{remoteSensingSourceData.status}
|
||||
</if>
|
||||
|
||||
<if test="remoteSensingSourceData.productResolutionMax != null and remoteSensingSourceData.productResolutionMin != null">
|
||||
and r.product_resolution >= #{remoteSensingSourceData.productResolutionMin} and r.product_resolution
|
||||
<= #{remoteSensingSourceData.productResolutionMax}
|
||||
</if>
|
||||
|
||||
<if test="remoteSensingSourceData.productResolutionMax == null and remoteSensingSourceData.productResolutionMin != null">
|
||||
and r.product_resolution > #{remoteSensingSourceData.productResolutionMin}
|
||||
</if>
|
||||
|
||||
<if test="remoteSensingSourceData.productResolutionMax != null and remoteSensingSourceData.productResolutionMin == null">
|
||||
and r.product_resolution < #{remoteSensingSourceData.productResolutionMax}
|
||||
</if>
|
||||
|
||||
<if test="remoteSensingSourceData.satelliteTypeSelect != null and remoteSensingSourceData.satelliteTypeSelect != ''">
|
||||
and r.satellite_type_select = #{remoteSensingSourceData.satelliteTypeSelect}
|
||||
</if>
|
||||
|
||||
/*卫星类型集合*/
|
||||
<if test="remoteSensingSourceData.satelliteCodeListNew != null and remoteSensingSourceData.satelliteCodeListNew != '' and remoteSensingSourceData.satelliteCodeListNew.size() != 0">
|
||||
and r.satellite_type_select in
|
||||
<foreach item="AList" index="index" collection="remoteSensingSourceData.satelliteCodeListNew"
|
||||
open="(" separator="," close=")">#{AList}
|
||||
</foreach>
|
||||
</if>
|
||||
|
||||
/*状态集合*/
|
||||
<if test="remoteSensingSourceData.statusList != null and remoteSensingSourceData.statusList != '' and remoteSensingSourceData.statusList.size() != 0">
|
||||
and r.status in
|
||||
<foreach item="AList" index="index" collection="remoteSensingSourceData.statusList"
|
||||
open="(" separator="," close=")">#{AList}
|
||||
</foreach>
|
||||
</if>
|
||||
|
||||
/*灾前还是灾后*/
|
||||
<if test="remoteSensingSourceData.beforeOrAfter != null and remoteSensingSourceData.beforeOrAfter != ''">
|
||||
<if test="remoteSensingSourceData.beforeOrAfter == 1">
|
||||
and r.product_time >= (select
|
||||
disaster_time
|
||||
from disaster_info where id = #{remoteSensingSourceData.disasterId})
|
||||
</if>
|
||||
<if test="remoteSensingSourceData.beforeOrAfter == 0">
|
||||
and r.product_time < (select
|
||||
disaster_time
|
||||
from disaster_info where id = #{remoteSensingSourceData.disasterId})
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
|
|
@ -29,4 +29,6 @@ public interface RemoteSensingSourceDataService extends IService<RemoteSensingSo
|
|||
R importTemplateImgList(List<MultipartFile> fileList, Long disasterId);
|
||||
|
||||
void exportRemoteSensing(Long id, HttpServletRequest request, HttpServletResponse response);
|
||||
|
||||
IPage<RemoteSensingSourceData> getRemoteSensingSourceDataByConditionNew(IPage<Object> page, RemoteSensingSourceData remoteSensingSourceData);
|
||||
}
|
||||
|
|
|
@ -344,6 +344,13 @@ public class RemoteSensingSourceDataServiceImpl extends ServiceImpl<RemoteSensin
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public IPage<RemoteSensingSourceData> getRemoteSensingSourceDataByConditionNew(IPage<Object> page, RemoteSensingSourceData remoteSensingSourceData) {
|
||||
List<String> result = Arrays.asList(remoteSensingSourceData.getStatusListNew().split(","));
|
||||
remoteSensingSourceData.setStatusList(result);
|
||||
return this.baseMapper.getRemoteSensingSourceDataByConditionNew(remoteSensingSourceData, page);
|
||||
}
|
||||
|
||||
public static void downLoadExcel(HttpServletResponse response, Workbook workbook, String fileName) {
|
||||
try {
|
||||
if (workbook instanceof HSSFWorkbook) {
|
||||
|
|
4
pom.xml
4
pom.xml
|
@ -218,7 +218,7 @@
|
|||
<repository>
|
||||
<id>kening-release</id>
|
||||
<name>Release Repository</name>
|
||||
<url>http://47.92.168.204:8081/repository/maven-public/</url>
|
||||
<url>http://192.168.31.17:8081/repository/maven-public/</url>
|
||||
<snapshots>
|
||||
<enabled>true</enabled>
|
||||
</snapshots>
|
||||
|
@ -231,7 +231,7 @@
|
|||
<pluginRepositories>
|
||||
<pluginRepository>
|
||||
<id>kening-plugin</id>
|
||||
<url>http://47.92.168.204:8081/repository/maven-public/</url>
|
||||
<url>http://192.168.31.17:8081/repository/maven-public/</url>
|
||||
<snapshots>
|
||||
<enabled>true</enabled>
|
||||
</snapshots>
|
||||
|
|
Loading…
Reference in New Issue