Advertisement
Guest User

Untitled

a guest
Apr 26th, 2017
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. BikeLock.where("reported_at is not null").order(reported_at: :desc).each do |l|
  2. file << l.status << "," << l.lock_state << "," << l.plate_number << ","
  3. file << l.imei << "," << l.iccid << "," << l.sim_sid << ","
  4. file << l.reported_at << "," << l.lock_state_updated_at
  5. file << "\n"
  6. end
  7. file.close
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement