Class: Agents::UpdateSpecialRequest
- Defined in:
- app/my_lib/agents/update_special_request.rb
Constant Summary
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
#audit_comment, #errors, #executor, #force_update, #owner, #reservation, #reservation_params, #restaurant, #user, #vendor_booking_id
Instance Method Summary collapse
Methods inherited from Update
#after_initialize, #initialize, #update_booking, #update_booking!
Methods included from ErrorType
#fatal_error?, #inventory_error?, #normal_error?, #overwrite_error_type!
Methods inherited from Base
#error_message, #hotline, #inventory_available?, #save_reservation!, #status=
Methods included from SharedJobs
#give_campaign_reward, #send_rating_email
Constructor Details
This class inherits a constructor from Agents::Update
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Agents::Base
Instance Method Details
#execute ⇒ Object
14 15 16 17 18 19 |
# File 'app/my_lib/agents/update_special_request.rb', line 14 def execute execute! rescue InvalidReservation, ActiveRecord::ActiveRecordError => e APMErrorHandler.report e false end |
#execute! ⇒ Object
6 7 8 9 10 11 12 |
# File 'app/my_lib/agents/update_special_request.rb', line 6 def execute! save_reservation! :sneaky @reservation.touch @reservation.run_callbacks :update # Just update the data on database, so workers can reload data and send the newest data true end |