From 3dea085b60ca5a34eed1b2c0f0eb827491d2e67a Mon Sep 17 00:00:00 2001 From: Gabriel Pastori <58153955+gabrielpastori1@users.noreply.github.com> Date: Mon, 11 Dec 2023 18:32:46 -0300 Subject: [PATCH] add chatwoot auto_create and profile photo --- package.json | 2 +- src/components/instance/InstanceBody.vue | 2 +- .../instance/profile/ProfilePhoto.vue | 21 ++++++++++++------- src/components/instance/settings/Chatwoot.vue | 18 ++++++++++++++++ src/layouts/default/AppFooter.vue | 2 +- src/store/app.js | 7 +++++++ 6 files changed, 41 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index e1cdb80..eb0445c 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "evolution-manager", "description": "Evolution Manager is an open-source interface for managing the Evolution API, simplifying the creation and administration of API instances with advanced features and diverse integrations.", - "version": "0.4.0", + "version": "0.4.1", "main": "dist", "engines": { "node": ">=16.0.0" diff --git a/src/components/instance/InstanceBody.vue b/src/components/instance/InstanceBody.vue index a28021e..837f857 100644 --- a/src/components/instance/InstanceBody.vue +++ b/src/components/instance/InstanceBody.vue @@ -91,7 +91,7 @@ export default { components: [ "ConnectionAlert", "BasicInfo", - // "ProfilePhoto", + "ProfilePhoto", "Privacy", ], }, diff --git a/src/components/instance/profile/ProfilePhoto.vue b/src/components/instance/profile/ProfilePhoto.vue index 26b0f89..2e1edd3 100644 --- a/src/components/instance/profile/ProfilePhoto.vue +++ b/src/components/instance/profile/ProfilePhoto.vue @@ -26,8 +26,7 @@ {{ error }} -
- {{ instance.instance.profilePictureUrl }} +
- mdi-upload + + mdi-upload Selecionar foto
+
+ + + +
@@ -177,6 +194,7 @@ const defaultObj = () => ({ sign_msg: true, reopen_conversation: true, conversation_pending: false, + auto_create: undefined, }); export default { diff --git a/src/layouts/default/AppFooter.vue b/src/layouts/default/AppFooter.vue index c000f3b..163af93 100644 --- a/src/layouts/default/AppFooter.vue +++ b/src/layouts/default/AppFooter.vue @@ -70,7 +70,7 @@ export default { { title: "Doc", icon: "mdi-book-open-page-variant", - url: "https://doc.evolution-api.com/help-center", + url: "https://doc.evolution-api.com", }, ], }), diff --git a/src/store/app.js b/src/store/app.js index 8af7dba..a9e38a7 100644 --- a/src/store/app.js +++ b/src/store/app.js @@ -123,6 +123,13 @@ export const useAppStore = defineStore('app', { this.instancesList[index].instance.status = status }, + setPhoto(instanceName, photo) { + const index = this.instancesList.findIndex( + (instance) => instance.instance.instanceName === instanceName + ) + if (index !== -1) this.instancesList[index].instance.profilePictureUrl = photo + }, + addInstanceKey({ instance, key }) { this.instancesKeys[instance] = key },