MicroStrategy ONE

Using Menus

The menus section in pageConfig.xml contains a series of menus— represented by individual <shortcut-list-set> elements— that are available to different pages. The config-src attribute of each <shortcut-list-set> element points to an external XML that contains the actual definition of the menu.

<menus>

    ...

    <shortcut-list-set config-src="/WEB-INF/xml/config/reportMenu.xml" name="report-menu"/>

    <shortcut-list-set config-src="/WEB-INF/xml/config/documentMenu.xml" name="document-menu"/>

    ...

    <shortcut-list-set name="report-toolbars">

        <shortcut-list config-src="/WEB-INF/xml/config/reportToolbarsMenu.xml" name="report-toolbars"/>

    </shortcut-list-set>

    ...

</menus>

Menus Structure

Each external XML menu definition file (that is, each file referenced by a config-src attribute in a <shortcut-list-set> child element of the <menus> node in pageConfig.xml) is made up the following XML elements:

  • <shortcut-list-set>: Root node for the menu. Delimits a menu from a different element in the HTML output.

    • <shortcut-list>: A menu can have multiple sections. A <shortcut-list> element delimits these sections. It contains a series of <shortcut> elements.

      • <shortcut>: A shortcut defines an option available in a menu. It includes  <event> child elements that specify the event to be triggered when the menu is clicked. The <event> elements in turn can have <argument> child elements.

A longer code sample from the reportMenu.xml file is shown below

<shortcut-list-set base-bean="rb" name="report-menu" version="1.0">

  <shortcut-list base-bean="rb" desc="File" desc-id="mstrWeb.489" name="report" use-default="false">

    <shortcut append-state="true" base-bean="rb" desc="New" desc-id="mstrWeb.1895" feature-id="new-report" href="#" iframe="false" name="report1">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenCreate"/>

    </shortcut>

    

    <shortcut append-state="true" base-bean="rb" desc="Save As" desc-id="mstrWeb.1896" enable-feature-id="enable-save-report" feature-id="is-viewable-report;save-report" href="#" iframe="false" name="report2">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventSaveAs">

        <argument name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentApplyChangesFirst" value="false"/>

        <argument base-bean="rb" name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentReportParentFolderID" sys-bean="com.microstrategy.web.beans.ReportBean" value="parentID"/>

        <argument base-bean="frame" name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentReportDesignMode" sys-bean="com.microstrategy.web.beans.ReportFrameBean" value="isDesignMode"/>

      </event>

    </shortcut>

    

    <shortcut append-state="true" base-bean="rb" desc="*Convert to Document*" desc-id="mstrWeb.5180" feature-id="document-execution;dhtml;documents-design-mode" enable-feature-id="is-viewable-report" href="#" iframe="true" name="convertToDoc" onclick="microstrategy.bone(&apos;UniqueReportID&apos;).commands.exec(&apos;createDocFromRpt&apos;);"/>

    

    <shortcut append-state="true" base-bean="rb" desc="Add to History List" desc-id="mstrWeb.1982" enable-feature-id="enable-add-history-list" feature-id="add-history-list" href="#" iframe="true" name="report3">

      <event XMLmerge_id="1" action="disable" event-id="com.microstrategy.web.beans.EnumReportBeanEvents.REPORT_EVENT_SAVE_TO_INBOX"/>

      <event XMLmerge_id="22" action="refresh" base-bean="rb" event-id="com.microstrategy.web.beans.EnumViewBeanEvents.VIEW_EVENT_ADD_TEMPLATE_UNIT" state="hidden"/>

      <event XMLmerge_id="23" action="refresh" base-bean="rb" event-id="com.microstrategy.web.beans.EnumViewBeanEvents.VIEW_EVENT_ADD_METRIC" state="hidden"/>

      <event XMLmerge_id="24" action="refresh" base-bean="rb" event-id="com.microstrategy.web.beans.EnumViewBeanEvents.VIEW_EVENT_GRID_DRILL" state="hidden"/>

      <event XMLmerge_id="25" action="refresh" base-bean="rb" event-id="com.microstrategy.web.beans.EnumViewBeanEvents.VIEW_EVENT_GRAPH_DRILL" state="hidden"/>

      <event XMLmerge_id="26" action="refresh" base-bean="rb" event-id="com.microstrategy.web.beans.EnumViewBeanEvents.VIEW_EVENT_GRID_DRILL_FIX_TEMPLATE" state="hidden"/>

    </shortcut>

    <shortcut append-state="true" base-bean="rb" desc="Subscribe to" desc-id="mstrWeb.5007" enable-feature-id="enable-scheduled-delivery" feature-id="dhtml;nc-enabled" href="#" iframe="true" name="report17">

      <shortcut append-state="true" base-bean="subs" desc="History List..." desc-id="mstrWeb.5008" enable-feature-id="enable-scheduling" feature-id="scheduling" href="#" iframe="true" name="report17_1">

        <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

          <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="subs"/>

        </event>

      </shortcut>

      <shortcut append-state="true" base-bean="mobileSubs" desc="Mobile..." desc-id="mstrWeb.5009" enable-feature-id="enable-scheduling" feature-id="use-mobile" href="#" iframe="true" name="report17_2">

        <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

          <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="mobileSubs"/>

        </event>

      </shortcut>

      <shortcut append-state="true" base-bean="ncSubs" desc="E-mail..." desc-id="mstrWeb.5068" enable-feature-id="enable-scheduled-email" feature-id="not-datamart;nc-enabled;scheduled-email" href="#" iframe="true" name="report17_3">

        <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

          <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncSubs"/>

        </event>

      </shortcut>

      <shortcut append-state="true" base-bean="ncFileSubs" desc="File..." desc-id="mstrWeb.3250" enable-feature-id="enable-scheduled-file-export" feature-id="not-datamart;nc-enabled;scheduled-file-export-menu" href="#" iframe="true" name="report17_4">

        <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

          <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncFileSubs"/>

        </event>

      </shortcut>

      <shortcut append-state="true" base-bean="ncPrintSubs" desc="Printer..." desc-id="mstrWeb.3251" enable-feature-id="enable-scheduled-print" feature-id="not-datamart;nc-enabled;scheduled-print-menu" href="#" iframe="true" name="report17_5">

        <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

          <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncPrintSubs"/>

        </event>

      </shortcut>

    </shortcut>

    <shortcut append-state="true" base-bean="subs" desc="[Subscribe to History List...]" desc-id="mstrWeb.5069" enable-feature-id="enable-scheduling" feature-id="!multi-subscribe-menu;scheduling" href="#" iframe="true" name="report18">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

        <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="subs"/>

      </event>

    </shortcut>

      <shortcut append-state="true" base-bean="mobileSubs" desc="[Subscribe to Mobile...]" desc-id="mstrWeb.5070" enable-feature-id="enable-scheduling" feature-id="!multi-subscribe-menu;use-mobile" href="#" iframe="true" name="report19">

        <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

          <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="mobileSubs"/>

        </event>

      </shortcut>

    <shortcut append-state="true" base-bean="ncSubs" desc="[Subscribe to E-mail...]" desc-id="mstrWeb.5071" enable-feature-id="enable-scheduled-email" feature-id="!multi-subscribe-menu;not-datamart;nc-enabled;scheduled-email" href="#" iframe="true" name="report20">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

        <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncSubs"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="ncFileSubs" desc="[Subscribe to File...]" desc-id="mstrWeb.5072" enable-feature-id="enable-scheduled-file-export" feature-id="!multi-subscribe-menu;not-datamart;nc-enabled;scheduled-file-export-menu" href="#" iframe="true" name="report21">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

        <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncFileSubs"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="ncPrintSubs" desc="[Subscribe to Printer...]" desc-id="mstrWeb.5073" enable-feature-id="enable-scheduled-print" feature-id="!multi-subscribe-menu;not-datamart;nc-enabled;scheduled-print-menu" href="#" iframe="true" name="report22">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

        <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncPrintSubs"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="ncSendNow" desc="Send Now..." desc-id="mstrWeb.2249" enable-feature-id="enable-send-now" feature-id="dhtml;use-immediate-delivery" href="#" iframe="true" name="report6">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventOpenReportFrameElement">

        <argument name="com.microstrategy.web.app.beans.EnumReportFrameEvents.WebEventArgumentReportFrameElementName" value="ncSendNow"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="rb" desc="Print..." desc-id="mstrWeb.2109" enable-feature-id="enable-print" feature-id="print;!pdf-print" href="#" iframe="false" name="report9" onclick="submitExportForm(this.href,this.target)" target="mstrExportWindow">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenPrintOptionsFromReport">

        <argument name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentPreferenceTransform" value="print"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="rb" desc="Print..." desc-id="mstrWeb.2109" enable-feature-id="enable-pdf" extra-url="&amp;pdfPrint=true" feature-id="pdf;pdf-print" href="#" iframe="false" name="report14" onclick="submitExportForm(this.href,this.target)" target="mstrExportWindow">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenPDFOptionsFromReport">

        <argument name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentPreferenceGroup" value="pdfPrint"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="rb" desc="Export..." desc-id="mstrWeb.2110" enable-feature-id="enable-export" feature-id="any-export" href="#" iframe="false" name="report11" onclick="submitExportForm(this.href,this.target)" target="mstrExportWindow" use-window-open="false">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenExportOptionsFromReport">

        <argument name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentPreferenceTransform" value="export"/>

        <argument base-bean="rb" name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentReportViewMode" sys-bean="com.microstrategy.web.beans.ReportBean" value="viewMode"/>

      </event>

      <event XMLmerge_id="2" action="refresh" base-bean="rb" event-id="com.microstrategy.web.app.beans.EnumDrillEditorEvents.WebEventDrillEditorProcess" state="hidden"/>

      <event XMLmerge_id="3" action="refresh" base-bean="rb" event-id="com.microstrategy.web.app.beans.EnumDrillEditorEvents.WebEventAdvDrillEditorProcess" state="hidden"/>

    </shortcut>

    <shortcut append-state="true" base-bean="rb" desc="PDF..." desc-id="mstrWeb.2111" enable-feature-id="enable-pdf" feature-id="web-export-to-pdf" href="#" iframe="false" name="report13" onclick="submitExportForm(this.href,this.target)" target="mstrExportWindow">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventOpenPDFOptionsFromReport">

        <argument name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentPreferenceGroup" value="pdf"/>

      </event>

    </shortcut>

    <shortcut append-state="true" base-bean="rb" desc="-" desc-id="mstrWeb.0" href="#" iframe="false" name="report15"/>

    <shortcut append-state="true" base-bean="rb" desc="Report Details" desc-id="mstrWeb.1924" feature-id="report-details" href="#" iframe="false" name="report16">

      <event XMLmerge_id="1" event-id="com.microstrategy.web.app.beans.EnumServletEvents.WebEventGetReportDetails">

        <argument base-bean="rb" name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentMessageID" sys-bean="com.microstrategy.web.beans.ReportBean" value="messageID"/>

        <argument base-bean="rb" name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentReportStateID" sys-bean="com.microstrategy.web.beans.ReportBean" value="stateID"/>

        <argument name="com.microstrategy.web.app.beans.EnumServletEvents.WebEventArgumentAllowExecute" value="0"/>

      </event>

    </shortcut>

  </shortcut-list>

...

 

See also: