title: Dynamically fill form fields according to value change of a dropdown before submitting form
body: <p>I am working on an order form of a RoR project and want to fill buyer info with existing customer info in database. So I need to select a customer name from a dropdown(select field) then fill in buyer info fields (name, phone, email, address like so) with selected customer's information.</p>
  
  <p>Therefore my question is, what's the preferred practise of doing this? My thought is something like an Ajax call with GET method to get json format data then use jQuery to fill in or change buyer info fields. Is it the correct "rails way" to achieve this function?</p>
  
  <p>BTW, the whole order form is simple_form, and buyer info fields are all in a simple_fields_for section. If this helps.</p>