Merge branch 'develop_master' into 'FOTON'

Develop master

See merge request LiuChao/foton-slrs-system-rest!326
This commit is contained in:
王夏晖
2021-12-27 16:14:57 +08:00
5 changed files with 75 additions and 9 deletions
@@ -82,19 +82,19 @@ public class EsRevisePlan extends BasePage {
// private String ptJson;
@ApiModelProperty(value = "引入企业标准json(标准id)")
private String rqbJson;
@ApiModelProperty(value = "引入企业标准json(标准id)")
@ApiModelProperty(value = "引入企业标准json(标准名称)")
private String rqbName;
@ApiModelProperty(value = "引入企业标准json(标准id)")
@ApiModelProperty(value = "引入企业标准json(标准编号)")
private String rqbCode;
@ApiModelProperty(value = "体系结构树(找到表直接json处理掉,存储方式是逗号拼接)")
@ApiModelProperty(value = "体系结构树(id存储方式是逗号拼接)")
private String tsJson;
@ApiModelProperty(value = "体系结构树(找到表直接json处理掉,存储方式是逗号拼接)")
@ApiModelProperty(value = "体系结构树(名称逗号拼接展示")
private String tsJsonName;
@ApiModelProperty(value = "标准范围")
private String area;
@ApiModelProperty(value = "标准范围")
private String areaName;
@ApiModelProperty(value = "标准范围")
@ApiModelProperty(value = "企标类别")
private String qblb;
private List<EsMatingRelation> esMatingRelations;
@@ -77,6 +77,14 @@ public class EsRevisePlanServiceImpl extends ServiceImpl<EsRevisePlanDao, EsRevi
return "企标名称不能重复,请更换新的企标名称";
}else {
esRevisePlanDao.insertOne(esRevisePlan);
esRevisePlan.getEsMatingRelations().forEach(esMatingRelation -> {
esMatingRelation.setEsId(UUIDUtils.randomUUID(32));
esMatingRelation.setEsId(esRevisePlan.getId());
});
esRevisePlan.getEsStandRelations().forEach(esStandRelation -> {
esStandRelation.setEsId(esRevisePlan.getId());
esStandRelation.setId(UUIDUtils.randomUUID(32));
});
esMatingRelationService.saveBatch(esRevisePlan.getEsMatingRelations());
esStandRelationService.saveBatch(esRevisePlan.getEsStandRelations());
return "操作成功";
@@ -40,6 +40,10 @@ public class EsStandRelation extends BaseEntity {
@TableField("use_level")
private String useLevel;
@ApiModelProperty(value = "采用程度名称")
@TableField(exist = false)
private String useLevelName;
@ApiModelProperty(value = "简述技术指标依据")
@TableField("technologic")
private String technologic;
@@ -142,9 +142,62 @@
</select>
<!-- 多条件查询-->
<select id="queryAll" parameterType="com.adc.da.slrs.esRevisePlan.entity.EsRevisePlan" resultMap="BaseInfoMapList">
select <include refid="BaseInfoList"></include> from es_revise_plan
<include refid="Conditions">
</include>
select
id,
es_name,
plan_status,
revise_status,
drafter,
res_person,
wg_leader,
draft_time,
release_time,
unit,
rqb_json as rqbJson,
ts_json as tsJson,
area,
qblb,
(select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) as unitName,
(SELECT GROUP_CONCAT(UNAME) from ts_user WHERE find_in_set(USID,drafter) ) as drafterName,
(SELECT GROUP_CONCAT(ts_dictype.DIC_TYPE_NAME) from ts_dictype WHERE find_in_set(ts_dictype.DIC_TYPE_CODE,area) ) as areaName,
(SELECT GROUP_CONCAT(UNAME) from ts_user WHERE find_in_set(USID,res_person) ) as res_personName,
(SELECT GROUP_CONCAT(UNAME) from ts_user WHERE find_in_set(USID,wg_leader) ) as wg_leaderName
from es_revise_plan
<where>
<if test="esName != null and esName != ''">
and es_name like concat('%',#{esName},'%')
</if>
<if test="area != null and area != ''">
and area = #{area}
</if>
<if test="qblb != null and qblb != ''">
and qblb = #{qblb}
</if>
<if test="planStatus != null and planStatus != ''">
and plan_status = #{planStatus}
</if>
<if test="reviseStatus != null and reviseStatus != ''">
and revise_status = #{reviseStatus}
</if>
<if test="drafter != null and drafter != ''">
and drafter = #{drafter}
</if>
<if test="resPerson != null and resPerson != ''">
and res_person = #{resPerson}
</if>
<if test="wgLeader != null and wgLeader != ''">
and wg_leader = #{wgLeader}
</if>
<if test="draftTime != null">
and DATE_FORMAT(draft_time,'%Y-%m-%d')=DATE_FORMAT(#{draftTime},'%Y-%m-%d')
</if>
<if test="releaseTime != null">
and DATE_FORMAT(release_time,'%Y-%m-%d')=DATE_FORMAT(#{releaseTime},'%Y-%m-%d')
</if>
<if test="unit != null and unit != ''">
and (select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) like concat('%',#{unit},'%')
</if>
</where>
<include refid="pages">
</include>
</select>
@@ -5,9 +5,10 @@
<select id="getDatas" resultType="com.adc.da.slrs.esStandRelation.entity.EsStandRelation">
select es_stand_relation.id , es_stand_relation.stand_id , es_stand_relation.stand_type,sar_standards_info.STAND_NAME as standName,
concat(sar_standards_info.STAND_SORT,concat(' ',concat(concat(sar_standards_info.STAND_NUMBER,concat('-',sar_standards_info.STAND_YEAR))))) as standNumber,
es_stand_relation.is_relate as isRelate,es_stand_relation.technologic,es_stand_relation.use_level as useLevel
es_stand_relation.is_relate as isRelate,es_stand_relation.technologic,es_stand_relation.use_level as useLevel,ts_dictype.DIC_TYPE_NAME as useLevelName
from es_stand_relation
left join sar_standards_info on es_stand_relation.stand_id = sar_standards_info.ID
left join ts_dictype on es_stand_relation.use_level = ts_dictype.DIC_TYPE_CODE
where es_stand_relation.es_id=#{id}
union all
select es_stand_relation.id , es_stand_relation.stand_id , es_stand_relation.stand_type,sar_bussioness_stand.STAND_NAME as standName,