replace deprecated update_attributes with update
This commit is contained in:
parent
eb45a2bf21
commit
3ffdb424d5
28 changed files with 52 additions and 53 deletions
|
|
@ -51,7 +51,7 @@ class Finance::BalancingController < Finance::BaseController
|
|||
|
||||
def update_note
|
||||
@order = Order.find(params[:id])
|
||||
if @order.update_attributes(params[:order])
|
||||
if @order.update(params[:order])
|
||||
render :layout => false
|
||||
else
|
||||
render :action => :edit_note, :layout => false
|
||||
|
|
@ -65,7 +65,7 @@ class Finance::BalancingController < Finance::BaseController
|
|||
|
||||
def update_transport
|
||||
@order = Order.find(params[:id])
|
||||
@order.update_attributes! params[:order]
|
||||
@order.update!(params[:order])
|
||||
redirect_to new_finance_order_path(order_id: @order.id)
|
||||
rescue => error
|
||||
redirect_to new_finance_order_path(order_id: @order.id), alert: t('errors.general_msg', msg: error.message)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue