Skip to content

Commit

Permalink
Merge pull request #9570 from nextcloud/fix/search-from-to-cc-bcc
Browse files Browse the repository at this point in the history
Fix: Display from, to, cc, bcc correctly on advance search
  • Loading branch information
GretaD authored Apr 18, 2024
2 parents 9da3f56 + b278767 commit 46d37f7
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions src/components/SearchMessages.vue
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
</div>
<div class="modal-inner--field">
<label class="modal-inner--label" for="fromId">
{{ t("mail", "From") }}
{{ t('mail', 'From') }}
</label>
<div class="modal-inner--container">
<NcSelect id="fromId"
Expand All @@ -95,7 +95,7 @@
:show-no-options="false"
:preserve-search="true"
:max="1"
@option:created="addTag($event,'from')"
@option:selecting="addTag($event,'from')"
@search="searchRecipients($event)" />
</div>
</div>
Expand All @@ -119,7 +119,7 @@
:show-no-options="false"
:preserve-search="true"
:max="1"
@option:created="addTag($event,'to')"
@option:selecting="addTag($event,'to')"
@search="searchRecipients($event)" />
</div>
</div>
Expand Down Expand Up @@ -458,22 +458,18 @@ export default {
}
},
addTag(tag, type) {
const _tag = [{
label: tag,
email: tag,
}]
switch (type) {
case 'to':
this.searchInTo = _tag
this.searchInTo = tag
break
case 'from':
this.searchInFrom = _tag
this.searchInFrom = tag
break
case 'cc':
this.searchInCc = _tag
this.searchInCc = tag
break
case 'bcc':
this.searchInBcc = _tag
this.searchInBcc = tag
break
}
},
Expand Down

0 comments on commit 46d37f7

Please sign in to comment.