update
This commit is contained in:
@ -313,7 +313,9 @@ class PrAdapter extends Adapter{
|
||||
async queryPrList(req,callback){
|
||||
var apires = this.getApiResultDefined();
|
||||
try {
|
||||
|
||||
const proc_nik = process.env.PROC_USER_NIK ?? ""
|
||||
const proc_users = proc_nik.split(",")
|
||||
|
||||
let limit = req.body.limit;
|
||||
let offset = req.body.offset;
|
||||
let keyword = req.body.keyword;
|
||||
@ -326,7 +328,9 @@ class PrAdapter extends Adapter{
|
||||
|
||||
let swherenik="";
|
||||
if(nik){
|
||||
swherenik="iby='"+nik+"' and ";
|
||||
if (!proc_users.includes(nik)) {
|
||||
swherenik = '(iby="'+nik+' or nikapproval="'+nik+'") and ';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -478,6 +482,8 @@ class PrAdapter extends Adapter{
|
||||
async queryPrManagementList(req,callback){
|
||||
var apires = this.getApiResultDefined();
|
||||
try {
|
||||
const proc_nik = process.env.PROC_USER_NIK ?? ""
|
||||
const proc_users = proc_nik.split(",")
|
||||
|
||||
let limit = req.query.limit;
|
||||
let offset = req.query.offset;
|
||||
@ -485,7 +491,7 @@ class PrAdapter extends Adapter{
|
||||
let nik = req.query.nik;
|
||||
|
||||
let swherenik="and iby='"+nik+"'";
|
||||
if(nik=='999999'){
|
||||
if (!proc_users.includes(nik)) {
|
||||
swherenik="";
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user