public bool SetRedEnvelopeState(int id, RedEnvelopeState redEnvelopeState) { DbCommand sqlStringCommand = base.database.GetSqlStringCommand("UPDATE [dbo].[Hishop_WeiXinRedEnvelope] SET [State] =@State WHERE Id=@Id"); base.database.AddInParameter(sqlStringCommand, "Id", DbType.Int32, id); base.database.AddInParameter(sqlStringCommand, "State", DbType.Int32, (int)redEnvelopeState); return(base.database.ExecuteNonQuery(sqlStringCommand) > 0); }
public static bool SetRedEnvelopeState(int id, RedEnvelopeState redEnvelopeState) { return(new WeiXinRedEnvelopeDao().SetRedEnvelopeState(id, redEnvelopeState)); }