Skip to content

Commit

Permalink
Release v1.1.2
Browse files Browse the repository at this point in the history
- fix sense export
- remove release notes from project
  • Loading branch information
HighCoordination committed Jan 22, 2018
1 parent e4c135a commit b9ae39d
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 202 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@ from version 3.0.0 up to currently latest version November 2017 Patch 1 includin

## Update

### trueChart-Menubar v1.1.0

**2017-12-21**
### trueChart-Menubar v1.1.x

> **Features and Improvements**
* **Support of Sense PDF export function** [HICO-2178]
Expand Down
193 changes: 0 additions & 193 deletions RELEASE_NOTES.txt

This file was deleted.

2 changes: 1 addition & 1 deletion gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ gulp.task('clean', function(){
gulp.task('resources', function(){
let qextFile = _env.PKG_NAME + '.qext';

let textData = gulp.src(`${_env.resourceDir}/{${qextFile},config.js,RELEASE_NOTES.txt}`)
let textData = gulp.src(`${_env.resourceDir}/{${qextFile},config.js}`)
.pipe(replace('##DATE##', _env.DATE))
.pipe(replace('##VERSION##', _env.VERSION))
.pipe(replace('##BUILD_NUMBER##', _env.BUILD_NUMBER))
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "truechart-menubar",
"version": "1.1.1",
"version": "1.1.2",
"description": "trueChart-Menubar as visualization extension for Qlik Sense® allows for vertical and horizontal buttons and selections (fields, master dimensions and variables) as well as unlimited trigger based Actions. #trueChart #trueChart-Menubar #highcoordination",
"main": "tcmenu.js",
"keywords": [
Expand Down
8 changes: 7 additions & 1 deletion src/js/Directives/SenseSelect.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ define([

qvangular.directive('senseselect', ['utilService', prefix + 'QlikService', SenseSelect]);

function SenseSelect(utilService){
function SenseSelect(utilService, qlikService){
return {
restrict: 'E',
scope: {
Expand All @@ -27,6 +27,10 @@ define([

$scope.utilService = utilService;

if(qlikService.isPrinting()){
$scope.item.show = $scope.item.isOpen = false;
}

$scope.openSenseSelect = function(item){
if(qlik.navigation.getMode() !== "edit"){

Expand Down Expand Up @@ -84,6 +88,8 @@ define([
item.listBox = visual;
visual.show($element.find('#QV05_' + $scope.itemId)[0]);
$scope.dimensionInfo = visual.model.layout.qListObject.qDimensionInfo;

$scope.parentscope.removePropsForPrinting($scope.parentscope.layout.exportListItemsDub);
});
}else{
console.warn("No Dimension Selected");
Expand Down
31 changes: 28 additions & 3 deletions src/js/init.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export function Extension(){
$scope.selState = _app.selectionState();
$scope.selState.OnData.bind(updateSelectionLabels);
}else{
_waitForUpdates = Promise.resolve();
_waitForUpdates = Promise.resolve({});
}
//##################### End Updates ###################

Expand Down Expand Up @@ -112,6 +112,7 @@ export function Extension(){
$scope.updateSelectionLabels = updateSelectionLabels;
$scope.handleButtonStates = handleButtonStates;
$scope.updateListItemsProps = updateListItemsProps;
$scope.removePropsForPrinting = removePropsForPrinting;
$scope.checkAndUpdateListObjects = checkAndUpdateListObjects;
$scope.checkExpressionCondition = checkExpressionCondition;

Expand Down Expand Up @@ -388,7 +389,7 @@ export function Extension(){
removeListener(_eventListener, _model.id); // remove previous listener before adding new ones
_eventListener[_model.id] = [
qlikService.bindListener(_model, 'Validated', setReady),
qlikService.bindListener(_model, 'Invalidated', () => setReady(false))
qlikService.bindListener(_model, 'Invalidated', () => setReady(false))
];

if(_selectionsInProgress){
Expand Down Expand Up @@ -751,7 +752,7 @@ export function Extension(){
}else{
// in case of other values ('1') it is important that the variable is set despite errors
return _app.variable.setStringValue(name, value)
.catch(qlikService.engineErrorHandler(_app.variable, 'setStringValue', [name, value]));
.catch(qlikService.engineErrorHandler(_app.variable, 'setStringValue', [name, value]));
}
}
});
Expand Down Expand Up @@ -884,6 +885,18 @@ export function Extension(){
});
});
}

function removePropsForPrinting(listItemsDub){
listItemsDub.forEach(function(listItem){

if(listItem.type === 'Group'){
removePropsForPrinting(listItem.groupItems)
}

delete listItem.listBox;

});
}
}

function getDimTitle(dimId, dimensions){
Expand Down Expand Up @@ -931,6 +944,7 @@ export function Extension(){

if($scope.isPrinting){
$scope.listItemsDub = layout.exportListItemsDub;
$scope._listObjects = layout.exportListObjects;

paintingPromise.resolve();

Expand Down Expand Up @@ -970,6 +984,17 @@ export function Extension(){

if(!$scope.isPrinting){
layout.exportListItemsDub = $scope.listItemsDub;
layout.exportListObjects = {};

$scope.removePropsForPrinting(layout.exportListItemsDub);

$scope._listObjects && Object.keys($scope._listObjects).forEach(function(key) {
if($scope._listObjects[key]){
layout.exportListObjects[key] = $scope._listObjects[key].layout;
}
});


}

paintingPromise.resolve();
Expand Down

0 comments on commit b9ae39d

Please sign in to comment.