Ejemplo n.º 1
0
        public bool GetUpdate(M_Sns_Kiss snsKiss)
        {
            string sqlStr = "UPDATE [dbo].[ZL_Sns_Kiss] SET [Title] = @Title,[Inputer] = @Inputer,[Sendto] = @Sendto,[Otherdel] = @Otherdel,[Content] = @Content,[InputerID] = @InputerID,[SendtoID] = @SendtoID,[SendTime] = @SendTime,[ReadTime] = @ReadTime,[IsRead] = @IsRead WHERE [id] = @id";

            SqlParameter[] cmdParams = snsKiss.GetParameters(snsKiss);
            return(SqlHelper.ExecuteSql(sqlStr, cmdParams));
        }
Ejemplo n.º 2
0
        public int GetInsert(M_Sns_Kiss snsKiss)
        {
            string sqlStr = "INSERT INTO [dbo].[ZL_Sns_Kiss] ([Title],[Inputer],[Sendto],[Otherdel],[Content],[InputerID],[SendtoID],[SendTime],[ReadTime],[IsRead]) VALUES (@Title,@Inputer,@Sendto,@Otherdel,@Content,@InputerID,@SendtoID,@SendTime,@ReadTime,@IsRead);select @@IDENTITY";

            SqlParameter[] cmdParams = snsKiss.GetParameters(snsKiss);
            return(SqlHelper.ObjectToInt32(SqlHelper.ExecuteScalar(CommandType.Text, sqlStr, cmdParams)));
        }
Ejemplo n.º 3
0
 public int insert(M_Sns_Kiss model)
 {
     return(Sql.insert(strTableName, model.GetParameters(model), BLLCommon.GetParas(model), BLLCommon.GetFields(model)));
 }
Ejemplo n.º 4
0
 public bool UpdateByID(M_Sns_Kiss model)
 {
     return(Sql.UpdateByIDs(strTableName, PK, model.IsRead.ToString(), BLLCommon.GetFieldAndPara(model), model.GetParameters(model)));
 }