mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-05 22:26:07 +00:00
Ordering index orders within query
This commit is contained in:
@@ -32,7 +32,7 @@ Spree::Admin::OrdersController.class_eval do
|
||||
|
||||
respond_override index: { :json => { :success => lambda {
|
||||
search = OpenFoodNetwork::Permissions.new(spree_current_user).editable_orders.ransack(params[:q])
|
||||
render_as_json search.result.sort_by(&:id)
|
||||
render_as_json search.result.reorder('id ASC')
|
||||
} } }
|
||||
|
||||
# Overwrite to use confirm_email_for_customer instead of confirm_email.
|
||||
|
||||
Reference in New Issue
Block a user