Exemple #1
0
        /// <summary>
        /// 获得数据列表
        /// </summary>
        public List <tdps.Model.DLNSRXX> DataTableToList(DataTable dt)
        {
            List <tdps.Model.DLNSRXX> modelList = new List <tdps.Model.DLNSRXX>();
            int rowsCount = dt.Rows.Count;

            if (rowsCount > 0)
            {
                tdps.Model.DLNSRXX model;
                for (int n = 0; n < rowsCount; n++)
                {
                    model = new tdps.Model.DLNSRXX();
                    if (dt.Rows[n]["DLZH"].ToString() != "")
                    {
                        model.DLZH = dt.Rows[n]["DLZH"].ToString();
                    }
                    model.NSRSBH = dt.Rows[n]["NSRSBH"].ToString();
                    NSRXX nsrxx = new NSRXX();
                    nsrxx.NSRMC = dt.Rows[n]["NSRMC"].ToString();
                    model.NSRXX = nsrxx;
                    modelList.Add(model);
                }
            }
            return(modelList);
        }
Exemple #2
0
 /// <summary>
 /// 更新一条数据
 /// </summary>
 public void Update(tdps.Model.DLNSRXX model, object trans)
 {
     dal.Update(model, trans);
 }
Exemple #3
0
 /// <summary>
 /// 更新一条数据
 /// </summary>
 public void Update(tdps.Model.DLNSRXX model)
 {
     dal.Update(model);
 }
Exemple #4
0
 /// <summary>
 /// 增加一条数据
 /// </summary>
 public void Add(tdps.Model.DLNSRXX model, object trans)
 {
     dal.Add(model, trans);
 }
Exemple #5
0
 /// <summary>
 /// 增加一条数据
 /// </summary>
 public void Add(tdps.Model.DLNSRXX model)
 {
     dal.Add(model);
 }