mirror of
https://github.com/dromara/RuoYi-Vue-Plus.git
synced 2025-09-24 07:19:46 +08:00
fix 修复数据权限 仅自己 相关问题
This commit is contained in:
@ -96,13 +96,14 @@ public class PlusDataPermissionHandler {
|
||||
return "";
|
||||
}
|
||||
// 不包含 key 变量 则不处理
|
||||
if (!StringUtils.contains(type.getSql(), "#" + dataColumn.key())) {
|
||||
if (!StringUtils.contains(type.getSqlTemplate(), "#" + dataColumn.key())) {
|
||||
sqlString.append(type.getElseSql());
|
||||
continue;
|
||||
}
|
||||
// 更新或删除需满足所有条件
|
||||
sqlString.append(isSelect ? " OR " : " AND ");
|
||||
// 解析sql模板并填充
|
||||
String sql = parser.parseExpression(type.getSql(), parserContext).getValue(context, String.class);
|
||||
String sql = parser.parseExpression(type.getSqlTemplate(), parserContext).getValue(context, String.class);
|
||||
sqlString.append(sql);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user