[ADF- 4871][TaskHeaderCloudComponent] Add Candidate Users/Groups properties (#5189)

* [ADF-4871] [TaskHeaderCloudComponent] Add Candidate Users/Groups properties

* Added Candidate users/groups properties to the task heade cloud component.

* * Created CardViewArrayItemComponent
* Modified FullName pipe to return username or email incase fullname missing.
* Added candidate Users/Groups properties to the taskcloudheader component.
* Added two service into task-cloudservice
* Updated Demoshell card-view with new widget

* * Fixed failing unit test

* * Fixed comments.

* * Refactored CardViewArrayItem model
* Fixed comments.

* * Changed candidate group icon
This commit is contained in:
siva kumar
2019-10-29 14:56:34 +05:30
committed by Maurizio Vitale
parent 1c6eb4d73d
commit 9c2bcdee1a
23 changed files with 610 additions and 12 deletions

View File

@@ -87,6 +87,14 @@ Defining properties from Typescript:
options$: of([{ key: 'one', label: 'One' }, { key: 'two', label: 'Two' }]),
key: 'select'
}),
new CardViewArrayItemModel({
label: 'Array of items',
value: '',
items$: of(['One', 'Two', 'Three', 'Four']),
key: 'array',
default: 'Empty',
noOfItemsToDisplay: 2
})
...
]
```
@@ -116,6 +124,7 @@ You define the property list, the [`CardViewComponent`](../../core/components/ca
- [**CardViewFloatItemModel**](#card-float-item) - _for float items_
- [**CardViewKeyValuePairsItemModel**](#card-key-value-pairs-item) - _for key-value-pairs items_
- [**CardViewSelectItemModel**](#card-select-item) - _for select items_
- [**CardViewArrayItemModel**](#card-array-item) - _for array items_
Each of these types implements the [Card View Item interface](../interfaces/card-view-item.interface.md):
@@ -336,6 +345,21 @@ const selectItemProperty = new CardViewSelectItemModel(options);
| value | string | | The original data value for the item |
| options$\* | [`Observable`](http://reactivex.io/documentation/observable.html)<[`CardViewSelectItemOption`](../../../lib/core/card-view/interfaces/card-view-selectitem-properties.interface.ts)\[]> | | The original data value for the item |
#### Card Array Item
[`CardViewArrayItemModel`](../../../lib/core/card-view/models/card-view-arrayitem.model.ts) is a property type for array properties.
```ts
const arrayItemProperty = new CardViewArrayItemModel(items);
```
| Name | Type | Default | Description |
| ---- | ---- | ------- | ----------- |
| label\* | string | | Item label |
| key\* | string | | Identifying key (important when editing the item) |
| editable | boolean | false | Toggles whether the item is editable |
| value | [`Observable`](http://reactivex.io/documentation/observable.html)<`string`\[]> | | The original data value for the item |
## See also
- [Card View Update service](../services/card-view-update.service.md)