Port current frontend to connections

This commit is contained in:
Chi Vinh Le
2017-08-29 19:06:58 +07:00
parent eb67d86163
commit 87e90e956d
2 changed files with 22 additions and 18 deletions
@@ -77,7 +77,7 @@ export default class Community extends Component {
return (
<div>
<FlaggedAccounts
commenters={users}
commenters={users.nodes}
showBanUserDialog={props.showBanUserDialog}
showSuspendUserDialog={props.showSuspendUserDialog}
showRejectUsernameDialog={props.showRejectUsernameDialog}
@@ -52,26 +52,30 @@ class CommunityContainer extends Component {
export const withCommunityQuery = withQuery(gql`
query CoralAdmin_Community($action_type: ACTION_TYPE) {
users(query:{action_type: $action_type}){
id
username
status
roles
actions{
hasNextPage
endCursor
nodes {
id
created_at
... on FlagAction {
reason
message
user {
id
username
username
status
roles
actions{
id
created_at
... on FlagAction {
reason
message
user {
id
username
}
}
}
}
action_summaries {
count
... on FlagActionSummary {
reason
action_summaries {
count
... on FlagActionSummary {
reason
}
}
}
}