Skip to content

Commit

Permalink
Merge branch 'ralph' of git://github.com/ralphite/bootcamp into ralph…
Browse files Browse the repository at this point in the history
…ite-ralph
  • Loading branch information
sebastian-code committed Oct 14, 2017
2 parents 3567175 + e1f7667 commit c406dc5
Show file tree
Hide file tree
Showing 11 changed files with 30 additions and 28 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,5 @@ media/
.env

venv_bootcamp/
staticfiles
staticfiles
.idea
6 changes: 3 additions & 3 deletions bootcamp/core/templates/core/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,13 @@ <h1>{{ page_user.profile.get_screen_name }} {% if page_user.get_full_name %}<sma
<img src="{{ page_user.profile.get_picture }}" class="picture">
<ul>
{% if page_user.profile.job_title %}
<li><span class="glyphicon glyphicon-briefcase"></span> {{ page_user.profile.job_title }}</li>
<li><span class="glyphicon glyphicon-briefcase"></span> {{ page_user.profile.job_title }}</li>
{% endif %}
{% if page_user.profile.location %}
<li><span class="glyphicon glyphicon-map-marker"></span> {{ page_user.profile.location }}</li>
<li><span class="glyphicon glyphicon-map-marker"></span> {{ page_user.profile.location }}</li>
{% endif %}
{% if page_user.profile.url %}
<li><span class="glyphicon glyphicon-globe"></span> <a href="{{ page_user.profile.get_url }}" target="_blank">{{ page_user.profile.get_url }}</a></li>
<li><span class="glyphicon glyphicon-globe"></span> <a href="{{ page_user.profile.get_url }}" target="_blank">{{ page_user.profile.get_url }}</a></li>
{% endif %}
</ul>
</div>
Expand Down
7 changes: 3 additions & 4 deletions bootcamp/core/views.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
import os
import json

from django.shortcuts import get_object_or_404
from PIL import Image

from django.conf import settings as django_settings
from django.contrib import messages
from django.db.models import Q
from django.contrib.auth import update_session_auth_hash
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from django.core.paginator import EmptyPage, PageNotAnInteger, Paginator
from django.shortcuts import redirect, render
from django.shortcuts import get_object_or_404, redirect, render

from bootcamp.core.forms import ChangePasswordForm, ProfileForm
from bootcamp.feeds.views import FEEDS_NUM_PAGES, feeds
Expand All @@ -19,8 +20,6 @@
from bootcamp.activities.models import Activity
from bootcamp.messenger.models import Message

from PIL import Image


def home(request):
if request.user.is_authenticated():
Expand Down
2 changes: 1 addition & 1 deletion bootcamp/feeds/static/js/feeds.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ $(function () {
$(".stream-update").hide();
$(".stream-update .new-posts").text("");
$(document).attr("title", page_title);
};
}

$("body").keydown(function (evt) {
var keyCode = evt.which?evt.which:evt.keyCode;
Expand Down
22 changes: 11 additions & 11 deletions bootcamp/locale/zh_CN/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ msgstr "写第一条评论"

#: bootcamp/articles/templates/articles/write.html:35
msgid "Preview"
msgstr ""
msgstr "预览"

#: bootcamp/authentication/templates/authentication/signup.html:12
#: bootcamp/core/templates/core/cover.html:41
Expand Down Expand Up @@ -274,7 +274,7 @@ msgstr "已解决"

#: bootcamp/core/templates/core/profile.html:46
msgid "Global Interactions"
msgstr ""
msgstr "全局交互"

#: bootcamp/core/templates/core/profile.html:71
#, fuzzy
Expand Down Expand Up @@ -348,24 +348,24 @@ msgstr "写第一条评论"

#: bootcamp/messenger/models.py:20
msgid "Message"
msgstr ""
msgstr "消息"

#: bootcamp/messenger/models.py:21
msgid "Messages"
msgstr ""
msgstr "消息"

#: bootcamp/messenger/templates/messenger/inbox.html:4
#: bootcamp/messenger/templates/messenger/inbox.html:6
msgid "Inbox"
msgstr ""
msgstr "收件箱"

#: bootcamp/messenger/templates/messenger/inbox.html:15
msgid "This is the begining of a great new conversation."
msgstr ""

#: bootcamp/messenger/templates/messenger/inbox.html:16
msgid "Let's get started now!"
msgstr ""
msgstr "让我们开始吧!"

#: bootcamp/questions/templates/questions/ask.html:7
#: bootcamp/questions/templates/questions/questions.html:15
Expand Down Expand Up @@ -424,11 +424,11 @@ msgstr "没有问题显示"

#: bootcamp/search/templates/search/partial_articles_results.html:24
msgid "No article found"
msgstr ""
msgstr "没有文章"

#: bootcamp/search/templates/search/partial_feed_results.html:23
msgid "No feed found"
msgstr ""
msgstr "没有Feed"

#: bootcamp/search/templates/search/partial_questions_results.html:22
#, fuzzy
Expand All @@ -445,17 +445,17 @@ msgstr "用户名"

#: bootcamp/search/templates/search/partial_users_results.html:19
msgid "No user found"
msgstr ""
msgstr "没有用户"

#: bootcamp/search/templates/search/results.html:17
#: bootcamp/search/templates/search/search.html:22
msgid "Search"
msgstr ""
msgstr "搜索"

#: bootcamp/search/templates/search/results.html:23
#: bootcamp/search/templates/search/search.html:19
msgid "Search Feed, Articles, Questions and Users"
msgstr ""
msgstr "搜索Feed、文章、问答和用户"

#: bootcamp/templates/base.html:47
msgid "Q&A"
Expand Down
3 changes: 2 additions & 1 deletion bootcamp/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@
LANGUAGES = (
('en', 'English'),
('pt-br', 'Portuguese'),
('es', 'Spanish')
('es', 'Spanish'),
('zh-cn', 'Chinese'),
)

LOCALE_PATHS = (PROJECT_DIR.child('locale'), )
Expand Down
2 changes: 1 addition & 1 deletion bootcamp/static/js/bootcamp.markdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ $(function () {
}
$(_textarea).selection("replace", {text: selection_list_result});
break;
};
}

});

Expand Down
4 changes: 2 additions & 2 deletions bootcamp/templates/400.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

{% block main %}
<div class="page-header">
<h1>Page not found</h1>
<h1>Bad request</h1>
</div>
<p style="margin-top: 1.2em">Hey you! My friend, it appears to me than you did something wrong. :(</p>
<p style="margin-top: 1.2em">Hey you! My friend, it appears to me that you did something wrong. :(</p>
{% endblock main %}
2 changes: 1 addition & 1 deletion bootcamp/templates/403.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
<div class="page-header">
<h1>Permission denied</h1>
</div>
<p style="margin-top: 1.2em">Hey you!</p>
<p style="margin-top: 1.2em">Hey you! Seems like you do not have permission to access this page. Please let us know otherwise.</p>
{% endblock main %}
2 changes: 1 addition & 1 deletion bootcamp/templates/500.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
<div class="page-header">
<h1>Server error</h1>
</div>
<p style="margin-top: 1.2em">Ooops! Something went wrong. That's all we know.</p>
<p style="margin-top: 1.2em">Oops! Something went wrong. That's all we know.</p>
{% endblock main %}
5 changes: 3 additions & 2 deletions bootcamp/templates/base.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{% load staticfiles i18n %}<!DOCTYPE html>
{% load staticfiles i18n %}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
Expand Down Expand Up @@ -64,7 +65,7 @@
$(function() {
$("#auto-search").autocomplete({
source: "{% url 'autocomplete' %}",
minLength: 2,
minLength: 2
});
});
</script>
Expand Down

0 comments on commit c406dc5

Please sign in to comment.