Merge pull request #416 from foodcoop1040/invite_config

Add config option to disable the invites
This commit is contained in:
wvengen 2016-03-07 19:47:00 +01:00
commit d358278333
12 changed files with 25 additions and 11 deletions

View file

@ -2,5 +2,6 @@
= config_input form, :use_wiki, as: :boolean
= config_input form, :use_nick, as: :boolean
= config_input form, :tolerance_is_costly, as: :boolean
= config_input form, :disable_invite, as: :boolean
= config_input form, :help_url, as: :url, input_html: {class: 'input-xlarge'}
= config_input form, :webstats_tracking_code, as: :text, input_html: {class: 'input-xxlarge', rows: 3}

View file

@ -1,4 +1,4 @@
- unless @ordergroup.new_record?
- unless @ordergroup.new_record? || FoodsoftConfig[:disable_invite]
%p= t('.first_paragraph', url: link_to(t('.here'), new_invite_path(id: @ordergroup.id), remote: true)).html_safe
= simple_form_for [:admin, @ordergroup] do |f|
- captured = capture do

View file

@ -1,4 +1,5 @@
%p= t('.first_paragraph', url: link_to(t('.here'), new_invite_path(id: @workgroup.id), remote: true)).html_safe
- unless FoodsoftConfig[:disable_invite]
%p= t('.first_paragraph', url: link_to(t('.here'), new_invite_path(id: @workgroup.id), remote: true)).html_safe
= simple_form_for [:admin, @workgroup] do |f|
- captured = capture do
%h4= t 'admin.access_to'