Expected result: keyword field filled
Actual result: Cannot read property 'setValue' of undefined at UploadPage.fillFormWithKeyword
-Login to client fresh client into police archvie
-Upload an image
-Go back to entries
-Go into settings
-Add both keywordfields to list of upload fields
-Go back to entries
-Acquire image
-Try to add a single keyword error => Cannot read property 'setValue' of undefined
The problem is that in the method fillFormWithKeyword the fieldForm does not get updated (maybe has something to do with an event.
public fillFormWithKeyword(field: MetadataField, keyword: Keyword): void {
this.fieldsForm.controls[field.name].setValue(keyword.keyword);
}
Steps to reproduce:
Expected result: keyword field filled Actual result:
Cannot read property 'setValue' of undefined at UploadPage.fillFormWithKeyword
-Login to client fresh client into police archvie -Upload an image -Go back to entries -Go into settings -Add both keywordfields to list of upload fields -Go back to entries -Acquire image -Try to add a single keyword error => Cannot read property 'setValue' of undefined
The problem is that in the method fillFormWithKeyword the fieldForm does not get updated (maybe has something to do with an event.
public fillFormWithKeyword(field: MetadataField, keyword: Keyword): void { this.fieldsForm.controls[field.name].setValue(keyword.keyword); }