Ejemplo n.º 1
0
        /// <summary>
        /// 获得数据列表
        /// </summary>
        public List <MobileSoft.Model.Unified.Tb_User_Relation> DataTableToList(DataTable dt)
        {
            List <MobileSoft.Model.Unified.Tb_User_Relation> modelList = new List <MobileSoft.Model.Unified.Tb_User_Relation>();
            int rowsCount = dt.Rows.Count;

            if (rowsCount > 0)
            {
                MobileSoft.Model.Unified.Tb_User_Relation model;
                for (int n = 0; n < rowsCount; n++)
                {
                    model             = new MobileSoft.Model.Unified.Tb_User_Relation();
                    model.Id          = dt.Rows[n]["Id"].ToString();
                    model.UserId      = dt.Rows[n]["UserId"].ToString();
                    model.CommunityId = dt.Rows[n]["CommunityId"].ToString();
                    model.CustId      = dt.Rows[n]["CustId"].ToString();
                    model.CustHoldId  = dt.Rows[n]["CustHoldId"].ToString();
                    model.RoomId      = dt.Rows[n]["RoomId"].ToString();
                    model.ParkingId   = dt.Rows[n]["ParkingId"].ToString();
                    model.IsCurr      = dt.Rows[n]["IsCurr"].ToString();
                    modelList.Add(model);
                }
            }
            return(modelList);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// 更新一条数据
 /// </summary>
 public void Update(MobileSoft.Model.Unified.Tb_User_Relation model)
 {
     dal.Update(model);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// 增加一条数据
 /// </summary>
 public void Add(MobileSoft.Model.Unified.Tb_User_Relation model)
 {
     dal.Add(model);
 }