I want to patch a form with slightly different field name. Is this possible in Angular?
Example: suppose this is my student.ts class.
export class Student {
id: number;
BIValueTerm: number;
}
I want to patch my formgroup with a student object. my formgroup looks like this:
// const student = ... ; student object
const studentForm = new FormGroup({
id: new FormControl(''),
bivalueTerm: new FormControl('')
});
studentForm.patchValue(student);
now the problem is, studentForm properly patches the id field but not bivalueTerm field. Is there any way I can also patch it?