<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mv="http://macVmlSchemaUri" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Title" content="">
<meta name="Keywords" content="">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style id=owaParaStyle>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:DengXian;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:Calibri;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#0563C1;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:#954F72;
text-decoration:underline;}
p.msochpdefault, li.msochpdefault, div.msochpdefault
{mso-style-name:msochpdefault;
mso-margin-top-alt:auto;
margin-right:0in;
mso-margin-bottom-alt:auto;
margin-left:0in;
font-size:10.0pt;
font-family:"Times New Roman";}
span.emailstyle17
{mso-style-name:emailstyle17;
font-family:Calibri;
color:windowtext;}
span.emailstyle18
{mso-style-name:emailstyle18;
font-family:Calibri;
color:#1F497D;}
span.emailstyle20
{mso-style-name:emailstyle20;
font-family:Calibri;
color:#1F497D;}
span.EmailStyle21
{mso-style-type:personal-reply;
font-family:Calibri;
color:windowtext;}
span.msoIns
{mso-style-type:export-only;
mso-style-name:"";
text-decoration:underline;
color:teal;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style>
</head>
<body bgcolor="white" lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">Hi Kari-<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">An AO doesn’t have the resource id attached by default, so you have to add it to the SOLR document for the AO. I’m actually working on a similar plugin that does that and a couple of other things. In the meantime, if you take a look at
<a href="https://github.com/hudmol/component_levels">https://github.com/hudmol/component_levels</a> you can get an idea of how that process works.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Best,<o:p></o:p></p>
<p class="MsoNormal">Joshua<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="color:black">From: </span></b><span style="color:black"><archivesspace_users_group-bounces@lyralists.lyrasis.org> on behalf of Kari R Smith <smithkr@mit.edu><br>
<b>Reply-To: </b>Archivesspace Users Group <archivesspace_users_group@lyralists.lyrasis.org><br>
<b>Date: </b>Tuesday, September 13, 2016 at 10:34 AM<br>
<b>To: </b>Noah Huffman <noah.huffman@duke.edu><br>
<b>Cc: </b>"archivesspace_users_group@lyralists.lyrasis.org" <archivesspace_users_group@lyralists.lyrasis.org><br>
<b>Subject: </b>Re: [Archivesspace_Users_Group] Adding display fields for search results - How to?</span><span style="font-size:12.0pt;color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-family:"Times New Roman""><o:p> </o:p></span></p>
</div>
<div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">Noah, Steve and Eric -- thank you for your help. I've got the plug-in running and in search results I now have a column for "ID" ... however it only shows an ID for a Resource
result and not with any of the archival objects. In the Plug-in, I see this bit of code and am wondering how to have it also display the collection (resource) "identifier" for "archival object". Our reference staff would like to be able to sort / know to
which collection the archival objects belong without having to open each one to find that out.
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">My continued thanks! -Kari<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
</div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> <% @search_data['results'].each do |result| <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> deleted = (params.has_key?("deleted_uri") and Array(params["deleted_uri"]).include?(result["id"])) || false<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> # SET DISPLAY IDENTIFIER<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> @display_identifier = ""<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> @display_identifier = result["identifier"].html_safe if result["identifier"]<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> @display_identifier = result["digital_object_id"].html_safe if result["digital_object_id"]<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> @display_identifier = result["authority_id"].html_safe if result["authority_id"]<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> if result["primary_type"] == "archival_object"<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> json = JSON.parse(result["json"])<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> @display_identifier = json["component_id"].html_safe if json["component_id"]<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> end<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> %><o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"><o:p> </o:p></span></p>
<div>
<div class="MsoNormal" align="center" style="text-align:center"><span style="font-size:12.0pt;font-family:"Times New Roman";color:black">
<hr size="2" width="100%" align="center">
</span></div>
<div id="divRpF326670">
<p class="MsoNormal" style="margin-bottom:12.0pt"><b><span style="font-size:10.0pt;font-family:Tahoma;color:black">From:</span></b><span style="font-size:10.0pt;font-family:Tahoma;color:black"> Noah Huffman [noah.huffman@duke.edu]<br>
<b>Sent:</b> Tuesday, September 13, 2016 09:02<br>
<b>To:</b> Kari R Smith<br>
<b>Subject:</b> RE: [Archivesspace_Users_Group] Adding display fields for search results - How to?</span><span style="font-size:12.0pt;font-family:"Times New Roman";color:black"><o:p></o:p></span></p>
</div>
<div>
<div>
<p class="MsoNormal"><span style="color:#1F497D">Hi Kari,</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">As Steve and Eric mentioned, you need a comma between the last two plugin names and you should uncomment the line by removing the # from the beginning of the line.</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Should look like this:</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">AppConfig[:plugins] = ['local', 'lcnaf', 'aspace-public-formats', 'aspace-search-identifier']</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">If you make those change and restart, it should work. If not, I’m happy to troubleshoot.</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">We use this plugin at Duke and it’s very useful.</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">-Noah</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="color:black">From:</span></b><span style="color:black"> archivesspace_users_group-bounces@lyralists.lyrasis.org [mailto:archivesspace_users_group-bounces@lyralists.lyrasis.org]
<b>On Behalf Of </b>Kari R Smith<br>
<b>Sent:</b> Monday, September 12, 2016 5:02 PM<br>
<b>To:</b> Archivesspace Users Group <archivesspace_users_group@lyralists.lyrasis.org><br>
<b>Subject:</b> Re: [Archivesspace_Users_Group] Adding display fields for search results - How to?<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span style="color:black"> <o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">Noah,
</span><span style="color:black"><o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">Does this snippet look like it's formatted correctly to work in the config.rb file? I saved this to the plug-in folder and restarted ASpace but it's not taking (meaning, ID
is not showing up in search results.)</span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> </span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">#AppConfig[:plugins] = ['local', 'lcnaf', 'aspace-public-formats' 'aspace-search-identifier'] </span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> </span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">Thanks for your help with this</span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black">Kari</span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:Tahoma;color:black"> </span><span style="color:black"><o:p></o:p></span></p>
<div>
<div class="MsoNormal" align="center" style="text-align:center"><span style="font-size:12.0pt;font-family:"Times New Roman";color:black">
<hr size="2" width="100%" align="center">
</span></div>
<div id="divRpF783444">
<p class="MsoNormal" style="margin-bottom:12.0pt"><b><span style="font-size:10.0pt;font-family:Tahoma;color:black">From:</span></b><span style="font-size:10.0pt;font-family:Tahoma;color:black">
<a href="mailto:archivesspace_users_group-bounces@lyralists.lyrasis.org" target="_blank">
archivesspace_users_group-bounces@lyralists.lyrasis.org</a> [archivesspace_users_group-bounces@lyralists.lyrasis.org] on behalf of Noah Huffman [noah.huffman@duke.edu]<br>
<b>Sent:</b> Monday, September 12, 2016 13:52<br>
<b>To:</b> Archivesspace Users Group<br>
<b>Subject:</b> Re: [Archivesspace_Users_Group] Adding display fields for search results - How to?</span><span style="color:black"><o:p></o:p></span></p>
</div>
<div>
<div>
<p class="MsoNormal"><span style="color:#1F497D">Kari,</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Here is a plugin that adds an identifier column to search results in the staff interface:
<a href="https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_lyrasis_aspace-2Dsearch-2Didentifier&d=CwMFEA&c=imBPVzF25OnBgGmVOlcsiEgHoG1i6YHLR0Sj_gZ4adc&r=F0JE8U9-xhxe_nE7d7aEUi-uqfKqvYJ222bS0oz9mko&m=XzVVdhtu-NOYwHpF7t1-skr-ItWN1h9pITcz5Cbf_uE&s=DhHvT91cE0yMiKtoYywN7I2G7ilS_k2IDiDwCZnTUqA&e=" target="_blank">
<b><span style="color:red">MailScanner has detected a possible fraud attempt from "urldefense.proofpoint.com" claiming to be</span></b> https://github.com/lyrasis/aspace-search-identifier</a></span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">I assume you could tweak this to have the identifier column display in the public interface as well.</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">-Noah</span><span style="color:black"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><span style="color:black"><o:p></o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="color:black">From:</span></b><span style="color:black">
<a href="mailto:archivesspace_users_group-bounces@lyralists.lyrasis.org" target="_blank">
archivesspace_users_group-bounces@lyralists.lyrasis.org</a> [<a href="mailto:archivesspace_users_group-bounces@lyralists.lyrasis.org" target="_blank">mailto:archivesspace_users_group-bounces@lyralists.lyrasis.org</a>]
<b>On Behalf Of </b>Kari R Smith<br>
<b>Sent:</b> Monday, September 12, 2016 1:40 PM<br>
<b>To:</b> Archivesspace Users Group (<a href="mailto:archivesspace_users_group@lyralists.lyrasis.org" target="_blank">archivesspace_users_group@lyralists.lyrasis.org</a>) <<a href="mailto:archivesspace_users_group@lyralists.lyrasis.org" target="_blank">archivesspace_users_group@lyralists.lyrasis.org</a>><br>
<b>Subject:</b> [Archivesspace_Users_Group] Adding display fields for search results - How to?<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span style="color:black"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Hi,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">I’m interested in hearing about any solutions for adding to the display fields for search results. Our main interest is in having the collection ID display in addition to the Resource Type and Title (currently
the only displayed data + last modified data).<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Thanks,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Kari R. Smith<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Digital Archivist, Institute Archives and Special Collections<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Massachusetts Institute of Technology Libraries<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">617.253.5690 smithkr at mit.edu
<a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__libraries.mit.edu_archives_&d=CwMFEA&c=imBPVzF25OnBgGmVOlcsiEgHoG1i6YHLR0Sj_gZ4adc&r=F0JE8U9-xhxe_nE7d7aEUi-uqfKqvYJ222bS0oz9mko&m=XzVVdhtu-NOYwHpF7t1-skr-ItWN1h9pITcz5Cbf_uE&s=EBE7rM9t-8OTzIMav4NpIY7v4ego4g7TTFaz_c7R0Rg&e=" target="_blank">
<b><span style="color:red">MailScanner has detected a possible fraud attempt from "urldefense.proofpoint.com" claiming to be</span></b> http://libraries.mit.edu/archives/</a><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> <o:p></o:p></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>