Skip to content

Commit eb04c3f

Browse files
committed
fix: reorganization of files and folders
1 parent 8ece6fb commit eb04c3f

4 files changed

Lines changed: 37 additions & 37 deletions

File tree

src/api/controllers/instance.controller.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ import { IntegrationService } from '../services/integration.service';
2020
import { WAMonitoringService } from '../services/monitor.service';
2121
import { SettingsService } from '../services/settings.service';
2222
import { WebhookService } from '../services/webhook.service';
23-
import { BaileysStartupService } from '../services/whatsapp.baileys.service';
24-
import { BusinessStartupService } from '../services/whatsapp.business.service';
23+
import { BaileysStartupService } from '../services/whatsapp/whatsapp.baileys.service';
24+
import { BusinessStartupService } from '../services/whatsapp/whatsapp.business.service';
2525
import { Events, Integration, wa } from '../types/wa.types';
2626
import { ProxyController } from './proxy.controller';
2727

src/api/services/monitor.service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ import {
2626
import { RepositoryBroker } from '../repository/repository.manager';
2727
import { Integration } from '../types/wa.types';
2828
import { CacheService } from './cache.service';
29-
import { BaileysStartupService } from './whatsapp.baileys.service';
30-
import { BusinessStartupService } from './whatsapp.business.service';
29+
import { BaileysStartupService } from './whatsapp/whatsapp.baileys.service';
30+
import { BusinessStartupService } from './whatsapp/whatsapp.business.service';
3131

3232
export class WAMonitoringService {
3333
constructor(

src/api/services/whatsapp.baileys.service.ts renamed to src/api/services/whatsapp/whatsapp.baileys.service.ts

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -54,14 +54,14 @@ import qrcode, { QRCodeToDataURLOptions } from 'qrcode';
5454
import qrcodeTerminal from 'qrcode-terminal';
5555
import sharp from 'sharp';
5656

57-
import { ConfigService, ConfigSessionPhone, Database, Log, QrCode, Redis } from '../../config/env.config';
58-
import { INSTANCE_DIR } from '../../config/path.config';
59-
import { BadRequestException, InternalServerErrorException, NotFoundException } from '../../exceptions';
60-
import { dbserver } from '../../libs/db.connect';
61-
import { RedisCache } from '../../libs/redis.client';
62-
import { makeProxyAgent } from '../../utils/makeProxyAgent';
63-
import { useMultiFileAuthStateDb } from '../../utils/use-multi-file-auth-state-db';
64-
import { useMultiFileAuthStateRedisDb } from '../../utils/use-multi-file-auth-state-redis-db';
57+
import { ConfigService, ConfigSessionPhone, Database, Log, QrCode, Redis } from '../../../config/env.config';
58+
import { INSTANCE_DIR } from '../../../config/path.config';
59+
import { BadRequestException, InternalServerErrorException, NotFoundException } from '../../../exceptions';
60+
import { dbserver } from '../../../libs/db.connect';
61+
import { RedisCache } from '../../../libs/redis.client';
62+
import { makeProxyAgent } from '../../../utils/makeProxyAgent';
63+
import { useMultiFileAuthStateDb } from '../../../utils/use-multi-file-auth-state-db';
64+
import { useMultiFileAuthStateRedisDb } from '../../../utils/use-multi-file-auth-state-redis-db';
6565
import {
6666
ArchiveChatDto,
6767
BlockUserDto,
@@ -75,7 +75,7 @@ import {
7575
SendPresenceDto,
7676
UpdateMessageDto,
7777
WhatsAppNumberDto,
78-
} from '../dto/chat.dto';
78+
} from '../../dto/chat.dto';
7979
import {
8080
AcceptGroupInvite,
8181
CreateGroupDto,
@@ -89,9 +89,9 @@ import {
8989
GroupToggleEphemeralDto,
9090
GroupUpdateParticipantDto,
9191
GroupUpdateSettingDto,
92-
} from '../dto/group.dto';
93-
import { InstanceDto, SetPresenceDto } from '../dto/instance.dto';
94-
import { HandleLabelDto, LabelDto } from '../dto/label.dto';
92+
} from '../../dto/group.dto';
93+
import { InstanceDto, SetPresenceDto } from '../../dto/instance.dto';
94+
import { HandleLabelDto, LabelDto } from '../../dto/label.dto';
9595
import {
9696
ContactMessage,
9797
MediaMessage,
@@ -108,17 +108,17 @@ import {
108108
SendStickerDto,
109109
SendTextDto,
110110
StatusMessage,
111-
} from '../dto/sendMessage.dto';
112-
import { chatwootImport } from '../integrations/chatwoot/utils/chatwoot-import-helper';
113-
import { SettingsRaw } from '../models';
114-
import { ChatRaw } from '../models/chat.model';
115-
import { ContactRaw } from '../models/contact.model';
116-
import { MessageRaw, MessageUpdateRaw } from '../models/message.model';
117-
import { RepositoryBroker } from '../repository/repository.manager';
118-
import { waMonitor } from '../server.module';
119-
import { Events, MessageSubtype, TypeMediaMessage, wa } from '../types/wa.types';
120-
import { CacheService } from './cache.service';
121-
import { WAStartupService } from './whatsapp.service';
111+
} from '../../dto/sendMessage.dto';
112+
import { chatwootImport } from '../../integrations/chatwoot/utils/chatwoot-import-helper';
113+
import { SettingsRaw } from '../../models';
114+
import { ChatRaw } from '../../models/chat.model';
115+
import { ContactRaw } from '../../models/contact.model';
116+
import { MessageRaw, MessageUpdateRaw } from '../../models/message.model';
117+
import { RepositoryBroker } from '../../repository/repository.manager';
118+
import { waMonitor } from '../../server.module';
119+
import { Events, MessageSubtype, TypeMediaMessage, wa } from '../../types/wa.types';
120+
import { CacheService } from './../cache.service';
121+
import { WAStartupService } from './../whatsapp.service';
122122

123123
// const retryCache = {};
124124

src/api/services/whatsapp.business.service.ts renamed to src/api/services/whatsapp/whatsapp.business.service.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ import FormData from 'form-data';
55
import fs from 'fs/promises';
66
import { getMIMEType } from 'node-mime-types';
77

8-
import { ConfigService, Database, WaBusiness } from '../../config/env.config';
9-
import { BadRequestException, InternalServerErrorException } from '../../exceptions';
10-
import { RedisCache } from '../../libs/redis.client';
11-
import { NumberBusiness } from '../dto/chat.dto';
8+
import { ConfigService, Database, WaBusiness } from '../../../config/env.config';
9+
import { BadRequestException, InternalServerErrorException } from '../../../exceptions';
10+
import { RedisCache } from '../../../libs/redis.client';
11+
import { NumberBusiness } from '../../dto/chat.dto';
1212
import {
1313
ContactMessage,
1414
MediaMessage,
@@ -22,12 +22,12 @@ import {
2222
SendReactionDto,
2323
SendTemplateDto,
2424
SendTextDto,
25-
} from '../dto/sendMessage.dto';
26-
import { ContactRaw, MessageRaw, MessageUpdateRaw, SettingsRaw } from '../models';
27-
import { RepositoryBroker } from '../repository/repository.manager';
28-
import { Events, wa } from '../types/wa.types';
29-
import { CacheService } from './cache.service';
30-
import { WAStartupService } from './whatsapp.service';
25+
} from '../../dto/sendMessage.dto';
26+
import { ContactRaw, MessageRaw, MessageUpdateRaw, SettingsRaw } from '../../models';
27+
import { RepositoryBroker } from '../../repository/repository.manager';
28+
import { Events, wa } from '../../types/wa.types';
29+
import { CacheService } from './../cache.service';
30+
import { WAStartupService } from './../whatsapp.service';
3131

3232
export class BusinessStartupService extends WAStartupService {
3333
constructor(

0 commit comments

Comments
 (0)