Correctifs sur les adhésions glissantes.
This commit is contained in:
parent
7f1ffbeed5
commit
50f91c63e0
4 changed files with 32 additions and 27 deletions
|
@ -97,20 +97,20 @@ def template(dialog=False):
|
|||
import jinja2
|
||||
oldstyle = style
|
||||
oldtableau = tableau
|
||||
tableau = lambda *args,**kwargs: oldtableau(*args,dialog=dialog,**kwargs)
|
||||
style = lambda *args,**kwargs:oldstyle(*args,dialog=dialog,**kwargs)
|
||||
newTableau = lambda *args,**kwargs: oldtableau(*args,dialog=dialog,**kwargs)
|
||||
newStyle = lambda *args,**kwargs:oldstyle(*args,dialog=dialog,**kwargs)
|
||||
template_path = '/usr/scripts/lc_ldap/printing/templates/'
|
||||
templateLoader = jinja2.FileSystemLoader( searchpath=["/", template_path] )
|
||||
templateEnv = jinja2.Environment( loader=templateLoader, trim_blocks=True )
|
||||
templateEnv.add_extension('jinja2.ext.do')
|
||||
templateEnv.filters['coul'] = style
|
||||
templateEnv.filters['coul'] = newStyle
|
||||
templateEnv.filters['blacklists'] = blacklists
|
||||
templateEnv.filters['prise_etat'] = prise_etat
|
||||
templateEnv.filters['timeformat'] = timeformat
|
||||
templateEnv.filters['split'] = split
|
||||
templateEnv.filters['telephone'] = telephone
|
||||
templateEnv.filters['const_of_mac'] = const_of_mac
|
||||
templateEnv.filters['tableau'] = tableau
|
||||
templateEnv.filters['tableau'] = newTableau
|
||||
return templateEnv
|
||||
|
||||
def machine(machine, params):
|
||||
|
@ -201,7 +201,7 @@ def proprio(proprio, params):
|
|||
params["cetud"] = cetud
|
||||
params['etat_administratif']=etat_administratif
|
||||
if proprio["chbre"][0].value not in ["????", "EXT"]:
|
||||
params['brassage'] = style("Cr@ns", "bleu") if gestion.annuaires_pg.is_crans(proprio["chbre"][0].value[0], proprio["chbre"][0].value[1:]) else style("CROUS", "jaune")
|
||||
params['brassage'] = style("Cr@ns", "bleu")# if gestion.annuaires_pg.is_crans(proprio["chbre"][0].value[0], proprio["chbre"][0].value[1:]) else style("CROUS", "jaune")
|
||||
|
||||
try:
|
||||
if proprio.machines():
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue