You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Dspace Advanced Search XMLUI定制:如何添加会议类文档标题至搜索筛选器

Adding Conference Document Titles to DSpace XMLUI Advanced Search Filters

Alright, let's tackle this customization step by step. I’ve worked through similar DSpace XMLUI tweaks before, so here’s an actionable, straightforward breakdown:

1. Confirm the Metadata Field for Conference Titles

First, nail down exactly which metadata field stores your conference document titles. Common options include:

  • The standard extended Dublin Core field dc.title.conference
  • A custom field like local.conference.title (if you’ve defined your own metadata schema)

Check your DSpace metadata registry to get the exact field key—this is non-negotiable for the next steps.

2. Update the Advanced Search Configuration File

Head to your DSpace XMLUI source files, and locate the advanced-search.xml file at this path:
dspace-xmlui/src/main/webapp/WEB-INF/classes/search/advanced-search.xml

Open it up, and add a new filter entry inside the <filters> section. For example, if your field is dc.title.conference, add:

<filter id="conference-title" label="Conference Title" type="text">
  <field>dc.title.conference</field>
</filter>
  • id: A unique, descriptive identifier for the filter
  • label: The text users will see in the advanced search UI
  • type: Set to text since we’re targeting a title field

3. Verify Theme XSLT Rendering (If Using a Custom Theme)

If you’re running a custom theme, double-check that its XSLT templates will render the new filter. Most default themes automatically pull in filters from the config file, but if you’ve modified the search UI:

  • Go to your theme’s XSL directory (typically dspace-xmlui/src/main/webapp/themes/[your-theme]/xsl/aspect/artifactbrowser/)
  • Open advanced-search.xsl or search.xsl
  • Ensure there’s a template that loops through all <filter> elements (look for code referencing $filters or iterating over /search/filters/filter) to guarantee your new filter gets displayed

4. Ensure the Metadata Field is Indexed

For the filter to actually return results, your conference title field needs to be included in DSpace’s search index. Open your dspace.cfg file and check the search index configuration sections (e.g., search.index.1, search.index.2). Add your field if it’s missing:

search.index.1 = dc.title.conference:text

If you add it here, you’ll need to reindex your repository after deployment with this command:

[dspace-install]/bin/dspace index-discovery

5. Deploy and Test

Once all changes are made:

  1. Recompile the XMLUI module:
    cd [dspace-source]/dspace-xmlui
    mvn clean package
    
  2. Replace the existing XMLUI WAR file in your DSpace installation:
    cp target/dspace-xmlui-webapp.war [dspace-install]/webapps/xmlui.war
    
  3. Restart your application server (Tomcat, Jetty, etc.)
  4. Navigate to the Advanced Search page—you should now see your new "Conference Title" filter. Test it with a known conference title to confirm it pulls up the correct documents.

内容的提问来源于stack exchange,提问作者Ghufran Khalil

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.27 03:53:34