Fix process unit test and add activiti apps documentation

This commit is contained in:
mauriziovitale84
2016-11-21 12:07:42 +00:00
committed by Mario Romano
parent 74fb64458c
commit 96ce41fcec
2 changed files with 27 additions and 2 deletions

View File

@@ -153,9 +153,14 @@ describe('ActivitiProcessInstanceListComponent', () => {
}); });
it('should reload processes when reload() is called', (done) => { it('should reload processes when reload() is called', (done) => {
spyOn(service, 'getProcessInstances').and.returnValue(Observable.throw('Fake server error')); spyOn(service, 'getProcessInstances').and.returnValue(Observable.of(fakeGlobalProcesses));
component.data = new ObjectDataTableAdapter(
[],
[
{type: 'text', key: 'fake-id', title: 'Name'}
]
);
component.state = 'open'; component.state = 'open';
component.ngOnInit();
component.onSuccess.subscribe( (res) => { component.onSuccess.subscribe( (res) => {
expect(res).toBeDefined(); expect(res).toBeDefined();
expect(component.data).toBeDefined(); expect(component.data).toBeDefined();

View File

@@ -291,6 +291,26 @@ This can be changed by adding the following custom html template:
</activiti-task-details> </activiti-task-details>
``` ```
## Basic usage example Activiti Apps
The component shows all the available apps.
```html
<activiti-apps [layoutType]="'GRID'"></activiti-filters>
```
#### Events
| Name | Description |
| --- | --- |
| `appClick` | Invoked when an app is clicked |
#### Options
| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `layoutType` | {string} | required | Define the layout of the apps. There are two possible values: GRID or LIST. |
## Basic usage example Activiti Filter ## Basic usage example Activiti Filter
The component shows all the available filters. The component shows all the available filters.