Closed vocabularies for the tag input type still allow custom values as long as there's a suggestion present

未关闭
#6,332 0 条评论 1 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 1 天内回复

@jensvannerum 已经在做这个了。

开始于 2026年10月6日。

评估

这个 Issue 还没有评估数据。

描述

affects: 10.x affects: 8.x affects: 9.x affects: main bug claimed: Atmire component: controlled vocabulary component: submission

Describe the bug

Even when a vocabulary is closed, if you use the tag input type for it, your input will always be appeneded to the list as a 'suggestion', allowing you to submit any value (as long as your input causes a suggestion to show).

To Reproduce

  1. Set any field up in the back end's submission-forms.xml to use a vocabulary with closed=true and input type tag e.g:
                <field>
                    <dc-schema>dc</dc-schema>
                    <dc-element>subject</dc-element>
                    <dc-qualifier></dc-qualifier>
                    <repeatable>true</repeatable>
                    <label>Subject Keywords</label>
                    <input-type>tag</input-type>
                    <hint>Enter appropriate subject keywords or phrases.</hint>
                    <required></required>
                    <vocabulary closed="true">srsc</vocabulary>
                </field>
  1. Start tying a value that appears in the vocabulary, but only partially so that your input is not in the vocabulary
  2. Verify that your input is shown as suggestion at the bottom of the list, you can click it, it's added as a tag and you can save/submit

In the images below you can see how I add "tes" which is NOT in my vocabulary

Image Image Image

Expected behavior

A clear and concise description of what you expected to happen.

I've already got a fix on DSpace 9, so I will claim this issue myself and re-do it against the latest main

主要语言
TypeScript
星标
180
派生
577
平均合并
1 天 23 小时
30 天内合并 PR
95

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

DSpace/dspace-angular 的其他 Issue

查看 DSpace/dspace-angular 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。