|
@@ -55,8 +55,19 @@
|
|
and wc.company_name like CONCAT("%", #{companyName} ,"%")
|
|
and wc.company_name like CONCAT("%", #{companyName} ,"%")
|
|
</if>
|
|
</if>
|
|
and wc.del_state = 0
|
|
and wc.del_state = 0
|
|
- and wc.company_code in (select code_number from sys_organization_auth where role_id =#{roleId} and code_type = 'company')
|
|
|
|
- and wc.create_by = #{userId}
|
|
|
|
|
|
+ <if test="state!=null or companyName!=null">
|
|
|
|
+ and
|
|
|
|
+ wc.company_code in (select code_number from sys_organization_auth where role_id =#{roleId} and code_type = 'company')
|
|
|
|
+ and
|
|
|
|
+ wc.create_by = #{userId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="state==null and companyName==null">
|
|
|
|
+ and
|
|
|
|
+ wc.create_by = #{userId}
|
|
|
|
+ or
|
|
|
|
+ wc.company_code in (select code_number from sys_organization_auth where role_id =#{roleId} and code_type = 'company')
|
|
|
|
+
|
|
|
|
+ </if>
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="selectByCodeNumber" parameterType="java.lang.String" resultType="com.energy.manage.common.po.windrelation.WindRelationPO">
|
|
<select id="selectByCodeNumber" parameterType="java.lang.String" resultType="com.energy.manage.common.po.windrelation.WindRelationPO">
|