finish widget
This commit is contained in:
1 parent
5ca7593a05
commit
b44b181fc7
22 files changed
+588
-101
No files matched your search
@@ -1,4 +1,5 @@
|
||||
class Admin::AskAcknowledgementsController < OrbitAdminController
|
||||
helper Admin::AsksHelper
|
||||
def initialize
|
||||
super
|
||||
@app_title = 'ask_acknowledgement'
|
||||
|
||||
@@ -14,7 +14,7 @@ class Admin::AsksController < OrbitAdminController
|
||||
|
||||
def filter_fields(categories, tags)
|
||||
{
|
||||
:situation=>[{:title=>"is_waiting",:id=>"is_waiting"},{:title=>"is_processed",:id=>"is_processed"},{:title=>"is_referral",:id=>"is_referral"}],
|
||||
:situation=>[{:title=>"ask.is_waiting",:id=>"is_waiting"},{:title=>"ask.is_processed",:id=>"is_processed"},{:title=>"ask.is_referral",:id=>"is_referral"},{:title=>"ask.is_published",:id=>"is_published"}],
|
||||
:category=>categories.map{|c| {:title=>(c.title.blank? ? " " : c.title), :id=>c.id}},
|
||||
:identity=>tags.map{|tag| {:title=>(tag.name.blank? ? " " : tag.name), :id=>tag.id}}
|
||||
}
|
||||
@@ -48,11 +48,13 @@ class Admin::AsksController < OrbitAdminController
|
||||
render :json => {key: ask_setting_index.key.to_i}
|
||||
end
|
||||
def index
|
||||
@ask_setting = AskSetting.first
|
||||
@ask_setting = AskSetting.create() if @ask_setting.nil?
|
||||
@tags = @module_app.tags
|
||||
@categories = @module_app.categories
|
||||
@filter_fields = filter_fields(@categories, @tags)
|
||||
# 列表欄位
|
||||
@table_fields = [:situation, :category, 'ask.name', 'ask.phone', 'ask.appointment']
|
||||
@table_fields = [:situation, :category, 'title' , 'ask.name', 'ask.phone', 'ask.appointment']
|
||||
# 列表排序
|
||||
# debugger
|
||||
if filter2("situation").blank? and filter2("identity").blank?
|
||||
|
||||
Reference in new issue
Block a user