This commit is contained in:
parent
34759d26a7
commit
09fd606b86
1 changed files with 29 additions and 26 deletions
|
|
@ -1475,6 +1475,9 @@ export class PositionController extends Controller {
|
|||
if (posMaster.orgRevision?.orgRevisionIsCurrent == true && !posMaster.isSit) {
|
||||
const _position = requestBody.positions.find((p) => p.positionIsSelected == true);
|
||||
if (_position) {
|
||||
const _posExecutive = _position.posExecutiveId
|
||||
? await this.posExecutiveRepository.findOne({ where: { id: _position.posExecutiveId } })
|
||||
: null;
|
||||
const current_holderId: any = posMaster.current_holderId;
|
||||
const _profile = await this.profileRepository.findOne({
|
||||
where: { id: current_holderId },
|
||||
|
|
@ -1484,7 +1487,7 @@ export class PositionController extends Controller {
|
|||
_profile.posTypeId = _position.posTypeId;
|
||||
_profile.posLevelId = _position.posLevelId;
|
||||
_profile.positionField = _position.posDictField ?? _null;
|
||||
_profile.posExecutive = _position.posExecutiveId ?? _null;
|
||||
_profile.posExecutive = _posExecutive?.posExecutiveName ?? _null;
|
||||
_profile.positionArea = _position.posDictArea ?? _null;
|
||||
_profile.positionExecutiveField = _position.posDictExecutiveField ?? _null;
|
||||
await this.profileRepository.save(_profile);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue