Beispiel #1
0
        /// <summary>
        /// 更新一条数据
        /// </summary>
        public void Update(Model.BlogType model)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.Append("update [Type] set ");
            strSql.Append("[Type]='" + model.Type + "'");
            strSql.Append(" where ID=" + model.ID + " ");
            SQLHelper.ExecuteNonQuery(strSql.ToString());
        }
Beispiel #2
0
        /// <summary>
        /// 增加一条数据
        /// </summary>
        public void Add(Model.BlogType model)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.Append("insert into [Type](");
            strSql.Append("[Type]");
            strSql.Append(")");
            strSql.Append(" values (");
            strSql.Append("'" + model.Type + "'");
            strSql.Append(")");
            SQLHelper.ExecuteNonQuery(strSql.ToString());
        }
Beispiel #3
0
 /// <summary>
 /// 更新一条数据
 /// </summary>
 public void Update(Model.BlogType model)
 {
     dal_type.Update(model);
 }
Beispiel #4
0
 /// <summary>
 /// 增加一条数据
 /// </summary>
 public void Add(Model.BlogType model)
 {
     dal_type.Add(model);
 }