@ardimedia/angular-portal-azure 0.2.101 → 0.2.103
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/apn.d.ts +1 -3
- package/apn.js +6 -80
- package/css/apn.css +1 -1
- package/package.json +1 -1
package/apn.d.ts
CHANGED
|
@@ -333,11 +333,9 @@ declare namespace angularportalazure {
|
|
|
333
333
|
class BladeGrid extends angularportalazure.BladeData {
|
|
334
334
|
constructor(portalService: angularportalazure.PortalService, path: string, title: string, subtitle?: string, width?: number);
|
|
335
335
|
items: any[];
|
|
336
|
-
loadItems(func: () => any): void;
|
|
336
|
+
loadItems(func: () => angular.IPromise<any>): void;
|
|
337
337
|
onLoadedItems(): void;
|
|
338
338
|
onFilter(actual: Object, expected: string): boolean;
|
|
339
|
-
/** Obsolete */
|
|
340
|
-
setObsoleteLayoutProperites(): void;
|
|
341
339
|
}
|
|
342
340
|
}
|
|
343
341
|
declare namespace angularportalazure {
|
package/apn.js
CHANGED
|
@@ -97,7 +97,6 @@ var angularportalazure;
|
|
|
97
97
|
function UserAccount(username, firstName, lastName) {
|
|
98
98
|
if (firstName === void 0) { firstName = ''; }
|
|
99
99
|
if (lastName === void 0) { lastName = ''; }
|
|
100
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'UserAccount\' constructor called.', [this, username, firstName, lastName]);
|
|
101
100
|
this.userName = username;
|
|
102
101
|
this.firstName = firstName;
|
|
103
102
|
this.lastName = lastName;
|
|
@@ -146,7 +145,6 @@ var angularportalazure;
|
|
|
146
145
|
var UserControlBase = (function () {
|
|
147
146
|
//#region Constructor
|
|
148
147
|
function UserControlBase(portalService) {
|
|
149
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'UserControlBase\' constructor called.', [this, portalService]);
|
|
150
148
|
this.portalService = portalService;
|
|
151
149
|
}
|
|
152
150
|
return UserControlBase;
|
|
@@ -240,9 +238,7 @@ var angularportalazure;
|
|
|
240
238
|
items: [],
|
|
241
239
|
navigateTo: function (path) { }
|
|
242
240
|
};
|
|
243
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'Blade\' constructor called.', [_this, portalService, path, title, subtitle, width]);
|
|
244
241
|
var that = _this;
|
|
245
|
-
//this.blade = this;
|
|
246
242
|
_this.path = path;
|
|
247
243
|
_this.title = title;
|
|
248
244
|
_this.subTitle = subtitle;
|
|
@@ -270,6 +266,7 @@ var angularportalazure;
|
|
|
270
266
|
//#region Add BladeArea.AddBlade event listener
|
|
271
267
|
/** OBSOLETE: remove when all OBSOLETE code has been removed */
|
|
272
268
|
if (portalService instanceof angularportalazure.PortalService == false) {
|
|
269
|
+
console.log('Blade.constructor: This code cannot be removed yet.');
|
|
273
270
|
return _this;
|
|
274
271
|
}
|
|
275
272
|
/** OBSOLETE: end */
|
|
@@ -333,7 +330,6 @@ var angularportalazure;
|
|
|
333
330
|
};
|
|
334
331
|
/** close blade. */
|
|
335
332
|
Blade.prototype.close = function () {
|
|
336
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'Blade.close\' called.', [this]);
|
|
337
333
|
this.listener1(); // Unregister listener1
|
|
338
334
|
if (this.portalService.bladeArea !== undefined) {
|
|
339
335
|
this.portalService.bladeArea.clearPath(this.path);
|
|
@@ -463,7 +459,6 @@ var angularportalazure;
|
|
|
463
459
|
function BladeArea(portalService) {
|
|
464
460
|
var _this = _super.call(this, portalService) || this;
|
|
465
461
|
_this.blades = new Array();
|
|
466
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea\' constructor called.', [_this, portalService]);
|
|
467
462
|
var that = _this;
|
|
468
463
|
// Set dependencies
|
|
469
464
|
_this.portalService = portalService;
|
|
@@ -476,7 +471,6 @@ var angularportalazure;
|
|
|
476
471
|
/** OBSOLETE: end */
|
|
477
472
|
// Register listener1
|
|
478
473
|
_this.listener1 = that.portalService.$rootScope.$on('BladeArea.AddBlade', function (event, args) {
|
|
479
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea\' BladeArea.AddBlade event processing.', [this, event, args]);
|
|
480
474
|
that.addBlade(args.path, args.pathSender);
|
|
481
475
|
});
|
|
482
476
|
return _this;
|
|
@@ -488,7 +482,6 @@ var angularportalazure;
|
|
|
488
482
|
this.portalService.$rootScope.$broadcast('BladeArea.AddBlade', args);
|
|
489
483
|
};
|
|
490
484
|
BladeArea.prototype.setFirstBlade = function (path) {
|
|
491
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.setFirstBlade\' called.', [this, path]);
|
|
492
485
|
this.clearAll();
|
|
493
486
|
this.hidePanorama();
|
|
494
487
|
return this.addBlade(path);
|
|
@@ -496,7 +489,6 @@ var angularportalazure;
|
|
|
496
489
|
/** obsolete */
|
|
497
490
|
BladeArea.prototype.addBlade = function (path, senderPath) {
|
|
498
491
|
if (senderPath === void 0) { senderPath = ''; }
|
|
499
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.addBlade\' called.', [this, senderPath, path]);
|
|
500
492
|
if (path == null) {
|
|
501
493
|
return;
|
|
502
494
|
}
|
|
@@ -554,30 +546,25 @@ var angularportalazure;
|
|
|
554
546
|
return blade;
|
|
555
547
|
};
|
|
556
548
|
BladeArea.prototype.clearAll = function () {
|
|
557
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearAll\' called.', [this]);
|
|
558
549
|
this.blades.length = 0;
|
|
559
550
|
this.showPanoramaIfNoBlades();
|
|
560
551
|
};
|
|
561
552
|
BladeArea.prototype.clearPath = function (path) {
|
|
562
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearPath\' called.', [this, path]);
|
|
563
553
|
var that = this;
|
|
564
554
|
// we do not distinguish between lower and upper case path name
|
|
565
555
|
path = path.toLowerCase();
|
|
566
556
|
var isremoved = that.blades.some(function (blade, index) {
|
|
567
557
|
if (blade.comparePaths(blade.path, path)) {
|
|
568
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearPath\' set bladeUrls.length to: ' + index);
|
|
569
558
|
that.blades.length = index;
|
|
570
559
|
return true;
|
|
571
560
|
}
|
|
572
561
|
});
|
|
573
562
|
if (!isremoved) {
|
|
574
|
-
angularportalazure.Debug.write('>>> bladeUrls:', [that.blades]);
|
|
575
563
|
throw new Error('[angularportalazure.BladeArea.clearPath] path: \'' + path + '\' could not be removed, since path not found in bladeUrls.');
|
|
576
564
|
}
|
|
577
565
|
this.showPanoramaIfNoBlades();
|
|
578
566
|
};
|
|
579
567
|
BladeArea.prototype.clearLevel = function (level) {
|
|
580
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearLevel\' called.', [this, level]);
|
|
581
568
|
if (this.blades.length < level) {
|
|
582
569
|
}
|
|
583
570
|
if (level == 0) {
|
|
@@ -587,28 +574,23 @@ var angularportalazure;
|
|
|
587
574
|
this.showPanoramaIfNoBlades();
|
|
588
575
|
};
|
|
589
576
|
BladeArea.prototype.clearLastLevel = function () {
|
|
590
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearLastLevel\' called.', [this]);
|
|
591
577
|
this.clearLevel(this.blades.length);
|
|
592
578
|
this.showPanoramaIfNoBlades();
|
|
593
579
|
};
|
|
594
580
|
BladeArea.prototype.clearChild = function (path) {
|
|
595
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearChild\' called.', [this, path]);
|
|
596
581
|
var that = this;
|
|
597
582
|
path = path.toLowerCase();
|
|
598
583
|
if (path === '') {
|
|
599
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearChild\' path is empty, nothing to clear.');
|
|
600
584
|
return;
|
|
601
585
|
}
|
|
602
586
|
var isremoved = that.blades.some(function (blade, index) {
|
|
603
587
|
// we do not distinguish between lower and upper case path name
|
|
604
588
|
if (blade.comparePaths(blade.path, path)) {
|
|
605
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.clearChild\' set bladeUrls.length to: ' + (index + 1));
|
|
606
589
|
that.blades.length = index + 1;
|
|
607
590
|
return true;
|
|
608
591
|
}
|
|
609
592
|
});
|
|
610
593
|
if (!isremoved) {
|
|
611
|
-
angularportalazure.Debug.write('>>> bladeUrls:', [that.blades]);
|
|
612
594
|
throw new Error('[angularportalazure.BladeArea.clearChild] path: \'' + path + '\' could not be removed, since path not found in bladeUrls.');
|
|
613
595
|
}
|
|
614
596
|
};
|
|
@@ -633,7 +615,6 @@ var angularportalazure;
|
|
|
633
615
|
//#endregion
|
|
634
616
|
//#region OBSOLETE
|
|
635
617
|
BladeArea.prototype.addBladePath = function (path) {
|
|
636
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.addBladePath\' called.', [this, path]);
|
|
637
618
|
// Fix issue with old code
|
|
638
619
|
if (this.portalService.$window === undefined) {
|
|
639
620
|
this.portalService.$window = this.portalService;
|
|
@@ -642,7 +623,6 @@ var angularportalazure;
|
|
|
642
623
|
//this.addBladeOld(path);
|
|
643
624
|
};
|
|
644
625
|
BladeArea.prototype.addBladeOld = function (path) {
|
|
645
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeArea.addBladeOld\' called.', [this, path]);
|
|
646
626
|
var that = this;
|
|
647
627
|
if (path === undefined || path == '') {
|
|
648
628
|
return;
|
|
@@ -681,9 +661,7 @@ var angularportalazure;
|
|
|
681
661
|
__extends(AvatarMenu, _super);
|
|
682
662
|
//#region Constructor
|
|
683
663
|
function AvatarMenu(portalService) {
|
|
684
|
-
|
|
685
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'AvatarMenu\' constructor called.', [_this]);
|
|
686
|
-
return _this;
|
|
664
|
+
return _super.call(this, portalService) || this;
|
|
687
665
|
}
|
|
688
666
|
return AvatarMenu;
|
|
689
667
|
}(angularportalazure.UserControlBase));
|
|
@@ -710,12 +688,10 @@ var angularportalazure;
|
|
|
710
688
|
this.tileSizes = tileSizes;
|
|
711
689
|
this.width = width;
|
|
712
690
|
this.height = height;
|
|
713
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'TileSize\' constructor called.', [this, tileSizes, width, height]);
|
|
714
691
|
}
|
|
715
692
|
//#endregion
|
|
716
693
|
//#region Methods
|
|
717
694
|
TileSize.getTileSizes = function () {
|
|
718
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'TileSize.getTileSizes\' called.', [this]);
|
|
719
695
|
var tileSizes = Array();
|
|
720
696
|
tileSizes.push(new TileSize(angularportalazure.TileSizes.small, 90, 90));
|
|
721
697
|
tileSizes.push(new TileSize(angularportalazure.TileSizes.mini, 180, 90));
|
|
@@ -736,7 +712,6 @@ var angularportalazure;
|
|
|
736
712
|
var Tile = (function () {
|
|
737
713
|
//#region Constructor
|
|
738
714
|
function Tile(title, bladePath, portalService) {
|
|
739
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'Tile\' constructor called.', [this, title, bladePath, portalService]);
|
|
740
715
|
this.portalService = portalService;
|
|
741
716
|
this.title = title;
|
|
742
717
|
this.bladePath = bladePath;
|
|
@@ -784,7 +759,6 @@ var angularportalazure;
|
|
|
784
759
|
//#endregion
|
|
785
760
|
//#region Methods
|
|
786
761
|
Tiles.prototype.addTile = function (tile) {
|
|
787
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'Tiles.addTile\' called.', [this, tile]);
|
|
788
762
|
var tileSize = this.tileSizes[tile.tileSize];
|
|
789
763
|
tile.size = angularportalazure.TileSizes[tile.tileSize]; // Get CSS Name
|
|
790
764
|
tile.top = this.nextTop + 'px';
|
|
@@ -817,7 +791,6 @@ var angularportalazure;
|
|
|
817
791
|
//#region Constructor
|
|
818
792
|
function Startboard(portalService) {
|
|
819
793
|
var _this = _super.call(this, portalService) || this;
|
|
820
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'Startboard\' constructor called.', [_this]);
|
|
821
794
|
_this.tiles = new angularportalazure.Tiles();
|
|
822
795
|
return _this;
|
|
823
796
|
}
|
|
@@ -839,7 +812,6 @@ var angularportalazure;
|
|
|
839
812
|
function Panorama(title, portalService) {
|
|
840
813
|
var _this = _super.call(this, portalService) || this;
|
|
841
814
|
_this.isVisible = true;
|
|
842
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'Panorama\' constructor called.', [_this, title]);
|
|
843
815
|
_this.title = title;
|
|
844
816
|
_this.portalService.panorama = _this;
|
|
845
817
|
_this.avatarMenu = new angularportalazure.AvatarMenu(_this.portalService);
|
|
@@ -865,7 +837,6 @@ var angularportalazure;
|
|
|
865
837
|
//#region Constructor
|
|
866
838
|
function PortalShell(title, portalService) {
|
|
867
839
|
var _this = _super.call(this, portalService) || this;
|
|
868
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'PortalShell\' constructor called.', [_this, title, portalService]);
|
|
869
840
|
_this.portalService = portalService;
|
|
870
841
|
_this.portalService.portalShell = _this;
|
|
871
842
|
_this.portalService.panorama = new angularportalazure.Panorama(title, _this.portalService);
|
|
@@ -876,11 +847,9 @@ var angularportalazure;
|
|
|
876
847
|
//#endregion
|
|
877
848
|
//#region Methods
|
|
878
849
|
PortalShell.prototype.initialize = function () {
|
|
879
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'PortalShell.initialize\' called.', [this]);
|
|
880
850
|
this.setObsoleteLayoutProperites();
|
|
881
851
|
};
|
|
882
852
|
PortalShell.prototype.setObsoleteLayoutProperites = function () {
|
|
883
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'PortalShell.setObsoleteLayoutProperites\' called.', [this]);
|
|
884
853
|
this.title = this.portalService.panorama.title;
|
|
885
854
|
this.tiles = this.portalService.panorama.startboard.tiles.tiles;
|
|
886
855
|
this.blades = this.portalService.bladeArea.blades;
|
|
@@ -916,7 +885,6 @@ var angularportalazure;
|
|
|
916
885
|
//#endregion
|
|
917
886
|
//#region Properties
|
|
918
887
|
this.parameter = { action: 'none', itemId: 0 };
|
|
919
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'PortalService\' constructor called.', [this, $injector]);
|
|
920
888
|
this.$injector = $injector;
|
|
921
889
|
//this.$scope = $scope;
|
|
922
890
|
this.$http = $injector.get('$http');
|
|
@@ -1160,7 +1128,6 @@ var angularportalazure;
|
|
|
1160
1128
|
var _this = _super.call(this, portalService, path, title, subtitle, width) || this;
|
|
1161
1129
|
//#region Properties
|
|
1162
1130
|
_this.item = null;
|
|
1163
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeDetail\' constructor called.', [_this, portalService, path, title, subtitle, width]);
|
|
1164
1131
|
_this.isCommandNew = true;
|
|
1165
1132
|
_this.commandNewText = 'neu';
|
|
1166
1133
|
_this.isCommandSave = true;
|
|
@@ -1237,41 +1204,12 @@ var angularportalazure;
|
|
|
1237
1204
|
//#endregion
|
|
1238
1205
|
//#region Properties
|
|
1239
1206
|
_this.items = [];
|
|
1207
|
+
_this.isCommandNew = true;
|
|
1208
|
+
_this.commandNewText = 'neu';
|
|
1240
1209
|
return _this;
|
|
1241
|
-
//this.isCommandNew = true;
|
|
1242
|
-
//this.commandNewText = 'neu';
|
|
1243
1210
|
}
|
|
1244
1211
|
//#endregion
|
|
1245
1212
|
//#region Methods
|
|
1246
|
-
//activate(): void {
|
|
1247
|
-
// let that = this;
|
|
1248
|
-
// //this.loadItems(() => this.getItemsFunction);
|
|
1249
|
-
// //var that = this;
|
|
1250
|
-
// //that.statusbar = 'Daten laden...';
|
|
1251
|
-
// //that.statusbarClass = '';
|
|
1252
|
-
// this.onActivate();
|
|
1253
|
-
// ////var onActivate = that.onActivate();
|
|
1254
|
-
// ////if (that.onActivate === null || that.onActivate === undefined) {
|
|
1255
|
-
// ////} else {
|
|
1256
|
-
// // //that.loadItems(onActivate);
|
|
1257
|
-
// // console.log('call onActivate()');
|
|
1258
|
-
// // that.onActivate()
|
|
1259
|
-
// // .then(function (data: any) {
|
|
1260
|
-
// // console.log('OK');
|
|
1261
|
-
// // that.items = data;
|
|
1262
|
-
// // that.statusbar = '';
|
|
1263
|
-
// // that.statusbarClass = '';
|
|
1264
|
-
// // }).catch(function (exception: angularportalazure.Exception) {
|
|
1265
|
-
// // console.log('exception');
|
|
1266
|
-
// // console.log(exception);
|
|
1267
|
-
// // that.statusbar = 'FEHLER: ' + exception.Message;
|
|
1268
|
-
// // that.statusbarClass = 'message-info message-off';
|
|
1269
|
-
// // });
|
|
1270
|
-
// ////}
|
|
1271
|
-
//}
|
|
1272
|
-
//onActivate(): angular.IHttpPromise<any> { // any should be: angular.IHttpPromise<any>
|
|
1273
|
-
// throw new Error('[angularportalazure.BladeGrid] \'onActivate\' is an abstract function. Define one in the derived class.');
|
|
1274
|
-
//}
|
|
1275
1213
|
BladeGrid.prototype.loadItems = function (func) {
|
|
1276
1214
|
var that = this;
|
|
1277
1215
|
that.statusbar = 'Daten laden...';
|
|
@@ -1284,8 +1222,8 @@ var angularportalazure;
|
|
|
1284
1222
|
that.showExceptionOnStatusbar(exception);
|
|
1285
1223
|
});
|
|
1286
1224
|
};
|
|
1287
|
-
|
|
1288
|
-
};
|
|
1225
|
+
/* Override this function. This function is called from the loadItems function, when the promise is done. */
|
|
1226
|
+
BladeGrid.prototype.onLoadedItems = function () { };
|
|
1289
1227
|
//#region Filter
|
|
1290
1228
|
BladeGrid.prototype.onFilter = function (actual, expected) {
|
|
1291
1229
|
//#region Documentation
|
|
@@ -1369,16 +1307,6 @@ var angularportalazure;
|
|
|
1369
1307
|
;
|
|
1370
1308
|
//#endregion
|
|
1371
1309
|
};
|
|
1372
|
-
//#endregion
|
|
1373
|
-
//#region OBSOLETE
|
|
1374
|
-
/** Obsolete */
|
|
1375
|
-
BladeGrid.prototype.setObsoleteLayoutProperites = function () {
|
|
1376
|
-
if (this.items.length !== 0) {
|
|
1377
|
-
this.navGrid.items = this.items; //--> needed, otherwise nav html pages will no longer work.
|
|
1378
|
-
}
|
|
1379
|
-
this.isNavGrid = this.isNavGrid;
|
|
1380
|
-
//super.setObsoleteLayoutProperites();
|
|
1381
|
-
};
|
|
1382
1310
|
return BladeGrid;
|
|
1383
1311
|
}(angularportalazure.BladeData));
|
|
1384
1312
|
angularportalazure.BladeGrid = BladeGrid;
|
|
@@ -1406,12 +1334,10 @@ var angularportalazure;
|
|
|
1406
1334
|
this.isVisible = isVisible;
|
|
1407
1335
|
this.callback = callback;
|
|
1408
1336
|
this.bladeNav = bladeNav;
|
|
1409
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeNavItem\' constructor called.', [this, title, bladePath, hrefPath, roles, isVisible]);
|
|
1410
1337
|
}
|
|
1411
1338
|
//#endregion
|
|
1412
1339
|
//#region
|
|
1413
1340
|
BladeNavItem.prototype.onNavItemClick = function () {
|
|
1414
|
-
angularportalazure.Debug.write('[angularportalazure-debug] \'BladeNavItem.onNavItemClick\' called.', [this]);
|
|
1415
1341
|
if (this.callback != null) {
|
|
1416
1342
|
this.callback();
|
|
1417
1343
|
}
|
package/css/apn.css
CHANGED
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@ardimedia/angular-portal-azure",
|
|
3
3
|
"description": "Angular Portal Azure - GUI Framework.",
|
|
4
4
|
"author": "Ardimedia Anstalt <info@ardimedia.com> (http://www.ardimedia.com)",
|
|
5
|
-
"version": "0.2.
|
|
5
|
+
"version": "0.2.103",
|
|
6
6
|
"main": "index.js",
|
|
7
7
|
"typings": "apn.d.ts",
|
|
8
8
|
"dependencies": {
|