委托方增加组织代码,与查询修改

This commit is contained in:
赵辉
2026-06-23 08:57:06 +08:00
parent e562dcf627
commit 31247d7faa
6 changed files with 28 additions and 3 deletions
@@ -291,4 +291,7 @@ public class UserShipperEntity extends BaseVOEntity {
@ApiModelProperty(name = "是否校验信用")
private String isCheckCredit;
@ApiModelProperty(name = "组织代码")
private String orgCode;
}
@@ -354,4 +354,6 @@ public class UserShipperPo implements Serializable {
private BigDecimal agreementCount;
@ApiModelProperty(name = "是否校验信用")
private String isCheckCredit;
@ApiModelProperty(name = "组织代码")
private String orgCode;
}
@@ -322,4 +322,7 @@ public class UserShipperDO extends UserDO {
private String userPassword;
@ApiModelProperty(name = "是否校验信用")
private String isCheckCredit;
@ApiModelProperty(name = "组织代码")
private String orgCode;
}
@@ -268,4 +268,7 @@ public class UserShipperDTO extends UserDTO {
private String userPassword;
@ApiModelProperty(name = "是否校验信用")
private String isCheckCredit;
@ApiModelProperty(name = "组织代码")
private String orgCode;
}
@@ -773,7 +773,13 @@
</if>
/*组织ID - 数据隔离:南光组织(organizationId=2827)查询全部,其他组织查询自己组织的数据*/
<if test="organizationId !=null">
AND u.organization_id = #{organizationId}
AND (
u.organization_id = #{organizationId}
OR b.org_code LIKE concat('%"code":"', #{organizationId}, '"%')
OR b.org_code LIKE concat('%code:', #{organizationId}, '%')
OR b.org_code LIKE concat('%code: ', #{organizationId}, '%')
OR b.org_code LIKE concat('%"code":', #{organizationId}, '%')
)
AND u.organization_name IS NOT NULL
</if>
GROUP BY u.user_id, u.user_name, u.user_area_address, u.user_area_county_id, u.user_area_name, u.user_phone, u.has_default_address, b.shipper_id, b.shipper_enterprise_name, u.DOCUMENT_PREPARER_NC_CODE, b.CUSTOMER_NC_CODE, u.organization_id, u.top_organization_id, b.settlement_currency
@@ -171,7 +171,8 @@
b.LIMIT_TIME,
b.CREDIT_AMOUNT,
b.IS_CHECK_CREDIT,
b.AGREEMENT_COUNT
b.AGREEMENT_COUNT,
b.org_code
FROM "USER" a
LEFT JOIN user_shipper b ON a.user_id = b.user_id
left join (select user_id, LISTAGG(DISTINCT r.role_name, '&amp;') WITHIN GROUP(ORDER BY r.role_name) AS roleName
@@ -375,7 +376,13 @@
</if>
/*用户组织ID*/
<if test="organizationId !=null">
and a.organization_id = #{organizationId}
AND (
a.organization_id = #{organizationId}
OR b.org_code LIKE concat('%"code":"', #{organizationId}, '"%')
OR b.org_code LIKE concat('%code:', #{organizationId}, '%')
OR b.org_code LIKE concat('%code: ', #{organizationId}, '%')
OR b.org_code LIKE concat('%"code":', #{organizationId}, '%')
)
</if>
/*组织名称*/
<if test="organizationName != null and organizationName != ''">
@@ -511,6 +518,7 @@
</foreach>
OR a.create_by = #{createBy})
</if>
</sql>
<select id="getShipperCountByMatter" parameterType="com.mhd.common.core.domain.todo.StatisticalMattersDo"