Commit 3b86d474 authored by Vanessa's avatar Vanessa

🐛 更新按钮错误

parent b88c8e79
......@@ -58,9 +58,9 @@
<div class="clear"></div>
</div>
<div class="right">
<button id="unSubmitArticle" class="none marginRight12" onclick="admin.article.unPublish();">${unPublishLabel}</button>
<button class="marginRight12" id="saveArticle">${saveLabel}${draftListLabel}</button>
<button id="submitArticle">${publishLabel}</button>
<button id="unSubmitArticle" class="none" onclick="admin.article.unPublish();">${unPublishLabel}</button>
</div>
<div class="clear"></div>
</div>
......
......@@ -17,7 +17,7 @@
* admin style
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @version 2.3.7.4, May 5, 2017
* @version 2.3.8.4, May 31, 2017
*/
/* start resset */
......@@ -907,14 +907,12 @@ table.form th {
width: 170px;
}
button#submitArticle,
#unSubmitArticle {
button#submitArticle {
background-color: #fa8564;
border-color: #fa8564;
}
button#submitArticle:hover,
#unSubmitArticle:hover{
button#submitArticle:hover {
background-color: #ec6459;
border-color: #ec6459;
}
......
This diff is collapsed.
This diff is collapsed.
/**
* Copyright (c) 2010-2017, b3log.org & hacpai.com
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
html{height:100%;overflow:hidden}html,body{margin:0;padding:0}body{background-color:#f3f1e5;color:#333;font-family:\5fae\8f6f\96c5\9ed1;font-size:small;height:100%}h2{background-color:#ececec;background-image:linear-gradient(#f9f9f9,#ececec);background-repeat:repeat-x;border-radius:4px 4px 0 0;font-size:16px;margin:0;padding:10px 20px;text-shadow:0 -1px 0 rgba(255,255,255,0.5)}input{border:1px solid #ccc;border-radius:3px 3px 3px 3px;box-shadow:0 1px 2px rgba(0,0,0,0.075) inset;font-size:13px;margin:15px 0;padding:7px 8px;transition:all .15s ease-in 0;vertical-align:middle;width:410px;font-family:\5fae\8f6f\96c5\9ed1;font-size:small}input:focus{box-shadow:0 1px 2px rgba(0,0,0,0.075) inset,0 0 5px rgbargba(200,200,200,0.9);border:1px solid #e6e5d9}.form{padding:20px}label{font-size:13px}button{position:relative;display:inline-block;font-size:13px;font-weight:700;color:#333;text-shadow:0 1px 0 rgba(255,255,255,0.9);white-space:nowrap;background-color:#eaeaea;background-image:linear-gradient(#fafafa,#eaeaea);background-repeat:repeat-x;border-radius:3px;border:1px solid #ddd;border-bottom-color:#c5c5c5;box-shadow:0 1px 3px rgba(0,0,0,0.075);vertical-align:baseline;cursor:pointer;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;outline:0;padding:7px 15px;margin-top:10px}button:hover,button:active{color:#fff;text-decoration:none;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#3072b3;background-image:linear-gradient(#599bcd,#3072b3);background-repeat:repeat-x}.clear{background-color:transparent;border:0;clear:both;display:block;font-size:0;height:0;line-height:0;overflow:hidden}.none{display:none}.main .icon{position:absolute;right:0;top:0;width:16px;height:16px}.solo{color:orangered;font-weight:bold}.logo{float:left;padding:162px 12px 0;width:217px;text-align:center}.wrapper{height:auto;min-height:100%;position:relative}.wrap{border-top:5px solid #e6e5d9;min-height:400px}.content{background:url("../images/zz.jpg") repeat-x scroll center bottom white;border-color:#e6e5d9;border-style:solid solid none;border-width:1px;margin:0 auto;padding:0 0 28px 0;position:relative;width:760px;top:60px}.main{border-left:1px solid #e6e5d9;float:right;font-size:15px;margin:24px 0;padding:12px 24px;width:470px;height:338px}.main a{text-decoration:none}.main li{margin:6px 0 6px 16px}.footerWrapper{background-color:#fff;border-top:1px solid #e6e5d9;bottom:0;padding:12px 0;position:absolute;text-align:center;width:100%}.footerWrapper a{text-decoration:none}.article-pwd>div,.article-pwd>form{margin:0 20px}.article-pwd>div{margin-bottom:10px;max-height:264px;overflow:auto;word-wrap:break-word}.img-403,.img-500{box-shadow:0 0 5px #e6e5d9;margin:20px 0 0 45px;padding:5px}.a-403,.a-500,.a-404{margin:20px 50px 0 0;text-align:right}.a-403{margin:10px 75px 0 0}.img-500{margin:20px 0 0 25px}.a-500{margin:25px 35px 0 0}.a-404{margin:42px 35px 0 0}.kill img{position:absolute;right:40px;top:200px}.kill ul{margin-bottom:50px}.kill p{margin:12px 20px}.kill span{margin-left:20px}#init{position:absolute;top:81px;width:470px}#init .form{padding:10px 20px}#init input,.register input{margin:5px 0;padding:5px 8px}.register{height:400px}#sys p{height:206px}#sys{padding:0 20px}#initButton{margin-right:10px}#tip{color:#21759b;font-weight:bold;margin-left:10px}
\ No newline at end of file
html{height:100%}html,body{margin:0;padding:0}body{background-color:#fff;color:#333;font-family:\5fae\8f6f\96c5\9ed1;font-size:small;height:100%}h2{background-color:#f3f1e5;border-radius:4px 4px 0 0;font-size:16px;margin:0;padding:10px 20px;text-shadow:0 -1px 0 rgba(255,255,255,0.5)}input{border:1px solid #ccc;border-radius:3px 3px 3px 3px;box-shadow:0 1px 2px rgba(0,0,0,0.075) inset;font-size:13px;margin:15px 0;padding:7px 8px;vertical-align:middle;width:410px;font-family:\5fae\8f6f\96c5\9ed1;font-size:small}input:focus{box-shadow:0 1px 2px rgba(0,0,0,0.075) inset,0 0 5px rgbargba(200,200,200,0.9);border:1px solid #e6e5d9}.form{padding:20px}label{font-size:13px}button{position:relative;display:inline-block;font-size:13px;font-weight:700;color:#333;text-shadow:0 1px 0 rgba(255,255,255,0.9);white-space:nowrap;background-color:#eaeaea;background-image:linear-gradient(#fafafa,#eaeaea);background-repeat:repeat-x;border-radius:3px;border:1px solid #ddd;border-bottom-color:#c5c5c5;box-shadow:0 1px 3px rgba(0,0,0,0.075);vertical-align:baseline;cursor:pointer;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;outline:0;padding:7px 15px;margin-top:10px}button:hover,button:active{color:#fff;text-decoration:none;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#3072b3;background-image:linear-gradient(#599bcd,#3072b3);background-repeat:repeat-x}.clear{background-color:transparent;border:0;clear:both;display:block;font-size:0;height:0;line-height:0;overflow:hidden}.none{display:none}.solo{color:orangered;font-weight:bold}.logo{float:left;padding:142px 12px 0;width:217px;text-align:center}.wrap{border-top:5px solid #e6e5d9;padding:110px 0;background-color:#f3f1e5}.content{background-color:#fff;margin:0 auto;width:760px}.main{border-left:1px solid #e6e5d9;float:right;font-size:15px;padding:20px;width:470px;min-height:360px}.main a{text-decoration:none}.main li{margin:6px 0 6px 16px}.footerWrapper{background-color:#fff;border-top:1px solid #e6e5d9;padding:12px 0;text-align:center}.footerWrapper a{text-decoration:none}.article-pwd>div,.article-pwd>form{margin:0 20px}.article-pwd>div{margin-bottom:10px;max-height:264px;overflow:auto;word-wrap:break-word}.a-403,.a-500,.a-404{margin:20px 50px 0 0;text-align:right}.a-403{margin:10px 75px 0 0}.img-500,.img-403,.img-404{max-width:100%;margin:20px 0;padding:0}.a-500{margin:25px 35px 0 0}.a-404{margin:42px 35px 0 0}.kill img{position:absolute;right:40px;top:200px}.kill ul{margin-bottom:50px}.kill p{margin:12px 20px}.kill span{margin-left:20px}#init{position:absolute;width:470px}#init input,.register input{margin:5px 0;padding:5px 8px}.register{height:400px}#sys p{height:206px}#sys{padding:0 20px}#initButton{margin-right:10px}#tip{color:#21759b;font-weight:bold;margin-left:10px}@media(max-width:780px){.wrap{padding:40px 0}.content{width:auto}.logo{display:none}.main{border:0;float:none;width:auto}input{width:100%;box-sizing:border-box;display:block}.a-500,.a-403,.a-404{margin:0 20px 0 0}#init{width:100%;padding:0 20px;box-sizing:border-box;left:0}}
\ No newline at end of file
......@@ -18,7 +18,7 @@
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.4.5.7, Jan 21, 2017
* @version 1.4.5.7, May 21, 2017
*/
admin.article = {
currentEditorType: '',
......@@ -369,10 +369,12 @@ admin.article = {
if (this.status) {
if (this.status.isArticle) {
$("#unSubmitArticle").show();
$("#submitArticle").hide();
$("#saveArticle").hide();
$("#submitArticle").show();
} else {
$("#submitArticle").show();
$("#unSubmitArticle").hide();
$("#saveArticle").show();
}
if (this.status.articleHadBeenPublished) {
$("#postToCommunityPanel").hide();
......@@ -383,6 +385,7 @@ admin.article = {
} else {
$("#submitArticle").show();
$("#unSubmitArticle").hide();
$("#saveArticle").show();
// 1.0.0 开始默认会发布到社区
// $("#postToCommunityPanel").show();
}
......
......@@ -1049,7 +1049,7 @@ $.extend(TablePaginate.prototype, {
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.4.5.7, Jan 21, 2017
* @version 1.4.6.7, May 21, 2017
*/
admin.article = {
currentEditorType: '',
......@@ -1400,10 +1400,12 @@ admin.article = {
if (this.status) {
if (this.status.isArticle) {
$("#unSubmitArticle").show();
$("#submitArticle").hide();
$("#saveArticle").hide();
$("#submitArticle").show();
} else {
$("#submitArticle").show();
$("#unSubmitArticle").hide();
$("#saveArticle").show();
}
if (this.status.articleHadBeenPublished) {
$("#postToCommunityPanel").hide();
......@@ -1414,6 +1416,7 @@ admin.article = {
} else {
$("#submitArticle").show();
$("#unSubmitArticle").hide();
$("#saveArticle").show();
// 1.0.0 开始默认会发布到社区
// $("#postToCommunityPanel").show();
}
......
This source diff could not be displayed because it is too large. You can view the blob instead.
/*
* Copyright (c) 2010-2017, b3log.org & hacpai.com
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
var Util={isLoggedIn:function(){if(($("#admin").length===1&&$("#admin").data("login"))||latkeConfig.isLoggedIn==="true"){return true}else{return false}},getUserName:function(){if($("#adminName").length===1){return $("#adminName").text()}else{return latkeConfig.userName}},error:function(){$("#tipMsg").text("Error: "+arguments[0]+" File: "+arguments[1]+"\nLine: "+arguments[2]+" please report this issue on https://github.com/b3log/solo/issues/new");$("#loadMsg").text("")},killIE:function(){var addKillPanel=function(){if(Cookie.readCookie("showKill")===""){var left=($(window).width()-701)/2,top=($(window).height()-420)/2;$("body").append("<div style='display: block; height: 100%; width: 100%; position: fixed; background-color: rgb(0, 0, 0); opacity: 0.6; top: 0px;z-index:11'></div><iframe style='left:"+left+"px;z-index:20;top: "+top+"px; position: fixed; border: 0px none; width: 701px; height: 420px;' src='"+latkeConfig.servePath+"/kill-browser'></iframe>")}};if($.browser.msie){if($.browser.version==="6.0"||$.browser.version==="7.0"){addKillPanel();return}if(window.external&&window.external.twGetRunPath){var path=external.twGetRunPath();if(path&&path.toLowerCase().indexOf("360se")>-1&&window.location.href.indexOf("admin-index")>-1){addKillPanel();return}}}},replaceEmString:function(str){var commentSplited=str.split("[em");if(commentSplited.length===1){return str}str=commentSplited[0];for(var j=1;j<commentSplited.length;j++){var key=commentSplited[j].substr(0,2);str+="<img src='"+latkeConfig.staticServePath+"/skins/"+Label.skinDirName+"/images/emotions/em"+key+".png' alt='"+Label["em"+key+"Label"]+"' title='"+Label["em"+key+"Label"]+"'/>"+commentSplited[j].substr(3)}return str},proessURL:function(url){if(!/^\w+:\/\//.test(url)){url="http://"+url}return url},switchMobile:function(skin){Cookie.createCookie("btouch_switch_toggle",skin,365);setTimeout(function(){location.reload()},1250)},setTopBar:function(){var $top=$("#top");if($top.length===1){var $showTop=$("#showTop");$showTop.click(function(){$top.slideDown();$showTop.hide()});$("#hideTop").click(function(){$top.slideUp();$showTop.show()})}},goTop:function(){$("html, body").animate({scrollTop:0},800)},goBottom:function(bottom){if(!bottom){bottom=0}var wHeight=$("body").height()>$(document).height()?$("body").height():$(document).height();window.scrollTo(0,wHeight-$(window).height()-bottom)},init:function(){Util.killIE();Util.setTopBar()},replaceSideEm:function(comments){for(var i=0;i<comments.length;i++){var $comment=$(comments[i]);$comment.html(Util.replaceEmString($comment.html()))}},buildTags:function(id){id=id||"tags";var classes=["tags1","tags2","tags3","tags4","tags5"],bList=$("#"+id+" b").get();var max=parseInt($("#"+id+" b").last().text());var distance=Math.ceil(max/classes.length);for(var i=0;i<bList.length;i++){var num=parseInt(bList[i].innerHTML);for(var j=0;j<classes.length;j++){if(num>j*distance&&num<=(j+1)*distance){bList[i].parentNode.className=classes[j];break}}}$("#"+id).html($("#"+id+" li").get().sort(function(a,b){var valA=$(a).find("span").text().toLowerCase();var valB=$(b).find("span").text().toLowerCase();return valA.localeCompare(valB)}))},toDate:function(time,format){var dateTime=new Date(time);var o={"M+":dateTime.getMonth()+1,"d+":dateTime.getDate(),"H+":dateTime.getHours(),"m+":dateTime.getMinutes(),"s+":dateTime.getSeconds(),"q+":Math.floor((dateTime.getMonth()+3)/3),S:dateTime.getMilliseconds()};if(/(y+)/.test(format)){format=format.replace(RegExp.$1,(dateTime.getFullYear()+"").substr(4-RegExp.$1.length))}for(var k in o){if(new RegExp("("+k+")").test(format)){format=format.replace(RegExp.$1,RegExp.$1.length==1?o[k]:("00"+o[k]).substr((""+o[k]).length))}}return format},getWinHeight:function(){if(window.innerHeight){return window.innerHeight}if(document.compatMode==="CSS1Compat"){return window.document.documentElement.clientHeight}return window.document.body.clientHeight}};if(!Cookie){var Cookie={readCookie:function(name){var nameEQ=name+"=";var ca=document.cookie.split(";");for(var i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==" "){c=c.substring(1,c.length)}if(c.indexOf(nameEQ)==0){return decodeURIComponent(c.substring(nameEQ.length,c.length))}}return""},eraseCookie:function(name){this.createCookie(name,"",-1)},createCookie:function(name,value,days){var expires="";if(days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));expires="; expires="+date.toGMTString()}document.cookie=name+"="+encodeURIComponent(value)+expires+"; path=/"}}};
\ No newline at end of file
var Util={isLoggedIn:function(){if(($("#admin").length===1&&$("#admin").data("login"))||latkeConfig.isLoggedIn==="true"){return true}else{return false}},getUserName:function(){if($("#adminName").length===1){return $("#adminName").text()}else{return latkeConfig.userName}},error:function(){$("#tipMsg").text("Error: "+arguments[0]+" File: "+arguments[1]+"\nLine: "+arguments[2]+" please report this issue on https://github.com/b3log/solo/issues/new");$("#loadMsg").text("")},killIE:function(){var addKillPanel=function(){if(Cookie.readCookie("showKill")===""){var left=($(window).width()-701)/2,top1=($(window).height()-420)/2;$("body").append("<div style='display: block; height: 100%; width: 100%; position: fixed; background-color: rgb(0, 0, 0); opacity: 0.6; top: 0px;z-index:11'></div><iframe style='left:"+left+"px;z-index:20;top: "+top1+"px; position: fixed; border: 0px none; width: 701px; height: 420px;' src='"+latkeConfig.servePath+"/kill-browser'></iframe>")}};if($.browser.msie){if($.browser.version==="6.0"||$.browser.version==="7.0"){addKillPanel();return}if(window.external&&window.external.twGetRunPath){var path=external.twGetRunPath();if(path&&path.toLowerCase().indexOf("360se")>-1&&window.location.href.indexOf("admin-index")>-1){addKillPanel();return}}}},replaceEmString:function(str){var commentSplited=str.split("[em");if(commentSplited.length===1){return str}str=commentSplited[0];for(var j=1;j<commentSplited.length;j++){var key=commentSplited[j].substr(0,2);str+="<img width='20' src='"+latkeConfig.staticServePath+"/images/emotions/em"+key+".png' alt='"+Label["em"+key+"Label"]+"' title='"+Label["em"+key+"Label"]+"'/> "+commentSplited[j].substr(3)}return str},proessURL:function(url){if(!/^\w+:\/\//.test(url)){url="http://"+url}return url},switchMobile:function(skin){Cookie.createCookie("btouch_switch_toggle",skin,365);setTimeout(function(){location.reload()},1250)},setTopBar:function(){var $top=$("#top");if($top.length===1){var $showTop=$("#showTop");$showTop.click(function(){$top.slideDown();$showTop.hide()});$("#hideTop").click(function(){$top.slideUp();$showTop.show()})}},goTop:function(){$("html, body").animate({scrollTop:0},800)},goBottom:function(bottom){if(!bottom){bottom=0}var wHeight=$("body").height()>$(document).height()?$("body").height():$(document).height();window.scrollTo(0,wHeight-$(window).height()-bottom)},init:function(){Util.killIE();Util.setTopBar()},replaceSideEm:function(comments){for(var i=0;i<comments.length;i++){var $comment=$(comments[i]);$comment.html(Util.replaceEmString($comment.html()))}},buildTags:function(id){id=id||"tags";var classes=["tags1","tags2","tags3","tags4","tags5"],bList=$("#"+id+" b").get();var max=parseInt($("#"+id+" b").last().text());var distance=Math.ceil(max/classes.length);for(var i=0;i<bList.length;i++){var num=parseInt(bList[i].innerHTML);for(var j=0;j<classes.length;j++){if(num>j*distance&&num<=(j+1)*distance){bList[i].parentNode.className=classes[j];break}}}$("#"+id).html($("#"+id+" li").get().sort(function(a,b){var valA=$(a).find("span").text().toLowerCase();var valB=$(b).find("span").text().toLowerCase();return valA.localeCompare(valB)}))},toDate:function(time,format){var dateTime=new Date(time);var o={"M+":dateTime.getMonth()+1,"d+":dateTime.getDate(),"H+":dateTime.getHours(),"m+":dateTime.getMinutes(),"s+":dateTime.getSeconds(),"q+":Math.floor((dateTime.getMonth()+3)/3),S:dateTime.getMilliseconds()};if(/(y+)/.test(format)){format=format.replace(RegExp.$1,(dateTime.getFullYear()+"").substr(4-RegExp.$1.length))}for(var k in o){if(new RegExp("("+k+")").test(format)){format=format.replace(RegExp.$1,RegExp.$1.length==1?o[k]:("00"+o[k]).substr((""+o[k]).length))}}return format},getWinHeight:function(){if(window.innerHeight){return window.innerHeight}if(document.compatMode==="CSS1Compat"){return window.document.documentElement.clientHeight}return window.document.body.clientHeight}};if(!Cookie){var Cookie={readCookie:function(name){var nameEQ=name+"=";var ca=document.cookie.split(";");for(var i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==" "){c=c.substring(1,c.length)}if(c.indexOf(nameEQ)==0){return decodeURIComponent(c.substring(nameEQ.length,c.length))}}return""},eraseCookie:function(name){this.createCookie(name,"",-1)},createCookie:function(name,value,days){var expires="";if(days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));expires="; expires="+date.toGMTString()}document.cookie=name+"="+encodeURIComponent(value)+expires+"; path=/"}}};
\ No newline at end of file
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment