Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wiki-js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
wiki-js
Commits
22e51c98
You need to sign in or sign up before continuing.
Commit
22e51c98
authored
Sep 01, 2019
by
Nick
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: tags load from editor
parent
5a7fd2d7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletion
+4
-1
common.js
server/controllers/common.js
+3
-0
editor.pug
server/views/editor.pug
+1
-1
No files found.
server/controllers/common.js
View file @
22e51c98
...
@@ -71,6 +71,9 @@ router.get(['/e', '/e/*'], async (req, res, next) => {
...
@@ -71,6 +71,9 @@ router.get(['/e', '/e/*'], async (req, res, next) => {
return
res
.
render
(
'unauthorized'
,
{
action
:
'edit'
})
return
res
.
render
(
'unauthorized'
,
{
action
:
'edit'
})
}
}
await
page
.
$relatedQuery
(
'tags'
)
page
.
tags
=
_
.
map
(
page
.
tags
,
'tag'
)
_
.
set
(
res
.
locals
,
'pageMeta.title'
,
`Edit
${
page
.
title
}
`
)
_
.
set
(
res
.
locals
,
'pageMeta.title'
,
`Edit
${
page
.
title
}
`
)
_
.
set
(
res
.
locals
,
'pageMeta.description'
,
page
.
description
)
_
.
set
(
res
.
locals
,
'pageMeta.description'
,
page
.
description
)
page
.
mode
=
'update'
page
.
mode
=
'update'
...
...
server/views/editor.pug
View file @
22e51c98
...
@@ -12,7 +12,7 @@ block body
...
@@ -12,7 +12,7 @@ block body
path=page.path
path=page.path
title=page.title
title=page.title
description=page.description
description=page.description
tags=page.tags
:
tags=page.tags
:is-published=page.isPublished
:is-published=page.isPublished
init-mode=page.mode
init-mode=page.mode
init-editor=page.editorKey
init-editor=page.editorKey
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment