public async Task <IActionResult> Edit(int id, [Bind("PaymentPackageId,FeatureId,Value,Unit,Id,Created,Modified,IsDeleted,ItemOrder")] PaymentPackageFeature paymentPackageFeature)
        {
            if (id != paymentPackageFeature.Id)
            {
                return(NotFound());
            }

            if (ModelState.IsValid)
            {
                try
                {
                    _context.Update(paymentPackageFeature);
                    await _context.SaveChangesAsync();
                }
                catch (DbUpdateConcurrencyException)
                {
                    if (!PaymentPackageFeatureExists(paymentPackageFeature.Id))
                    {
                        return(NotFound());
                    }
                    else
                    {
                        throw;
                    }
                }
                return(RedirectToAction(nameof(Index)));
            }
            ViewData["FeatureId"]        = new SelectList(_context.Feature, "Id", "Name", paymentPackageFeature.FeatureId);
            ViewData["PaymentPackageId"] = new SelectList(_context.PaymentPackage, "Id", "DisplayName", paymentPackageFeature.PaymentPackageId);
            return(View(paymentPackageFeature));
        }
        public async Task <IActionResult> Create([Bind("PaymentPackageId,FeatureId,Value,Unit,Id,Created,Modified,IsDeleted,ItemOrder")] PaymentPackageFeature paymentPackageFeature)
        {
            if (ModelState.IsValid)
            {
                _context.Add(paymentPackageFeature);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            ViewData["FeatureId"]        = new SelectList(_context.Feature, "Id", "Name", paymentPackageFeature.FeatureId);
            ViewData["PaymentPackageId"] = new SelectList(_context.PaymentPackage, "Id", "DisplayName", paymentPackageFeature.PaymentPackageId);
            return(View(paymentPackageFeature));
        }