添加区划名称,用于显示地区

This commit is contained in:
sh
2026-04-15 17:07:32 +08:00
parent 62e86f24c9
commit 975ea1611a
3 changed files with 11 additions and 2 deletions

View File

@@ -178,4 +178,7 @@ public class ESJobDocument
@ApiModelProperty("下架时间") @ApiModelProperty("下架时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private String downTime; private String downTime;
@ApiModelProperty("区划名称")
private String regionName;
} }

View File

@@ -211,4 +211,8 @@ public class Job extends BaseEntity
@ApiModelProperty("下架时间") @ApiModelProperty("下架时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private String downTime; private String downTime;
@TableField(exist = false)
@ApiModelProperty("区划名称")
private String regionName;
} }

View File

@@ -92,6 +92,7 @@
<result property="passReason" column="pass_reason" /> <result property="passReason" column="pass_reason" />
<result property="jobStatus" column="job_status" /> <result property="jobStatus" column="job_status" />
<result property="downTime" column="down_time" /> <result property="downTime" column="down_time" />
<result property="regionName" column="region_name" />
<association property="companyVo" resultMap="CompanyResult"/> <association property="companyVo" resultMap="CompanyResult"/>
</resultMap> </resultMap>
@@ -292,10 +293,11 @@
) )
</select> </select>
<select id="selectAllJob" resultMap="JobEsResult"> <select id="selectAllJob" resultMap="JobEsResult">
SELECT j.*,c.industry,c.scale,c.nature as company_nature,c.code,c.description as company_description,c.name,c.company_id,t.contact_person,t.contact_person_phone FROM job as j SELECT j.*,c.industry,c.scale,c.nature as company_nature,c.code,c.description as company_description,c.name,c.company_id,t.contact_person,t.contact_person_phone,COALESCE(sa.name, '未知区域') as region_name FROM job as j
left join company as c on c.company_id = j.company_id and j.del_flag='0' and c.del_flag='0' left join company as c on c.company_id = j.company_id and j.del_flag='0' and c.del_flag='0'
LEFT JOIN (SELECT t1.*, ROW_NUMBER() OVER (PARTITION BY t1.company_id ORDER BY t1.id) AS rn FROM company_contact AS t1 WHERE t1.del_flag = '0' ) AS t LEFT JOIN (SELECT t1.*, ROW_NUMBER() OVER (PARTITION BY t1.company_id ORDER BY t1.id) AS rn FROM company_contact AS t1 WHERE t1.del_flag = '0' ) AS t
ON t.company_id = j.company_id AND t.rn = 1 WHERE j.del_flag = '0' limit #{offset},#{batchSize} ON t.company_id = j.company_id AND t.rn = 1
LEFT JOIN sys_area sa ON j.region_code=sa.code WHERE j.del_flag = '0' limit #{offset},#{batchSize}
</select> </select>
<select id="selectAllInsertRowWork" resultType="com.ruoyi.cms.domain.RowWork"> <select id="selectAllInsertRowWork" resultType="com.ruoyi.cms.domain.RowWork">
select Id, TaskId, TaskName, Std_class, SF, ZCMC, Aca112, Acb22a, Aac011, Acb240, select Id, TaskId, TaskName, Std_class, SF, ZCMC, Aca112, Acb22a, Aac011, Acb240,