Toggle navigation
Toggle navigation
This project
Loading...
Sign in
201side
/
floater
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
3
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
robin*
2020-12-09 12:53:35 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
efea6d06a3cb9c5466dd4e762685d7d01f9ce0d1
efea6d06
1 parent
ac337366
스레드에 서브스레드 갯수 추가
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
1 deletions
src/routes/board.js
src/routes/board.js
View file @
efea6d0
...
...
@@ -21,7 +21,7 @@ app.post('/board/:bid/thread', async(req, res) => {
if
(
!
board
)
{
res
.
status
(
404
).
json
({
error
:
'Board not found'
});
}
let
thread
=
await
db
.
get
(
'thread'
).
insert
({
board
:
board
.
_id
,
title
:
req
.
body
.
title
,
content
:
req
.
body
.
content
,
lastUpdated
:
Date
.
now
()});
let
thread
=
await
db
.
get
(
'thread'
).
insert
({
board
:
board
.
_id
,
title
:
req
.
body
.
title
,
content
:
req
.
body
.
content
,
lastUpdated
:
Date
.
now
()
,
count
:
1
});
res
.
json
({
thread
});
});
app
.
get
(
'/borad/:bid/thread/:tid'
,
async
(
req
,
res
)
=>
{
...
...
Please
register
or
login
to post a comment