diff --git a/kfet/templates/kfet/home.html b/kfet/templates/kfet/home.html index 7368d91d..fb1e78b7 100644 --- a/kfet/templates/kfet/home.html +++ b/kfet/templates/kfet/home.html @@ -8,165 +8,10 @@
-
-
-
Trucs
-
à dire
-
- -
{% include 'kfet/base_messages.html' %} -
-
-

Liste des trucs

-
-
-
-

Répartition des câlins

- -
-
-
-
-

Répartition des câlins

- -
-
-
-
-

Répartition des câlins

- -
-
-
-
-
{% endblock %} - -{% block extra_head %} - - -{% endblock %} diff --git a/kfet/views.py b/kfet/views.py index b5b4d276..e2cb7a26 100644 --- a/kfet/views.py +++ b/kfet/views.py @@ -2534,51 +2534,3 @@ class ArticleStatLastMonth(ArticleStatLast): def get_labels(self, **kwargs): months = lastmonths(7) return monthnames(months) - -# ------------------------------ -# Article Statistique Catégories -# ------------------------------ - - -class DurationStat(HybridListView): - lookup_duration_type = 'day' # 'day' || 'week' || 'month' - lookup_duration_number = 3 # ie ici : 3 jours - - def get_end_date(self, **kwargs): - if self.lookup_duration_type == 'day': - return this_morning() - elif self.lookup_duration_type == 'week': - return this_monday_morning() - elif self.lookup_duration_type == 'month': - return this_first_month_day() - else: - raise ValueError('duration_type invalid') - - def get_begining_date(self, **kwargs): - end_date = self.get_end_date(self, **kwargs) - if self.lookup_duration_type == 'day': - days = self.lookup_nb_duration - elif self.lookup_duration_type == 'week': - days = 7*self.lookup_nb_duration - elif self.lookup_duration_type == 'month': - days = 30*self.lookup_nb_duration - else: - raise ValueError('this should not be happening.') - delta = timezone.timedelta(days=days) - return end_date - delta - - @method_decorator(login_required) - def dispatch(self, *args, **kwargs): - return super(DurationStat, self).dispatch(*args, **kwargs) - - -# TODO -# class CategoryDurationStat(DurationStat): -# model = ArticleCategory -# template_name = 'kfet/category_stat.html' -# -# def get_context_data(self, **kwargs): -# context = {} -# queryset = kwargs.pop('object_list', self.object_list) -# -# return context