diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2012-07-16 22:50:35 -0400 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2012-07-16 22:50:35 -0400 |
commit | 1c788b98ee532e12717f24e17f9fe62dde6d6a38 (patch) | |
tree | 815b36eb8bbc0ac2395ab496645b4e1d19ed42e8 | |
parent | a2faac0a22ed74255bfa44b36c8d8a3b07e96813 (diff) | |
download | askbot-1c788b98ee532e12717f24e17f9fe62dde6d6a38.tar.gz askbot-1c788b98ee532e12717f24e17f9fe62dde6d6a38.tar.bz2 askbot-1c788b98ee532e12717f24e17f9fe62dde6d6a38.zip |
restored ability to comment and vote on closed questions and removed width from "answer own question" button
-rw-r--r-- | askbot/skins/default/media/style/style.less | 7 | ||||
-rw-r--r-- | askbot/skins/default/templates/question/content.html | 11 | ||||
-rw-r--r-- | askbot/skins/default/templates/question/javascript.html | 56 |
3 files changed, 37 insertions, 37 deletions
diff --git a/askbot/skins/default/media/style/style.less b/askbot/skins/default/media/style/style.less index 7f5c4eb1..4e272eca 100644 --- a/askbot/skins/default/media/style/style.less +++ b/askbot/skins/default/media/style/style.less @@ -1740,9 +1740,6 @@ ul#related-tags li { #fmanswer_button{ margin:8px 0px; } - #fmanswer_button.answer-own-question { - width: 150px; - } .question-img-favorite:hover { background: url(../images/vote-favorite-on.png) } @@ -1879,9 +1876,9 @@ ul#related-tags li { margin: -3px 0px 0px -2px; } .content { - margin-bottom: 7px; + margin-bottom: 7px; } - + .comment-votes { float: left; width: 37px; diff --git a/askbot/skins/default/templates/question/content.html b/askbot/skins/default/templates/question/content.html index 906b1953..f01c68e0 100644 --- a/askbot/skins/default/templates/question/content.html +++ b/askbot/skins/default/templates/question/content.html @@ -31,6 +31,11 @@ {# ==== START: question/new_answer_form.html ==== #} {% include "question/new_answer_form.html" %} {# ==== END: question/new_answer_form.html ==== #} -{% if request.user == question.author %}{# this is outside the form on purpose #} - <input type="button" class="submit after-editor answer-own-question" id="fmanswer_button" value="{% trans %}Answer Your Own Question{% endtrans %}"/> -{%endif%} +{% if question.closed == False and request.user == question.author %}{# this is outside the form on purpose #} +<input + type="button" + class="submit after-editor answer-own-question" + id="fmanswer_button" + value="{% trans %}Answer Your Own Question{% endtrans %}" +/> +{% endif %} diff --git a/askbot/skins/default/templates/question/javascript.html b/askbot/skins/default/templates/question/javascript.html index 3a29579d..73e209bb 100644 --- a/askbot/skins/default/templates/question/javascript.html +++ b/askbot/skins/default/templates/question/javascript.html @@ -1,32 +1,30 @@ -{% if not thread.closed %} - <script type='text/javascript' src='{{"/js/editor.js"|media}}'></script> - <script type='text/javascript'> - {% if settings.ENABLE_MATHJAX or settings.MARKUP_CODE_FRIENDLY %} - var codeFriendlyMarkdown = true; - {% else %} - var codeFriendlyMarkdown = false; - {% endif %} - var maxCommentLength = {{settings.MAX_COMMENT_LENGTH}}; - askbot['urls']['postComments'] = '{% url post_comments %}'; - askbot['urls']['editComment'] = '{% url edit_comment %}'; - askbot['urls']['deleteComment'] = '{% url delete_comment %}'; - askbot['urls']['getComment'] = '{% url get_comment %}'; - askbot['urls']['question_url_template'] = scriptUrl + '{{ 'question/'|transurl }}{{ "{{QuestionID}}/{{questionSlug}}" }}';{# yes it needs to be that whacky #} - askbot['urls']['vote_url_template'] = scriptUrl + '{{ 'questions/'|transurl }}{{ "{{QuestionID}}/" }}{{ 'vote/'|transurl }}'; - askbot['urls']['user_signin'] = '{{ settings.LOGIN_URL }}'; - askbot['urls']['swap_question_with_answer'] = '{% url swap_question_with_answer %}'; - askbot['urls']['upvote_comment'] = '{% url upvote_comment %}'; - askbot['urls']['delete_post'] = '{% url delete_post %}'; - askbot['messages']['addComment'] = '{% trans %}post a comment{% endtrans %}'; - {% if settings.SAVE_COMMENT_ON_ENTER %} - askbot['settings']['saveCommentOnEnter'] = true; - {% else %} - askbot['settings']['saveCommentOnEnter'] = false; - {% endif %} - </script> - <script type='text/javascript' src='{{"/js/wmd/showdown.js"|media}}'></script> - <script type='text/javascript' src='{{"/js/wmd/wmd.js"|media}}'></script> -{% endif %} +<script type='text/javascript' src='{{"/js/editor.js"|media}}'></script> +<script type='text/javascript'> + {% if settings.ENABLE_MATHJAX or settings.MARKUP_CODE_FRIENDLY %} + var codeFriendlyMarkdown = true; + {% else %} + var codeFriendlyMarkdown = false; + {% endif %} + var maxCommentLength = {{settings.MAX_COMMENT_LENGTH}}; + askbot['urls']['postComments'] = '{% url post_comments %}'; + askbot['urls']['editComment'] = '{% url edit_comment %}'; + askbot['urls']['deleteComment'] = '{% url delete_comment %}'; + askbot['urls']['getComment'] = '{% url get_comment %}'; + askbot['urls']['question_url_template'] = scriptUrl + '{{ 'question/'|transurl }}{{ "{{QuestionID}}/{{questionSlug}}" }}';{# yes it needs to be that whacky #} + askbot['urls']['vote_url_template'] = scriptUrl + '{{ 'questions/'|transurl }}{{ "{{QuestionID}}/" }}{{ 'vote/'|transurl }}'; + askbot['urls']['user_signin'] = '{{ settings.LOGIN_URL }}'; + askbot['urls']['swap_question_with_answer'] = '{% url swap_question_with_answer %}'; + askbot['urls']['upvote_comment'] = '{% url upvote_comment %}'; + askbot['urls']['delete_post'] = '{% url delete_post %}'; + askbot['messages']['addComment'] = '{% trans %}post a comment{% endtrans %}'; + {% if settings.SAVE_COMMENT_ON_ENTER %} + askbot['settings']['saveCommentOnEnter'] = true; + {% else %} + askbot['settings']['saveCommentOnEnter'] = false; + {% endif %} +</script> +<script type='text/javascript' src='{{"/js/wmd/showdown.js"|media}}'></script> +<script type='text/javascript' src='{{"/js/wmd/wmd.js"|media}}'></script> <script type='text/javascript' src='{{"/js/jquery.validate.min.js"|media}}'></script> <script type='text/javascript' src='{{"/js/post.js"|media}}'></script> <script type="text/javascript"> |