public ActionResult Edit(CalculatorConstantViewModel viewModel)
        {
            if (Request.IsAjaxRequest())
            {
                var req = new SaveCalculatorConstantRequest();
                req.Id = viewModel.Id;
                req.Value = viewModel.Value;
                req.IsAjaxRequest = true;
                var response = _calculatorConstantService.SaveCalculatorConstant(req);
                return Json(response);

            }
            else
            {
                var req = viewModel.MapTo<SaveCalculatorConstantRequest>();
                _calculatorConstantService.SaveCalculatorConstant(req);
                return RedirectToAction("Index");
            }
        }
 public ActionResult Create(CalculatorConstantViewModel viewModel)
 {
     var req = viewModel.MapTo<SaveCalculatorConstantRequest>();
     _calculatorConstantService.SaveCalculatorConstant(req);
     return RedirectToAction("Index");
 }