u
This commit is contained in:
@@ -98,6 +98,7 @@ const MENU = {
|
||||
{ value: 'category.createUnderParent', label: 'createUnderParent', hint: 'googleAuthId, parentId, name → row' },
|
||||
{ value: 'category.delete', label: 'delete', hint: 'googleAuthId, id' },
|
||||
{ value: 'category.getTreeForCompany', label: 'getTreeForCompany', hint: 'googleAuthId, companyId → rows' },
|
||||
{ value: 'category.getCategoryArticles', label: 'getCategoryArticles', hint: 'googleAuthId, categoryId → rows' },
|
||||
],
|
||||
},
|
||||
companyuser: {
|
||||
@@ -340,6 +341,19 @@ async function runMethod(client, action) {
|
||||
await client.category.getTreeForCompany(Number(googleAuthId), Number(companyId)),
|
||||
];
|
||||
}
|
||||
case 'category.getCategoryArticles': {
|
||||
const googleAuthId = await askInt('google_auth id');
|
||||
if (googleAuthId == null) return;
|
||||
const categoryId = await askInt('category id');
|
||||
if (categoryId == null) return;
|
||||
return [
|
||||
'rows',
|
||||
await client.category.getCategoryArticles(
|
||||
Number(googleAuthId),
|
||||
Number(categoryId),
|
||||
),
|
||||
];
|
||||
}
|
||||
case 'companyuser.add': {
|
||||
const companyId = await askInt('Company id');
|
||||
if (companyId == null) return;
|
||||
|
||||
Reference in New Issue
Block a user