@@ -995,12 +995,12 @@ def title=(title)
995995 }
996996
997997 filter :search ,
998- verify : -> ( values , context ) {
998+ verify : -> ( values , context ) {
999999 values . all? { |v | ( v . is_a? ( Hash ) || v . is_a? ( ActionController ::Parameters ) ) } && values
1000- } ,
1001- apply : -> ( records , values , _options ) {
1002- records . where ( title : values . first [ 'title' ] )
1003- }
1000+ } ,
1001+ apply : -> ( records , values , _options ) {
1002+ records . where ( title : values . first [ 'title' ] )
1003+ }
10041004
10051005 def self . updatable_fields ( context )
10061006 super ( context ) - [ :author , :subject ]
@@ -1267,7 +1267,7 @@ def subject
12671267
12681268 def custom_links ( options )
12691269 {
1270- link_to_external_api : "http://external-api.com/posts/#{ created_at . year } /#{ created_at . month } /#{ created_at . day } -#{ subject . gsub ( ' ' , '-' ) } "
1270+ link_to_external_api : "http://external-api.com/posts/#{ created_at . year } /#{ created_at . month } /#{ created_at . day } -#{ subject . gsub ( ' ' , '-' ) } "
12711271 }
12721272 end
12731273end
@@ -1528,28 +1528,28 @@ class PurchaseOrderResource < JSONAPI::Resource
15281528
15291529 has_one :customer
15301530 has_many :line_items , relation_name : -> ( options = { } ) {
1531- context = options [ :context ]
1532- current_user = context ? context [ :current_user ] : nil
1533-
1534- unless current_user && current_user . book_admin
1535- :line_items
1536- else
1537- :admin_line_items
1538- end
1539- } ,
1531+ context = options [ :context ]
1532+ current_user = context ? context [ :current_user ] : nil
1533+
1534+ unless current_user && current_user . book_admin
1535+ :line_items
1536+ else
1537+ :admin_line_items
1538+ end
1539+ } ,
15401540 reflect : false
15411541
15421542 has_many :order_flags , acts_as_set : true ,
15431543 relation_name : -> ( options = { } ) {
1544- context = options [ :context ]
1545- current_user = context ? context [ :current_user ] : nil
1546-
1547- unless current_user && current_user . book_admin
1548- :order_flags
1549- else
1550- :admin_order_flags
1551- end
1552- }
1544+ context = options [ :context ]
1545+ current_user = context ? context [ :current_user ] : nil
1546+
1547+ unless current_user && current_user . book_admin
1548+ :order_flags
1549+ else
1550+ :admin_order_flags
1551+ end
1552+ }
15531553 end
15541554
15551555 class OrderFlagResource < JSONAPI ::Resource
0 commit comments