修改计划企业列表list

zhangtao
dongdingding 1 year ago
parent 18cad02690
commit 050d9acc4f

@ -61,21 +61,11 @@ public class BPlanEnterpriseController extends BaseController {
/**
*
*/
@ApiOperation(value = "查询计划企业列表")
@ApiOperation(value = "查询计划企业列表",response = BPlanEnterprise.class)
@GetMapping("/list")
public AjaxResult list(BPlanEnterprise bPlanEnterprise) {
List<BPlanEnterprise> list = bPlanEnterpriseService.selectBPlanEnterpriseList(bPlanEnterprise);
// for (BPlanEnterprise a : list) {
// String enterPriseId = String.valueOf(a.getEnterpriseId());
// BKeyEnterprise count = bKeyEnterpriseService.getByentCode(enterPriseId);
// if (count != null) {
// a.setIsPoint(1);
// } else {
// a.setIsPoint(2);
// }
//
// bPlanEnterpriseService.updateById(a);
// }
return AjaxResult.success(list);
}

@ -10,6 +10,7 @@ import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import javax.validation.Valid;
import java.io.Serializable;
import java.util.Date;
@ -200,5 +201,37 @@ public class BPlanEnterprise implements Serializable {
private Integer checkAgeing;
/**
* 1 2 3
*/
@ApiModelProperty(value = "1当月 2提前 3滞后")
private Integer RISK_LEVEL;
/**
*
*/
@ApiModelProperty(value = "安全风险等级")
private String riskLevel;
/**
*
*/
@ApiModelProperty(value = "标准化等级")
private String standLevel;
/**
*
*/
@ApiModelProperty(value = "上次检查时间")
private Date examineEndTime;
}

@ -35,7 +35,8 @@
<select id="selectBPlanEnterpriseList" parameterType="BPlanEnterprise" resultType="BPlanEnterprise">
select a.id,
SELECT DISTINCT
a.id,
a.enterprise_id,
a.create_id,
a.create_by,
@ -59,11 +60,13 @@
a.check_status,
a.check_id,
a.check_ageing,
c.RISK_LEVEL as riskLevel,
c.STAND_LEVEL as standLevel,
c.EXAMINE_END_TIME as examineEndTime,
CASE WHEN b.ent_code IS NOT NULL THEN 1 ELSE 2 END AS isPoint
from b_plan_enterprise a
LEFT JOIN
b_key_enterprise b ON a.enterprise_id = b.ent_code
FROM b_plan_enterprise a
LEFT JOIN b_key_enterprise b ON a.enterprise_id = b.ent_code
LEFT JOIN b_enterprise_new c ON a.enterprise_id = c.enterprise_id COLLATE utf8mb4_unicode_ci;
<where>
<if test="enterpriseId != null and enterpriseId != ''">and a.enterprise_id = #{enterpriseId}</if>
<if test="createId != null ">and a.create_id = #{createId}</if>

Loading…
Cancel
Save