Commit 354590bf authored by christophe siraut's avatar christophe siraut

Ajouté les instructions de traduction + travail sur les templates

parent 40028f31
nuage - Easy poll sharing
nuage - Easy poll sharing
=========================
nuage aims to provide a collaborative meeting poll system, similar to doodle or rdvz. It is build in python, using the django framework and a little of javascript. This application was named after Django's famous song. Feedback and collaboration are welcome at nuage@ domainepublic.net
nuage aims to provide a collaborative meeting poll system, similar to doodle or rdvz. It is build in python, using the django framework and a little of javascript. This application was named after Django's famous song. Feedback and collaboration are welcome at nuage@ domainepublic.net
Fast installation
Translation
===========
Install python-django package (<1.2)
Extract the nuage archive somewhere in your home folder
Edit project setings (optional)
Create/update a translation file:
# vi settings.py
# django-admin makemessages -l fr
Build nuage database
Edit and translate the translation file:
# ./manage.py sql sondage
# ./manage.py syncdb
# gedit locale/fr/LC_MESSAGES/django.po
Start the python webserver
Compile translated messages:
# ./manage.py runserver
# django-admin compilemessages
You should have the application running at 127.0.0.1:8000
Fast installation
=================
Apache installation
Install python-django package (<1.2)
Extract the nuage archive somewhere in your home folder
Edit project setings (optional)
Install python-django package (<1.2)
Extract the archive somewhere in your home folder
Move the "static" folder on tha apache side.
Edit project setings, set DEBUG option to False, and change MEDIA_ROOT
# vi settings.py
# vi settings.py
Build nuage database
Build nuage database
# ./manage.py sql sondage
# ./manage.py syncdb
# ./manage.py sql sondage
# ./manage.py syncdb
Start the python webserver
There are several ways to configure Apache and python,
we try wsgi, simply install libapache2-mod-wsgi, and add the following to /etc/apache2/sites-available/nuage
# ./manage.py runserver
<VirtualHost 62.58.108.143:80>
ServerName nuage.domainepublic.net
You should have the application running at 127.0.0.1:8000
Alias /static/ /var/www/nuage/static/
Alias /media/ /var/www/nuage/media/
Apache installation
===================
WSGIScriptAlias / /home/chris/django/nuage/apache/django.wsgi
Install python-django package (<1.2)
Extract the archive somewhere in your home folder
Move the "static" folder on tha apache side.
Edit project setings, set DEBUG option to False, and change MEDIA_ROOT
</VirtualHost>
# vi settings.py
Move the static files and link the media files
Build nuage database
mv static /var/www/nuage/
ln -s /usr/share/python-support/python-django/django/contrib/admin/media/ /var/www/nuage/
# ./manage.py sql sondage
# ./manage.py syncdb
Fix permission for apache user
There are several ways to configure Apache and python,
we try wsgi, simply install libapache2-mod-wsgi, and add the following to /etc/apache2/sites-available/nuage
sudo chown www-data nuage/nuage.sqlite
sudo chown www-data nuage
<VirtualHost 62.58.108.143:80>
ServerName nuage.domainepublic.net
Installing lenny django package on squeeze
Alias /static/ /var/www/nuage/static/
Alias /media/ /var/www/nuage/media/
Remove any installed python-django package (1.2)
Install lenny python-django (1.0)
Add the following to /etc/apt/preferences
Package: python-django
Pin: version 1.0*
Pin-Priority: 1001
WSGIScriptAlias / /home/chris/django/nuage/apache/django.wsgi
Build log
</VirtualHost>
django-admin startproject nuage
Move the static files and link the media files
cd nuage; BAZ=$(pwd)
gedit settings.py urls.py
mv static /var/www/nuage/
ln -s /usr/share/python-support/python-django/django/contrib/admin/media/ /var/www/nuage/
./manage.py startapp sondage
cd sondage; gedit models.py forms.py views.py
Fix permission for apache user
cd $BAZ; ./manage.py startapp userbase
cd userbase; gedit views.py
sudo chown www-data nuage/nuage.sqlite
sudo chown www-data nuage
cd $BAZ; mkdir templates static
Installing lenny django package on squeeze
==========================================
# rm nuage.sqlite ; ./manage.py sql sondage ; ./manage.py syncdb
Remove any installed python-django package (1.2)
Install lenny python-django (1.0)
Add the following to /etc/apt/preferences
Package: python-django
Pin: version 1.0*
Pin-Priority: 1001
Build log
=========
django-admin startproject nuage
cd nuage; BAZ=$(pwd)
gedit settings.py urls.py
./manage.py startapp sondage
cd sondage; gedit models.py forms.py views.py
cd $BAZ; ./manage.py startapp userbase
cd userbase; gedit views.py
cd $BAZ; mkdir templates static
# rm nuage.sqlite ; ./manage.py sql sondage ; ./manage.py syncdb
......@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2010-06-18 14:06+0200\n"
"POT-Creation-Date: 2010-06-21 19:35+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......@@ -16,13 +16,54 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: templates/index.html:18
#: templates/base.html:7
msgid "Easy poll sharing"
msgstr "rendez-vous partagés"
#: templates/base.html:63
msgid "Nuages is brought to you by"
msgstr "un service proposé par"
#: templates/index.html:9
msgid ""
"<i>nuage</i> let you create polls easily, and publish them for your mates. "
"You may poll on dates or any subject, in order to plan meetings or get a "
"group opinion."
msgstr "nuage en français"
"Create polls easily, and publish them for your mates. You may poll on dates "
"or any subject, in order to plan meetings or get a group opinion."
msgstr ""
"Crez facilement des sondages en ligne et publiez les à vos amis. Vous pouvez "
"sonder pour un rendez-vous sur un quelconque sujet."
#: templates/index.html:17
msgid "New poll"
msgstr "Nouveau sondage"
#: templates/index.html:33
msgid "About nuage"
#: templates/index.html:21
msgid "Shedule an event"
msgstr "Rendez-vous partagé"
#: templates/index.html:24
#, fuzzy
msgid "About nuages"
msgstr "À propos de nuage"
#: templates/index.html:32
msgid "My polls"
msgstr "Mes sondages"
#: templates/index.html:46
msgid "No polls are available."
msgstr "Aucun sondage disponible"
#: templates/index.html:52
msgid "Examples"
msgstr "Examples"
#: templates/nuages.html:9
msgid ""
"A collaborative meeting poll system, similar to doodle or rdvz. It is build "
"in python, using the django framework and a little of javascript. This "
"application was named after Django's famous song."
msgstr ""
#: templates/nuages.html:10
msgid "Feedback and collaboration are welcome at"
msgstr ""
{% load i18n %}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title> {% block title %} nuage - Easy poll sharing {% endblock %} </title>
<title> {% block title %} nuages - {% trans "Easy poll sharing" %} {% endblock %} </title>
{% block head %}{% endblock %}
<!-- Django stylesheets -->
......@@ -11,30 +13,40 @@
<!--link rel="stylesheet" type="text/css" href="/media/css/widgets.css"/-->
<!-- Custom stylesheet -->
<link rel="stylesheet" href="/static/css/nuage.css" />
<link rel="stylesheet" href="/static/css/nuages.css" />
</head>
<body>
<div id="nheader">
<div id="menu"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<div class="menu"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="/">nuage</a> &nbsp;
<a href="/">Nuages</a> &nbsp;
{% if user.is_authenticated %}
<a href="/user/logout/">logout</a>
{% else %}
<a href="/user/login/">login</a>
<a href="/user/login/">Login</a>
{% endif %}
{% block menu %}{% endblock %}
{% if error_message %}
<div id="notify"><!--img src="/static/images/info.png" alt="info" "-->&nbsp; {{ error_message }} </div>
{% if error_message %} &nbsp;&nbsp;&nbsp;
<div id="notify"><!--img src="/static/images/info.png" alt="info" "-->&nbsp; <span class="tip">{{ error_message }} </span></div>
{% endif %}
<span class="right"><form style="display:nline" name="langForm" action="/i18n/setlang/" method="post">
<input name="next" type="hidden" value="/" />
<!--option value="">Language </option!-->
<select name="language" onChange="langForm.submit()" />
<option value="#" /></option>
{% for lang in LANGUAGES %}
<option value="{{ lang.0 }}" />{{ lang.0 }}</option>
{% endfor %}
</select>
</form></span>
</div>
<div>
</div>
<div id="chapeau">
{% block chapeau %}{% endblock %}
......@@ -46,6 +58,10 @@
{% block content %}{% endblock %}
</div>
<div id="nfooter">
{% block footer %}{% endblock %}
<span >{% trans "Nuages is brought to you by" %} <a href="http://www.domainepublic.net">Domaine Public</a>.</span>
</div>
</body>
......
{% extends "base.html" %}
{% load i18n %}
{% block chapeau %}
<h2>nuage</h2>
<h2>nuages</h2>
<p class="info">
<i>nuage</i> let you create polls easily, and publish them for your mates. You may poll on dates or any subject, in order to plan meetings or get a group opinion.
{% trans "Create polls easily, and publish them for your mates. You may poll on dates or any subject, in order to plan meetings or get a group opinion." %}
</p>
{% endblock %}
......@@ -13,14 +14,14 @@
<br /><br /><br />
<div class="hide"> <a href="#"><p class="icone">
<img width="24px" src="/static/images/view-calendar-list.png" alt="Make a poll"> &nbsp; New poll</p></a> </div>
<img width="24px" src="/static/images/view-calendar-list.png" alt="Make a poll"> &nbsp; {% trans "New poll" %}</p></a> </div>
<a href="/new/" title="Make an poll" alt="Make an event"><p class="icone">
<img width="24px" src="/static/images/view-calendar-day-2.png"> &nbsp; &nbsp; Shedule an event</p></a>
<img width="24px" src="/static/images/view-calendar-day-2.png"> &nbsp; &nbsp; {% trans "Shedule an event" %}</p></a>
<a href="/nuage" title="Make an event" alt="Learn more"><p class="icone">
<img width="24px" src="/static/images/document-send.png"> &nbsp; About nuage</p></a>
<a href="/nuages" title="Make an event" alt="Learn more"><p class="icone">
<img width="24px" src="/static/images/document-send.png"> &nbsp; {% trans "About nuages" %}</p></a>
<br /><br /><br /><br /> <br /><br />
......@@ -28,7 +29,7 @@
{% if user.is_authenticated %}
<h3>My polls</h3>
<h3>{% trans "My polls" %}</h3>
{% if object_list %}
<ul>
{% for object in object_list %}
......@@ -42,13 +43,13 @@
</ul>
{% else %}
<p>No polls are available.</p>
<p>{% trans "No polls are available." %}</p>
{% endif %}
{% else %}
<h3>Examples</h3>
<h3>{% trans "Examples" %}</h3>
<ul>
<li><a href="/7d31/">Quand allons nous au potager?</a></li>
......
......@@ -5,10 +5,10 @@
<h2>About</h2>
<p class="info">
A collaborative meeting poll system, similar to doodle or rdvz. It is build in python, using the django framework and a little of javascript. This application was named after Django's famous song.
{% trans "A collaborative meeting poll system, similar to doodle or rdvz. It is build in python, using the django framework and a little of javascript. This application was named after Django's famous song.
Feedback and collaboration are welcome at <a href="mailto:">nuage@ domainepublic.net</a>.
Here is the <a href="http://projets.domainepublic.net/projects/nuage/">project page</a>,
sources</a> are <a href="http://www.gnu.org/licenses/gpl.html">freely</a> available.
sources</a> are <a href="http://www.gnu.org/licenses/gpl.html">freely</a> available." %}
</p>
{% endblock %}
......
......@@ -31,7 +31,7 @@ urlpatterns = patterns('',
# (r'^admin/', include(admin.site.urls)),
(r'^$', 'django.views.generic.list_detail.object_list', dict(info_dict, template_name='index.html')),
(r'^nuages$', 'django.views.generic.simple.direct_to_template', {'template': 'nuage.html'}),
(r'^nuages$', 'django.views.generic.simple.direct_to_template', {'template': 'nuages.html'}),
(r'^(?P<poll_id>\w{4})/$', 'nuage.sondage.views.vote'),
(r'^new/$', 'nuage.sondage.views.new'),
(r'^(?P<object_id>\w+)/edit/$', 'nuage.sondage.views.secure_update_object', dict(poll_dict, post_save_redirect='choices/')),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment