Exemple #1
0
 /// </summary>
 ///Query 方法 dt查询结果
 /// </summary>
 public System.Collections.IList Query(System.Data.DataTable dt)
 {
     System.Collections.IList result = new System.Collections.ArrayList();
     foreach (System.Data.DataRow dr in dt.Rows)
     {
         project.Entity.Base.EntityRoom entity = new project.Entity.Base.EntityRoom();
         entity.RMID              = dr["RMID"].ToString();
         entity.RMNo              = dr["RMNo"].ToString();
         entity.RMLOCNo1          = dr["RMLOCNo1"].ToString();
         entity.RMLOCNo1Name      = dr["RMLOCNo1Name"].ToString();
         entity.RMLOCNo2          = dr["RMLOCNo2"].ToString();
         entity.RMLOCNo2Name      = dr["RMLOCNo2Name"].ToString();
         entity.RMLOCNo3          = dr["RMLOCNo3"].ToString();
         entity.RMLOCNo3Name      = dr["RMLOCNo3Name"].ToString();
         entity.RMLOCNo4          = dr["RMLOCNo4"].ToString();
         entity.RMLOCNo4Name      = dr["RMLOCNo4Name"].ToString();
         entity.RMRentType        = dr["RMRentType"].ToString();
         entity.RMBuildSize       = ParseDecimalForString(dr["RMBuildSize"].ToString());
         entity.RMRentSize        = ParseDecimalForString(dr["RMRentSize"].ToString());
         entity.RMAddr            = dr["RMAddr"].ToString();
         entity.RMRemark          = dr["RMRemark"].ToString();
         entity.RMISEnable        = bool.Parse(dr["RMISEnable"].ToString());
         entity.RMStatus          = dr["RMStatus"].ToString();
         entity.RMReservedDate    = ParseDateTimeForString(dr["RMReservedDate"].ToString());
         entity.RMEndReservedDate = ParseDateTimeForString(dr["RMEndReservedDate"].ToString());
         entity.RMCurrentCustNo   = dr["RMCurrentCustNo"].ToString();
         entity.RMCurrentCustName = dr["RMCurrentCustName"].ToString();
         entity.RMCreateDate      = ParseDateTimeForString(dr["RMCreateDate"].ToString());
         entity.RMCreator         = dr["RMCreator"].ToString();
         entity.HaveAirCondition  = bool.Parse(dr["HaveAirCondition"].ToString());
         result.Add(entity);
     }
     return(result);
 }
Exemple #2
0
 /// <summary>
 /// 带参数的构函数
 /// </summary>
 /// <param name="entity">实体类</param>
 public BusinessRoom(project.Entity.Base.EntityRoom entity)
 {
     this._entity = entity;
 }