Dmitry Novikov 7 years ago
parent
commit
8a525bfd73
  1. 3
      periodic.py

3
periodic.py

@ -72,8 +72,7 @@ def main():
abon.ballance -= amount abon.ballance -= amount
ex.time_start = now ex.time_start = now
ex.deadline = None # Deadline sets automatically in signal pre_save ex.deadline = None # Deadline sets automatically in signal pre_save
ex.is_active = True
ex.save(update_fields=('time_start', 'deadline', 'is_active'))
ex.save(update_fields=('time_start', 'deadline'))
abon.save(update_fields=('ballance',)) abon.save(update_fields=('ballance',))
# make log about it # make log about it
l = AbonLog.objects.create( l = AbonLog.objects.create(

Loading…
Cancel
Save