。。。

This commit is contained in:
wangliwen 2023-01-04 15:14:39 +08:00
parent 59a94ed12e
commit ddffb66933
5 changed files with 33 additions and 1 deletions

View File

@ -8,6 +8,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
import io.renren.common.annotation.LogOperation;
import io.renren.common.constant.Constant;
import io.renren.common.utils.Result;
import io.renren.modules.date_snapshot.service.SysDateSnapshotService;
import io.renren.modules.processForm.service.TAbilityApplicationService;
import io.renren.modules.resource.dao.ResourceDao;
import io.renren.modules.resource.excel.census.SelectApplyDeptDetailTypeCountListExcel;
@ -70,6 +71,9 @@ public class CensusController {
@Autowired
private JdbcTemplate jdbcTemplate;
@Autowired
private SysDateSnapshotService sysDateSnapshotService;
@Value("${census.type}")
private String[] censusTypes; // 需要进行统计的资源类型

View File

@ -1,8 +1,10 @@
package io.renren.modules.date_snapshot.dao;
import io.renren.common.dao.BaseDao;
import io.renren.modules.date_snapshot.dto.SysDateSnapshotDTO;
import io.renren.modules.date_snapshot.entity.SysDateSnapshotEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
/**
* 运行数据快照资源数量申请数量
@ -13,4 +15,6 @@ import org.apache.ibatis.annotations.Mapper;
@Mapper
public interface SysDateSnapshotDao extends BaseDao<SysDateSnapshotEntity> {
SysDateSnapshotDTO selectForFlag(@Param("type") Integer type);
}

View File

@ -109,6 +109,6 @@ public class SysDateSnapshotServiceImpl extends CrudServiceImpl<SysDateSnapshotD
@Override
public SysDateSnapshotDTO selectForFlag(Integer type) {
return null;
return baseDao.selectForFlag(type);
}
}

View File

@ -21,4 +21,16 @@
typeHandler="com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler"/>
</resultMap>
<select id="selectForFlag" resultType="io.renren.modules.date_snapshot.dto.SysDateSnapshotDTO">
SELECT
*
FROM
sys_date_snapshot
WHERE
type = ${type}
ORDER BY
create_date DESC
LIMIT 1;
</select>
</mapper>

View File

@ -73,6 +73,18 @@
<if test="updateDate != null and updateDate != ''">
and updateDate #{updateDate}
</if>
<if test="senses != null and senses.length > 0 ">
and application_area in
<foreach collection="senses" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
<if test="areas != null and areas.length > 0 ">
and area in
<foreach collection="areas" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
group by tf.id
ORDER BY ${orderField} ${orderType}
</select>