Skip to content

Commit

Permalink
CFM-274_Breadcrumb_Component_External_Identity_Source_Record (#207)
Browse files Browse the repository at this point in the history
* Fix the parent breadcrumb of an External Identity Source Record

* View ExternalIdentitySourceRecord render in Modal

* Refactor/Simplify Primary Link Calculation

* Transmogrification sql typo.External identity Source link fix

* Fix Configurtion Breadcrumb for isConfigurationTables

* Fix ExternalIdentitySource alert link to open in modal. Fixed modal links to open on target _top

* fix typo

* Change inherited class from MVEAController to StandardController
  • Loading branch information
Ioannis authored Sep 10, 2024
1 parent d541e2d commit 573c009
Show file tree
Hide file tree
Showing 13 changed files with 308 additions and 204 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -449,9 +449,11 @@ public function search(
while(($data = fgetcsv($handle)) !== false) {
// strtolower, previous behavior was full string only so dupe that

$match = array_search(strtolower($searchAttrs['q']), array_map('strtolower', $data));
$match = collection($data)
->map(fn($value, $key) => strtolower($value ?? ''))
->filter(fn($item, $key) => strtolower($searchAttrs['q']) === $item);

if($match !== false) {
if($match->count() > 0) {
// $match will be the CSV column that matched, but for now we ignore that
// since we just need to know that the row matched somewhere. Note the first
// column is always the SORID.
Expand Down
7 changes: 5 additions & 2 deletions app/resources/locales/en_US/information.po
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,10 @@ msgid "ExternalIdentitySources.records"
msgstr "Source Records"

msgid "ExternalIdentitySources.retrieve"
msgstr "This is the current record retrieved directly from the source. <a href="{0}">View the latest record cached by Registry</a>."
msgstr "This is the current record retrieved directly from the source. {0}"

msgid "ExternalIdentitySources.cached"
msgstr "View the latest record cached by Registry"

msgid "ExternalIdentitySources.retrieve.notSynced"
msgstr "This is the current record available directly from the source."
Expand All @@ -70,7 +73,7 @@ msgid "ExternalIdentitySourceRecords.metadata"
msgstr "Metadata"

msgid "ExternalIdentitySourceRecords.view"
msgstr "This is the latest record from the source as cached by Registry. <a href="{0}">Retrieve the current record directly from the source</a>."
msgstr "This is the latest record from the source as cached by Registry. <a href="{0}" target="_top">Retrieve the current record directly from the source</a>."

msgid "ExternalIdentitySources.search.attrs.none"
msgstr "The External Identity Source cannot be searched."
Expand Down
4 changes: 2 additions & 2 deletions app/src/Command/TransmogrifyCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -1308,8 +1308,8 @@ protected function roleSqlSelect(string $tableName): string {
manager_co_person_id,
cou_id,
CASE
WHEN affiliation IS NULL THEN "member"
WHEN affiliation = "" THEN "member"
WHEN affiliation IS NULL THEN 'member'
WHEN affiliation = '' THEN 'member'
ELSE affiliation
END as affiliation,
title,
Expand Down
Loading

0 comments on commit 573c009

Please sign in to comment.