public ActionResult NewAgreement(AgreementEditViewModel viewModel)
        {
            if (!ModelState.IsValid)
            {
                return(AgreementViewEdit(viewModel, CurrentFirmaSession, null));
            }

            var agreement = new Agreement(false, false, viewModel.ContractTypeID.Value);

            viewModel.UpdateModelAndSaveChanges(agreement, CurrentFirmaSession, HttpRequestStorage.DatabaseEntities);

            SetMessageForDisplay($"Agreement {agreement.GetDetailLinkUsingAgreementNumber()} successfully created.");

            return(new ModalDialogFormJsonResult());
        }