ProductAnalysis.cs 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  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. public string tmid { get; set; } //TMID
  12. }
  13. public class ProdAnalysisApiResult : ProdAnalysis
  14. {
  15. public ProdAnalysisApiResult()
  16. {
  17. school = new SchoolSimple();
  18. tmidInfo = new SchoolSimple();
  19. }
  20. public SchoolSimple school { get; set; }
  21. public SchoolSimple tmidInfo { get; set; }
  22. public string dateUnit { get; set; }
  23. public string date { get; set; } //日期 [例] 2022、202203、20220314
  24. public int year { get; set; } //统计日期:年
  25. public int month { get; set; } //统计日期:月
  26. public int day { get; set; } //统计日期:日
  27. }
  28. public class ProdAnalysisCosmos : ProdAnalysis
  29. {
  30. public ProdAnalysisCosmos()
  31. {
  32. pk = "ProdAnalysis";
  33. code = "ProdAnalysis";
  34. deviceList = new List<string>();
  35. }
  36. public string pk { get; set; }
  37. public string code { get; set; }
  38. public string id { get; set; }
  39. public string dateUnit { get; set; } //統計日期單位 "year":年統計 "month":月統計 "day":日統計
  40. public string date { get; set; } //统计日期 ※依据dateUnit变化 [例]"year":2023 "month":202302 "day":20230210
  41. public long dateTime { get; set; } //timestamp UTC milisecond 比較時間用
  42. public int year { get; set; } //统计日期:年
  43. public int month { get; set; } //统计日期:月
  44. public int day { get; set; } //统计日期:日
  45. public long createDate { get; set; } //統計時間
  46. public int? ttl { get; set; } = -1;
  47. }
  48. public class SchoolSimple
  49. {
  50. public string name { get; set; }
  51. public string region { get; set; }
  52. public string province { get; set; }
  53. public string city { get; set; }
  54. public string dist { get; set; }
  55. public string areaId { get; set; }
  56. public string type { get; set; }
  57. }
  58. }