-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rename "Library ID" to "University ID"
Connects to sul-dlss/SearchWorks#3773 This commit helps us move the access portfolio beyond using library barcode numbers, leaning instead on the university-assigned and -managed "university ID."
- Loading branch information
Showing
13 changed files
with
74 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,6 +38,9 @@ en: | |
time_tomorrow: 'Tomorrow at %-l:%M%P' | ||
hello: "Hello world" | ||
mylibrary: | ||
university_id: | ||
label: 'University ID' | ||
help_text: 'This is an 8- to 10-digit number that serves as a replacement for the Library ID that was previously utilized.' | ||
renew_item: | ||
success_html: <span class="font-weight-bold">Success!</span> "%{title}" was renewed. | ||
error_html: <span class="font-weight-bold">Sorry!</span> Something went wrong and "%{title}" was not renewed. | ||
|
@@ -64,7 +67,7 @@ en: | |
success_html: <span class="font-weight-bold">Success!</span> Your new PIN is ready to use. | ||
invalid_token_html: <span class="font-weight-bold">Sorry!</span> That reset PIN link is invalid or expired. Enter your library ID to request a new link. | ||
reset_pin: | ||
success_html: <span class="font-weight-bold">Check your email!</span> A PIN reset link has been sent to the address associated with library ID %{library_id} | ||
success_html: <span class="font-weight-bold">Check your email!</span> A PIN reset link has been sent to the address associated with %{university_id_label} %{university_id} | ||
request_failed_html: <span class="font-weight-bold">Sorry!</span> Something went wrong, possibly due to a connection failure. Try again or contact us for help. | ||
reset_pins_mailer: | ||
reset_pin: | ||
|
@@ -83,7 +86,7 @@ en: | |
request_failed_html: <span class="font-weight-bold">Sorry!</span> Something went wrong, possibly due to a connection failure. Please <a href="mailto:[email protected]">contact us</a> for help resolving your fines. | ||
payment_failed_html: <span class="font-weight-bold">Sorry!</span> Payment failed. Please <a href="mailto:[email protected]">contact us</a> for help resolving your fines. | ||
sessions: | ||
login_by_library_id: | ||
login_by_university_id: | ||
alert: Unable to authenticate. | ||
login_by_sunetid: | ||
error_html: <p class="h3">Unable to log in. Your SUNet ID is not linked to a library account.</p> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
require 'rails_helper' | ||
|
||
RSpec.describe ResetPinsController do | ||
let(:mock_client) { instance_double(FolioClient, find_patron_by_barcode: patron, ping: true) } | ||
let(:mock_client) { instance_double(FolioClient, find_patron_by_university_id: patron, ping: true) } | ||
let(:patron) do | ||
instance_double(Folio::Patron, display_name: 'Patron', barcode: 'PATRON', email: '[email protected]', | ||
pin_reset_token: 'abcdef') | ||
|
@@ -35,13 +35,15 @@ | |
context 'with unauthenticated requests' do | ||
describe '#reset' do | ||
it 'sends the reset pin email' do | ||
expect { post :reset, params: { library_id: '123456' } }.to change { ActionMailer::Base.deliveries.count }.by(1) | ||
expect { post :reset, params: { university_id: '123456789' } } | ||
.to change { ActionMailer::Base.deliveries.count } | ||
.by(1) | ||
end | ||
|
||
it 'sets flash messages' do | ||
post :reset, params: { library_id: '123456' } | ||
post :reset, params: { university_id: '123456789' } | ||
|
||
expect(flash[:success]).to match(/associated with library ID 123456/) | ||
expect(flash[:success]).to match(/associated with University ID 123456789/) | ||
end | ||
end | ||
end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
require 'rails_helper' | ||
|
||
RSpec.describe 'Reset Pin' do | ||
let(:mock_client) { instance_double(FolioClient, find_patron_by_barcode: patron, ping: true, change_pin: nil) } | ||
let(:mock_client) { instance_double(FolioClient, find_patron_by_university_id: patron, ping: true, change_pin: nil) } | ||
let(:patron) do | ||
instance_double(Folio::Patron, email: '[email protected]', display_name: 'J Doe', barcode: '123', | ||
pin_reset_token: 'foo') | ||
|
@@ -26,7 +26,7 @@ | |
|
||
it 'allows user to reset pin' do | ||
visit reset_pin_path | ||
fill_in('library_id', with: '123456') | ||
fill_in('university_id', with: '123456') | ||
click_on 'Reset/Request PIN' | ||
expect(page).to have_css '.flash_messages', text: 'Check your email!' | ||
end | ||
|