Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Accounting::Bookkeeping::OrderItemCreatedTransaction.all.each_with_index { |transaction, index| entry = transaction.bookkeeping_entries.find_by(credit_account_code: '8800'); next if entry.nil?; Accounting::Bookkeeping::EntryCountryTag.find_or_create_by(entry: entry, country: Accounting::Country.find_by(code: transaction.buyer_tax_country)); print '.'; sleep(30) if (index + 1) % 10000 == 0 }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement