ListDto.tt 930 B

123456789101112131415161718192021222324252627282930313233343536
  1. <#@ template language="C#" #>
  2. <#@ assembly name="System.Core" #>
  3. <#@ import namespace="System.Linq" #>
  4. <#@ import namespace="System.Text" #>
  5. <#@ import namespace="System.Collections.Generic" #>
  6. using System;
  7. using Abp.AutoMapper;
  8. using Abp.Application.Services.Dto;
  9. namespace <#=Model.ApplicationNamespace#>.Dto
  10. {
  11. <#
  12. if(!string.IsNullOrEmpty(Model.HtmlPageTitle)){
  13. #>
  14. /// <summary>
  15. /// <#=Model.HtmlPageTitle#>
  16. /// </summary>
  17. <# }
  18. #> [AutoMapTo(typeof(<#=Model.ClassName#>)),AutoMapFrom(typeof(<#=Model.ClassName#>))]
  19. public class <#=Model.FileName#>Dto: EntityDto<<#=Model.IdType#>>
  20. {
  21. <#
  22. foreach (var item in Model.Columns)
  23. {
  24. if(!item.IsGenreated) continue;
  25. if(!string.IsNullOrEmpty(item.Comment)){
  26. #> /// <summary>
  27. /// <#=item.Comment#>
  28. /// </summary>
  29. <# }
  30. #> public <#=item.AttrType#> <#=item.ColumnName#> { get; set; }
  31. <#
  32. }
  33. #>
  34. }
  35. }