school.interface.ts 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. import { ApiProperty } from '@midwayjs/swagger';
  2. import { Rule, RuleType } from '@midwayjs/validate';
  3. import { dealVO } from '../../frame/VOBase';
  4. export class FVO_school {
  5. constructor(data: object) {
  6. dealVO(this, data);
  7. }
  8. @ApiProperty({ description: '数据id' })
  9. id: string = undefined;
  10. @ApiProperty({ description: '平台用户id' })
  11. 'user': number = undefined;
  12. @ApiProperty({ description: '名称' })
  13. 'name': string = undefined;
  14. @ApiProperty({ description: '负责人' })
  15. 'person': string = undefined;
  16. @ApiProperty({ description: '负责人电话' })
  17. 'person_phone': string = undefined;
  18. @ApiProperty({ description: '简介' })
  19. 'brief': string = undefined;
  20. @ApiProperty({ description: '地址' })
  21. 'address': string = undefined;
  22. @ApiProperty({ description: '是否公开' })
  23. 'is_show': string = undefined;
  24. @ApiProperty({ description: '状态' })
  25. 'status': string = undefined;
  26. }
  27. export class QDTO_school {
  28. @ApiProperty({ description: '平台用户id' })
  29. 'user': number = undefined;
  30. @ApiProperty({ description: '名称' })
  31. 'name': string = undefined;
  32. @ApiProperty({ description: '负责人电话' })
  33. 'person_phone': string = undefined;
  34. @ApiProperty({ description: '是否公开' })
  35. 'is_show': string = undefined;
  36. @ApiProperty({ description: '状态' })
  37. 'status': string = undefined;
  38. }
  39. export class QVO_school extends FVO_school {
  40. constructor(data: object) {
  41. super(data);
  42. dealVO(this, data);
  43. }
  44. }
  45. export class CDTO_school {
  46. @ApiProperty({ description: '平台用户id' })
  47. @Rule(RuleType['number']().empty(''))
  48. 'user': number = undefined;
  49. @ApiProperty({ description: '名称' })
  50. @Rule(RuleType['string']().empty(''))
  51. 'name': string = undefined;
  52. @ApiProperty({ description: '负责人' })
  53. @Rule(RuleType['string']().empty(''))
  54. 'person': string = undefined;
  55. @ApiProperty({ description: '负责人电话' })
  56. @Rule(RuleType['string']().empty(''))
  57. 'person_phone': string = undefined;
  58. @ApiProperty({ description: '简介' })
  59. @Rule(RuleType['string']().empty(''))
  60. 'brief': string = undefined;
  61. @ApiProperty({ description: '地址' })
  62. @Rule(RuleType['string']().empty(''))
  63. 'address': string = undefined;
  64. @ApiProperty({ description: '是否公开' })
  65. @Rule(RuleType['string']().empty(''))
  66. 'is_show': string = undefined;
  67. @ApiProperty({ description: '状态' })
  68. @Rule(RuleType['string']().empty(''))
  69. 'status': string = undefined;
  70. }
  71. export class CVO_school extends FVO_school {
  72. constructor(data: object) {
  73. super(data);
  74. dealVO(this, data);
  75. }
  76. }
  77. export class UDTO_school extends CDTO_school {
  78. @ApiProperty({ description: '数据id' })
  79. @Rule(RuleType['number']().empty(''))
  80. id: number = undefined;
  81. }
  82. export class UVAO_school extends FVO_school {
  83. constructor(data: object) {
  84. super(data);
  85. dealVO(this, data);
  86. }
  87. }