Skip to content

Commit

Permalink
Merge pull request #4295 from sul-dlss/1348-symphonyisms
Browse files Browse the repository at this point in the history
Stop using home_location and current_location.
  • Loading branch information
jcoyne committed Jul 5, 2024
2 parents 2d297ab + d469b22 commit 726f82f
Show file tree
Hide file tree
Showing 17 changed files with 36 additions and 1,488 deletions.
2 changes: 1 addition & 1 deletion lib/holdings/item.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def library
# the temporary location if the location detail searchworksTreatTemporaryLocationAsPermanentLocation
# is set to true.
def effective_permanent_location_code
item_display[:effective_permanent_location_code] || item_display[:home_location]
item_display[:effective_permanent_location_code]
end

# NOTE: This may be nil
Expand Down
18 changes: 9 additions & 9 deletions spec/components/librarian/item_details/table_component_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"id" => "502863a5-b53c-58cf-9305-03846673ef14",
"barcode" => "36105223688552",
"library" => "EARTH-SCI",
"home_location" => "EAR-STACKS",
"effective_permanent_location_code" => "EAR-STACKS",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -34,7 +34,7 @@
"id" => "9773449d-90d7-5108-b73d-c532e69de8cd",
"barcode" => "36105226059181",
"library" => "EARTH-SCI",
"home_location" => "EAR-STACKS",
"effective_permanent_location_code" => "EAR-STACKS",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -56,7 +56,7 @@
"id" => "99c01199-b248-58a7-a452-d7219c2cb817",
"barcode" => "36105225598411",
"library" => "RUMSEY-MAP",
"home_location" => "RUM-W7-STK-REF",
"effective_permanent_location_code" => "RUM-W7-STK-REF",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -78,7 +78,7 @@
"id" => "ad35d1a4-067e-522d-99e4-5be7b1358668",
"barcode" => "36105218665789",
"library" => "GREEN",
"home_location" => "GRE-STACKS",
"effective_permanent_location_code" => "GRE-STACKS",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -100,7 +100,7 @@
"id" => "be2de21c-e500-5334-862a-e22fcc9d2776",
"barcode" => "36105226157456",
"library" => "RUMSEY-MAP",
"home_location" => "RUM-W7-STK-REF",
"effective_permanent_location_code" => "RUM-W7-STK-REF",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -122,7 +122,7 @@
"id" => "db5de9be-8e47-540a-b9ce-1f0940e21169",
"barcode" => "36105226146277",
"library" => "EARTH-SCI",
"home_location" => "EAR-STACKS",
"effective_permanent_location_code" => "EAR-STACKS",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -144,7 +144,7 @@
"id" => "dda764bf-b634-5253-a1b8-00abdc7cd60a",
"barcode" => "36105225598403",
"library" => "RUMSEY-MAP",
"home_location" => "RUM-W7-STK-REF",
"effective_permanent_location_code" => "RUM-W7-STK-REF",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -166,7 +166,7 @@
"id" => "df0d7b8b-23f8-50a5-97d0-d6ed95173eac",
"barcode" => "36105225598080",
"library" => "RUMSEY-MAP",
"home_location" => "RUM-W7-STK-REF",
"effective_permanent_location_code" => "RUM-W7-STK-REF",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand All @@ -188,7 +188,7 @@
"id" => "e4cdaaa5-9ed2-57b3-aede-ba9f69aa9f23",
"barcode" => "36105005105536",
"library" => "GREEN",
"home_location" => "GRE-STACKS",
"effective_permanent_location_code" => "GRE-STACKS",
"type" => "book",
"note" => nil,
"instance_id" => "3e6a2511-5b6b-5c2e-aa91-57cd3c6f3392",
Expand Down
2 changes: 1 addition & 1 deletion spec/fixtures/solr_documents/1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ item_display_struct:
- id: a
barcode: '36105217238315'
library: EARTH-SCI
home_location: EAR-STACKS
effective_permanent_location_code: EAR-STACKS
type: STKS
lopped_callnumber: G70.212 .A426 2011:test
callnumber: G70.212 .A426 2011:test
Expand Down
18 changes: 9 additions & 9 deletions spec/fixtures/solr_documents/10.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,55 +19,55 @@ item_display_struct:
instance_id: 19eba0e5-8bab-55f9-b799-092737ca0c86
barcode: "123"
library: GREEN
home_location: GRE-STACKS
effective_permanent_location_code: GRE-STACKS
callnumber: HF1604 .G368 2024
full_shelfkey: ABC
- id: e3cf1a84-4cf6-49c9-87cc-d53afe6b4ead
barcode: "456"
library: ENG
home_location: ENG-STACKS
effective_permanent_location_code: ENG-STACKS
callnumber: DEF
full_shelfkey: DEF
- id: c10082be-e7d8-4a52-899c-e67b864eceab
barcode: "123"
library: ENG
home_location: ENG-STACKS
effective_permanent_location_code: ENG-STACKS
callnumber: GHI
full_shelfkey: GHI
- id: 1e93dcf5-9aa8-441b-9ec8-a769c2ae5035
barcode: "321"
library: ENG
home_location: ENG-STACKS
effective_permanent_location_code: ENG-STACKS
callnumber: CBA
full_shelfkey: CBA
- id: 71adbdae-5e3a-4f2d-86c3-42ca019fae9c
barcode: "654"
library: ENG
home_location: ENG-STACKS
effective_permanent_location_code: ENG-STACKS
callnumber: FED
full_shelfkey: FED
- id: b9fd7d43-e160-4a99-b513-b0d9fd1f90cf
barcode: "876"
library: ENG
home_location: ENG-STACKS
effective_permanent_location_code: ENG-STACKS
callnumber: IHG
full_shelfkey: IHG
- id: a9c6236e-bd02-484c-ae0c-b13b32ce6ff9
barcode: "678"
library: EARTH-SCI
home_location: EAR-STACKS
effective_permanent_location_code: EAR-STACKS
callnumber: JKL
full_shelfkey: JKL
- id: f1618f71-71e5-4e7a-bbd0-8398038c1f97
barcode: "123"
library: ENG
home_location: ENG-STACKS
effective_permanent_location_code: ENG-STACKS
callnumber: MNO
full_shelfkey: MNO
- id: 9bfbc4ae-8724-4d84-aadb-181011fae1fb
barcode: "543"
library: MARINE-BIO
home_location: MAR-STACKS
effective_permanent_location_code: MAR-STACKS
callnumber: PQR
full_shelfkey: PQR
folio_json_struct:
Expand Down
3 changes: 1 addition & 2 deletions spec/fixtures/solr_documents/2279186.yml
Original file line number Diff line number Diff line change
Expand Up @@ -353,8 +353,7 @@ item_display_struct:
- id: f947bd93-a1eb-5613-8745-1063f948c461
barcode: '36105026515499'
library: SAL3
home_location: SAL3-STACKS
current_location:
effective_permanent_location_code: SAL3-STACKS
type:
note:
instance_id: 9bf55756-7e18-52d8-81a6-84a62353e512
Expand Down
Loading

0 comments on commit 726f82f

Please sign in to comment.