Skip to content

Commit

Permalink
🎨 推送社区需弹框确认 Fix #120
Browse files Browse the repository at this point in the history
  • Loading branch information
88250 committed Jun 24, 2020
1 parent 32bb666 commit 242ee41
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 19 deletions.
2 changes: 1 addition & 1 deletion src/main/resources/js/admin/admin.min.js

Large diffs are not rendered by default.

9 changes: 7 additions & 2 deletions src/main/resources/js/admin/articleList.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { TablePaginate } from './tablePaginate'
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.3.0.2, Jan 10, 2020
* @version 1.3.0.3, Jun 24, 2020
*/

/* article-list 相关操作 */
Expand Down Expand Up @@ -73,12 +73,17 @@ admin.articleList = {
* @param id 文章 id
*/
syncToHacpai: function (id) {
const licenseConfirm = '文章推送社区后将以 署名-相同方式共享 4.0 国际 (CC BY-SA 4.0) (https://creativecommons.org/licenses/by-sa/4.0/deed.zh) 许可协议发布,请确认是否推送?'
if (!confirm(licenseConfirm)) {
return;
}

$.ajax({
url: Label.servePath + '/console/article/push2rhy?id=' + id,
type: 'GET',
cache: false,
success: function (result, textStatus) {
$('#tipMsg').text(Label.pushSuccLabel)
$('#tipMsg').html(Label.pushSuccLabel)
},
})
},
Expand Down
9 changes: 1 addition & 8 deletions src/main/resources/lang_en_US.properties
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ queryUserFailedLabel=Query user info failed
commentContentLabel=Content
cancelLabel=Cancel
langLabel=en_US
pushSuccLabel=Sync completed, please check log for details
pushSuccLabel=After the push request is complete, please check the community's response to this push in the <a href="${servePath}/admin-index.do#tools/others/log" target="_blank">log viewer</a>
pushToHacpaiLabel=Sync to Hacpai
getUploadTokenErrLabel=Get community file storage service upload token failed
startToUseLabel=Start
Expand Down Expand Up @@ -103,13 +103,6 @@ footerContent1Label=Footer:
userAvatar1Label=Avatar:
staticErrorLabel=<h2>Latke Configuraton Error</h2>\
<div style='text-align:center'><br><br><br>Please visit <a target='_blank' href='https://hacpai.com/article/1474087427032'>Latke \u914D\u7F6E\u5256\u6790</a> to solve it.<br><br><br></div>
markdownHelpLabel=<dl><dt>Headings</dt><dd> # First-level heading</dd><dd> #### Fourth-level heading</dd></dl>\
<dl><dt>Link</dt><dd>[link text here](link.address.here)</dd></dl>\
<dl><dt>Emphasized text</dt><dd>*italics* or _italics_</dd><dd>**boldface** or __boldface__</dd><dd>***boldface+italics*** or ___boldface+italics___</dd></dl>\
<dl><dt>List</dt><dt></dt><dd>* An item in an enumerated (unordered)</dd><dd>1. An item in an enumerated (ordered)</dd></dl>\
<dl><dt>Code</dt><dd>`var markDown = undefined`</dd></dl>\
<dl><dt>Image</dt><dd>![alt text](/path/to/img.jpg 'Title')</dd></dl>\
<dl><dt><a href='http://daringfireball.net/projects/markdown/syntax' target='_blank'>All Grammar</a></dt></dl>
editType1Label=Editor Type:
typeLabel=Type
onlineVisitor1Label=Online Visitors:
Expand Down
9 changes: 1 addition & 8 deletions src/main/resources/lang_zh_CN.properties
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ queryUserFailedLabel=\u67E5\u8BE2\u7528\u6237\u4FE1\u606F\u5931\u8D25
commentContentLabel=\u8BC4\u8BBA\u5185\u5BB9
cancelLabel=\u53D6\u6D88
langLabel=zh_CN
pushSuccLabel=\u63A8\u9001\u5B8C\u6BD5\uFF0C\u7EC6\u8282\u8BF7\u67E5\u770B\u65E5\u5FD7
pushSuccLabel=\u63A8\u9001\u8BF7\u6C42\u5B8C\u6BD5\uFF0C\u8BF7\u5728<a href="${servePath}/admin-index.do#tools/others/log" target="_blank">\u65E5\u5FD7\u6D4F\u89C8</a>\u4E2D\u67E5\u770B\u793E\u533A\u5BF9\u672C\u6B21\u63A8\u9001\u7684\u54CD\u5E94\u7ED3\u679C
pushToHacpaiLabel=\u63A8\u9001\u5230\u793E\u533A
getUploadTokenErrLabel=\u83B7\u53D6\u793E\u533A\u6587\u4EF6\u5B58\u50A8\u670D\u52A1\u4E0A\u4F20\u51ED\u8BC1\u5F02\u5E38
startToUseLabel=\u5F00\u59CB\u4F7F\u7528
Expand Down Expand Up @@ -103,13 +103,6 @@ footerContent1Label=\u9875\u811A\uFF1A
userAvatar1Label=\u5934\u50CF\uFF1A
staticErrorLabel=<h2><a href='https://hacpai.com/tag/Latke' target='_blank'>Latke</a> \u914D\u7F6E\u9519\u8BEF</h2>\
<div style='text-align:center'><br><br><br>\u8BF7\u6D4F\u89C8 <a target='_blank' href='https://hacpai.com/article/1474087427032'>Latke \u914D\u7F6E\u5256\u6790</a> \u4EE5\u89E3\u51B3\u8BE5\u95EE\u9898\u3002<br><br><br></div>
markdownHelpLabel=<dl><dt>\u6807\u9898</dt><dd> # \u4E00\u7EA7\u6807\u9898</dd><dd> #### \u56DB\u7EA7\u6807\u9898</dd></dl>\
<dl><dt>\u94FE\u63A5</dt><dd>[\u94FE\u63A5\u6587\u5B57](\u94FE\u63A5\u5730\u5740)</dd></dl>\
<dl><dt>\u5F3A\u8C03</dt><dd>*\u659C\u4F53* \u6216\u8005 _\u659C\u4F53_</dd><dd>**\u7C97\u4F53** \u6216\u8005 __\u7C97\u4F53__</dd><dd>***\u7C97\u4F53+\u659C\u4F53*** \u6216\u8005 ___\u7C97\u4F53+\u659C\u4F53___</dd></dl>\
<dl><dt>\u5217\u8868</dt><dt></dt><dd>* \u65E0\u5E8F</dd><dd>1. \u6709\u5E8F</dd></dl>\
<dl><dt>\u4EE3\u7801</dt><dd>`var markDown = undefined`</dd></dl>\
<dl><dt>\u56FE\u7247</dt><dd>![alt text](/path/to/img.jpg 'Title')</dd></dl>\
<dl><dt><a href='http://daringfireball.net/projects/markdown/syntax' target='_blank'>\u5B8C\u6574\u8BED\u6CD5</a></dt></dl>
editType1Label=\u7F16\u8F91\u5668\u7C7B\u578B\uFF1A
typeLabel=\u7C7B\u578B
onlineVisitor1Label=\u5F53\u524D\u8BBF\u5BA2\uFF1A
Expand Down

0 comments on commit 242ee41

Please sign in to comment.