@netgrif/components-core 6.0.1 → 6.0.2-rc.4

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 (68) hide show
  1. package/bundles/netgrif-components-core.umd.js +152 -44
  2. package/bundles/netgrif-components-core.umd.js.map +1 -1
  3. package/bundles/netgrif-components-core.umd.min.js +1 -1
  4. package/bundles/netgrif-components-core.umd.min.js.map +1 -1
  5. package/esm2015/assets/i18n/de.json +3 -0
  6. package/esm2015/assets/i18n/en.json +3 -0
  7. package/esm2015/assets/i18n/sk.json +20 -17
  8. package/esm2015/lib/authorization/permission/permission.service.js +1 -5
  9. package/esm2015/lib/data-fields/enumeration-field/enumeration-list-field/abstract-enumeration-list-field.component.js +4 -1
  10. package/esm2015/lib/data-fields/enumeration-field/models/enumeration-field.js +2 -2
  11. package/esm2015/lib/data-fields/file-field/abstract-file-field.component.js +10 -3
  12. package/esm2015/lib/data-fields/file-list-field/abstract-file-list-field.component.js +5 -3
  13. package/esm2015/lib/data-fields/models/abstract-data-field.js +10 -1
  14. package/esm2015/lib/forms/email-submission/abstract-email-submission-form.component.js +5 -2
  15. package/esm2015/lib/forms/models/abstract-registration.component.js +6 -1
  16. package/esm2015/lib/header/case-header/case-header.service.js +2 -2
  17. package/esm2015/lib/navigation/navigation-drawer/abstract-navigation-drawer.component.js +6 -6
  18. package/esm2015/lib/resources/engine-endpoint/task-resource.service.js +2 -1
  19. package/esm2015/lib/resources/interface/data-groups.js +1 -1
  20. package/esm2015/lib/search/models/category/no-configuration-user-autocomplete-category.js +2 -2
  21. package/esm2015/lib/side-menu/services/side-menu.service.js +17 -1
  22. package/esm2015/lib/task/services/assign-policy.service.js +1 -1
  23. package/esm2015/lib/task/services/finish-policy.service.js +1 -2
  24. package/esm2015/lib/task/services/task-data.service.js +10 -4
  25. package/esm2015/lib/task-content/model/task-fields.js +2 -0
  26. package/esm2015/lib/task-content/public-api.js +2 -1
  27. package/esm2015/lib/task-content/services/task-content.service.js +51 -5
  28. package/esm5/assets/i18n/de.json +3 -0
  29. package/esm5/assets/i18n/en.json +3 -0
  30. package/esm5/assets/i18n/sk.json +20 -17
  31. package/esm5/lib/authorization/permission/permission.service.js +1 -7
  32. package/esm5/lib/data-fields/enumeration-field/enumeration-list-field/abstract-enumeration-list-field.component.js +4 -1
  33. package/esm5/lib/data-fields/enumeration-field/models/enumeration-field.js +2 -2
  34. package/esm5/lib/data-fields/file-field/abstract-file-field.component.js +10 -3
  35. package/esm5/lib/data-fields/file-list-field/abstract-file-list-field.component.js +5 -3
  36. package/esm5/lib/data-fields/models/abstract-data-field.js +11 -1
  37. package/esm5/lib/forms/email-submission/abstract-email-submission-form.component.js +5 -2
  38. package/esm5/lib/forms/models/abstract-registration.component.js +6 -1
  39. package/esm5/lib/header/case-header/case-header.service.js +2 -2
  40. package/esm5/lib/navigation/navigation-drawer/abstract-navigation-drawer.component.js +6 -6
  41. package/esm5/lib/resources/engine-endpoint/task-resource.service.js +2 -1
  42. package/esm5/lib/resources/interface/data-groups.js +1 -1
  43. package/esm5/lib/search/models/category/no-configuration-user-autocomplete-category.js +2 -2
  44. package/esm5/lib/side-menu/services/side-menu.service.js +17 -1
  45. package/esm5/lib/task/services/assign-policy.service.js +1 -1
  46. package/esm5/lib/task/services/finish-policy.service.js +1 -2
  47. package/esm5/lib/task/services/task-data.service.js +10 -4
  48. package/esm5/lib/task-content/model/task-fields.js +2 -0
  49. package/esm5/lib/task-content/public-api.js +2 -1
  50. package/esm5/lib/task-content/services/task-content.service.js +59 -5
  51. package/fesm2015/netgrif-components-core.js +143 -42
  52. package/fesm2015/netgrif-components-core.js.map +1 -1
  53. package/fesm5/netgrif-components-core.js +152 -44
  54. package/fesm5/netgrif-components-core.js.map +1 -1
  55. package/lib/data-fields/enumeration-field/enumeration-list-field/abstract-enumeration-list-field.component.d.ts +1 -0
  56. package/lib/data-fields/models/abstract-data-field.d.ts +4 -0
  57. package/lib/forms/email-submission/abstract-email-submission-form.component.d.ts +2 -0
  58. package/lib/forms/models/abstract-registration.component.d.ts +1 -0
  59. package/lib/resources/interface/data-groups.d.ts +4 -0
  60. package/lib/side-menu/services/side-menu.service.d.ts +8 -0
  61. package/lib/task-content/model/task-fields.d.ts +7 -0
  62. package/lib/task-content/public-api.d.ts +1 -0
  63. package/lib/task-content/services/task-content.service.d.ts +7 -6
  64. package/netgrif-components-core.metadata.json +1 -1
  65. package/package.json +1 -1
  66. package/src/assets/i18n/de.json +3 -0
  67. package/src/assets/i18n/en.json +3 -0
  68. package/src/assets/i18n/sk.json +20 -17
@@ -1062,6 +1062,9 @@
1062
1062
  },
1063
1063
  dynamicEnum: {
1064
1064
  noData: "No items match your search"
1065
+ },
1066
+ "enum": {
1067
+ reset: "Reset"
1065
1068
  }
1066
1069
  };
1067
1070
  var dialog = {
@@ -1335,7 +1338,7 @@
1335
1338
  caseGetFailed: "Načítanie prípadov zlyhalo",
1336
1339
  noLongerExists: "Zvolená úloha už neexistuje",
1337
1340
  caseDeleteFailed: "Prípad sa nepodarilo vymazať",
1338
- caseDeleteSuccess: "Prípad úspešný zmazaný",
1341
+ caseDeleteSuccess: "Prípad bol úspešne zmazaný",
1339
1342
  rolesSuccessAssign: "Roly boli úspešne priradené vybraným používateľom"
1340
1343
  },
1341
1344
  view: {
@@ -1453,7 +1456,7 @@
1453
1456
  validations: {
1454
1457
  required: "Toto pole je potrebné!",
1455
1458
  requiredTrue: "Zadaná hodnota musí byť true",
1456
- odd: "Zadané čislo musí byť nepárne",
1459
+ odd: "Zadané číslo musí byť nepárne",
1457
1460
  even: "Zadané číslo musí byť párne",
1458
1461
  positive: "Zadané číslo musí byť kladné",
1459
1462
  negative: "Zadané číslo musí byť záporné",
@@ -1464,22 +1467,22 @@
1464
1467
  pattern: "Zadaný text je v nesprávnom formáte",
1465
1468
  phone: "Zadaný text musí byť tel. číslo",
1466
1469
  email: "Zadaný text musí byť email",
1467
- dateRange: "Zadaný dátum musí byť z rozsahu {{left}} a {{right}}",
1470
+ dateRange: "Zadaný dátum musí byť v rozsahu {{left}} a {{right}}",
1468
1471
  weekend: "Zadaný dátum musí byť víkendový deň",
1469
1472
  workday: "Zadaný dátum musí byť pracovný deň",
1470
1473
  enumeration: "Musí byť vybraná jedna z možností",
1471
1474
  min: "Zadané číslo musí byť väčšie ako {{length}}"
1472
1475
  },
1473
1476
  snackBar: {
1474
- downloadFail: " stahovanie zlyhalo",
1475
- moreFiles: "Zvolil si viac súborov ako je povolené",
1476
- sameFiles: "Nemôžeš nahrať dva rovnaké súbory",
1477
+ downloadFail: " sťahovanie zlyhalo",
1478
+ moreFiles: "Zvolili ste si viac súborov ako je povolené",
1479
+ sameFiles: "Nemôžete nahrať dva rovnaké súbory",
1477
1480
  fileSize: "Veľkosť súboru presiahla povolený limit",
1478
- wontUploadSameFile: "Súbor už existuje. Ak chcete súbor aktualizovať zvoľte iný názov súboru alebo súbor odstránte",
1479
- wontUploadSameFiles: "Vybrané súbory už boli nahrané. Ak chcete súbory aktualizovať odstránte už nahrané súbory",
1481
+ wontUploadSameFile: "Súbor už existuje. Ak chcete súbor aktualizovať, zvoľte iný názov súboru alebo súbor odstráňte",
1482
+ wontUploadSameFiles: "Vybrané súbory už boli nahrané. Ak chcete súbory aktualizovať, odstráňte už nahrané súbory",
1480
1483
  fileUploadFailed: "Súbor sa nepodarilo nahrať",
1481
1484
  fileDeleteFailed: "Súbor sa nepodarilo vymazať",
1482
- maxFilesExceeded: "Je presiahnutý maximálny počet nahrateľných súborov: ",
1485
+ maxFilesExceeded: "Je presiahnutý maximálny počet nahratých súborov: ",
1483
1486
  maxFilesSizeExceeded: "Je presiahnutá maximálna veľkosť nahrávaných súborov: ",
1484
1487
  notSelectedUser: "Nebol vybraný žiadny používateľ",
1485
1488
  userAssigned: "Používateľ {{userName}} bol pridelený"
@@ -1499,6 +1502,9 @@
1499
1502
  },
1500
1503
  dynamicEnum: {
1501
1504
  noData: "Vášmu vyhľadávaniu nezodpovedajú žiadne položky"
1505
+ },
1506
+ "enum": {
1507
+ reset: "Resetovať"
1502
1508
  }
1503
1509
  };
1504
1510
  var dialog$1 = {
@@ -1598,7 +1604,7 @@
1598
1604
  };
1599
1605
  var admin$1 = {
1600
1606
  "user-list": {
1601
- noUsersWereFound: "Momentálne nie sú v systéme žiadny používatelia",
1607
+ noUsersWereFound: "Momentálne nie sú v systéme žiadni používatelia",
1602
1608
  listTitle: "Používatelia"
1603
1609
  },
1604
1610
  "process-list": {
@@ -1612,14 +1618,14 @@
1612
1618
  newUser: "Nový používateľ",
1613
1619
  orgs: "Organizácie",
1614
1620
  selectedOrgs: "Vybrané Organizácie",
1615
- selectedRoless: "Vybrané Role",
1621
+ selectedRoless: "Vybrané Roly",
1616
1622
  mail: "Zadajte Email",
1617
- noSelectedOrgs: "Nie su zvolené žiadne organizácie!",
1618
- noSelectedRoles: "Nie su zvolené žiadne role!",
1623
+ noSelectedOrgs: "Nie zvolené žiadne organizácie!",
1624
+ noSelectedRoles: "Nie zvolené žiadne role!",
1619
1625
  noOrgs: "Nie sú žiadne dostupné organizácie!",
1620
1626
  version: "Verzia",
1621
1627
  emailFieldMandatory: "Email je povinný",
1622
- oneOrMoreOrganization: "Nový používateľ musí patriť aspoň do jenej organizácie",
1628
+ oneOrMoreOrganization: "Nový používateľ musí patriť aspoň do jednej organizácie",
1623
1629
  inviteSent: "Pozvánka bola odoslaná",
1624
1630
  inviteFailed: "Poslanie pozvánky zlyhalo",
1625
1631
  "invite-user": "POZVAŤ POUŽÍVATEĽA"
@@ -1633,7 +1639,7 @@
1633
1639
  };
1634
1640
  var caseTree$1 = {
1635
1641
  newNodeDefaultName: "Nový Vrchol",
1636
- noTaskSelected: "Momentálne nie je zvolený žiaden prípad. Pre vybranie prípadu zvoľte vrchol v strome."
1642
+ noTaskSelected: "Momentálne nie je zvolený žiadny prípad. Pre vybranie prípadu zvoľte vrchol v strome."
1637
1643
  };
1638
1644
  var dashboard$1 = {
1639
1645
  cases: "prípady"
@@ -1703,13 +1709,13 @@
1703
1709
  errSecond: "Názov je povinné pole.",
1704
1710
  errThird: "Farba je povinné pole.",
1705
1711
  noNets: "Žiadne povolené siete",
1706
- createCase: "Uspešne vytvorený nový prípad",
1712
+ createCase: "Úspešne vytvorený nový prípad",
1707
1713
  defaultCaseName: "s prednastaveným názvom prípadu"
1708
1714
  },
1709
1715
  user: {
1710
1716
  assign: "Priradiť používateľa",
1711
1717
  choose: "Zvoľte používateľa",
1712
- noUser: "Neexistujú žiadny používatelia",
1718
+ noUser: "Neexistujú žiadni používatelia",
1713
1719
  err: "Nepodarilo sa načítať používateľov",
1714
1720
  showcase: "Nebol zvolený mód zobrazenia používateľa!"
1715
1721
  },
@@ -1936,6 +1942,9 @@
1936
1942
  },
1937
1943
  dynamicEnum: {
1938
1944
  noData: "Keine Einträge entsprechen Ihrer Suchanfrage"
1945
+ },
1946
+ "enum": {
1947
+ reset: "Rücksetzen"
1939
1948
  }
1940
1949
  };
1941
1950
  var dialog$2 = {
@@ -3847,6 +3856,7 @@
3847
3856
  this._block = new rxjs.Subject();
3848
3857
  this._touch = new rxjs.Subject();
3849
3858
  this._validRequired = true;
3859
+ this.layoutSubject = new rxjs.BehaviorSubject(_layout);
3850
3860
  this.resetLocalLayout();
3851
3861
  }
3852
3862
  Object.defineProperty(DataField.prototype, "stringId", {
@@ -3946,6 +3956,7 @@
3946
3956
  },
3947
3957
  set: function (layout) {
3948
3958
  this._layout = layout;
3959
+ this.layoutSubject.next(layout);
3949
3960
  },
3950
3961
  enumerable: false,
3951
3962
  configurable: true
@@ -4083,6 +4094,7 @@
4083
4094
  this._touch.complete();
4084
4095
  this._block.complete();
4085
4096
  this._initialized$.complete();
4097
+ this.layoutSubject.complete();
4086
4098
  };
4087
4099
  DataField.prototype.registerFormControl = function (formControl) {
4088
4100
  var _this = this;
@@ -4244,6 +4256,7 @@
4244
4256
  });
4245
4257
  };
4246
4258
  DataField.prototype.resolveAppearance = function (config) {
4259
+ var _this = this;
4247
4260
  var appearance = 'outline';
4248
4261
  if (this.layout && this.layout.appearance) {
4249
4262
  appearance = this.layout.appearance;
@@ -4255,6 +4268,12 @@
4255
4268
  }
4256
4269
  }
4257
4270
  this.materialAppearance = appearance;
4271
+ /* Listen for changes of layout in future */
4272
+ this.layoutSubject.subscribe(function (layout) {
4273
+ if (_this.layout && _this.layout.appearance) {
4274
+ _this.materialAppearance = _this.layout.appearance;
4275
+ }
4276
+ });
4258
4277
  };
4259
4278
  DataField.prototype.resolvePrevValue = function (value) {
4260
4279
  if (this._value.getValue() !== undefined
@@ -5085,6 +5104,9 @@
5085
5104
  }
5086
5105
  AbstractEnumerationListFieldComponent.prototype.ngOnInit = function () {
5087
5106
  };
5107
+ AbstractEnumerationListFieldComponent.prototype.resetEnum = function () {
5108
+ this.formControlRef.reset();
5109
+ };
5088
5110
  AbstractEnumerationListFieldComponent.propDecorators = {
5089
5111
  enumerationField: [{ type: core.Input }],
5090
5112
  formControlRef: [{ type: core.Input }],
@@ -5182,7 +5204,7 @@
5182
5204
  if (this._choices === undefined || this._choices.length === 0 || control.value === '' || control.value === undefined) {
5183
5205
  return null;
5184
5206
  }
5185
- return this._choices.find(function (choice) { return choice.key === control.value; }) ? null : { wrongValue: true };
5207
+ return this._choices.find(function (choice) { return choice.key === control.value || control.value === null; }) ? null : { wrongValue: true };
5186
5208
  };
5187
5209
  EnumerationField.prototype.getType = function () {
5188
5210
  return !!this.component && !!this.component.name ? this.component.name : this.view;
@@ -6545,6 +6567,7 @@
6545
6567
  };
6546
6568
  if (dataGroupResource.parentTaskId !== undefined) {
6547
6569
  dataGroupObject.parentTaskId = dataGroupResource.parentTaskId;
6570
+ dataGroupObject.parentTransitionId = dataGroupResource.parentTransitionId;
6548
6571
  dataGroupObject.parentTaskRefId = dataGroupResource.parentTaskRefId;
6549
6572
  dataGroupObject.nestingLevel = dataGroupResource.nestingLevel;
6550
6573
  }
@@ -6969,8 +6992,15 @@
6969
6992
  * Construct display name.
6970
6993
  */
6971
6994
  AbstractFileFieldComponent.prototype.constructDisplayName = function () {
6972
- var _a, _b, _c, _d, _e;
6973
- return (_c = (_b = (_a = this.dataField) === null || _a === void 0 ? void 0 : _a.value) === null || _b === void 0 ? void 0 : _b.name) !== null && _c !== void 0 ? _c : ((_e = (_d = this.dataField) === null || _d === void 0 ? void 0 : _d.placeholder) !== null && _e !== void 0 ? _e : this._translate.instant('dataField.file.noFile'));
6995
+ if (!!this.dataField) {
6996
+ if (!!this.dataField.value && !!this.dataField.value.name) {
6997
+ return this.dataField.value.name;
6998
+ }
6999
+ else if (!!this.dataField.placeholder) {
7000
+ return this.dataField.placeholder;
7001
+ }
7002
+ }
7003
+ return this._translate.instant('dataField.file.noFile');
6974
7004
  };
6975
7005
  /**
6976
7006
  * Initialize file field image from backend if it is image type.
@@ -7335,8 +7365,10 @@
7335
7365
  * Construct display name.
7336
7366
  */
7337
7367
  AbstractFileListFieldComponent.prototype.constructDisplayName = function () {
7338
- var _a, _b;
7339
- return (_b = (_a = this.dataField) === null || _a === void 0 ? void 0 : _a.placeholder) !== null && _b !== void 0 ? _b : this._translate.instant('dataField.file.noFile');
7368
+ if (!!this.dataField && !!this.dataField.placeholder) {
7369
+ return this.dataField.placeholder;
7370
+ }
7371
+ return this._translate.instant('dataField.file.noFile');
7340
7372
  };
7341
7373
  AbstractFileListFieldComponent.prototype.parseResponse = function () {
7342
7374
  var _this = this;
@@ -7853,6 +7885,9 @@
7853
7885
  SideMenuService.prototype.open = function (componentOrTemplateRef, width, injectionData) {
7854
7886
  var _this = this;
7855
7887
  if (width === void 0) { width = exports.SideMenuSize.MEDIUM; }
7888
+ if (!this.componentIsPresent()) {
7889
+ throw new Error('Side menu is not initialized');
7890
+ }
7856
7891
  if (this._sideMenuComponent.isOpened()) {
7857
7892
  throw new Error('Side menu has been already opened with another content');
7858
7893
  }
@@ -7888,6 +7923,19 @@
7888
7923
  SideMenuService.prototype.close = function (closeEvent) {
7889
7924
  return this._controlObject.close(closeEvent);
7890
7925
  };
7926
+ /**
7927
+ * Toggle this _sideMenu. This is equivalent to calling close() when it's already opened, or open() when it's closed.
7928
+ *
7929
+ * @param isOpen Whether the _sideMenu should be open.
7930
+ *
7931
+ * @returns open or close side menu
7932
+ */
7933
+ // public toggle(isOpen?: boolean): Observable<MatDrawerToggleResult> {
7934
+ // return from(this._sideMenu.toggle(isOpen));
7935
+ // }
7936
+ SideMenuService.prototype.componentIsPresent = function () {
7937
+ return !!this._sideMenuComponent;
7938
+ };
7891
7939
  SideMenuService.ctorParameters = function () { return [
7892
7940
  { type: Boolean, decorators: [{ type: core.Optional }, { type: core.Inject, args: [NAE_NET_VERSION_VISIBLE,] }] },
7893
7941
  { type: Boolean, decorators: [{ type: core.Optional }, { type: core.Inject, args: [NAE_NET_ALL_VERSIONS,] }] }
@@ -11072,7 +11120,7 @@
11072
11120
  if (this.selectedOperator.numberOfOperands !== 1) {
11073
11121
  throw new Error("Only unary operators are currently supported by the " + this._className + " implementation");
11074
11122
  }
11075
- return this.selectedOperator.createQuery(this.elasticKeywords, userInput[0], false);
11123
+ return this.selectedOperator.createQuery(this.elasticKeywords, Array.isArray(userInput[0]) ? userInput[0] : userInput, false);
11076
11124
  };
11077
11125
  NoConfigurationUserAutocompleteCategory.prototype.serializeOperandValue = function (valueFormControl) {
11078
11126
  return this._userAutocomplete.serializeOperandValue(valueFormControl);
@@ -16151,6 +16199,7 @@
16151
16199
  var AbstractEmailSubmissionFormComponent = /** @class */ (function () {
16152
16200
  function AbstractEmailSubmissionFormComponent(formBuilder) {
16153
16201
  this.displayLegalNotice = true;
16202
+ this.loading = new LoadingEmitter();
16154
16203
  this.rootFormGroup = formBuilder.group({
16155
16204
  email: ['', forms$3.Validators.email]
16156
16205
  });
@@ -16160,6 +16209,7 @@
16160
16209
  AbstractEmailSubmissionFormComponent.prototype.ngOnDestroy = function () {
16161
16210
  this.formSubmit.complete();
16162
16211
  this.goBackButton.complete();
16212
+ this.loading.complete();
16163
16213
  };
16164
16214
  AbstractEmailSubmissionFormComponent.prototype.emitGoBack = function () {
16165
16215
  this.goBackButton.emit();
@@ -16168,7 +16218,7 @@
16168
16218
  if (!this.rootFormGroup.valid) {
16169
16219
  return;
16170
16220
  }
16171
- this.formSubmit.emit({ email: this.rootFormGroup.controls['email'].value });
16221
+ this.formSubmit.emit({ email: this.rootFormGroup.controls['email'].value, loading: this.loading });
16172
16222
  };
16173
16223
  AbstractEmailSubmissionFormComponent.propDecorators = {
16174
16224
  displayLegalNotice: [{ type: core.Input }],
@@ -16272,12 +16322,14 @@
16272
16322
  this.invalidToken = new core.EventEmitter();
16273
16323
  this._tokenVerified = false;
16274
16324
  this.loadingToken = new LoadingEmitter(true);
16325
+ this.loadingSubmit = new LoadingEmitter(false);
16275
16326
  }
16276
16327
  AbstractRegistrationComponent.prototype.ngOnDestroy = function () {
16277
16328
  this.formSubmit.complete();
16278
16329
  this.register.complete();
16279
16330
  this.invalidToken.complete();
16280
16331
  this.loadingToken.complete();
16332
+ this.loadingSubmit.complete();
16281
16333
  };
16282
16334
  Object.defineProperty(AbstractRegistrationComponent.prototype, "token", {
16283
16335
  get: function () {
@@ -16327,10 +16379,13 @@
16327
16379
  return;
16328
16380
  }
16329
16381
  request.token = this._token;
16382
+ this.loadingSubmit.on();
16330
16383
  this.callRegistration(request).pipe(operators.take(1)).subscribe(function (message) {
16331
16384
  _this.register.emit(message);
16385
+ _this.loadingSubmit.off();
16332
16386
  }, function (error) {
16333
16387
  _this.register.emit({ error: error });
16388
+ _this.loadingSubmit.off();
16334
16389
  });
16335
16390
  };
16336
16391
  AbstractRegistrationComponent.prototype.isFieldValid = function (formControlName) {
@@ -18639,12 +18694,6 @@
18639
18694
  })) {
18640
18695
  return false;
18641
18696
  }
18642
- if (!Object.keys(net.permissions).filter(function (role) { return Object.keys(net.permissions[role])
18643
- .some(function (perm) { return perm === action; }); }).some(function (role) {
18644
- return !!net.permissions[role][action];
18645
- })) {
18646
- return true;
18647
- }
18648
18697
  return Object.keys(net.permissions).some(function (role) {
18649
18698
  return _this._userService.hasRoleById(role) ? !!net.permissions[role][action] : false;
18650
18699
  });
@@ -19830,7 +19879,7 @@
19830
19879
  new HeaderColumn(exports.HeaderColumnType.META, exports.CaseMetaField.VISUAL_ID, 'headers.caseMeta.visualID', 'text'),
19831
19880
  new HeaderColumn(exports.HeaderColumnType.META, exports.CaseMetaField.MONGO_ID, 'headers.caseMeta.mongoID', 'text', false),
19832
19881
  new HeaderColumn(exports.HeaderColumnType.META, exports.CaseMetaField.TITLE, 'headers.caseMeta.title', 'text'),
19833
- new HeaderColumn(exports.HeaderColumnType.META, exports.CaseMetaField.AUTHOR, 'headers.caseMeta.author', 'text'),
19882
+ new HeaderColumn(exports.HeaderColumnType.META, exports.CaseMetaField.AUTHOR, 'headers.caseMeta.author', 'user'),
19834
19883
  new HeaderColumn(exports.HeaderColumnType.META, exports.CaseMetaField.CREATION_DATE, 'headers.caseMeta.creationDate', 'date'),
19835
19884
  ];
19836
19885
  };
@@ -21724,7 +21773,7 @@
21724
21773
  this.userPreferenceService = userPreferenceService;
21725
21774
  this._config = {
21726
21775
  mode: 'over',
21727
- opened: false,
21776
+ opened: true,
21728
21777
  disableClose: false
21729
21778
  };
21730
21779
  this.openedChange = new core.EventEmitter();
@@ -21785,14 +21834,14 @@
21785
21834
  configurable: true
21786
21835
  });
21787
21836
  AbstractNavigationDrawerComponent.prototype.open = function () {
21788
- if (this._fixed) {
21789
- return Promise.resolve('open');
21837
+ if (!this._sideNav.opened) {
21838
+ this._sideNav.open();
21790
21839
  }
21791
- return this._sideNav.open();
21840
+ return Promise.resolve('open');
21792
21841
  };
21793
21842
  AbstractNavigationDrawerComponent.prototype.close = function () {
21794
21843
  if (this._fixed) {
21795
- return Promise.resolve('open');
21844
+ return Promise.resolve('close');
21796
21845
  }
21797
21846
  return this._sideNav.close();
21798
21847
  };
@@ -23637,8 +23686,15 @@
23637
23686
  // todo actions owner zbytočný?
23638
23687
  var frontendActions = chFields.taskId === this.task.stringId && chFields[TaskContentService.FRONTEND_ACTIONS_KEY];
23639
23688
  Object.keys(chFields).forEach(function (changedField) {
23640
- if (!!_this.taskFieldsIndex[chFields.taskId] && !!_this.taskFieldsIndex[chFields.taskId][changedField]) {
23641
- _this.updateField(chFields, _this.taskFieldsIndex[chFields.taskId][changedField], frontendActions);
23689
+ if (!!_this.taskFieldsIndex[chFields.taskId] && !!_this.taskFieldsIndex[chFields.taskId].fields
23690
+ && !!_this.taskFieldsIndex[chFields.taskId].fields[changedField]) {
23691
+ _this.updateField(chFields, _this.taskFieldsIndex[chFields.taskId].fields[changedField], frontendActions);
23692
+ }
23693
+ else if (_this.isFieldInTaskRef(changedField)) {
23694
+ var taskId = _this.getReferencedTaskId(changedField);
23695
+ if (!!taskId && !!_this.taskFieldsIndex[taskId] && !!_this.taskFieldsIndex[taskId].fields
23696
+ && !!_this.taskFieldsIndex[taskId].fields[changedField])
23697
+ _this.updateReferencedField(chFields, _this.taskFieldsIndex[taskId].fields[changedField], frontendActions);
23642
23698
  }
23643
23699
  });
23644
23700
  this.$shouldCreate.next(this._task.dataGroups);
@@ -23665,8 +23721,10 @@
23665
23721
  field.behavior = updatedField.behavior[_this._task.transitionId];
23666
23722
  }
23667
23723
  else {
23668
- // ignore the behavior update, since it does not affect this task
23669
- return; // continue - the field does not need updating, since nothing changed
23724
+ var transitionId = _this.getReferencedTransitionId(field.stringId);
23725
+ if (!!transitionId && transitionId !== '' && updatedField.behavior[transitionId])
23726
+ field.behavior = updatedField.behavior[transitionId];
23727
+ break;
23670
23728
  }
23671
23729
  break;
23672
23730
  case 'choices':
@@ -23702,6 +23760,26 @@
23702
23760
  field.update();
23703
23761
  });
23704
23762
  };
23763
+ TaskContentService.prototype.updateReferencedField = function (chFields, field, frontendActions) {
23764
+ var _this = this;
23765
+ if (this._fieldConverterService.resolveType(field) === exports.FieldTypeResource.TASK_REF) {
23766
+ this._taskDataReloadRequest$.next(frontendActions ? frontendActions : undefined);
23767
+ return;
23768
+ }
23769
+ var updatedField = chFields[field.stringId];
23770
+ Object.keys(updatedField).forEach(function (key) {
23771
+ switch (key) {
23772
+ case 'behavior':
23773
+ var transitionId = _this.getReferencedTransitionId(field.stringId);
23774
+ if (!!transitionId && transitionId !== '' && updatedField.behavior[transitionId])
23775
+ field.behavior = updatedField.behavior[transitionId];
23776
+ break;
23777
+ default:
23778
+ field[key] = updatedField[key];
23779
+ }
23780
+ field.update();
23781
+ });
23782
+ };
23705
23783
  /**
23706
23784
  * Performs the specific frontend action.
23707
23785
  *
@@ -23717,6 +23795,31 @@
23717
23795
  rxjs.timer().subscribe(function () { return _this.validateTaskData(); });
23718
23796
  }
23719
23797
  };
23798
+ TaskContentService.prototype.isFieldInTaskRef = function (changedField) {
23799
+ var _this = this;
23800
+ return !!this.taskFieldsIndex &&
23801
+ Object.keys(this.taskFieldsIndex)
23802
+ .some(function (taskId) { return taskId !== _this.task.stringId && _this.taskFieldsIndex[taskId].fields[changedField]; });
23803
+ };
23804
+ TaskContentService.prototype.getReferencedTransitionId = function (changedField) {
23805
+ var _this = this;
23806
+ if (!!this.taskFieldsIndex) {
23807
+ var taskFieldsIndexId = Object.keys(this.taskFieldsIndex).find(function (taskId) {
23808
+ return Object.keys(_this.taskFieldsIndex[taskId].fields).includes(changedField);
23809
+ });
23810
+ return this.taskFieldsIndex[taskFieldsIndexId].transitionId;
23811
+ }
23812
+ return undefined;
23813
+ };
23814
+ TaskContentService.prototype.getReferencedTaskId = function (changedField) {
23815
+ var _this = this;
23816
+ if (!!this.taskFieldsIndex) {
23817
+ return Object.keys(this.taskFieldsIndex).find(function (taskId) {
23818
+ return Object.keys(_this.taskFieldsIndex[taskId].fields).includes(changedField);
23819
+ });
23820
+ }
23821
+ return undefined;
23822
+ };
23720
23823
  TaskContentService.FRONTEND_ACTIONS_KEY = '_frontend_actions';
23721
23824
  TaskContentService.VALIDATE_FRONTEND_ACTION = 'validate';
23722
23825
  TaskContentService.ctorParameters = function () { return [
@@ -24285,6 +24388,8 @@
24285
24388
  dataGroups.forEach(function (group) {
24286
24389
  var dataGroupParentCaseId = group.parentCaseId === undefined ? _this._safeTask.caseId : group.parentCaseId;
24287
24390
  var parentTaskId = group.parentTaskId === undefined ? _this._safeTask.stringId : group.parentTaskId;
24391
+ var parentTransitionId = group.parentTransitionId === undefined ?
24392
+ _this._safeTask.transitionId : group.parentTransitionId;
24288
24393
  if (dataGroupParentCaseId !== _this._safeTask.caseId) {
24289
24394
  if (!_this._taskContentService.referencedTaskAndCaseIds[dataGroupParentCaseId]) {
24290
24395
  _this._taskContentService.referencedTaskAndCaseIds[dataGroupParentCaseId] = [group.parentTaskId];
@@ -24301,8 +24406,12 @@
24301
24406
  if (group.fields.length > 0 && !_this._taskContentService.taskFieldsIndex[parentTaskId]) {
24302
24407
  _this._taskContentService.taskFieldsIndex[parentTaskId] = {};
24303
24408
  }
24409
+ if (group.fields.length > 0 && !_this._taskContentService.taskFieldsIndex[parentTaskId].fields) {
24410
+ _this._taskContentService.taskFieldsIndex[parentTaskId].fields = {};
24411
+ }
24304
24412
  group.fields.forEach(function (field) {
24305
- _this._taskContentService.taskFieldsIndex[parentTaskId][field.stringId] = field;
24413
+ _this._taskContentService.taskFieldsIndex[parentTaskId].transitionId = parentTransitionId;
24414
+ _this._taskContentService.taskFieldsIndex[parentTaskId].fields[field.stringId] = field;
24306
24415
  field.valueChanges().subscribe(function () {
24307
24416
  if (_this.wasFieldUpdated(field)) {
24308
24417
  if (field instanceof DynamicEnumerationField) {
@@ -24469,7 +24578,7 @@
24469
24578
  try {
24470
24579
  for (var fieldIdsOfRequest_1 = (e_2 = void 0, __values(fieldIdsOfRequest)), fieldIdsOfRequest_1_1 = fieldIdsOfRequest_1.next(); !fieldIdsOfRequest_1_1.done; fieldIdsOfRequest_1_1 = fieldIdsOfRequest_1.next()) {
24471
24580
  var fieldId = fieldIdsOfRequest_1_1.value;
24472
- var field = this._taskContentService.taskFieldsIndex[taskId][fieldId];
24581
+ var field = this._taskContentService.taskFieldsIndex[taskId].fields[fieldId];
24473
24582
  if (field === undefined) {
24474
24583
  this._log.error("Unexpected state. Datafield " + fieldId + " of task " + taskId + " in setData request is not present in the task.");
24475
24584
  return false;
@@ -24677,7 +24786,7 @@
24677
24786
  var _this = this;
24678
24787
  Object.keys(body).forEach(function (taskId) {
24679
24788
  Object.keys(body[taskId]).forEach(function (fieldId) {
24680
- _this._taskContentService.taskFieldsIndex[taskId][fieldId].waitingForResponse = false;
24789
+ _this._taskContentService.taskFieldsIndex[taskId].fields[fieldId].waitingForResponse = false;
24681
24790
  });
24682
24791
  });
24683
24792
  };
@@ -25333,7 +25442,6 @@
25333
25442
  FinishPolicyService.prototype.autoNoDataFinishPolicy = function (afterAction) {
25334
25443
  if (this._safeTask.dataSize <= 0) {
25335
25444
  this._finishTaskService.validateDataAndFinish(afterAction);
25336
- this._taskOperations.close();
25337
25445
  }
25338
25446
  else {
25339
25447
  this._taskOperations.open();