Class: HubriseApp::Services::AssignAppInstance

Inherits:
Object
  • Object
show all
Defined in:
app/lib/hubrise_app/services/assign_app_instance.rb

Class Method Summary collapse

Class Method Details

.run(hr_user, hr_app_instance, _ctx) ⇒ Object



5
6
7
8
9
10
# File 'app/lib/hubrise_app/services/assign_app_instance.rb', line 5

def self.run(hr_user, hr_app_instance, _ctx)
  UserAppInstance.find_or_initialize_by(
    hr_app_instance_id: hr_app_instance.hr_id,
    hr_user_id: hr_user.hr_id
  ).update!(refreshed_at: Time.now)
end