Hey guys, i got a question with using both dataKey and optionValue.
The problem is
I using multiselect for set some info to formArray, to input im getting an array of formGroup
this._formBuilder.group({
id: [uuidv4()],
name: ['', Validators.required],
type: ['TEXT', Validators.required],
initialValue: ['']
})
to uniquely identify a value in option and to reactively change "name"(there was a problem when i changed "name" data in multiselect became uncheked but it left at formgroup so i was not able to clear or modify data in formArray, "dataKey" helped me to fix this problem, data changed reactively from both sides multiselect and formArray) im using dataKey="id"
Now i got the problem using both using both dataKey and optionValue, i need to pass just "name" to formArray not whole object and when i click on some option multiselect checks all options. PLEASE HELP!
If you need more info about it, just ask i'll show u all u need
p-multiselect
-
- Information
-
Who is online
Users browsing this forum: No registered users and 24 guests