Loki
3 years ago
13 changed files with 79 additions and 28 deletions
@ -1 +1 @@
|
||||
Subproject commit 940f54e876f1c6ccc6e239c5990d34e83fb02b78 |
||||
Subproject commit beb44f8aa54a4e20a48985d771a0353641df4787 |
@ -0,0 +1,25 @@
|
||||
package cn.iocoder.yudao.module.farm.config; |
||||
|
||||
import cn.iocoder.yudao.framework.datapermission.core.dept.rule.DeptDataPermissionRuleCustomizer; |
||||
import cn.iocoder.yudao.module.farm.dal.dataobject.project.ProjectDO; |
||||
import cn.iocoder.yudao.module.farm.dal.dataobject.task.TaskDO; |
||||
import org.springframework.context.annotation.Bean; |
||||
import org.springframework.context.annotation.Configuration; |
||||
|
||||
@Configuration |
||||
public class FarmPermissionRuleCustomizer { |
||||
|
||||
@Bean |
||||
public DeptDataPermissionRuleCustomizer farmCustomizer(){ |
||||
return rule -> { |
||||
rule.addDeptColumn(ProjectDO.class); |
||||
// user隔离不起作用
|
||||
rule.addUserColumn(ProjectDO.class,"creator"); |
||||
|
||||
rule.addDeptColumn(TaskDO.class); |
||||
rule.addUserColumn(TaskDO.class,"creator"); |
||||
}; |
||||
} |
||||
|
||||
|
||||
} |
Loading…
Reference in new issue