blob: fc4ab3cf56f8a636a093dfa7249d8b231e7eb87f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
class LineReferentialsController < BreadcrumbController
defaults :resource_class => LineReferential
def sync
@sync = resource.line_referential_syncs.build
if @sync.save
flash[:notice] = t('notice.line_referential_sync.created')
else
flash[:error] = @sync.errors.full_messages.to_sentence
end
redirect_to resource
end
protected
def begin_of_chain
current_organisation
end
def line_referential_params
params.require(:line_referential).permit(:sync_interval)
end
end
|