mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
User creations logic in comments.
This commit is contained in:
parent
c2c03d1032
commit
f3cd722e9f
@ -32,6 +32,13 @@ export class AdminResolver {
|
||||
// TODO: Check user validity
|
||||
const userRepository = getCustomRepository(UserRepository)
|
||||
const user = await userRepository.findByEmail(email)
|
||||
// TODO: Check user open creation state (Open creation)
|
||||
// SELECT * FROM transaction_creations WHERE state_user_id = loginUser.id AND target_date > Date - 2 Monat
|
||||
// SELECT * FROM pending_creations WHERE userId = loginUser.id
|
||||
// COUNT amount from 2 tables
|
||||
// if amount < 3000 => Store in pending_creations
|
||||
const creations = getUserCreations(user.id)
|
||||
// UserAdmin.creations()
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user