richie 3.1.3.dev30__py2.py3-none-any.whl → 3.1.3.dev31__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of richie might be problematic. Click here for more details.

@@ -683,6 +683,15 @@ class Course(EsIdMixin, BasePageExtension):
683
683
  return self.best_course_run.price
684
684
  return None
685
685
 
686
+ @property
687
+ def discounted_price(self):
688
+ """
689
+ Returns the discounted price of the course run with the best state.
690
+ """
691
+ if self.best_course_run:
692
+ return self.best_course_run.discounted_price
693
+ return None
694
+
686
695
  @property
687
696
  def certificate_offer(self):
688
697
  """
@@ -701,6 +710,15 @@ class Course(EsIdMixin, BasePageExtension):
701
710
  return self.best_course_run.certificate_price
702
711
  return None
703
712
 
713
+ @property
714
+ def discounted_certificate_price(self):
715
+ """
716
+ Returns the discounted certificate price of the course run with the best state.
717
+ """
718
+ if self.best_course_run:
719
+ return self.best_course_run.discounted_certificate_price
720
+ return None
721
+
704
722
  def copy_relations(self, oldinstance, language=None):
705
723
  """
706
724
  This method is called for 2 types of copying:
@@ -117,7 +117,14 @@
117
117
  <use href="#icon-offer-{{course.offer|default:'free'}}" />
118
118
  </svg>
119
119
  {% if course.offer != 'free' and course.price %}
120
- <span class="offer__price">{{ course.price|currency:course.price_currency }}</span>
120
+ {% if course.discounted_price %}
121
+ <div class="offer_prices">
122
+ <span class="offer__price offer__price--striked">{{ course.price|currency:course.price_currency }}</span>
123
+ <span class="offer__price offer__price--discounted">{{ course.discounted_price|currency:course.price_currency }}</span>
124
+ </div>
125
+ {% else %}
126
+ <span class="offer__price">{{ course.price|currency:course.price_currency }}</span>
127
+ {% endif %}
121
128
  {% endif %}
122
129
  </div>
123
130
  </div>
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: richie
3
- Version: 3.1.3.dev30
3
+ Version: 3.1.3.dev31
4
4
  Summary: A CMS to build learning portals for open education
5
5
  Author-email: "Open FUN (France Université Numérique)" <fun.dev@fun-mooc.fr>
6
6
  License: MIT License
@@ -1012,7 +1012,7 @@ richie/apps/courses/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5
1012
1012
  richie/apps/courses/models/__init__.py,sha256=TKx_JE0qeWMcDmHjk_NfDb_8CKIxXPgxMHzD7k6IMeA,323
1013
1013
  richie/apps/courses/models/blog.py,sha256=q7AHQDYWB2uHeoGJ1nePKjZoPWeLg2bPSrmhudAupcc,3450
1014
1014
  richie/apps/courses/models/category.py,sha256=OIqqvGOwQlgE7oI6sUPNBD4X6iRNjd7yfXtoGnxh7fI,7356
1015
- richie/apps/courses/models/course.py,sha256=1UdZMjZdTkAZ2IcTrVQ6Z3HJQh1w1XwVbqvQLw7O7Xc,47885
1015
+ richie/apps/courses/models/course.py,sha256=IPmQUPHn_hJDEs2SwjNiayxXungKfZExXPwnYrI_0NM,48435
1016
1016
  richie/apps/courses/models/menuentry.py,sha256=ABF8wEhyZ9T45YXhBCUDcK7Up8N5HZ9XB8R824EUSoI,1393
1017
1017
  richie/apps/courses/models/organization.py,sha256=slRhrk_LBE4sMF3LQ9tuzbKmPnDhXaas7YvUsFWE5qU,8715
1018
1018
  richie/apps/courses/models/person.py,sha256=tjKShF35iQlsESODWFDwMs22a7-Lyawzz6xBs5u5nGQ,2996
@@ -1029,7 +1029,7 @@ richie/apps/courses/templates/courses/cms/category_list.html,sha256=j7kAF1q8Kf6_
1029
1029
  richie/apps/courses/templates/courses/cms/course_detail.html,sha256=zlBaepOI4A7GNxaAHSyl0yHG8Q6mL2u05WVHDUCZc-U,32448
1030
1030
  richie/apps/courses/templates/courses/cms/fragment_blogpost_glimpse.html,sha256=dft1drWDvUJxWaG-20OYUeCLs8SyEZfspEsO3utbr2k,7876
1031
1031
  richie/apps/courses/templates/courses/cms/fragment_category_glimpse.html,sha256=yiGr9RS4u-Rp1TCAQ1jsZe0aZir4NJZHw8gTM5x3CrI,4659
1032
- richie/apps/courses/templates/courses/cms/fragment_course_glimpse.html,sha256=NIla-vW6WctxTM7cRFlqSFh7-Qtuj9fDoRToCpHUbyQ,8663
1032
+ richie/apps/courses/templates/courses/cms/fragment_course_glimpse.html,sha256=pY5OBPlgPyJ9AZBwneEvAZA9MlpcUeJMhNG40XNXRqc,9147
1033
1033
  richie/apps/courses/templates/courses/cms/fragment_course_products.html,sha256=LNCvZJaHfqBvUuO3CuEsHOgNs_Ae_TkwiiHbUNLtoJU,324
1034
1034
  richie/apps/courses/templates/courses/cms/fragment_course_relations.html,sha256=dIvJLlRgKgzPoSb-MxsFw_-gB8OmTjKn9D6m6uiYJP4,2840
1035
1035
  richie/apps/courses/templates/courses/cms/fragment_error_detail_template_banner.html,sha256=C9saCP2CJWK_dLVlHVmWt_ntdstlAKYWIKiLVHAvqeY,529
@@ -2486,9 +2486,9 @@ richie/static/richie/js/build/99870.34581ce2cb1783eaefab.index.js,sha256=3ZdjUuB
2486
2486
  richie/static/richie/js/build/99895.34581ce2cb1783eaefab.index.js,sha256=ST2kyTdc0fVK0IxNmItIgs6dnds7DVRwC7dzbHjG4CA,2570
2487
2487
  richie/static/richie/js/build/99953.34581ce2cb1783eaefab.index.js,sha256=OWoLPJnHrmvF3HBQPgXooAGo5E0yJpJ7QTFHFghJpI8,135
2488
2488
  richie/static/richie/js/build/index.js,sha256=_nRO5lntGWFWNEzWezxPzwzFeWW1VHCeOXPNe6sxu5w,1332732
2489
- richie-3.1.3.dev30.dist-info/licenses/LICENSE,sha256=5LKjFIE1kpKzBfR2iwq_RGHhHM5XawdlfZrcHTsCLpA,1079
2490
- richie-3.1.3.dev30.dist-info/METADATA,sha256=9MEKLcbs1rVIrd8LNnjctyu_Qi2hQn5n6hS20kIO9IY,7034
2491
- richie-3.1.3.dev30.dist-info/WHEEL,sha256=JNWh1Fm1UdwIQV075glCn4MVuCRs0sotJIq-J6rbxCU,109
2492
- richie-3.1.3.dev30.dist-info/top_level.txt,sha256=WJvFAAHtUQ5T5MOuG6jRynDJG9kVfl4jtuf1qxIXND8,16
2493
- richie-3.1.3.dev30.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
2494
- richie-3.1.3.dev30.dist-info/RECORD,,
2489
+ richie-3.1.3.dev31.dist-info/licenses/LICENSE,sha256=5LKjFIE1kpKzBfR2iwq_RGHhHM5XawdlfZrcHTsCLpA,1079
2490
+ richie-3.1.3.dev31.dist-info/METADATA,sha256=DleT72tkl12CarENmd42r9-nXlteefyiCnCogDMF4Aw,7034
2491
+ richie-3.1.3.dev31.dist-info/WHEEL,sha256=JNWh1Fm1UdwIQV075glCn4MVuCRs0sotJIq-J6rbxCU,109
2492
+ richie-3.1.3.dev31.dist-info/top_level.txt,sha256=WJvFAAHtUQ5T5MOuG6jRynDJG9kVfl4jtuf1qxIXND8,16
2493
+ richie-3.1.3.dev31.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
2494
+ richie-3.1.3.dev31.dist-info/RECORD,,