File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change 11<template >
22 <div class =" q-gutter-md" >
33 <div class =" row text-h6" >Invite guests</div >
4+ <div class =" row q-mt-sm" >
5+ <div style =" width : 590px " >
6+ <q-input v-model =" filter" filled dense placeholder =" Search" >
7+ <template #prepend >
8+ <q-icon name =" search" />
9+ </template >
10+ </q-input >
11+ </div >
12+ </div >
413 <div class =" row q-mt-sm" style =" margin-left : 12px " >
514 <template v-if =" guestsWithInvitation .length > 0 " >
615 <div
@@ -61,8 +70,10 @@ export default defineComponent({
6170 const team = ctfnote .profiles .injectTeam ();
6271 const now = ref (new Date ());
6372 const settings = ctfnote .settings .injectSettings ();
73+ const filter = ref (' ' );
6474
6575 return {
76+ filter ,
6677 now ,
6778 team ,
6879 settings ,
@@ -79,7 +90,14 @@ export default defineComponent({
7990 );
8091 },
8192 guestsWithInvitation() {
82- return this .guests .map ((g ) => {
93+ let guests = this .guests ;
94+ if (this .filter ) {
95+ guests = guests .filter ((g ) =>
96+ g .username .toLowerCase ().includes (this .filter .toLowerCase ()),
97+ );
98+ }
99+
100+ return guests .map ((g ) => {
83101 const invitation = this .ctf .invitations .find (
84102 (i ) => i .profileId == g .id ,
85103 );
You can’t perform that action at this time.
0 commit comments