终端一体化运控平台
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
 
 
 

189 rader
5.3 KiB

  1. using BPA.Helper;
  2. using BPA.Message.Enum;
  3. using Newtonsoft.Json;
  4. using System;
  5. using System.Collections.Generic;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9. using System.Windows.Media;
  10. namespace BPASmartClient.ScreenLib
  11. {
  12. /// <summary>
  13. /// 订单制作Model
  14. /// </summary>
  15. public class OrderMakeFormModel : NotifyBase
  16. {
  17. /// <summary>
  18. /// 状态
  19. /// </summary>
  20. private ORDER_STATUS _Status;
  21. public ORDER_STATUS Status
  22. {
  23. get { return _Status; }
  24. set {
  25. _Status = value;
  26. foreground = new SolidColorBrush(Color.FromArgb(255, 0, 204, 255));
  27. switch ((ORDER_STATUS)value)
  28. {
  29. case ORDER_STATUS.WAIT:
  30. MakeStatus = "等待制作";
  31. foreground = new SolidColorBrush(Color.FromArgb(255, 0, 204, 255));
  32. break;
  33. case ORDER_STATUS.COOKING:
  34. MakeStatus = "制作中";
  35. foreground = new SolidColorBrush(Color.FromArgb(255, 0, 255, 127));
  36. break;
  37. case ORDER_STATUS.COMPLETED_COOK:
  38. MakeStatus = "制作完成";
  39. foreground = new SolidColorBrush(Color.FromArgb(255, 255, 215, 00));
  40. break;
  41. case ORDER_STATUS.COMPLETED_TAKE:
  42. MakeStatus = "取餐完成";
  43. foreground = new SolidColorBrush(Color.FromArgb(255, 102, 204, 153));
  44. break;
  45. case ORDER_STATUS.ERR_NOT_REPLY_WHEN_COOKING:
  46. MakeStatus = "取餐完成";
  47. foreground = new SolidColorBrush(Color.FromArgb(255, 255, 0, 0));
  48. break;
  49. default:
  50. MakeStatus = "异常订单";
  51. break;
  52. }
  53. OnPropertyChanged();
  54. }
  55. }
  56. /// <summary>
  57. /// 制作状态
  58. /// </summary>
  59. private string _MakeStatus;
  60. public string MakeStatus
  61. {
  62. get { return _MakeStatus; }
  63. set
  64. {
  65. _MakeStatus = value;
  66. OnPropertyChanged();
  67. }
  68. }
  69. /// <summary>
  70. /// 商品名称
  71. /// </summary>
  72. public string GoodName { get; set; }
  73. /// <summary>
  74. /// 订单排序号
  75. /// </summary>
  76. public string SortNum { get; set; }
  77. /// <summary>
  78. /// 开始时间
  79. /// </summary>
  80. public string StartTime { get; set; }
  81. /// <summary>
  82. /// 结束时间
  83. /// </summary>
  84. public string StopTime { get; set; }
  85. private Brush _foreground;
  86. public Brush foreground
  87. {
  88. get
  89. {
  90. return _foreground;
  91. }
  92. set
  93. {
  94. if (_foreground == value)
  95. return;
  96. _foreground = value;
  97. OnPropertyChanged("foreground");
  98. }
  99. }
  100. }
  101. public class HttpReturn
  102. {
  103. public bool isSuccess { get; set; }
  104. public StoreInfoResponse data { get; set; }
  105. }
  106. public class StoreInfoResponse
  107. {
  108. /// <summary>
  109. /// 档口
  110. /// </summary>
  111. [JsonProperty("gateList")]
  112. public List<StallModelResponse> Stalls { get; set; }
  113. /// <summary>
  114. /// 设备
  115. /// </summary>
  116. [JsonProperty("payCardList")]
  117. public List<DeviceModelResponse> Devices { get; set; }
  118. }
  119. public class StallModelResponse
  120. {
  121. public string Id { get; set; }
  122. /// <summary>
  123. /// 档口名称
  124. /// </summary>
  125. public string Name { get; set; }
  126. /// <summary>
  127. /// 归属门店
  128. /// </summary>
  129. public string StoreId { get; set; }
  130. /// <summary>
  131. /// 收费方式(1,固定金额2,自由设定)
  132. /// </summary>
  133. public int Mode { get; set; }
  134. /// <summary>
  135. /// 收款金额
  136. /// </summary>
  137. public decimal Price { get; set; }
  138. /// <summary>
  139. /// 广告
  140. /// </summary>
  141. public string Remaek { get; set; }
  142. /// <summary>
  143. ///状态0正常,1停用
  144. /// </summary>
  145. public int Status { get; set; }
  146. }
  147. public class DeviceModelResponse
  148. {
  149. public string Id { get; set; }
  150. /// <summary>
  151. /// 刷卡设备名称
  152. /// </summary>
  153. public string Name { get; set; }
  154. /// <summary>
  155. /// 档口id
  156. /// </summary>
  157. public string GateId { get; set; }
  158. /// <summary>
  159. /// 地址
  160. /// </summary>
  161. public string Address { get; set; }
  162. /// <summary>
  163. /// 刷卡间隔时间
  164. /// </summary>
  165. public int SleepTime { get; set; }
  166. /// <summary>
  167. /// 状态0正常,1停用
  168. /// </summary>
  169. public int Status { get; set; }
  170. }
  171. public class AdDTO
  172. {
  173. public string Device { get; set; }
  174. public string Ad { get; set; }
  175. public string Stalls { get; set; }
  176. public string Address { get; set; }
  177. }
  178. }