mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-19 17:14:57 +00:00
Start process: Make the title optional (#5580)
* Make the title optional * Add the title on demoshell * Remove the mat card and css * Fix scss
This commit is contained in:
parent
01d0f777c0
commit
f4f46d0c60
@ -213,6 +213,7 @@
|
||||
<adf-start-process
|
||||
#activitiStartProcess
|
||||
[appId]="appId"
|
||||
[title]="'ADF_PROCESS_LIST.START_PROCESS.FORM.TITLE'"
|
||||
[name]="defaultProcessName"
|
||||
[processDefinitionName]="defaultProcessDefinitionName"
|
||||
(formContentClicked)="onContentClick($event)"
|
||||
|
@ -39,6 +39,7 @@ Starts a process.
|
||||
| Name | Type | Default value | Description |
|
||||
| ---- | ---- | ------------- | ----------- |
|
||||
| appId | `number` | | (optional) Limit the list of processes that can be started to those contained in the specified app. |
|
||||
| title | `string` | "" | (optional) Define the header of the component. |
|
||||
| name | `string` | "" | (optional) Name to assign to the current process. |
|
||||
| processDefinitionName | `string` | | (optional) Definition name of the process to start. |
|
||||
| processFilterSelector | `boolean` | true | (optional) Parameter to enable selection of process when filtering. |
|
||||
@ -61,6 +62,7 @@ Starts a process.
|
||||
```html
|
||||
<adf-start-process
|
||||
[appId]="YOUR_APP_ID"
|
||||
[title]="'ADF_PROCESS_LIST.START_PROCESS.FORM.TITLE'"
|
||||
[name]="PROCESS_NAME"
|
||||
[processDefinitionName]="PROCESS_DEFINITION_NAME">
|
||||
</adf-start-process>
|
||||
|
@ -1,10 +1,9 @@
|
||||
<mat-card class="adf-start-process">
|
||||
<mat-card-title>{{'ADF_PROCESS_LIST.START_PROCESS.FORM.TITLE' | translate}}
|
||||
</mat-card-title>
|
||||
<mat-card-content *ngIf="isProcessDefinitionEmpty()">
|
||||
<mat-card-subtitle id="error-message" *ngIf="errorMessageId">
|
||||
<div class="adf-start-process">
|
||||
<div class="title" *ngIf="title">{{ title | translate}}</div>
|
||||
<div class="content" *ngIf="isProcessDefinitionEmpty()">
|
||||
<div class="subtitle" id="error-message" *ngIf="errorMessageId">
|
||||
{{errorMessageId|translate}}
|
||||
</mat-card-subtitle>
|
||||
</div>
|
||||
<mat-form-field class="adf-process-input-container">
|
||||
<input
|
||||
matInput
|
||||
@ -60,13 +59,13 @@
|
||||
{{'ADF_PROCESS_LIST.START_PROCESS.FORM.ACTION.CANCEL'| translate | uppercase}}
|
||||
</button>
|
||||
</adf-start-form>
|
||||
</mat-card-content>
|
||||
<mat-card-content *ngIf="hasErrorMessage()">
|
||||
<mat-card-subtitle class="error-message" id="no-process-message">
|
||||
</div>
|
||||
<div class="content" *ngIf="hasErrorMessage()">
|
||||
<div class="subtitle" class="error-message" id="no-process-message">
|
||||
{{'ADF_PROCESS_LIST.START_PROCESS.NO_PROCESS_DEFINITIONS' | translate | uppercase}}
|
||||
</mat-card-subtitle>
|
||||
</mat-card-content>
|
||||
<mat-card-actions *ngIf="!hasStartForm()">
|
||||
</div>
|
||||
</div>
|
||||
<div class="mat-content-actions" *ngIf="!hasStartForm()">
|
||||
<button
|
||||
mat-button
|
||||
*ngIf="!hasStartForm()"
|
||||
@ -85,5 +84,5 @@
|
||||
class="btn-start">
|
||||
{{'ADF_PROCESS_LIST.START_PROCESS.FORM.ACTION.START' | translate | uppercase}}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,6 +1,6 @@
|
||||
.adf {
|
||||
&-start-process {
|
||||
width: 66%;
|
||||
width: 96%;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
margin-top: 10px;
|
||||
@ -14,13 +14,13 @@
|
||||
width: 100%;
|
||||
padding: 16px 0 0;
|
||||
}
|
||||
mat-card-actions {
|
||||
.mat-content-actions {
|
||||
text-align: right;
|
||||
}
|
||||
.mat-button {
|
||||
text-transform: uppercase !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
&-process-input-container {
|
||||
mat-form-field {
|
||||
width: 100%;
|
||||
|
@ -50,6 +50,9 @@ export class StartProcessInstanceComponent implements OnChanges, OnInit, OnDestr
|
||||
@Input()
|
||||
appId: number;
|
||||
|
||||
@Input()
|
||||
title: string;
|
||||
|
||||
/** (optional) Definition name of the process to start. */
|
||||
@Input()
|
||||
processDefinitionName: string;
|
||||
|
Loading…
x
Reference in New Issue
Block a user