refactor: sepeare user and auth modules

This commit is contained in:
Abdalhamid Alhamad
2024-12-29 14:17:39 +03:00
parent ebf335eabd
commit ca71632755
29 changed files with 59 additions and 55 deletions

View File

@ -1,7 +1,7 @@
import { BadRequestException, forwardRef, Inject, Injectable } from '@nestjs/common';
import { User } from '~/auth/entities';
import { DeviceService } from '~/auth/services';
import { BadRequestException, Injectable } from '@nestjs/common';
import { OciService } from '~/document/services';
import { User } from '~/user/entities';
import { DeviceService } from '~/user/services';
import { UpdateCustomerRequestDto, UpdateNotificationsSettingsRequestDto } from '../dtos/request';
import { Customer } from '../entities';
import { CustomerRepository } from '../repositories/customer.repository';
@ -11,7 +11,7 @@ export class CustomerService {
constructor(
private readonly customerRepository: CustomerRepository,
private readonly ociService: OciService,
@Inject(forwardRef(() => DeviceService)) private readonly deviceService: DeviceService,
private readonly deviceService: DeviceService,
) {}
async updateNotificationSettings(userId: string, data: UpdateNotificationsSettingsRequestDto, deviceId: string) {
const customer = await this.findCustomerById(userId);