示例#1
0
        //新增
        public bool Add(XFeedback model)
        {
            string sql = string.Format(@"insert into XFeedback
                                (FID,MID,FType,Info,IsReply,SortIndex,IsDeleted,CreateTime,UpdateTime)
                                values(@FID,@MID,@FType,@Info,@IsReply,@SortIndex,@IsDeleted,@CreateTime,@UpdateTime)");

            DbParameter[] parms =
            {
                new SqlParameter("@FID",        SqlDbType.VarChar, 50)
                {
                    Value = model.FID
                },
                new SqlParameter("@MID",        SqlDbType.VarChar, 50)
                {
                    Value = model.MID
                },
                new SqlParameter("@FType",      SqlDbType.VarChar, 50)
                {
                    Value = model.FType
                },
                new SqlParameter("@Info",       SqlDbType.Text)
                {
                    Value = model.Info
                },
                new SqlParameter("@IsReply",    SqlDbType.Int)
                {
                    Value = model.IsReply
                },
                new SqlParameter("@SortIndex",  SqlDbType.Int)
                {
                    Value = model.SortIndex
                },
                new SqlParameter("@IsDeleted",  SqlDbType.Int)
                {
                    Value = model.IsDeleted
                },
                new SqlParameter("@CreateTime", SqlDbType.DateTime)
                {
                    Value = model.CreateTime
                },
                new SqlParameter("@UpdateTime", SqlDbType.DateTime)
                {
                    Value = model.UpdateTime
                }
            };
            return(dbHelper.ExecuteNonQuery(sql, parms));
        }
示例#2
0
        //修改登录签名



        //删除
        public bool Delete(XFeedback model)
        {
            string sql = string.Format(@"update XFeedback set
                               IsDeleted=@IsDeleted,UpdateTime=@UpdateTime where
                                FID=@FID");

            DbParameter[] parms =
            {
                new SqlParameter("@FID",        SqlDbType.VarChar, 50)
                {
                    Value = model.FID
                },
                new SqlParameter("@IsDeleted",  SqlDbType.Int)
                {
                    Value = model.IsDeleted
                },
                new SqlParameter("@UpdateTime", SqlDbType.DateTime)
                {
                    Value = model.UpdateTime
                }
            };
            return(dbHelper.ExecuteNonQuery(sql, parms));
        }
示例#3
0
 //修改
 public bool Update(XFeedback model)
 {
     return(dalXFeedback.Update(model));
 }
示例#4
0
 //删除
 public bool Delete(XFeedback model)
 {
     return(dalXFeedback.Delete(model));
 }
示例#5
0
 //新增
 public bool Add(XFeedback model)
 {
     return(dalXFeedback.Add(model));
 }