//=================================================================================== /// <summary> /// This method set the form record type. /// </summary> /// <param name="FormType">EvFormRecordTypes enumerated list</param> //----------------------------------------------------------------------------------- public void SetLayoutType(String FormType) { EdRecordTypes recordType = EdRecordTypes.Null; if (EvStatics.tryParseEnumValue <EdRecordTypes> (FormType, out recordType) == true) { this.RecordLayoutTypeSelection = recordType; } this.RecordLayoutTypeSelection = EdRecordTypes.Null; }
}//END method // ===================================================================================== /// <summary> /// This method generates the commands associated with the selected menu item. /// </summary> /// <param name="PageId">String: page identifier</param> /// <param name="Title">String: command title</param> /// <returns>Evado.UniForm.Model.Command object.</returns> // ------------------------------------------------------------------------------------ public Evado.UniForm.Model.Command GetNavigationCommand ( String PageId, String Title, String Parameters) { this.resetAdapterLog ( ); this.LogMethod ( "getMenuCommandObject" ); this.LogDebug ( "PageId: {0}, Title: {1}.", PageId, Title ); // // Initialise the methods variables and objects. // Evado.Digital.Model.EdStaticPageIds pageId = Evado.Digital.Model.EdStaticPageIds.Null; Evado.UniForm.Model.Command pageCommand = new Evado.UniForm.Model.Command ( ); // // process static page identifeirs to create their commands. // if ( EvStatics.tryParseEnumValue<Evado.Digital.Model.EdStaticPageIds> ( PageId, out pageId ) == true ) { #region Admin menu items // // Administration page commands // switch ( pageId ) { case Evado.Digital.Model.EdStaticPageIds.Application_Profile: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Database_Version: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( Evado.Digital.Model.EdStaticPageIds.Database_Version ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Email_Templates_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Email_Templates.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Application_Event_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Events.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Application_Event: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Events.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); // // Add the groupCommand parameters. // pageCommand.SetGuid ( this.Session.MenuItem.Guid ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Organisation_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Organisations.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Organisation_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Organisations.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); // // Add the groupCommand parameters. // pageCommand.SetGuid ( this.Session.MenuItem.Guid ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.User_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Users.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.My_User_Profile_Update_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Users.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Email_User_Page: { string [] arParameters = Parameters.Split ( ';' ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Users.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); foreach ( string parm in arParameters ) { if ( parm.Contains ( "=" ) == false ) { continue; } String [] arParm = parm.Split ( '=' ); pageCommand.AddParameter ( arParm [ 0 ], arParm [ 1 ] ); } return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Menu_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Menu.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } }//END admin page switch statement //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region applilcation configuration // // Project configuration menu commands. // switch ( pageId ) { case Evado.Digital.Model.EdStaticPageIds.Alert_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Alert.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Binary_File_List_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Binary_File.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Page_Layout_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Page_Layouts.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Page_Layout_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Page_Layouts.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Selection_List_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Selection_Lists.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Selection_List_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Selection_Lists.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Record_Layout_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Record_Layouts.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Entity_Layout_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entity_Layouts.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } }//END admin page switch statement //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region analysis and reporting menu items. // // Project analysis and reporting menu commands. // switch ( pageId ) { case Evado.Digital.Model.EdStaticPageIds.Data_Charting_Page: { this.LogValue ( PageId + " ADDED" ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Analysis.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Record_Query_Page: { this.LogValue ( PageId + " ADDED" ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Analysis.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Audit_Configuration_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Audit_Records_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Audit_Record_Items_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } } //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region reporting menu items. // // Project analysis and reporting menu commands. // switch ( pageId ) { case Evado.Digital.Model.EdStaticPageIds.Report_Template_View: { this.LogValue ( PageId + " ADDED" ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.ReportTemplates.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Report_Template_Page: { this.LogValue ( PageId + " ADDED" ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.ReportTemplates.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Operational_Report_List: { this.LogValue ( PageId + " ADDED" ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Reports.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Operational_Report_Page: { this.LogValue ( PageId + " ADDED" ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Reports.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); return pageCommand; } }//END switch statement //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region record menu items. // // Project records menu commands. // switch ( pageId ) { // ------------------------------------------------------------------------------ // milestone ancillary records pages. // case Evado.Digital.Model.EdStaticPageIds.Ancillary_Record_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Ancillary_Record.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Records_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Record_Export_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Record_Admin_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Record_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.SetGuid ( this.Session.Record.Guid ); if ( this.Session.Entity != null ) { pageCommand.AddParameter ( EdRecord.FieldNames.TypeId, this.Session.Entity.TypeId ); } return pageCommand; } //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Entity commands // // Entitity menu commands // case Evado.Digital.Model.EdStaticPageIds.Entity_View: case Evado.Digital.Model.EdStaticPageIds.Entity_Filter_View: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Entity_Export_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Entity_Admin_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); return pageCommand; } case Evado.Digital.Model.EdStaticPageIds.Entity_Page: { pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.SetGuid ( this.Session.Entity.Guid ); if ( this.Session.Entity != null ) { pageCommand.AddParameter ( EdRecord.FieldNames.TypeId, this.Session.Entity.TypeId ); } return pageCommand; } }//END switch //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion }//END Static page ids. // // Create the command to to display a page layout.. // if ( PageId.Contains ( EuAdapter.CONST_PAGE_ID_PREFIX ) == true ) { string stPageId = PageId.Replace ( EuAdapter.CONST_PAGE_ID_PREFIX, String.Empty ); this.LogDebug ( "PAGE: PageId: {0}, Title: {1} StPageId: {2}.", PageId, Title, stPageId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Page.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( stPageId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); return pageCommand; } // // Create the command to query Entities as a filtered list // i.e. retrieves an organisation's child entity layout. // if ( PageId.Contains ( EuAdapter.CONST_AUTHOR_PAGE_ID_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); layoutId = layoutId.Replace ( EuAdapter.CONST_AUTHOR_PAGE_ID_SUFFIX, String.Empty ); this.LogDebug ( "AUTHOR: PageId: {0}, Title: {1} Layout: {2}, Author Query.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( Evado.Digital.Model.EdStaticPageIds.Entity_View ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EdRecord.FieldNames.Author, this.Session.UserProfile.UserId ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentUserId, this.Session.UserProfile.UserId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EuEntities.CONST_AUTHOR_SELECTION, "Yes" ); return pageCommand; } // // Create the command to query Entities as a filtered list // i.e. retrieves an organisation's child entity layout. // if ( PageId.Contains ( EuAdapter.CONST_ENTITY_FILTERED_LIST_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); layoutId = layoutId.Replace ( EuAdapter.CONST_ENTITY_FILTERED_LIST_SUFFIX, String.Empty ); this.LogDebug ( "FILTERED: PageId: {0}, Title: {1} Layout: {2}, Filtered Query.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( Evado.Digital.Model.EdStaticPageIds.Entity_Filter_View ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_EMPTY_SELECTION_FIELD, "Yes" ); return pageCommand; } // // Create the command to access a Entity by its organisation parent's identifier. // i.e. retrieves an organisation's child entity layout. // if ( PageId.Contains ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX2 ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); this.LogDebug ( "1 layoutId: {0}.", layoutId ); layoutId = layoutId.Replace ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX2, String.Empty ); this.LogDebug ( "2 Template: {0}.", EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX2 ); this.LogDebug ( "2 layoutId: {0}.", layoutId ); this.LogDebug ( "ORG: PageId: {0}, Title: {1} Layout: {2}, Org Parent.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentOrgId, this.Session.Organisation.OrgId ); this.LogDebug ( "Command Method: {0}.", pageCommand.Method ); return pageCommand; } // // Create the command to access a Entity by its organisation parent's identifier. // i.e. retrieves an organisation's child entity layout. // if ( PageId.Contains ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); this.LogDebug ( "1 layoutId: {0}.", layoutId ); layoutId = layoutId.Replace ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX, String.Empty ); this.LogDebug ( "2 Template: {0}.", EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX ); this.LogDebug ( "2 layoutId: {0}.", layoutId ); this.LogDebug ( "ORG: PageId: {0}, Title: {1} Layout: {2}, Org Parent.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentOrgId, this.Session.Organisation.OrgId ); return pageCommand; } // // Create the command to access a Entity by its user parent's identifier. // i.e. retrieves an user's child entity layout. // else if ( PageId.Contains ( EuAdapter.CONST_USER_PARENT_PAGE_ID_SUFFIX2 ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); this.LogDebug ( "1 layoutId: {0}.", layoutId ); layoutId = layoutId.Replace ( EuAdapter.CONST_USER_PARENT_PAGE_ID_SUFFIX2, String.Empty ); this.LogDebug ( "2 layoutId: {0}.", layoutId ); this.LogDebug ( "DEF USR: PageId: {0}, Title: {1} Layout: {2}, User Parent.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentUserId, this.Session.UserProfile.UserId ); return pageCommand; } // // Create the command to access a Entity by its user parent's identifier. // i.e. retrieves an user's child entity layout. // else if ( PageId.Contains ( EuAdapter.CONST_USER_PARENT_PAGE_ID_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); layoutId = layoutId.Replace ( EuAdapter.CONST_USER_PARENT_PAGE_ID_SUFFIX, String.Empty ); this.LogDebug ( "USER: PageId: {0}, Title: {1} Layout: {2}, User Parent.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentUserId, this.Session.UserProfile.UserId ); return pageCommand; } // // Create the command to access a Entity by its Entity parent. // i.e. retrieves an Entity's child records layout. // else if ( PageId.Contains ( EuAdapter.CONST_ENTITY_PARENT_PAGE_ID_SUFFIX ) == true ) { this.LogDebug ( "A PageId: {0}, Title: {1} Entity Parent.", PageId, Title ); string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PARENT_PAGE_ID_SUFFIX, String.Empty ); this.LogDebug ( "1 layoutId: {0}.", layoutId ); layoutId = layoutId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); this.LogDebug ( "2 layoutId: {0}.", layoutId ); this.LogDebug ( "PARENT: PageId: {0}, Title: {1} Layout: {2}, User Parent.", PageId, Title, layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentGuid, this.Session.Entity.Guid ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentLayoutId, this.Session.Entity.LayoutId ); return pageCommand; } // // Create the command to access a Entity by its Entity parent. // i.e. retrieves an Entity's child records layout. // else if ( PageId.Contains ( EuAdapter.CONST_ENTITY_PARENT_PAGE_ID_SUFFIX ) == true ) { this.LogDebug ( "A PageId: {0}, Title: {1} Entity Parent.", PageId, Title ); string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PARENT_PAGE_ID_SUFFIX, String.Empty ); this.LogDebug ( "1 layoutId: {0}.", layoutId ); layoutId = layoutId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); this.LogDebug ( "2 layoutId: {0}.", layoutId ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentGuid, this.Session.Entity.Guid ); return pageCommand; } // // Create the command to access Entities by their layout identifers. // else if ( PageId.Contains ( EuAdapter.CONST_ENTITY_PREFIX ) == true ) { this.LogDebug ( "PageId: {0}, Title: {1} Layout.", PageId, Title ); string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PREFIX, String.Empty ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); return pageCommand; } // // Create the command to access records by their layout identifers. // if ( PageId.Contains ( EuAdapter.CONST_RECORD_PREFIX) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_RECORD_PREFIX, String.Empty ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); return pageCommand; } // // Create the command to access a record by its organisation parent's identifier. // i.e. retrieves an organisation's child entity layout. // else if ( PageId.Contains ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX, String.Empty ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentOrgId, this.Session.Organisation.OrgId ); return pageCommand; } // // Create the command to access a record by its user parent's identifier. // i.e. retrieves an user's child entity layout. // else if ( PageId.Contains ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ORG_PARENT_PAGE_ID_SUFFIX, String.Empty ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentUserId, this.Session.UserProfile.UserId ); return pageCommand; } // // Create the command to access a record by its Entity parent. // i.e. retrieves an Entity's child records layout. // else if ( PageId.Contains ( EuAdapter.CONST_ENTITY_PARENT_PAGE_ID_SUFFIX ) == true ) { string layoutId = PageId.Replace ( EuAdapter.CONST_ENTITY_PARENT_PAGE_ID_SUFFIX, String.Empty ); pageCommand = new Evado.UniForm.Model.Command ( Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.UniForm.Model.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( PageId ); pageCommand.AddParameter ( EdRecord.FieldNames.Layout_Id, layoutId ); pageCommand.AddParameter ( EuEntities.CONST_HIDE_SELECTION, "Yes" ); pageCommand.AddParameter ( EdRecord.FieldNames.ParentGuid, this.Session.Entity.Guid ); return pageCommand; } return null; }//END convertMenuItem method
//=================================================================================== /// <summary> /// This value checks that a parameter exists in the test action /// /// </summary> /// <param name="Parameter">EuTestActionParameters enumerated value.</param> /// <returns>Bool: True indicates the parameter exists.</returns> //----------------------------------------------------------------------------------- public bool createParameterList ( ) { // // If option list exists then exit as it does not need to be created. // if ( this._optionList.Count > 0 ) { return true; } // // If there are no parameters then exit with error as nothing can be created. // if ( this._Parameters == String.Empty ) { return false; } // // initialise the methods variables and objects. // string [ ] arParameters = this._Parameters.Split ( ';' ); EutCommandParameters enParameter = EutCommandParameters.Null; this.AddResponse = String.Empty; // // Iterate through the parameters array creating a parameter list. // foreach ( String parameter in arParameters ) { // // exit is parmeter is empty. // if ( parameter == String.Empty ) { return false; } // // exit is parmeter is empty. // if ( parameter.Contains ( "=" ) == false ) { return false; } int eqIndex = parameter.IndexOf ( '=' ); string parmeterName = parameter.Substring ( 0, eqIndex ); String parmeterValue = parameter.Substring ( eqIndex + 1 ); parmeterName = parmeterName.Trim ( ); // // validate that the parameter is valid. // if ( EvStatics.tryParseEnumValue<EutCommandParameters> ( parmeterName, out enParameter ) == false ) { this.Result = EutCommandResults.Parameter_Validation_Failure; this.AddResponse = "Parameter : " + parmeterName + " failed type validation. "; return false; } this._optionList.Add ( new EutParameter ( enParameter, parmeterValue.Trim ( ) ) ); }//End parameter iteration loop. // // test to see if the value value needs to be reversed. // this.hasReverseStatus ( ); return true; }//END createParameterList method
}//END hasTestParameter value //=================================================================================== /// <summary> /// This value set a class member value. /// </summary> //----------------------------------------------------------------------------------- public bool SetValue ( EuTestCaseMembers Member, String Value ) { // // initialise the methods variables // int iValue = 0; EutCommand testType = EutCommand.Null; EutCommandResults result = EutCommandResults.Ok; switch ( Member ) { case EuTestCaseMembers.Section: { if ( int.TryParse ( Value, out iValue ) == false ) { return false; } this.SectionNo = iValue; return true; } case EuTestCaseMembers.No: { if ( int.TryParse ( Value, out iValue ) == false ) { return false; } this.TestNo = iValue; return true; } case EuTestCaseMembers.Action: { if ( EvStatics.tryParseEnumValue<EutCommand> ( Value, out testType ) == false ) { return false; } this.Action = testType; return true; } case EuTestCaseMembers.Parameters: { this.Parameters = Value; this.createParameterList ( ); return true; } case EuTestCaseMembers.Description: { this.Description = Value; return true; } case EuTestCaseMembers.TestResponse: { this.AddResponse = Value; return true; } case EuTestCaseMembers.TestResult: { if ( EvStatics.tryParseEnumValue<EutCommandResults> ( Value, out result ) == false ) { return false; } this.Result = result; return true; } } return false; }
}//END Method #endregion // ===================================================================================== /// <summary> /// This method generates the commands associated with the selected menu item. /// </summary> /// <param name="MenuItem">The menu object</param> /// <returns>ClientClientDataObjectEvado.Model.UniForm.Command object.</returns> // ------------------------------------------------------------------------------------ public Evado.Model.UniForm.Command getMenuItemCommandObject ( EvMenuItem MenuItem ) { this.resetAdapterLog ( ); this.LogMethod ( "getMenuCommandObject" ); this.LogDebug ( "PageId: {0}, Title: {1}, Group: ", MenuItem.PageId, MenuItem.Title, MenuItem.Group ); Evado.Model.UniForm.Command pageCommand = new Evado.Model.UniForm.Command ( "Title", Evado.Model.UniForm.CommandTypes.Normal_Command, EuAdapter.ADAPTER_ID, String.Empty, Evado.Model.UniForm.ApplicationMethods.Get_Object ); EdStaticPageIds pageId = EdStaticPageIds.Null; if ( EvStatics.tryParseEnumValue<EdStaticPageIds> ( MenuItem.PageId, out pageId ) == true ) { #region Admin menu items // // Administration page commands // switch ( pageId ) { case EdStaticPageIds.Application_Profile: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Database_Version: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( EdStaticPageIds.Database_Version ); return pageCommand; } case EdStaticPageIds.Email_Templates_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Email_Templates.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Application_Event_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Events.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Application_Event: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Events.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); // // Add the groupCommand parameters. // pageCommand.SetGuid ( this.Session.MenuItem.Guid ); return pageCommand; } case EdStaticPageIds.Organisation_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Organisations.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Organisation_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Organisations.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); // // Add the groupCommand parameters. // pageCommand.SetGuid ( this.Session.MenuItem.Guid ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.User_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Users.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.User_Profile_Update_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Users.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Menu_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Menu.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } }//END admin page switch statement //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region applilcation configuration // // Project configuration menu commands. // switch ( pageId ) { case EdStaticPageIds.Alert_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Alert.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Binary_File_List_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Binary_File.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Selection_List_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Selection_Lists.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Selection_List_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Selection_Lists.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Record_Layout_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Record_Layouts.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Entity_Layout_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entity_Layouts.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } }//END admin page switch statement //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region project analysis and reporting menu items. // // Project analysis and reporting menu commands. // switch ( pageId ) { case EdStaticPageIds.Data_Charting_Page: { this.LogValue ( MenuItem.PageId + " ADDED" ); pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Analysis.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Record_Query_Page: { this.LogValue ( MenuItem.PageId + " ADDED" ); pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Analysis.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Audit_Configuration_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Audit_Records_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Audit_Record_Items_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Application_Properties.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } } //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region reporting menu items. // // Project analysis and reporting menu commands. // switch ( pageId ) { case EdStaticPageIds.Report_Template_View: { this.LogValue ( MenuItem.PageId + " ADDED" ); pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.ReportTemplates.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Report_Template_Page: { this.LogValue ( MenuItem.PageId + " ADDED" ); pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.ReportTemplates.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Operational_Report_List: { this.LogValue ( MenuItem.PageId + " ADDED" ); pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Reports.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Operational_Report_Page: { this.LogValue ( MenuItem.PageId + " ADDED" ); pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Reports.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } }//END switch statement //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region record menu items. // // Project records menu commands. // switch ( pageId ) { // ------------------------------------------------------------------------------ // milestone ancillary records pages. // case EdStaticPageIds.Ancillary_Record_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Ancillary_Record.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Records_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Record_Export_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Record_Admin_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Record_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Records.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); pageCommand.SetGuid ( this.Session.Record.Guid ); if ( this.Session.Entity != null ) { pageCommand.AddParameter ( EdRecord.RecordFieldNames.TypeId, this.Session.Entity.TypeId ); } return pageCommand; } //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion #region Entity commands // // Entitity menu commands // case EdStaticPageIds.Entity_View: case EdStaticPageIds.Entity_Query_View: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Entity_Export_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Entity_Admin_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.Model.UniForm.ApplicationMethods.List_of_Objects ); pageCommand.SetPageId ( MenuItem.PageId ); return pageCommand; } case EdStaticPageIds.Entity_Page: { pageCommand = new Model.UniForm.Command ( MenuItem.Title, EuAdapter.ADAPTER_ID, EuAdapterClasses.Entities.ToString ( ), Evado.Model.UniForm.ApplicationMethods.Get_Object ); pageCommand.SetPageId ( MenuItem.PageId ); pageCommand.SetGuid ( this.Session.Entity.Guid ); if ( this.Session.Entity != null ) { pageCommand.AddParameter ( EdRecord.RecordFieldNames.TypeId, this.Session.Entity.TypeId ); } return pageCommand; } }//END switch } //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ #endregion return null; }//END convertMenuItem method