diff options
-rw-r--r-- | django_authopenid/urls.py | 8 | ||||
-rw-r--r-- | django_authopenid/views.py | 2 | ||||
-rw-r--r-- | forum/admin.py | 4 | ||||
-rw-r--r-- | forum/forms.py | 5 | ||||
-rw-r--r-- | forum/managers.py | 4 | ||||
-rw-r--r-- | forum/models.py | 11 | ||||
-rw-r--r-- | forum/views.py | 48 | ||||
-rw-r--r-- | locale/es/LC_MESSAGES/django.mo | bin | 49734 -> 49900 bytes | |||
-rw-r--r-- | locale/es/LC_MESSAGES/django.po | 486 | ||||
-rw-r--r-- | templates/ask.html | 7 | ||||
-rw-r--r-- | templates/authopenid/sendpw.html | 2 | ||||
-rw-r--r-- | templates/authopenid/signin.html | 11 | ||||
-rw-r--r-- | templates/categories.html | 56 | ||||
-rw-r--r-- | templates/footer.html | 8 | ||||
-rw-r--r-- | templates/header.html | 1 | ||||
-rw-r--r-- | templates/index.html | 17 | ||||
-rw-r--r-- | templates/question.html | 1 | ||||
-rw-r--r-- | templates/question_edit.html | 6 | ||||
-rw-r--r-- | templates/questions.html | 1 | ||||
-rw-r--r-- | urls.py | 3 |
20 files changed, 427 insertions, 254 deletions
diff --git a/django_authopenid/urls.py b/django_authopenid/urls.py index 9c0887d8..d932a48d 100644 --- a/django_authopenid/urls.py +++ b/django_authopenid/urls.py @@ -15,10 +15,10 @@ urlpatterns = patterns('django_authopenid.views', url(r'^%s$' % _('register/'), 'register', name='user_register'), url(r'^%s$' % _('signup/'), 'signup', name='user_signup'), #disable current sendpw function - url(r'^%s$' % _('sendpw/'), 'signin', name='user_sendpw'), - #url(r'^%s$' % _('sendpw/'), 'sendpw', name='user_sendpw'), - #url(r'^%s%s$' % (_('password/'), _('confirm/')), 'confirmchangepw', - # name='user_confirmchangepw'), + #url(r'^%s$' % _('sendpw/'), 'signin', name='user_sendpw'), + url(r'^%s$' % _('sendpw/'), 'sendpw', name='sendpw'), + url(r'^%s%s$' % (_('password/'), _('confirm/')), 'confirmchangepw', + name='user_confirmchangepw'), # manage account settings #url(r'^$', _('account_settings'), name='user_account_settings'), diff --git a/django_authopenid/views.py b/django_authopenid/views.py index 218a31a2..95898a81 100644 --- a/django_authopenid/views.py +++ b/django_authopenid/views.py @@ -223,7 +223,7 @@ def signin(request,newquestion=False,newanswer=False): 'form1': form_auth, 'form2': form_signin, 'msg': request.GET.get('msg',''), - 'sendpw_url': reverse('user_sendpw'), + 'sendpw_url': reverse('sendpw'), }, context_instance=RequestContext(request)) def complete_signin(request): diff --git a/forum/admin.py b/forum/admin.py index 482da048..c326a034 100644 --- a/forum/admin.py +++ b/forum/admin.py @@ -13,6 +13,9 @@ class QuestionAdmin(admin.ModelAdmin): class TagAdmin(admin.ModelAdmin): """Tag admin class""" +class CategoryAdmin(admin.ModelAdmin): + """Category admin class""" + class Answerdmin(admin.ModelAdmin): """Answer admin class""" @@ -58,6 +61,7 @@ class BookAuthorRssAdmin(admin.ModelAdmin): admin.site.register(Question, QuestionAdmin) admin.site.register(Tag, TagAdmin) +admin.site.register(Category, CategoryAdmin) admin.site.register(Answer, Answerdmin) admin.site.register(Comment, CommentAdmin) admin.site.register(Vote, VoteAdmin) diff --git a/forum/forms.py b/forum/forms.py index 59d0d620..127210c5 100644 --- a/forum/forms.py +++ b/forum/forms.py @@ -95,6 +95,8 @@ class AskForm(forms.Form): tags = TagNamesField() wiki = WikiField() + categories = forms.ModelChoiceField(help_text=_('please choice a category'), + queryset=Category.objects.all(), label=_('Category')) openid = forms.CharField(required=False, max_length=255, widget=forms.TextInput(attrs={'size' : 40, 'class':'openid-input'})) user = forms.CharField(required=False, max_length=255, widget=forms.TextInput(attrs={'size' : 35})) email = forms.CharField(required=False, max_length=255, widget=forms.TextInput(attrs={'size' : 35})) @@ -154,6 +156,9 @@ class EditQuestionForm(forms.Form): tags = TagNamesField() summary = SummaryField() + categories = forms.ModelChoiceField(help_text=_('please choice a category'), + queryset=Category.objects.all(), label=_('Category')) + def __init__(self, question, revision, *args, **kwargs): super(EditQuestionForm, self).__init__(*args, **kwargs) self.fields['title'].initial = revision.title diff --git a/forum/managers.py b/forum/managers.py index 2e3e4186..314f022f 100644 --- a/forum/managers.py +++ b/forum/managers.py @@ -18,6 +18,10 @@ class QuestionManager(models.Manager): def get_questions_by_tag(self, tagname, orderby): questions = self.filter(deleted=False, tags__name = unquote(tagname)).order_by(orderby) return questions + + def get_questions_by_category(self, categoryname, orderby): + questions = self.filter(category__name = categoryname).order_by(orderby) + return questions def get_unanswered_questions(self, orderby): questions = self.filter(deleted=False, answer_count=0).order_by(orderby) diff --git a/forum/models.py b/forum/models.py index f647ba12..04745a4a 100644 --- a/forum/models.py +++ b/forum/models.py @@ -17,6 +17,12 @@ import settings from forum.managers import * from const import * +class Category(models.Model): + name = models.CharField(max_length=50, unique = True) + + def __unicode__(self): + return self.name + class EmailFeed(models.Model): #subscription key for unsubscribe by visiting emailed link key = models.CharField(max_length=32) @@ -122,6 +128,7 @@ class Question(models.Model): author = models.ForeignKey(User, related_name='questions') added_at = models.DateTimeField(default=datetime.datetime.now) tags = models.ManyToManyField(Tag, related_name='questions') + category = models.ForeignKey(Category, related_name='questions') # Status wiki = models.BooleanField(default=False) wikified_at = models.DateTimeField(null=True, blank=True) @@ -655,10 +662,10 @@ def record_comment_event(instance, created, **kwargs): from django.contrib.contenttypes.models import ContentType question_type = ContentType.objects.get_for_model(Question) question_type_id = question_type.id - if (instance.content_type_id == question_type_id): + if (instance.content_type_id == question_type_id): type = TYPE_ACTIVITY_COMMENT_QUESTION else: - type = TYPE_ACTIVITY_COMMENT_ANSWER + type=TYPE_ACTIVITY_COMMENT_ANSWER activity = Activity(user=instance.user, active_at=instance.added_at, content_object=instance, activity_type=type) activity.save() diff --git a/forum/views.py b/forum/views.py index d663a4cb..10438982 100644 --- a/forum/views.py +++ b/forum/views.py @@ -106,7 +106,7 @@ def privacy(request): def unanswered(request): return questions(request, unanswered=True) -def questions(request, tagname=None, unanswered=False): +def questions(request, tagname=None, categoryname=None, unanswered=False): """ List of Questions, Tagged questions, and Unanswered questions. """ @@ -137,6 +137,8 @@ def questions(request, tagname=None, unanswered=False): #check if request is from unanswered questions template_file = "unanswered.html" objects = Question.objects.get_unanswered_questions(orderby) + elif categoryname: + objects = Question.objects.get_questions_by_category(categoryname, orderby) else: objects = Question.objects.get_questions(orderby) @@ -223,7 +225,7 @@ def create_new_answer( question=None, author=None,\ def create_new_question(title=None,author=None,added_at=None, wiki=False,tagnames=None,summary=None, - text=None): + text=None, category=None): """this is not a view and maybe should become one of the methods on Question object? """ @@ -237,7 +239,8 @@ def create_new_question(title=None,author=None,added_at=None, wiki = wiki, tagnames = tagnames, html = html, - summary = summary + summary = summary, + category = category ) if question.wiki: question.last_edited_by = question.author @@ -273,6 +276,7 @@ def ask(request): text = form.cleaned_data['text'] html = sanitize_html(markdowner.convert(text)) summary = strip_tags(html)[:120] + category = form.cleaned_data['categories'] if request.user.is_authenticated(): author = request.user @@ -284,7 +288,8 @@ def ask(request): wiki = wiki, tagnames = tagnames, summary = summary, - text = text + text = text, + category = category ) return HttpResponseRedirect(question.get_absolute_url()) @@ -513,6 +518,7 @@ def _edit_question(request, question): 'tagnames': form.cleaned_data['tags'], 'summary': strip_tags(html)[:120], 'html': html, + 'category': form.cleaned_data['categories'] } # only save when it's checked @@ -746,6 +752,40 @@ def tags(request): def tag(request, tag): return questions(request, tagname=tag) +def categories(request): + is_paginated = True + sortby = request.GET.get('sort', 'used') + try: + page = int(request.GET.get('page', '1')) + except ValueError: + page = 1 + + if request.method == "GET": + objects_list = Paginator(Category.objects.all(), DEFAULT_PAGE_SIZE) + + try: + categories = objects_list.page(page) + except (EmptyPage, InvalidPage): + categories = objects_list.page(objects_list.num_pages) + + return render_to_response('categories.html', { + "categories" : categories, + "context" : { + 'is_paginated' : is_paginated, + 'pages': objects_list.num_pages, + 'page': page, + 'has_previous': categories.has_previous(), + 'has_next': categories.has_next(), + 'previous': categories.previous_page_number(), + 'next': categories.next_page_number(), + 'base_url': '/categorias/' + } + + }, context_instance=RequestContext(request)) + +def category(request, category): + return questions(request, categoryname=category) + def vote(request, id): """ vote_type: diff --git a/locale/es/LC_MESSAGES/django.mo b/locale/es/LC_MESSAGES/django.mo Binary files differindex bdd1b3b2..77746600 100644 --- a/locale/es/LC_MESSAGES/django.mo +++ b/locale/es/LC_MESSAGES/django.mo diff --git a/locale/es/LC_MESSAGES/django.po b/locale/es/LC_MESSAGES/django.po index b7324b7f..3d9e8297 100644 --- a/locale/es/LC_MESSAGES/django.po +++ b/locale/es/LC_MESSAGES/django.po @@ -2,22 +2,21 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-08-12 15:53+0000\n" -"PO-Revision-Date: 2009-08-16 17:05-0600\n" +"POT-Creation-Date: 2009-08-16 23:31+0000\n" +"PO-Revision-Date: 2009-08-16 17:32-0600\n" "Last-Translator: Bruno Sarlo <bsarlo@gmail.com>\n" "Language-Team: LANGUAGE <LL@li.org>\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: settings.py:12 urls.py:25 forum/views.py:304 forum/views.py:698 +#: settings.py:12 urls.py:25 forum/views.py:310 forum/views.py:705 msgid "account/" msgstr "cuenta/" #: settings.py:12 urls.py:26 django_authopenid/urls.py:9 #: django_authopenid/urls.py:10 django_authopenid/urls.py:11 -#: django_authopenid/urls.py:13 forum/views.py:304 forum/views.py:699 -#: templates/authopenid/confirm_email.txt:10 +#: django_authopenid/urls.py:13 forum/views.py:310 forum/views.py:706 msgid "signin/" msgstr "ingresar/" @@ -58,7 +57,7 @@ msgstr "códigodeprivacidad/" msgid "logout/" msgstr "cerrarsesion/" -#: urls.py:34 urls.py:35 urls.py:36 urls.py:48 forum/models.py:418 +#: urls.py:34 urls.py:35 urls.py:36 urls.py:48 forum/models.py:425 msgid "answers/" msgstr "respuestas/" @@ -76,7 +75,8 @@ msgstr "revisiones/" #: urls.py:37 urls.py:38 urls.py:39 urls.py:40 urls.py:41 urls.py:42 #: urls.py:43 urls.py:44 urls.py:45 urls.py:46 urls.py:47 forum/feed.py:19 -#: forum/models.py:306 forum/views.py:1416 +#: forum/models.py:313 forum/views.py:1228 forum/views.py:1230 +#: forum/views.py:1470 msgid "questions/" msgstr "preguntas/" @@ -112,12 +112,12 @@ msgstr "borrar/" msgid "question/" msgstr "pregunta/" -#: urls.py:51 urls.py:52 forum/views.py:740 forum/views.py:2013 +#: urls.py:51 urls.py:52 forum/views.py:747 forum/views.py:2067 msgid "tags/" msgstr "etiquetas/" -#: urls.py:53 urls.py:54 urls.py:55 forum/views.py:993 forum/views.py:997 -#: forum/views.py:1418 forum/views.py:1751 forum/views.py:2015 +#: urls.py:53 urls.py:54 urls.py:55 forum/views.py:1034 forum/views.py:1038 +#: forum/views.py:1472 forum/views.py:1805 forum/views.py:2069 msgid "users/" msgstr "usuarios/" @@ -240,7 +240,7 @@ msgstr "la nueva contraseña no coincide" msgid "Incorrect username." msgstr "Nombre de usuario incorrecto" -#: django_authopenid/urls.py:10 forum/views.py:304 forum/views.py:699 +#: django_authopenid/urls.py:10 forum/views.py:310 forum/views.py:706 msgid "newquestion/" msgstr "nuevapregunta/" @@ -264,10 +264,19 @@ msgstr "registrarse/" msgid "signup/" msgstr "registrarse/" -#: django_authopenid/urls.py:18 +#: django_authopenid/urls.py:19 msgid "sendpw/" msgstr "enviarcontrasena/" +#: django_authopenid/urls.py:20 +#, fuzzy +msgid "password/" +msgstr "contraseña" + +#: django_authopenid/urls.py:20 +msgid "confirm/" +msgstr "" + #: django_authopenid/urls.py:27 msgid "validate/" msgstr "" @@ -523,8 +532,8 @@ msgstr "" "por favor use solo los siguientes caracteres en los nombres de etiquetas: " "letras 'a-z', números y caracteres '.-_#'" -#: forum/forms.py:75 templates/index.html:57 templates/question.html:209 -#: templates/question.html.py:395 templates/questions.html:58 +#: forum/forms.py:75 templates/index.html:64 templates/question.html:210 +#: templates/question.html.py:396 templates/questions.html:58 #: templates/questions.html.py:70 templates/unanswered.html:48 #: templates/unanswered.html.py:60 msgid "community wiki" @@ -550,75 +559,84 @@ msgstr "" "ingresa un breve resumen de tu revisión (ej. error ortográfico, gramática, " "mejoras de estilo. Este campo es opcional." -#: forum/forms.py:175 +#: forum/forms.py:98 forum/forms.py:159 +msgid "please choice a category" +msgstr "por favor escoja una categoría" + +#: forum/forms.py:99 forum/forms.py:160 +msgid "Category" +msgstr "Categoría" + +#: forum/forms.py:180 msgid "this email does not have to be linked to gravatar" msgstr "este email no tiene porque estar asociado a un Gravatar" -#: forum/forms.py:176 +#: forum/forms.py:181 msgid "Real name" msgstr "Nombre real" -#: forum/forms.py:177 +#: forum/forms.py:182 msgid "Website" msgstr "Sitio Web" -#: forum/forms.py:178 +#: forum/forms.py:183 msgid "Location" msgstr "Ubicación" -#: forum/forms.py:179 +#: forum/forms.py:184 msgid "Date of birth" msgstr "Fecha de nacimiento" -#: forum/forms.py:179 +#: forum/forms.py:184 msgid "will not be shown, used to calculate age, format: YYYY-MM-DD" msgstr "no será mostrado, usado para calcular la edad. Formato: YYY-MM-DD" -#: forum/forms.py:180 templates/authopenid/settings.html:21 +#: forum/forms.py:185 templates/authopenid/settings.html:21 msgid "Profile" msgstr "Perfil" -#: forum/forms.py:207 forum/forms.py:208 +#: forum/forms.py:212 forum/forms.py:213 msgid "this email has already been registered, please use another one" msgstr "este email ya ha sido registrado, por favor use otro" -#: forum/models.py:246 +#: forum/models.py:253 +#, python-format msgid "%(author)s modified the question" msgstr "%(author)s modificó la pregunta" -#: forum/models.py:250 +#: forum/models.py:257 #, python-format msgid "%(people)s posted %(new_answer_count)s new answers" msgstr "%(people)s publicaron %(new_answer_count)s nuevas respuestas" -#: forum/models.py:255 +#: forum/models.py:262 #, python-format msgid "%(people)s commented the question" msgstr "%(people)s comentarion la pregunta" -#: forum/models.py:260 +#: forum/models.py:267 #, python-format msgid "%(people)s commented answers" msgstr "%(people)s comentaron la respuesta" -#: forum/models.py:262 +#: forum/models.py:269 #, python-format msgid "%(people)s commented an answer" msgstr "%(people)s comentaron la respuesta" -#: forum/models.py:306 forum/models.py:418 +#: forum/models.py:313 forum/models.py:425 msgid "revisions" msgstr "revisiones/" -#: forum/models.py:441 templates/badges.html:51 +#: forum/models.py:448 templates/badges.html:51 msgid "gold" msgstr "oro" -#: forum/models.py:442 templates/badges.html:59 +#: forum/models.py:449 templates/badges.html:59 msgid "silver" msgstr "plata" -#: forum/models.py:443 templates/badges.html:66 +#: forum/models.py:450 templates/badges.html:66 msgid "bronze" msgstr "bronce" @@ -706,27 +724,27 @@ msgstr "preferencias del usuario" msgid "profile - user preferences" msgstr "perfil - preferencia de " -#: forum/views.py:947 +#: forum/views.py:988 #, python-format msgid "subscription saved, %(email)s needs validation" msgstr "subscripción guardada, %(email)s necesita validación" -#: forum/views.py:1860 +#: forum/views.py:1914 msgid "uploading images is limited to users with >60 reputation points" msgstr "para subir imagenes debes tener más de 60 puntos de reputación" -#: forum/views.py:1862 +#: forum/views.py:1916 msgid "allowed file types are 'jpg', 'jpeg', 'gif', 'bmp', 'png', 'tiff'" msgstr "" "los tipos de archivos permitidos son 'jpg', 'jpeg', 'gif', 'bmp', 'png', " "'tiff'" -#: forum/views.py:1864 +#: forum/views.py:1918 #, python-format msgid "maximum upload file size is %sK" msgstr "tamaño máximo permitido es archivo %sK" -#: forum/views.py:1866 +#: forum/views.py:1920 #, python-format msgid "" "Error uploading file. Please contact the site administrator. Thank you. %s" @@ -850,22 +868,22 @@ msgid "select revision" msgstr "seleccionar revisión" #: templates/answer_edit.html:62 templates/ask.html:94 -#: templates/question.html:467 templates/question_edit.html:91 +#: templates/question.html:468 templates/question_edit.html:91 msgid "Toggle the real time Markdown editor preview" msgstr "Activar la visualización en tiempo real de Markdown" #: templates/answer_edit.html:62 templates/ask.html:94 -#: templates/question.html:467 templates/question_edit.html:91 +#: templates/question.html:468 templates/question_edit.html:91 msgid "toggle preview" msgstr "Activar previsualización" -#: templates/answer_edit.html:71 templates/question_edit.html:115 +#: templates/answer_edit.html:71 templates/question_edit.html:121 #: templates/question_retag.html:73 msgid "Save edit" msgstr "Guardar la edición" #: templates/answer_edit.html:72 templates/close.html:29 -#: templates/question_edit.html:116 templates/question_retag.html:74 +#: templates/question_edit.html:122 templates/question_retag.html:74 #: templates/reopen.html:30 templates/user_edit.html:83 #: templates/authopenid/changeemail.html:34 msgid "Cancel" @@ -956,15 +974,16 @@ msgstr "" "a>. <br/> Puedes enviar tu pregunta ahora y validar tu email luego. Tu " "pregunta será guardada mientras tanto y publicada cuando valides tu email." -#: templates/ask.html:107 +#: templates/ask.html:107 templates/ask.html.py:114 +#: templates/question_edit.html:117 msgid "(required)" msgstr "(requerido)" -#: templates/ask.html:114 +#: templates/ask.html:121 msgid "Login/signup to post your question" msgstr "Iniciar sesión/registrarse para publicar su pregunta" -#: templates/ask.html:116 +#: templates/ask.html:123 msgid "Ask your question" msgstr "Haz tu pregunta" @@ -980,7 +999,7 @@ msgstr "Usuarios han sido galardonados con distinciones:" msgid "Badges summary" msgstr "Resumen de distinciones" -#: templates/badges.html:17 templates/user_stats.html:115 +#: templates/badges.html:17 templates/user_stats.html:73 msgid "Badges" msgstr "Distinciones" @@ -1081,17 +1100,17 @@ msgid "ask the author" msgstr "preguntar al autor" #: templates/book.html:88 templates/book.html.py:93 -#: templates/users_questions.html:17 +#: templates/users_questions.html:18 msgid "this question was selected as favorite" msgstr "esta pregunta ha sido seleccionada como favorita" #: templates/book.html:88 templates/book.html.py:93 -#: templates/users_questions.html:11 templates/users_questions.html.py:17 +#: templates/users_questions.html:11 templates/users_questions.html.py:18 msgid "number of times" msgstr "numero de veces" -#: templates/book.html:105 templates/index.html:48 templates/questions.html:46 -#: templates/unanswered.html:37 templates/users_questions.html:30 +#: templates/book.html:105 templates/index.html:55 templates/questions.html:46 +#: templates/unanswered.html:37 templates/users_questions.html:32 msgid "votes" msgstr "votos" @@ -1099,15 +1118,15 @@ msgstr "votos" msgid "the answer has been accepted to be correct" msgstr "la respuesta ha sido aceptada como correcta" -#: templates/book.html:115 templates/index.html:49 templates/questions.html:47 -#: templates/unanswered.html:38 templates/users_questions.html:40 +#: templates/book.html:115 templates/index.html:56 templates/questions.html:47 +#: templates/unanswered.html:38 templates/users_questions.html:42 msgid "views" msgstr "vistas" -#: templates/book.html:125 templates/index.html:69 templates/question.html:499 -#: templates/questions.html:84 templates/questions.html.py:156 +#: templates/book.html:125 templates/index.html:76 templates/question.html:500 +#: templates/questions.html:84 templates/questions.html.py:157 #: templates/tags.html:49 templates/unanswered.html:75 -#: templates/unanswered.html.py:106 templates/users_questions.html:52 +#: templates/unanswered.html.py:106 templates/users_questions.html:54 msgid "using tags" msgstr "usando etiquetas" @@ -1115,10 +1134,27 @@ msgstr "usando etiquetas" msgid "subscribe to book RSS feed" msgstr "suscribirse al RSS del libro" -#: templates/book.html:147 templates/index.html:118 +#: templates/book.html:147 templates/index.html:131 msgid "subscribe to the questions feed" msgstr "suscribirse al agregado de noticias" +#: templates/categories.html:6 templates/categories.html.py:29 +msgid "Category list" +msgstr "Lista de Categorías" + +#: templates/categories.html:34 templates/tags.html:42 +msgid "Nothing found" +msgstr "Nada encontrado" + +#: templates/categories.html:40 +#, fuzzy +msgid "see questions that matches" +msgstr "ver preguntas etiquetadas" + +#: templates/categories.html:40 +msgid "category " +msgstr "categoría" + #: templates/close.html:6 templates/close.html.py:16 msgid "Close question" msgstr "Cerrar pregunta" @@ -1371,16 +1407,17 @@ msgstr "Por favor haz tu pregunta, ¡ayudanos a mejorar nuestra comunidad!" msgid "questions" msgstr "preguntas" -#: templates/faq.html:126 templates/index.html:123 +#: templates/faq.html:126 templates/index.html:137 templates/index.html.py:139 msgid "." msgstr "." -#: templates/footer.html:7 templates/header.html:14 templates/index.html:83 +#: templates/footer.html:7 templates/header.html:14 templates/index.html:91 +#: templates/index.html.py:95 msgid "about" msgstr "acerca de nosotros" -#: templates/footer.html:8 templates/header.html:15 templates/index.html:84 -#: templates/question_edit_tips.html:16 +#: templates/footer.html:8 templates/header.html:15 templates/index.html:92 +#: templates/index.html.py:96 templates/question_edit_tips.html:16 msgid "faq" msgstr "preguntas frecuentes" @@ -1424,7 +1461,7 @@ msgstr "usuarios" msgid "books" msgstr "libros" -#: templates/header.html:36 +#: templates/header.html:36 templates/index.html:137 msgid "unanswered questions" msgstr "sin respuesta" @@ -1448,97 +1485,107 @@ msgstr "Inicio" msgid "Questions" msgstr "Preguntas" -#: templates/index.html:24 +#: templates/index.html:25 templates/index.html.py:30 msgid "last updated questions" msgstr "ultimas preguntas actualizadas" -#: templates/index.html:24 templates/questions.html:25 -#: templates/unanswered.html:20 +#: templates/index.html:25 templates/index.html.py:30 +#: templates/questions.html:25 templates/unanswered.html:20 msgid "newest" msgstr "más nuevas" -#: templates/index.html:25 templates/questions.html:27 +#: templates/index.html:26 templates/index.html.py:31 +#: templates/questions.html:27 msgid "hottest questions" msgstr "preguntas calientes" -#: templates/index.html:25 templates/questions.html:27 +#: templates/index.html:26 templates/index.html.py:31 +#: templates/questions.html:27 msgid "hottest" msgstr "más calientes" -#: templates/index.html:26 templates/questions.html:28 +#: templates/index.html:27 templates/index.html.py:32 +#: templates/questions.html:28 msgid "most voted questions" msgstr "preguntas más votadas" -#: templates/index.html:26 templates/questions.html:28 +#: templates/index.html:27 templates/index.html.py:32 +#: templates/questions.html:28 msgid "most voted" msgstr "más votadas" -#: templates/index.html:27 +#: templates/index.html:28 templates/index.html.py:33 msgid "all questions" msgstr "todas las preguntas" -#: templates/index.html:47 templates/questions.html:45 -#: templates/unanswered.html:36 templates/users_questions.html:35 +#: templates/index.html:54 templates/questions.html:45 +#: templates/unanswered.html:36 templates/users_questions.html:37 msgid "answers" msgstr "respuestas" -#: templates/index.html:69 templates/question.html:499 -#: templates/questions.html:84 templates/questions.html.py:156 +#: templates/index.html:76 templates/question.html:500 +#: templates/questions.html:84 templates/questions.html.py:157 #: templates/tags.html:49 templates/unanswered.html:75 -#: templates/unanswered.html.py:106 templates/users_questions.html:52 +#: templates/unanswered.html.py:106 templates/users_questions.html:54 msgid "see questions tagged" msgstr "ver preguntas etiquetadas" -#: templates/index.html:80 +#: templates/index.html:87 msgid "welcome to website" msgstr "bienvenido a sitio" -#: templates/index.html:89 +#: templates/index.html:102 msgid "Recent tags" msgstr "Etiquetas recientes" -#: templates/index.html:94 templates/question.html:125 +#: templates/index.html:107 templates/question.html:125 #, python-format msgid "see questions tagged '%(tagname)s'" msgstr "ver preguntas etiquetadas '%(tagname)s'" -#: templates/index.html:97 templates/index.html.py:123 +#: templates/index.html:110 templates/index.html.py:137 +#: templates/index.html:139 msgid "popular tags" msgstr "etiquetas populares" -#: templates/index.html:102 +#: templates/index.html:115 msgid "Recent awards" msgstr "Reconocimientos recientes" -#: templates/index.html:108 +#: templates/index.html:121 msgid "given to" msgstr "dados a" -#: templates/index.html:113 +#: templates/index.html:126 msgid "all awards" msgstr "todos los reconocimientos" -#: templates/index.html:118 +#: templates/index.html:131 msgid "subscribe to last 30 questions by RSS" msgstr "suscribirse a las últimas 30 preguntas por RSS" -#: templates/index.html:123 +#: templates/index.html:137 templates/index.html.py:139 msgid "Still looking for more? See" msgstr "¿Aún sigues buscando más? Ver" -#: templates/index.html:123 -msgid "complete list of questions" +#: templates/index.html:137 +#, fuzzy +msgid "complete list of quesionts" msgstr "lista completa de preguntas" -#: templates/index.html:123 +#: templates/index.html:137 templates/index.html.py:139 msgid "or" msgstr "ó" -#: templates/index.html:123 +#: templates/index.html:137 templates/index.html.py:139 msgid "Please help us answer" msgstr "Ayudanos a responder" -#: templates/index.html:123 +#: templates/index.html:139 +msgid "complete list of questions" +msgstr "lista completa de preguntas" + +#: templates/index.html:139 msgid "list of unanswered questions" msgstr "lista de preguntas sin respuesta" @@ -1632,7 +1679,7 @@ msgid "i like this post (click again to cancel)" msgstr "Me gusta esta entrada (clickear devuelta para cancelar)" #: templates/question.html:75 templates/question.html.py:89 -#: templates/question.html:289 +#: templates/question.html:290 msgid "current number of votes" msgstr "número actual de votos" @@ -1651,52 +1698,56 @@ msgstr "" "remover marca de favorito a esta pregunta (clickear devuelta para volver a " "marcar)" -#: templates/question.html:134 templates/question.html.py:322 +#: templates/question.html:128 templates/questions.html:87 +msgid "Category: " +msgstr "Categoría: " + +#: templates/question.html:135 templates/question.html.py:323 #: templates/revisions_answer.html:53 templates/revisions_question.html:53 msgid "edit" msgstr "editar" -#: templates/question.html:138 templates/question.html.py:332 +#: templates/question.html:139 templates/question.html.py:333 msgid "delete" msgstr "borrar" -#: templates/question.html:143 +#: templates/question.html:144 msgid "reopen" msgstr "re-abrir" -#: templates/question.html:148 +#: templates/question.html:149 msgid "close" msgstr "cerrar" -#: templates/question.html:154 templates/question.html.py:345 +#: templates/question.html:155 templates/question.html.py:346 msgid "" "report as offensive (i.e containing spam, advertising, malicious text, etc.)" msgstr "" "reportar como ofensivo (ej. contiene spam, publicidad, texto malicioso, etc.)" -#: templates/question.html:155 templates/question.html.py:346 +#: templates/question.html:156 templates/question.html.py:347 msgid "flag offensive" msgstr "marcar como ofensivo" -#: templates/question.html:167 templates/question.html.py:355 +#: templates/question.html:168 templates/question.html.py:356 #: templates/revisions_answer.html:65 templates/revisions_question.html:65 msgid "updated" msgstr "actualizado" -#: templates/question.html:216 templates/question.html.py:402 +#: templates/question.html:217 templates/question.html.py:403 #: templates/revisions_answer.html:63 templates/revisions_question.html:63 msgid "asked" msgstr "preguntado" -#: templates/question.html:246 templates/question.html.py:429 +#: templates/question.html:247 templates/question.html.py:430 msgid "comments" msgstr "comentarios" -#: templates/question.html:247 templates/question.html.py:430 +#: templates/question.html:248 templates/question.html.py:431 msgid "add comment" msgstr "agregar comentario" -#: templates/question.html:260 +#: templates/question.html:261 #, python-format msgid "" "The question has been closed for the following reason \"%(question." @@ -1705,115 +1756,115 @@ msgstr "" "La pregunta ha sido cerrada por el siguiente motivo \"%(question." "get_close_reason_display)s\" por" -#: templates/question.html:262 +#: templates/question.html:263 #, python-format msgid "close date %(question.closed_at)s" msgstr "fecha de cerrada %(question.closed_at)s" -#: templates/question.html:269 templates/user_stats.html:28 +#: templates/question.html:270 templates/user_stats.html:13 msgid "Answers" msgstr "Respuestas" -#: templates/question.html:271 +#: templates/question.html:272 msgid "oldest answers will be shown first" msgstr "la respuesta mas vieja será mostrada primero" -#: templates/question.html:271 +#: templates/question.html:272 msgid "oldest answers" msgstr "pregunta más vieja" -#: templates/question.html:272 +#: templates/question.html:273 msgid "newest answers will be shown first" msgstr "preguntas más nuevas serán mostradas primero" -#: templates/question.html:272 +#: templates/question.html:273 msgid "newest answers" msgstr "más nuevas" -#: templates/question.html:273 +#: templates/question.html:274 msgid "most voted answers will be shown first" msgstr "las preguntas más votadas serán mostradas primero" -#: templates/question.html:273 +#: templates/question.html:274 msgid "popular answers" msgstr "respuestas populares" -#: templates/question.html:287 templates/question.html.py:288 +#: templates/question.html:288 templates/question.html.py:289 msgid "i like this answer (click again to cancel)" msgstr "me gusta esta respuesta (clickear devuelta para cancelar)" -#: templates/question.html:294 templates/question.html.py:295 +#: templates/question.html:295 templates/question.html.py:296 msgid "i dont like this answer (click again to cancel)" msgstr "no me gusta esta respuesta (clickear devuelta para cancelar)" -#: templates/question.html:300 templates/question.html.py:301 +#: templates/question.html:301 templates/question.html.py:302 msgid "mark this answer as favorite (click again to undo)" msgstr "marcar esta respuesta como favorita (clickear devuelta para deshacer)" -#: templates/question.html:306 templates/question.html.py:307 +#: templates/question.html:307 templates/question.html.py:308 msgid "the author of the question has selected this answer as correct" msgstr "el autor de esta pregunta ha seleccionado esta respuesta como correcta" -#: templates/question.html:329 +#: templates/question.html:330 msgid "undelete" msgstr "deshacer eliminar" -#: templates/question.html:339 +#: templates/question.html:340 msgid "answer permanent link" msgstr "enlace permanente a respuesta" -#: templates/question.html:340 +#: templates/question.html:341 msgid "permanent link" msgstr "enlace permanente" -#: templates/question.html:453 +#: templates/question.html:454 msgid "Your answer" msgstr "Tu respuesta" -#: templates/question.html:456 +#: templates/question.html:457 msgid "you can answer anonymously and then login" msgstr "puedes responder de forma anónima y luego ingresar" -#: templates/question.html:479 +#: templates/question.html:480 msgid "Answer the question" msgstr "Responde la pregunta" -#: templates/question.html:481 +#: templates/question.html:482 msgid "Notify me daily if there are any new answers." msgstr "Notificarme diariamente si hay nuevas respuestas." -#: templates/question.html:483 +#: templates/question.html:484 msgid "once you sign in you will be able to subscribe for any updates here" msgstr "" "una vez que hayas ingresado podrás suscribirte a cualquiera de las " "actualizaciones aquí." -#: templates/question.html:494 +#: templates/question.html:495 msgid "Question tags" msgstr "Tags de la pregunta" -#: templates/question.html:504 +#: templates/question.html:505 msgid "question asked" msgstr "pregunta preguntada" -#: templates/question.html:504 templates/question.html.py:510 +#: templates/question.html:505 templates/question.html.py:511 #: templates/user_info.html:51 msgid "ago" msgstr " atras" -#: templates/question.html:507 +#: templates/question.html:508 msgid "question was seen" msgstr "la pregunta fue vista" -#: templates/question.html:507 +#: templates/question.html:508 msgid "times" msgstr "veces" -#: templates/question.html:510 +#: templates/question.html:511 msgid "last updated" msgstr "última vez actualizada" -#: templates/question.html:515 +#: templates/question.html:516 msgid "Related questions" msgstr "Preguntas relacionadas" @@ -1878,7 +1929,7 @@ msgstr "preguntas actualizadas más recientemente" msgid "active" msgstr "actividad" -#: templates/questions.html:109 +#: templates/questions.html:110 #, python-format msgid "" "\n" @@ -1897,7 +1948,7 @@ msgstr[1] "" "\t\t\ttiene un total de %(q_num)s preguntas etiquetadas con %(tagname)s\n" "\t\t\t" -#: templates/questions.html:116 +#: templates/questions.html:117 #, python-format msgid "" "\n" @@ -1916,7 +1967,7 @@ msgstr[1] "" "\t\t\thay un total de %(q_num)s pregunta que contiene %(searchtitle)s\n" "\t\t\t" -#: templates/questions.html:122 +#: templates/questions.html:123 #, fuzzy, python-format msgid "" "\n" @@ -1929,36 +1980,36 @@ msgid_plural "" msgstr[0] "ver preguntas etiquetadas '%(tagname)s'" msgstr[1] "ver pregunta etiquetada '%(tagname)s'" -#: templates/questions.html:131 +#: templates/questions.html:132 msgid "latest questions info" msgstr "<strong>Más recientes</strong> preguntas son mostradas primero." -#: templates/questions.html:135 +#: templates/questions.html:136 msgid "Questions are sorted by the <strong>time of last update</strong>." msgstr "" "Las preguntas estan ordenadas por <strong>fecha de último update</strong>." -#: templates/questions.html:136 +#: templates/questions.html:137 msgid "Most recently answered ones are shown first." msgstr "Las más recientemente respondidas son mostradas primero." -#: templates/questions.html:140 +#: templates/questions.html:141 msgid "Questions sorted by <strong>number of responses</strong>." msgstr "Preguntas ordenadas por <strong>número de respuestas</strong>." -#: templates/questions.html:141 +#: templates/questions.html:142 msgid "Most answered questions are shown first." msgstr "Preguntas más respondidas aparecen primero." -#: templates/questions.html:145 +#: templates/questions.html:146 msgid "Questions are sorted by the <strong>number of votes</strong>." msgstr "Las preguntas son ordenadas por el <strong>número de votos</strong>." -#: templates/questions.html:146 +#: templates/questions.html:147 msgid "Most voted questions are shown first." msgstr "Las preguntas más votadas son mostradas primero." -#: templates/questions.html:153 templates/unanswered.html:102 +#: templates/questions.html:154 templates/unanswered.html:102 msgid "Related tags" msgstr "Etiquetas relacionadas" @@ -2023,10 +2074,6 @@ msgstr "Todas las etiquetas que coincidan con la busqueda" msgid "all tags - make this empty in english" msgstr "todas las tags" -#: templates/tags.html:42 -msgid "Nothing found" -msgstr "Nada encontrado" - #: templates/unanswered.html:7 templates/unanswered.html.py:18 msgid "Unanswered questions" msgstr "Preguntas sin respuesta" @@ -2126,41 +2173,50 @@ msgstr "Enviar mis respuestas a Twitter" msgid "Save" msgstr "Guardar" -#: templates/user_stats.html:16 +#: templates/user_stats.html:10 msgid "User questions" msgstr "Preguntas del usuario" -#: templates/user_stats.html:38 +#: templates/user_stats.html:20 #, python-format msgid "the answer has been voted for %(vote_count)s times" msgstr "la respuesta ha sido votada %(vote_count)s veces" -#: templates/user_stats.html:38 +#: templates/user_stats.html:20 msgid "this answer has been selected as correct" msgstr "esta respuesta ha sido seleccionada como correcta" -#: templates/user_stats.html:46 +#: templates/user_stats.html:28 #, python-format msgid "the answer has been commented %(comment_count)s times" msgstr "la respuesta ha sido comentada %(comment_count)s veces" -#: templates/user_stats.html:60 -msgid "votes total" -msgstr "votos totales" +#: templates/user_stats.html:36 +#, fuzzy +msgid "Votes" +msgstr "votos" + +#: templates/user_stats.html:41 +msgid "thumb up" +msgstr "" -#: templates/user_stats.html:69 +#: templates/user_stats.html:42 msgid "user has voted up this many times" msgstr "el usuario ha votado positivo esta cantidad de veces" -#: templates/user_stats.html:74 +#: templates/user_stats.html:46 +msgid "thumb down" +msgstr "" + +#: templates/user_stats.html:47 msgid "user voted down this many times" msgstr "el usuario voto negativo esta cantidad de veces" -#: templates/user_stats.html:87 +#: templates/user_stats.html:54 msgid "Tags" msgstr "Etiquetas" -#: templates/user_stats.html:97 +#: templates/user_stats.html:61 #, python-format msgid "see other questions tagged '%(tag)s' " msgstr "ver otras preguntas etiqueteadas '%(tag)s'" @@ -2177,6 +2233,11 @@ msgstr "gráfica de la reputación del usuario" msgid "reputation history" msgstr "historial de reputación" +#: templates/user_tabs.html:23 +#, fuzzy +msgid "questions that user selected as his/her favorite" +msgstr "esta pregunta ha sido seleccionada como favorita" + #: templates/user_tabs.html:24 msgid "favorites" msgstr "favoritos" @@ -2214,7 +2275,15 @@ msgstr "Nada encontrado." msgid "this questions was selected as favorite" msgstr "esta pregunta ha sido seleccionada como favorita" -#: templates/users_questions.html:33 +#: templates/users_questions.html:12 +msgid "thumb-up on" +msgstr "" + +#: templates/users_questions.html:19 +msgid "thumb-up off" +msgstr "" + +#: templates/users_questions.html:35 msgid "this answer has been accepted to be correct" msgstr "esta respuesta ha sido aceptada como correcta" @@ -2240,7 +2309,7 @@ msgid "Your new Email" msgstr "Tu nuevo Email" #: templates/authopenid/changeemail.html:31 -#: templates/authopenid/signin.html:136 +#: templates/authopenid/signin.html:137 msgid "Password" msgstr "Contraseña" @@ -2348,7 +2417,7 @@ msgid "This account already exists, please use another." msgstr "Esta cuenta ya existe, por favor usar otra." #: templates/authopenid/complete.html:19 templates/authopenid/complete.html:32 -#: templates/authopenid/signin.html:120 +#: templates/authopenid/sendpw.html:16 templates/authopenid/signin.html:121 msgid "Sorry, looks like we have some errors:" msgstr "Ups, parece que hay errores:" @@ -2380,40 +2449,11 @@ msgstr "contraseña" msgid "Register" msgstr "Registrarse" -#: templates/authopenid/complete.html:62 templates/authopenid/signin.html:138 +#: templates/authopenid/complete.html:62 templates/authopenid/signin.html:140 +#: templates/authopenid/signin.html:144 msgid "Forgot your password?" msgstr "¿Olvidaste tu contraseña?" -#: templates/authopenid/confirm_email.txt:2 -msgid "Thank you for registering at our Q&A forum!" -msgstr "" - -#: templates/authopenid/confirm_email.txt:4 -msgid "Your account details are:" -msgstr "" - -#: templates/authopenid/confirm_email.txt:6 -#: templates/authopenid/sendpw_email.txt:7 -msgid "Username:" -msgstr "Nombre de usuario:" - -#: templates/authopenid/confirm_email.txt:7 -#: templates/authopenid/delete.html:20 -msgid "Password:" -msgstr "Contraseña" - -#: templates/authopenid/confirm_email.txt:9 -msgid "Please sign in here:" -msgstr "" - -#: templates/authopenid/confirm_email.txt:12 -#: templates/authopenid/email_validation.txt:14 -#: templates/authopenid/sendpw_email.txt:13 -msgid "" -"Sincerely,\n" -"Forum Administrator" -msgstr "" - #: templates/authopenid/delete.html:9 msgid "Account: delete account" msgstr "Cuenta: borrar cuenta" @@ -2430,6 +2470,10 @@ msgstr "" msgid "Check confirm box, if you want delete your account." msgstr "Marca caja de confirmación, si deseas borrar tu cuenta." +#: templates/authopenid/delete.html:20 +msgid "Password:" +msgstr "Contraseña" + #: templates/authopenid/delete.html:32 msgid "I am sure I want to delete my account." msgstr "Estoy seguro que quiero borrar mi cuenta." @@ -2446,25 +2490,6 @@ msgstr "(requerido por tu seguridad)" msgid "Delete account permanently" msgstr "Borrar la cuenta de forma permanente" -#: templates/authopenid/email_validation.txt:2 -msgid "Greetings from the Q&A forum" -msgstr "" - -#: templates/authopenid/email_validation.txt:4 -msgid "To make use of the Forum, please follow the link below:" -msgstr "" - -#: templates/authopenid/email_validation.txt:8 -msgid "Following the link above will help us verify your email address." -msgstr "" - -#: templates/authopenid/email_validation.txt:10 -msgid "" -"If you beleive that this message was sent in mistake - \n" -"no further action is needed. Just ingore this email, we apologize\n" -"for any inconvenience" -msgstr "" - #: templates/authopenid/sendpw.html:4 templates/authopenid/sendpw.html.py:8 msgid "Send new password" msgstr "Enviar nueva contraseña" @@ -2501,26 +2526,6 @@ msgstr "" "Nota: tu nueva contraseña solo será activada luego de que hagas click en el " "link de activación en el email enviado." -#: templates/authopenid/sendpw_email.txt:2 -#, python-format -msgid "" -"Someone has requested to reset your password on %(site_url)s.\n" -"If it were not you, it is safe to ignore this email." -msgstr "" - -#: templates/authopenid/sendpw_email.txt:5 -msgid "Your new account details are:" -msgstr "" - -#: templates/authopenid/sendpw_email.txt:8 -#, fuzzy -msgid "New password:" -msgstr "Nueva contraseña:" - -#: templates/authopenid/sendpw_email.txt:10 -msgid "To confirm that you wanted to reset your password please visit:" -msgstr "" - #: templates/authopenid/settings.html:30 msgid "Give your account a new password." msgstr "Crea una nueva contraseña para tu cuenta." @@ -2589,7 +2594,8 @@ msgstr "" "Ingresa tu dirección (URL) de <a class=\"openid_logo\" href=\"http://openid." "net\">OpenID</a>" -#: templates/authopenid/signin.html:112 templates/authopenid/signin.html:137 +#: templates/authopenid/signin.html:112 templates/authopenid/signin.html:139 +#: templates/authopenid/signin.html:143 msgid "Login" msgstr "Ingresar" @@ -2597,48 +2603,48 @@ msgstr "Ingresar" msgid "we support two login modes" msgstr "soportamos dos tipos de ingreso" -#: templates/authopenid/signin.html:134 +#: templates/authopenid/signin.html:135 msgid "Use login name and password" msgstr "Nombre de usuario y contraseña" -#: templates/authopenid/signin.html:135 +#: templates/authopenid/signin.html:136 msgid "Login name" msgstr "Nombre de usuario" -#: templates/authopenid/signin.html:139 +#: templates/authopenid/signin.html:141 templates/authopenid/signin.html:145 msgid "Create new account" msgstr "Crear cuenta nueva" -#: templates/authopenid/signin.html:148 +#: templates/authopenid/signin.html:155 msgid "Why use OpenID?" msgstr "¿Porqué usar OpenID?" -#: templates/authopenid/signin.html:151 +#: templates/authopenid/signin.html:158 msgid "with openid it is easier" msgstr "Con OpenID no necesitas crear un nuevo nombre de usuario y contraseña." -#: templates/authopenid/signin.html:154 +#: templates/authopenid/signin.html:161 msgid "reuse openid" msgstr "" "Puedes de forma segura re-usar el mismo nombre de usuario para todos los " "sitios que acepten OpenID." -#: templates/authopenid/signin.html:157 +#: templates/authopenid/signin.html:164 msgid "openid is widely adopted" msgstr "" "OpenID es extensamente usado. Hay más de 160,000,000 cuentas de OpenID en " "uso en el mundo. Mas de 10,000 sitios aceptan OpenID." -#: templates/authopenid/signin.html:160 +#: templates/authopenid/signin.html:167 msgid "openid is supported open standard" msgstr "" "OpenID es basado en un standard abierto, apoyado por muchas organizaciones." -#: templates/authopenid/signin.html:165 +#: templates/authopenid/signin.html:172 msgid "Find out more" msgstr "Averigua más" -#: templates/authopenid/signin.html:166 +#: templates/authopenid/signin.html:173 msgid "Get OpenID" msgstr "Adquiere una OpenID" @@ -2682,6 +2688,16 @@ msgstr "Registrate con tu OpenID" msgid "Login with your OpenID" msgstr "Ingresar con tu OpenID" +#~ msgid "votes total" +#~ msgstr "votos totales" + +#~ msgid "Username:" +#~ msgstr "Nombre de usuario:" + +#, fuzzy +#~ msgid "New password:" +#~ msgstr "Nueva contraseña:" + #~ msgid "site title" #~ msgstr "Preguntalo.com.uy" diff --git a/templates/ask.html b/templates/ask.html index 9e86a5a0..447ee749 100644 --- a/templates/ask.html +++ b/templates/ask.html @@ -110,6 +110,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/templates/authopenid/sendpw.html b/templates/authopenid/sendpw.html index 383723ca..b02ee6e9 100644 --- a/templates/authopenid/sendpw.html +++ b/templates/authopenid/sendpw.html @@ -13,7 +13,7 @@ {% trans "Please enter your username below and new password will be sent to your registered e-mail" %} </div> {% if form.errors %} -<p class="errors"><span class="big">{% "Sorry, looks like we have some errors:" %}</span><br/> +<p class="errors"><span class="big">{% trans "Sorry, looks like we have some errors:" %}</span><br> {% if form.username.errors %} <span class="error">{{ form.username.errors|join:", " }}</span> {% endif %} diff --git a/templates/authopenid/signin.html b/templates/authopenid/signin.html index 8601f6ee..7c234ff3 100644 --- a/templates/authopenid/signin.html +++ b/templates/authopenid/signin.html @@ -113,8 +113,9 @@ </fieldset> </form> <div class="login"> - <p style="display:none">{% trans "we support two login modes" %}</p> - <div style="display:none"> + <p>{% trans "we support two login modes" %}</p> + <div > + <br> {% if form1.errors %} <p class="errors"> <span class="big">{% trans "Sorry, looks like we have some errors:" %}</span><br/> @@ -134,9 +135,15 @@ <legend class="big">{% trans "Use login name and password" %}</legend> <div class="form-row"><label for="id_username">{% trans "Login name" %}:</label><br />{{ form1.username }}</div> <div class="form-row"><label for="id_password">{% trans "Password" %}:</label><br />{{ form1.password }}</div> +<<<<<<< HEAD:templates/authopenid/signin.html + <div class="submit-row"><input type="submit" class="submit" name="blogin" value="{% trans "Login" %}"> + <a href="{%url sendpw%}">{% trans "Forgot your password?" %}</a> + <a href="/registrarse">{% trans "Create new account" %}</a></div> +======= <div class="submit-row"><input type="submit" class="submit" name="blogin" value="{% trans "Login" %}"/> <a href="">{% trans "Forgot your password?" %}</a> <a href="">{% trans "Create new account" %}</a></div> +>>>>>>> master:templates/authopenid/signin.html </fieldset> </form> </div> diff --git a/templates/categories.html b/templates/categories.html new file mode 100644 index 00000000..c617f22d --- /dev/null +++ b/templates/categories.html @@ -0,0 +1,56 @@ +{% extends "base_content.html" %} +<!-- tags.html --> +{% load i18n %} +{% load extra_tags %} +{% load humanize %} +{% block title %}{% spaceless %}{% trans "Category list" %}{% endspaceless %}{% endblock %} +{% block forejs %} + <script type="text/javascript"> + $().ready(function(){ + $("#nav_tags").attr('className',"on"); + $("#ipSearchTag").focus(); + + var orderby = "{{ tab_id }}"; + if(orderby != "used" && orderby != "name") + orderby = "used"; + $("#sort_" + orderby).attr('className',"on"); + $("#type-tag").attr('checked',true); + + Hilite.exact = false; + Hilite.elementid = "searchtags"; + Hilite.debug_referrer = location.href; + }); + + </script> +{% endblock %} +{% block content %} +<!-- Tabs --> +<div class="tabBar"> + <div class="headQuestions">{% trans "Category list" %}</div> +</div> +<div id="searchtags"> +<p> +{% if not categories.object_list %} + <span>{% trans "Nothing found" %}</span> +{% endif %} +</p> +<ul class="tagsList tags"> +{% for category in categories.object_list %} + <li> + <a href="{% url forum.views.category category|urlencode %}" title="{% trans "see questions that matches" %}'{{ category }}'{% trans "category " %}" rel="tag"> + {{ category }} + </a> + <br> + + </li> +{% endfor %} +</ul> +</div> + +{% endblock %} +{% block tail %} +<div class="pager"> + {% cnprog_paginator context %} +</div> +{% endblock %} +<!-- end tags.html --> diff --git a/templates/footer.html b/templates/footer.html index 9e877b42..34064fd5 100644 --- a/templates/footer.html +++ b/templates/footer.html @@ -3,7 +3,7 @@ {% load i18n %} <!-- 页面底部开始: --> <div id="ground"> - <div class="footerLinks" > + <div class="footerLinks" > <a href="{% url about %}">{% trans "about" %}</a><span class="link-separator"> |</span> <a href="{% url faq %}">{% trans "faq" %}</a><span class="link-separator"> |</span> <a href="{{ blog_url }}">{% trans "blog" %}</a><span class="link-separator"> |</span> @@ -11,12 +11,12 @@ <a href="{% url privacy %}">{% trans "privacy policy" %}</a><span class="link-separator"> |</span> <a href="{{ feedback_url }}" target="_blank">{% trans "give feedback" %}</a> </div> - <p style="margin-top:10px;"> + <!--<p style="margin-top:10px;"> <a href="http://code.google.com/p/cnprog/" target="_blank"> <img src="/content/images/djangomade124x25_grey.gif" border="0" alt="Made with Django." title="Made with Django." /> </a> - <!--<div style="font-size:90%;color:#333">{% trans "current revision" %}: R-0120-20090406</div>--> - </p> + <div style="font-size:90%;color:#333">{% trans "current revision" %}: R-0120-20090406</div> + </p>--> <p id="licenseLogo"><img src="/content/images/cc-wiki.png" title="Creative Commons: Attribution - Share Alike" alt="cc-wiki" width="50" height="68" /></p> </div> <!-- 页面底部结束: --> diff --git a/templates/header.html b/templates/header.html index e1097802..c9b01a20 100644 --- a/templates/header.html +++ b/templates/header.html @@ -71,3 +71,4 @@ </div> </div> <!-- end template header.html --> + diff --git a/templates/index.html b/templates/index.html index 104b24d0..3e52e59c 100644 --- a/templates/index.html +++ b/templates/index.html @@ -21,10 +21,17 @@ <div class="tabBar"> <div class="headQuestions">{% trans "Questions" %}</div> <div class="tabsA"> +<<<<<<< HEAD:templates/index.html + <a id="latest" href="?sort=latest" title="{% trans "last updated questions" %}" >{% trans "newest" %}</a> + <a id="hottest" href="?sort=hottest" title="{% trans "hottest questions" %}" >{% trans "hottest" %}</a> + <a id="mostvoted" href="?sort=mostvoted" title="{% trans "most voted questions" %}" >{% trans "most voted" %}</a> + <a id="all" href="/preguntas/" title="{% trans "all questions" %}" >{% trans "all questions" %}</a> +======= <a id="latest" href="{% url questions %}?sort=latest" title="{% trans "last updated questions" %}" >{% trans "newest" %}</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> +>>>>>>> master:templates/index.html </div> </div> <!-- 问题列表 --> @@ -79,9 +86,15 @@ <div class="boxA"> <h3>{% trans "welcome to website" %}</h3> <div class="body"> +<<<<<<< HEAD:templates/index.html + {{settings.APP_INTRO|safe}} + <div class="more"><a href="/sobre">{% trans "about" %} »</a></div> + <div class="more"><a href="/faq">{% trans "faq" %} »</a></div> +======= {{ settings.APP_INTRO|safe }} <div class="more"><a href="{% url about %}">{% trans "about" %} »</a></div> <div class="more"><a href="{% url faq %}">{% trans "faq" %} »</a></div> +>>>>>>> master:templates/index.html </div> </div> {% endif %} @@ -120,7 +133,11 @@ {% endblock %} {% block tail %} <div style="padding:5px 0 5px 5px;"> +<<<<<<< HEAD:templates/index.html +<span class="evenMore">{% trans "Still looking for more? See" %} <a href="/preguntas/">{% trans "complete list of quesionts" %}</a>, {% trans "or" %} <a href="/etiquetas/">{% trans "popular tags" %}</a>{% trans "." %} {% trans "Please help us answer" %} <a href="/preguntas/sin-responder">{% trans "unanswered questions" %}</a>{% trans "." %}</span> +======= <span class="evenMore">{% trans "Still looking for more? See" %} <a href="{% url questions %}">{% trans "complete list of questions" %}</a> {% trans "or" %} <a href="/tags/">{% trans "popular tags" %}</a>{% trans "." %} {% trans "Please help us answer" %} <a href="{% url questions %}unanswered">{% trans "list of unanswered questions" %}</a>{% trans "." %}</span> +>>>>>>> master:templates/index.html </div> {% endblock %} <!-- index.html --> diff --git a/templates/question.html b/templates/question.html index 66713342..d6257a71 100644 --- a/templates/question.html +++ b/templates/question.html @@ -125,6 +125,7 @@ title="{% blocktrans with tag as tagname %}see questions tagged '{{ tagname }}'{% endblocktrans %}" rel="tag">{{ tag }}</a> {% endfor %} </div> + {% trans "Category: " %} <a href="{% url forum.views.category question.category|urlencode %}">{{question.category}}</a> <div id="question-controls" style="clear:both;"> <table width="100%"> <tr> diff --git a/templates/question_edit.html b/templates/question_edit.html index db090ca3..a7460b65 100644 --- a/templates/question_edit.html +++ b/templates/question_edit.html @@ -111,6 +111,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/templates/questions.html b/templates/questions.html index 985b4921..6121d876 100644 --- a/templates/questions.html +++ b/templates/questions.html @@ -84,6 +84,7 @@ <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 %} </div> @@ -64,5 +64,6 @@ urlpatterns = patterns('', url(r'^%s%s(?P<short_name>[^/]+)/$' % (_('books/'), _('ask/')), app.ask_book, name='ask_book'), url(r'^%s(?P<short_name>[^/]+)/$' % _('books/'), app.book, name='book'), url(r'^%s$' % _('search/'), app.search, name='search'), - (r'^i18n/', include('django.conf.urls.i18n')), + (r'^categorias/$', app.categories), + (r'^categorias/(?P<category>[^/]+)/$', app.category), ) |