Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
arunas-smala committed Nov 5, 2024
1 parent 256364c commit 5e27957
Showing 1 changed file with 18 additions and 6 deletions.
24 changes: 18 additions & 6 deletions services/users.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -497,16 +497,28 @@ export default class UsersService extends moleculer.Service {

@Action({
params: {
id: {
type: 'number',
convert: true,
},
id: [
{
type: 'array',
items: 'number|convert',
},
'number|convert',
],
mapping: 'boolean|default:false',
},
})
async getVisibleUserGroups(
ctx: Context<{ id: number; populate?: string }, AppAuthMeta & UserAuthMeta>,
ctx: Context<
{ id: number | number[]; populate?: string; mapping?: boolean },
AppAuthMeta & UserAuthMeta
>,
) {
const { id, populate } = ctx.params;
const { id, populate, mapping } = ctx.params;

if (mapping) {
// TODO:
}

const query: any = {
user: id,
};
Expand Down

0 comments on commit 5e27957

Please sign in to comment.