Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
return this.resourceDetails.resourceVersionId;
},
newKeywordTrimmed(): string {
return this.newKeyword?.trim().replace(/ +(?= )/g, '').toLowerCase();
return this.newKeyword?.trim().replace(/ +(?= )/g, '');
},
},
methods: {
Expand All @@ -77,9 +77,9 @@
},
async addKeyword() {
if (this.newKeyword && this.newKeywordTrimmed.length > 0) {
let allTrimmedKeyword = this.newKeywordTrimmed.toLowerCase().split(',');
let allTrimmedKeyword = this.newKeywordTrimmed.split(',');
allTrimmedKeyword = allTrimmedKeyword.filter(e => String(e).trim());
if (!this.resourceDetails.resourceKeywords.find(_keyword => allTrimmedKeyword.includes(_keyword.keyword.toLowerCase()))) {
if (!this.resourceDetails.resourceKeywords.find(_keyword => allTrimmedKeyword.includes(_keyword.keyword))) {
for (var i = 0; i < allTrimmedKeyword.length; i++) {
let item = allTrimmedKeyword[i];
if (item.length > 0 && item.length <= 50) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@
!Boolean(this.$route.query.initialCreate); // or if the user is editing an existing draft (initialCreate=false)
},
newKeywordTrimmed(): string {
return this.newKeyword?.trim().replace(/ +(?= )/g, '').toLowerCase();
return this.newKeyword?.trim().replace(/ +(?= )/g, '');
},
showProviders(): boolean {
if (!this.$store.state.userProviders) {
Expand Down Expand Up @@ -393,7 +393,7 @@
this.keywords = this.resourceDetail.resourceKeywords.map(obj => {
let kw = new KeywordModel();
kw.id = obj.id;
kw.keyword = obj.keyword.toLowerCase();
kw.keyword = obj.keyword;
return kw;
});
if (this.resourceDetail.resourceProviderId > 0) {
Expand Down Expand Up @@ -532,9 +532,9 @@
},
async addKeyword() {
if (this.newKeyword && this.newKeywordTrimmed.length > 0) {
let allTrimmedKeyword = this.newKeywordTrimmed.toLowerCase().split(',');
let allTrimmedKeyword = this.newKeywordTrimmed.split(',');
allTrimmedKeyword = allTrimmedKeyword.filter(e => String(e).trim());
if (!this.keywords.find(_keyword => allTrimmedKeyword.includes(_keyword.keyword.toLowerCase()))) {
if (!this.keywords.find(_keyword => allTrimmedKeyword.includes(_keyword.keyword))) {
for (var i = 0; i < allTrimmedKeyword.length; i++) {
let item = allTrimmedKeyword[i];
if (item.length > 0 && item.length <= 50) {
Expand Down
Loading