# # # # build_profiles_page() # # # include "templates.util.encoding"; include "templates.admin_pages.profiles.get_convert_profile_state"; include "templates.admin_pages.profiles_dashboard.profiles_dashboard_util"; # # # get_config_options_and_tools_menu_items # # subroutine(get_config_options_and_tools_menu_items( bool is_lite, string menu_name), ( # menu_name is "config_options" or "tools" # This creates a javascript menu structure for the config_options or tools menu. node menu_path = "templates.config_pages.config_navigation"; node features = menu_path {"features"}; node menu_groups; if (!is_lite) then ( menu_groups = menu_path{menu_name}; ) else ( menu_groups = menu_path{"lite"}{menu_name}; ); node menu_item; node group; int num_groups = num_subnodes(menu_groups); int group_count = 1; int num_list_items; int list_count; string page_name; string label; bool show_separator = false; string menu_dat = "["; string menu_item_dat; foreach group menu_groups ( num_list_items = num_subnodes(group); list_count = 1; foreach menu_item group ( page_name = node_name(menu_item); label = expand(@features{page_name}{"label"}); # Add separator line class name on last list item, except in last group. if (num_list_items == list_count and num_groups != group_count) then ( show_separator = true; ) else ( show_separator = false; ); menu_item_dat = "{"; menu_item_dat .= add_json("page", page_name, "string"); menu_item_dat .= add_json("label", label, "string"); menu_item_dat .= add_json("separator", show_separator, "bool"); menu_item_dat = close_json(menu_item_dat); menu_dat .= menu_item_dat . ","; list_count++; ); group_count++; ); menu_dat = replace_last(menu_dat, ",", "]"); # Return menu_dat; )); # # # build_profiles_page # # subroutine(build_profiles_page( string session_id, bool is_msie_v6, string licensing_tier, string user_node_name, bool is_root_admin, node user_grants, bool is_view_dashboard_permission, bool is_edit_dashboard_permission), ( # # # Get initial profile data # # bool is_lite = (licensing_tier eq "lite"); int num_licensed_profiles = get_number_of_licensed_profiles(); node feature_permissions = user_grants{"super_admin"}{"profiles"}; string profiles_list_checksum = get_profiles_list_checksum(session_id, is_root_admin, user_node_name); string profiles_dashboard_view_dat = get_profiles_dashboard_view_dat(is_root_admin, is_view_dashboard_permission, user_grants); string profile_conversion_state_dat = get_convert_profile_state(); string config_options_menu_items = get_config_options_and_tools_menu_items(is_lite, "config_options"); string tools_menu_items = get_config_options_and_tools_menu_items(is_lite, "tools"); bool is_add_permission = (feature_permissions?{"add"}); # Check if we show profiles filter bool show_profiles_filter = false; string preferences_path = "users_cache." . user_node_name . ".preferences.show_profiles_filter"; if (?(preferences_path)) then ( show_profiles_filter = @(preferences_path); ); '\n'; # # # Toolbar # # '
'; ''; ''; build_toolbar_spacer(); if (is_root_admin or is_add_permission) then ( build_toolbar_button("profiles", "new_profile"); ); build_toolbar_button("profiles", "view"); build_toolbar_spacer(); # Profiles search box in toolbar ''; build_right_toolbar_spacer(); # build_toolbar_help_button("?dp+docs.technical_manual.toc"); if (is_root_admin or is_add_permission) then ( # Add info text for number of licensed profiles ''; ); ''; '
'; '
'; ''; ''; ''; ''; # ''; ''; '
 ×-
'; '
'; '
'; '
'; # toolbar-10 # # Add view drop down menu # ''; # # # Form section # # ''; # form_section # # # # Saving info # # # ''; # # # # Deleting info # # # ''; # # # # # New profile info # # # # '
'; # Panel header, is inserted by javascript! # # # Panel body # # '
\n'; ''; # new_profile_info '
'; # panel-30-body '
'; # new_profile_info:panel # # # # Rename profile form # # # '
'; # Panel header, is inserted by javascript! # # Panel body # '
\n'; '
'; '
'; ''; ''; ''; ''; ''; ''; ''; ''; ''; '
'; 'Duplicate profile __PARAM__1 excluding its database.'; # Text becomes replaced via js '
'; ''; '
'; '
'; '
'; # panel-50-form # # # Save, Cancel button # # '
'; ''; ''; '
'; '
'; # rename_profile:form '
\n'; # panel-50-body '
\n'; # rename_profile:panel # # # Rename profile database form # # '
'; # Panel header, is inserted by javascript! # # Panel body # '
\n'; '
'; '
'; '

-

'; # Text is set via js ''; ''; ''; ''; ''; ''; ''; ''; ''; ''; ''; ''; ''; ''; ''; '
'; ''; ''; ''; '
'; ''; ''; ''; '
'; ''; ''; '
'; ''; '
'; '
'; '
'; # panel-50-form # # # Save, Cancel button # # '
'; ''; ''; '
'; '
'; # rename_profile_db:form '
\n'; # panel-50-body '
\n'; # rename_profile_db:panel # # # Duplicate profile form # # '
'; # Panel header, is inserted by javascript! # # Panel body # '
\n'; '
'; '
'; ''; ''; ''; ''; ''; ''; # ''; ''; ''; ''; '
'; 'Duplicate profile __PARAM__1 excluding its database.'; # Text becomes replaced via js '
' . lang_admin.profiles.profile_name . ':'; ''; '
'; '
'; '
'; # panel-50-form # # # Save, Cancel button # # '
'; ''; ''; '
'; '
'; # duplicate_profile:form '
\n'; # panel-50-body '
\n'; # duplicate_profile:panel # # # Confirm delete profile form # # '
'; # Panel header div is created by javascript '
'; '
'; # Text is handled by javascript '

Are you sure you want to delete the profile "profile name" and its database?

'; '
'; ' '; ''; '
'; '
'; '
'; ''; ''; '
'; '
'; # panel-50-body '
'; # panel-50 # # # Confirm profile conversion form # # '
'; # Panel header div is created by javascript '
'; '
'; '

' . lang_admin.profiles.start_converting_profiles . '

'; '
'; '
'; ''; ''; '
'; '
'; # panel-50-body '
'; # panel-50 # # # Profiles view, confirm delete column # # '
'; # Panel header div is created by javascript '
'; '
'; # Text is handled by javascript '

' . lang_admin.profiles.confirm_delete_column . '

'; '
'; '
'; ''; ''; '
'; '
'; # panel-50-body '
'; # panel-50 # # # Profiles view, edit column or cell form # # '
'; # Panel header, is inserted by javascript! # # Panel body # '
\n'; '
'; '
'; ''; # Select profile ''; ''; ''; ''; ''; ''; ''; # Select report field ''; ''; ''; ''; ''; # Show column label - header cell only ''; ''; ''; ''; # Custom column label - header cell only ''; ''; ''; ''; # Show cell labels - header cell only ''; ''; ''; ''; ''; ''; # Show cell label - body cell only ''; ''; ''; ''; ''; ''; # Custom cell label for header and body cell ''; ''; ''; ''; ''; '
' . lang_admin.profiles.reference_profile . ':'; ''; '
'; '
' . lang_admin.profiles.report_field . ':'; ''; '
'; '
 '; ' '; ''; '
' . lang_admin.profiles.column_label . ':'; ' '; '(' . lang_admin.profiles.leave_blank_to_use_report_field_label . ')'; '
 '; ' '; ''; '
 '; ' '; ''; '
' . lang_admin.profiles.cell_label . ':'; ' '; '(' . lang_admin.profiles.leave_blank_to_use_report_field_label . ')'; '
'; '
'; # panel-50-form # # # Save, Cancel button # # '
'; ''; ''; '
'; '
'; # edit_cell:form '
\n'; # panel-50-body '
\n'; # edit_cell:panel ));