public void AddException(tblErrorLog objerrorlog) { using (var context = new ChitaleDBContext()) { try { context.tblErrorLogs.Add(objerrorlog); context.SaveChanges(); } catch (Exception ex) { } } }
public bool GenerateOTP(OTPMaintenance objOTP) { bool status = false; using (var context = new ChitaleDBContext()) { try { context.OTPMaintenances.Add(objOTP); context.SaveChanges(); status = true; } catch (Exception ex) { newexception.AddException(ex); } } return(status); }
public bool RedeemptionRequest(tblRedemptionRequest objRedeem) { bool status = false; using (var context = new ChitaleDBContext()) { try { context.tblRedemptionRequests.Add(objRedeem); context.SaveChanges(); status = true; } catch (Exception ex) { newexception.AddException(ex); } } return(status); }