Toggle navigation
Toggle navigation
This project
Loading...
Sign in
2020-1-CloudComputing
/
D_Team_Khuloud
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
toror33
2020-06-09 13:59:39 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
34fb07b531fa0d23efdde628b74e0bc5c9b1d61f
34fb07b5
1 parent
9043186a
연락처 삭제
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
1 deletions
backend/routes/contact.js
backend/routes/contact.js
View file @
34fb07b
...
...
@@ -106,7 +106,20 @@ contact_delete : 연락처 삭제 모듈
input : 사용자의 연락처 삭제 요청
output : 연락처 삭제 성공 여부
*/
router
.
get
(
'/contact_delete'
,
function
(
req
,
res
,
next
)
{
router
.
post
(
'/contact_delete'
,
function
(
req
,
res
,
next
)
{
// console.log("req.query",req.query);
var
user_id
=
req
.
query
.
id
;
var
sqlquery
=
"DELETE FROM contact WHERE user_id = ?"
;
connection
.
query
(
sqlquery
,
[
user_id
],
function
(
err
,
rows
)
{
if
(
err
)
{
console
.
log
(
"delete contact failed"
);
throw
err
;
}
else
{
// console.log(rows);s
res
.
status
(
200
).
send
(
"delete"
);
}
});
});
/*
...
...
Please
register
or
login
to post a comment