Skip to content

Commit

Permalink
integrate django cms, add contrib page
Browse files Browse the repository at this point in the history
  • Loading branch information
glibersat committed Oct 21, 2011
1 parent 9f3ffe4 commit 4675f75
Show file tree
Hide file tree
Showing 32 changed files with 759 additions and 2 deletions.
439 changes: 439 additions & 0 deletions apps/i4p_base/static/css/pages/style.css

Large diffs are not rendered by default.

Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added apps/i4p_base/static/images/pages/contrib/rss.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
77 changes: 77 additions & 0 deletions apps/i4p_base/templates/pages/base.html
@@ -0,0 +1,77 @@
{% load i18n cms_tags menu_tags sekizai_tags %}
{% load compress %}
<!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="fr" lang="fr">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Imagination for People - Contrib - {% page_attribute page_title %}</title>

<meta name="description" content="{% page_attribute meta_description %}"/>
<meta name="keywords" content="{% page_attribute meta_keywords %}"/>

{% addtoblock "css" %}
{% compress css %}
<link href="{{ STATIC_URL }}css/pages/style.css" media="all" rel="stylesheet" type="text/css" />
{% endcompress %}
{% endaddtoblock %}

{% addtoblock "js" %}
{% compress js %}
<script type="text/javascript" src="{{ STATIC_URL }}js/jquery-1.6.1.js"></script>
{% endcompress %}
<script type="text/javascript">
jQuery(document).ready(function($){

$(".details").hide();
$(".details").first().show();

$("ul#jobs li a").mouseenter(function(){
$(".details").stop().fadeOut("slow");
var panelID=$(this).attr("href");
$("#"+panelID).fadeIn("slow");
});
});

</script>
{% endaddtoblock %}

{% block extra_head %}{% endblock %}

{% render_block "css" %}



</head>


<body>

{% if user.is_authenticated %}
{% cms_toolbar %}
{% endif %}


{% block header %} {% include "pages/header.html" %} {% endblock %}


<div class="centreur">

<div class="content">

{% block content %}{% endblock %}

</div>
<div class="push"></div>
</div>


{% block footer %} {% include "pages/footer.html" %} {% endblock %}

{% render_block "js" %}


</body>

</html>
172 changes: 172 additions & 0 deletions apps/i4p_base/templates/pages/contrib.html
@@ -0,0 +1,172 @@
{% extends "pages/base.html" %}
{% load i18n cms_tags %}


{% block content %}


<!-- ACCROCHE -->

<img id="accroche" src="{{ STATIC_URL }}images/pages/contrib/accroche.jpg" width="974px" height="114px" alt="Une communauté dédiée à l'imagination citoyenne" />
<br />
<h2>
<a href="http://imaginationforpeople.org" target="_blank">Imaginationforpeople.org</a> est propulsée par un ensemble de composants libres sous <a href="http://fr.wikipedia.org/wiki/GNU_Affero_General_Public_License" target="_blank">licences AGPL</a> et <a href="http://fr.wikipedia.org/wiki/Creative_Commons" target="_blank">Creative Commons.</a>
<br />
Cette plateforme est la votre, la notre : vous pouvez aider à l'améliorer ou l'utiliser pour votre propre projet.
</h2>


<!-- GROS BLOC CENTRAL DES DIFFERENTS METIERS-->

<div id="jobs_block">
<!-- Pictos des différents jobs -->
<ul id="jobs">
<li><a href="trad"><img src="{{ STATIC_URL }}images/pages/contrib/job-trad.jpg" width="159px" height="126px" alt="Traducteur" /></a></li>
<div class="separatorv"></div>
<li><a href="dev"><img src="{{ STATIC_URL }}images/pages/contrib/job-dev.jpg" width="159px" height="126px" alt="Developpeur" /></a></li>
<div class="separatorv"></div>
<li><a href="graph"><img src="{{ STATIC_URL }}images/pages/contrib/job-graph.jpg" width="159px" height="126px" alt="Graphiste" /></a></li>
<div class="separatorv"></div>
<li><a href="redac"><img src="{{ STATIC_URL }}images/pages/contrib/job-redac.jpg" width="159px" height="126px" alt="Redacteur" /></a></li>
<div class="separatorv"></div>
<li><a href="ess"><img src="{{ STATIC_URL }}images/pages/contrib/job-ess.jpg" width="159px" height="126px" alt="Essaimeur" /></a></li>
<div class="separatorv"></div>
<li><a href="rapp"><img src="{{ STATIC_URL }}images/pages/contrib/job-rap.jpg" width="159px" height="126px" alt="Rapporteur" /></a></li>
</ul>

<div class="clear"></div>

<!-- Détails des jobs -->
<div class="details-block">
<div class="details" id="trad">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-trad.png" width="387px" height="167px" />
<p>Developers can help Mozilla by adding new features, making our technology smaller and faster and making development easier for others. You can find many developers on IRC so stop by and ask ...</p>
<a href="#">Get the code</a>
</div>

<div class="details" id="dev">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-dev.png" width="387px" height="167px" />
<p>Developers can help Mozilla by adding new features, making our technology smaller and faster and making development easier for others. You can find many developers on IRC so stop by and ask ...</p>
<a href="#">Get the code</a>
</div>

<div class="details" id="graph">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-graph.png" width="387px" height="167px" />
<p>Developers can help Mozilla by adding new features, making our technology smaller and faster and making development easier for others. You can find many developers on IRC so stop by and ask ...</p>
<a href="#">Get the code</a>
</div>

<div class="details" id="redac">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-redac.png" width="387px" height="167px" />
<p>Developers can help Mozilla by adding new features, making our technology smaller and faster and making development easier for others. You can find many developers on IRC so stop by and ask ...</p>
<a href="#">Get the code</a>
</div>

<div class="details" id="ess">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-ess.png" width="387px" height="167px" />
<p>Developers can help Mozilla by adding new features, making our technology smaller and faster and making development easier for others. You can find many developers on IRC so stop by and ask ...</p>
<a href="#">Get the code</a>
</div>

<div class="details" id="rapp">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="387px" height="167px" />
<p>Developers can help Mozilla by adding new features, making our technology smaller and faster and making development easier for others. You can find many developers on IRC so stop by and ask ...</p>
<a href="#">Get the code</a>
</div>
</div>

<div class="clear"></div>
</div>
<img class="tache_centre" src="{{ STATIC_URL }}images/pages/contrib/tache-centre.jpg" width="974px" height="30px" alt="Une communauté dédiée à l'imagination citoyenne" />

<br /><br />


<!-- BLOC CONTENU LES 3 COLONNES DE NEWS DIVERSES-->

<div class="col col1">
<h1>Dernières activités<img src="{{ STATIC_URL }}images/pages/contrib/arrow-ico.jpg" width="20px" height="21x" style="float:right;" /></h1>
<ul>
<li class="odd">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="24px" height="24x" alt="Guillaume Libersat" />
<span>10:37 | Guillaume Libersat</span>
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>

<li class="even">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="24px" height="24x" alt="Guillaume Libersat" />
<span>10:37 | Guillaume Libersat</span>
<p><a href="#">Révision 3e336783: Merge branch 'hotfix/loginforms'</a></p>
</li>

<li class="odd">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="24px" height="24x" alt="Guillaume Libersat" />
<span>10:37 | Guillaume Libersat</span>
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>

<li class="even">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="24px" height="24x" alt="Guillaume Libersat" />
<span>10:37 | Guillaume Libersat</span>
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>
</ul>
</div>

<div class="col col2">

<h1>Rejoignez la communauté</h1>
<ul class="community">
<li>
<span>Blabla bla canaal irc blabal coincoin</span>
<p>#14p@irc.freenode.net</p>
</li>
<li>
<span>Blabla bla canaal irc blabal coincoin</span>
<p>#14p@irc.freenode.net</p>
</li>
</ul>

<h1>Derniers commits<img src="{{ STATIC_URL }}images/pages/contrib/arrow-ico.jpg" width="20px" height="21x" style="float:right;" /></h1>
<ul>
<li class="odd">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="24px" height="24x" alt="Guillaume Libersat" />
<span>10:37 | Guillaume Libersat</span>
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>

<li class="even">
<img src="{{ STATIC_URL }}images/pages/contrib/illus-rapp.png" width="24px" height="24x" alt="Guillaume Libersat" />
<span>10:37 | Guillaume Libersat</span>
<p><a href="#">Révision 3e336783: Merge branch 'hotfix/loginforms'</a></p>
</li>
</ul>

</div>

<div class="col col3">
<h1>Blog / News<img src="{{ STATIC_URL }}images/pages/contrib/rss.jpg" width="20px" height="21x" alt="RSS" style="float:right;" /></h1>
<ul>
<li class="odd">
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>

<li class="even">
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>

<li class="odd">
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>

<li class="even">
<p>Révision 3e336783: Merge branch 'hotfix/loginforms'</p>
</li>
</ul>
</div>

<div class="clear"></div>
<br /><br /><br />


{% endblock %}
33 changes: 33 additions & 0 deletions apps/i4p_base/templates/pages/footer.html
@@ -0,0 +1,33 @@
<div id="footer">
<div class="centreur">

<img id="logo" src="{{ STATIC_URL }}images/pages/contrib/footer-logo.jpg" width="225px" height="81px" alt="Imagination for People - Contrib" />

<div id="links">
<div class="separatorv"></div>
<ul >
<h1>Nébuleuse</h1>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
</ul>
<div class="separatorv"></div>
<ul>
<h1>A propos</h1>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
</ul>
<div class="separatorv"></div>
<ul>
<h1>Participez</h1>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
<li><a href="#">Les plus</a></li>
</ul>
</div>
</div>
<div id="tache-top"></div>
</div>
17 changes: 17 additions & 0 deletions apps/i4p_base/templates/pages/header.html
@@ -0,0 +1,17 @@
<div id="header">
<div class="centreur">
<a href="/">
<img id="logo" src="{{ STATIC_URL }}images/pages/contrib/logo.png" width="194px" height="63px" alt="Imagination for People - Contrib" />
</a>

<ul id="menu">
<li><a href="#">Prestations / tarifs</a></li>
<li><a href="#">Promotions</a></li>
<li><a href="#">Les plus</a></li>
<li><a href="#">A propos de moi</a></li>
<li><a href="#">Contact</a></li>
</ul>
</div>

<div id="tache-top"></div>
</div>
1 change: 1 addition & 0 deletions requirements.txt
Expand Up @@ -9,6 +9,7 @@ django-countries==1.0.5

django-tagging==0.3.1
django-autoslug==1.4.1
django-cms==2.2

django-imagekit==0.3.6
Pillow==1.7.4
Expand Down
19 changes: 18 additions & 1 deletion settings.py
Expand Up @@ -98,7 +98,10 @@

'localeurl.middleware.LocaleURLMiddleware',


'cms.middleware.multilingual.MultilingualURLMiddleware',
'cms.middleware.page.CurrentPageMiddleware',
'cms.middleware.user.CurrentUserMiddleware',
'cms.middleware.toolbar.ToolbarMiddleware',
)

if DEBUG:
Expand All @@ -123,6 +126,9 @@
'django.core.context_processors.static',
'apps.project_sheet.context_processors.project_search_forms',
'apps.member.context_processors.member_forms',

'cms.context_processors.media',
'sekizai.context_processors.sekizai',
)


Expand Down Expand Up @@ -186,6 +192,11 @@
'django.contrib.humanize',

'emencia.django.newsletter',
'cms',
'mptt',
'menus',
'sekizai',
'cms.plugins.text',

# Internal Apps
'apps.i4p_base',
Expand Down Expand Up @@ -290,6 +301,7 @@
LOCALE_INDEPENDENT_PATHS = (
re.compile('^/js/dajax/.*$'),
re.compile('^/static/.*$'),
re.compile('^/admin/.*$'),
re.compile('^/media/.*$'),
re.compile('^/robots.txt$'),
re.compile('^/sitemap.xml$'),
Expand Down Expand Up @@ -400,3 +412,8 @@

## Newsletter
DEFAULT_HEADER_SENDER = "Imagination For People Newsletter <contact@imaginationforpeople.org>"

## CMS
CMS_TEMPLATES = (
('pages/contrib.html', 'Contrib page'),
)
3 changes: 2 additions & 1 deletion urls.py
Expand Up @@ -22,6 +22,7 @@

urlpatterns = patterns('',
url(r'^', include('apps.i4p_base.urls')),

url(r'^comment/', include('django.contrib.comments.urls')),
url(r'^notification/', include('notification.urls')),
url(r'^project/', include('apps.project_sheet.urls')),
Expand All @@ -43,11 +44,11 @@
(r'^tinymce/', include('tinymce.urls')),
(r'^uploadify/', include('uploadify.urls')),

# (r'^grappelli/', include('grappelli.urls')),
url(r'^admin/filebrowser/', include('filebrowser.urls')),

(r'^admin/doc/', include('django.contrib.admindocs.urls')),
(r'^admin/', include(admin.site.urls)),
url(r'^', include('cms.urls')),
)

## Javascript i18n catalog
Expand Down

0 comments on commit 4675f75

Please sign in to comment.