|
|
@ -1,3 +1,5 @@ |
|
|
|
|
|
|
|
import { DELETED } from '../../consts'; |
|
|
|
|
|
|
|
|
|
|
|
import buildGetRequestHandler from '../buildGetRequestHandler'; |
|
|
|
import buildGetRequestHandler from '../buildGetRequestHandler'; |
|
|
|
import { buildQueryResultReducer } from '../../buildQueryResultModifier'; |
|
|
|
import { buildQueryResultReducer } from '../../buildQueryResultModifier'; |
|
|
|
|
|
|
|
|
|
|
@ -8,7 +10,7 @@ export const getUser = buildGetRequestHandler((request, buildQueryOptions) => { |
|
|
|
let condLimitRegular = ''; |
|
|
|
let condLimitRegular = ''; |
|
|
|
|
|
|
|
|
|
|
|
if (sessionUserName !== 'admin') { |
|
|
|
if (sessionUserName !== 'admin') { |
|
|
|
condLimitRegular = `WHERE user_uuid = '${sessionUserUuid}'`; |
|
|
|
condLimitRegular = `AND user_uuid = '${sessionUserUuid}'`; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const query = ` |
|
|
|
const query = ` |
|
|
@ -16,6 +18,7 @@ export const getUser = buildGetRequestHandler((request, buildQueryOptions) => { |
|
|
|
a.user_name, |
|
|
|
a.user_name, |
|
|
|
a.user_uuid |
|
|
|
a.user_uuid |
|
|
|
FROM users AS a |
|
|
|
FROM users AS a |
|
|
|
|
|
|
|
WHERE a.user_algorithm != '${DELETED}' |
|
|
|
${condLimitRegular};`;
|
|
|
|
${condLimitRegular};`;
|
|
|
|
|
|
|
|
|
|
|
|
const afterQueryReturn: QueryResultModifierFunction | undefined = |
|
|
|
const afterQueryReturn: QueryResultModifierFunction | undefined = |
|
|
|