1- {% extends 'base.html' %}
2-
1+ {% extends 'base.html' %} {% block content %}
2+ < div class ="pricing-header px-3 py-3 pt-md-5 pb-md-4 mx-auto text-center ">
3+ < h3 class ="display-5 "> Pricing</ h3 >
4+ </ div >
35
4- {% block content %}
5- < div class ="pricing-header px-3 py-3 pt-md-5 pb-md-4 mx-auto text-center ">
6- < h3 class ="display-5 "> Pricing</ h3 >
7- </ div >
8-
96< div class ="container ">
10- < div class ="card-deck mb-3 text-center ">
11- {% for plan in object_list %}
12- < div class ="card mb-4 shadow-sm ">
13- < div class ="card-header ">
14- < h4 class ="my-0 font-weight-normal "> {{plan.name}}</ h4 >
15- </ div >
16- < div class ="card-body ">
17- < h5 class ="card-title pricing-card-title "> Tshs. {{plan.price}} < small class ="text-muted "> / mo</ small > </ h5 >
18- < ul class ="list-unstyled mt-3 mb-4 ">
19- < li > 3 users included</ li >
20- < li > 3 Branch/store</ li >
21- < li > Free support</ li >
22- < li > Centre manager</ li >
23- </ ul >
24- {% if request.user.is_authenticated %}
25- {% if plan.name == 'Free' %}
26- {% if plan.name != current_plan %}
27- < small class ="text-warning "> You can not subscribe to free plan</ small >
28- {% else %}
29- < small class ="text-success "> This is your current plan</ small >
30- {% endif %}
31- {% else %}
32- < form action ="" method ="POST ">
33- {% csrf_token %}
34- {% if plan.name != current_plan %}
35- < button class ="btn btn-lg btn-block btn-primary "> Buy Now</ button >
36- {% else %}
37- < small class ="text-success "> This is your current plan</ small >
38- {% endif %}
39- < input type ="hidden " name ="plan_id " value ="{{plan.id}} ">
40- </ form >
41- {% endif %}
42- {% else %}
43- {% if plan.name == 'Free' %}
44- < a href ="{% url 'accounts:signup' %} " class ="btn btn-lg btn-block btn-outline-primary "> Sign up for free</ a >
45- {% else %}
46- < a href ="{% url 'accounts:signup' %} " class ="btn btn-lg btn-block btn-primary "> Get Started</ a >
47- {% endif %}
48- {% endif %}
49-
50- </ div >
51- </ div >
52- {% endfor %}
7+ < div class ="card-deck mb-3 text-center ">
8+ {% for plan in object_list %}
9+ < div class ="card mb-4 shadow-sm ">
10+ < div class ="card-header ">
11+ < h4 class ="my-0 font-weight-normal "> {{plan.name}}</ h4 >
12+ </ div >
13+ < div class ="card-body ">
14+ < h5 class ="card-title pricing-card-title ">
15+ ${{plan.price|floatformat:2}} < small class ="text-muted "> / mo</ small >
16+ </ h5 >
17+ < ul class ="list-unstyled mt-3 mb-4 ">
18+ < li > {{plan.max_staff}} staff included</ li >
19+ < li > {{plan.max_branch}} branch/store</ li >
20+ < li > {{plan.duration_days}} days duration</ li >
21+ < li > Free support</ li >
22+ </ ul >
23+ {% if request.user.is_authenticated %} {% if plan.name == 'Free' %} {%
24+ if plan.name != current_plan %}
25+ < small class ="text-warning "> You can not subscribe to free plan</ small >
26+ {% else %}
27+ < small class ="text-success "> This is your current plan</ small >
28+ {% endif %} {% else %}
29+ < form action ="" method ="POST ">
30+ {% csrf_token %} {% if plan.name != current_plan %}
31+ < button class ="btn btn-lg btn-block btn-primary "> Buy Now</ button >
32+ {% else %}
33+ < small class ="text-success "> This is your current plan</ small >
34+ {% endif %}
35+ < input type ="hidden " name ="plan_id " value ="{{plan.id}} " />
36+ </ form >
37+ {% endif %} {% else %} {% if plan.name == 'Free' %}
38+ < a
39+ href ="{% url 'accounts:signup' %} "
40+ class ="btn btn-lg btn-block btn-outline-primary "
41+ > Sign up for free</ a
42+ >
43+ {% else %}
44+ < a
45+ href ="{% url 'accounts:signup' %} "
46+ class ="btn btn-lg btn-block btn-primary "
47+ > Get Started</ a
48+ >
49+ {% endif %} {% endif %}
50+ </ div >
5351 </ div >
52+ {% endfor %}
53+ </ div >
5454</ div >
5555
56- {% endblock %}
56+ {% endblock %}
0 commit comments