Toggle navigation
Toggle navigation
This project
Loading...
Sign in
2020-1-capstone-design1
/
Triz_Project1
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
1
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
sdy
2020-04-26 18:40:17 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
965b19c6594c1fcdbdaa19aa594f6b5405118213
965b19c6
1 parent
e179a033
create deleteUser
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
0 deletions
back/src/api/User/deleteUser/deleteUser.graphql
back/src/api/User/deleteUser/deleteUser.js
back/src/api/User/deleteUser/deleteUser.graphql
0 → 100644
View file @
965b19c
type Mutation {
deleteUser(email: String!): Boolean!
}
back/src/api/User/deleteUser/deleteUser.js
0 → 100644
View file @
965b19c
import
{
isAuthenticated
,
prisma
}
from
"../../../utils"
;
export
default
{
Mutation
:
{
deleteUser
:
async
(
_
,
args
,
{
request
})
=>
{
isAuthenticated
(
request
);
const
{
email
}
=
args
;
return
prisma
.
user
.
delete
({
where
:
{
email
,
},
});
},
},
};
Please
register
or
login
to post a comment