mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-10-08 14:51:32 +00:00
[ADF-2201] Tidied Start Process docs (#2864)
* [ADF-2201] Tidied Start Process docs * [ADF-2201] Removed file with probably incorrect name
This commit is contained in:
committed by
Eugenio Romano
parent
c66115fe70
commit
441d1e648e
@@ -138,6 +138,7 @@ for more information about installing and using the source code.
|
|||||||
| [Bpm user service](bpm-user.service.md) | Gets information about the current Process Services user. | [Source](../lib/core/userinfo/services/bpm-user.service.ts) |
|
| [Bpm user service](bpm-user.service.md) | Gets information about the current Process Services user. | [Source](../lib/core/userinfo/services/bpm-user.service.ts) |
|
||||||
| [Ecm user service](ecm-user.service.md) | Gets information about a Content Services user. | [Source](../lib/core/userinfo/services/ecm-user.service.ts) |
|
| [Ecm user service](ecm-user.service.md) | Gets information about a Content Services user. | [Source](../lib/core/userinfo/services/ecm-user.service.ts) |
|
||||||
| _Renditions service_ | _Not currently documented_ | [Source](../lib/core/services/renditions.service.ts) |
|
| _Renditions service_ | _Not currently documented_ | [Source](../lib/core/services/renditions.service.ts) |
|
||||||
|
| _Search configuration service_ | _Not currently documented_ | [Source](../lib/core/services/search-configuration.service.ts) |
|
||||||
| _Sites service_ | _Not currently documented_ | [Source](../lib/core/services/sites.service.ts) |
|
| _Sites service_ | _Not currently documented_ | [Source](../lib/core/services/sites.service.ts) |
|
||||||
|
|
||||||
## Widgets
|
## Widgets
|
||||||
@@ -169,7 +170,7 @@ for more information about installing and using the source code.
|
|||||||
## Components
|
## Components
|
||||||
|
|
||||||
| Name | Description | Source link |
|
| Name | Description | Source link |
|
||||||
| --------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- |
|
| ---- | ----------- | ----------- |
|
||||||
| [Breadcrumb component](breadcrumb.component.md) | Indicates the current position within a navigation hierarchy. | [Source](../lib/content-services/breadcrumb/breadcrumb.component.ts) |
|
| [Breadcrumb component](breadcrumb.component.md) | Indicates the current position within a navigation hierarchy. | [Source](../lib/content-services/breadcrumb/breadcrumb.component.ts) |
|
||||||
| [Dropdown breadcrumb component](dropdown-breadcrumb.component.md) | Indicates the current position within a navigation hierarchy using a dropdown menu. | [Source](../lib/content-services/breadcrumb/dropdown-breadcrumb.component.ts) |
|
| [Dropdown breadcrumb component](dropdown-breadcrumb.component.md) | Indicates the current position within a navigation hierarchy using a dropdown menu. | [Source](../lib/content-services/breadcrumb/dropdown-breadcrumb.component.ts) |
|
||||||
| [Content metadata component](content-metadata.component.md) | Allows a user to display and edit metadata related to a node. | [Source](../lib/content-services/content-metadata/components/content-metadata/content-metadata.component.ts) |
|
| [Content metadata component](content-metadata.component.md) | Allows a user to display and edit metadata related to a node. | [Source](../lib/content-services/content-metadata/components/content-metadata/content-metadata.component.ts) |
|
||||||
@@ -190,7 +191,7 @@ for more information about installing and using the source code.
|
|||||||
| [Version list component](version-list.component.md) | Displays the version history of a node in a [Version Manager component](version-manager.component.md) | [Source](../lib/content-services/version-manager/version-list.component.ts) |
|
| [Version list component](version-list.component.md) | Displays the version history of a node in a [Version Manager component](version-manager.component.md) | [Source](../lib/content-services/version-manager/version-list.component.ts) |
|
||||||
| [Version manager component](version-manager.component.md) | Displays the version history of a node with the ability to upload a new version. | [Source](../lib/content-services/version-manager/version-manager.component.ts) |
|
| [Version manager component](version-manager.component.md) | Displays the version history of a node with the ability to upload a new version. | [Source](../lib/content-services/version-manager/version-manager.component.ts) |
|
||||||
| [Webscript component](webscript.component.md) | Provides access to Webscript features. | [Source](../lib/content-services/webscript/webscript.component.ts) |
|
| [Webscript component](webscript.component.md) | Provides access to Webscript features. | [Source](../lib/content-services/webscript/webscript.component.ts) |
|
||||||
| _Content metadata component_ | _Not currently documented_ | [Source](../lib/content-services/content-metadata/content-metadata.component.ts) |
|
| _Content metadata card component_ | _Not currently documented_ | [Source](../lib/content-services/content-metadata/components/content-metadata-card/content-metadata-card.component.ts) |
|
||||||
| _Content node selector panel component_ | _Not currently documented_ | [Source](../lib/content-services/content-node-selector/content-node-selector-panel.component.ts) |
|
| _Content node selector panel component_ | _Not currently documented_ | [Source](../lib/content-services/content-node-selector/content-node-selector-panel.component.ts) |
|
||||||
|
|
||||||
## Directives
|
## Directives
|
||||||
@@ -242,7 +243,6 @@ for more information about installing and using the source code.
|
|||||||
| Name | Description | Source link |
|
| Name | Description | Source link |
|
||||||
| ---- | ----------- | ----------- |
|
| ---- | ----------- | ----------- |
|
||||||
| [Apps list component](apps-list.component.md) | Shows all available apps. | [Source](../lib/process-services/app-list/apps-list.component.ts) |
|
| [Apps list component](apps-list.component.md) | Shows all available apps. | [Source](../lib/process-services/app-list/apps-list.component.ts) |
|
||||||
| [Select app dialog component](select-apps-dialog-component.md) | Shows a dialog listing all the PS apps with a slect box to slect it | [Source](../lib/process-services/app-list/select-apps-dialog-component.ts) |
|
|
||||||
| [Create process attachment component](create-process-attachment.component.md) | Displays Upload Component (Drag and Click) to upload the attachment to a specified process instance | [Source](../lib/process-services/attachment/create-process-attachment.component.ts) |
|
| [Create process attachment component](create-process-attachment.component.md) | Displays Upload Component (Drag and Click) to upload the attachment to a specified process instance | [Source](../lib/process-services/attachment/create-process-attachment.component.ts) |
|
||||||
| [Create task attachment component](create-task-attachment.component.md) | Displays Upload Component (Drag and Click) to upload the attachment to a specified task | [Source](../lib/process-services/attachment/create-task-attachment.component.ts) |
|
| [Create task attachment component](create-task-attachment.component.md) | Displays Upload Component (Drag and Click) to upload the attachment to a specified task | [Source](../lib/process-services/attachment/create-task-attachment.component.ts) |
|
||||||
| [Process attachment list component](process-attachment-list.component.md) | Displays attached documents on a specified process instance | [Source](../lib/process-services/attachment/process-attachment-list.component.ts) |
|
| [Process attachment list component](process-attachment-list.component.md) | Displays attached documents on a specified process instance | [Source](../lib/process-services/attachment/process-attachment-list.component.ts) |
|
||||||
@@ -266,6 +266,7 @@ for more information about installing and using the source code.
|
|||||||
| [Task header component](task-header.component.md) | Shows all the information related to a task. | [Source](../lib/process-services/task-list/components/task-header.component.ts) |
|
| [Task header component](task-header.component.md) | Shows all the information related to a task. | [Source](../lib/process-services/task-list/components/task-header.component.ts) |
|
||||||
| [Task list component](task-list.component.md) | Renders a list containing all the tasks matched by the parameters specified. | [Source](../lib/process-services/task-list/components/task-list.component.ts) |
|
| [Task list component](task-list.component.md) | Renders a list containing all the tasks matched by the parameters specified. | [Source](../lib/process-services/task-list/components/task-list.component.ts) |
|
||||||
| _Attach file widget component_ | _Not currently documented_ | [Source](../lib/process-services/content-widget/attach-file-widget.component.ts) |
|
| _Attach file widget component_ | _Not currently documented_ | [Source](../lib/process-services/content-widget/attach-file-widget.component.ts) |
|
||||||
|
| _Attach folder widget component_ | _Not currently documented_ | [Source](../lib/process-services/content-widget/attach-folder-widget.component.ts) |
|
||||||
|
|
||||||
## Directives
|
## Directives
|
||||||
|
|
||||||
|
@@ -1,26 +0,0 @@
|
|||||||
# Select app Component
|
|
||||||
|
|
||||||
Shows all available apps and give you back the selected app.
|
|
||||||
|
|
||||||

|
|
||||||
|
|
||||||
## Basic Usage
|
|
||||||
|
|
||||||
```ts
|
|
||||||
import { SelectAppsDialogComponent } from '@alfresco/adf-process-services';
|
|
||||||
|
|
||||||
constructor(private dialog: MatDialog) {
|
|
||||||
}
|
|
||||||
|
|
||||||
startSelectDialog(){
|
|
||||||
const dialogRef = this.dialog.open(SelectAppsDialogComponent, {
|
|
||||||
width: '630px',
|
|
||||||
panelClass: 'adf-version-manager-dialog'
|
|
||||||
});
|
|
||||||
|
|
||||||
dialogRef.afterClosed().subscribe(selectedProcess => {
|
|
||||||
this.processId = selectedProcess.id;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
```
|
|
29
docs/select-apps-dialog.component.md
Normal file
29
docs/select-apps-dialog.component.md
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
# Select app Component
|
||||||
|
|
||||||
|
Show all available apps and return the selected app.
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Basic Usage
|
||||||
|
|
||||||
|
```ts
|
||||||
|
import { SelectAppsDialogComponent } from '@alfresco/adf-process-services';
|
||||||
|
|
||||||
|
constructor(private dialog: MatDialog) {
|
||||||
|
}
|
||||||
|
|
||||||
|
startSelectDialog(){
|
||||||
|
const dialogRef = this.dialog.open(SelectAppsDialogComponent, {
|
||||||
|
width: '630px',
|
||||||
|
panelClass: 'adf-version-manager-dialog'
|
||||||
|
});
|
||||||
|
|
||||||
|
dialogRef.afterClosed().subscribe(selectedProcess => {
|
||||||
|
this.processId = selectedProcess.id;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## See Also
|
||||||
|
|
||||||
|
- [Start process component](start-process.component.md)
|
@@ -14,27 +14,34 @@ Starts a process.
|
|||||||
|
|
||||||
### Properties
|
### Properties
|
||||||
|
|
||||||
| Name | Description |
|
| Name | Type | Description |
|
||||||
| --- | --- |
|
| ---- | -- | ----------- |
|
||||||
| appId | (required): Limit the list of processes which can be started to those contained in the specified app |
|
| appId | `number` | (required): Limit the list of processes which can be started to those contained in the specified app |
|
||||||
| name | (optional) name to assign to the current process |
|
| name | `string` | (optional) name to assign to the current process |
|
||||||
| processDefinitionId| (optional) definition ID of the process to start |
|
| processDefinitionId | `string` | (optional) definition ID of the process to start |
|
||||||
| variables | Variables in input to the process [RestVariable](https://github.com/Alfresco/alfresco-js-api/tree/master/src/alfresco-activiti-rest-api/docs/RestVariable.md)|
|
| variables | `ProcessInstanceVariable[]` |Variables in input to the process [RestVariable](https://github.com/Alfresco/alfresco-js-api/tree/master/src/alfresco-activiti-rest-api/docs/RestVariable.md) |
|
||||||
| values | Parameter to pass form field values in the start form if is associated |
|
| values | `FormValues` | Parameter to pass form field values in the start form if is associated |
|
||||||
|
|
||||||
### Events
|
### Events
|
||||||
|
|
||||||
| Name | Description |
|
| Name | Type | Description |
|
||||||
| --- | --- |
|
| ---- | -- | --------- |
|
||||||
| start | Raised when the process start |
|
| start | `EventEmitter<ProcessInstance>` | Emitted when the process starts |
|
||||||
| cancel | Raised when the process canceled |
|
| cancel | `EventEmitter<ProcessInstance>` | Emitted when the process is canceled |
|
||||||
| error | Raised when the start process fail |
|
| error | `EventEmitter<ProcessInstance>` | Emitted when the start process operation fails |
|
||||||
|
|
||||||
### Details
|
## Details
|
||||||
|
|
||||||
- If your app has only one processDefintion it will be automaticaly gather from the ***adf-start-process***.
|
Displays the *Start Process* form, allowing the user to specify some details like process name and process definition, which are the most basic requirements to start a new process instance. The following
|
||||||
- If your app has multiple processDefintion and you didn't define processDefinitionId parameter a drop down will allow you to select which use
|
options are available for choosing which process to start:
|
||||||
- If your app has multiple processDefintion and you defined the processDefinitionId parameter the ***adf-start-process*** will be automatically instantiated with the selected process.
|
|
||||||
|
- If your app has only one `processDefinition` then the `adf-start-process` component will iind and
|
||||||
|
use it automatically.
|
||||||
|
- If your app has multiple `processDefinitions` and you don't define a `processDefinitionId` parameter
|
||||||
|
then a drop down will allow you to select which one to use.
|
||||||
|
- If your app has multiple `processDefinitions` and you do define a `processDefinitionId` parameter then the `adf-start-process` component will be automatically instantiated with the selected process.
|
||||||
|
|
||||||
|
An error message will be shown if no process definition at all is available.
|
||||||
|
|
||||||
### Start a process with processDefinitionId
|
### Start a process with processDefinitionId
|
||||||
|
|
||||||
@@ -46,16 +53,15 @@ Starts a process.
|
|||||||
</adf-start-process>
|
</adf-start-process>
|
||||||
```
|
```
|
||||||
|
|
||||||
If you have more then one process in yor app you can in this way preselect which is the process to start
|
Use this method to preselect which process to start if there is more than one process in your app.
|
||||||
|
|
||||||
|
|
||||||
### Custom data example
|
### Custom data example
|
||||||
|
|
||||||
Here is an example of how to pass in form field values, these correspond to the start form that has been defined for the process:
|
Here is an example of how to pass in form field values to initialize the start form that has been
|
||||||
|
defined for the process:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
const formValues:FormValues = {
|
const formValues: FormValues = {
|
||||||
'test_1': 'value_1',
|
'test_1': 'value_1',
|
||||||
'test_2': 'value_2',
|
'test_2': 'value_2',
|
||||||
'test_3': 'value_1',
|
'test_3': 'value_1',
|
||||||
@@ -72,13 +78,13 @@ const formValues:FormValues = {
|
|||||||
</adf-start-process>
|
</adf-start-process>
|
||||||
```
|
```
|
||||||
|
|
||||||
### Attach a File to the start-form of the process
|
### Attaching a File to the start form of the process
|
||||||
|
|
||||||
After the repository is created in APS, you can see your new repository in the Alfresco Repositories list.
|
After the repository is created in APS, you can it in the Alfresco Repositories list.
|
||||||
If the ID is set to 1, then all default values are fine.
|
If the ID is set to 1 then all default values are fine.
|
||||||
However, if it is set to something else, for example, ***1002*** and the name is ***alfresco***, you must set in your 'app.config.json' the property ***alfrescoRepositoryName*** alfresco-1002:
|
However, if it is set to something else, for example, _1002_ and the name is _alfresco_, you must set the property `alfrescoRepositoryName` in your `app.config.json` file to _alfresco-1002_:
|
||||||
|
|
||||||
```ts
|
```json
|
||||||
{
|
{
|
||||||
name: 'Alfresco ADF Application'
|
name: 'Alfresco ADF Application'
|
||||||
},
|
},
|
||||||
@@ -88,11 +94,10 @@ However, if it is set to something else, for example, ***1002*** and the name is
|
|||||||
alfrescoRepositoryName : 'alfresco-1002'
|
alfrescoRepositoryName : 'alfresco-1002'
|
||||||
```
|
```
|
||||||
|
|
||||||
After you need to pass the node in the input values object with the other properties:
|
You then need to pass the node as the input `values` object with the other properties:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
|
let node: MinimalNodeEntryEntity = this.nodesApiService.getNode(NODE_ID);
|
||||||
let node: MinimalNodeEntryEntity = this.odesApiService.getNode(NODE_ID);
|
|
||||||
|
|
||||||
const formValues: FormValues = {
|
const formValues: FormValues = {
|
||||||
'file' : node
|
'file' : node
|
||||||
@@ -100,8 +105,8 @@ const formValues: FormValues = {
|
|||||||
};
|
};
|
||||||
```
|
```
|
||||||
|
|
||||||
Note In the object above the key 'file' is the name of the attach file field in the start form of the process.
|
Note that in the object above, the key `file` is the name of the attach file field in the start form of the process. The value of the `file` property must be a
|
||||||
The value of the file property has to be a ***MinimalNodeEntryEntity**:
|
[MinimalNodeEntryEntity](document-library.model.md):
|
||||||
|
|
||||||
```html
|
```html
|
||||||
<adf-start-process
|
<adf-start-process
|
||||||
@@ -110,12 +115,10 @@ The value of the file property has to be a ***MinimalNodeEntryEntity**:
|
|||||||
</adf-start-process>
|
</adf-start-process>
|
||||||
```
|
```
|
||||||
|
|
||||||
The result will be the start form prefilled with the file:
|
The result will be the start form prefilled with the file data:
|
||||||
|
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
## See also
|
||||||
|
|
||||||
## Details
|
- [Select Apps Dialog component](select-apps-dialog.component.md)
|
||||||
|
|
||||||
Displays Start Process, allowing the user to specify some details like process name and process definition, which are the most basic requirement to start a new process instance. The user have to select the process definition from a dropdown if there are more than one process definition available. If there is just one process definition available for the app, then it is auto-selected. There is a error message shown if no process definition is available.
|
|
||||||
|
Reference in New Issue
Block a user