Class: Ci::PipelineSchedules::UpdateService
- Inherits:
-
BaseSaveService
- Object
- BaseSaveService
- Ci::PipelineSchedules::UpdateService
- Defined in:
- app/services/ci/pipeline_schedules/update_service.rb
Constant Summary collapse
- AUTHORIZE =
:update_pipeline_schedule
Constants inherited from BaseSaveService
BaseSaveService::INVALID_REF_MESSAGE, BaseSaveService::INVALID_REF_MODEL_MESSAGE
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(schedule, user, params) ⇒ UpdateService
constructor
A new instance of UpdateService.
Constructor Details
#initialize(schedule, user, params) ⇒ UpdateService
Returns a new instance of UpdateService.
8 9 10 11 12 13 |
# File 'app/services/ci/pipeline_schedules/update_service.rb', line 8 def initialize(schedule, user, params) @schedule = schedule @user = user @project = schedule.project @params = params end |
Instance Method Details
#execute ⇒ Object
15 16 17 18 19 20 21 |
# File 'app/services/ci/pipeline_schedules/update_service.rb', line 15 def execute return forbidden_to_save unless allowed_to_save? prepare_inputs_for_update super end |