ProductAnalysis.cs 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Text;
  4. using TEAMModelOS.SDK.Models.Cosmos;
  5. using TEAMModelOS.SDK.Models.Dtos;
  6. namespace TEAMModelOS.SDK.Models
  7. {
  8. public class ProdAnalysis : ProdAnalysisCalItem
  9. {
  10. public string schoolId { get; set; } //學校ID
  11. }
  12. public class ProdAnalysisApiResult : ProdAnalysis
  13. {
  14. public ProdAnalysisApiResult()
  15. {
  16. school = new SchoolSimple();
  17. }
  18. public SchoolSimple school { get; set; }
  19. public string dateUnit { get; set; }
  20. public string date { get; set; } //日期 [例] 2022、202203、20220314
  21. public int year { get; set; } //统计日期:年
  22. public int month { get; set; } //统计日期:月
  23. public int day { get; set; } //统计日期:日
  24. }
  25. public class ProdAnalysisCosmos : ProdAnalysis
  26. {
  27. public ProdAnalysisCosmos()
  28. {
  29. pk = "ProdAnalysis";
  30. code = "ProdAnalysis";
  31. deviceList = new List<string>();
  32. }
  33. public string pk { get; set; }
  34. public string code { get; set; }
  35. public string id { get; set; }
  36. public string dateUnit { get; set; } //統計日期單位 "year":年統計 "month":月統計 "day":日統計
  37. public string date { get; set; } //统计日期 ※依据dateUnit变化 [例]"year":2023 "month":202302 "day":20230210
  38. public long dateTime { get; set; } //timestamp UTC milisecond 比較時間用
  39. public int year { get; set; } //统计日期:年
  40. public int month { get; set; } //统计日期:月
  41. public int day { get; set; } //统计日期:日
  42. public long createDate { get; set; } //統計時間
  43. public int? ttl { get; set; } = -1;
  44. }
  45. public class SchoolSimple
  46. {
  47. public string name { get; set; }
  48. public string region { get; set; }
  49. public string province { get; set; }
  50. public string city { get; set; }
  51. public string dist { get; set; }
  52. public string areaId { get; set; }
  53. public string type { get; set; }
  54. }
  55. }