protected void Page_Load(object sender, EventArgs e) { if (!this.IsPostBack) { this.InitializeLanguage(); this.InitializePage(); } else { if (!string.IsNullOrEmpty(this.HiddenSelectedState.Value)) { this.SelectedState = DiagrammiManager.GetStatoById(this.HiddenSelectedState.Value); this.HiddenSelectedState.Value = string.Empty; string msgConfirm = "WarningPhaseChangeStateDiagramm"; if (this.controllaStatoFinale()) { msgConfirm = "WarningPhaseChangeStateDiagramFinalState"; } ScriptManager.RegisterStartupScript(this, this.GetType(), "ajaxConfirmModal", "ajaxConfirmModal('" + msgConfirm.Replace("'", @"\'") + "', 'HiddenChangeStateDiagramm', '', '" + SelectedState.DESCRIZIONE + "');", true); return; } if (!string.IsNullOrEmpty(this.HiddenChangeStateDiagramm.Value)) { this.HiddenChangeStateDiagramm.Value = string.Empty; string retVal = this.SelectedState.SYSTEM_ID.ToString(); this.MissingRolesList = DiagrammiManager.ChangeStateGetMissingRoles(UIManager.ProjectManager.getProjectInSession().systemID, this.SelectedState.SYSTEM_ID.ToString()); if (this.MissingRolesList == null || this.MissingRolesList.Count == 0) { this.SalvaStato(); } ScriptManager.RegisterStartupScript(this, this.GetType(), "closeMask", "if (parent.fra_main) {parent.fra_main.closeAjaxModal('Phases', '" + retVal + "');} else {parent.closeAjaxModal('Phases', '" + retVal + "');};", true); this.SelectedState = null; } ScriptManager.RegisterStartupScript(this, this.GetType(), "reallowOp", "reallowOp();", true); } }