Merge branch 'develop' of github.com:Frappet/bma-ehr-organization into develop
This commit is contained in:
commit
0d1734f497
1 changed files with 23 additions and 3 deletions
|
|
@ -1603,9 +1603,29 @@ export class CommandController extends Controller {
|
||||||
let commandRecive = new CommandRecive();
|
let commandRecive = new CommandRecive();
|
||||||
commandRecive = Object.assign(new CommandRecive(), item);
|
commandRecive = Object.assign(new CommandRecive(), item);
|
||||||
commandRecive.order = order;
|
commandRecive.order = order;
|
||||||
// commandRecive.amount = "xxxxxxxxxx";
|
let salaryData = null_;
|
||||||
// commandRecive.positionSalaryAmount = "xxxxxxxxxx";
|
if(item.profileId){
|
||||||
// commandRecive.mouthSalaryAmount = "xxxxxxxxxx";
|
salaryData = await this.profileRepository.findOne({
|
||||||
|
where: {
|
||||||
|
id: item.profileId
|
||||||
|
}
|
||||||
|
});
|
||||||
|
let null_: any = 0;
|
||||||
|
if (!salaryData) {
|
||||||
|
salaryData = await this.profileEmployeeRepository.findOne({
|
||||||
|
where: {
|
||||||
|
id: item.profileId
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
commandRecive.amount = salaryData ? salaryData.amount : null_;
|
||||||
|
commandRecive.positionSalaryAmount = salaryData ? salaryData.positionSalaryAmount : null_;
|
||||||
|
commandRecive.mouthSalaryAmount = salaryData ? salaryData.mouthSalaryAmount : null_;
|
||||||
|
}else{
|
||||||
|
commandRecive.amount = null_;
|
||||||
|
commandRecive.positionSalaryAmount = null_;
|
||||||
|
commandRecive.mouthSalaryAmount = null_;
|
||||||
|
}
|
||||||
commandRecive.remarkVertical =
|
commandRecive.remarkVertical =
|
||||||
item.remarkVertical == null ? null_ : item.remarkVertical;
|
item.remarkVertical == null ? null_ : item.remarkVertical;
|
||||||
commandRecive.remarkHorizontal =
|
commandRecive.remarkHorizontal =
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue