We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
如題,我想寫一個房仲網站,例如有房屋和土地兩種項目,這個檔案在 app/views/items/_form.html.erb
<%= f.select :kind, [['房屋',0],['土地',1]], include_blank: true, label: '項目' %> <%= f.select :category, [['大廈',0],['透天',1],['公寓',2],['建地',3'],['農地',4],['工業地',5]], label: '分類' %>
當『新增』物件時,我希望選完項目後,若選擇『房屋』時可以只出現房屋的分類 (例:大廈、透天、公寓),選『土地』時可以只出現土地的分類(例:建地、農地、工業地)。
請問該如何修改?是否一定要搭配 jQuery 的 append?
The text was updated successfully, but these errors were encountered:
我希望選完項目後
有這個動作就一定要搭配 Javascript 來做了 ,除非你要帶參數給後端讓他重新宣染整個頁面。
Sorry, something went wrong.
收到,謝謝 ^_^
No branches or pull requests
如題,我想寫一個房仲網站,例如有房屋和土地兩種項目,這個檔案在 app/views/items/_form.html.erb
當『新增』物件時,我希望選完項目後,若選擇『房屋』時可以只出現房屋的分類 (例:大廈、透天、公寓),選『土地』時可以只出現土地的分類(例:建地、農地、工業地)。
請問該如何修改?是否一定要搭配 jQuery 的 append?
The text was updated successfully, but these errors were encountered: