Re-working how the properties are read on tasks.
fixing childcount to child_count.
This commit is contained in:
parent
268cd189d4
commit
d6b2448720
16
angular.json
16
angular.json
|
@ -14,13 +14,13 @@
|
|||
"options": {
|
||||
"tsConfig": "projects/sartography-workflow-lib/tsconfig.lib.json",
|
||||
"project": "projects/sartography-workflow-lib/ng-package.json"
|
||||
}
|
||||
, "configurations": {
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
"tsConfig": "projects/sartography-workflow-lib/tsconfig.lib.prod.json"
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
"test": {
|
||||
"builder": "@angular-devkit/build-angular:karma",
|
||||
"options": {
|
||||
|
@ -49,6 +49,10 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
}},
|
||||
"defaultProject": "sartography-workflow-lib"
|
||||
}
|
||||
}
|
||||
},
|
||||
"defaultProject": "sartography-workflow-lib",
|
||||
"cli": {
|
||||
"analytics": "bc6a81f9-c4c5-46ec-a27b-ba6ec643e910"
|
||||
}
|
||||
}
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "sartography-workflow-lib",
|
||||
"version": "0.0.159",
|
||||
"version": "0.0.160",
|
||||
"peerDependencies": {
|
||||
"@angular/common": "^8.2.14",
|
||||
"@angular/core": "^8.2.14",
|
||||
|
|
|
@ -22,12 +22,14 @@ export enum WorkflowTaskType {
|
|||
}
|
||||
|
||||
export class WorkflowTask {
|
||||
DISPLAY_NAME_PROP = 'display_name';
|
||||
|
||||
data: any;
|
||||
documentation: string;
|
||||
form: BpmnFormJson;
|
||||
id: string;
|
||||
name: string;
|
||||
properties?: BpmnFormJsonFieldProperty[];
|
||||
properties?: object;
|
||||
state: WorkflowTaskState;
|
||||
title: string;
|
||||
type: WorkflowTaskType;
|
||||
|
@ -36,8 +38,8 @@ export class WorkflowTask {
|
|||
process_name?: string;
|
||||
|
||||
display_name?(): string {
|
||||
if (this.properties && this.properties.length > 0) {
|
||||
const displayNameProp = this.properties.find(p => p.id === 'display_name');
|
||||
if (this.properties && this.DISPLAY_NAME_PROP in this.properties) {
|
||||
const displayNameProp = this.properties[this.DISPLAY_NAME_PROP];
|
||||
if (displayNameProp) {
|
||||
return displayNameProp.value;
|
||||
}
|
||||
|
|
|
@ -64,6 +64,6 @@ export interface WorkflowNavItem {
|
|||
backtracks: boolean;
|
||||
level: number;
|
||||
indent: number;
|
||||
childcount: number;
|
||||
child_count: number;
|
||||
state: WorkflowTaskState;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue