@@ -0,0 +1,32 @@
+namespace ZhonTai.Admin.Domain.Role;
+
+/// <summary>
+/// 数据范围
+/// </summary>
+public enum DataScope
+{
+ /// <summary>
+ /// 全部
+ /// </summary>
+ All = 1,
+ /// 本部门
+ Dept = 2,
+ /// 本部门和下级部门
+ DeptWithChild = 3,
+ /// 指定部门
+ Custom = 4,
+ /// 本人数据
+ Self = 5
+}
@@ -49,6 +49,12 @@ public partial class RoleEntity : EntityFull, ITenant
[Column(MapType = typeof(int))]
public RoleType Type { get; set; }
+ /// 数据范围
+ [Column(MapType = typeof(int))]
+ public DataScope DataScope { get; set; } = DataScope.All;
/// <summary>
/// 说明
/// </summary>