no message
This commit is contained in:
parent
25b5d58f2a
commit
53787597fd
54 changed files with 219 additions and 332 deletions
|
|
@ -142,13 +142,11 @@ export class ProfileChangeNameEmployeeTempController extends Controller {
|
|||
|
||||
Object.assign(data, { ...body, ...meta });
|
||||
const history = new ProfileChangeNameHistory();
|
||||
history.profileChangeNameId = data.id;
|
||||
Object.assign(history, { ...data, id: undefined });
|
||||
|
||||
await Promise.all([
|
||||
this.changeNameRepository.save(data),
|
||||
(history.profileChangeNameId = data.id),
|
||||
this.changeNameHistoryRepository.save(history),
|
||||
]);
|
||||
await this.changeNameRepository.save(data);
|
||||
history.profileChangeNameId = data.id;
|
||||
await this.changeNameHistoryRepository.save(history);
|
||||
|
||||
profile.firstName = body.firstName ?? profile.firstName;
|
||||
profile.lastName = body.lastName ?? profile.lastName;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue