Enforce term 'topic' instead of 'tag' in project context
What does this MR do?
Related issue: #328226 (closed)
In GitLab, you can add arbitrary topics to a project in the project settings:
In the backend, that's implemented using the acts_as_taggable_on
gem. That's okay. But unfortunately, the terms tags
and tag_list
are used instead of topics
and topic_list
in some places in the backend. This is not consistent and also brings confusion with the actual tags (git tags of project repositories).
This MR fixes this confusion by replacing all occurrences of the incorrect term tag
in the project context with the correct term topic
. This step was discussed in #328226 (closed) and provides the basis for implementing more ideas to boost project topics.
This change has an impact on all places where the wrong term "tags" has been used for project topics so far:
Frontend: Explore projects by topic:
- Before: http://gdk.test:3000/explore/projects?tag=topic1
- After: http://gdk.test:3000/explore/projects?topic=topic1
API: Project
entity (GET):
GET http://gdk.test:3000/api/v4/projects/3
{
"id": 3,
"name": "Wget2",
- "tag_list": [
+ "topic_list": [
"topic1",
"topic2"
],
...
}
API: Project
entity (POST/PUT):
PUT http://gdk.test:3000/api/v4/projects/3
Body:
{
- "tag_list": "topic1,topic2",
+ "topic_list": "topic1,topic2",
...
}
/cc @bufferoverflow
Does this MR meet the acceptance criteria?
Conformity
-
📋 Does this MR need a changelog?-
I have included a changelog entry.
-
-
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. - [-] Tested in all supported browsers
- [-] Informed Infrastructure department of a default or new setting change, if applicable per definition of done
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
- [-] Label as security and @ mention
@gitlab-com/gl-security/appsec
- [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
- [-] Security reports checked/validated by a reviewer from the AppSec team