check workflow
This commit is contained in:
parent
e3e6a1df36
commit
a4647e102a
14 changed files with 84 additions and 73 deletions
|
|
@ -230,18 +230,18 @@ export class kpiCapacityController extends Controller {
|
|||
@Get("group")
|
||||
async GetKpiCapacityTypeGROUP(@Query("positionName") positionName: string) {
|
||||
let position = await this.positionRepository.findOne({
|
||||
where: {
|
||||
where: {
|
||||
name: Like(`${positionName}`),
|
||||
kpiLink: Not(IsNull()) || Not("")
|
||||
kpiLink: Not(IsNull()) || Not(""),
|
||||
},
|
||||
relations: ["kpiLink", "kpiLink.kpiCapacitys"],
|
||||
});
|
||||
|
||||
if (position == null) {
|
||||
position = await this.positionRepository.findOne({
|
||||
where: {
|
||||
name: "นักจัดการงานทั่วไป",
|
||||
kpiLink: Not(IsNull()) || Not("")
|
||||
where: {
|
||||
name: "นักจัดการงานทั่วไป",
|
||||
kpiLink: Not(IsNull()) || Not(""),
|
||||
},
|
||||
relations: ["kpiLink", "kpiLink.kpiCapacitys"],
|
||||
});
|
||||
|
|
@ -310,7 +310,8 @@ export class kpiCapacityController extends Controller {
|
|||
],
|
||||
})
|
||||
async GetKpiCapacityByIdEdit(@Request() request: RequestWithUser, @Path() id: string) {
|
||||
let _data = await new permission().PermissionGet(request, "SYS_EVA_COMPETENCY");
|
||||
let _workflow = await new permission().Workflow(request, id, "SYS_EVA_COMPETENCY");
|
||||
if (_workflow == false) await new permission().PermissionGet(request, "SYS_EVA_COMPETENCY");
|
||||
const kpiCapacity = await this.kpiCapacityRepository.findOne({
|
||||
where: { id: id },
|
||||
select: ["type", "name", "description"],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue