want to choose a teacher, it only shows Teacher_@#$%^. What is Teacher_@#$%^? And how can I change them to teacher_names?
Pass it teacher.teacher_name (or teacher.name depends on what attribute of teacher stores teacher name)
in the controller?
Allright here you get tutorial link again https://guides.rubyonrails.org/form_helpers.html
label_method: :surname I added this, and now it shows surnames. Is it possible to show surnames and firstnames concatented? Or I have to add another column full_name?
В гайде написано как в селект передавать кастомные ключи+значения
Обсуждают сегодня