Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
solo-1
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
solo-1
Commits
d063bde7
Unverified
Commit
d063bde7
authored
Apr 18, 2019
by
Liang Ding
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '3.6.0-dev' of
https://github.com/b3log/solo
into 3.6.0-dev
parents
77827a43
7f5cea3d
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
9 additions
and
95 deletions
+9
-95
src/main/resources/lang_en_US.properties
src/main/resources/lang_en_US.properties
+0
-2
src/main/resources/lang_zh_CN.properties
src/main/resources/lang_zh_CN.properties
+0
-2
src/main/webapp/admin/admin-page-list.ftl
src/main/webapp/admin/admin-page-list.ftl
+1
-9
src/main/webapp/js/admin/editor.js
src/main/webapp/js/admin/editor.js
+0
-1
src/main/webapp/js/admin/pageList.js
src/main/webapp/js/admin/pageList.js
+4
-69
src/main/webapp/js/page.js
src/main/webapp/js/page.js
+3
-7
src/main/webapp/scss/admin.scss
src/main/webapp/scss/admin.scss
+0
-4
src/main/webapp/skins
src/main/webapp/skins
+1
-1
No files found.
src/main/resources/lang_en_US.properties
View file @
d063bde7
...
@@ -88,8 +88,6 @@ markdownHelpLabel=<dl><dt>Headings</dt><dd> # First-level heading</dd><dd> ####
...
@@ -88,8 +88,6 @@ markdownHelpLabel=<dl><dt>Headings</dt><dd> # First-level heading</dd><dd> ####
<dl><dt>Image</dt><dd></dd></dl>
\
<dl><dt>Image</dt><dd></dd></dl>
\
<dl><dt><a href='http://daringfireball.net/projects/markdown/syntax' target='_blank'>All Grammar</a></dt></dl>
<dl><dt><a href='http://daringfireball.net/projects/markdown/syntax' target='_blank'>All Grammar</a></dt></dl>
editType1Label
=
Editor Type:
editType1Label
=
Editor Type:
pageLinkLabel
=
Link
type1Label
=
Type:
typeLabel
=
Type
typeLabel
=
Type
onlineVisitor1Label
=
Online Visitors:
onlineVisitor1Label
=
Online Visitors:
noDataLabel
=
Lazy guy, has nothing!
noDataLabel
=
Lazy guy, has nothing!
...
...
src/main/resources/lang_zh_CN.properties
View file @
d063bde7
...
@@ -88,8 +88,6 @@ markdownHelpLabel=<dl><dt>\u6807\u9898</dt><dd> # \u4E00\u7EA7\u6807\u9898</dd><
...
@@ -88,8 +88,6 @@ markdownHelpLabel=<dl><dt>\u6807\u9898</dt><dd> # \u4E00\u7EA7\u6807\u9898</dd><
<dl><dt>
\u
56FE
\u7247
</dt><dd></dd></dl>
\
<dl><dt>
\u
56FE
\u7247
</dt><dd></dd></dl>
\
<dl><dt><a href='http://daringfireball.net/projects/markdown/syntax' target='_blank'>
\u
5B8C
\u6574\u
8BED
\u
6CD5</a></dt></dl>
<dl><dt><a href='http://daringfireball.net/projects/markdown/syntax' target='_blank'>
\u
5B8C
\u6574\u
8BED
\u
6CD5</a></dt></dl>
editType1Label
=
\u
7F16
\u
8F91
\u5668\u
7C7B
\u
578B
\u
FF1A
editType1Label
=
\u
7F16
\u
8F91
\u5668\u
7C7B
\u
578B
\u
FF1A
pageLinkLabel
=
\u
94FE
\u
63A5
type1Label
=
\u
7C7B
\u
578B
\u
FF1A
typeLabel
=
\u
7C7B
\u
578B
typeLabel
=
\u
7C7B
\u
578B
onlineVisitor1Label
=
\u
5F53
\u
524D
\u
8BBF
\u
5BA2
\u
FF1A
onlineVisitor1Label
=
\u
5F53
\u
524D
\u
8BBF
\u
5BA2
\u
FF1A
noDataLabel
=
\u
8BE5
\u5217\u8868\u
5F88
\u
61D2
\u
FF0C
\u
4EC0
\u
4E48
\u
90FD
\u
6CA1
\u6709\u7559\u
4E0B
\u3002\u3002\u3002
noDataLabel
=
\u
8BE5
\u5217\u8868\u
5F88
\u
61D2
\u
FF0C
\u
4EC0
\u
4E48
\u
90FD
\u
6CA1
\u6709\u7559\u
4E0B
\u3002\u3002\u3002
...
...
src/main/webapp/admin/admin-page-list.ftl
View file @
d063bde7
...
@@ -44,15 +44,7 @@
...
@@ -44,15 +44,7 @@
<option value="_blank">${targetBlankLabel}</option>
<option value="_blank">${targetBlankLabel}</option>
<option value="_parent">${targetParentLabel}</option>
<option value="_parent">${targetParentLabel}</option>
<option value="_top">${targetTopLabel}</option>
<option value="_top">${targetTopLabel}</option>
</select>
</select>
<label class="page-list__label">${type1Label}</label>
<button data-type="link" class="selected fn-type">${pageLinkLabel}</button>
<button data-type="page" class="fn-type">${pageLabel}</button>
</div>
<div id="pagePagePanel" class="fn__none">
<div id="pageContent" style="height: 430px;width: 100%;" name="pageContent"></div>
<label>${allowComment1Label}</label>
<input type="checkbox" id="pageCommentable" checked="checked" />
</div>
</div>
<div class="fn__right">
<div class="fn__right">
<button onclick="admin.pageList.submit();">${saveLabel}</button>
<button onclick="admin.pageList.submit();">${saveLabel}</button>
...
...
src/main/webapp/js/admin/editor.js
View file @
d063bde7
...
@@ -104,4 +104,3 @@ $.extend(SoloEditor.prototype, {
...
@@ -104,4 +104,3 @@ $.extend(SoloEditor.prototype, {
admin
.
editors
.
articleEditor
=
{}
admin
.
editors
.
articleEditor
=
{}
admin
.
editors
.
abstractEditor
=
{}
admin
.
editors
.
abstractEditor
=
{}
admin
.
editors
.
pageEditor
=
{}
src/main/webapp/js/admin/pageList.js
View file @
d063bde7
...
@@ -32,7 +32,6 @@ admin.pageList = {
...
@@ -32,7 +32,6 @@ admin.pageList = {
currentPage
:
1
currentPage
:
1
},
},
id
:
""
,
id
:
""
,
type
:
"
link
"
,
/*
/*
* 初始化 table, pagination, comments dialog
* 初始化 table, pagination, comments dialog
*/
*/
...
@@ -57,11 +56,6 @@ admin.pageList = {
...
@@ -57,11 +56,6 @@ admin.pageList = {
text
:
Label
.
openMethodLabel
,
text
:
Label
.
openMethodLabel
,
index
:
"
pageTarget
"
,
index
:
"
pageTarget
"
,
width
:
120
width
:
120
},
{
style
:
"
padding-left: 12px;
"
,
text
:
Label
.
typeLabel
,
index
:
"
pageType
"
,
width
:
80
},
{
},
{
text
:
Label
.
commentLabel
,
text
:
Label
.
commentLabel
,
index
:
"
comments
"
,
index
:
"
comments
"
,
...
@@ -71,29 +65,6 @@ admin.pageList = {
...
@@ -71,29 +65,6 @@ admin.pageList = {
this
.
tablePagination
.
initPagination
();
this
.
tablePagination
.
initPagination
();
this
.
tablePagination
.
initCommentsDialog
();
this
.
tablePagination
.
initCommentsDialog
();
this
.
getList
(
page
);
this
.
getList
(
page
);
admin
.
editors
.
pageEditor
=
new
SoloEditor
({
id
:
"
pageContent
"
});
// select type
$
(
"
.fn-type
"
).
click
(
function
()
{
var
$it
=
$
(
this
);
if
(
$it
.
hasClass
(
"
selected
"
))
{
return
;
}
$
(
"
.fn-type
"
).
removeClass
(
"
selected
"
);
$it
.
addClass
(
"
selected
"
);
admin
.
pageList
.
type
=
$it
.
data
(
"
type
"
);
if
(
admin
.
pageList
.
type
===
"
page
"
)
{
$
(
"
#pagePagePanel
"
).
slideDown
();
}
else
{
$
(
"
#pagePagePanel
"
).
slideUp
();
}
});
},
},
/*
/*
* 根据当前页码获取列表
* 根据当前页码获取列表
...
@@ -149,7 +120,6 @@ admin.pageList = {
...
@@ -149,7 +120,6 @@ admin.pageList = {
pageData
[
i
].
pagePermalink
=
"
<a class='no-underline' href='
"
+
pages
[
i
].
pagePermalink
+
"
' target='_blank'>
"
pageData
[
i
].
pagePermalink
=
"
<a class='no-underline' href='
"
+
pages
[
i
].
pagePermalink
+
"
' target='_blank'>
"
+
pages
[
i
].
pagePermalink
+
"
</a>
"
;
+
pages
[
i
].
pagePermalink
+
"
</a>
"
;
pageData
[
i
].
pageTarget
=
pages
[
i
].
pageOpenTarget
;
pageData
[
i
].
pageTarget
=
pages
[
i
].
pageOpenTarget
;
pageData
[
i
].
pageType
=
pages
[
i
].
pageType
;
pageData
[
i
].
comments
=
pages
[
i
].
pageCommentCount
;
pageData
[
i
].
comments
=
pages
[
i
].
pageCommentCount
;
pageData
[
i
].
expendRow
=
"
<span><a href='
"
+
pages
[
i
].
pagePermalink
+
"
' target='_blank'>
"
+
Label
.
viewLabel
+
"
</a>
\
pageData
[
i
].
expendRow
=
"
<span><a href='
"
+
pages
[
i
].
pagePermalink
+
"
' target='_blank'>
"
+
Label
.
viewLabel
+
"
</a>
\
<a href='javascript:void(0)' onclick=
\"
admin.pageList.get('
"
+
pages
[
i
].
oId
+
"
')
\"
>
"
+
Label
.
updateLabel
+
"
</a>
\
<a href='javascript:void(0)' onclick=
\"
admin.pageList.get('
"
+
pages
[
i
].
oId
+
"
')
\"
>
"
+
Label
.
updateLabel
+
"
</a>
\
...
@@ -188,15 +158,6 @@ admin.pageList = {
...
@@ -188,15 +158,6 @@ admin.pageList = {
$
(
"
#pagePermalink
"
).
val
(
result
.
page
.
pagePermalink
);
$
(
"
#pagePermalink
"
).
val
(
result
.
page
.
pagePermalink
);
$
(
"
#pageTarget
"
).
val
(
result
.
page
.
pageOpenTarget
);
$
(
"
#pageTarget
"
).
val
(
result
.
page
.
pageOpenTarget
);
$
(
"
#pageIcon
"
).
val
(
result
.
page
.
pageIcon
);
$
(
"
#pageIcon
"
).
val
(
result
.
page
.
pageIcon
);
if
(
result
.
page
.
pageType
===
"
page
"
)
{
$
(
$
(
"
.fn-type
"
).
get
(
1
)).
click
();
}
else
{
$
(
$
(
"
.fn-type
"
).
get
(
0
)).
click
();
}
$
(
"
#pageCommentable
"
).
prop
(
"
checked
"
,
result
.
page
.
pageCommentable
);
admin
.
editors
.
pageEditor
.
setContent
(
result
.
page
.
pageContent
);
$
(
"
#loadMsg
"
).
text
(
""
);
$
(
"
#loadMsg
"
).
text
(
""
);
}
}
});
});
...
@@ -249,20 +210,12 @@ admin.pageList = {
...
@@ -249,20 +210,12 @@ admin.pageList = {
$
(
"
#loadMsg
"
).
text
(
Label
.
loadingLabel
);
$
(
"
#loadMsg
"
).
text
(
Label
.
loadingLabel
);
$
(
"
#tipMsg
"
).
text
(
""
);
$
(
"
#tipMsg
"
).
text
(
""
);
var
pageContent
=
admin
.
editors
.
pageEditor
.
getContent
();
var
pagePermalink
=
Util
.
proessURL
(
$
(
"
#pagePermalink
"
).
val
().
replace
(
/
(
^
\s
*
)
|
(\s
*$
)
/g
,
""
));
var
pagePermalink
=
$
(
"
#pagePermalink
"
).
val
().
replace
(
/
(
^
\s
*
)
|
(\s
*$
)
/g
,
""
);
if
(
admin
.
pageList
.
type
===
"
link
"
)
{
pagePermalink
=
Util
.
proessURL
(
pagePermalink
);
}
var
requestJSONObject
=
{
var
requestJSONObject
=
{
"
page
"
:
{
"
page
"
:
{
"
pageTitle
"
:
$
(
"
#pageTitle
"
).
val
(),
"
pageTitle
"
:
$
(
"
#pageTitle
"
).
val
(),
"
pageContent
"
:
pageContent
,
"
pagePermalink
"
:
pagePermalink
,
"
pagePermalink
"
:
pagePermalink
,
"
pageCommentable
"
:
$
(
"
#pageCommentable
"
).
prop
(
"
checked
"
),
"
pageType
"
:
admin
.
pageList
.
type
,
"
pageOpenTarget
"
:
$
(
"
#pageTarget
"
).
val
(),
"
pageOpenTarget
"
:
$
(
"
#pageTarget
"
).
val
(),
"
pageIcon
"
:
$
(
"
#pageIcon
"
).
val
()
"
pageIcon
"
:
$
(
"
#pageIcon
"
).
val
()
}
}
...
@@ -284,11 +237,7 @@ admin.pageList = {
...
@@ -284,11 +237,7 @@ admin.pageList = {
$
(
"
#pagePermalink
"
).
val
(
""
);
$
(
"
#pagePermalink
"
).
val
(
""
);
$
(
"
#pageTitle
"
).
val
(
""
);
$
(
"
#pageTitle
"
).
val
(
""
);
$
(
"
#pageIcon
"
).
val
(
""
);
$
(
"
#pageIcon
"
).
val
(
""
);
$
(
"
#pageCommentable
"
).
prop
(
"
cheked
"
,
false
);
$
(
"
#pageTarget
"
).
val
(
"
_self
"
);
$
(
"
#pageTarget
"
).
val
(
"
_self
"
);
$
(
$
(
"
.fn-type
"
).
get
(
0
)).
click
();
admin
.
editors
.
pageEditor
.
setContent
(
""
);
if
(
admin
.
pageList
.
pageInfo
.
currentCount
===
Label
.
PAGE_SIZE
&&
if
(
admin
.
pageList
.
pageInfo
.
currentCount
===
Label
.
PAGE_SIZE
&&
admin
.
pageList
.
pageInfo
.
currentPage
===
admin
.
pageList
.
pageInfo
.
pageCount
)
{
admin
.
pageList
.
pageInfo
.
currentPage
===
admin
.
pageList
.
pageInfo
.
pageCount
)
{
...
@@ -314,22 +263,14 @@ admin.pageList = {
...
@@ -314,22 +263,14 @@ admin.pageList = {
$
(
"
#loadMsg
"
).
text
(
Label
.
loadingLabel
);
$
(
"
#loadMsg
"
).
text
(
Label
.
loadingLabel
);
$
(
"
#tipMsg
"
).
text
(
""
);
$
(
"
#tipMsg
"
).
text
(
""
);
var
pageContent
=
admin
.
editors
.
pageEditor
.
getContent
();
var
pagePermalink
=
Util
.
proessURL
(
$
(
"
#pagePermalink
"
).
val
().
replace
(
/
(
^
\s
*
)
|
(\s
*$
)
/g
,
""
));
var
pagePermalink
=
$
(
"
#pagePermalink
"
).
val
().
replace
(
/
(
^
\s
*
)
|
(\s
*$
)
/g
,
""
);
if
(
admin
.
pageList
.
type
===
"
link
"
)
{
pagePermalink
=
Util
.
proessURL
(
pagePermalink
);
}
var
requestJSONObject
=
{
var
requestJSONObject
=
{
"
page
"
:
{
"
page
"
:
{
"
pageTitle
"
:
$
(
"
#pageTitle
"
).
val
(),
"
pageTitle
"
:
$
(
"
#pageTitle
"
).
val
(),
"
oId
"
:
this
.
id
,
"
oId
"
:
this
.
id
,
"
pageContent
"
:
pageContent
,
"
pagePermalink
"
:
pagePermalink
,
"
pagePermalink
"
:
pagePermalink
,
"
pageCommentable
"
:
$
(
"
#pageCommentable
"
).
prop
(
"
checked
"
),
"
pageType
"
:
admin
.
pageList
.
type
,
"
pageOpenTarget
"
:
$
(
"
#pageTarget
"
).
val
(),
"
pageOpenTarget
"
:
$
(
"
#pageTarget
"
).
val
(),
"
pageIcon
"
:
$
(
"
#pageIcon
"
).
val
()
"
pageIcon
"
:
$
(
"
#pageIcon
"
).
val
()
}
}
...
@@ -353,12 +294,7 @@ admin.pageList = {
...
@@ -353,12 +294,7 @@ admin.pageList = {
$
(
"
#pageTitle
"
).
val
(
""
);
$
(
"
#pageTitle
"
).
val
(
""
);
$
(
"
#pageIcon
"
).
val
(
""
);
$
(
"
#pageIcon
"
).
val
(
""
);
$
(
"
#pagePermalink
"
).
val
(
""
);
$
(
"
#pagePermalink
"
).
val
(
""
);
$
(
"
#pageCommentable
"
).
prop
(
"
cheked
"
,
false
);
$
(
"
#pageTarget
"
).
val
(
"
_self
"
);
$
(
"
#pageTarget
"
).
val
(
"
_self
"
);
$
(
$
(
"
.fn-type
"
).
get
(
0
)).
click
();
admin
.
editors
.
pageEditor
.
setContent
(
""
);
$
(
"
#loadMsg
"
).
text
(
""
);
$
(
"
#loadMsg
"
).
text
(
""
);
}
}
});
});
...
@@ -371,8 +307,7 @@ admin.pageList = {
...
@@ -371,8 +307,7 @@ admin.pageList = {
if
(
$
(
"
#pageTitle
"
).
val
().
replace
(
/
\s
/g
,
""
)
===
""
)
{
if
(
$
(
"
#pageTitle
"
).
val
().
replace
(
/
\s
/g
,
""
)
===
""
)
{
$
(
"
#tipMsg
"
).
text
(
Label
.
titleEmptyLabel
);
$
(
"
#tipMsg
"
).
text
(
Label
.
titleEmptyLabel
);
$
(
"
#pageTitle
"
).
focus
();
$
(
"
#pageTitle
"
).
focus
();
}
else
if
(
admin
.
pageList
.
type
===
"
link
"
&&
}
else
if
(
$
(
"
#pagePermalink
"
).
val
().
replace
(
/
\s
/g
,
""
)
===
""
)
{
$
(
"
#pagePermalink
"
).
val
().
replace
(
/
\s
/g
,
""
)
===
""
)
{
$
(
"
#tipMsg
"
).
text
(
Label
.
linkEmptyLabel
);
$
(
"
#tipMsg
"
).
text
(
Label
.
linkEmptyLabel
);
}
else
{
}
else
{
return
true
;
return
true
;
...
...
src/main/webapp/js/page.js
View file @
d063bde7
...
@@ -20,7 +20,7 @@
...
@@ -20,7 +20,7 @@
*
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 2.2.0.
2, Apr 2
, 2019
* @version 2.2.0.
3, Apr 18
, 2019
*/
*/
var
Page
=
function
(
tips
)
{
var
Page
=
function
(
tips
)
{
this
.
currentCommentId
=
''
this
.
currentCommentId
=
''
...
@@ -322,11 +322,7 @@ $.extend(Page.prototype, {
...
@@ -322,11 +322,7 @@ $.extend(Page.prototype, {
*/
*/
submitComment
:
function
()
{
submitComment
:
function
()
{
var
that
=
this
,
var
that
=
this
,
tips
=
this
.
tips
,
tips
=
this
.
tips
type
=
'
article
'
if
(
tips
.
externalRelevantArticlesDisplayCount
===
undefined
)
{
type
=
'
page
'
}
if
(
vditor
.
getValue
().
length
>
1
&&
vditor
.
getValue
().
length
<
500
)
{
if
(
vditor
.
getValue
().
length
>
1
&&
vditor
.
getValue
().
length
<
500
)
{
$
(
'
#soloEditorAdd
'
).
attr
(
'
disabled
'
,
'
disabled
'
)
$
(
'
#soloEditorAdd
'
).
attr
(
'
disabled
'
,
'
disabled
'
)
...
@@ -341,7 +337,7 @@ $.extend(Page.prototype, {
...
@@ -341,7 +337,7 @@ $.extend(Page.prototype, {
$
.
ajax
({
$
.
ajax
({
type
:
'
POST
'
,
type
:
'
POST
'
,
url
:
Label
.
servePath
+
'
/
'
+
type
+
'
/comments
'
,
url
:
Label
.
servePath
+
'
/
article
/comments
'
,
cache
:
false
,
cache
:
false
,
contentType
:
'
application/json
'
,
contentType
:
'
application/json
'
,
data
:
JSON
.
stringify
(
requestJSONObject
),
data
:
JSON
.
stringify
(
requestJSONObject
),
...
...
src/main/webapp/scss/admin.scss
View file @
d063bde7
...
@@ -558,10 +558,6 @@ button#submitArticle:hover {
...
@@ -558,10 +558,6 @@ button#submitArticle:hover {
border-color
:
#ec6459
;
border-color
:
#ec6459
;
}
}
#pagePagePanel
{
margin-top
:
0
;
}
/* end article */
/* end article */
/* start preference */
/* start preference */
...
...
skins
@
c699f2ff
Subproject commit
0d277a9b0eab083a0daf007f8b9674747182c1b5
Subproject commit
c699f2ff8542bf20f1660b9f981f139745406529
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