Staff.cs 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. using Cksoft.Unity;
  2. using DllUfpEntity;
  3. using System;
  4. using System.Collections.Generic;
  5. namespace DllUfpEntity
  6. {
  7. [Table("Staff")]
  8. public class Staff : BaseEntity
  9. {
  10. ////自动产生代码开始&&此行不能删除
  11. #region 自动产生代码
  12. public Staff()
  13. {
  14. base.EntityStatusID = 1;
  15. }
  16. [ColDetail(10, "ID", 1, 1, 100, 1, "a.ID", "", 1, 1)]
  17. [Key]
  18. public string ID { get; set; }
  19. [ColDetail(20, "FCode", 1, 1, 100, 1, "a.FCode", "", 1, 1)]
  20. public string FCode { get; set; }
  21. [ColDetail(30, "FName", 1, 1, 100, 1, "a.FName", "", 1, 1)]
  22. public string FName { get; set; }
  23. [ColDetail(40, "Password", 1, 1, 100, 1, "a.Password", "", 1, 1)]
  24. public string Password { get; set; }
  25. [ColDetail(60, "IsSA", 1, 1, 100, 1, "a.IsSA", "", 1, 1)]
  26. public int? IsSA { get; set; }
  27. [ColDetail(50, "Remark", 1, 1, 100, 1, "a.Remark", "", 1, 1)]
  28. public string Remark { get; set; }
  29. [ColDetail(60, "FStatus", 1, 1, 100, 1, "a.FStatus", "", 1, 1)]
  30. public int FStatus { get; set; }
  31. [ColDetail(70, "reccode", 1, 1, 100, 1, "a.RecCode", "", 1, 1)]
  32. public string RecCode { get; set; }
  33. [ColDetail(80, "rectime", 1, 1, 100, 1, "a.RecTime", "", 1, 1)]
  34. public DateTime RecTime { get; set; }
  35. [ColDetail(90, "modcode", 1, 1, 100, 1, "a.ModCode", "", 1, 1)]
  36. public string ModCode { get; set; }
  37. [ColDetail(100, "modtime", 1, 1, 100, 1, "a.ModTime", "", 1, 1)]
  38. public DateTime ModTime { get; set; }
  39. [Ignore]
  40. public string RoleIds { get; set; }
  41. [Ignore]
  42. public string RoleNames { get; set; }
  43. [Ignore]
  44. public IEnumerable<Role> Roles { get; set; }
  45. public override string GetSelectSql()
  46. {
  47. return string.Format($"select { GetQueryColSql()} from { GetQueryTabSql()}");
  48. }
  49. public override string GetQueryColSql()
  50. {
  51. string sqlstr = "a.ID ID,a.FCode FCode,a.FName FName,a.Password Password,a.Remark Remark,a.FStatus FStatus,a.RecCode RecCode,a.RecTime RecTime,a.ModCode ModCode";
  52. sqlstr += ",a.ModTime ModTime,0 EntityStatusID,a.ISSA IsSA";
  53. return sqlstr;
  54. }
  55. public override string GetQueryTabSql()
  56. {
  57. string sqlstr = " Staff a ";
  58. return sqlstr;
  59. }
  60. public override string GetQuerySortSql()
  61. {
  62. return "";
  63. }
  64. #endregion
  65. ////自动产生代码结束&&此行不能删除
  66. /// <summary>
  67. /// 当前员工所拥有的角色
  68. /// </summary>
  69. }
  70. }