public void AddMethod()
        {
            Payment p      = new Payment(5, "P5", "None");
            var     result = PaymentTestRepo.CreateNewPaymentMethod(p);
            var     Total  = PaymentTestRepo.RetrieveAllPayments();

            Assert.IsTrue(Total.Count > 4);
        }
        public IActionResult Add(OptionsViewModel model)
        {
            Payment p = new Payment(1, model.PaymentMethodName, model.PaymentMethodDescription);

            if (model.PaymentMethodDescription == null)
            {
                model.PaymentMethodDescription = "No description";
            }
            if (payRep.CreateNewPaymentMethod(p))
            {
                return(RedirectToAction("Overview", "PaymentMethod"));
            }
            return(RedirectToAction("Overview", "PaymentMethod"));
        }