Remove pd checkbox from terms page
This commit is contained in:
parent
9254f0c2be
commit
41a1867043
4 changed files with 2 additions and 17 deletions
|
@ -34,7 +34,6 @@ module Accounts
|
|||
flash[:notice] = { :partial => "accounts/terms/terms_declined_flash" } if current_user.save
|
||||
else
|
||||
unless current_user.terms_agreed?
|
||||
current_user.consider_pd = params[:user][:consider_pd]
|
||||
current_user.tou_agreed = Time.now.utc
|
||||
current_user.terms_agreed = Time.now.utc
|
||||
current_user.terms_seen = true
|
||||
|
|
|
@ -72,13 +72,4 @@
|
|||
<%= submit_tag(t(".continue"), :name => "continue", :id => "continue", :disabled => true, :class => "btn btn-primary") %>
|
||||
<%= submit_tag(t(".cancel"), :name => "decline", :id => "decline", :class => "btn btn-outline-secondary") %>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<div class="form-check">
|
||||
<%= check_box("user", "consider_pd", :class => "form-check-input") %>
|
||||
<label for="user_consider_pd" class="form-check-label">
|
||||
<%= t ".consider_pd" %>
|
||||
</label>
|
||||
<span class="minorNote">(<%= link_to(t(".consider_pd_why"), t(".consider_pd_why_url"), :target => :new) %>)</span>
|
||||
</div>
|
||||
<% end %>
|
||||
|
|
|
@ -306,9 +306,6 @@ en:
|
|||
read_ct: "I have read and agree to the above contributor terms"
|
||||
tou_explain_html: "These %{tou_link} govern the use of the website and other infrastructure provided by the OSMF. Please click on the link, read and agree to the text."
|
||||
read_tou: "I have read and agree to the Terms of Use"
|
||||
consider_pd: "In addition to the above, I consider my contributions to be in the Public Domain"
|
||||
consider_pd_why: "what's this?"
|
||||
consider_pd_why_url: https://osmfoundation.org/wiki/Licence_and_Legal_FAQ/Why_would_I_want_my_contributions_to_be_public_domain
|
||||
guidance_info_html: "Information to help understand these terms: a %{readable_summary_link} and some %{informal_translations_link}"
|
||||
readable_summary: human readable summary
|
||||
informal_translations: informal translations
|
||||
|
|
|
@ -52,13 +52,12 @@ module Accounts
|
|||
user = create(:user, :terms_seen => false, :terms_agreed => nil)
|
||||
session_for(user)
|
||||
|
||||
put account_terms_path, :params => { :user => { :consider_pd => true }, :read_ct => 1, :read_tou => 1 }
|
||||
put account_terms_path, :params => { :read_ct => 1, :read_tou => 1 }
|
||||
assert_redirected_to edit_account_path
|
||||
assert_equal "Thanks for accepting the new contributor terms!", flash[:notice]
|
||||
|
||||
user.reload
|
||||
|
||||
assert user.consider_pd
|
||||
assert_not_nil user.terms_agreed
|
||||
assert user.terms_seen
|
||||
end
|
||||
|
@ -67,13 +66,12 @@ module Accounts
|
|||
user = create(:user, :terms_seen => false, :terms_agreed => nil)
|
||||
session_for(user)
|
||||
|
||||
put account_terms_path, :params => { :user => { :consider_pd => true }, :referer => "/test", :read_ct => 1, :read_tou => 1 }
|
||||
put account_terms_path, :params => { :referer => "/test", :read_ct => 1, :read_tou => 1 }
|
||||
assert_redirected_to "/test"
|
||||
assert_equal "Thanks for accepting the new contributor terms!", flash[:notice]
|
||||
|
||||
user.reload
|
||||
|
||||
assert user.consider_pd
|
||||
assert_not_nil user.terms_agreed
|
||||
assert user.terms_seen
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue