mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ADF-1139] People search - Provide an API to reset the search (#2196)
* People search provide a way to reset the search * Fix readme rules
This commit is contained in:
committed by
Mario Romano
parent
81712d69d6
commit
426464a53c
@@ -39,6 +39,11 @@
|
||||
- [Task People Component](#task-people-component)
|
||||
* [Properties](#properties-8)
|
||||
+ [Events](#events-7)
|
||||
+ [How to customize the people component behavior](#how-to-customize-the-people-component-behavior)
|
||||
+ [Involve People single click and close search](#involve-people-single-click-and-close-search)
|
||||
+ [Involve People single click without close search](#involve-people-single-click-without-close-search)
|
||||
+ [Involve People double click and close search](#involve-people-double-click-and-close-search)
|
||||
+ [Involve People double double without close search](#involve-people-double-double-without-close-search)
|
||||
- [ADF Comments Component](#adf-comments-component)
|
||||
* [Properties](#properties-9)
|
||||
+ [Events](#events-8)
|
||||
@@ -50,7 +55,7 @@
|
||||
+ [Events](#events-10)
|
||||
- [People Search Component](#people-search-component)
|
||||
* [Properties](#properties-12)
|
||||
* [Events](#events-12)
|
||||
* [Events](#events-11)
|
||||
- [Build from sources](#build-from-sources)
|
||||
- [NPM scripts](#npm-scripts)
|
||||
- [Demo](#demo)
|
||||
@@ -474,6 +479,66 @@ This component displays involved users to a specified task
|
||||
|
||||
No Events
|
||||
|
||||
#### How to customize the people component behavior
|
||||
|
||||
The people component provide two methods to customize the behavior:
|
||||
- involveUserAndCloseSearch: The selected user is going to be added and the search section closed
|
||||
- involveUserWithoutCloseSearch: The selected user is going to be added without close the search section
|
||||
|
||||
In this way will be easy customize the people component to involve the user with the single or double click event:
|
||||
|
||||
#### Involve People single click and close search
|
||||
|
||||
```html
|
||||
<adf-people #people
|
||||
(row-click)="people.involveUserAndCloseSearch()"
|
||||
[people]="YOUR_INVOLVED_PEOPLE_LIST"
|
||||
[taskId]="YOUR_TASK_ID"
|
||||
[readOnly]="YOUR_READ_ONLY_FLAG">
|
||||
</adf-people>
|
||||
```
|
||||
|
||||

|
||||
|
||||
#### Involve People single click without close search
|
||||
|
||||
```html
|
||||
<adf-people #people
|
||||
(row-click)="people.involveUserWithoutCloseSearch()"
|
||||
[people]="YOUR_INVOLVED_PEOPLE_LIST"
|
||||
[taskId]="YOUR_TASK_ID"
|
||||
[readOnly]="YOUR_READ_ONLY_FLAG">
|
||||
</adf-people>
|
||||
```
|
||||
|
||||

|
||||
|
||||
#### Involve People double click and close search
|
||||
|
||||
```html
|
||||
<adf-people #people
|
||||
(row-dblclick)="people.involveUserAndCloseSearch()"
|
||||
[people]="YOUR_INVOLVED_PEOPLE_LIST"
|
||||
[taskId]="YOUR_TASK_ID"
|
||||
[readOnly]="YOUR_READ_ONLY_FLAG">
|
||||
</adf-people>
|
||||
```
|
||||
|
||||

|
||||
|
||||
#### Involve People double double without close search
|
||||
|
||||
```html
|
||||
<adf-people #people
|
||||
(row-dblclick)="people.involveUserWithoutCloseSearch()"
|
||||
[people]="YOUR_INVOLVED_PEOPLE_LIST"
|
||||
[taskId]="YOUR_TASK_ID"
|
||||
[readOnly]="YOUR_READ_ONLY_FLAG">
|
||||
</adf-people>
|
||||
```
|
||||
|
||||

|
||||
|
||||
## ADF Comments Component
|
||||
|
||||
This component displays comments entered by involved users to a specified task. It also allows an involved user to add his/her comment to the task.
|
||||
|
Reference in New Issue
Block a user