chore: default wa_gateway_type=gowa (baileys dilepas) + README
This commit is contained in:
1 parent
0f612df70f
commit
cb60ceec10
10 files changed
+19
-19
No files matched your search
@@ -6496,7 +6496,7 @@ router.get('/whatsapp/gowa/qr.png', requireAdminSession, async (req, res) => {
|
||||
});
|
||||
|
||||
router.get('/whatsapp', requireAdminSession, requireSidebarMenuAccess('whatsapp'), async (req, res) => {
|
||||
const waGatewayType = getSetting('wa_gateway_type', 'baileys');
|
||||
const waGatewayType = getSetting('wa_gateway_type', 'gowa');
|
||||
const metaSettings = {
|
||||
meta_phone_number_id: getSetting('meta_phone_number_id', ''),
|
||||
meta_waba_id: getSetting('meta_waba_id', ''),
|
||||
@@ -6611,7 +6611,7 @@ router.post('/whatsapp/test-fonnte', requireAdminSession, express.json(), async
|
||||
|
||||
// LIVE CHAT ROUTES
|
||||
router.get('/whatsapp/live-chat', requireAdminSession, requireSidebarMenuAccess('whatsapp'), async (req, res) => {
|
||||
const waGatewayType = getSetting('wa_gateway_type', 'baileys');
|
||||
const waGatewayType = getSetting('wa_gateway_type', 'gowa');
|
||||
const customers = customerSvc.getAllCustomers();
|
||||
res.render('admin/whatsapp_live_chat', {
|
||||
title: 'Live Chat WhatsApp',
|
||||
@@ -7075,7 +7075,7 @@ router.post('/whatsapp/run-reminder-now', requireAdminSession, async (req, res)
|
||||
|
||||
router.get('/api/whatsapp/status', requireAdmin, async (req, res) => {
|
||||
try {
|
||||
const gatewayType = getSetting('wa_gateway_type', 'baileys');
|
||||
const gatewayType = getSetting('wa_gateway_type', 'gowa');
|
||||
if (gatewayType === 'fonnte') {
|
||||
const token = getSetting('fonnte_token', '');
|
||||
res.json({
|
||||
|
||||
@@ -2088,7 +2088,7 @@ router.get('/app/admin/olts', requireAdminApiAuth, (req, res) => {
|
||||
// ─── ADMIN NATIVE: WHATSAPP STATUS ───────────────────────────────────────────
|
||||
router.get('/app/admin/whatsapp/status', requireAdminApiAuth, async (req, res) => {
|
||||
try {
|
||||
const gwType = String(require('../config/settingsManager').getSetting('wa_gateway_type', 'baileys') || 'baileys').toLowerCase();
|
||||
const gwType = String(require('../config/settingsManager').getSetting('wa_gateway_type', 'gowa') || 'baileys').toLowerCase();
|
||||
let isConnected = false;
|
||||
let waNumber = '-';
|
||||
let waName = gwType.toUpperCase();
|
||||
|
||||
Reference in new issue
Block a user