# use the first move ever created for this journal and period
725
cr.execute('select id, state, name from account_move where journal_id=%s and period_id=%s order by id limit 1', (context['journal_id'],context['period_id']))
result = super(account_move_line, self).write(cr, uid, ids, vals, context)
752
782
753
783
if check:
813
843
is_new_move = False
814
844
if not move_id:
815
845
if journal.centralisation:
816
# use the first move ever created for this journal and period
817
cr.execute('select id, state, name from account_move where journal_id=%s and period_id=%s order by id limit 1', (context['journal_id'],context['period_id']))