Downgrading django from 1.10 to 1.9. Added supports.html. Added supports view . Fixing post supports style. Working on # #2689 Removing links from supportus.html. . Working on # #2689 FIxed history fonts style and color . Working on # #2689 Finished supportus.html. Working on # #2689 Tagging post. Working on # #2689 Fixing broken links history.html. Working on #2674 Deactivate membership. Working on #2686 Reactivate membership
This commit is contained in:
parent
2102823f8e
commit
2a4b6e973d
8 changed files with 131 additions and 65 deletions
|
@ -91,7 +91,8 @@ class Membership(models.Model):
|
||||||
@classmethod
|
@classmethod
|
||||||
def activate_or_crete(cls, data, user):
|
def activate_or_crete(cls, data, user):
|
||||||
membership = cls.get_by_user(user)
|
membership = cls.get_by_user(user)
|
||||||
obj, created = cls.objects.update_or_create(id=membership.id, defaults=data)
|
membership_id = membership.id if membership else None
|
||||||
|
obj, created = cls.objects.update_or_create(id=membership_id, defaults=data)
|
||||||
return obj
|
return obj
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
|
|
@ -254,7 +254,7 @@ header {
|
||||||
|
|
||||||
.supporter-black {
|
.supporter-black {
|
||||||
padding: 15px 5px 15px;
|
padding: 15px 5px 15px;
|
||||||
color: #f5f5f5;
|
color: #000000;
|
||||||
font-size:18px;
|
font-size:18px;
|
||||||
font-weight: 200;
|
font-weight: 200;
|
||||||
font-family:raleway, monteserrat, open sans, helvitica neue, sans-serif;
|
font-family:raleway, monteserrat, open sans, helvitica neue, sans-serif;
|
||||||
|
|
|
@ -102,7 +102,7 @@
|
||||||
<br>
|
<br>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
<br>
|
<br>
|
||||||
<a href="http://startbootstrap.com/template-overviews/creative/" class="btn btn-default btn-primary sr-button">Become a supporter</a>
|
<a href="{% url 'digitalglarus:supportus' %}" class="btn btn-default btn-primary sr-button">Become a supporter</a>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
|
|
|
@ -1,6 +1,34 @@
|
||||||
{% extends "new_base_glarus.html" %}
|
{% extends "new_base_glarus.html" %}
|
||||||
{% load staticfiles cms_tags %}
|
{% load staticfiles cms_tags %}
|
||||||
|
|
||||||
|
{% block extra_css %}
|
||||||
|
<style type="text/css">
|
||||||
|
|
||||||
|
.supportus-posts .post-preview {
|
||||||
|
background-color: white;
|
||||||
|
padding-right: 3%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.supportus-posts img {
|
||||||
|
margin:6% !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.supportus-posts p {
|
||||||
|
/*font-size: 0.5em !important;*/
|
||||||
|
}
|
||||||
|
|
||||||
|
.supportus-posts .post-meta {
|
||||||
|
font-size: 0.4em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.supporter-white {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
<!-- Header -->
|
<!-- Header -->
|
||||||
|
@ -38,9 +66,9 @@
|
||||||
|
|
||||||
<div class="col-md-4 col-sm-6 portfolio-item text-center wow fadeInDown">
|
<div class="col-md-4 col-sm-6 portfolio-item text-center wow fadeInDown">
|
||||||
<div class="supportus-box">
|
<div class="supportus-box">
|
||||||
<a href="#">
|
<!-- <a href="#"> -->
|
||||||
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/2.png' %}" alt="">
|
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/2.png' %}" alt="">
|
||||||
</a>
|
<!-- </a> -->
|
||||||
|
|
||||||
<h3 class="donate">Get our news</h3>
|
<h3 class="donate">Get our news</h3>
|
||||||
|
|
||||||
|
@ -57,9 +85,9 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-4 col-sm-6 text-center wow fadeInDown">
|
<div class="col-md-4 col-sm-6 text-center wow fadeInDown">
|
||||||
<div class="supportus-box">
|
<div class="supportus-box">
|
||||||
<a href="#">
|
<!-- <a href="#"> -->
|
||||||
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/3.png' %}" alt="">
|
<img class="img-responsive img-centered image-blog " src="{% static 'digitalglarus/img/supportus/3.png' %}" alt="">
|
||||||
</a>
|
<!-- </a> -->
|
||||||
|
|
||||||
<h3 class="donate">Connect and Share</h3>
|
<h3 class="donate">Connect and Share</h3>
|
||||||
|
|
||||||
|
@ -80,9 +108,9 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-4 col-sm-6 text-center wow fadeInDown">
|
<div class="col-md-4 col-sm-6 text-center wow fadeInDown">
|
||||||
<div class="supportus-box">
|
<div class="supportus-box">
|
||||||
<a href="#">
|
<!-- <a href="#"> -->
|
||||||
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/1.png' %}" alt="">
|
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/1.png' %}" alt="">
|
||||||
</a>
|
<!-- </a> -->
|
||||||
|
|
||||||
<h3 class="donate">
|
<h3 class="donate">
|
||||||
Donate now
|
Donate now
|
||||||
|
@ -107,20 +135,20 @@
|
||||||
<div class="col-md-12 col-lg-12 text-center wow fadeInDown whatwedowith">
|
<div class="col-md-12 col-lg-12 text-center wow fadeInDown whatwedowith">
|
||||||
<div class="whatwe-wrap">
|
<div class="whatwe-wrap">
|
||||||
<h2 class="whatwedo">What we do with your support</h2>
|
<h2 class="whatwedo">What we do with your support</h2>
|
||||||
<p class="carousel-text text-center supporter-black">Discover how your donation is being used in renovating our coworking space!</p>
|
<p class="carousel-text text-center supporter-white">Discover how your donation is being used in renovating our coworking space!</p>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-2"></div>
|
<div class="col-md-3"></div>
|
||||||
<div class="col-md-8">
|
<div class="col-md-6 supportus-posts">
|
||||||
<section class="blog-list">
|
<section class="blog-list">
|
||||||
{% for post in post_list %}
|
{% for post in post_list %}
|
||||||
{% include "ungleich/djangocms_blog/includes/blog_item.html" with post=post image="true" TRUNCWORDS_COUNT=TRUNCWORDS_COUNT %}
|
{% include "ungleich/djangocms_blog/includes/blog_item.html" with post=post image="true" TRUNCWORDS_COUNT=TRUNCWORDS_COUNT %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<a href="https://blog.ungleich.ch/en-us/blog/2016/05/21/renovation-digital-chalet/">
|
<!-- <a href="https://blog.ungleich.ch/en-us/blog/2016/05/21/renovation-digital-chalet/">
|
||||||
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/7.png' %}" alt="">
|
<img class="img-responsive img-centered" src="{% static 'digitalglarus/img/supportus/7.png' %}" alt="">
|
||||||
</a>
|
</a>
|
||||||
</div>
|
--> </div>
|
||||||
<div class="col-md-2"></div>
|
<div class="col-md-2"></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -80,6 +80,7 @@
|
||||||
color:white;
|
color:white;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
{% block extra_css %} {% endblock %}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
|
||||||
|
@ -112,6 +113,9 @@
|
||||||
<li>
|
<li>
|
||||||
<a class="page-scroll" href="{% url 'digitalglarus:history' %}">history</a>
|
<a class="page-scroll" href="{% url 'digitalglarus:history' %}">history</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a class="page-scroll" href="{% url 'digitalglarus:supportus' %}">support us</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a class="page-scroll" href="http://blog.ungleich.ch">BLOG</a>
|
<a class="page-scroll" href="http://blog.ungleich.ch">BLOG</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
|
@ -51,7 +51,7 @@ class SupportusView(TemplateView):
|
||||||
|
|
||||||
def get_context_data(self, *args, **kwargs):
|
def get_context_data(self, *args, **kwargs):
|
||||||
context = super(SupportusView, self).get_context_data(**kwargs)
|
context = super(SupportusView, self).get_context_data(**kwargs)
|
||||||
tags = ["digitalglarus"]
|
tags = ["dg-renovation"]
|
||||||
posts = Post.objects.filter(tags__name__in=tags, publish=True).translated(get_language())
|
posts = Post.objects.filter(tags__name__in=tags, publish=True).translated(get_language())
|
||||||
context.update({
|
context.update({
|
||||||
'post_list': posts
|
'post_list': posts
|
||||||
|
|
129
requirements.txt
129
requirements.txt
|
@ -1,53 +1,86 @@
|
||||||
|
Babel==2.3.4
|
||||||
Django==1.9.4
|
Django==1.9.4
|
||||||
aldryn-newsblog
|
Django-Select2==4.3.2
|
||||||
wheel
|
Pillow==3.2.0
|
||||||
django-bootstrap3
|
URLObject==2.4.0
|
||||||
django-cms
|
Unidecode==0.04.19
|
||||||
django-compressor
|
YURL==0.13
|
||||||
django-filter
|
aldryn-apphooks-config==0.2.7
|
||||||
django-taggit
|
aldryn-boilerplates==0.7.4
|
||||||
django-taggit-autosuggest
|
aldryn-categories==1.0.3
|
||||||
django-taggit-templatetags
|
aldryn-common==1.0.1
|
||||||
django-templatetag-sugar
|
aldryn-newsblog==1.2.1
|
||||||
django-model-utils
|
aldryn-people==1.2.0
|
||||||
djangocms-blog
|
aldryn-reversion==1.0.8
|
||||||
django-dotenv
|
aldryn-search==0.2.11
|
||||||
psycopg2
|
aldryn-translation-tools==0.2.1
|
||||||
django-mptt
|
backport-collections==0.1
|
||||||
easy_thumbnails
|
cmsplugin-filer==1.0.1
|
||||||
django-polymorphic
|
django-appconf==1.0.2
|
||||||
model-mommy
|
django-appdata==0.1.5
|
||||||
pycryptodome
|
django-bootstrap3==7.0.1
|
||||||
django-stored-messages
|
django-classy-tags==0.7.2
|
||||||
django-guardian
|
django-cms==3.2.5
|
||||||
|
django-compressor==2.0
|
||||||
|
django-debug-toolbar==1.4
|
||||||
|
django-dotenv==1.4.1
|
||||||
|
django-extensions==1.6.7
|
||||||
|
django-filer==1.2.0
|
||||||
|
django-filter==0.13.0
|
||||||
|
django-formtools==1.0
|
||||||
|
django-guardian==1.4.4
|
||||||
|
django-haystack==2.4.1
|
||||||
|
django-meta==1.2
|
||||||
|
django-meta-mixin==0.3.0
|
||||||
|
django-model-utils==2.5
|
||||||
|
django-mptt==0.8.4
|
||||||
|
django-parler==1.6.3
|
||||||
|
django-phonenumber-field==1.1.0
|
||||||
|
django-polymorphic==0.9.2
|
||||||
|
django-reversion==1.10.2
|
||||||
|
django-sekizai==0.9.0
|
||||||
|
django-sortedm2m==1.2.2
|
||||||
|
django-spurl==0.6.4
|
||||||
|
django-standard-form==1.1.1
|
||||||
|
django-stored-messages==1.4.0
|
||||||
|
django-taggit==0.18.3
|
||||||
|
django-taggit-autosuggest==0.2.8
|
||||||
|
django-taggit-templatetags==0.2.5
|
||||||
|
django-templatetag-sugar==1.0
|
||||||
|
django-treebeard==4.0.1
|
||||||
|
djangocms-admin-style==1.1.1
|
||||||
|
djangocms-apphook-setup==0.1.2
|
||||||
|
djangocms-blog==0.7.0
|
||||||
|
djangocms-file==1.0
|
||||||
|
djangocms-flash==0.3.0
|
||||||
|
djangocms-googlemap==0.4.0
|
||||||
|
djangocms-inherit==0.2.1
|
||||||
|
djangocms-link==1.7.2
|
||||||
|
djangocms-page-meta==0.5.11
|
||||||
|
djangocms-picture==1.0.0
|
||||||
|
djangocms-teaser==0.2.0
|
||||||
|
djangocms-text-ckeditor==2.9.3
|
||||||
|
djangocms-video==1.0.0
|
||||||
|
easy-thumbnails==2.3
|
||||||
|
html5lib==0.9999999
|
||||||
|
lxml==3.6.0
|
||||||
|
model-mommy==1.2.6
|
||||||
|
phonenumbers==7.4.0
|
||||||
|
phonenumberslite==7.4.0
|
||||||
|
psycopg2==2.6.1
|
||||||
|
pycryptodome==3.4
|
||||||
|
pylibmc==1.5.1
|
||||||
|
python-dateutil==2.5.3
|
||||||
|
python-slugify==1.2.0
|
||||||
|
pytz==2016.4
|
||||||
|
rcssmin==1.0.6
|
||||||
|
requests==2.10.0
|
||||||
|
rjsmin==1.0.12
|
||||||
|
six==1.10.0
|
||||||
|
sqlparse==0.1.19
|
||||||
|
stripe==1.33.0
|
||||||
|
wheel==0.29.0
|
||||||
|
|
||||||
#PLUGINS
|
|
||||||
djangocms_flash
|
|
||||||
djangocms_googlemap
|
|
||||||
djangocms_inherit
|
|
||||||
djangocms_link
|
|
||||||
djangocms_teaser
|
|
||||||
djangocms_page_meta
|
|
||||||
djangocms_text_ckeditor
|
|
||||||
djangocms_file
|
|
||||||
djangocms_picture
|
|
||||||
djangocms_video
|
|
||||||
|
|
||||||
#PAYMENT
|
|
||||||
stripe
|
|
||||||
|
|
||||||
django-treebeard
|
|
||||||
django-sekizai
|
|
||||||
django-classy-tags
|
|
||||||
djangocms-admin-style
|
|
||||||
html5lib
|
|
||||||
six
|
|
||||||
|
|
||||||
# Optional, recommended packages
|
|
||||||
Pillow>=2
|
|
||||||
django-filer
|
|
||||||
cmsplugin-filer
|
|
||||||
django-reversion
|
|
||||||
pylibmc
|
|
||||||
django_extensions
|
|
||||||
django-debug-toolbar
|
|
|
@ -31,7 +31,7 @@
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p class="post-subtitle">
|
<p class="post-subtitle">
|
||||||
{% if not TRUNCWORDS_COUNT %}
|
{% if not TRUNCWORDS_COUNT %}
|
||||||
{% render_model post "abstract" %}
|
{% render_model post "abstract" %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{% render_model post "abstract" "" "" 'truncatewords_html:TRUNCWORDS_COUNT' %}
|
{% render_model post "abstract" "" "" 'truncatewords_html:TRUNCWORDS_COUNT' %}
|
||||||
|
|
Loading…
Reference in a new issue