mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-09 11:17:43 +02:00
list accounts (#733)
Signed-off-by: Andrey Platov <andrey@hardcoreeng.com>
This commit is contained in:
+12
-1
@@ -22,7 +22,8 @@ import {
|
||||
dropAccount,
|
||||
dropWorkspace,
|
||||
getAccount,
|
||||
listWorkspaces
|
||||
listWorkspaces,
|
||||
listAccounts
|
||||
} from '@anticrm/account'
|
||||
import contact, { combineName } from '@anticrm/contact'
|
||||
import core, { TxOperations } from '@anticrm/core'
|
||||
@@ -187,6 +188,16 @@ program
|
||||
})
|
||||
})
|
||||
|
||||
program
|
||||
.command('show-accounts')
|
||||
.description('Show accounts')
|
||||
.action(async () => {
|
||||
return await withDatabase(mongodbUri, async (db) => {
|
||||
const accountsJSON = JSON.stringify(await listAccounts(db), null, 2)
|
||||
console.info(accountsJSON)
|
||||
})
|
||||
})
|
||||
|
||||
program
|
||||
.command('drop-account <name>')
|
||||
.description('drop account')
|
||||
|
||||
Reference in New Issue
Block a user