forked from DGNum/gestioCOF
stupidness removed
This commit is contained in:
parent
cb9ba76a4f
commit
e0b0a53112
1 changed files with 6 additions and 6 deletions
|
@ -68,20 +68,20 @@ class Home(TemplateView):
|
|||
|
||||
|
||||
def KFET_OPEN():
|
||||
kfet_open_date = cache.get('KFET_OPEN_DATE')
|
||||
kfet_open = cache.get('KFET_OPEN')
|
||||
if not kfet_open_date:
|
||||
kfet_open_date = cache.get('KFET_OPEN_DATE', None)
|
||||
kfet_open = cache.get('KFET_OPEN', None)
|
||||
if kfet_open_date is None:
|
||||
kfet_open_date = timezone.now()
|
||||
cache.set('KFET_OPEN_DATE', kfet_open_date)
|
||||
if not kfet_open:
|
||||
if kfet_open is None:
|
||||
kfet_open = False
|
||||
cache.set('KFET_OPEN', kfet_open)
|
||||
return (kfet_open, kfet_open_date)
|
||||
|
||||
|
||||
def KFET_FORCE_CLOSE():
|
||||
kfet_force_close = cache.get('KFET_FORCE_CLOSE')
|
||||
if not kfet_force_close:
|
||||
kfet_force_close = cache.get('KFET_FORCE_CLOSE', None)
|
||||
if kfet_force_close is None:
|
||||
kfet_force_close = False
|
||||
cache.set('KFET_FORCE_CLOSE', kfet_force_close)
|
||||
return kfet_force_close
|
||||
|
|
Loading…
Reference in a new issue