优化数据仓储
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -8,6 +9,7 @@ namespace ZR.Model.System
|
||||
/// 文章表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("article")]
|
||||
[Tenant("0")]
|
||||
public class Article
|
||||
{
|
||||
[SqlSugar.SugarColumn(IsIdentity = true, IsPrimaryKey = true)]
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using Newtonsoft.Json;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
@@ -8,7 +9,8 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 文章目录
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("articleCategory")]
|
||||
[SugarTable("articleCategory")]
|
||||
[Tenant("0")]
|
||||
public class ArticleCategory
|
||||
{
|
||||
public int Category_Id { get; set; }
|
||||
@@ -16,7 +18,7 @@ namespace ZR.Model.System
|
||||
public int ParentId { get; set; }
|
||||
|
||||
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public List<ArticleCategory> Children { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ namespace ZR.Model.System.Generate
|
||||
/// 代码生成表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("gen_table")]
|
||||
[SqlSugar.Tenant("0")]
|
||||
public class GenTable: SysBase
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace ZR.Model.System.Generate
|
||||
/// 代码生成表字段
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("gen_table_column")]
|
||||
[SqlSugar.Tenant("0")]
|
||||
public class GenTableColumn: SysBase
|
||||
{
|
||||
[SqlSugar.SugarColumn(IsIdentity = true, IsPrimaryKey = true)]
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -10,7 +11,8 @@ namespace ZR.Model.System
|
||||
/// @author zhaorui
|
||||
/// @date 2021-09-29
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("sys_config")]
|
||||
[SugarTable("sys_config")]
|
||||
[Tenant("0")]
|
||||
public class SysConfig: SysBase
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -8,7 +8,8 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 部门表
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("sys_dept")]
|
||||
[SugarTable("sys_dept")]
|
||||
[Tenant("0")]
|
||||
public class SysDept: SysBase
|
||||
{
|
||||
/** 部门ID */
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 字典数据表
|
||||
/// </summary>
|
||||
//[Table("sys_dict_data")]
|
||||
[Tenant("0")]
|
||||
[SugarTable("sys_dict_data")]
|
||||
public class SysDictData: SysBase
|
||||
{
|
||||
|
||||
@@ -10,7 +10,7 @@ namespace ZR.Model.System
|
||||
/// 字典类型表
|
||||
/// </summary>
|
||||
[SugarTable("sys_dict_type")]//当和数据库名称不一样可以设置别名
|
||||
//[Table("sys_dict_type")]
|
||||
[Tenant("0")]
|
||||
public class SysDictType : SysBase
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
using System;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace ZR.Model.System
|
||||
{
|
||||
[SqlSugar.SugarTable("sys_file")]
|
||||
[Tenant("0")]
|
||||
[SugarTable("sys_file")]
|
||||
public class SysFile
|
||||
{
|
||||
public int Id { get; set; }
|
||||
|
||||
@@ -8,6 +8,7 @@ namespace ZR.Model.System
|
||||
/// sys_logininfor 表
|
||||
/// </summary>
|
||||
[SugarTable("sys_logininfor")]
|
||||
[Tenant("0")]
|
||||
public class SysLogininfor: SysBase
|
||||
{
|
||||
//[Key]
|
||||
|
||||
@@ -1,12 +1,13 @@
|
||||
using System.Collections.Generic;
|
||||
using SqlSugar;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ZR.Model.System
|
||||
{
|
||||
/// <summary>
|
||||
/// Sys_menu表
|
||||
/// </summary>
|
||||
//[Table("sys_menu")]
|
||||
[SqlSugar.SugarTable("sys_menu")]
|
||||
[SugarTable("sys_menu")]
|
||||
[Tenant("0")]
|
||||
public class SysMenu: SysBase
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -1,25 +1,27 @@
|
||||
using Newtonsoft.Json;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace ZR.Model.System
|
||||
{
|
||||
[SqlSugar.SugarTable("sys_oper_log")]
|
||||
[SugarTable("sys_oper_log")]
|
||||
[Tenant("0")]
|
||||
public class SysOperLog
|
||||
{
|
||||
[SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public long OperId { get; set; }
|
||||
/** 操作模块 */
|
||||
//@Excel(name = "操作模块")
|
||||
public String title { get; set; }
|
||||
public string title { get; set; }
|
||||
|
||||
/** 业务类型(0其它 1新增 2修改 3删除) */
|
||||
//@Excel(name = "业务类型", readConverterExp = "0=其它,1=新增,2=修改,3=删除,4=授权,5=导出,6=导入,7=强退,8=生成代码,9=清空数据")
|
||||
public int businessType { get; set; }
|
||||
|
||||
/** 业务类型数组 */
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public int[] businessTypes { get; set; }
|
||||
|
||||
/** 请求方法 */
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
namespace ZR.Model.System
|
||||
using SqlSugar;
|
||||
|
||||
namespace ZR.Model.System
|
||||
{
|
||||
[SqlSugar.SugarTable("sys_post")]
|
||||
[SugarTable("sys_post")]
|
||||
[Tenant("0")]
|
||||
public class SysPost: SysBase
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using Newtonsoft.Json;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
@@ -8,13 +9,14 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 角色表 sys_role
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("sys_role")]
|
||||
[SugarTable("sys_role")]
|
||||
[Tenant("0")]
|
||||
public class SysRole : SysBase
|
||||
{
|
||||
/// <summary>
|
||||
/// 角色ID
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||
public long RoleId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@@ -40,18 +42,18 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 删除标志(0代表存在 2代表删除)
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsOnlyIgnoreInsert = true, IsOnlyIgnoreUpdate = true)]
|
||||
[SugarColumn(IsOnlyIgnoreInsert = true, IsOnlyIgnoreUpdate = true)]
|
||||
public string DelFlag { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 菜单组
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public long[] MenuIds { get; set; }
|
||||
/// <summary>
|
||||
/// 部门组(数据权限)
|
||||
/// </summary>
|
||||
[SqlSugar.SugarColumn(IsIgnore = true)]
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public long[] DeptIds { get; set; }
|
||||
|
||||
public SysRole() { }
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using Newtonsoft.Json;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
@@ -8,14 +9,15 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 角色菜单
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("sys_role_menu")]
|
||||
[SugarTable("sys_role_menu")]
|
||||
[Tenant("0")]
|
||||
public class SysRoleMenu
|
||||
{
|
||||
[JsonProperty("roleId")]
|
||||
[SqlSugar.SugarColumn(IsPrimaryKey = true)]
|
||||
[SugarColumn(IsPrimaryKey = true)]
|
||||
public long Role_id { get; set; }
|
||||
[JsonProperty("menuId")]
|
||||
[SqlSugar.SugarColumn(IsPrimaryKey = true)]
|
||||
[SugarColumn(IsPrimaryKey = true)]
|
||||
public long Menu_id { get; set; }
|
||||
public DateTime Create_time { get; set; }
|
||||
public string Create_by { get; set; }
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace ZR.Model.System
|
||||
/// 角色部门
|
||||
/// </summary>
|
||||
[SugarTable("sys_role_post")]
|
||||
[Tenant("0")]
|
||||
public class SysRolePost
|
||||
{
|
||||
public long RoleId { get; set; }
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -7,7 +8,8 @@ namespace ZR.Model.System
|
||||
/// <summary>
|
||||
/// 任务日志
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("sys_Tasks_log")]
|
||||
[SugarTable("sys_Tasks_log")]
|
||||
[Tenant("0")]
|
||||
public class SysTasksLog
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -11,6 +11,7 @@ namespace ZR.Model.System
|
||||
///计划任务
|
||||
///</summary>
|
||||
[SugarTable("Sys_TasksQz")]
|
||||
[Tenant("0")]
|
||||
public class SysTasksQz
|
||||
{
|
||||
public SysTasksQz()
|
||||
|
||||
@@ -10,6 +10,7 @@ namespace ZR.Model.System
|
||||
/// 用户表
|
||||
/// </summary>
|
||||
[SugarTable("sys_user")]
|
||||
[Tenant("0")]
|
||||
public class SysUser : SysBase
|
||||
{
|
||||
/// <summary>
|
||||
|
||||
@@ -10,6 +10,7 @@ namespace ZR.Model.System
|
||||
/// 用户岗位
|
||||
/// </summary>
|
||||
[SugarTable("sys_user_post")]
|
||||
[Tenant("0")]
|
||||
public class SysUserPost
|
||||
{
|
||||
public long UserId { get; set; }
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -8,6 +9,7 @@ namespace ZR.Model.System
|
||||
/// 用户角色关联表 用户N-1 角色
|
||||
/// </summary>
|
||||
[SqlSugar.SugarTable("sys_user_role")]
|
||||
[Tenant("0")]
|
||||
public class SysUserRole
|
||||
{
|
||||
[SqlSugar.SugarColumn(ColumnName = "user_id", IsPrimaryKey = true)]
|
||||
|
||||
Reference in New Issue
Block a user