labour_request_index_entity.dart 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. import 'package:domain/entity/response/index_option_entity.dart';
  2. import 'package:domain/generated/json/base/json_field.dart';
  3. import 'package:domain/generated/json/labour_request_index_entity.g.dart';
  4. import 'dart:convert';
  5. export 'package:domain/generated/json/labour_request_index_entity.g.dart';
  6. @JsonSerializable()
  7. class LabourRequestIndexEntity {
  8. @JSONField(name: "department_list")
  9. List<LabourRequestIndexDepartmentList>? departmentList = [];
  10. @JSONField(name: "outlet_list")
  11. List<LabourRequestIndexDepartmentList>? outletList = [];
  12. @JSONField(name: "status_list")
  13. List<LabourRequestIndexStatusList>? statusList = [];
  14. @JSONField(name: "division_list")
  15. List<IndexOptionEntity> divisionList = [];
  16. LabourRequestIndexEntity();
  17. factory LabourRequestIndexEntity.fromJson(Map<String, dynamic> json) => $LabourRequestIndexEntityFromJson(json);
  18. Map<String, dynamic> toJson() => $LabourRequestIndexEntityToJson(this);
  19. @override
  20. String toString() {
  21. return jsonEncode(this);
  22. }
  23. }
  24. @JsonSerializable()
  25. class LabourRequestIndexDepartmentList {
  26. String? value = '';
  27. String? txt = '';
  28. String? selected = '';
  29. LabourRequestIndexDepartmentList();
  30. factory LabourRequestIndexDepartmentList.fromJson(Map<String, dynamic> json) => $LabourRequestIndexDepartmentListFromJson(json);
  31. Map<String, dynamic> toJson() => $LabourRequestIndexDepartmentListToJson(this);
  32. @override
  33. String toString() {
  34. return jsonEncode(this);
  35. }
  36. }
  37. @JsonSerializable()
  38. class LabourRequestIndexStatusList {
  39. String? value = '';
  40. String? txt = '';
  41. String? selected = '';
  42. LabourRequestIndexStatusList();
  43. factory LabourRequestIndexStatusList.fromJson(Map<String, dynamic> json) => $LabourRequestIndexStatusListFromJson(json);
  44. Map<String, dynamic> toJson() => $LabourRequestIndexStatusListToJson(this);
  45. @override
  46. String toString() {
  47. return jsonEncode(this);
  48. }
  49. }