mirror of
https://github.com/EvolutionAPI/evolution-manager.git
synced 2025-07-13 15:14:49 -06:00
translate instance root components
body, header, connectPhone
This commit is contained in:
parent
c0f3dcdc50
commit
790755de55
@ -2,7 +2,7 @@
|
|||||||
<v-tabs v-model="tab" background-color="transparent" color="primary" grow>
|
<v-tabs v-model="tab" background-color="transparent" color="primary" grow>
|
||||||
<v-tab v-for="tab in tabs" :key="tab.id" :value="tab.id">
|
<v-tab v-for="tab in tabs" :key="tab.id" :value="tab.id">
|
||||||
<v-icon start>{{ tab.icon }}</v-icon>
|
<v-icon start>{{ tab.icon }}</v-icon>
|
||||||
{{ tab.title }}
|
{{ $t(`instanceTabs.${tab.id}`) }}
|
||||||
</v-tab>
|
</v-tab>
|
||||||
</v-tabs>
|
</v-tabs>
|
||||||
|
|
||||||
@ -62,7 +62,6 @@ export default {
|
|||||||
{
|
{
|
||||||
id: "settings",
|
id: "settings",
|
||||||
icon: "mdi-cog",
|
icon: "mdi-cog",
|
||||||
title: "Configurações",
|
|
||||||
components: [
|
components: [
|
||||||
"Options",
|
"Options",
|
||||||
"Webhook",
|
"Webhook",
|
||||||
@ -75,7 +74,6 @@ export default {
|
|||||||
{
|
{
|
||||||
id: "message",
|
id: "message",
|
||||||
icon: "mdi-message",
|
icon: "mdi-message",
|
||||||
title: "Mensagens",
|
|
||||||
components: [
|
components: [
|
||||||
"OpenSendMessage",
|
"OpenSendMessage",
|
||||||
"HasWhatsapp",
|
"HasWhatsapp",
|
||||||
@ -87,7 +85,6 @@ export default {
|
|||||||
{
|
{
|
||||||
id: "profile",
|
id: "profile",
|
||||||
icon: "mdi-account",
|
icon: "mdi-account",
|
||||||
title: "Perfil",
|
|
||||||
components: [
|
components: [
|
||||||
"ConnectionAlert",
|
"ConnectionAlert",
|
||||||
"BasicInfo",
|
"BasicInfo",
|
||||||
|
@ -63,7 +63,7 @@
|
|||||||
size="small"
|
size="small"
|
||||||
>
|
>
|
||||||
<v-icon start>mdi-restart</v-icon>
|
<v-icon start>mdi-restart</v-icon>
|
||||||
{{ restart.success ? "Reiniciada!" : "Reiniciar" }}
|
{{ restart.success ? `${$t("restarted")}` : `${$t("restart")}` }}
|
||||||
</v-btn>
|
</v-btn>
|
||||||
<v-btn
|
<v-btn
|
||||||
@click="disconnectInstance"
|
@click="disconnectInstance"
|
||||||
@ -76,7 +76,7 @@
|
|||||||
size="small"
|
size="small"
|
||||||
>
|
>
|
||||||
<v-icon start>mdi-cellphone-nfc-off</v-icon>
|
<v-icon start>mdi-cellphone-nfc-off</v-icon>
|
||||||
{{ disconnect.confirm ? "Tem Certeza?" : "Desconectar" }}
|
{{ disconnect.confirm ? `${$t("sure")}` : `${$t("disconnect")}` }}
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</div>
|
</div>
|
||||||
</v-card>
|
</v-card>
|
||||||
@ -157,10 +157,8 @@ export default {
|
|||||||
computed: {
|
computed: {
|
||||||
owner() {
|
owner() {
|
||||||
if (!this.instance?.instance?.owner)
|
if (!this.instance?.instance?.owner)
|
||||||
return (
|
return this.$t(`status.${this.instance.instance.status}`) || this.$t("unknown");
|
||||||
this.statusMapper[this.instance.instance.status]?.text ||
|
|
||||||
"Desconhecido"
|
|
||||||
);
|
|
||||||
return (this.instance?.instance?.owner || "").split("@")[0];
|
return (this.instance?.instance?.owner || "").split("@")[0];
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -1,17 +1,23 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-card v-if="instance.instance?.status != 'open'" @click="startConnect" elevation="0">
|
<v-card
|
||||||
|
v-if="instance.instance?.status != 'open'"
|
||||||
|
@click="startConnect"
|
||||||
|
elevation="0"
|
||||||
|
>
|
||||||
<v-alert
|
<v-alert
|
||||||
icon="mdi-qrcode-scan"
|
icon="mdi-qrcode-scan"
|
||||||
color="deep-orange-darken-2"
|
color="deep-orange-darken-2"
|
||||||
class="text-white"
|
class="text-white"
|
||||||
>
|
>
|
||||||
<div class="d-flex justify-space-between align-center flex-wrap">
|
<div class="d-flex justify-space-between align-center flex-wrap">
|
||||||
<b>Telefone não conectado</b>
|
<b>{{ $t("connectPhone.title") }}</b>
|
||||||
<v-btn @click="startConnect" size="small"> Conectar </v-btn>
|
<v-btn @click="startConnect" size="small">
|
||||||
|
{{ $t("connection.action") }}
|
||||||
|
</v-btn>
|
||||||
</div>
|
</div>
|
||||||
</v-alert>
|
</v-alert>
|
||||||
</v-card>
|
</v-card>
|
||||||
<v-dialog v-model="dialog" max-width="350px">
|
<v-dialog v-model="dialog" max-width="350px" :persistent="loading">
|
||||||
<v-card :loading="loading && qrCode">
|
<v-card :loading="loading && qrCode">
|
||||||
<v-card-text class="pt-6">
|
<v-card-text class="pt-6">
|
||||||
<v-img v-if="qrCode" :src="qrCode" width="300px" height="300px" />
|
<v-img v-if="qrCode" :src="qrCode" width="300px" height="300px" />
|
||||||
@ -38,7 +44,7 @@
|
|||||||
class="mt-2"
|
class="mt-2"
|
||||||
>
|
>
|
||||||
<v-icon start size="small">mdi-refresh</v-icon>
|
<v-icon start size="small">mdi-refresh</v-icon>
|
||||||
Atualizar
|
{{ $t("refresh") }}
|
||||||
</v-btn>
|
</v-btn>
|
||||||
|
|
||||||
<v-alert type="error" v-if="error" class="mt-2">
|
<v-alert type="error" v-if="error" class="mt-2">
|
||||||
@ -47,7 +53,9 @@
|
|||||||
</v-card-text>
|
</v-card-text>
|
||||||
<v-card-actions>
|
<v-card-actions>
|
||||||
<v-spacer></v-spacer>
|
<v-spacer></v-spacer>
|
||||||
<v-btn text @click="dialog = false" :disabled="loading"> Cancel </v-btn>
|
<v-btn text @click="dialog = false" :disabled="loading">
|
||||||
|
{{ $t("cancel") }}
|
||||||
|
</v-btn>
|
||||||
<v-spacer></v-spacer>
|
<v-spacer></v-spacer>
|
||||||
</v-card-actions>
|
</v-card-actions>
|
||||||
</v-card>
|
</v-card>
|
||||||
|
@ -32,7 +32,9 @@
|
|||||||
</v-card-text>
|
</v-card-text>
|
||||||
<v-card-actions>
|
<v-card-actions>
|
||||||
<div class="d-flex flex-wrap justify-space-between w-100 align-center">
|
<div class="d-flex flex-wrap justify-space-between w-100 align-center">
|
||||||
<v-btn size="small" text @click="showAbout"> {{ $t('about.title') }} </v-btn>
|
<v-btn size="small" text @click="showAbout">
|
||||||
|
{{ $t("about.title") }}
|
||||||
|
</v-btn>
|
||||||
<div class="d-flex justify-end flex-grow-1 gap-1">
|
<div class="d-flex justify-end flex-grow-1 gap-1">
|
||||||
<v-btn
|
<v-btn
|
||||||
v-if="!!AppStore.connection.host"
|
v-if="!!AppStore.connection.host"
|
||||||
@ -72,8 +74,8 @@
|
|||||||
:disabled="!valid"
|
:disabled="!valid"
|
||||||
:loading="loading"
|
:loading="loading"
|
||||||
>
|
>
|
||||||
{{ $t('connection.action') }}
|
{{ $t("connection.action") }}
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</v-card-actions>
|
</v-card-actions>
|
||||||
@ -81,7 +83,9 @@
|
|||||||
|
|
||||||
<v-card class="mt-2" v-if="connectionsList && connectionsList.length > 1">
|
<v-card class="mt-2" v-if="connectionsList && connectionsList.length > 1">
|
||||||
<v-card-text>
|
<v-card-text>
|
||||||
<h3 class="mb-4">{{ $t('connection.saved') }}</h3>
|
<h3 class="mb-4">
|
||||||
|
{{ $t("connection.saved", connectionsList.length) }}
|
||||||
|
</h3>
|
||||||
<v-list>
|
<v-list>
|
||||||
<v-list-item
|
<v-list-item
|
||||||
v-for="conect in connectionsList"
|
v-for="conect in connectionsList"
|
||||||
|
@ -1,15 +1,21 @@
|
|||||||
|
// src/i18n/en.js
|
||||||
import { en } from 'vuetify/locale'
|
import { en } from 'vuetify/locale'
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
$vuetify: { ...en },
|
$vuetify: { ...en },
|
||||||
all: "All",
|
all: "All",
|
||||||
close: "Close",
|
close: "Close",
|
||||||
|
cancel: "Cancel",
|
||||||
|
restart: "Restart",
|
||||||
|
restarted: "Restarted",
|
||||||
|
refresh: "Refresh",
|
||||||
|
disconnect: "Disconnect",
|
||||||
|
sure: "Sure?",
|
||||||
instance: "Instance | Instances",
|
instance: "Instance | Instances",
|
||||||
search: "Search",
|
search: "Search",
|
||||||
loading: "Loading",
|
loading: "Loading",
|
||||||
noInstances: "No instances found",
|
noInstances: "No instances found",
|
||||||
|
unknown: "Unknown",
|
||||||
status: {
|
status: {
|
||||||
close: "Disconnected",
|
close: "Disconnected",
|
||||||
connecting: "Connecting",
|
connecting: "Connecting",
|
||||||
@ -28,5 +34,13 @@ export default {
|
|||||||
title: "Configure connection",
|
title: "Configure connection",
|
||||||
action: "Connect",
|
action: "Connect",
|
||||||
saved: "Connection saved | Connections saved",
|
saved: "Connection saved | Connections saved",
|
||||||
|
},
|
||||||
|
instanceTabs: {
|
||||||
|
settings: "Settings",
|
||||||
|
message: "Messages",
|
||||||
|
profile: "Profile",
|
||||||
|
},
|
||||||
|
connectPhone: {
|
||||||
|
title: "Phone not connected"
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,15 +1,21 @@
|
|||||||
|
// src/i18n/pt.js
|
||||||
import { pt } from 'vuetify/locale'
|
import { pt } from 'vuetify/locale'
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
$vuetify: { ...pt },
|
$vuetify: { ...pt },
|
||||||
all: "Todo | Todos",
|
all: "Todo | Todos",
|
||||||
close: "Fechar",
|
close: "Fechar",
|
||||||
|
cancel: "Cancelar",
|
||||||
|
restart: "Reiniciar",
|
||||||
|
restarted: "Reiniciada",
|
||||||
|
refresh: "Atualizar",
|
||||||
|
disconnect: "Desconectar",
|
||||||
|
sure: "Tem certeza?",
|
||||||
instance: "Instância | Instâncias",
|
instance: "Instância | Instâncias",
|
||||||
search: "Pesquisar",
|
search: "Pesquisar",
|
||||||
loading: "Carregando",
|
loading: "Carregando",
|
||||||
noInstances: "Nenhuma instância encontrada",
|
noInstances: "Nenhuma instância encontrada",
|
||||||
|
unknown: "Desconhecido",
|
||||||
status: {
|
status: {
|
||||||
close: "Desconectado",
|
close: "Desconectado",
|
||||||
connecting: "Conectando",
|
connecting: "Conectando",
|
||||||
@ -28,8 +34,13 @@ export default {
|
|||||||
title: "Configurar conexão",
|
title: "Configurar conexão",
|
||||||
action: "Conectar",
|
action: "Conectar",
|
||||||
saved: "Conexão salva | Conexões salvas",
|
saved: "Conexão salva | Conexões salvas",
|
||||||
|
},
|
||||||
|
instanceTabs: {
|
||||||
|
settings: "Configurações",
|
||||||
|
message: "Mensagens",
|
||||||
|
profile: "Perfil",
|
||||||
|
},
|
||||||
|
connectPhone: {
|
||||||
|
title: "Telefone não conectado"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user