CodeRuleSeedEntity.cs 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. using LeaRun.Application.Code;
  2. using System;
  3. namespace LeaRun.Application.Entity.SystemManage
  4. {
  5. /// <summary>
  6. /// 版 本 6.1
  7. /// Copyright (c) 2013-2016 上海力软信息技术有限公司
  8. /// 创建人:佘赐雄
  9. /// 日 期:2015.12.21 16:19
  10. /// 描 述:编号规则种子
  11. /// </summary>
  12. public class CodeRuleSeedEntity : BaseEntity
  13. {
  14. #region 实体成员
  15. /// <summary>
  16. /// 编号规则种子主键
  17. /// </summary>
  18. public string RuleSeedId { get; set; }
  19. /// <summary>
  20. /// 编码规则主键
  21. /// </summary>
  22. public string RuleId { get; set; }
  23. /// <summary>
  24. /// 用户主键
  25. /// </summary>
  26. public string UserId { get; set; }
  27. /// <summary>
  28. /// 种子值
  29. /// </summary>
  30. public int? SeedValue { get; set; }
  31. /// <summary>
  32. /// 创建日期
  33. /// </summary>
  34. public DateTime? CreateDate { get; set; }
  35. /// <summary>
  36. /// 创建用户主键
  37. /// </summary>
  38. public string CreateUserId { get; set; }
  39. /// <summary>
  40. /// 创建用户
  41. /// </summary>
  42. public string CreateUserName { get; set; }
  43. /// <summary>
  44. /// 修改日期
  45. /// </summary>
  46. public DateTime? ModifyDate { get; set; }
  47. /// <summary>
  48. /// 修改用户主键
  49. /// </summary>
  50. public string ModifyUserId { get; set; }
  51. /// <summary>
  52. /// 修改用户
  53. /// </summary>
  54. public string ModifyUserName { get; set; }
  55. #endregion
  56. #region 扩展操作
  57. /// <summary>
  58. /// 新增调用
  59. /// </summary>
  60. public override void Create()
  61. {
  62. this.RuleSeedId = Guid.NewGuid().ToString();
  63. this.CreateDate = DateTime.Now;
  64. this.ModifyDate = DateTime.Now;
  65. this.CreateUserId = OperatorProvider.Provider.Current().UserId;
  66. this.CreateUserName = OperatorProvider.Provider.Current().UserName;
  67. }
  68. /// <summary>
  69. /// 编辑调用
  70. /// </summary>
  71. /// <param name="keyValue"></param>
  72. public override void Modify(string keyValue)
  73. {
  74. this.ModifyDate = DateTime.Now;
  75. this.ModifyUserId = OperatorProvider.Provider.Current().UserId;
  76. this.ModifyUserName = OperatorProvider.Provider.Current().UserName;
  77. }
  78. #endregion
  79. }
  80. }