diff --git a/app/controllers/admin/asks_controller.rb b/app/controllers/admin/asks_controller.rb index 4b2a932..5e95ee5 100644 --- a/app/controllers/admin/asks_controller.rb +++ b/app/controllers/admin/asks_controller.rb @@ -92,7 +92,7 @@ class Admin::AsksController < OrbitAdminController @categories = @module_app.categories @filter_fields = filter_fields(@categories, @tags) # 列表欄位 - @table_fields = [:situation, :category, 'title' , 'ask.name', 'ask.phone', 'ask.appointment'] + @table_fields = [:situation, :category, 'title' , 'ask.name', 'ask.phone', 'ask.appointment','ask.created_at'] # 列表排序 # debugger if filter2("situation").blank? and filter2("identity").blank? diff --git a/app/views/admin/asks/_ask_setting.html.erb b/app/views/admin/asks/_ask_setting.html.erb index 68b1da5..9c65fc4 100644 --- a/app/views/admin/asks/_ask_setting.html.erb +++ b/app/views/admin/asks/_ask_setting.html.erb @@ -133,7 +133,9 @@
<%= AskQuestion.human_attribute_name(:name) %>:<%= @ask_question.name %> | - -<%= AskQuestion.human_attribute_name(:mail) %>:<%= @ask_question.mail %> | -<%= AskQuestion.human_attribute_name(:phone) %>:<%= @ask_question.phone %> | - -||
<%= t('title') %>:<%= f.text_field :title %> | -||||
<%= AskQuestion.human_attribute_name(:appointment) %>:<%= @ask_question.appointment.strftime("%Y-%m-%d %H:%M") rescue nil %> | - -||||
<%= AskQuestion.human_attribute_name(:name) %>:<%= @ask_question.name %> | + +<%= AskQuestion.human_attribute_name(:mail) %>:<%= @ask_question.mail %> | +<%= AskQuestion.human_attribute_name(:phone) %>:<%= @ask_question.phone %> | + +||
<%= t('title') %>:<%= @ask_question.title %> | +||||
<%= AskQuestion.human_attribute_name(:appointment) %>:<%= @ask_question.appointment.strftime("%Y-%m-%d %H:%M") rescue nil %> | + +||||
- <%= f.label :reply %>
- <%= f.text_area :reply, rows: 10, style: 'width: 500px' %> - |
- ||||
- <%= f.label :comment %>
- <%= f.text_field :comment, style: 'width: 500px' %> |
- ||||
<%= f.label :agree_show %><%= f.select :agree_show,[[t('ask.no'),false],[t('ask.yes'),true]] %> | -||||
<%= f.label t('situation') %> <%= f.select :situation, [ - [t('ask.is_waiting'), 'is_waiting'], - [t('ask.is_processed'), 'is_processed'], - [t('ask.is_referral'), 'is_referral'], - [t('ask.is_published'),'is_published'] - ] %> | -||||
+ <%= f.label :reply %>
+ <%= f.text_area :reply, rows: 10, style: 'width: 500px' %> + |
+ ||||
+ <%= f.label :comment %>
+ <%= @ask_question.comment %> |
+ ||||
<%= f.label :agree_show %><%= @ask_question.agree_show ? t('ask.yes') : t('ask.no') %> + | +||||
<%= f.label t('situation') %> + <% tmp = {'is_waiting'=>t('ask.is_waiting'), + 'is_processed'=>t('ask.is_processed'), + 'is_referral'=>t('ask.is_referral'), + 'is_published'=>t('ask.is_published')} %> + <%= tmp[@ask_question.situation] %> + | +||||
- <%= f.label :send_email %><%= f.radio_button :send_email, 1, checked: @ask_question.send_email? %><%= t('ask.yes') %> - - <%= f.radio_button :send_email, 0, checked: !@ask_question.send_email? %><%= t('ask.no') %> - | -