ออกคำสั่ง
This commit is contained in:
parent
63ed0534d0
commit
3f3ec27abd
8 changed files with 268 additions and 19 deletions
|
|
@ -1329,10 +1329,10 @@ export class CommandController extends Controller {
|
|||
persons: {
|
||||
refId: string;
|
||||
profileId?: string | null;
|
||||
citizenId: string;
|
||||
prefix: string;
|
||||
firstName: string;
|
||||
lastName: string;
|
||||
citizenId: string | null;
|
||||
prefix: string | null;
|
||||
firstName: string | null;
|
||||
lastName: string | null;
|
||||
}[];
|
||||
},
|
||||
@Request() request: RequestWithUser,
|
||||
|
|
@ -2704,6 +2704,14 @@ export class CommandController extends Controller {
|
|||
}[];
|
||||
},
|
||||
) {
|
||||
const posMasters = await this.posMasterActRepository.find({
|
||||
where: { id: In(body.refIds.map((x) => x.refId)) },
|
||||
});
|
||||
const data = posMasters.map((_data) => ({
|
||||
..._data,
|
||||
statusReport: "PENDING",
|
||||
}));
|
||||
await this.posMasterActRepository.save(data);
|
||||
return new HttpSuccess();
|
||||
}
|
||||
@Post("command40/officer/report")
|
||||
|
|
@ -2714,12 +2722,12 @@ export class CommandController extends Controller {
|
|||
refIds: string[];
|
||||
},
|
||||
) {
|
||||
// const profile = await this.profileEmployeeRepository.find({ where: { id: In(body.refIds) } });
|
||||
// const data = profile.map((_data) => ({
|
||||
// ..._data,
|
||||
// statusTemp: "DONE",
|
||||
// }));
|
||||
// await this.profileEmployeeRepository.save(data);
|
||||
const posMasters = await this.posMasterActRepository.find({ where: { id: In(body.refIds) } });
|
||||
const data = posMasters.map((_data) => ({
|
||||
..._data,
|
||||
statusReport: "REPORT",
|
||||
}));
|
||||
await this.posMasterActRepository.save(data);
|
||||
return new HttpSuccess();
|
||||
}
|
||||
@Post("command40/officer/delete")
|
||||
|
|
@ -2730,12 +2738,12 @@ export class CommandController extends Controller {
|
|||
refIds: string[];
|
||||
},
|
||||
) {
|
||||
// const profile = await this.profileEmployeeRepository.find({ where: { id: In(body.refIds) } });
|
||||
// const data = profile.map((_data) => ({
|
||||
// ..._data,
|
||||
// statusTemp: "WAITTING",
|
||||
// }));
|
||||
// await this.profileEmployeeRepository.save(data);
|
||||
const posMasters = await this.posMasterActRepository.find({ where: { id: In(body.refIds) } });
|
||||
const data = posMasters.map((_data) => ({
|
||||
..._data,
|
||||
statusReport: "PENDING",
|
||||
}));
|
||||
await this.posMasterActRepository.save(data);
|
||||
return new HttpSuccess();
|
||||
}
|
||||
@Post("command40/officer/report/attachment")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue