public async Task<ActionResult> CentiliConfirm(CentiliModel data)
        {
            Order order = await db.Order.Where(x => x.Id == data.OrderId).FirstOrDefaultAsync();

            if (data.Code == data.EnteredCode && order != null)
            {
                order.OrderStatus = await db.OrderStatus.Where(x => x.Name == "Successful").FirstOrDefaultAsync();
                await db.SaveChangesAsync();
                string userId = User.Identity.GetUserId();
                AspNetUsers user = await db.AspNetUsers.Where(x => x.Id == userId).FirstOrDefaultAsync();
                if (user != null)
                    SendConfirmationEmail(user.Email, order.Id);
                return RedirectToAction("OrderDetails", new { id = order.Id });
            }
            else
            {
                if (order != null)
                {
                    order.OrderStatus = await db.OrderStatus.Where(x => x.Name == "Declined").FirstOrDefaultAsync();
                    await db.SaveChangesAsync();
                }
                return View("OrderUnsuccessful");
            }
        }
        public async Task<ActionResult> CentiliRenew(long productId)
        {
            string userId = User.Identity.GetUserId();

            SoftwareProduct product = await db.SoftwareProduct.Where(x => x.Id == productId).FirstOrDefaultAsync();

            if (product == null) return RedirectToAction("Index");

            Order order = new Order()
            {
                AspNetUsers = db.AspNetUsers.Where(x => x.Id == userId).FirstOrDefault(),
                OrderStatus = db.OrderStatus.Where(x => x.Name == "Waiting").FirstOrDefault(),
                OrderType = db.OrderType.Where(x => x.Name == "Licence").FirstOrDefault(),
                SoftwareProduct = product,
                TotalPrice = product.Price,
                CreatedAt = DateTime.Now
            };

            db.Order.Add(order);
            await db.SaveChangesAsync();

            CentiliModel data = new CentiliModel()
            {
                Code = Guid.NewGuid().ToString().Remove(5),
                OrderId = order.Id
            };

            return View(data);
        }