Files
cmtool/app/views/cmtool/contact_forms/index.html.slim
T
bterkuile 4013070e4f feat: migrate from Foundation to Fomantic-UI
Swap foundation-rails for fomantic-ui-sass across the gem's own
layout/menu/alerts partials and all 11 generic scaffold resources
(pages, news, faqs, quotes, images, directories, keywords, yml_files,
contact_forms, newsletter_subscriptions, users). Foundation grid/button
classes replaced with Fomantic ui.form/ui.button/ui.table conventions;
legacy Foundation mixins in the custom component sass (panel, button,
grid-row/grid-column) rewritten as plain CSS since they no longer exist
once foundation_and_overrides.scss is gone.

Also fixes a real bug found along the way: boolean_text used
`.present?` on values, but SimplyCouch stores booleans as the strings
"0"/"1" — and "0".present? is true in Ruby, so it always rendered
"Yes" regardless of actual value. Now uses ActiveModel::Type::Boolean.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-07 23:36:35 -05:00

27 lines
881 B
Plaintext

- title :index, Cmtool::ContactForm
- if @contact_forms.any?
table.ui.celled.table
thead
tr
th= Cmtool::ContactForm.human_attribute_name(:gender)
th= Cmtool::ContactForm.human_attribute_name(:name)
th= Cmtool::ContactForm.human_attribute_name(:email)
th= Cmtool::ContactForm.human_attribute_name(:phone)
th
th
tbody
- @contact_forms.each do |contact_form|
tr
td= contact_form.gender
td= link_to contact_form.name, cmtool.contact_form_path(contact_form)
td= contact_form.email
td= contact_form.phone
= edit_td contact_form
= destroy_td contact_form
- else
= empty_result(Cmtool::ContactForm)
- content_for :page_links do
ul
li= link_to link_to_new_content(Cmtool::ContactForm), cmtool.new_contact_form_path, class: 'record-new-button'