blob: 39c2cdb892306904d4a29b6072e18fe267f7fa05 (
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 < ChouetteController
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
|