Compare commits

..

1 Commits

Author SHA1 Message Date
Jingjing Xie
3e273f5b78 fix: enable export as xls options on qcs 2021-06-22 13:33:50 +02:00
3 changed files with 6 additions and 21 deletions

View File

@@ -24,8 +24,7 @@ gulp.task('qext', function () {
repository: pkg.repository,
dependencies: {
'qlik-sense': '>=5.5.x'
},
__next: true
}
};
if (pkg.contributors) {
qext.contributors = pkg.contributors;

View File

@@ -12,7 +12,7 @@ if (!window._babelPolyfill) {
require("@babel/polyfill"); // eslint-disable-line global-require
}
export default ({ flags }) => ({
export default {
design: {
dimensions: {
max: 1,
@@ -104,22 +104,8 @@ export default ({ flags }) => ({
);
return snapshotLayout;
},
async getContextMenu (obj, menu) {
if (!this.$scope.layout.allowexportxls) {
return menu;
}
const app = this.backendApi.model.app;
const isPersonalResult = await app.global.isPersonalMode();
// Export as XLS option is removed from desktop because the desktop wrapper blocks downloads.
// Enabled for windows and QCS
// isPersonalMode returns true for both desktop and QCS
// By checking both if has download dialog and if is QCS can enable Export as XLS option on QCS
if (
(this.backendApi.model.layout.qMeta.privileges.includes('exportdata') && !isPersonalResult) ||
(flags.isEnabled('DOWNLOAD_USE_REPORTING') && isPersonalResult)
) {
getContextMenu (obj, menu) {
if (this.backendApi.model.layout.qMeta.privileges.indexOf('exportdata') !== -1) {
menu.addItem({
translation: 'Export as XLS',
tid: 'export-excel',
@@ -137,4 +123,4 @@ export default ({ flags }) => ({
return menu;
},
version: 1.0
});
};

View File

@@ -2,7 +2,7 @@ const StyleLintPlugin = require('stylelint-webpack-plugin');
const packageJSON = require('./package.json');
const path = require('path');
const DIST = path.resolve("./dist");
const DIST = path.resolve('./dist');
// eslint-disable-next-line no-process-env
const MODE = process.env.NODE_ENV || 'development';
const SOURCE_MAP = 'source-map';