1234567891011121314151617181920212223242526272829303132333435363738394041 |
- // Licensed Materials - Property of IBM
- // IBM Cognos Products: rs
- // (C) Copyright IBM Corp. 2015, 2020
- // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- define(['bi/glass/app/plugins/MenuActionInterface'], function(MenuActionInterface) {
- var CreateReportMenu = MenuActionInterface.extend({
-
- onSelectItem: function(context) {
- var v_sMenuItem = context.target.itemId;
-
- console.log("CreateReportMenu, " + v_sMenuItem + ", selected");
- console.log("CREATE TEMPLATE SELECTED.");
-
- context.glassContext.openAppView(
- 'authoring',
- {
- content:
- {
- // TODO
- // provide and id for glass to cache
- // HACK until we get we work out the proper id
- id: Date.now().toString(),
- }
- });
- },
-
- isItemVisible: function(context){
- console.log("rsAppRunMenu.isItemVisible");
-
- if (!context.glassContext.hasCapability('canUseReportStudio'))
- {
- return false;
-
- }
- return true;
- }
- });
- return CreateReportMenu;
- });
|