This commit is contained in:
amazuecos
2024-10-15 17:25:01 +00:00
13 changed files with 40 additions and 27 deletions

View File

@ -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;