So I have a JSON Of the following Format:
{
"loan": {
"loanKey": 6575,
"poolNum": "300801056",
"triggers": [
{
"id": 4276,
"triggerType": "DSCR",
"triggerValue": 1.2
}
]
}
},
{
"loan": {
"loanKey": 6651,
"poolNum": "30308716"
}
},
{
"loan": {
"loanKey": 8224,
"poolNum": "998"
}
},
{
"loan": {
"loanKey": 8225,
"poolNum": "999"
}
},
{
"loan": {
"loanKey": 9877,
"poolNum": "998"
}
},
{
"loan": {
"loanKey": 9878,
"poolNum": "999"
}
}
]
Now I am accessing a certain row and its internal elements in a way below:
<ng-container matColumnDef="loanKey">
<th mat-header-cell *matHeaderCellDef mat-sort-header>Loan Key/ID</th>
<td mat-cell *matCellDef="let row">
{{ row.loan.loanKey }}
</td>
</ng-container>
With this I am getting the value I req. to display on the table, but due to mismatch of the matColumnDef name and interpolation name the matSearch and Sort arent working. Can anyone help fix this?