77 <v-avatar size =" 100" rounded =" xl" >
88 <v-icon
99 v-if ="
10- (instance.instance.status != 'open' ||
11- instance.instance.profilePictureUrl == null) &&
12- statusMapper[instance.instance.status ].icon
10+ (instance.connectionStatus != 'open' ||
11+ instance.profilePicUrl == null) &&
12+ statusMapper[instance.connectionStatus ].icon
1313 "
1414 size =" 70"
1515 >
16- {{ statusMapper[instance.instance.status ].icon }}
16+ {{ statusMapper[instance.connectionStatus ].icon }}
1717 </v-icon >
18- <v-img v-else :src =" instance.instance.profilePictureUrl " />
18+ <v-img v-else :src =" instance.profilePicUrl " />
1919 </v-avatar >
2020 <div class =" d-flex flex-column" >
2121 <span class =" text-overline" style =" line-height : 1em " >
2222 {{ owner }}
2323 </span >
2424 <h2 class =" mb-0" >
25- {{ instance.instance.instanceName }}
25+ {{ instance.name }}
2626 <v-chip
27- v-if =" instance?.instance?.apikey "
27+ v-if =" instance?.token "
2828 color =" info"
2929 class =" ml-2"
3030 size =" x-small"
3131 @click =" copyApikey"
3232 >
3333 <v-icon start size =" small" >mdi-key</v-icon >
34- {{ (instance.instance?.apikey || "").slice(0, 10) }}...
34+ {{ (instance.token || "").slice(0, 10) }}...
3535 <v-icon end size =" small" >
3636 {{ copied ? "mdi-check" : "mdi-content-copy" }}
3737 </v-icon >
3838 </v-chip >
3939 </h2 >
40- <small >{{ instance.instance. profileStatus }}</small >
40+ <small >{{ instance.profileStatus }}</small >
4141 </div >
4242 <v-spacer ></v-spacer >
4343 <div class =" d-flex gap-2 flex-wrap justify-end" >
6868 <v-btn
6969 @click =" disconnectInstance"
7070 :disabled ="
71- instance.instance.status === 'close' || restart.loading || reload
71+ instance.connectionStatus === 'close' || restart.loading || reload
7272 "
7373 :loading =" disconnect.loading"
7474 variant =" tonal"
@@ -102,7 +102,7 @@ export default {
102102 copyApikey () {
103103 if (this .copied ) return ;
104104
105- copyToClipboard (this .instance .instance . apikey );
105+ copyToClipboard (this .instance .token );
106106
107107 this .copied = true ;
108108 setTimeout (() => {
@@ -123,7 +123,7 @@ export default {
123123 async restartInstance () {
124124 this .restart .loading = true ;
125125 try {
126- await instanceController .restart (this .instance .instance . instanceName );
126+ await instanceController .restart (this .instance .name );
127127 this .restart .success = true ;
128128
129129 setTimeout (() => {
@@ -144,7 +144,7 @@ export default {
144144 this .disconnect .loading = true ;
145145 try {
146146 this .disconnect .confirm = false ;
147- await instanceController .logout (this .instance .instance . instanceName );
147+ await instanceController .logout (this .instance .name );
148148 await this .AppStore .reconnect ();
149149 } catch (e) {
150150 console .log (e);
@@ -156,10 +156,10 @@ export default {
156156 },
157157 computed: {
158158 owner () {
159- if (! this .instance ? .instance ? . owner )
160- return this .$t (` status.${ this .instance .instance . status } ` ) || this .$t (" unknown" );
159+ if (! this .instance ? .ownerJid )
160+ return this .$t (` status.${ this .instance .connectionStatus } ` ) || this .$t (" unknown" );
161161
162- return (this .instance ? .instance ? . owner || " " ).split (" @" )[0 ];
162+ return (this .instance ? .ownerJid || " " ).split (" @" )[0 ];
163163 },
164164 },
165165 props: {
@@ -171,4 +171,6 @@ export default {
171171};
172172< / script>
173173
174- < style>< / style>
174+ < style scoped>
175+ /* Add your styles here if needed */
176+ < / style>
0 commit comments