แก้ format ฟิว posMasterNo (4) สำหรับบันทึกลงระบบที่พัฒนาบน .net
All checks were successful
Build & Deploy on Dev / build (push) Successful in 58s
All checks were successful
Build & Deploy on Dev / build (push) Successful in 58s
This commit is contained in:
parent
fa63953d75
commit
ba185f8de8
1 changed files with 6 additions and 0 deletions
|
|
@ -9173,26 +9173,32 @@ export class ProfileController extends Controller {
|
|||
profile.avatar && profile.avatarName ? `${profile.avatar}/${profile.avatarName}` : null,
|
||||
};
|
||||
|
||||
const _numPart = posMaster ? [posMaster.posMasterNoPrefix, posMaster.posMasterNo, posMaster.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||
if (_profile.child4Id != null) {
|
||||
_profile.node = 4;
|
||||
_profile.nodeId = _profile.child4Id;
|
||||
_profile.nodeShortName = _profile.child4ShortName;
|
||||
_profile.posNo = `${_profile.child4ShortName} ${_numPart}`;
|
||||
} else if (_profile.child3Id != null) {
|
||||
_profile.node = 3;
|
||||
_profile.nodeId = _profile.child3Id;
|
||||
_profile.nodeShortName = _profile.child3ShortName;
|
||||
_profile.posNo = `${_profile.child3ShortName} ${_numPart}`;
|
||||
} else if (_profile.child2Id != null) {
|
||||
_profile.node = 2;
|
||||
_profile.nodeId = _profile.child2Id;
|
||||
_profile.nodeShortName = _profile.child2ShortName;
|
||||
_profile.posNo = `${_profile.child2ShortName} ${_numPart}`;
|
||||
} else if (_profile.child1Id != null) {
|
||||
_profile.node = 1;
|
||||
_profile.nodeId = _profile.child1Id;
|
||||
_profile.nodeShortName = _profile.child1ShortName;
|
||||
_profile.posNo = `${_profile.child1ShortName} ${_numPart}`;
|
||||
} else if (_profile.rootId != null) {
|
||||
_profile.node = 0;
|
||||
_profile.nodeId = _profile.rootId;
|
||||
_profile.nodeShortName = _profile.rootShortName;
|
||||
_profile.posNo = `${_profile.rootShortName} ${_numPart}`;
|
||||
}
|
||||
return new HttpSuccess(_profile);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue