StructList.cs 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475
  1. using System;
  2. using System.Collections.Generic;
  3. namespace MOKA_Factory_Tools
  4. {
  5. class StructList
  6. {
  7. public static string CheckServerConnectionUrl = "https://cn.uc.qhmoka.com/scbc-server";//检查网络是否通顺对应URL
  8. }
  9. public class LocalPath
  10. {
  11. public static string localpath { get; set; }= AppDomain.CurrentDomain.BaseDirectory;
  12. }
  13. public class MidList
  14. {
  15. public string message { get; set; }
  16. public string code { get; set; }
  17. public string factoryname { get; set; }
  18. public string factoryip { get; set; }
  19. public string factoryNum { get; set; }
  20. public string version { get; set; }
  21. public string projectid { get; set; }
  22. public string clienttype { get; set; }
  23. public string host { get; set; }
  24. public string quantity { get; set; }
  25. public string whiteType { get; set; }
  26. public RokuCustomer rokuCustomer { get; set; }
  27. public Dictionary <string,string> keytype { get; set; }
  28. }
  29. public class RokuCustomer
  30. {
  31. public string id { get; set; }
  32. public string ordernum { get; set; }
  33. public string brand { get; set; }
  34. public string region { get; set; }
  35. public string oemmodel { get; set; }
  36. public string supporturl { get; set; }
  37. public string supportphone { get; set; }
  38. public string productiondate { get; set; }
  39. public string remotetype { get; set; }
  40. public string updatetime { get; set; }
  41. public string createtime { get; set; }
  42. public string isdelete { get; set; }
  43. }
  44. public class WhiteBalanceInput
  45. {
  46. public string bid { get; set; }
  47. public string mac { get; set; }
  48. }
  49. public class WhiteBalanceList
  50. {
  51. public string message { get; set; }
  52. public string code { get; set; }
  53. public WhiteBalanceInfo whiteBalanceInfo { get; set; }
  54. }
  55. public class WhiteBalanceInfo
  56. {
  57. public string id { get; set; }
  58. public string ordernum { get; set; }
  59. public string hdmirgain { get; set; }
  60. public string hdmiggain { get; set; }
  61. public string hdmibgain { get; set; }
  62. public string nrgain { get; set; }
  63. public string nggain { get; set; }
  64. public string nbgain { get; set; }
  65. public string lrgain { get; set; }
  66. public string lggain { get; set; }
  67. public string lbgain { get; set; }
  68. public string updatetime { get; set; }
  69. public string createtime { get; set; }
  70. public string isdelete { get; set; }
  71. public string isExemption { get; set; }
  72. }
  73. public class MidAddress
  74. {
  75. public string host { get; set; }
  76. public string order { get; set; }
  77. public string number { get; set; }
  78. public string pid { get; set; }
  79. public string ctype { get; set; }
  80. public string version { get; set; }
  81. public string purl { get; set; }
  82. public string psize { get; set; }
  83. public string pmd5 { get; set; }
  84. public string status { get; set; }
  85. public string start_date { get; set; }
  86. public string finish_date { get; set; }
  87. public string des { get; set; }
  88. public string code { get; set; }
  89. }
  90. public class OrderInput
  91. {
  92. public string clientType { get; set; }
  93. public string version { get; set; }
  94. public string bid { get; set; }
  95. public string mac { get; set; }
  96. }
  97. public class DBKeysStringFormat
  98. {
  99. public string cikey { get; set; }
  100. public string esn { get; set; }
  101. public string hdcp { get; set; }
  102. public string widevine { get; set; }
  103. public string hdcp22 { get; set; }
  104. public string did { get; set; }
  105. public string mac { get; set; }
  106. public string widi { get; set; }
  107. public string mgk { get; set; }
  108. public string attestation { get; set; }
  109. }
  110. public class FunctionSetting
  111. {
  112. public string TVCOM { get; set; }
  113. public string TVBaud { get; set; }
  114. public string ChannelList { get; set; }
  115. public bool WriteChannel { get; set; }
  116. public bool WriteOSD { get; set; }
  117. public string OSDList { get; set; }
  118. public bool WriteSHOP { get; set; }
  119. public string SHOPList { get; set; }
  120. public bool WriteWB { get; set; }
  121. public bool WBInit { get; set; }
  122. public string WBPath { get; set; }
  123. public string WBFileName { get; set; }
  124. public byte[] ChannelCode { get; set; }
  125. public byte[] OSDLCode { get; set; }
  126. public byte[] ShopLCode { get; set; }
  127. public byte[] NormalRGB { get; set; }
  128. public byte[] CoolRGB { get; set; }
  129. public byte[] WarmRGB { get; set; }
  130. public int EnterFactoryRetry { get; set; }
  131. public int Wait_after_completion { get; set; }
  132. public int LocalDidSize { get; set; }
  133. public int LocalMacSize { get; set; }
  134. public int LocalHdcpSize { get; set; }
  135. public int LocalWidiSize { get; set; }
  136. public int LocalHdcp22Size { get; set; }
  137. public int LocalEsnSize { get; set; }
  138. public int LocalMGKSize { get; set; }
  139. public int LocalCiSize { get; set; }
  140. public int LocalWidevineSize { get; set; }
  141. public int LocalFairplaySize { get; set; }
  142. public int LocalECPSize { get; set; }
  143. public int LocalWifiMacSize { get; set; }
  144. public int LocalBTMacSize { get; set; }
  145. public bool NoDoublewrite { get; set; }//Local DB模式下不允许扫描已经抄写过的SN
  146. public string BarcodeKeyword { get; set; }
  147. public int BarcodeLength { get; set; }
  148. public bool BarcodeLimit { get; set; }
  149. public bool BarcodeWrite { get; set; }
  150. public int SerailDelay { get; set; }
  151. public bool UsingLocalServer { get; set; }
  152. public Dictionary<string, string> CustomCMD { get; set; }
  153. /// <summary>
  154. /// 允许不用扫条码抄写(单击按钮);
  155. /// </summary>
  156. public bool AllowNoScanning { get; set; }
  157. public int ReportTimeOut { get; set; }
  158. /// <summary>
  159. /// 是否启用G客户防呆措施;
  160. /// </summary>
  161. public bool UsingGFoolProofing { get; set; } = false;
  162. /// <summary>
  163. /// G客户防呆抄写次数限制,默认2次;
  164. /// </summary>
  165. public int GFoolProofingCount { get; set; } = 2;
  166. /// <summary>
  167. /// 是否导出日本板卡的ACAS ID与SN号;
  168. /// </summary>
  169. public bool ExportSNACASID { get; set; } = false;
  170. }
  171. public class KeyInfo
  172. {
  173. public string DID { get; set; }
  174. public string Mac { get; set; }
  175. public string HDCP { get; set; }
  176. public string HDCP22 { get; set; }
  177. public string ESN { get; set; }
  178. public string WiDi { get; set; }
  179. public string Widevine { get; set; }
  180. public string CI_plus { get; set; }
  181. public string Attestation { get; set; }
  182. public string AttestationMD5 { get; set; }
  183. public string MGK { get; set; }
  184. public string Fairplay { get; set; }
  185. public string DSN { get; set; }
  186. public string WiFi_MAC { get; set; }
  187. public string BT_MAC { get; set; }
  188. public string LEK { get; set; }
  189. public string PEK { get; set; }
  190. public string Playready { get; set; }
  191. public string Hashkey { get; set; }
  192. public string ECP { get; set; }
  193. public string YouTube_KEY { get; set; }
  194. public string EDIDPid { get; set; }
  195. public string EDIDModelName { get; set; }
  196. public string ACASKey { get; set; }
  197. public string ACASKeyMd5 { get; set; }
  198. }
  199. public class FireTVKey
  200. {
  201. public bool LEK { get; set; }
  202. public bool PEK { get; set; }
  203. public bool Playready { get; set; }
  204. public bool Hashkey { get; set; }
  205. }
  206. public class FireTVDsnInput
  207. {
  208. public string ordernum { get; set; }
  209. public string fsn { get; set; }
  210. public string psn { get; set; }
  211. public string deviceCode { get; set; }
  212. public string mac { get; set; }
  213. }
  214. public class ReadCheck
  215. {
  216. public bool PIDReadcheck { get; set; }
  217. public bool OSDReadcheck { get; set; }
  218. public bool SHOPReadcheck { get; set; }
  219. public bool DIDReadcheck { get; set; }
  220. public bool MacReadcheck { get; set; }
  221. public bool HDCPReadcheck { get; set; }
  222. public bool HDCP22Readcheck { get; set; }
  223. public bool ESNReadcheck { get; set; }
  224. public bool WiDiReadcheck { get; set; }
  225. public bool WidevineReadcheck { get; set; }
  226. public bool CI_plusReadcheck { get; set; }
  227. public bool AttestationReadcheck { get; set; }
  228. public bool MGKReadcheck { get; set; }
  229. public bool FairplayReadcheck { get; set; }
  230. public bool ECPReadcheck { get; set; }
  231. public bool WifiMacReadcheck { get; set; }
  232. public bool BTMacReadcheck { get; set; }
  233. public bool LEKReadcheck { get; set; }
  234. public bool PEKReadcheck { get; set; }
  235. public bool PlayreadyReadcheck { get; set; }
  236. public bool HashReadcheck { get; set; }
  237. public bool DSNReadcheck { get; set; }
  238. public bool YouTubeReadcheck { get; set; }
  239. public bool EDIDPIDReadcheck { get; set; }
  240. public bool EDIDModeNameReadcheck { get; set; }
  241. public bool ACASKeyReadcheck { get; set; }
  242. public bool ACASIDReadcheck { get; set; }
  243. }
  244. public class WriteCheck
  245. {
  246. public bool DIDCheckcheck { get; set; }
  247. public bool MacCheckcheck { get; set; }
  248. public bool HDCPCheckcheck { get; set; }
  249. public bool HDCP22Checkcheck { get; set; }
  250. public bool ESNCheckcheck { get; set; }
  251. public bool WiDiCheckcheck { get; set; }
  252. public bool WidevineCheckcheck { get; set; }
  253. public bool CI_plusCheckcheck { get; set; }
  254. public bool AttestationCheckcheck { get; set; }
  255. public bool MGKCheckcheck { get; set; }
  256. public bool FairplayCheckcheck { get; set; }
  257. public bool ECPCheckcheck { get; set; }
  258. public bool WifiMacCheckcheck { get; set; }
  259. public bool BTMacCheckcheck { get; set; }
  260. public bool LEKCheckcheck { get; set; }
  261. public bool PEKCheckcheck { get; set; }
  262. public bool PlayreadyCheckcheck { get; set; }
  263. public bool HashCheckcheck { get; set; }
  264. public bool DSNCheckcheck { get; set; }
  265. public bool YouTubeCheckcheck { get; set; }
  266. public bool ACASKeyCheckcheck { get; set; }
  267. }
  268. public class WriteDone
  269. {
  270. public bool PIDWrite_YesNo { get; set; }
  271. public int PIDWriteDelay { get; set; }
  272. public bool AutoWhiteBalance { get; set; }
  273. public bool ChannelWrite_YesNo { get; set; }
  274. public bool OSDWrite_YesNo { get; set; }
  275. public bool SHOPWrite_YesNo { get; set; }
  276. public bool ClientTypeCheck_YesNo { get; set; }
  277. public bool SoftwareVersionCheck_YesNo { get; set; }
  278. public bool DIDWrite_YesNo { get; set; }
  279. public bool MacWrite_YesNo { get; set; }
  280. public bool HDCPWrite_YesNo { get; set; }
  281. public bool HDCP22Write_YesNo { get; set; }
  282. public bool ESNWrite_YesNo { get; set; }
  283. public bool WiDiWrite_YesNo { get; set; }
  284. public bool WidevineWrite_YesNo { get; set; }
  285. public bool CI_plusWrite_YesNo { get; set; }
  286. public bool AttestationWrite_YesNo { get; set; }
  287. public bool MGKWrite_YesNo { get; set; }
  288. public bool FairplayWrite_YesNo { get; set; }
  289. public bool ECPWrite_YesNo { get; set; }
  290. public bool WifiMacWrite_YesNo { get; set; }
  291. public bool BTMacWrite_YesNo { get; set; }
  292. public bool LEKWrite_YesNo { get; set; }
  293. public bool PEKWrite_YesNo { get; set; }
  294. public bool PlayreadyWrite_YesNo { get; set; }
  295. public bool HashWrite_YesNo { get; set; }
  296. public bool DSNWrite_YesNo { get; set; }
  297. public bool YouTubeWrite_YesNo { get; set; }
  298. public bool EDIDPIDWrite_YesNo { get; set; }
  299. public bool EDIDModeNameWrite_YesNo { get; set; }
  300. public bool ACASKeyWrite_YesNo { get; set; }
  301. }
  302. public class ErrorInfo
  303. {
  304. public string reportType { get; set; }
  305. public string reportData { get; set; }
  306. public string version { get; set; }
  307. public string factory { get; set; }
  308. public string mac { get; set; }
  309. public string reportTime { get; set; }
  310. }
  311. public class UpgradeCheckInput
  312. {
  313. public string appid { get; set; }
  314. public string devicemodel { get; set; }
  315. public string dnum { get; set; }
  316. public string ver { get; set; }
  317. public string type { get; set; }
  318. }
  319. public class UpgradeMsgList
  320. {
  321. public string servertime { get; set; }
  322. public string callid { get; set; }
  323. public string state { get; set; }
  324. public string note { get; set; }
  325. public string language { get; set; }
  326. public UpgradeMsgList2 upgrade { get; set; }
  327. public string apiversion { get; set; }
  328. }
  329. public class UpgradeReportInput
  330. {
  331. public string appid { get; set; }
  332. public string devmodel { get; set; }
  333. public string dnum { get; set; }
  334. public string ver { get; set; }
  335. public string result { get; set; }
  336. public string type { get; set; }
  337. }
  338. public class UpgradeMsgList2
  339. {
  340. public string type { get; set; }
  341. public string appid { get; set; }
  342. public string apptype { get; set; }
  343. public string version { get; set; }
  344. public string verid { get; set; }
  345. public object md5 { get; set; }
  346. public string size { get; set; }
  347. public string minicon { get; set; }
  348. public object midicon { get; set; }
  349. public string fileurl { get; set; }
  350. public string increment { get; set; }
  351. public object appendver { get; set; }
  352. public string updatetime { get; set; }
  353. }
  354. public static class Serverurl
  355. {
  356. public static string Testurl = "http://test.scbc.qhmoka.com/scbc-server/clientType/getMessage.do";//测试用服务器
  357. public static string Officialurl = "https://cn.uc.qhmoka.com/scbc-server/clientType/getMessage.do";//生产用服务器
  358. }
  359. public static class UpgradeUrl
  360. {
  361. public static string Officialurl = "https://cn.ota.qhmoka.com/ota-services/upmp/upgradeIncrForTool";//生产用升级检查接口
  362. public static string Testurl = "https://test.uc.qhmoka.com/ota-services/upmp/upgradeIncrForTool";//测试用升级检查接口
  363. }
  364. public static class UpgradeReportUrl
  365. {
  366. public static string Officialurl = "https://cn.ota.qhmoka.com/ota-services/upmp/operateInterfaceForPC";//生产用升级上报接口
  367. //public static string Testurl = "https://test.uc.qhmoka.com/ota-services/upmp/operateInterfaceForPC";//测试用升级上报接口
  368. }
  369. public static class ErrorreportServerurl
  370. {
  371. public static string Testurl = "http://test.micro.server.qhmoka.com/report/reportToolsLog";//异常上报测试服务器
  372. public static string Officialurl = "https://ap.micro.server.qhmoka.com/report/reportToolsLog";//异常上报正式服务器
  373. }
  374. public static class GetWhiteBalanceInfoUrl
  375. {
  376. public static string Testurl = "http://test.scbc.qhmoka.com/scbc-server/clientType/getBalanceMessage.do";//获取订单白平衡配置测试接口
  377. public static string Officialurl = "https://cn.uc.qhmoka.com/scbc-server/clientType/getBalanceMessage.do";//获取订单白平衡配置正式接口
  378. }
  379. public static class FireTVDsnUrl
  380. {
  381. public static string Testurl = "http://test.scbc.qhmoka.com/scbc-server/dsn/";//获取FireTV DSN相关测试接口
  382. public static string Officialurl = "https://cn.uc.qhmoka.com/scbc-server/dsn/";//获取FireTV DSN相关正式接口
  383. }
  384. public static class Loginurl
  385. {
  386. public static string Testurl = "http://test.scbc.qhmoka.com/scbc-server/login.do";//测试用登录接口
  387. public static string Officialurl = "https://cn.uc.qhmoka.com/scbc-server/login.do";//生产用登录接口
  388. }
  389. public class LoginInput
  390. {
  391. public string account { get; set; }
  392. public string password { get; set; }
  393. public string mac { get; set; }
  394. }
  395. public class LoginOutput
  396. {
  397. public string msg { get; set; }
  398. public string code { get; set; }
  399. public string factoryname { get; set; }
  400. public string factorynum { get; set; }
  401. }
  402. public static class TestMode
  403. {
  404. // 默认为正式服务器;
  405. public static bool testMode = false;
  406. public static string MAC = CommonMethod.GetMacAddress();
  407. public static string loginUrl = Loginurl.Officialurl;
  408. public static string fireTVDsnUrl = FireTVDsnUrl.Officialurl;
  409. public static string getWhiteBalanceInfoUrl = GetWhiteBalanceInfoUrl.Officialurl;
  410. public static string errorreportServerurl = ErrorreportServerurl.Officialurl;
  411. public static string upgradeReportUrl = UpgradeReportUrl.Officialurl;
  412. public static string upgradeUrl = UpgradeUrl.Officialurl;
  413. public static string serverurl = Serverurl.Officialurl;
  414. public static void SetTestMode(bool simulation = false)
  415. {
  416. if (simulation)
  417. {// 模拟测试时使用测试服务器;
  418. loginUrl = Loginurl.Testurl;
  419. fireTVDsnUrl = FireTVDsnUrl.Testurl;
  420. getWhiteBalanceInfoUrl = GetWhiteBalanceInfoUrl.Testurl;
  421. errorreportServerurl = ErrorreportServerurl.Testurl;
  422. upgradeReportUrl = UpgradeReportUrl.Officialurl;
  423. upgradeUrl = UpgradeUrl.Testurl;
  424. serverurl = Serverurl.Testurl;
  425. }
  426. else
  427. {
  428. loginUrl = Loginurl.Officialurl;
  429. fireTVDsnUrl = FireTVDsnUrl.Officialurl;
  430. getWhiteBalanceInfoUrl = GetWhiteBalanceInfoUrl.Officialurl;
  431. errorreportServerurl = ErrorreportServerurl.Officialurl;
  432. upgradeReportUrl = UpgradeReportUrl.Officialurl;
  433. upgradeUrl = UpgradeUrl.Officialurl;
  434. serverurl = Serverurl.Officialurl;
  435. }
  436. }
  437. }
  438. }