终端一体化运控平台
Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.
 
 
 

142 Zeilen
4.3 KiB

  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace BPASmartClient.MorkT_Container
  7. {
  8. internal enum GOODS_TYPE
  9. {
  10. /// <summary>
  11. /// 未知
  12. /// </summary>
  13. NEITHER,
  14. /// <summary>
  15. /// 咖啡
  16. /// </summary>
  17. COFFEE,
  18. /// <summary>
  19. /// 果汁
  20. /// </summary>
  21. JUICE,
  22. /// <summary>
  23. /// 茶水
  24. /// </summary>
  25. TEA,
  26. /// <summary>
  27. /// 水
  28. /// </summary>
  29. WATER,
  30. /// <summary>
  31. /// 杯子
  32. /// </summary>
  33. CUP
  34. }
  35. internal enum BATCHING_CLASS
  36. {
  37. HOLDER,
  38. MAIN_MATERIAL,
  39. }
  40. internal class PolymerBatching
  41. {
  42. internal const string Juicer_MAIN_BATCHIN1_LOC = "52";
  43. internal const string Juicer_MAIN_BATCHIN2_LOC = "53";
  44. internal const string Juicer_MAIN_BATCHIN3_LOC = "54";
  45. internal const string Juicer_MAIN_BATCHIN4_LOC = "55";
  46. //internal const string Juicer_MAIN_BATCHIN5_LOC = "56";
  47. //internal const string Juicer_MAIN_BATCHIN6_LOC = "57";
  48. //internal const string Juicer_MAIN_BATCHIN7_LOC = "58";
  49. //internal const string Juicer_MAIN_BATCHIN8_LOC = "59";
  50. internal const string COFFEE_HOLDER_LOC = "30";
  51. internal const string TEA_HOLDER_LOC = "51";
  52. public static Dictionary<string, GOODS_TYPE> GOODS_TYPES = new Dictionary<string, GOODS_TYPE>() {
  53. {"1", GOODS_TYPE.COFFEE},
  54. {"2", GOODS_TYPE.COFFEE},
  55. {"3", GOODS_TYPE.COFFEE},
  56. {"4", GOODS_TYPE.COFFEE},
  57. {"5", GOODS_TYPE.COFFEE},
  58. {"6", GOODS_TYPE.COFFEE},
  59. {"7", GOODS_TYPE.COFFEE},
  60. {"8", GOODS_TYPE.COFFEE},
  61. {"9", GOODS_TYPE.COFFEE},
  62. {"10",GOODS_TYPE.COFFEE},
  63. {"11",GOODS_TYPE.COFFEE},
  64. {"12",GOODS_TYPE.COFFEE},
  65. {"13",GOODS_TYPE.COFFEE},
  66. {"14",GOODS_TYPE.COFFEE},
  67. {"15",GOODS_TYPE.COFFEE},
  68. {"16",GOODS_TYPE.COFFEE},
  69. {"17",GOODS_TYPE.COFFEE},
  70. {"18",GOODS_TYPE.COFFEE},
  71. {"19",GOODS_TYPE.COFFEE},
  72. {"20",GOODS_TYPE.COFFEE},
  73. {"21",GOODS_TYPE.COFFEE},
  74. {"22",GOODS_TYPE.COFFEE},
  75. {"23",GOODS_TYPE.COFFEE},
  76. {"24",GOODS_TYPE.COFFEE},
  77. {"25",GOODS_TYPE.COFFEE},
  78. };
  79. public GOODS_TYPE GoodsType { get; set; }
  80. public BATCHING_CLASS BatchingClass { get; set; }
  81. private string loc;
  82. public string Loc
  83. {
  84. get { return loc; }
  85. set
  86. {
  87. loc = value;
  88. if (GOODS_TYPES.ContainsKey(loc))
  89. GoodsType = GOODS_TYPES[loc];
  90. switch (loc)
  91. {
  92. case COFFEE_HOLDER_LOC:
  93. case TEA_HOLDER_LOC:
  94. BatchingClass = BATCHING_CLASS.HOLDER;
  95. break;
  96. default:
  97. BatchingClass = BATCHING_CLASS.MAIN_MATERIAL;
  98. break;
  99. }
  100. }
  101. }
  102. internal static Dictionary<string, PolymerBatching> BuildAll()
  103. {
  104. Dictionary<string, PolymerBatching> temp = new Dictionary<string, PolymerBatching>();
  105. foreach (var item in GOODS_TYPES)
  106. {
  107. temp.Add(item.Key, new PolymerBatching() { Loc = item.Key });
  108. }
  109. return temp;
  110. }
  111. //internal static IC_SE GetIceCreamSE(string loc, out string sence)
  112. //{
  113. // switch (loc)
  114. // {
  115. // case Juicer_MAIN_BATCHIN1_LOC:
  116. // sence = JaKaHelper.SENCE_接果汁1;
  117. // return IC_SE.SE_1;
  118. // case Juicer_MAIN_BATCHIN2_LOC:
  119. // sence = JaKaHelper.SENCE_接果汁2;
  120. // return IC_SE.SE_2;
  121. // case Juicer_MAIN_BATCHIN3_LOC:
  122. // sence = JaKaHelper.SENCE_接果汁3;
  123. // return IC_SE.SE_3;
  124. // default:
  125. // sence = JaKaHelper.SENCE_接果汁1;
  126. // return IC_SE.SE_1;
  127. // }
  128. //}
  129. }
  130. }