fix bug
This commit is contained in:
parent
23b8909706
commit
965984c5c6
1 changed files with 8 additions and 8 deletions
|
|
@ -153,7 +153,7 @@ export class SalaryPeriodController extends Controller {
|
|||
await this.salaryProfileRepository.remove(salaryProfile);
|
||||
|
||||
// หาจำนวน Quota คงเหลือ
|
||||
if (salaryProfile.salaryOrg.snapshot == "SNAP1") {
|
||||
// if (salaryProfile.salaryOrg.snapshot == "SNAP1") {
|
||||
if(salaryProfile.salaryOrg.salaryPeriod.period == "APR"){
|
||||
const amountFullType = await this.salaryProfileRepository.count({
|
||||
where: {
|
||||
|
|
@ -179,7 +179,7 @@ export class SalaryPeriodController extends Controller {
|
|||
salaryProfile.salaryOrg.remainingAmount = calRemainAmount;
|
||||
await this.salaryOrgRepository.save(salaryProfile?.salaryOrg);
|
||||
}
|
||||
}
|
||||
// }
|
||||
|
||||
return new HttpSuccess();
|
||||
}
|
||||
|
|
@ -287,7 +287,7 @@ export class SalaryPeriodController extends Controller {
|
|||
await this.salaryProfileRepository.save(salaryProfile);
|
||||
|
||||
// หาจำนวน Quota คงเหลือ
|
||||
if (salaryProfile.salaryOrg.snapshot == "SNAP1") {
|
||||
// if (salaryProfile.salaryOrg.snapshot == "SNAP1") {
|
||||
if(salaryProfile.salaryOrg.salaryPeriod.period == "APR"){
|
||||
const amountFullType = await this.salaryProfileRepository.count({
|
||||
where: {
|
||||
|
|
@ -313,7 +313,7 @@ export class SalaryPeriodController extends Controller {
|
|||
salaryProfile.salaryOrg.remainingAmount = calRemainAmount;
|
||||
await this.salaryOrgRepository.save(salaryProfile?.salaryOrg);
|
||||
}
|
||||
}
|
||||
// }
|
||||
return new HttpSuccess();
|
||||
}
|
||||
|
||||
|
|
@ -345,7 +345,7 @@ export class SalaryPeriodController extends Controller {
|
|||
await this.salaryProfileRepository.save(salaryProfile);
|
||||
if (salaryOrg) {
|
||||
// หาจำนวน Quota คงเหลือ
|
||||
if (salaryOrg.snapshot == "SNAP1") {
|
||||
// if (salaryOrg.snapshot == "SNAP1") {
|
||||
if(salaryOrg.salaryPeriod.period == "APR"){
|
||||
const amountFullType = await this.salaryProfileRepository.count({
|
||||
where: {
|
||||
|
|
@ -371,7 +371,7 @@ export class SalaryPeriodController extends Controller {
|
|||
salaryOrg.remainingAmount = calRemainAmount;
|
||||
await this.salaryOrgRepository.save(salaryOrg);
|
||||
}
|
||||
}
|
||||
// }
|
||||
}
|
||||
return new HttpSuccess();
|
||||
}
|
||||
|
|
@ -692,7 +692,7 @@ export class SalaryPeriodController extends Controller {
|
|||
await this.salaryProfileRepository.save(salaryProfile);
|
||||
|
||||
// หาจำนวน Quota คงเหลือ
|
||||
if (salaryOrg.snapshot == "SNAP1") {
|
||||
// if (salaryOrg.snapshot == "SNAP1") {
|
||||
if(salaryOrg.salaryPeriod.period == "APR"){
|
||||
const amountFullType = await this.salaryProfileRepository.count({
|
||||
where: {
|
||||
|
|
@ -718,7 +718,7 @@ export class SalaryPeriodController extends Controller {
|
|||
salaryOrg.remainingAmount = calRemainAmount;
|
||||
await this.salaryOrgRepository.save(salaryOrg);
|
||||
}
|
||||
}
|
||||
// }
|
||||
|
||||
return new HttpSuccess(salaryProfile.id);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue