Exemplo n.º 1
0
 /// <summary>
 /// 根据Name返回DClass的值,假设性别的CODE是201,DClass=201
 /// </summary>
 /// <param name="Name">返回code的值</param>
 public string GetDcodeByName(string Name)
 {
     string str = "Name='"+Name+"'";
     List<LabMS.Model.Dictionary> listd = new List<LabMS.Model.Dictionary>();
     Dictionary dt = new Dictionary();
     listd = dt.GetModelList(str);
     return listd[0].Code;
 }
Exemplo n.º 2
0
 /// <summary>
 /// 获得性别码,从基础字典里面
 /// </summary>
 /// <returns></returns>
 public string GetSexCode(string sexcode)
 {
     string DClass=GetDClassFromDictorary("性别");
     string str = "DClass='" + DClass + "' and Code='" + sexcode + "'";
     Dictionary BD = new Dictionary();
     List<LabMS.Model.Dictionary> listD = new List<LabMS.Model.Dictionary>();
     listD=BD.GetModelList(str);
     return listD[0].Name;  //如果Name表示的男,女
 }