Skip to content
Open
Show file tree
Hide file tree
Changes from 2 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
1 change: 1 addition & 0 deletions src/pages/instance/Chatwoot/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ function Chatwoot() {
/>
<FormSwitch name="reopenConversation" label={t("chatwoot.form.reopenConversation.label")} className="w-full justify-between" helper={t("chatwoot.form.reopenConversation.description")} />
<FormSwitch name="importContacts" label={t("chatwoot.form.importContacts.label")} className="w-full justify-between" helper={t("chatwoot.form.importContacts.description")} />
<FormSwitch name="mergeBrazilContacts" label={t("chatwoot.form.mergeBrazilContacts.label")} className="w-full justify-between" helper={t("chatwoot.form.mergeBrazilContacts.description")} />
<FormSwitch name="importMessages" label={t("chatwoot.form.importMessages.label")} className="w-full justify-between" helper={t("chatwoot.form.importMessages.description")} />
<FormInput name="daysLimitImportMessages" label={t("chatwoot.form.daysLimitImportMessages.label")}>
<Input type="number" />
Expand Down
3 changes: 3 additions & 0 deletions src/pages/instance/DashboardInstance/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { CircleUser, MessageCircle, RefreshCw, UsersRound } from "lucide-react";
import { useEffect, useMemo, useState } from "react";
import { useTranslation } from "react-i18next";
import QRCode from "react-qr-code";
import { toast } from "react-toastify";

import { InstanceStatus } from "@/components/instance-status";
import { InstanceToken } from "@/components/instance-token";
Expand Down Expand Up @@ -46,8 +47,10 @@ function DashboardInstance() {
try {
await restart(instanceName);
await reloadInstance();
toast.success(t("instance.dashboard.toast.restart.success"));
} catch (error) {
console.error("Error:", error);
toast.error(t("instance.dashboard.toast.restart.error"));
}
};

Expand Down
10 changes: 10 additions & 0 deletions src/translate/languages/pt-BR.json
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,12 @@
"restart": "Reiniciar",
"disconnect": "Desconectar"
},
"toast": {
"restart": {
"success": "Instância reiniciada com sucesso",
"error": "Erro ao reiniciar instância"
}
},
"alert": "Para conectar, escaneie o QR Code com o WhatsApp",
"contacts": "Contatos",
"chats": "Chats",
Expand Down Expand Up @@ -349,6 +355,10 @@
"label": "Importar Contatos",
"description": "Importar contatos da agenda do WhatsApp ao conectar o QR Code"
},
"mergeBrazilContacts": {
"label": "Mesclar Contatos Brasil",
"description": "Mescla contatos brasileiros com e sem código de país (55)"
},
"importMessages": {
"label": "Importar Mensagens",
"description": "Importar mensagens do WhatsApp ao conectar o QR Code"
Expand Down