~openerp/openobject-server/5.0

« back to all changes in this revision

Viewing changes to bin/addons/base/ir/ir_cron.py

  • Committer: Don Kirkby
  • Date: 2010-11-18 23:23:14 UTC
  • mto: This revision was merged to the branch mainline in revision 2168.
  • Revision ID: donkirkby+launpd@gmail.com-20101118232314-2cx8fo9tr4q2se21
[FIX] Schedule jobs even if their next time has passed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
123
123
                    cr.commit()
124
124
 
125
125
 
126
 
            cr.execute('select min(nextcall) as min_next_call from ir_cron where numbercall<>0 and active and nextcall>=now()')
 
126
            cr.execute('select min(nextcall) as min_next_call from ir_cron where numbercall<>0 and active')
127
127
            next_call = cr.dictfetchone()['min_next_call']
128
128
            if next_call:
129
129
                next_call = time.mktime(time.strptime(next_call, '%Y-%m-%d %H:%M:%S'))