I have a value and I need to put it in the dropdown at start:
state is an object {'code':...,'description'}
and listState in array of state
loadValue(stateSave: Object) {//state save is the object just saved
this.state={'code':stateSave['code'],'description':stateSave['description'] }
and in my html is:
<p-dropdown [options]="listState" [(ngModel)]="state" optionLabel="description"></p-dropdown>
My problem is that if I have an old value just saved and I want to show it but the dropdown doesn't work, because at start it doesn't show anything. Anyone can help me?