// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Update User methods // ================================================================================== /// <summary> /// THis method saves the ResultData object updating the field values contained in the /// parameter list. /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.ClientClientDataObjectEvado.UniForm.Model.Command object.</param> /// <returns>Application Data object</returns> // ---------------------------------------------------------------------------------- private Evado.UniForm.Model.AppData getDataObject_ExitPage ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getDataObject_ExitPage" ); this.LogValue ( "Parameter: " + PageCommand.getAsString ( false, false ) ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); EvEventCodes result; // // register the user details. // result = this.RegisterUserDetails ( PageCommand ); // // create the registration exit page. clientDataObject = this.GetUserRegistrationExitPage ( result ); this.LogMethodEnd ( "getDataObject_ExitPage" ); return clientDataObject; }//END getDataObject_ExitPage method
}//END getClientDataObject method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class get object methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); Guid OrgGuid = Guid.Empty; try { // // return the client ResultData object for the customer. // this.getDataObject ( clientDataObject ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.ApplicationProfile_Page_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return null; }//END getObject method
}//END getObject method // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> // ------------------------------------------------------------------------------ private void getDataObject_MUP_Page ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getDataObject_MUP_Page" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); Evado.UniForm.Model.Field pageField = new Evado.UniForm.Model.Field ( ); Evado.UniForm.Model.Group pageGroup = new Evado.UniForm.Model.Group ( ); // // set the client ResultData object properties // ClientDataObject.Id = this.Session.UserProfile.Guid; ClientDataObject.Page.Id = this.Session.UserProfile.Guid; ClientDataObject.Title = EdLabels.User_Profile_Page_Title + this.Session.UserProfile.CommonName; ClientDataObject.Page.Title = ClientDataObject.Title; ClientDataObject.Page.PageId = Evado.Digital.Model.EdStaticPageIds.User_Profile_Page.ToString ( ); ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; this.LogDebug ( "clientDataObject status: " + ClientDataObject.Page.EditAccess ); this.getDataObject_MUP_GeneralGroup ( ClientDataObject.Page ); this.getDataObject_MUP_DetailsGroup ( ClientDataObject.Page ); this.getDataObject_MUP_OrganisationGroup ( ClientDataObject.Page ); this.getDataObject_MUP_PersonaliseGroup ( ClientDataObject.Page ); this.LogMethodEnd ( "getDataObject_MUP_Page" ); }//END getclientDataObject Method
}//END Method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class private create object methods // ================================================================================== /// <summary> /// THis method saves the ResultData object updating the field values contained in the /// parameter list. /// </summary> /// <param name="Command">Evado.UniForm.Model.Command object.</param> /// <returns>Evado.UniForm.Model.AppData object</returns> // ---------------------------------------------------------------------------------- private Evado.UniForm.Model.AppData createObject ( Evado.UniForm.Model.Command Command ) { this.LogMethod ( "createObject" ); try { // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "createObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return this.Session.LastPage; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "createObject", this.Session.UserProfile ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); this.Session.MenuItem = new EvMenuItem ( ); this.Session.MenuItem.Guid = Evado.Digital.Model.EvcStatics.CONST_NEW_OBJECT_ID; this.Session.MenuItem.Group = this.Session.MenuGroupIdentifier; this.Session.MenuItem.Platform = this.Session.MenuPlatformId; this.AdapterObjects.MenuList = new List<EvMenuItem> ( ); this.getClientData ( clientDataObject ); //this.LogDebug ( "Exit createObject method. ID: {0}, Title: {1} ", clientDataObject.Id, clientDataObject.Title ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.MenuItem_Load_Page_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; ; }//END method
}//END getProperties_SectionsPageGroup Method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Form properties Section page. // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>Evado.UniForm.Model.AppData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getPropertiesSectionObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getFormPropertiesSection" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); Guid formGuid = Guid.Empty; int SectionNo = 0; try { string value = PageCommand.GetParameter ( EdRecordSection.FormSectionClassFieldNames.Sectn_No.ToString ( ) ); this.LogDebug ( "Parameter value: " + value ); if ( value != String.Empty ) { if ( int.TryParse ( value, out SectionNo ) == false ) { SectionNo = 0; } } if ( this.getSection ( SectionNo ) == false ) { return null; } // // Generate the client ResultData object for the UniForm client. // this.getPropertiesSectionDataObject ( clientDataObject ); this.LogMethodEnd ( "getFormPropertiesSection" ); // // Return the client ResultData object to the calling method. // return clientDataObject; } catch ( Exception Ex ) { // // On an exception raised create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.Form_Retrieve_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } this.LogMethodEnd ( "getFormPropertiesSection" ); return null; }//END getFormPropertiesObject method
}//END getClientDataObject method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class private methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ public Evado.UniForm.Model.AppData getListObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getListObject" ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // initialise the list page. // clientDataObject.Title = EdLabels.ApplicationEvent_List_Page_Title; clientDataObject.Page.Title = clientDataObject.Title; clientDataObject.Id = Guid.NewGuid ( ); this.queryApplicatinEventLog ( ); // // Create the new pageMenuGroup. // this.getSelectionGroup ( clientDataObject.Page ); // // Add the trial applicationEvent list to the page. // this.getListGroup ( clientDataObject.Page ); this.LogValue ( "data.Title: " + clientDataObject.Title ); this.LogValue ( "data.Page.Title: " + clientDataObject.Page.Title ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.ApplicationEvent_List_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } this.LogMethodEnd ( "getListObject" ); return this.Session.LastPage; }//END getListObject method.
}//END updateObject method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Create User methods // ================================================================================== /// <summary> /// THis method saves the ResultData object updating the field values contained in the /// parameter list. /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>Application Data object</returns> // ---------------------------------------------------------------------------------- private Evado.UniForm.Model.AppData getDataObject_RegistrationPage ( Evado.UniForm.Model.Command PageCommand ) { this.LogValue ( Evado.UniForm.Model.EuStatics.CONST_METHOD_START + this.ClassNameSpace + "getDataObject_RegistrationPage" ); this.LogDebug ( "AdminOrganisation.OrgId: " +this.Session.SelectedUserType.ToString() ); this.LogDebug ( "Demo Expiry {0}", this.AdapterObjects.Settings.DemoAccountExpiryDays.ToString() ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Create the milestone object and add it to the clinical session object. // this.Session.AdminUserProfile = new Evado.Digital.Model.EdUserProfile ( ); this.Session.AdminUserProfile.Guid = Evado.Digital.Model.EvcStatics.CONST_NEW_OBJECT_ID; this.Session.AdminUserProfile.ExpiryDate = DateTime.Now.AddDays ( this.AdapterObjects.Settings.DemoAccountExpiryDays ); this.Session.AdminUserProfile.UserId = this.createDemoUderId ( ); this.Session.AdminUserProfile.FamilyName = this.Session.AdminUserProfile.UserId; this.Session.AdminUserProfile.GivenName = this.Session.AdminUserProfile.UserId; this.Session.AdminUserProfile.UserType = "End_User"; this.LogDebug ( "AdminUserProfile.UserId: {0} ", this.Session.AdminUserProfile.UserId ); this.LogDebug ( "AdminUserProfile.ExpiryDate: {0} ", this.Session.AdminUserProfile.ExpiryDate ); this.getDataObject_RegistrationPage ( clientDataObject ); this.LogMethodEnd ( "getDataObject_RegistrationPage" ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.User_Profile_Creation_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } this.LogMethodEnd ( "getDataObject_RegistrationPage" ); return this.Session.LastPage; ; }//END method
}//END getObject method // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private void getDataObject ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getDataObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); Evado.UniForm.Model.Field pageField = new Evado.UniForm.Model.Field ( ); ClientDataObject.Id = Guid.NewGuid ( ); ClientDataObject.Title = EdLabels.UserAdmin_Page_Title; ClientDataObject.Page.Id = ClientDataObject.Id; ClientDataObject.Page.Title = ClientDataObject.Title; ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; this.LogValue ( "Page.Status: " + ClientDataObject.Page.EditAccess ); // // Add the page commands // //this.addPageCommands ( ClientDataObject.Page ); // // Create the demo registration group.. // this.create_DemonRegistration_Group ( ClientDataObject.Page ); // // Create the introductory email Group. // this.create_IntroductoryEmail_Group ( ClientDataObject.Page ); // // create the reset pssword email group. // this.create_ResetPasswordEmail_Group ( ClientDataObject.Page ); // // Create the passsword update email group // this.create_UpdatePasswordEmail_Group ( ClientDataObject.Page ); // // create the reset pssword email group. // this.create_PasswordChangeEmail_Group ( ClientDataObject.Page ); }//END getDataObject Method
}//END getOrganisation method. // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private void getDataObject ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getDataObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); Evado.UniForm.Model.Field pageField = new Evado.UniForm.Model.Field ( ); ClientDataObject.Id = this.Session.AdminOrganisation.Guid; ClientDataObject.Title = EdLabels.Organisation_Page_Title; ClientDataObject.Page.Id = ClientDataObject.Id; ClientDataObject.Page.Title = ClientDataObject.Title; ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Disabled; // // Set the user edit access to the objects. // if ( this.Session.UserProfile.hasAdministrationAccess == true ) { ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; } this.LogValue ( "Page.EditAccess: " + ClientDataObject.Page.EditAccess ); // // Add the page commands // this.getDataObject_PageCommands ( ClientDataObject.Page ); // // Add the detail group to the page. // this.getDataObject_DetailsGroup ( ClientDataObject.Page ); this.LogMethodEnd ( "getDataObject" ); }//END Method
// ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getObject_MyUserProfile ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getObject_MyUserProfile" ); // // Initialise the methods variables and objects. // Guid subjectGuid = Guid.Empty; Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); try { // // return the client ResultData object for the customer. // this.getDataObject_MUP_Page ( clientDataObject ); this.LogMethodEnd ( "getObject_MyUserProfile" ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.User_Profile_Page_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } this.LogMethodEnd ( "getObject_MyUserProfile" ); return this.Session.LastPage; }//END getObject method
// ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> // ------------------------------------------------------------------------------ private void getDataObject_RegistrationPage ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getDataObject_RegistrationPage" ); // // set the client ResultData object properties // ClientDataObject.Id = this.Session.AdminUserProfile.Guid; ClientDataObject.Page.Id = this.Session.AdminUserProfile.Guid; ClientDataObject.Title = EdLabels.User_Profile_Page_Title + this.Session.AdminUserProfile.CommonName; ClientDataObject.Page.Title = ClientDataObject.Title; ClientDataObject.Page.PageId = Evado.Digital.Model.EdStaticPageIds.User_Profile_Page.ToString ( ); ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; this.getDataObject_Debug_Group ( ClientDataObject.Page ); // // Display the instructions // this.getDataObject_InstructionsGroup ( ClientDataObject.Page ); // // Add the page commands to the page. // this.getDataObject_PageCommands ( ClientDataObject.Page ); // // Add the field pageMenuGroup to the page. // this.getDataObject_FieldGroup ( ClientDataObject.Page ); this.LogMethodEnd ( "getDataObject_RegistrationPage" ); }//END getDataObject_RegistrationPage Method
}//END getDataObject_GroupCommands Method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class create object methods // ================================================================================== /// <summary> /// THis method saves the ResultData object updating the field values contained in the /// parameter list. /// </summary> /// <param name="Command">Evado.UniForm.Model.ClientClientDataObjectEvado.UniForm.Model.Command object.</param> /// <returns>Application Data object</returns> // ---------------------------------------------------------------------------------- private Evado.UniForm.Model.AppData createObject ( Evado.UniForm.Model.Command Command ) { this.LogMethod ( "createObject" ); try { // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "createObject", this.Session.UserProfile ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( "getListObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return this.Session.LastPage; ; } // // Initialise the dlinical ResultData objects. // this.Session.AdminOrganisation = new EdOrganisation ( ); this.Session.AdminOrganisation.Guid = Evado.Digital.Model.EvcStatics.CONST_NEW_OBJECT_ID; this.Session.AdminOrganisation.OrgId = String.Empty; this.Session.AdminOrganisation.ImageFileName = String.Empty; this._CurrentFileName = String.Empty; this.getDataObject ( clientDataObject ); this.LogValue ( "Exit createObject method. ID: " + clientDataObject.Id + ", Title: " + clientDataObject.Title ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = "Error raised when creating a trial site."; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; }//END method
}//END RegisterUserDetails method // ================================================================================== /// <summary> /// THis method validates that the user id is not duplicated in the ADS /// </summary> /// <returns>Application Data object</returns> // ---------------------------------------------------------------------------------- private Evado.UniForm.Model.AppData GetUserRegistrationExitPage ( EvEventCodes UpdateResult ) { this.LogMethod ( "GetUserRegistrationExitPage method" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); String groupDescription = this.AdapterObjects.ContentTemplates.DemoRegistrationConfirmation; if ( UpdateResult != EvEventCodes.Ok ) { this.LogDebug ( "ERROR: Update Result Error: {0}", UpdateResult ); groupDescription = this.AdapterObjects.ContentTemplates.DemoRegistrationError; } // // set the client ResultData object properties // clientDataObject.Id = this.Session.AdminUserProfile.Guid; clientDataObject.Page.Id = this.Session.AdminUserProfile.Guid; clientDataObject.Title = EdLabels.User_Profile_Page_Title + this.Session.AdminUserProfile.CommonName; clientDataObject.Page.Title = clientDataObject.Title; clientDataObject.Page.PageId = Evado.Digital.Model.EdStaticPageIds.User_Profile_Page.ToString ( ); clientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; var pageGroup = clientDataObject.Page.AddGroup ( String.Empty, Evado.UniForm.Model.EditAccess.Disabled ); pageGroup.Layout = Evado.UniForm.Model.GroupLayouts.Full_Width; // // Define the markdown options. // MarkdownSharp.MarkdownOptions markDownOptions = new MarkdownSharp.MarkdownOptions ( ); markDownOptions.AutoHyperlink = true; markDownOptions.AutoNewlines = true; markDownOptions.EmptyElementSuffix = "/>"; markDownOptions.EncodeProblemUrlCharacters = true; markDownOptions.LinkEmails = true; markDownOptions.StrictBoldItalic = true; // // Initialise the markdown class // MarkdownSharp.Markdown markDown = new MarkdownSharp.Markdown ( markDownOptions ); // // perform the html body transformation. // string description = markDown.Transform ( groupDescription ); pageGroup.Description = description; this.LogMethodEnd ( "GetUserRegistrationExitPage" ); return clientDataObject; }
}//END getDataObject_ExitPage method // ================================================================================== /// <summary> /// THis method saves the ResultData object updating the field values contained in the /// parameter list. /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.ClientClientDataObjectEvado.UniForm.Model.Command object.</param> /// <returns>Application Data object</returns> // ---------------------------------------------------------------------------------- private EvEventCodes RegisterUserDetails ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "RegisterUserDetails" ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); EvEventCodes result; // // Update the object. // if ( this.updateObjectValue ( PageCommand ) == false ) { this.ErrorMessage = EdLabels.UserProfile_Value_Update_Error_Message; this.LogMethodEnd ( "RegisterUserDetails" ); return EvEventCodes.Value_Update_Processing_Error; } this.LogValue ( "Guid: " + this.Session.AdminUserProfile.Guid ); this.LogValue ( "UserId: " + this.Session.AdminUserProfile.UserId ); this.LogValue ( "CommonName: " + this.Session.AdminUserProfile.CommonName ); this.Session.AdminUserProfile.UserId = EvStatics.CleanSamUserId ( this.Session.AdminUserProfile.UserId ); if ( PageCommand.hasParameter ( EuUserRegistration.CONST_NEW_PASSWORD_PARAMETER ) == true ) { this.LogValue ( "Creating a new password." ); this.createDefaultPassword ( ); } this.LogValue ( "AdminUserProfile.Password: "******"RegisterUserDetails" ); return result; } this.LogMethodEnd ( "RegisterUserDetails" ); return EvEventCodes.Ok; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.User_Profile_Save_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } this.LogMethodEnd ( "RegisterUserDetails" ); return EvEventCodes.Database_Record_Update_Error; }//END RegisterUserDetails method
}//END getFormPropertiesObject method // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> // ------------------------------------------------------------------------------ private void getPropertiesSectionDataObject ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getPropertiesSectionDataObject" ); this.LogDebug ( "FormSection.No: " + this.Session.FormSection.No ); this.LogDebug ( "FormSection.Title: " + this.Session.FormSection.Title ); this.LogDebug ( "FormSection.DisplayRoles: " + this.Session.FormSection.ReadAccessRoles ); this.LogDebug ( "FormSection.EditRoles: " + this.Session.FormSection.EditAccessRoles ); this.LogDebug ( "HasConfigrationEditAccess: " + this.Session.UserProfile.hasManagementAccess ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.Group pageGroup = new Evado.UniForm.Model.Group ( ); Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); Evado.UniForm.Model.Field pageField = new Evado.UniForm.Model.Field ( ); Evado.UniForm.Model.Parameter parameter = new Evado.UniForm.Model.Parameter ( ); List<EvOption> optionList = new List<EvOption> ( ); optionList.Add ( new EvOption ( ) ); foreach ( EdRecordField field in this.Session.EntityLayout.Fields ) { optionList.Add ( new EvOption ( field.FieldId, field.FieldId + EdLabels.Space_Hypen + field.Title ) ); } // // Initialise the client ResultData object. // if ( this.Session.EntityLayout.Guid != Guid.Empty ) { ClientDataObject.Id = Guid.NewGuid ( ); ClientDataObject.Title = String.Format ( EdLabels.FormProperties_Section_Page_Title, this.Session.EntityLayout.LayoutId, this.Session.EntityLayout.Title, this.Session.FormSection.LinkText ); ClientDataObject.Page.Id = ClientDataObject.Id; ClientDataObject.Page.PageDataGuid = ClientDataObject.Id; ClientDataObject.Page.PageId = this.Session.EntityLayout.LayoutId; } else { ClientDataObject.Id = Guid.NewGuid ( ); ClientDataObject.Title = EdLabels.Form_Page_New_Form_Title; ClientDataObject.Page.Id = ClientDataObject.Id; ClientDataObject.Page.PageDataGuid = ClientDataObject.Id; } ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; if ( this.Session.UserProfile.hasManagementAccess == true ) { ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; } if ( this.Session.EntityLayout.State != EdRecordObjectStates.Form_Issued && this.Session.EntityLayout.State != EdRecordObjectStates.Withdrawn ) { ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Disabled; } // // Set the user's edit access if they have configuration edit access. // if ( this.Session.UserProfile.hasManagementAccess == true ) { ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; } pageGroup = ClientDataObject.Page.AddGroup ( EdLabels.FormProperties_Section_Group_Text, Evado.UniForm.Model.EditAccess.Inherited ); pageGroup.Layout = Evado.UniForm.Model.GroupLayouts.Full_Width; // // Form No // pageField = pageGroup.createTextField ( EdRecordSection.FormSectionClassFieldNames.Sectn_No.ToString ( ), EdLabels.Form_Section_No_Field_Label, this.Session.FormSection.No.ToString ( ), 50 ); pageField.Layout = EuAdapter.DefaultFieldLayout; pageField.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; // // Form title // pageField = pageGroup.createTextField ( EdRecordSection.FormSectionClassFieldNames.Sectn_Title.ToString ( ), EdLabels.Form_Section_Title_Field_Label, this.Session.FormSection.Title, 50 ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Form Instructions // pageField = pageGroup.createFreeTextField ( EdRecordSection.FormSectionClassFieldNames.Sectn_Instructions.ToString ( ), EdLabels.Form_Section_Instructions_Field_Label, EdLabels.Form_Section_Instructions_Field_Description, this.Session.FormSection.Instructions, 90, 5 ); pageField.Layout = EuAdapter.DefaultFieldLayout; optionList = new List<EvOption> ( ); this.LogDebug ( "FormSection.Order: " + this.Session.FormSection.Order ); foreach ( EdRecordSection section in this.Session.EntityLayout.Design.FormSections ) { if ( section.Order < this.Session.FormSection.Order ) { this.LogDebug ( "secttion.Order: " + section.Order + " BEFORE SECTION" ); var value = String.Format ( EdLabels.Form_Section_Order_Before_Text, section.Title ); optionList.Add ( new EvOption ( ( section.Order - 1 ).ToString ( ), value ) ); } if ( section.Order == this.Session.FormSection.Order ) { this.LogDebug ( "secttion.Order: " + section.Order + " CURRENT" ); optionList.Add ( new EvOption ( this.Session.FormSection.Order.ToString ( ), this.Session.FormSection.Title ) ); } if ( section.Order > this.Session.FormSection.Order ) { this.LogDebug ( "secttion.Order: " + section.Order + " AFTER SECTION" ); var value = String.Format ( EdLabels.Form_Section_Order_After_Text, section.Title ); optionList.Add ( new EvOption ( ( section.Order + 1 ).ToString ( ), value ) ); } } // // The form section order // pageField = pageGroup.createSelectionListField ( EdRecordSection.FormSectionClassFieldNames.Sectn_Order.ToString ( ), EdLabels.Form_Section_Order_Field_Label, this.Session.FormSection.Order.ToString ( ), optionList ); pageField.Layout = EuAdapter.DefaultFieldLayout; /* // // The form section field id // pageField = pageGroup.createSelectionListField ( EvFormSection.FormSectionClassFieldNames.Sectn_Field_Id.ToString ( ), EdLabels.Form_Section_Field_ID_Field_Label, this.SessionObjects.FormSection.FieldId, optionList ); pageField.Layout = EuPageGenerator.ApplicationFieldLayout; // // Form Field value // pageField = pageGroup.createTextField ( EvFormSection.FormSectionClassFieldNames.Sectn_Field_Value.ToString ( ), EdLabels.Form_Section_Field_Value_Field_Label, this.SessionObjects.FormSection.FieldValue, 50 ); pageField.Layout = EuPageGenerator.ApplicationFieldLayout; pageField.EditAccess = Evado.UniForm.Model.EditAccess.Inherited; // // form secton on open display section. // pageField = pageGroup.createBooleanField ( EvFormSection.FormSectionClassFieldNames.Sectn_On_Open_Visible.ToString ( ), EdLabels.Form_Section_Visible_On_Open_Field_Label, this.SessionObjects.FormSection.OnOpenVisible ); pageField.Layout = EuPageGenerator.ApplicationFieldLayout; // // Form on field value match display field field // pageField = pageGroup.createBooleanField ( EvFormSection.FormSectionClassFieldNames.Sectn_On_Match_Visible.ToString ( ), EdLabels.Form_Section_Visible_Field_Value_Matches_Field_Label, this.SessionObjects.FormSection.OnMatchVisible ); pageField.Layout = EuPageGenerator.ApplicationFieldLayout; */ // // get the list of display roles. // optionList = new List<EvOption> ( ); optionList = this.AdapterObjects.Settings.GetRoleOptionList ( false ); // // The form section user display roles // pageField = pageGroup.createCheckBoxListField ( EdRecordSection.FormSectionClassFieldNames.Sectn_Display_Roles.ToString ( ), EdLabels.Form_Section_User_Display_Roles_Field_Label, EdLabels.Form_Section_User_Display_Roles_Field_Description, this.Session.FormSection.ReadAccessRoles, optionList ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // get the list of edit roles. // pageField = pageGroup.createCheckBoxListField ( EdRecordSection.FormSectionClassFieldNames.Sectn_Edit_Roles.ToString ( ), EdLabels.Form_Section_User_Edit_Roles_Field_Label, EdLabels.Form_Section_User_Edit_Roles_Field_Description, this.Session.FormSection.EditAccessRoles, optionList ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Add the command to save the page content. // pageCommand = pageGroup.addCommand ( EdLabels.Form_Properties_Section_Save_Command_Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entity_Layouts.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Custom_Method ); pageCommand.SetPageId ( Evado.Digital.Model.EdStaticPageIds.Form_Properties_Page ); pageCommand.setCustomMethod ( Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetGuid ( this.Session.EntityLayout.Guid ); pageCommand.AddParameter ( EuRecordLayouts.CONST_UPDATE_SECTION_COMMAND_PARAMETER, "1" ); }//END getPropertiesDataObject Method
}//END getListGroup method. // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class get object methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); Guid orgGuid = Guid.Empty; // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; this.LogMethodEnd ( "getObject" ); return this.Session.LastPage; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "getObject", this.Session.UserProfile ); // // get the organisation guid. // orgGuid = PageCommand.GetGuid ( ); // // guid and object empty. // if ( orgGuid == Guid.Empty && this.Session.AdminOrganisation.Guid == Guid.Empty ) { this.ErrorMessage = EdLabels.Organisation_Guid_Empty_Message; this.LogMethodEnd ( "getObject" ); return this.Session.LastPage; } // // load the organisation // if ( this.getOrganisation ( orgGuid ) == false ) { this.Session.LastPage.Message = this.ErrorMessage; this.LogMethodEnd ( "getObject" ); return this.Session.LastPage; } // // return the client ResultData object for the customer. // this.getDataObject ( clientDataObject ); // // return the client data object. // this.LogMethodEnd ( "getObject" ); return clientDataObject; }//END getObject method
}//END getListObject method. // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class private get object methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); Guid menuGuid = Guid.Empty; try { // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return this.Session.LastPage; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "getObject", this.Session.UserProfile ); // // if the parameter value exists then set the customerId // menuGuid = PageCommand.GetGuid ( ); this.LogDebug ( "Menu Guid: " + menuGuid ); // // return if not trial id // if ( menuGuid == Guid.Empty ) { this.ErrorMessage = EdLabels.MenuItem_Guid_Empty_Message; return this.Session.LastPage; } // // Retrieve the menu item from the global list of menut items. // this.Session.MenuItem = this.getMenuItem ( menuGuid ); this.LogDebug ( "MenuItem.PageId: " + this.Session.MenuItem.PageId ); // // return the client ResultData object for the customer. // this.getClientData ( clientDataObject ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.MenuItem_Load_Page_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; }//END getObject method
}//END getListObject method. // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasManagementAccess == false ) { this.LogIllegalAccess ( "Evado.UniForm.Clinical.ApplicationEvents.getListObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return null; } // // Log access to page. // this.LogPageAccess ( "Evado.UniForm.Clinical.ApplicationEvents.getObject", this.Session.UserProfile ); // // if the parameter value exists then set the customerId // Guid objectGuid = PageCommand.GetGuid ( ); this.LogValue ( "objectGuid: " + objectGuid ); try { // // Retrieve the customer object from the database via the DAL and BLL layers. // this._ApplicationEvent = this._Bll_ApplicationEvents.getItem ( objectGuid ); this.LogClass ( this._Bll_ApplicationEvents.Log ); this.LogValue ( "EventId: " + this._ApplicationEvent.EventId ); // // return the client ResultData object for the customer. // this.getDataObject ( clientDataObject ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.ApplicationEvent_Page_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; }//END getObject method
}//END getObject method // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private void getDataObject ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getDataObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); Evado.UniForm.Model.Field pageField = new Evado.UniForm.Model.Field ( ); ClientDataObject.Id = this._ApplicationEvent.Guid; ClientDataObject.Title = EdLabels.ApplicationEvent_Page_Title; ClientDataObject.Page.Id = ClientDataObject.Id; ClientDataObject.Page.Title = ClientDataObject.Title; ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; // // Add the help button if the help url is defined. // if ( this.AdapterObjects.HelpUrl != String.Empty ) { Evado.UniForm.Model.Command helpCommand = ClientDataObject.Page.addCommand ( EdLabels.Label_Help_Command_Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Events.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); helpCommand.Type = Evado.UniForm.Model.CommandTypes.Http_Link; helpCommand.AddParameter ( Evado.UniForm.Model.CommandParameters.Link_Url, EvcStatics.createHelpUrl ( this.AdapterObjects.HelpUrl, Evado.Digital.Model.EdStaticPageIds.Application_Event ) ); } // // create the page pageMenuGroup // Evado.UniForm.Model.Group pageGroup = ClientDataObject.Page.AddGroup ( String.Empty, String.Empty, Evado.UniForm.Model.EditAccess.Inherited ); pageGroup.Layout = Evado.UniForm.Model.GroupLayouts.Full_Width; pageGroup.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; // // Create the customer id object // pageField = pageGroup.createReadOnlyTextField ( String.Empty, EdLabels.ApplicationEvent_Date_Time_Field_Label, this._ApplicationEvent.DateTime.ToString ( "dd MMM yyyy HH:mm:ss" ) ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the event id object // { if ( this._ApplicationEvent.EventId == 0 || this._ApplicationEvent.EventId == 1 ) { this._ApplicationEvent.EventId = (int) EvEventCodes.Ok; } EvEventCodes code = (EvEventCodes) this._ApplicationEvent.EventId; String content = this._ApplicationEvent.EventId.ToString ( "000000" ) + " > " + Evado.Model.EvStatics.enumValueToString ( code ); pageField = pageGroup.createReadOnlyTextField ( String.Empty, EdLabels.ApplicationEvent_Event_Id_Field_Label, content ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the type id object // pageField = pageGroup.createReadOnlyTextField ( String.Empty, EdLabels.ApplicationEvent_Type_Field_Label, Evado.Model.EvStatics.enumValueToString ( this._ApplicationEvent.Type ) ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the Category id object // pageField = pageGroup.createReadOnlyTextField ( String.Empty, EdLabels.ApplicationEvent_Category_Field_Label, this._ApplicationEvent.Category ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the description object // pageField = pageGroup.createFreeTextField ( String.Empty, EdLabels.ApplicationEvent_Description_Field_Label, this._ApplicationEvent.Description, 80, 40 ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the user object // pageField = pageGroup.createReadOnlyTextField ( String.Empty, EdLabels.ApplicationEvent_UserName_Field_Label, this._ApplicationEvent.UserId ); pageField.Layout = EuAdapter.DefaultFieldLayout; }//END Method
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class public methods // ================================================================================== /// <summary> /// This method gets the application object from the list. /// /// </summary> /// <param name="PageCommand">ClientPateEvado.UniForm.Model.Command object</param> /// <returns>ClientApplicationData</returns> // ---------------------------------------------------------------------------------- public Evado.UniForm.Model.AppData getClientDataObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getClientDataObject" ); this.LogValue ( "Parameter PageCommand " + PageCommand.getAsString ( false, true ) ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Initialise the menu platformID value. // if ( this.Session.MenuPlatformId == null ) { this.Session.MenuPlatformId = this.AdapterObjects.PlatformId; } // // Determine the method to be called // switch ( PageCommand.Method ) { case Evado.UniForm.Model.ApplicationMethods.List_of_Objects: { clientDataObject = this.getListObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Get_Object: { clientDataObject = this.getObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Create_Object: { clientDataObject = this.createObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Save_Object: case Evado.UniForm.Model.ApplicationMethods.Delete_Object: { clientDataObject = this.updateObject ( PageCommand ); break; } }//END Switch // // Handle returned exceptions. // if ( clientDataObject == null ) { this.LogDebug ( " null application data returned." ); clientDataObject = this.Session.LastPage; } // // If an errot message exist display it. // if ( this.ErrorMessage != String.Empty ) { clientDataObject.Message = this.ErrorMessage; } // // return the client ResultData object. // this.LogMethodEnd ( "getDataObject" ); return clientDataObject; } catch ( Exception Ex ) { this.LogException ( Ex ); } this.LogMethodEnd ( "getDataObject" ); return this.Session.LastPage; }//END getClientDataObject method
}//END getGroupListCommand method //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class private record export methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getRecordExport_Object ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getRecordExport_Object" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); List<EdRecord> recordList = new List<EdRecord> ( ); try { // // If the user does not have monitor or ResultData manager roles exit the page. // if ( this.Session.Entity.hasReadAccess ( this.Session.UserProfile.Roles ) == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getRecordExport_Object", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Record_Access_Error_Message; return this.Session.LastPage; } // // Log the user's access to page. // this.LogPageAccess ( this.ClassNameSpace + "getRecordExport_Object", this.Session.UserProfile ); // // Initialise the client ResultData object. // clientDataObject.Id = Guid.NewGuid ( ); clientDataObject.Page.Id = clientDataObject.Id; clientDataObject.Page.PageDataGuid = clientDataObject.Id; clientDataObject.Title = EdLabels.Record_View_Page_Title; clientDataObject.Page.Title = clientDataObject.Title; clientDataObject.Page.PageId = Evado.Digital.Model.EdStaticPageIds.Record_Export_Page.ToString ( ); // // Create the new pageMenuGroup for query selection. // this.getRecordExport_SelectionGroup ( clientDataObject.Page ); this.LogValue ( "FormId: " + this.Session.Selected_EntityLayoutId ); this.LogValue ( "UserCommonName: " + this.Session.UserProfile.CommonName ); // // Create the export file and save if for download. // this.getRecordExport_DownloadGroup ( clientDataObject.Page ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.Record_View_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; }//END getListObject method.
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class public methods // ================================================================================== /// <summary> /// This method gets the trial site object. /// /// </summary> /// <param name="PageCommand">ClientPateEvado.UniForm.Model.Command object</param> /// <returns>Evado.UniForm.Model.AppData</returns> // ---------------------------------------------------------------------------------- override public Evado.UniForm.Model.AppData getDataObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getClientDataObject" ); this.LogValue ( "PageCommand Content: " + PageCommand.getAsString ( false, false ) ); try { // // Initialise the methods variables and objects. // bool bResult = true; Evado.UniForm.Model.AppData clientDataObjectObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return null; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "getObject", this.Session.UserProfile ); if ( this.AdapterObjects.ContentTemplates == null ) { this.AdapterObjects.ContentTemplates = new EvStaticContentTemplates ( ); this.AdapterObjects.ContentTemplates = EvStatics.Files.readXmlFile<EvStaticContentTemplates> ( this.AdapterObjects.ApplicationPath, EuStaticContentTemplates.CONST_EMAIL_TEMPLATE_FILENAME ); } if ( this.AdapterObjects.ContentTemplates == null ) { this.AdapterObjects.ContentTemplates = new EvStaticContentTemplates ( ); } if ( this.AdapterObjects.ContentTemplates.IntroductoryEmail_Title == null ) { this.AdapterObjects.ContentTemplates.IntroductoryEmail_Title = String.Empty; this.AdapterObjects.ContentTemplates.IntroductoryEmail_Body = String.Empty; this.AdapterObjects.ContentTemplates.UpdatePasswordEmail_Title = String.Empty; this.AdapterObjects.ContentTemplates.UpdatePasswordEmail_Body = String.Empty; this.AdapterObjects.ContentTemplates.ResetPasswordEmail_Body = String.Empty; this.AdapterObjects.ContentTemplates.ResetPasswordEmail_Body = String.Empty; this.AdapterObjects.ContentTemplates.PasswordConfirmationEmail_Title = String.Empty; this.AdapterObjects.ContentTemplates.PasswordConfirmationEmail_Body = String.Empty; } _displayPage = false; string value = PageCommand.GetParameter ( EuStaticContentTemplates.CONST_DISPLAY_PAGE ); if ( true == EvStatics.getBool ( value ) ) { _displayPage = true; } // // Set the page type to control the DB query type. // string pageType = PageCommand.GetPageId ( ); this.Session.setPageId ( pageType ); this.LogValue ( "PageId: " + this.Session.PageId ); // // Determine the method to be called // switch ( PageCommand.Method ) { case Evado.UniForm.Model.ApplicationMethods.Get_Object: { clientDataObjectObject = this.getObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Save_Object: { this.LogValue ( " Save Object method" ); // // Update the object values // bResult = this.updateObject ( PageCommand ); // // Process an update error result. // if ( bResult == false ) { this.LogValue ( " Save method failed" ); // // Return the generated ResultData object. // clientDataObjectObject = null; } break; } }//END Swith // // Handle returned exceptions. // if ( clientDataObjectObject == null ) { this.LogValue ( " null application data returned." ); } // // Return the last client ResultData object. // return clientDataObjectObject; } catch ( Exception Ex ) { this.LogException ( Ex ); } return new Evado.UniForm.Model.AppData ( ); }//END getClientDataObject method
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class create object methods // ================================================================================== /// <summary> /// THis method saves the ResultData object updating the field values contained in the /// parameter list. /// </summary> /// <param name="Command">Evado.UniForm.Model.Command object.</param> /// <returns>Application Data object</returns> // ---------------------------------------------------------------------------------- private Evado.UniForm.Model.AppData createObject ( Evado.UniForm.Model.Command Command ) { try { this.LogMethod ( "createObject" ); // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "createObject", this.Session.UserProfile ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasEvadoAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "createObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return null; } // // Initialise the dlinical ResultData objects. // this.AdapterObjects.ContentTemplates = new EvStaticContentTemplates ( ); this.getDataObject ( clientDataObject ); this.LogValue ( "Exit createObject method. ID: " + clientDataObject.Id + ", Title: " + clientDataObject.Title ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = "Error raised when creating a trial site."; // // Generate the log the error event. // this.LogException ( Ex ); } return null; }//END method
}//END getClientDataObject method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class private list methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private Evado.UniForm.Model.AppData getListObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getListObject" ); this.LogDebug ( "MenuPlatformId: " + this.Session.MenuPlatformId ); this.LogDebug ( "MenuGroupIdentifer: " + this.Session.MenuGroupIdentifier ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return this.Session.LastPage; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); // // if the customer command has been executed then refresh the menu list. // if ( PageCommand.hasParameter ( Evado.UniForm.Model.CommandParameters.Custom_Method ) == true ) { this.AdapterObjects.MenuList = new List<EvMenuItem> ( ); } // // Get the selected pageMenuGroup identifier. // if ( PageCommand.hasParameter ( EuSession.CONST_MENU_GROUP_ID ) == true ) { this.Session.MenuGroupIdentifier = PageCommand.GetParameter ( EuSession.CONST_MENU_GROUP_ID ); } this.LogValue ( "UPDATED: MenuGroupIdentifer: " + this.Session.MenuGroupIdentifier ); // // Get the selected pageMenuGroup identifier. // if ( PageCommand.hasParameter ( EvMenuItem.MenuFieldNames.Platform.ToString ( ) ) == true ) { this.Session.MenuPlatformId = PageCommand.GetParameter ( EvMenuItem.MenuFieldNames.Platform.ToString ( ) ); } this.LogValue ( "UPDATED: MenuPlatformId: " + this.Session.MenuPlatformId ); // // Update the global menu list, to pick up any changes that where made during an audit cycle. // this.loadGlobalMenu ( ); // // ensure that all page layouts have menu groups headers. // this.updatePageLayoutGroups ( ); // // Initialise the ResultData object. // clientDataObject.Title = EdLabels.Menu_Item_List; clientDataObject.Page.Title = clientDataObject.Title; clientDataObject.Id = Guid.NewGuid ( ); // // Add the save groupCommand // clientDataObject.Page.addCommand ( EdLabels.Menu_New_Item_Command_Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Menu.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Create_Object ); // // add the selection pageMenuGroup. // this.getSelectionListGroup ( clientDataObject.Page ); // // Add the Menu Field list to the page. // this.getList_Menu_List_Group ( clientDataObject.Page, this.Session.MenuGroupIdentifier ); this.LogDebug ( "Page.Title: " + clientDataObject.Page.Title ); this.LogDebug ( "Page.CommandList.Count: " + clientDataObject.Page.CommandList.Count ); // // Return the client ResultData object. // return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.Menu_List_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; }//END getListObject method.
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class public methods // ================================================================================== /// <summary> /// This method gets the trial site object /// </summary> /// <param name="PageCommand">ClientPateEvado.UniForm.Model.Command object</param> /// <returns>ClientApplicationData</returns> // ---------------------------------------------------------------------------------- public override Evado.UniForm.Model.AppData getDataObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getDataObject" ); this.LogValue ( "PageCommand Content: " + PageCommand.getAsString ( false, false ) ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); if ( PageCommand.hasParameter ( EdOrganisation.FieldNames.Org_Type ) == true ) { this.Session.SelectedOrganisationType = PageCommand.GetParameter ( EdOrganisation.FieldNames.Org_Type ); } if ( PageCommand.hasParameter ( Evado.UniForm.Model.CommandParameters.Custom_Method ) == true ) { this.Session.AdminOrganisationList = new List<EdOrganisation> ( ); } this.LogValue ( "SelectedOrganisationType: " + this.Session.SelectedOrganisationType ); // // Determine the method to be called // switch ( PageCommand.Method ) { case Evado.UniForm.Model.ApplicationMethods.List_of_Objects: { clientDataObject = this.getListObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Get_Object: { clientDataObject = this.getObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Create_Object: { clientDataObject = this.createObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Save_Object: case Evado.UniForm.Model.ApplicationMethods.Delete_Object: { // // Update the object values // clientDataObject = this.updateObject ( PageCommand ); break; } }//END Switch // // Handle returned exceptions. // if ( clientDataObject == null ) { this.LogDebug ( " null application data returned." ); clientDataObject = this.Session.LastPage; } // // If an errot message exist display it. // if ( this.ErrorMessage != String.Empty ) { clientDataObject.Message = this.ErrorMessage; } // // return the client ResultData object. // this.LogMethodEnd ( "getDataObject" ); return clientDataObject; } catch ( Exception Ex ) { this.LogException ( Ex ); } this.LogMethodEnd ( "getDataObject" ); return this.Session.LastPage; }//END getDataObject method
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class public methods /// <summary> /// This method gets the application object from the list. /// /// </summary> /// <param name="PageCommand">ClientPateEvado.UniForm.Model.Command object</param> /// <returns>ClientApplicationData</returns> // ---------------------------------------------------------------------------------- override public Evado.UniForm.Model.AppData getDataObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getClientDataObject" ); this.LogValue ( "Parameter PageCommand " + PageCommand.getAsString ( false, false ) ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); var pageId = PageCommand.GetPageId<Evado.Digital.Model.EdStaticPageIds> ( ); this.LogDebug ( "Page Id {0}.", pageId ); // // Load the customer group. // this.getAdsCustomerGroup ( ); // // Determine the method to be called // switch ( PageCommand.Method ) { case Evado.UniForm.Model.ApplicationMethods.List_of_Objects: case Evado.UniForm.Model.ApplicationMethods.Get_Object: case Evado.UniForm.Model.ApplicationMethods.Create_Object: case Evado.UniForm.Model.ApplicationMethods.Save_Object: case Evado.UniForm.Model.ApplicationMethods.Delete_Object: { switch ( pageId ) { case Evado.Digital.Model.EdStaticPageIds.User_Registration_Page: default: { clientDataObject = this.getDataObject_RegistrationPage ( PageCommand ); break; } case Evado.Digital.Model.EdStaticPageIds.Demo_User_Exit_Page: { this.LogValue ( " Save Object method" ); clientDataObject = this.getDataObject_ExitPage ( PageCommand ); break; } } break; } }//END Switch // // Handle returned exceptions. // if ( clientDataObject == null ) { clientDataObject = this.Session.LastPage; this.LogDebug ( " null application data returned." ); } if ( this.ErrorMessage != String.Empty ) { this.LogDebug ( "Append error message" ); clientDataObject.Message = this.ErrorMessage; } // // return the client ResultData object. // this.LogMethodEnd ( "getClientDataObject" ); return clientDataObject; } catch ( Exception Ex ) { this.LogException ( Ex ); } this.LogMethodEnd ( "getClientDataObject" ); return this.Session.LastPage; }//END updateObject method
}//END getDataObject method // +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class list methods // ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ public Evado.UniForm.Model.AppData getListObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getListObject" ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return this.Session.LastPage; ; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); if ( PageCommand.hasParameter ( Evado.UniForm.Model.CommandParameters.Custom_Method ) == true ) { this.Session.AdminOrganisationList = new List<EdOrganisation> ( ); } // // fill the organisation list. // this.getOrganisationList ( ); // // Initialise the list of organisations. // clientDataObject.Title = EdLabels.Organisation_List_Page_Title; clientDataObject.Page.Title = clientDataObject.Title; clientDataObject.Id = Guid.NewGuid ( ); this.getOrganisationSelection ( clientDataObject.Page ); // // Add the trial organisation list to the page. // this.getListGroup ( clientDataObject.Page ); this.LogMethodEnd ( "getListObject" ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.Organisation_List_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } this.LogMethodEnd ( "getListObject" ); return this.Session.LastPage; ; }//END getListObject method.
// ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="PageCommand">Evado.UniForm.Model.Command object.</param> /// <returns>ClientApplicationData object</returns> // ----------------------------------------------------------------------------- private Evado.UniForm.Model.AppData getListObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getListObject" ); this.LogDebug ( "Selected_EntityLayoutId: " + this.Session.Selected_EntityLayoutId ); this.LogDebug ( "EntitySelectionState: " + this.Session.EntityStateSelection ); this.LogDebug ( "EntitySelectionLayoutId: " + this.Session.Selected_EntityLayoutId ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); this.EnableEntityEditButtonUpdate = false; // // get the selected entity. // this.Session.EntityLayout = this.AdapterObjects.GetEntityLayout ( this.Session.Selected_EntityLayoutId ); this.LogDebug ( "EntityLayout.ReadAccessRoles: " + this.Session.EntityLayout.Design.ReadAccessRoles ); this.LogDebug ( "UserProfile.Roles: " + this.Session.UserProfile.Roles ); // // If the user does not have monitor or ResultData manager roles exit the page. // if ( this.Session.EntityLayout.hasReadAccess ( this.Session.UserProfile.Roles ) == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Record_Access_Error_Message; return this.Session.LastPage; ; } // // Log the user's access to page. // this.LogPageAccess ( this.ClassNameSpace + "getListObject", this.Session.UserProfile ); this.LogDebug ( "LayoutId {0}", this.Session.EntityLayout.LayoutId ); // // Set the parent entity variables. // this.ParentLayoutId = this.Session.Entity.LayoutId; this.ParentGuid = this.Session.Entity.Guid; if ( PageCommand.hasParameter ( EdRecord.FieldNames.ParentGuid ) == true ) { this.ParentGuid = PageCommand.GetParameterAsGuid ( EdRecord.FieldNames.ParentGuid ); } if ( PageCommand.hasParameter ( EdRecord.FieldNames.ParentLayoutId ) == true ) { this.ParentLayoutId = PageCommand.GetParameter ( EdRecord.FieldNames.ParentLayoutId ); } // // Execute the monitor list record query. // this.executeRecordQuery ( ); // // Initialise the client ResultData object. // clientDataObject.Id = Guid.NewGuid ( ); clientDataObject.Page.Id = clientDataObject.Id; clientDataObject.Page.PageDataGuid = clientDataObject.Id; clientDataObject.Title = EdLabels.Entity_View_Page_Title; if ( this.AdapterObjects.Settings.UseHomePageHeaderOnAllPages == true ) { clientDataObject.Title = this.AdapterObjects.Settings.HomePageHeaderText; } else { clientDataObject.Title = this.Session.EntityLayout.Title; } clientDataObject.Page.Title = clientDataObject.Title; clientDataObject.Page.PageId = Evado.Digital.Model.EdStaticPageIds.Records_View.ToString ( ); if ( this.Session.Entity.hasEditAccess ( this.Session.UserProfile.Roles ) == true ) { clientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; } this.LogValue ( "Page.EditAccess: " + clientDataObject.Page.EditAccess ); // // Create the new pageMenuGroup for query selection. // this.getList_SelectionGroup ( clientDataObject.Page ); // // Create the pageMenuGroup containing commands to open the records. // this.getEntity_ListGroup ( clientDataObject.Page ); this.LogValue ( "data.Page.Title: " + clientDataObject.Page.Title ); return clientDataObject; } catch ( Exception Ex ) { // // Create the error message to be displayed to the user. // this.ErrorMessage = EdLabels.Record_View_Error_Message; // // Generate the log the error event. // this.LogException ( Ex ); } return this.Session.LastPage; ; }//END getListObject method.
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Class public methods // ================================================================================== /// <summary> /// This method gets the trial site object. /// /// </summary> /// <param name="PageCommand">ClientPateEvado.UniForm.Model.Command object</param> /// <returns>ClientApplicationData</returns> // ---------------------------------------------------------------------------------- public Evado.UniForm.Model.AppData getClientDataObject ( Evado.UniForm.Model.Command PageCommand ) { this.LogMethod ( "getClientDataObject" ); this.LogValue ( "PageCommand Content: " + PageCommand.getAsString ( false, true ) ); try { // // Initialise the methods variables and objects. // Evado.UniForm.Model.AppData clientDataObject = new Evado.UniForm.Model.AppData ( ); // // Determine if the user has access to this page and log and error if they do not. // if ( this.Session.UserProfile.hasAdministrationAccess == false ) { this.LogIllegalAccess ( this.ClassNameSpace + "getClientDataObject", this.Session.UserProfile ); this.ErrorMessage = EdLabels.Illegal_Page_Access_Attempt; return this.Session.LastPage; } // // Log access to page. // this.LogPageAccess ( this.ClassNameSpace + "getClientDataObject", this.Session.UserProfile ); // // save the event selection parameters. // this.saveEventLogSelectionParameters ( PageCommand ); // // Determine the method to be called // switch ( PageCommand.Method ) { case Evado.UniForm.Model.ApplicationMethods.List_of_Objects: { clientDataObject = this.getListObject ( PageCommand ); break; } case Evado.UniForm.Model.ApplicationMethods.Get_Object: { clientDataObject = this.getObject ( PageCommand ); break; } }//END Swith // // Handle returned exceptions. // if ( clientDataObject == null ) { this.LogValue ( " null application data returned." ); clientDataObject = this.Session.LastPage; } // // If an errot message exist display it. // if ( this.ErrorMessage != String.Empty ) { clientDataObject.Message = this.ErrorMessage; } // // return the client ResultData object. // this.LogMethodEnd ( "getClientDataObject" ); return clientDataObject; } catch ( Exception Ex ) { this.LogException ( Ex ); } this.LogMethodEnd ( "getClientDataObject" ); return this.Session.LastPage; }//END getClientDataObject method
// ============================================================================== /// <summary> /// This method returns a client application ResultData object /// </summary> /// <param name="ClientDataObject">Evado.UniForm.Model.AppData object.</param> /// <returns>ClientApplicationData object</returns> // ------------------------------------------------------------------------------ private void getClientData ( Evado.UniForm.Model.AppData ClientDataObject ) { this.LogMethod ( "getDataObject" ); // // Initialise the methods variables and objects. // Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); Evado.UniForm.Model.Field pageField = new Evado.UniForm.Model.Field ( ); List<EvOption> optionList = new List<EvOption> ( ); EvOption option = new EvOption ( ); ClientDataObject.Id = this.Session.MenuItem.Guid; ClientDataObject.Title = EdLabels.Menu_Item; ClientDataObject.Page.Id = ClientDataObject.Id; ClientDataObject.Page.Title = ClientDataObject.Title; ClientDataObject.Page.EditAccess = Evado.UniForm.Model.EditAccess.Enabled; // // create the page pageMenuGroup // Evado.UniForm.Model.Group pageGroup = ClientDataObject.Page.AddGroup ( EdLabels.Menu_General_Group_Title, Evado.UniForm.Model.EditAccess.Inherited ); pageGroup.Layout = Evado.UniForm.Model.GroupLayouts.Full_Width; // // Add the platform selection list // optionList.Add ( new EvOption ( EuMenus.CONST_ADMIN_APPLICATION_IDENTIFIER, EdLabels.Menu_Admin_Platform_Option_Description ) ); optionList.Add ( new EvOption ( EuMenus.CONST_PRODUCTION_APPLICATION_IDENTIFIER, EdLabels.Menu_Production_Platform_Option_Description ) ); pageField = pageGroup.createSelectionListField ( String.Empty, EdLabels.Menu_Platform_Field_Label, this.Session.MenuPlatformId, optionList ); pageField.EditAccess = Evado.UniForm.Model.EditAccess.Disabled; // // Create the customer id object // optionList = this.AdapterObjects.PageIdentifiers; Evado.Digital.Model.EvcStatics.sortOptionListValues ( optionList ); pageField = pageGroup.createSelectionListField ( EvMenuItem.MenuFieldNames.Page_Id.ToString ( ), EdLabels.Menu_Page_Id_Field_Label, this.Session.MenuItem.PageId.ToString ( ), optionList ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the customer name object // pageField = pageGroup.createTextField ( EvMenuItem.MenuFieldNames.Title.ToString ( ), EdLabels.Menu_Title_Field_Label, String.Empty, this.Session.MenuItem.Title, 20 ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the customer name object // pageField = pageGroup.createNumericField ( EvMenuItem.MenuFieldNames.Order.ToString ( ), EdLabels.Menu_Order_Field_Label, this.Session.MenuItem.Order, 0, 200 ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Create the customer name object // optionList = this.AdapterObjects.Settings.GetRoleOptionList ( false ); string roles = this.Session.MenuItem.RoleList; pageField = pageGroup.createCheckBoxListField ( EvMenuItem.MenuFieldNames.Role_List.ToString ( ), EdLabels.Menu_Role_List_Field_Label, roles, optionList ); pageField.Layout = EuAdapter.DefaultFieldLayout; pageField.Description = EdLabels.Menu_Role_List_Field_Description; // // Create the customer name object // pageField = pageGroup.createTextField ( EvMenuItem.MenuFieldNames.Parameters.ToString ( ), EdLabels.Menu_Parameters_Field_Label, String.Empty, this.Session.MenuItem.Parameters, 20 ); pageField.Layout = EuAdapter.DefaultFieldLayout; // // Add the save groupCommand // pageCommand = pageGroup.addCommand ( EdLabels.Menu_Save_Command_Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Menu.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Save_Object ); // // Define the save and delete groupCommand parameters // pageCommand.SetGuid ( ClientDataObject.Id ); // // Add the delete groupCommand object. // pageCommand = pageGroup.addCommand ( EdLabels.Menu_Delete_Command_Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Menu.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Save_Object ); // // Define the save and delete groupCommand parameters // pageCommand.SetGuid ( ClientDataObject.Id ); pageCommand.AddParameter ( Evado.Digital.Model.EvcStatics.CONST_SAVE_ACTION, EuMenus.CONST_DELETE_ACTION ); }//END Method