diff options
Diffstat (limited to 'forum/skins/default')
-rw-r--r-- | forum/skins/default/media/js/com.cnprog.admin.js | 4 | ||||
-rw-r--r-- | forum/skins/default/media/js/com.cnprog.i18n.js | 4 | ||||
-rw-r--r-- | forum/skins/default/media/style/style.css | 1 | ||||
-rw-r--r-- | forum/skins/default/templates/ask.html | 7 | ||||
-rw-r--r-- | forum/skins/default/templates/authopenid/complete.html | 1 | ||||
-rw-r--r-- | forum/skins/default/templates/authopenid/confirm_email.txt | 14 | ||||
-rw-r--r-- | forum/skins/default/templates/authopenid/email_validation.txt | 16 | ||||
-rw-r--r-- | forum/skins/default/templates/authopenid/sendpw_email.txt | 4 | ||||
-rwxr-xr-x | forum/skins/default/templates/base.html | 3 | ||||
-rw-r--r-- | forum/skins/default/templates/header.html | 1 | ||||
-rw-r--r-- | forum/skins/default/templates/index.html | 5 | ||||
-rw-r--r-- | forum/skins/default/templates/question.html | 521 | ||||
-rw-r--r-- | forum/skins/default/templates/question_edit.html | 6 | ||||
-rw-r--r-- | forum/skins/default/templates/questions.html | 275 | ||||
-rw-r--r-- | forum/skins/default/templates/user_email_subscriptions.html | 3 | ||||
-rw-r--r-- | forum/skins/default/templates/user_info.html | 2 |
16 files changed, 846 insertions, 21 deletions
diff --git a/forum/skins/default/media/js/com.cnprog.admin.js b/forum/skins/default/media/js/com.cnprog.admin.js index 39dff48c..974dce23 100644 --- a/forum/skins/default/media/js/com.cnprog.admin.js +++ b/forum/skins/default/media/js/com.cnprog.admin.js @@ -3,7 +3,11 @@ $(document).ready( function(){ success: function(a,b){$('.admin #action_status').html($.i18n._('changes saved'));}, dataType:'json', timeout:5000, +<<<<<<< HEAD:templates/content/js/com.cnprog.admin.js + url: $.i18n._('/') + $.i18n._('moderate-user/') + viewUserID + '/' +======= url: scriptUrl + $.i18n._('moderate-user/') + viewUserID + '/' +>>>>>>> 82d35490db90878f013523c4d1a5ec3af2df8b23:templates/content/js/com.cnprog.admin.js }; var form = $('.admin #moderate_user_form').ajaxForm(options); var box = $('.admin input#id_is_approved').click(function(){ diff --git a/forum/skins/default/media/js/com.cnprog.i18n.js b/forum/skins/default/media/js/com.cnprog.i18n.js index da9bf396..58cb8f16 100644 --- a/forum/skins/default/media/js/com.cnprog.i18n.js +++ b/forum/skins/default/media/js/com.cnprog.i18n.js @@ -59,6 +59,10 @@ var i18nZh = { }; var i18nEn = { +<<<<<<< HEAD:templates/content/js/com.cnprog.i18n.js + '/':'/', +======= +>>>>>>> 82d35490db90878f013523c4d1a5ec3af2df8b23:templates/content/js/com.cnprog.i18n.js 'need >15 points to report spam':'need >15 points to report spam ', '>15 points requried to upvote':'>15 points required to upvote ', 'tags cannot be empty':'please enter at least one tag', diff --git a/forum/skins/default/media/style/style.css b/forum/skins/default/media/style/style.css index 175fcb66..88c7e7db 100644 --- a/forum/skins/default/media/style/style.css +++ b/forum/skins/default/media/style/style.css @@ -1163,6 +1163,7 @@ ul.bulleta li {background:url(../images/bullet_green.gif) no-repeat 0px 2px; pad .message p { margin-bottom:0px; } + p.space-above { margin-top:10px; } diff --git a/forum/skins/default/templates/ask.html b/forum/skins/default/templates/ask.html index 083b01d9..84253be5 100644 --- a/forum/skins/default/templates/ask.html +++ b/forum/skins/default/templates/ask.html @@ -115,6 +115,13 @@ <p class="title-desc"> {{ form.tags.help_text }} </p> + <p class="form-item"> + <strong>{{ form.categories.label_tag }}:</strong> {% trans "(required)" %} <span class="form-error"></span><br> + {{ form.categories }} {{ form.categories.errors }} + </p> + <p class="title-desc"> + {{ form.categories.help_text }} + </p> {% if not request.user.is_authenticated %} <input type="submit" value="{% trans "Login/signup to post your question" %}" class="submit" /> {% else %} diff --git a/forum/skins/default/templates/authopenid/complete.html b/forum/skins/default/templates/authopenid/complete.html index 62970e38..72dca1a5 100644 --- a/forum/skins/default/templates/authopenid/complete.html +++ b/forum/skins/default/templates/authopenid/complete.html @@ -92,6 +92,7 @@ parameters: {% endif %} {{ form1.email }} </div> + <p class='nomargin'>{% trans "Tag filter tool will be your right panel, once you log in." %}</p> <p>{% trans "receive updates motivational blurb" %}</p> <div class='simple-subscribe-options'> {{email_feeds_form.subscribe}} diff --git a/forum/skins/default/templates/authopenid/confirm_email.txt b/forum/skins/default/templates/authopenid/confirm_email.txt index 3a01f146..0b3b2505 100644 --- a/forum/skins/default/templates/authopenid/confirm_email.txt +++ b/forum/skins/default/templates/authopenid/confirm_email.txt @@ -1,13 +1,13 @@ -{% load i18n %} -{% trans "Thank you for registering at our Q&A forum!" %} +Gracias por registrarse en Hasked.com -{% trans "Your account details are:" %} +Los detalles de su cuenta son: -{% trans "Username:" %} {{ username }} -{% trans "Password:" %} {{ password }} +Nombre de usuario: {{ username }} +Contraseña: {{ password }} {% trans "Please sign in here:" %} {{signup_url}} -{% blocktrans %}Sincerely, -Forum Administrator{% endblocktrans %} +Saludos, +El equipo administrador de Hasked.com + diff --git a/forum/skins/default/templates/authopenid/email_validation.txt b/forum/skins/default/templates/authopenid/email_validation.txt index 5b166a9b..d741614f 100644 --- a/forum/skins/default/templates/authopenid/email_validation.txt +++ b/forum/skins/default/templates/authopenid/email_validation.txt @@ -1,15 +1,13 @@ -{% load i18n %} -{% trans "Greetings from the Q&A forum" %}, +Saludos de Hasked.com, -{% trans "To make use of the Forum, please follow the link below:" %} +Para poder usar Hasked haga click en el siguiente link: {{validation_link}} -{% trans "Following the link above will help us verify your email address." %} +Seguir el link de arriba nos ayuda a verificar su correo electrónico. -{% blocktrans %}If you beleive that this message was sent in mistake - -no further action is needed. Just ingore this email, we apologize -for any inconvenience{% endblocktrans %} +Si cree que este mensaje se mandó por error no se requiere de mas acciones. +Solo ignore este correo, pedimos disculpas por cualquier incoveniente -{% blocktrans %}Sincerely, -Forum Administrator{% endblocktrans %} +Saludos, +Equipo de administración de Hasked.com diff --git a/forum/skins/default/templates/authopenid/sendpw_email.txt b/forum/skins/default/templates/authopenid/sendpw_email.txt index f044ca45..c4910d12 100644 --- a/forum/skins/default/templates/authopenid/sendpw_email.txt +++ b/forum/skins/default/templates/authopenid/sendpw_email.txt @@ -5,5 +5,5 @@ If it were not you, it is safe to ignore this email.{% endblocktrans %} {% blocktrans %}email explanation how to use new {{password}} for {{username}} with the {{key_link}}{% endblocktrans %} -{% blocktrans %}Sincerely, -Forum Administrator{% endblocktrans %} +Saludos, +El Equipo administrador de Hasked.com diff --git a/forum/skins/default/templates/base.html b/forum/skins/default/templates/base.html index 9033b0c9..58ef0627 100755 --- a/forum/skins/default/templates/base.html +++ b/forum/skins/default/templates/base.html @@ -17,6 +17,9 @@ <link href="{% media "/media/style/style.css" %}" rel="stylesheet" type="text/css" /> <script src="http://www.google.com/jsapi" type="text/javascript"></script> <script type="text/javascript">google.load("jquery", "1.2.6");</script> + <script type='text/javascript' src='{% href "/content/js/com.cnprog.i18n.js" %}'></script> + <script type='text/javascript' src='{% href "/content/js/jquery.i18n.js" %}'></script> + <script type='text/javascript' src='{% href "/content/js/com.cnprog.utils.js" %}'></script> <script type="text/javascript"> var i18nLang = '{{settings.LANGUAGE_CODE}}'; var scriptUrl = '/{{settings.FORUM_SCRIPT_ALIAS}}' diff --git a/forum/skins/default/templates/header.html b/forum/skins/default/templates/header.html index 3afc46c5..3b29ffc4 100644 --- a/forum/skins/default/templates/header.html +++ b/forum/skins/default/templates/header.html @@ -63,3 +63,4 @@ </div> </div> <!-- end template header.html --> + diff --git a/forum/skins/default/templates/index.html b/forum/skins/default/templates/index.html index 7fa189ae..30cba1be 100644 --- a/forum/skins/default/templates/index.html +++ b/forum/skins/default/templates/index.html @@ -24,10 +24,11 @@ <div class="tabBar"> <div class="headQuestions">{% trans "Questions" %}</div> <div class="tabsA"> - <a id="latest" href="{% url questions %}?sort=latest" title="{% trans "last updated questions" %}" >{% trans "newest" %}</a> + <a id="latest" href="{% url questions %}?sort=latest" title="{% trans "last updated questions" %}" >{% trans "newest" %}</a> + <a id="active" href="{% url questions %}?sort=active" title="{% trans "most recently updated questions" %}">{% trans "active" %}</a> <a id="hottest" href="{% url questions %}?sort=hottest" title="{% trans "hottest questions" %}" >{% trans "hottest" %}</a> <a id="mostvoted" href="{% url questions %}?sort=mostvoted" title="{% trans "most voted questions" %}" >{% trans "most voted" %}</a> - <a id="all" href="{% url questions %}" title="{% trans "all questions" %}" >{% trans "all questions" %}</a> + <!--<a id="all" href="{% url questions %}" title="{% trans "all questions" %}" >{% trans "all questions" %}</a>--> </div> </div> <!-- 问题列表 --> diff --git a/forum/skins/default/templates/question.html b/forum/skins/default/templates/question.html index fe9f5cde..ae562b6b 100644 --- a/forum/skins/default/templates/question.html +++ b/forum/skins/default/templates/question.html @@ -1,3 +1,523 @@ +<<<<<<< HEAD:templates/question.html +{% extends "base.html" %} +<!-- question.html --> +{% load extra_tags %} +{% load extra_filters %} +{% load smart_if %} +{% load humanize %} +{% load i18n %} +{% block title %}{% spaceless %}{{ question.get_question_title }}{% endspaceless %}{% endblock %} +{% block forejs %} + <meta name="description" content="{{question.summary}}" /> + <meta name="keywords" content="{{question.tagname_meta_generator}}" /> + <link rel="canonical" href="{{settings.APP_URL}}{{question.get_absolute_url}}" /> + {% if not question.closed %} + <script type='text/javascript' src='{% href "/content/js/com.cnprog.editor.js" %}'></script> + <script type='text/javascript' src='{% href "/content/js/wmd/showdown.js" %}'></script> + <script type='text/javascript' src='{% href "/content/js/wmd/wmd.js" %}'></script> + <link rel="stylesheet" type="text/css" href="{% href "/content/js/wmd/wmd.css" %}" /> + {% endif %} + <script type='text/javascript' src='{% href "/content/js/com.cnprog.post.js" %}'></script> + <script type='text/javascript' src='{% href "/content/js/jquery.validate.pack.js" %}'></script> + + <script type="text/javascript"> + // define reputation needs for comments + var repNeededForComments = 50; + $().ready(function(){ + $("#nav_questions").attr('className',"on"); + var answer_sort_tab = "{{ tab_id }}"; + $("#" + answer_sort_tab).attr('className',"on"); + + Vote.init({{ question.id }}, '{{ question.author.id }}','{{ request.user.id }}'); + + {% if not question.closed and request.user.is_authenticated %}initEditor();{% endif %} + + lanai.highlightSyntax(); + $('#btLogin').bind('click', function(){window.location.href='{% url user_signin %}'; } ) + }); + + function initEditor(){ + $('#editor').TextAreaResizer(); + //highlight code synctax when editor has new text + $("#editor").typeWatch({highlight: false, wait: 3000, + captureLength: 5, callback: lanai.highlightSyntax}); + + var display = true; + var txt = "[{% trans "hide preview" %}]"; + $('#pre-collapse').text(txt); + $('#pre-collapse').bind('click', function(){ + txt = display ? "[{% trans "show preview" %}]" : "[{% trans "hide preview" %}]"; + display = !display; + $('#previewer').toggle(); + $('#pre-collapse').text(txt); + }); + + setupFormValidation("#fmanswer", CPValidator.getQuestionFormRules(), CPValidator.getQuestionFormMessages()); + } + + </script> +{% endblock %} + +{% block content %} +<div class="headNormal"> + <a href="{{ question.get_absolute_url }}">{{ question.get_question_title }}</a> +</div> +<div id="main-body" class=""> + <div id="askform"> + <table style="width:100%;" id="question-table" {% if question.deleted %}class="deleted"{%endif%}> + <tr> + <td style="width:30px;vertical-align:top"> + <div class="vote-buttons"> + {% if question_vote %} + <img id="question-img-upvote-{{ question.id }}" class="question-img-upvote" + {% if question_vote.is_upvote %} + src="{% href "/content/images/vote-arrow-up-on.png" %}" + {% else %} + src="{% href "/content/images/vote-arrow-up.png" %}" + {% endif %} + alt="{% trans "i like this post (click again to cancel)" %}" + title="{% trans "i like this post (click again to cancel)" %}" /> + <div id="question-vote-number-{{ question.id }}" class="vote-number" + title="{% trans "current number of votes" %}"> + {{ question.score }} + </div> + <img id="question-img-downvote-{{ question.id }}" class="question-img-downvote" + {% if question_vote.is_downvote %} + src="{% href "/content/images/vote-arrow-down-on.png" %}" + {% else %} + src="{% href "/content/images/vote-arrow-down.png" %}" + {% endif %} + alt="{% trans "i dont like this post (click again to cancel)" %}" + title="{% trans "i dont like this post (click again to cancel)" %}" /> + + {% else %} + <img id="question-img-upvote-{{ question.id }}" class="question-img-upvote" + alt="{% trans "i like this post (click again to cancel)" %}" + src="{% href "/content/images/vote-arrow-up.png" %}" + title="{% trans "i like this post (click again to cancel)" %}" /> + <div id="question-vote-number-{{ question.id }}" class="vote-number" + title="{% trans "current number of votes" %}"> + {{ question.score }} + </div> + <img id="question-img-downvote-{{ question.id }}" class="question-img-downvote" + src="{% href "/content/images/vote-arrow-down.png" %}" + alt="{% trans "i dont like this post (click again to cancel)" %}" + title="{% trans "i dont like this post (click again to cancel)" %}" /> + + {% endif %} + {% if favorited %} + <img class="question-img-favorite" src="{% href "/content/images/vote-favorite-on.png" %}" + alt="{% trans "mark this question as favorite (click again to cancel)" %}" + title="{% trans "mark this question as favorite (click again to cancel)" %}" /> + <div id="favorite-number" class="favorite-number my-favorite-number"> + {{ question.favourite_count }} + </div> + {% else %} + <img class="question-img-favorite" src="{% href "/content/images/vote-favorite-off.png" %}" + alt="{% trans "remove favorite mark from this question (click again to restore mark)" %}" + title="{% trans "remove favorite mark from this question (click again to restore mark)" %}" /> + <div id="favorite-number" class="favorite-number"> + {% ifnotequal question.favourite_count 0 %}{{ question.favourite_count }}{% endifnotequal %} + </div> + + {% endif %} + + </div> + </td> + <td> + <div id="item-right"> + <div class="question-body"> + {{ question.html|safe }} + </div> + <div id="question-controls" class="post-controls"> + <div id="question-tags" class="tags"> + {% for tag in question.tagname_list %} + <a href="{% url forum.views.tag tag|urlencode %}" class="post-tag" + title="{% blocktrans with tag as tagname %}see questions tagged '{{ tagname }}'{% endblocktrans %}" rel="tag">{{ tag }}</a> + {% endfor %} + </div> + {% joinitems using '<span class="action-link-separator">|</span>' %} + {% if request.user|can_edit_post:question %} + <span class="action-link"><a href="{% url edit_question question.id %}">{% trans 'edit' %}</a></span> + {% endif %} + {% separator %} + {% if question.closed %} + {% if request.user|can_reopen_question:question %} + <span class="action-link"><a href="{% url reopen question.id %}">{% trans "reopen" %}</a></span> + {% endif %} + {% else %} + {% if request.user|can_close_question:question %} + <span class="action-link"><a href="{% url close question.id %}">{% trans "close" %}</a></span> + {% endif %} + {% endif %} + {% separator %} + {% if request.user|can_flag_offensive %} + <span id="question-offensive-flag-{{ question.id }}" class="offensive-flag" + title="{% trans "report as offensive (i.e containing spam, advertising, malicious text, etc.)" %}"> + <a>{% trans "flag offensive" %}</a> + {% if request.user|can_view_offensive_flags and question.offensive_flag_count %} + <span class="darkred">({{ question.offensive_flag_count }})</span> + {% endif %} + </span> + {% endif %} + {% separator %} + {% if request.user|can_delete_post:question %} + <span class="action-link"><a id="question-delete-link-{{question.id}}">{% trans "delete" %}</a></span> + {% endif %} + {% endjoinitems %} + </div> + <div class="post-update-info-container"> + {% post_contributor_info question "original_author" %} + {% post_contributor_info question "last_updater" %} + </div> + <div class="comments-container" id="comments-container-question-{{question.id}}"> + {% for comment in question.get_comments|slice:":5" %} + <p class="comment" id="comment-{{comment.id}}"> + {{comment.comment}} + - <a class="comment-user" href="{{comment.user.get_profile_url}}">{{comment.user}}</a> + {% spaceless %} + <span class="comment-age">({% diff_date comment.added_at %})</span> + {% if request.user|can_delete_comment:comment %} + <img class="delete-icon" + src="{% href "/content/images/close-small.png" %}" + title="{% trans "delete this comment" %}"/> + {% endif %} + {% endspaceless %} + </p> + {% endfor %} + </div> + <div class="post-comments" style="margin-bottom:20px"> + <input id="can-post-comments-question-{{question.id}}" type="hidden" value="{{ request.user|can_add_comments:question }}"/> + {% if request.user|can_add_comments:question or question.comment_count > 5 %} + <a id="comments-link-question-{{question.id}}" class="comments-link"> + {% if request.user|can_add_comments:question %} + {% trans "add comment" %} + {% endif %} + {% if question.comment_count > 5 %} + {% if request.user|can_add_comments:question %}/ + {% blocktrans count question.get_comments|slice:"5:"|length as counter %} + see <strong>one</strong> more + {% plural %} + see <strong>{{counter}}</strong> more + {% endblocktrans %} + {% else %} + {% blocktrans count question.get_comments|slice:"5:"|length as counter %} + see <strong>one</strong> more comment + {% plural %} + see <strong>{{counter}}</strong> more comments + {% endblocktrans %} + {% endif %} + {% endif %}</a> + {% endif %} + </div> + </div> + + </td> + </tr> + </table> + {% if question.closed %} + <div class="question-status" style="margin-bottom:15px"> + <h3>{% blocktrans with question.get_close_reason_display as close_reason %}The question has been closed for the following reason "{{ close_reason }}" by{% endblocktrans %} + <a href="{{ question.closed_by.get_profile_url }}">{{ question.closed_by.username }}</a> + {% blocktrans with question.closed_at as closed_at %}close date {{closed_at}}{% endblocktrans %}</h3> + </div> + {% endif %} + {% if answers %} + <hr/> + <div class="tabBar"> + <a name="sort-top"></a> + <div class="headQuestions"> + {% blocktrans count answers|length as counter %} + One Answer: + {% plural %} + {{counter}} Answers: + {% endblocktrans %} + </div> + <div class="tabsA"> + <a id="oldest" href="{% url question question.id %}?sort=oldest#sort-top" + title="{% trans "oldest answers will be shown first" %}">{% trans "oldest answers" %}</a> + <a id="latest" href="{% url question question.id %}?sort=latest#sort-top" + title="{% trans "newest answers will be shown first" %}">{% trans "newest answers" %}</a> + <a id="votes" href="{% url question question.id %}?sort=votes#sort-top" + title="{% trans "most voted answers will be shown first" %}">{% trans "popular answers" %}</a> + </div> + </div> + {% cnprog_paginator context %} + + {% for answer in answers %} + <a name="{{ answer.id }}"></a> + <div id="answer-container-{{ answer.id }}" class="answer {% if answer.accepted %}accepted-answer{% endif %} {% ifequal answer.author_id question.author_id %} answered-by-owner{% endifequal %} {% if answer.deleted %}deleted{% endif %}"> + <table style="width:100%;"> + <tr> + <td style="width:30px;vertical-align:top"> + <div class="vote-buttons"> + <img id="answer-img-upvote-{{ answer.id }}" class="answer-img-upvote" + src="{% blockresource %}/content/images/vote-arrow-up{% get_user_vote_image user_answer_votes answer.id 1 %}.png{% endblockresource %}" + alt="{% trans "i like this answer (click again to cancel)" %}" + title="{% trans "i like this answer (click again to cancel)" %}"/> + <div id="answer-vote-number-{{ answer.id }}" class="vote-number" title="{% trans "current number of votes" %}"> + {{ answer.score }} + </div> + <img id="answer-img-downvote-{{ answer.id }}" class="answer-img-downvote" + src="{% blockresource %}/content/images/vote-arrow-down{% get_user_vote_image user_answer_votes answer.id -1 %}.png{% endblockresource %}" + alt="{% trans "i dont like this answer (click again to cancel)" %}" + title="{% trans "i dont like this answer (click again to cancel)" %}" /> + + {% ifequal request.user question.author %} + <img id="answer-img-accept-{{ answer.id }}" class="answer-img-accept" + src="{% blockresource %}/content/images/vote-accepted{% if answer.accepted %}-on{% endif %}.png{% endblockresource %}" + alt="{% trans "mark this answer as favorite (click again to undo)" %}" + title="{% trans "mark this answer as favorite (click again to undo)" %}" /> + {% else %} + {% if answer.accepted %} + <img id="answer-img-accept-{{ answer.id }}" class="answer-img-accept" + src="{% blockresource %}/content/images/vote-accepted{% if answer.accepted %}-on{% endif %}.png{% endblockresource %}" + alt="{% trans "the author of the question has selected this answer as correct" %}" + title="{% trans "the author of the question has selected this answer as correct" %}" /> + {% endif %} + {% endifequal %} + </div> + </td> + <td> + <div class="item-right"> + <div class="answer-body"> + {{ answer.html|safe }} + </div> + <div class="answer-controls post-controls"> + {% joinitems using '<span class="action-link-separator">|</span>' %} + <span class="linksopt"> + <a href="#{{ answer.id }}" title="{% trans "answer permanent link" %}"> + {% trans "permanent link" %} + </a> + </span> + {% separator %} + {% if request.user|can_edit_post:answer %} + <span class="action-link"><a href="{% url edit_answer answer.id %}">{% trans 'edit' %}</a></span> + {% endif %} + {% separator %} + + {% if request.user|can_flag_offensive %} + <span id="answer-offensive-flag-{{ answer.id }}" class="offensive-flag" + title="{% trans "report as offensive (i.e containing spam, advertising, malicious text, etc.)" %}"> + <a>{% trans "flag offensive" %}</a> + {% if request.user|can_view_offensive_flags and answer.offensive_flag_count %} + <span class="darkred">({{ answer.offensive_flag_count }})</span> + {% endif %} + </span> + {% endif %} + {% separator %} + {% if request.user|can_delete_post:answer %} + {% spaceless %} + <span class="action-link"> + <a id="answer-delete-link-{{answer.id}}"> + {% if answer.deleted %}{% trans "undelete" %}{% else %}{% trans "delete" %}{% endif %}</a> + </span> + {% endspaceless %} + {% endif %} + {% endjoinitems %} + </div> + <div class="post-update-info-container"> + {% post_contributor_info answer "original_author" %} + {% post_contributor_info answer "last_updater" %} + </div> + <div class="comments-container" id="comments-container-answer-{{answer.id}}"> + {% for comment in answer.get_comments|slice:":5" %} + <p id="comment-{{comment.id}}" class="comment"> + {{comment.comment}} + - <a class="comment-user" href="{{comment.user.get_profile_url}}">{{comment.user}}</a> + {% spaceless %} + <span class="comment-age">({% diff_date comment.added_at %})</span> + {% if request.user|can_delete_comment:comment %} + <img class="delete-icon" + src="{% href "/content/images/close-small.png" %}" + title="{% trans "delete this comment" %}"/> + {% endif %} + {% endspaceless %} + </p> + {% endfor %} + </div> + <div class="post-comments" style="margin-bottom:20px"> + <input id="can-post-comments-answer-{{answer.id}}" type="hidden" value="{{ request.user|can_add_comments:answer}}"/> + {% if request.user|can_add_comments:answer or answer.comment_count > 5 %} + <a id="comments-link-answer-{{answer.id}}" class="comments-link"> + {% if request.user|can_add_comments:answer %} + {% trans "add comment" %} + {% endif %} + {% if answer.comment_count > 5 %} + {% if request.user|can_add_comments:answer %}/ + {% blocktrans count answer.get_comments|slice:"5:"|length as counter %} + see <strong>one</strong> more + {% plural %} + see <strong>{{counter}}</strong> more + {% endblocktrans %} + {% else %} + {% blocktrans count answer.get_comments|slice:"5:"|length as counter %} + see <strong>one</strong> more comment + {% plural %} + see <strong>{{counter}}</strong> more comments + {% endblocktrans %} + {% endif %} + {% endif %}</a> + {% endif %} + </div> + </div> + <div id="comment-{{ answer.id }}" class="post-comments" > + <input id="can-post-comments-answer-{{answer.id}}" type="hidden" value="{{ request.user|can_add_comments }}"/> + <a id="comments-link-answer-{{answer.id}}" class="comments-link"> + {% if answer.comment_count %}{% trans "comments" %} + <strong>({{answer.comment_count}})</strong>{% else %}{% trans "add comment" %}{% endif %}</a> + <div id="comments-answer-{{answer.id}}" class="comments-container"> + <div class="comments"/></div> + + </td> + </tr> + </table> + </div> + {% endfor %} + <div class="paginator-container-left"> + {% cnprog_paginator context %} + </div> + {% endif %} + <form id="fmanswer" action="{% url answer question.id %}" method="post"> + {% if request.user.is_authenticated %} + <p style="padding-left:3px"> + {{ answer.email_notify }} + <label for="question-subscribe-updates"> + {% ifequal request.user.get_q_sel_email_feed_frequency 'n' %} + {% trans "Notify me once a day when there are any new answers" %} + {% else %} + {% ifequal request.user.get_q_sel_email_feed_frequency 'd' %} + {% trans "Notify me once a day when there are any new answers" %} + {% else %} + {% ifequal request.user.get_q_sel_email_feed_frequency 'w' %} + {% trans "Notify me weekly when there are any new answers" %} + {% endifequal %} + {% endifequal %} + {% endifequal %} + </label> + {% blocktrans with request.user.get_profile_url as profile_url %} + You can always adjust frequency of email updates from your {{profile_url}} + {% endblocktrans %} + </p> + {% else %} + <p style="padding-left:3px"> + <input class="nomargin" type="checkbox" disabled="disabled" /> + <label>{% trans "once you sign in you will be able to subscribe for any updates here" %}</label> + </p> + {% endif %} + <div style="clear:both"> + </div> + + {% if not question.closed %} + <div style="padding:10px 0 0 0;"> + {% spaceless %} + <div class="headNormal"> + {% if answers %} + {% trans "Your answer" %} + {% else %} + {% trans "Be the first one to answer this question!" %} + {% endif %} + </div> + {% endspaceless %} + </div> + {% if not request.user.is_authenticated %} + <div class="message">{% trans "you can answer anonymously and then login" %}</div> + {% else %} + <p class="message"> + {% ifequal request.user question.author %} + {% trans "answer your own question only to give an answer" %} + {% else %} + {% trans "please only give an answer, no discussions" %} + {% endifequal %} + </p> + {% endif %} + + <div id="description" class="" > + <div id="wmd-button-bar" class="wmd-panel"></div> + {{ answer.text }} + <div class="preview-toggle"> + <table width="100%"> + <tr> + <td> + <span id="pre-collapse" + title="{% trans "Toggle the real time Markdown editor preview" %}"> + {% trans "toggle preview" %} + </span> + </td> + {% if settings.WIKI_ON %} + <td style="text-align:right;"> + {{ answer.wiki }} + <span style="font-weight:normal;cursor:help" + title="{{answer.wiki.help_text}}"> + {{ answer.wiki.label_tag }} + </span> + </td> + {% endif %} + </tr> + + </table> + </div> + <div id="previewer" class="wmd-preview"></div> + {{ answer.text.errors }} + </div> + <p><span class="form-error"></span></p> + <input type="submit" + {% if user.is_anonymous %} + value="{% trans "Login/Signup to Post Your Answer" %}" + {% else %} + {% if user == question.author %} + value="{% trans "Answer Your Own Question" %}" + {% else %} + value="{% trans "Answer the question" %}" + {% endif %} + {% endif %} + class="submit" style="float:left"/> + {% endif %} + </form> + </div> +</div> +{% endblock %} + +{% block sidebar %} +<div class="boxC"> + <p> + {% trans "Question tags" %}: + </p> + <p class="tags" > + {% for tag in tags %} + <a href="{% url forum.views.tag tag.name|urlencode %}" + title="{% trans "see questions tagged"%}'{{tag.name}}'{% trans "using tags" %}" + rel="tag">{{ tag.name }}</a> <span class="tag-number">×{{ tag.used_count|intcomma }}</span><br/> + {% endfor %} + </p> + <p> + {% trans "question asked" %}: <strong title="{{ question.added_at }}">{% diff_date question.added_at %}</strong> + </p> + <p> + {% trans "question was seen" %}: <strong>{{ question.view_count|intcomma }} {% trans "times" %}</strong> + </p> + <p> + {% trans "last updated" %}: <strong title="{{ question.last_activity_at }}">{% diff_date question.last_activity_at %}</strong> + </p> +</div> + +<div class="boxC"> + <h3 class="subtitle">{% trans "Related questions" %}</h3> + <div class="questions-related"> + {% for question in similar_questions %} + <p> + <a href="{{ question.get_absolute_url }}">{{ question.get_question_title }}</a> + </p> + {% endfor %} + </div> +</div> + +{% endblock %} + +{% block endjs %} +{% endblock %} +<!-- end question.html --> +======= {% extends "base.html" %}
<!-- question.html -->
{% load extra_tags %}
@@ -506,3 +1026,4 @@ {% block endjs %}
{% endblock %}
<!-- end question.html -->
+>>>>>>> evgenyfadeev/master:templates/question.html diff --git a/forum/skins/default/templates/question_edit.html b/forum/skins/default/templates/question_edit.html index fe711849..5a6268c9 100644 --- a/forum/skins/default/templates/question_edit.html +++ b/forum/skins/default/templates/question_edit.html @@ -114,6 +114,12 @@ <div class="title-desc"> {{ form.summary.help_text }} </div> + <br> + + <p class="form-item"> + <strong>{{ form.categories.label_tag }}:</strong> {% trans "(required)" %} <span class="form-error"></span><br> + {{ form.categories }} {{ form.categories.errors }} + </p> <div class="error" ></div> <input type="submit" value="{% trans "Save edit" %}" class="submit" /> <input type="button" value="{% trans "Cancel" %}" class="submit" onclick="history.back(-1);" /> diff --git a/forum/skins/default/templates/questions.html b/forum/skins/default/templates/questions.html index 4c3b96d2..2e593f90 100644 --- a/forum/skins/default/templates/questions.html +++ b/forum/skins/default/templates/questions.html @@ -1,3 +1,277 @@ +<<<<<<< HEAD:templates/questions.html +{% extends "base.html" %} +<!-- questions.html --> +{% load extra_tags %} +{% load i18n %} +{% load humanize %} +{% load extra_filters %} +{% load smart_if %} +{% block title %}{% spaceless %}{% trans "Questions" %}{% endspaceless %}{% endblock %} +{% block forejs %} + <script type="text/javascript"> + var tags = {{ tags_autocomplete|safe }}; + $().ready(function(){ + var tab_id = "{{ tab_id }}"; + $("#"+tab_id).attr('className',"on"); + var on_tab = {% if is_unanswered %}'#nav_unanswered'{% else %}'#nav_questions'{% endif %}; + $(on_tab).attr('className','on'); + Hilite.exact = false; + Hilite.elementid = "listA"; + Hilite.debug_referrer = location.href; + }); + </script> + <script type='text/javascript' src='{% href "/content/js/com.cnprog.editor.js" %}'></script> + <script type='text/javascript' src='{% href "/content/js/com.cnprog.tag_selector.js" %}'></script> +{% endblock %} +{% block content %} +<div class="tabBar"> +<<<<<<< HEAD:templates/questions.html + <div class="headQuestions">{% if searchtag %}{% trans "Found by tags" %}{% else %}{% if searchtitle %}{% trans "Found by title" %}{% else %}{% trans "All questions" %}{% endif %}{% endif %}</div> +======= + <div class="headQuestions"> + {% if searchtag %} + {% trans "Found by tags" %} + {% else %} + {% if searchtitle %} + {% if settings.USE_SPHINX_SEARCH %} + {% trans "Search results" %} + {% else %} + {% trans "Found by title" %} + {% endif %} + {% else %} + {% if is_unanswered %} + {% trans "Unanswered questions" %} + {% else %} + {% trans "All questions" %} + {% endif %} + {% endif %} + {% endif %} + </div> +>>>>>>> 82d35490db90878f013523c4d1a5ec3af2df8b23:templates/questions.html + <div class="tabsA"> + <a id="latest" href="?sort=latest" class="off" title="{% trans "most recently asked questions" %}">{% trans "newest" %}</a> + <a id="active" href="?sort=active" class="off" title="{% trans "most recently updated questions" %}">{% trans "active" %}</a> + <a id="hottest" href="?sort=hottest" class="off" title="{% trans "hottest questions" %}">{% trans "hottest" %}</a> + <a id="mostvoted" href="?sort=mostvoted" class="off" title="{% trans "most voted questions" %}">{% trans "most voted" %}</a> + </div> +</div> +<div id="listA"> + {% for question in questions.object_list %} + <div class="qstA" + {% if request.user.is_authenticated %} + {% if question.interesting_score > 0 %} + style="background:#ffff99;" + {% else %} + {% if not request.user.hide_ignored_questions %} + {% if question.ignored_score > 0 %} + style="background:#f3f3f3;" + {% endif %} + {% endif %} + {% endif %} + {% endif %} + > + <h2> + <a href="{{ question.get_absolute_url }}">{{ question.get_question_title }}</a> + </h2> + <div class="stat"> + <table> + <tr> + <td><span class="num">{{ question.answer_count|intcomma }}</span> </td> + <td><span class="num">{{ question.score|intcomma }}</span> </td> + <td><span class="num">{{ question.view_count|cnprog_intword|safe }}</span> </td> + </tr> + <tr> + <td><span class="unit">{% trans "answers" %}</span></td> + <td><span class="unit">{% trans "votes" %}</span></td> + <td><span class="unit">{% trans "views" %}</span></td> + </tr> + </table> + </div> + + <div class="summary"> + {{ question.summary }}... + </div> + + {% ifequal tab_id 'active'%} + {% if question.wiki and settings.WIKI_ON %} + <span class="from wiki">{% trans "community wiki" %}</span> + <span class="date" title="{{ question.added_at }}">{% diff_date question.added_at %}</span> + {% else %} + <div class="from"> + {% comment %}{% gravatar question.last_activity_by 24 %}{% endcomment %} + <span class="author"><a href="{{ question.last_activity_by.get_profile_url }}">{{ question.last_activity_by }}</a></span> + <span class="score">{% get_score_badge question.last_activity_by %} </span> + <span class="date" title="{{ question.last_activity_at }}">{% diff_date question.last_activity_at %}</span> + </div> + {% endif %} + {% else %} + {% if question.wiki and settings.WIKI_ON %} + <span class="from wiki">{% trans "community wiki" %}</span> + <span class="date" title="{{ question.added_at }}">{% diff_date question.added_at %}</span> + {% else %} + <div class="from"> + {% comment %}{% gravatar question.author 24 %}{% endcomment %} + {% if question.last_activity_at != question.added_at %} + {% if question.author.id != question.last_activity_by.id %} + {% trans "Posted:" %} + <span class="author"><a href="{{ question.author.get_profile_url }}">{{ question.author }}</a></span> + <span class="score">{% get_score_badge question.author %} </span> + / {% trans "Updated:" %} + <span class="author"><a href="{{ question.last_activity_by.get_profile_url }}">{{ question.last_activity_by }}</a></span> + <span class="score">{% get_score_badge question.last_activity_by %} </span> + <span class="date" title="{{ question.last_activity_at }}">{% diff_date question.last_activity_at %}</span> + {% else %} + {% trans "Updated:" %} + <span class="author"><a href="{{ question.last_activity_by.get_profile_url }}">{{ question.last_activity_by }}</a></span> + <span class="score">{% get_score_badge question.last_activity_by %} </span> + <span class="date" title="{{ question.last_activity_at }}">{% diff_date question.last_activity_at %}</span> + {% endif %} + {% else %} + {% trans "Posted:" %} + <span class="author"><a href="{{ question.author.get_profile_url }}">{{ question.author }}</a></span> + <span class="score">{% get_score_badge question.author %} </span> + <span class="date" title="{{ question.added_at }}">{% diff_date question.added_at %}</span> + {% endif %} + </div> + {% endif %} + {% endifequal %} + + <div class="tags"> + {% for tag in question.tagname_list %} + <a href="{% url forum.views.tag tag|urlencode %}" title="{% trans "see questions tagged" %}'{{ tag }}'{% trans "using tags" %}" rel="tag">{{ tag }}</a> + {% endfor %} + </div> + {%trans "Category: "%}<a href="{% url forum.views.category question.category|urlencode %}">{{ question.category}}</a> + </div> + {% endfor %} + {% if searchtitle %} + {% if questions_count == 0 %} + <p class="evenMore" style="padding-top:30px;text-align:center;"> + {% trans "Did not find anything?" %} + {% else %} + <p class="evenMore" style="padding-left:9px"> + {% trans "Did not find what you were looking for?" %} + {% endif %} + <a href="{% url ask %}">{% trans "Please, post your question!" %}</a> + </p> + {% endif %} +</div> +{% endblock %} + +{% block tail %} + <div class="pager">{% cnprog_paginator context %}</div> + <div class="pagesize">{% cnprog_pagesize context %}</div> +{% endblock %} + +{% block sidebar %} +<div class="boxC"> + {% if searchtag %} +<<<<<<< HEAD:templates/questions.html + {% blocktrans count questions_count as cnt with questions_count|intcomma as q_num and searchtag as tagname %} + have total {{q_num}} questions tagged {{tagname}} + {% plural %} + have total {{q_num}} questions tagged {{tagname}} + {% endblocktrans %} + {% else %} + {% if searchtitle %} + {% blocktrans count questions_count as cnt with questions_count|intcomma as q_num %} + have total {{q_num}} questions containing {{searchtitle}} + {% plural %} + have total {{q_num}} questions containing {{searchtitle}} + {% endblocktrans %} + {% else %} + {% blocktrans count questions as cnt with questions_count|intcomma as q_num %} + have total {{q_num}} questions + {% plural %} + have total {{q_num}} questions + {% endblocktrans %} + {% endif %} + {% endif %} + <p> +======= + {% blocktrans count questions_count as cnt with questions_count|intcomma as q_num and searchtag as tagname %} + have total {{q_num}} questions tagged {{tagname}} + {% plural %} + have total {{q_num}} questions tagged {{tagname}} + {% endblocktrans %} + {% else %} + {% if searchtitle %} + {% if settings.USE_SPHINX_SEARCH %} + {% blocktrans count questions_count as cnt with questions_count|intcomma as q_num %} + have total {{q_num}} questions containing {{searchtitle}} in full text + {% plural %} + have total {{q_num}} questions containing {{searchtitle}} in full text + {% endblocktrans %} + {% else %} + {% blocktrans count questions_count as cnt with questions_count|intcomma as q_num %} + have total {{q_num}} questions containing {{searchtitle}} + {% plural %} + have total {{q_num}} questions containing {{searchtitle}} + {% endblocktrans %} + {% endif %} + {% else %} + {% if is_unanswered %} + {% blocktrans count questions as cnt with questions_count|intcomma as q_num %} + have total {{q_num}} unanswered questions + {% plural %} + have total {{q_num}} unanswered questions + {% endblocktrans %} + {% else %} + {% blocktrans count questions as cnt with questions_count|intcomma as q_num %} + have total {{q_num}} questions + {% plural %} + have total {{q_num}} questions + {% endblocktrans %} + {% endif %} + {% endif %} + {% endif %} + <p class="nomargin"> +>>>>>>> 82d35490db90878f013523c4d1a5ec3af2df8b23:templates/questions.html + {% ifequal tab_id "latest" %} + {% trans "latest questions info" %} + {% endifequal %} + + {% ifequal tab_id "active" %} + {% trans "Questions are sorted by the <strong>time of last update</strong>." %} + {% trans "Most recently answered ones are shown first." %} + {% endifequal %} + + {% ifequal tab_id "hottest" %} + {% trans "Questions sorted by <strong>number of responses</strong>." %} + {% trans "Most answered questions are shown first." %} + {% endifequal %} + + {% ifequal tab_id "mostvoted" %} + {% trans "Questions are sorted by the <strong>number of votes</strong>." %} + {% trans "Most voted questions are shown first." %} + {% endifequal %} + </p> +</div> +{% if request.user.is_authenticated %} +{% include "tag_selector.html" %} +{% endif %} +<div class="boxC"> + <h3 class="subtitle">{% trans "Related tags" %}</h3> + <div class="tags"> + {% for tag in tags %} +<<<<<<< HEAD:templates/questions.html + <a rel="tag" title="{% trans "see questions tagged" %}'{{ tag.name }}'{% trans "using tags" %}" href="{% url forum.views.tag tag.name|urlencode %}">{{ tag.name }}</a> + <span class="tag-number">× {{ tag.used_count|intcomma }}</span> + <br /> + {% endfor %} + <br /> +======= + <a rel="tag" title="{% blocktrans with tag.name as tag_name %}see questions tagged '{{ tag_name }}'{% endblocktrans %}" href="{% url forum.views.tag tag.name|urlencode %}">{{ tag.name }}</a> + <span class="tag-number">× {{ tag.used_count|intcomma }}</span> + <br /> + {% endfor %} +>>>>>>> 82d35490db90878f013523c4d1a5ec3af2df8b23:templates/questions.html + </div> +</div> + +{% endblock %} +<!-- end questions.html --> +======= {% extends "base.html" %}
<!-- questions.html -->
{% load extra_tags %}
@@ -233,3 +507,4 @@ {% endblock %}
<!-- end questions.html -->
+>>>>>>> evgenyfadeev/master:templates/questions.html diff --git a/forum/skins/default/templates/user_email_subscriptions.html b/forum/skins/default/templates/user_email_subscriptions.html index c0204cbc..10440529 100644 --- a/forum/skins/default/templates/user_email_subscriptions.html +++ b/forum/skins/default/templates/user_email_subscriptions.html @@ -13,9 +13,12 @@ {% endif %} <form method="POST"> {% include "edit_user_email_feeds_form.html" %} +<<<<<<< HEAD:templates/user_email_subscriptions.html +======= <table class='form-as-table'> {{tag_filter_selection_form}} </table> +>>>>>>> 82d35490db90878f013523c4d1a5ec3af2df8b23:templates/user_email_subscriptions.html <div class="submit-row text-align-right"> <input type="submit" class="submit" name="save" value="{% trans "Update" %}"/> <input type="submit" class="submit" name="stop_email" value="{% trans "Stop sending email" %}"/> diff --git a/forum/skins/default/templates/user_info.html b/forum/skins/default/templates/user_info.html index c550e13f..4ebcddd6 100644 --- a/forum/skins/default/templates/user_info.html +++ b/forum/skins/default/templates/user_info.html @@ -19,7 +19,7 @@ <tr> <td align="center"> <div class="scoreNumber">{{view_user.reputation|intcomma}}</div> - <p><b style="color:#777;">{% trans "reputation" %}</b></p> + <p><b style="color:#777;">{% trans "karma" %}</b></p> </td> </tr> </table> |