-
Notifications
You must be signed in to change notification settings - Fork 18
Conversation
The new template-tag gets all the tags associated to talks proposed to the current conference. The template tag leverages a new `detaches` function (committed as well), that demands all the computations and db hits to the `conference.dataaccess.tags_for_talks` function.
Now the voting.html template (used in `conference.views.voting` callback) includes only the set of tags associated to talks of the current conference (thanks to the new `p3_tags_for_talks` template tag). The template has been changed trying to not break backward compatibilities with other templates extending "base.html". To this end, the "base.html" template now wraps the invocation to `p3_tags` and `conference_js_data` tags in a new block that is overridden by the `voting.html` template. Finally, the CSS style for tags has been modified as well in order to allow for a better usability of tags filter.
This filter is used in the voting page. The setting is queried by the conference app (see `conference.settings) (A new PR on `conference` will follow)
A fix that I forgot to commit and push
@@ -265,3 +270,27 @@ def tags(): | |||
tags = cache_me( | |||
signals=(cdata.tags.invalidated,), | |||
models=(models.P3Profile, cmodels.AttendeeProfile))(tags) | |||
|
|||
def tags_for_proposed_talks(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ottimo, però io chiamerei la funzione tags_for_conference_talks e non mi limiterei ai talk "proposed".
Una funzione che restituisce tutti i tag usati in una conferenza la vedo più utile di una che lavora solo su i talk proposti (in questo caso potremmo usarla solo durante il voting).
Aggiungerei due parametri, il codice della conferenza (obbligatorio, ci penserà il template tag a fornire come default la conferenza attuale) e lo stato dei talk (default None, che significa tutti)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fatto! 👍
Purtroppo ai modificato direttamente il file .css invece che i file sass e così le tue modifiche andranno perse alla prossima modifica. Se non sai mettere le mani sui file scss ci penso io |
Now the CfP link in home appears only if the cfp is actually opened.
Per Saas pensaci tu! Penso di aver capito dove e come intervenire, ma non voglio fare macelli :) |
Creato nuovo template tag per filtrare i tag associati ai talks della conferenza (i dettagli sono tutti nei commenti dei commit).
Migliorato (IMHO :D ) css style per tags, in modo da renderli più usabili e meno ingombranti.
Nuovo opzione di settings per il filtro sul tipo di talk (utilizzato in
conference.settings
econference.views.voting
) - segue PR suconference
.Fixed url per talk update (avevo dimenticato di pusharlo nell'ultima PR... sorry :( )