public async Task <IActionResult> Edit(int id, [Bind("Iduser,Idcustomer,Name,LastName,Active")] UserProfiles userProfiles) { if (id != userProfiles.Iduser) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(userProfiles); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!UserProfilesExists(userProfiles.Iduser)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(userProfiles)); }
public async Task <IActionResult> Edit(int id, [Bind("Idcode,DialledNumber,Description")] Code code) { if (id != code.Idcode) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(code); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CodeExists(code.Idcode)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(code)); }
public async Task <IActionResult> Edit(int id, [Bind("Idreport,Name")] Report report) { if (id != report.Idreport) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(report); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ReportExists(report.Idreport)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(report)); }
public async Task <IActionResult> Edit(int id, [Bind("Idivraction,Digit,FkIvr,FkIvrDest,FkContactDest,FkAnnouncementDest,FkMailboxDest,VoicemailMain")] Ivraction ivraction) { if (id != ivraction.Idivraction) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(ivraction); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!IvractionExists(ivraction.Idivraction)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(ivraction)); }
public async Task<IActionResult> Edit(int id, [Bind("Idrouting,Priority,RingingTime,FkContact,FkSite,Active,FkRoutingGroup,HuntBusy,FkAnnouncement,FkIvr,FkMailbox,VoicemailMain")] Routing routing) { if (id != routing.Idrouting) { return NotFound(); } if (ModelState.IsValid) { try { _context.Update(routing); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!RoutingExists(routing.Idrouting)) { return NotFound(); } else { throw; } } return RedirectToAction(nameof(Index)); } return View(routing); }
public async Task <IActionResult> Edit(int id, [Bind("IdnumberTemplate,FkNumber,FkTemplate,Priority,Active,FkRoutingGroup")] NumberTemplate numberTemplate) { if (id != numberTemplate.IdnumberTemplate) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(numberTemplate); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!NumberTemplateExists(numberTemplate.IdnumberTemplate)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(numberTemplate)); }
public async Task <IActionResult> Edit(int id, [Bind("Idivr,Name,Description,Audiomessage,Audioname,Audiosize,Repeattimes,Timeout,FkCustomer")] Ivr ivr) { if (id != ivr.Idivr) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(ivr); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!IvrExists(ivr.Idivr)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(ivr)); }
public async Task <IActionResult> Edit(int id, [Bind("IdroutingGroup,Name,Description,Active,IsUserGenerated,FkCustomer,Forking")] Routinggroup routinggroup) { if (id != routinggroup.IdroutingGroup) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(routinggroup); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!RoutinggroupExists(routinggroup.IdroutingGroup)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(routinggroup)); }
public async Task <IActionResult> Edit(int id, [Bind("Idcustomer,Name,Description,RoutingNumber,DefaultBillingNumber,NonGeo,FkExceptionLcr,BlockAnonymous,Customercol")] Customer customer) { if (id != customer.Idcustomer) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(customer); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CustomerExists(customer.Idcustomer)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(customer)); }
public async Task <IActionResult> Edit(int id, [Bind("Idcarrier,Name,Description,Domain,RoutingNumber,BillingNumber,Preference")] Carrier carrier) { if (id != carrier.Idcarrier) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(carrier); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CarrierExists(carrier.Idcarrier)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(carrier)); }
public async Task <IActionResult> Edit(int id, [Bind("IdreportConfiguration,Name,Description,FkUserProfile,FkCustomer")] Reportconfiguration reportconfiguration) { if (id != reportconfiguration.IdreportConfiguration) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(reportconfiguration); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ReportconfigurationExists(reportconfiguration.IdreportConfiguration)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(reportconfiguration)); }
public async Task <IActionResult> Edit(int id, [Bind("Idfeature,Name,Description,Code")] Feature feature) { if (id != feature.Idfeature) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(feature); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!FeatureExists(feature.Idfeature)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(feature)); }
public async Task <IActionResult> Edit(int id, [Bind("IddayDetails,Day,TimeFrom,TimeTo,Status,FkPeriod")] Daydetails daydetails) { if (id != daydetails.IddayDetails) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(daydetails); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!DaydetailsExists(daydetails.IddayDetails)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(daydetails)); }
public async Task <IActionResult> Edit(int id, [Bind("Idsite,Name,Description,Domain,FkNumberFormat,FkCustomer")] Site site) { if (id != site.Idsite) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(site); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!SiteExists(site.Idsite)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(site)); }
public async Task <IActionResult> Edit(int id, [Bind("Idmailbox,Pin,Name,Email,SendEmail,DeleteOpt,Attachment,Audiomessage,Audioname,Audiosize,FkNumber,FkCustomer,Fax")] Mailbox mailbox) { if (id != mailbox.Idmailbox) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(mailbox); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!MailboxExists(mailbox.Idmailbox)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(mailbox)); }
public async Task <IActionResult> Edit(int id, [Bind("Idperiod,TimeFrom,TimeTo,Frequency,Day,Status,FkTemplate")] Period period) { if (id != period.Idperiod) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(period); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PeriodExists(period.Idperiod)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(period)); }
public async Task <IActionResult> Edit(int id, [Bind("Idbarring,Code,NormalisedCode,Description,Status,FkCustomer")] Barring barring) { if (id != barring.Idbarring) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(barring); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!BarringExists(barring.Idbarring)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(barring)); }
public async Task <IActionResult> Edit(int id, [Bind("IdcarrierCodeException,Priority,Status,FkCarrier,FkCode,FkExceptionLcr")] CarrierCodeException carrierCodeException) { if (id != carrierCodeException.IdcarrierCodeException) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(carrierCodeException); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CarrierCodeExceptionExists(carrierCodeException.IdcarrierCodeException)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(carrierCodeException)); }
public async Task <IActionResult> Edit(long id, [Bind("Idlog,Action,Timestamp,Table,Attribute,NewValue,IdModified,FkUser")] Log log) { if (id != log.Idlog) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(log); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!LogExists(log.Idlog)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(log)); }
public async Task <IActionResult> Edit(int id, [Bind("Idannouncement,Name,Description,Audiomessage,Audioname,Audiosize,Repeattimes,FkCustomer,FkContact,InProgress")] Announcement announcement) { if (id != announcement.Idannouncement) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(announcement); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!AnnouncementExists(announcement.Idannouncement)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(announcement)); }
public async Task <IActionResult> Edit(int id, [Bind("Id,Msgnum,Dir,Context,Macrocontext,Callerid,Origtime,Duration,Flag,Mailboxuser,Mailboxcontext,MsgId,Recording")] Voicemessages voicemessages) { if (id != voicemessages.Id) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(voicemessages); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!VoicemessagesExists(voicemessages.Id)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(voicemessages)); }
public async Task <IActionResult> Edit(int id, [Bind("IdexceptionNumber,Number,Description")] Exceptionnumber exceptionnumber) { if (id != exceptionnumber.IdexceptionNumber) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(exceptionnumber); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ExceptionnumberExists(exceptionnumber.IdexceptionNumber)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(exceptionnumber)); }
public async Task <IActionResult> Edit(int id, [Bind("Idgroup,Name,Description,FkCustomer")] Numbergroup numbergroup) { if (id != numbergroup.Idgroup) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(numbergroup); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!NumbergroupExists(numbergroup.Idgroup)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(numbergroup)); }
public async Task <IActionResult> Edit(int id, [Bind("IdfeatureCustomer,DateFrom,DateTo,Quantity,FkFeature,FkCustomer")] FeatureCustomer featureCustomer) { if (id != featureCustomer.IdfeatureCustomer) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(featureCustomer); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!FeatureCustomerExists(featureCustomer.IdfeatureCustomer)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(featureCustomer)); }
public async Task <IActionResult> Edit(int id, [Bind("Idcontact,Name,Description,PhoneNumber,FkCustomer,FkSite")] Contact contact) { if (id != contact.Idcontact) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(contact); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ContactExists(contact.Idcontact)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(contact)); }