fix bug #2183
All checks were successful
Build & Deploy on Dev / build (push) Successful in 1m22s
All checks were successful
Build & Deploy on Dev / build (push) Successful in 1m22s
This commit is contained in:
parent
6a07841763
commit
5ef5f7d4ed
2 changed files with 16 additions and 12 deletions
|
|
@ -4040,10 +4040,12 @@ export class CommandController extends Controller {
|
|||
where: { refId: item.resignId },
|
||||
relations: { command: true },
|
||||
});
|
||||
const executeDate = commandResign ? new Date(commandResign.command.commandExcecuteDate).setHours(0,0,0,0) : today;
|
||||
if (_command.status != "REPORTED"
|
||||
&& (_command.status != "WAITING" || today < executeDate)) {
|
||||
await reOrderCommandRecivesAndDelete(commandResign!.refId);
|
||||
const executeDate = commandResign
|
||||
? new Date(commandResign.command.commandExcecuteDate).setHours(0,0,0,0)
|
||||
: today;
|
||||
if (commandResign && _command.status !== "REPORTED" &&
|
||||
(_command.status !== "WAITING" || today < executeDate)) {
|
||||
await reOrderCommandRecivesAndDelete(commandResign!.id);
|
||||
}
|
||||
}
|
||||
let _commandYear = item.commandYear;
|
||||
|
|
@ -4377,6 +4379,7 @@ export class CommandController extends Controller {
|
|||
let _posNumCodeSitAbb: string = "";
|
||||
const _command = await this.commandRepository.findOne({
|
||||
where: { id: body.data.find((x) => x.commandId)?.commandId ?? "" },
|
||||
relations: { commandType: true },
|
||||
});
|
||||
if (_command) {
|
||||
if (_command?.isBangkok?.toLocaleUpperCase() == "OFFICE") {
|
||||
|
|
@ -4438,9 +4441,11 @@ export class CommandController extends Controller {
|
|||
where: { refId: item.resignId },
|
||||
relations: { command: true },
|
||||
});
|
||||
const executeDate = commandResign ? new Date(commandResign.command.commandExcecuteDate).setHours(0,0,0,0) : today;
|
||||
if (_command.status != "REPORTED"
|
||||
&& (_command.status !== "WAITING" || today < executeDate)) {
|
||||
const executeDate = commandResign
|
||||
? new Date(commandResign.command.commandExcecuteDate).setHours(0,0,0,0)
|
||||
: today;
|
||||
if (commandResign && _command.status !== "REPORTED" &&
|
||||
(_command.status !== "WAITING" || today < executeDate)) {
|
||||
await reOrderCommandRecivesAndDelete(commandResign!.id);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue