@ardimedia/angular-portal-azure 0.2.200 → 0.2.202

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.
Files changed (3) hide show
  1. package/apn.d.ts +1 -1
  2. package/apn.js +17 -25
  3. package/package.json +1 -1
package/apn.d.ts CHANGED
@@ -420,10 +420,10 @@ declare namespace angularportalazure {
420
420
  StatusText: string | undefined;
421
421
  Url: string;
422
422
  static prepareException(response: angular.IHttpPromiseCallbackArg<angularportalazure.Exception> | any): angularportalazure.Exception;
423
+ static getOneLineMessage(exception: angularportalazure.Exception): string;
423
424
  private static processDotNetException1(response);
424
425
  private static processDotNetException2(response);
425
426
  private static setExceptionType(response, exception);
426
- getMessageAndExceptionMessage(): string;
427
427
  }
428
428
  }
429
429
  declare namespace angularportalazure {
package/apn.js CHANGED
@@ -331,21 +331,8 @@ var angularportalazure;
331
331
  this.statusBarClass = 'apa-statusbar-info';
332
332
  };
333
333
  Blade.prototype.setStatusBarException = function (exception) {
334
- var _this = this;
335
- if (exception.Message === undefined) {
336
- this.statusBar = 'FEHLER: ' + exception;
337
- this.statusBarClass = 'apa-statusbar-error';
338
- }
339
- else {
340
- this.statusBar = 'FEHLER: ' + exception.Message;
341
- this.statusBarClass = 'apa-statusbar-error';
342
- }
343
- if (exception.Messages !== undefined) {
344
- exception.Messages.forEach(function (item) {
345
- _this.statusBar += ' - ' + item;
346
- _this.statusBarClass = 'apa-statusbar-error';
347
- });
348
- }
334
+ this.statusBar = angularportalazure.Exception.getOneLineMessage(exception);
335
+ this.statusBarClass = 'apa-statusbar-error';
349
336
  };
350
337
  //#endregion
351
338
  //#endregion
@@ -1418,6 +1405,21 @@ var angularportalazure;
1418
1405
  console.log(exception);
1419
1406
  return exception;
1420
1407
  };
1408
+ Exception.getOneLineMessage = function (exception) {
1409
+ var message = 'FEHLER ';
1410
+ if (exception.Message !== undefined) {
1411
+ message += ': ' + exception.Message + ' ';
1412
+ }
1413
+ if (exception.ExceptionMessage !== undefined) {
1414
+ message += ': ' + exception.ExceptionMessage + ' ';
1415
+ }
1416
+ if (exception.Messages !== undefined) {
1417
+ exception.Messages.forEach(function (item) {
1418
+ message += '- ' + item + ' ';
1419
+ });
1420
+ }
1421
+ return message;
1422
+ };
1421
1423
  Exception.processDotNetException1 = function (response) {
1422
1424
  var exception = new angularportalazure.Exception();
1423
1425
  //#region Convert data to Messages
@@ -1468,16 +1470,6 @@ var angularportalazure;
1468
1470
  }
1469
1471
  exception.ExceptionType = response.data.ExceptionType;
1470
1472
  };
1471
- //#endregion
1472
- //#region Public Methods
1473
- Exception.prototype.getMessageAndExceptionMessage = function () {
1474
- if (this.ExceptionMessage === undefined) {
1475
- return this.Message;
1476
- }
1477
- else {
1478
- return this.Message + " " + this.ExceptionMessage;
1479
- }
1480
- };
1481
1473
  return Exception;
1482
1474
  }(angularportalazure.ValidationsExceptionDotNet));
1483
1475
  angularportalazure.Exception = Exception;
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.200",
5
+ "version": "0.2.202",
6
6
  "main": "index.js",
7
7
  "typings": "apn.d.ts",
8
8
  "dependencies": {