Merge pull request #77 from sartography/standalone-workflow-204

Standalone workflow 204
This commit is contained in:
Dan Funk 2021-05-04 16:35:12 -04:00 committed by GitHub
commit b45f529a89
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 17 additions and 1 deletions

View File

@ -89,7 +89,16 @@ export class WorkflowSpecDialogComponent {
description: 'Write a few sentences explaining to users why this workflow exists and what it should be used for.',
required: true,
},
}
},
{
key: 'standalone',
type: 'checkbox',
defaultValue: this.data.standalone,
templateOptions: {
label: 'Standalone',
description: 'Is this a standalone workflow?',
},
},
];
});
}

View File

@ -25,6 +25,7 @@ export interface WorkflowSpecDialogData {
description: string;
category_id: number;
display_order: number;
standalone: boolean;
}
export interface WorkflowSpecCategoryDialogData {

View File

@ -19,6 +19,9 @@
<dt>ID</dt><dd>{{workflowSpec.id}}</dd>
<dt>Name</dt><dd>{{workflowSpec.name}}</dd>
<dt>Description</dt><dd>{{workflowSpec.description}}</dd>
<dt>Standalone</dt><dd *ngIf="workflowSpec.standalone; then thenBlock else elseBlock"></dd>
<ng-template #thenBlock><dd>True</dd></ng-template>
<ng-template #elseBlock><dd>False</dd></ng-template>
</dl>
<h4>Workflow Spec Files</h4>

View File

@ -141,6 +141,7 @@ describe('WorkflowSpecListComponent', () => {
description: '',
category_id: 0,
display_order: 0,
standalone: false
};
const _upsertWorkflowSpecificationSpy = spyOn((component as any), '_upsertWorkflowSpecification')

View File

@ -114,6 +114,7 @@ export class WorkflowSpecListComponent implements OnInit {
description: selectedSpec ? selectedSpec.description : '',
category_id: selectedSpec ? selectedSpec.category_id : null,
display_order: hasDisplayOrder ? selectedSpec.display_order : 0,
standalone: selectedSpec ? selectedSpec.standalone : null,
};
@ -263,6 +264,7 @@ export class WorkflowSpecListComponent implements OnInit {
description: data.description,
category_id: data.category_id,
display_order: data.display_order,
standalone: data.standalone
};
if (isNew) {