| Field | Datatype |
|---|---|
| name | string |
| office_num | integer |
| phone_num | string |
| Field | Datatype |
|---|---|
| last_name | string |
| first_name | string |
| gender | string |
| phone_num | string |
| doctor_id | integer |
http://localhost:3000/doctors http://localhost:3000/patients
has_many :patientsAdd this line to the Patient model:
belongs_to :doctor
def directory @docs = Doctor.order(:name).all @women = Patient.where(gender: 'F').all @men = Patient.where(gender: 'M').all end
http://localhost:3000