领胜LDS 键盘AOI检测项目
wells.liu
2020-06-28 19a9489aef9b3353171eca5e6b583aadb2828593
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
using Autofac;
using Bro.Common.Helper;
using Bro.Common.Interface;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Globalization;
 
namespace Bro.Common.Model
{
    public class ProcessMethodSelectorConverter : ComboBoxItemTypeConvert
    {
        public override Hashtable GetConvertHash(ITypeDescriptorContext context)
        {
            Hashtable table = new Hashtable();
            using (var scope = GlobalVar.Container.BeginLifetimeScope())
            {
                List<ProcessMethodAttribute> methodList = scope.Resolve<List<ProcessMethodAttribute>>();
 
                methodList.ForEach(d =>
                {
                    table[d.MethodCode] = d.MethodCode + "_" + d.MethodDesc;
                });
            }
 
            return table;
        }
    }
}