schangxiang@126.com
2025-11-04 f5ed29dc26c7cd952d56ec5721a2efc43cd25992
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
using DataEntity;
using DataEntity.Share;
using DataRWDAL;
using DataRWDalDrive.DB;
using HxEnum;
using MySqlX.XDevAPI.Common;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.IO;
using System.Linq;
using System.Windows;
using System.Windows.Media.Media3D;
using XCommon.Log;
using XImagingXhandler.XDAL;
 
namespace XHandler.Class.DataEx
{
    public enum PickMode
    {
        Choice,
        Puncture,
        Aspirate
    }
 
    public enum CoatingMode
    {
        HuiMode,
        ZMode
    }
 
    public enum PickPosition
    {
        /// <summary>
        /// 皿底部
        /// </summary>
        DishBottom,
        /// <summary>
        /// 菌表面
        /// </summary>
        BacterialSurface,
 
    }
 
    public class DataModule
    {
 
        private static DataModule _instance;
        public static DataModule getInstance()
        {
            if (_instance == null)
            {
                _instance = new DataModule();
                return _instance;
            }
            return _instance;
        }
 
        /// <summary>
        /// 获取机械臂信息
        /// </summary>
        private List<DeviceArm> deviceArms;
        public List<DeviceArm> GetDeviceArm(bool bRefresh = false, bool insert = true)
        {
            if (bRefresh)
            {
                deviceArms = DeviceArmDB.GetDeviceArmFromdb(Shared.SoftwareInformation.software_information_id);
                if (insert)
                {
                    DeviceArm da = new DeviceArm();
                    da.head_type = Properties.Resources.strPlsSelect;
                    da.device_arm_name = Properties.Resources.strPlsSelect;
                    da.arm_type = -1;
                    deviceArms.Insert(0, da);
                }
            }
            else
            {
                if (deviceArms == null)
                {
                    deviceArms = DeviceArmDB.GetDeviceArmFromdb(Shared.SoftwareInformation.software_information_id);
                    if (insert)
                    {
                        DeviceArm da = new DeviceArm();
                        da.head_type = Properties.Resources.strPlsSelect;
                        da.device_arm_name = Properties.Resources.strPlsSelect;
                        da.arm_type = -1;
                        deviceArms.Insert(0, da);
                    }
                }
            }
            return deviceArms;
        }
 
        public List<DeviceArm> GetDeviceArmWithAll()
        {
            List<DeviceArm> result = null;
            //if (deviceArms == null)
            //{
                deviceArms = DeviceArmDB.GetDeviceArmFromdb(Shared.SoftwareInformation.software_information_id);
                result = deviceArms.Where(x => x.arm_type.Equals(1)).ToList();
                DeviceArm da = new DeviceArm();
                da.head_type = Properties.Resources.strAllArm;
                da.device_arm_name = Properties.Resources.strAllArm;
                da.arm_type = -1;
                result.Insert(0, da);
            //}
            return result;
        }
 
        private ObservableCollection<LiquidType> liquidTypes;
        public ObservableCollection<LiquidType> GetLiquidTypes(bool bRefresh = false, bool insert = true)
        {
            if (bRefresh)
            {
                liquidTypes = LiquidTypeDB.GetLiquidTypeFromdb(2);
                if (insert)
                {
                    LiquidType lt = new LiquidType();
                    lt.liquid_type_id = string.Empty;
                    lt.liquid_type_name = Properties.Resources.strLiquidType;
                    liquidTypes.Insert(0, lt);
                }
            }
            else
            {
                if (liquidTypes == null)
                {
                    liquidTypes = LiquidTypeDB.GetLiquidTypeFromdb(2);
                    if (insert)
                    {
                        LiquidType lt = new LiquidType();
                        lt.liquid_type_id = string.Empty;
                        lt.liquid_type_name = Properties.Resources.strPlsSelectType;
                        liquidTypes.Insert(0, lt);
                    }
                }
            }
            return liquidTypes;
        }
 
        #region 获取液体范围类型
        private ObservableCollection<LiquidRange> liquidRanges;
        public ObservableCollection<LiquidRange> GetLiquidRanges(bool bRefresh = false, bool insert = true)
        {
            if (bRefresh)
            {
                liquidRanges = LiquidRangeDB.GetLiquidRangeFromdb();
                if (insert)
                {
                    LiquidRange lr = new LiquidRange();
                    lr.liquid_range_id = "-1";
                    lr.liquid_range_name = Properties.Resources.strPlsSelectRage;
                    liquidRanges.Insert(0, lr);
                }
            }
            else
            {
                if (liquidRanges == null)
                {
                    liquidRanges = LiquidRangeDB.GetLiquidRangeFromdb();
                    if (insert)
                    {
                        LiquidRange lr = new LiquidRange();
                        lr.liquid_range_id = "-1";
                        lr.liquid_range_name = Properties.Resources.strPlsSelectRage;
                        liquidRanges.Insert(0, lr);
                    }
                }
            }
            return liquidRanges;
        }
        #endregion
 
        private ObservableCollection<LabwareType> labwareTypes;
        public ObservableCollection<LabwareType> GetLabwareTypes(bool bRefresh = false, bool insert = true)
        {
            if (bRefresh)
            {
                labwareTypes = LabwareTypeDB.GetLabwareTypeFromdb(1);
                //if (insert)
                //{
                //    LabwareType type = new LabwareType();
                //    type.labwaretype_name = Properties.Resources.strAllType;
                //    labwareTypes.Insert(0, type);
                //}
            }
            else
            {
                if (labwareTypes == null)
                {
                    labwareTypes = LabwareTypeDB.GetLabwareTypeFromdb(1);
                    //if (insert)
                    //{
                    //    LabwareType type = new LabwareType();
                    //    type.labwaretype_name = Properties.Resources.strAllType;
                    //    labwareTypes.Insert(0, type);
                    //}
                }
            }
            return labwareTypes;
        }
 
        private ObservableCollection<Labware> labwares;
        public ObservableCollection<Labware> GetLabwares(bool bRefresh = false)
        {
            if (bRefresh)
                labwares = DataRWDAL.LabwareDB.GetLabware(2);
            else
            {
                if (labwares == null)
                {
                    labwares = DataRWDAL.LabwareDB.GetLabware(2);
                }
            }
            if(labwares!=null)
            {
                foreach(Labware l in labwares)
                {
                    if(l.labware_type_id.Equals("4"))
                    {
                        l.labwareWellInfoList = DataRWDAL.LabwareDB.GetSpecialLabwareWellInfo(l.labware_id);
                    }
                }
            }
 
            return labwares;
        }
 
        private ObservableCollection<Labware> tipsLabwares;
        public ObservableCollection<Labware> GetTipsLabwares(bool bRefresh = false, bool insert = true)
        {
            if (bRefresh)
            {
                tipsLabwares = DataRWDAL.LabwareDB.GetTipLabwareFromdb();
                if (insert)
                {
                    Labware lb = new Labware();
                    lb.labware_name = Properties.Resources.strPleaseSelect;
                    tipsLabwares.Insert(0, lb);
                }
            }
            else
            {
                if (tipsLabwares == null)
                {
                    tipsLabwares = DataRWDAL.LabwareDB.GetTipLabwareFromdb();
                    if (insert)
                    {
                        Labware lb = new Labware();
                        lb.labware_name = Properties.Resources.strPleaseSelect;
                        tipsLabwares.Insert(0, lb);
                    }
                }
            }
            return tipsLabwares;
        }
 
        /// <summary>
        /// 获取台面点位
        /// </summary>
        private List<Lattice> lattices;
        public List<Lattice> GetLattices(bool bExcludeTrash = false, bool bRefresh = false)
        {
            TabletopTemplate tabletopTemplate = TabletopTemplateDB.GetCurrentAppTabletopTemplateCollectionFromdb();  //增加台面模板判断
            if (tabletopTemplate == null)
            {
                if (bRefresh)
                    lattices = DataRWDAL.LatticeDB.GetLatticeDataFromdb(Shared.SoftwareInformation.software_device_number);
                else
                {
                    if (lattices == null)
                    {
                        lattices = DataRWDAL.LatticeDB.GetLatticeDataFromdb(Shared.SoftwareInformation.software_device_number);
                    }
                }
 
                
            }
            else
            {
                if (bRefresh)
                    lattices = DataRWDAL.LatticeDB.GetLatticeDataByTabletopTemplateFromdb(tabletopTemplate.tabletopid);
                else
                {
                    if (lattices == null)
                    {
                        lattices = DataRWDAL.LatticeDB.GetLatticeDataByTabletopTemplateFromdb(tabletopTemplate.tabletopid);
                    }
                }
            }
 
            if (bExcludeTrash)
            {
                var selLattices = lattices.Where(it => it.is_trash == EnumManagement.GetEnumValue(IsTrashEnum.No));
                if (selLattices.Any())
                {
                    lattices = selLattices.ToList();
                }
            }
 
            return lattices;
        }
 
        private ObservableCollection<Method> methods;
        public ObservableCollection<Method> GetMethod()
        {
            if (methods == null)
            {
                methods = new ObservableCollection<Method>();
                ObservableCollection<Method> list = MethodDB.GetMethodFromdb();
                foreach (var item in list)
                {
                    if (item.method_group_id != EnumManagement.GetEnumValue(MethodGroupEnum.None))
                        methods.Add(item);
                }
            }
 
            return methods;
        }
 
        /// <summary>
        /// 获取菌的信息
        /// </summary>
        private ObservableCollection<Bacteria> bacterias;
        public ObservableCollection<Bacteria> GetBacterias(bool bRefresh = false)
        {
            if (bRefresh)
                bacterias = BacteriaDB.GetBacteriaListFromdb(2);
            else
            {
                if (bacterias == null)
                {
                    bacterias = BacteriaDB.GetBacteriaListFromdb(2);
                }
            }
            return bacterias;
        }
 
        /// <summary>
        /// 获取挑菌方式
        /// </summary>
        private ObservableCollection<DropdownName> choiceModeList;
        public ObservableCollection<DropdownName> GetChoiceMode(string softwareDeviceNumber)
        {
            if (choiceModeList == null)
            {
                choiceModeList = new ObservableCollection<DropdownName>();
                choiceModeList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(ChoiceModeEnum.SigleSelectMode).ToString(),
                    dropdown_name = Properties.Resources.strSingleSelect
                });
            }
 
            return choiceModeList;
        }
 
        #region 获取加液、取液位置类型
        public ObservableCollection<DropdownName> GetDispensePositionType()
        {
            ObservableCollection<DropdownName> positionTypeList = new ObservableCollection<DropdownName>();
            positionTypeList.Add(new DropdownName()
            {
                dropdown_id = EnumManagement.GetEnumValue(MixPositionEnum.Liquid).ToString(),
                dropdown_name = EnumManagement.GetEnumDescription(MixPositionEnum.Liquid)
            });
            positionTypeList.Add(new DropdownName()
            {
                dropdown_id = EnumManagement.GetEnumValue(MixPositionEnum.Top).ToString(),
                dropdown_name = EnumManagement.GetEnumDescription(MixPositionEnum.Top)
            });
 
            positionTypeList.Add(new DropdownName()
            {
                dropdown_id = EnumManagement.GetEnumValue(MixPositionEnum.Bottom).ToString(),
                dropdown_name = EnumManagement.GetEnumDescription(MixPositionEnum.Bottom)
            });
 
            return positionTypeList;
        }
        #endregion
 
        /// <summary>
        /// 获取涂布方式
        /// </summary>
        private ObservableCollection<DropdownName> coatingModeList;
        public ObservableCollection<DropdownName> GetCoatingMode()
        {
            if (coatingModeList == null)
            {
                coatingModeList = new ObservableCollection<DropdownName>();
 
                #region 回字型
                coatingModeList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(CoatingModeEnum.HuiziMode).ToString(),
                    dropdown_name = Properties.Resources.strHuiziMode
                });
                #endregion
 
                #region Z字型
                coatingModeList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(CoatingModeEnum.ZMode).ToString(),
                    dropdown_name = Properties.Resources.strZMode
                });
                #endregion
 
                #region 上下移动
                coatingModeList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(CoatingModeEnum.UpDownMode).ToString(),
                    dropdown_name = Properties.Resources.strUpDownMode
                });
                #endregion
 
                #region 吸放液
                coatingModeList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(CoatingModeEnum.AspirateDispenseMode).ToString(),
                    dropdown_name = Properties.Resources.strAspirateDispense
                });
                #endregion
 
                #region 放液
                coatingModeList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(CoatingModeEnum.DispenseMode).ToString(),
                    dropdown_name = Properties.Resources.strDispense
                });
                #endregion
            }
 
            return coatingModeList;
        }
 
        private ObservableCollection<string> pickPositionList;
        public ObservableCollection<string> GetPickPosition()
        {
            if (pickPositionList == null)
            {
                pickPositionList = new ObservableCollection<string>();
                pickPositionList.Add(Properties.Resources.strDishBottom);
                pickPositionList.Add(Properties.Resources.strBacteriaSurface);
            }
 
            return pickPositionList;
        }
 
        private ObservableCollection<string> coatingPositionList;
        public ObservableCollection<string> GetCoatingPosition()
        {
            if (coatingPositionList == null)
            {
                coatingPositionList = new ObservableCollection<string>();
                coatingPositionList.Add(Properties.Resources.strDishBottom);
            }
 
            return coatingPositionList;
        }
 
        private ObservableCollection<string> divisionList;
        public ObservableCollection<string> GetDivisionList()
        {
            if (divisionList == null)
            {
                divisionList = new ObservableCollection<string>();
                divisionList.Add("1" + Properties.Resources.strDivision);
                divisionList.Add("2" + Properties.Resources.strDivision);
                divisionList.Add("3" + Properties.Resources.strDivision);
                divisionList.Add("4" + Properties.Resources.strDivision);
            }
 
            return divisionList;
        }
 
        private ObservableCollection<string> specsDiameterList;
        public ObservableCollection<string> GetSpecsDiameterList()
        {
            if (specsDiameterList == null)
            {
                specsDiameterList = new ObservableCollection<string>();
                specsDiameterList.Add("35 mm");
                specsDiameterList.Add("55 mm");
                specsDiameterList.Add("60 mm");
                specsDiameterList.Add("65 mm");
                specsDiameterList.Add("70 mm");
                specsDiameterList.Add("90 mm");
                specsDiameterList.Add("100 mm");
                specsDiameterList.Add("120 mm");
                specsDiameterList.Add("150 mm");
                specsDiameterList.Add("180 mm");
                specsDiameterList.Add("200 mm");
            }
 
            return specsDiameterList;
        }
 
        private ObservableCollection<string> specsHeightList;
        public ObservableCollection<string> GetSpecsHeightList()
        {
            if (specsHeightList == null)
            {
                specsHeightList = new ObservableCollection<string>();
                specsHeightList.Add("9 mm");
                specsHeightList.Add("10 mm");
                specsHeightList.Add("15 mm");
                specsHeightList.Add("20 mm");
            }
 
            return specsHeightList;
        }
 
        private ObservableCollection<BacteriaCoordinateEx> pickBacteriaCoordinationList = new ObservableCollection<BacteriaCoordinateEx>();
        /// <summary>
        /// 获取拍照json文件里的数据
        /// </summary>
        /// <param name="jsonFile"></param>
        /// <returns></returns>
        public ObservableCollection<BacteriaCoordinateEx> GetBacteriaCoordinateList(string jsonFile = "")
        {
            if (string.IsNullOrEmpty(jsonFile))
                return pickBacteriaCoordinationList;
            if (!File.Exists(jsonFile))
            {
                return pickBacteriaCoordinationList;
            }
            try
            {
                pickBacteriaCoordinationList.Clear();
                string jsonData = File.ReadAllText(jsonFile);
                jsonData = jsonData.Replace("#!HxSEP!#", "");
 
                JObject job = JObject.Parse(jsonData);
                JArray jArray = (JArray)job["germlist"];
 
                foreach (JToken jt in jArray)
                {
                    BacteriaCoordinate bacteriaCoordinate = new BacteriaCoordinate();
                    bacteriaCoordinate.bacteriacoordinate_id = jt["index"].ToString();
                    string coordinate3D = string.Empty;
                    string coordinate3Dx = jt["coordinate3D"]["x"].ToString();
                    string coordinate3Dy = jt["coordinate3D"]["y"].ToString();
                    string coordinate3Dz = jt["coordinate3D"]["z"].ToString();
                    coordinate3D = jt["coordinate3D"]["x"].ToString() + "," + jt["coordinate3D"]["y"].ToString() + "," + jt["coordinate3D"]["z"].ToString();
                    bacteriaCoordinate.coordinate_machine = coordinate3D;
                    string coordinatePixel = string.Empty;
                    string pixelx = jt["coordinatePixel"]["x"].ToString();
                    string pixely = jt["coordinatePixel"]["y"].ToString();
                    coordinatePixel = jt["coordinatePixel"]["x"].ToString() + "," + jt["coordinatePixel"]["y"].ToString();
                    bacteriaCoordinate.coordinate_pixel = coordinatePixel;
 
                    BacteriaCoordinateEx ex = new BacteriaCoordinateEx(bacteriaCoordinate);
                    ex.diameter = jt["diameterSize"].ToString();
                    double pixelX = double.Parse(pixelx);
                    double pixelY = double.Parse(pixely);
                    ex.pixelPoint = new Point(pixelX, pixelY);
 
                    double p3DX = double.Parse(coordinate3Dx);
                    double p3DY = double.Parse(coordinate3Dy);
                    double p3DZ = double.Parse(coordinate3Dz);
                    ex.machinePoint = new Point3D(p3DX, p3DY, p3DZ);
                    pickBacteriaCoordinationList.Add(ex);
                }
            }
            catch (Exception ex)
            {
                LoggerHelper.ErrorLog("ERROR:", ex);
            }
 
            return pickBacteriaCoordinationList;
        }
 
        /// <summary>
        /// 未检测到时的处理方法
        /// </summary>
        private ObservableCollection<string> undetectProcessList;
        public ObservableCollection<string> GetUndetectProcessList()
        {
            if (undetectProcessList == null)
            {
                undetectProcessList = new ObservableCollection<string>();
                undetectProcessList.Add(Properties.Resources.strFailedContinue);
                undetectProcessList.Add(Properties.Resources.strContinueFromBottom);
                undetectProcessList.Add(Properties.Resources.strContinueFromTop);
                //undetectProcessList.Add(Properties.Resources.strAuto);
                undetectProcessList.Add(Properties.Resources.strShowWindows);
                undetectProcessList.Add(Properties.Resources.strCurrentPos);
            }
            return undetectProcessList;
        }
 
        /// <summary>
        /// 液面跟随方式
        /// </summary>
        private ObservableCollection<string> liquidFollowTypeList;
        public ObservableCollection<string> GetLiquidFollowTypeList()
        {
            if (liquidFollowTypeList == null)
            {
                liquidFollowTypeList = new ObservableCollection<string>();
                liquidFollowTypeList.Add(Properties.Resources.strPleaseSelect);
                liquidFollowTypeList.Add(Properties.Resources.strSpeedAndPointDis);
                liquidFollowTypeList.Add(Properties.Resources.strLiquidFaceArea);
            }
            return liquidFollowTypeList;
        }
 
        /// <summary>
        /// 吸液堵塞处理方式
        /// </summary>
        private ObservableCollection<string> AspirateBlockDealTypeList;
        public ObservableCollection<string> GetAspirateBlockDealTypeList()
        {
            if (AspirateBlockDealTypeList == null)
            {
                AspirateBlockDealTypeList = new ObservableCollection<string>();
                AspirateBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal0);
                AspirateBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal1);
                AspirateBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal2);
                AspirateBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal3);
                AspirateBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal4);
                AspirateBlockDealTypeList.Add(Properties.Resources.strShowWindows);
            }
            return AspirateBlockDealTypeList;
        }
 
        /// <summary>
        /// 排液堵塞处理方式
        /// </summary>
        private ObservableCollection<string> DispenseBlockDealTypeList;
        public ObservableCollection<string> GetDispenseBlockDealTypeList()
        {
            if (DispenseBlockDealTypeList == null)
            {
                DispenseBlockDealTypeList = new ObservableCollection<string>();
                DispenseBlockDealTypeList.Add(Properties.Resources.strDispenseBlockDeal0);
                DispenseBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal3);
                DispenseBlockDealTypeList.Add(Properties.Resources.strAspirateBlockDeal4);
                DispenseBlockDealTypeList.Add(Properties.Resources.strShowWindows);
            }
            return DispenseBlockDealTypeList;
        }
 
        /// <summary>
        /// 吸空处理方式
        /// </summary>
        private ObservableCollection<string> AspirateAirDealTypeList;
        public ObservableCollection<string> GetAspirateAirDealTypeList()
        {
            if (AspirateAirDealTypeList == null)
            {
                AspirateAirDealTypeList = new ObservableCollection<string>();
                AspirateAirDealTypeList.Add(Properties.Resources.strAspirateAirDeal0);
                AspirateAirDealTypeList.Add(Properties.Resources.strAspirateAirDeal1);
                AspirateAirDealTypeList.Add(Properties.Resources.strAspirateBlockDeal3);
                AspirateAirDealTypeList.Add(Properties.Resources.strAspirateBlockDeal4);
            }
            return AspirateAirDealTypeList;
        }
 
        #region 稀释方向
        /// <summary>
        /// 稀释方向
        /// </summary>
        private ObservableCollection<DropdownName> dilutionDirectionList;
        public ObservableCollection<DropdownName> GetDilutionDirectionList()
        {
            if (dilutionDirectionList == null)
            {
                dilutionDirectionList = new ObservableCollection<DropdownName>();
 
                #region 从左到右
                dilutionDirectionList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(DilutionDirectionEnum.LeftToRight).ToString(),
                    dropdown_name = Properties.Resources.strLeftToRight
                });
                #endregion
 
                #region 从上到下
                dilutionDirectionList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(DilutionDirectionEnum.UpToDown).ToString(),
                    dropdown_name = Properties.Resources.strUpToDown
                });
                #endregion
 
                #region 从下到上
                dilutionDirectionList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(DilutionDirectionEnum.DownToUp).ToString(),
                    dropdown_name = Properties.Resources.strDownToUp
                });
                #endregion
 
            }
 
            return dilutionDirectionList;
        }
        #endregion
 
        #region 更换Tip
        /// <summary>
        /// 更换Tip
        /// </summary>
        private ObservableCollection<DropdownName> changeTipList;
        public ObservableCollection<DropdownName> GetChangeTipList()
        {
            if (changeTipList == null)
            {
                changeTipList = new ObservableCollection<DropdownName>();
 
                #region 不更换
                changeTipList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(ChangeTipEnum.NoChange).ToString(),
                    dropdown_name = Properties.Resources.strNoChangeTip
                });
                #endregion
 
                #region 更换
                changeTipList.Add(new DropdownName()
                {
                    dropdown_id = EnumManagement.GetEnumValue(ChangeTipEnum.Change).ToString(),
                    dropdown_name = Properties.Resources.strChangeTip
                });
                #endregion
            }
 
            return changeTipList;
        }
        #endregion
    }
}