diff --git a/ci4/app/Language/es/Chat.php b/ci4/app/Language/es/Chat.php
index 1e649965..3bc975c8 100644
--- a/ci4/app/Language/es/Chat.php
+++ b/ci4/app/Language/es/Chat.php
@@ -2,6 +2,7 @@
return [
"chat" => "MensajerÃa",
+ "messages" => "Mensajes",
"modal" => [
"new_hebra" => "Nueva hebra",
"title" => "TÃtulo",
diff --git a/ci4/app/Models/Chat/ChatModel.php b/ci4/app/Models/Chat/ChatModel.php
index 161b8115..7405f3b9 100644
--- a/ci4/app/Models/Chat/ChatModel.php
+++ b/ci4/app/Models/Chat/ChatModel.php
@@ -210,6 +210,7 @@ class ChatModel extends Model
->join("chat_departments","chat_departments.id = chats.chat_department_id","left")
->join("pedidos","pedidos.id = chats.pedido_id","left")
->whereIn("pedidos.id",$pedidos)
+ ->where("chats.chat_department_id is NOT NULL",NULL,FALSE)
->get()->getResultObject();
$chatMessageModel = model(ChatMessageModel::class);
$count = 0;
@@ -237,6 +238,7 @@ class ChatModel extends Model
->join("chat_departments","chat_departments.id = chats.chat_department_id","left")
->join("facturas","facturas.id = chats.factura_id","left")
->whereIn("facturas.id",$facturas)
+ ->where("chats.chat_department_id is NOT NULL",NULL,FALSE)
->get()->getResultObject();
$chatMessageModel = model(ChatMessageModel::class);
$count = 0;
@@ -264,6 +266,7 @@ class ChatModel extends Model
->join("chat_departments","chat_departments.id = chats.chat_department_id","left")
->join("presupuestos","presupuestos.id = chats.presupuesto_id","left")
->whereIn("presupuestos.id",$presupuestos)
+ ->where("chats.chat_department_id is NOT NULL",NULL,FALSE)
->get()->getResultObject();
$chatMessageModel = model(ChatMessageModel::class);
$count = 0;
diff --git a/ci4/app/Views/themes/vuexy/components/chat_internal_factura.php b/ci4/app/Views/themes/vuexy/components/chat_internal_factura.php
index 210be798..8b6ec719 100644
--- a/ci4/app/Views/themes/vuexy/components/chat_internal_factura.php
+++ b/ci4/app/Views/themes/vuexy/components/chat_internal_factura.php
@@ -15,17 +15,21 @@
+ user()->inGroup('admin') || auth()->user()->inGroup('beta')) { ?>
+
= view("themes/vuexy/components/chat_factura", data: ["modelId" => $modelId,"type" => "factura"]) ?>
+ user()->inGroup('admin') || auth()->user()->inGroup('beta')) { ?>
= view("themes/vuexy/components/internal_messages", data: ["modelId" => $modelId,"type" => "factura"]) ?>
+
diff --git a/ci4/app/Views/themes/vuexy/components/chat_internal_pedido.php b/ci4/app/Views/themes/vuexy/components/chat_internal_pedido.php
index 800229f2..bc6f8813 100644
--- a/ci4/app/Views/themes/vuexy/components/chat_internal_pedido.php
+++ b/ci4/app/Views/themes/vuexy/components/chat_internal_pedido.php
@@ -15,17 +15,21 @@
+ user()->inGroup('admin') || auth()->user()->inGroup('beta')) { ?>
+
= view("themes/vuexy/components/chat_pedido", data: ["modelId" => $modelId, "type" => "pedido"]) ?>
-
- = view("themes/vuexy/components/internal_messages", data: ["modelId" => $modelId, "type" => "pedido"]) ?>
-
+ user()->inGroup('admin') || auth()->user()->inGroup('beta')) { ?>
+
+ = view("themes/vuexy/components/internal_messages", data: ["modelId" => $modelId, "type" => "pedido"]) ?>
+
+
diff --git a/ci4/app/Views/themes/vuexy/components/chat_internal_presupuesto.php b/ci4/app/Views/themes/vuexy/components/chat_internal_presupuesto.php
index e8775dde..d8509da1 100644
--- a/ci4/app/Views/themes/vuexy/components/chat_internal_presupuesto.php
+++ b/ci4/app/Views/themes/vuexy/components/chat_internal_presupuesto.php
@@ -15,17 +15,21 @@
+ user()->inGroup('admin') || auth()->user()->inGroup('beta')) { ?>
+
= view("themes/vuexy/components/chat_presupuesto", data: ["modelId" => $modelId, "type" => "presupuesto"]) ?>
-
- = view("themes/vuexy/components/internal_messages", data: ["modelId" => $modelId, "type" => "presupuesto"]) ?>
-
+ user()->inGroup('admin') || auth()->user()->inGroup('beta')) { ?>
+
+ = view("themes/vuexy/components/internal_messages", data: ["modelId" => $modelId, "type" => "presupuesto"]) ?>
+
+
diff --git a/ci4/app/Views/themes/vuexy/components/chat_pedido.php b/ci4/app/Views/themes/vuexy/components/chat_pedido.php
index 44e17de6..03768365 100644
--- a/ci4/app/Views/themes/vuexy/components/chat_pedido.php
+++ b/ci4/app/Views/themes/vuexy/components/chat_pedido.php
@@ -37,16 +37,6 @@
-
-
diff --git a/ci4/app/Views/themes/vuexy/components/chat_presupuesto.php b/ci4/app/Views/themes/vuexy/components/chat_presupuesto.php
index cf791d27..5a9bb075 100644
--- a/ci4/app/Views/themes/vuexy/components/chat_presupuesto.php
+++ b/ci4/app/Views/themes/vuexy/components/chat_presupuesto.php
@@ -1,4 +1,4 @@
-
+
diff --git a/ci4/app/Views/themes/vuexy/main/defaultlayout.php b/ci4/app/Views/themes/vuexy/main/defaultlayout.php
index 05d7d9b8..6dfae172 100644
--- a/ci4/app/Views/themes/vuexy/main/defaultlayout.php
+++ b/ci4/app/Views/themes/vuexy/main/defaultlayout.php
@@ -122,7 +122,7 @@ $picture = "/assets/img/default-user.png";