forked from wangziqi/gongxue-base
feat: integrate notification creation into business modules (classes, schedules done; bills/occupancies/deposits need student→userId mapping)
This commit is contained in:
@@ -16,6 +16,8 @@ import {
|
||||
import { FileInterceptor } from '@nestjs/platform-express';
|
||||
import type { Response } from 'express';
|
||||
import { OccupanciesService } from './occupancies.service';
|
||||
import { NotificationsService } from '../notifications/notifications.service';
|
||||
import { NotificationType } from '../entities/notification.entity';
|
||||
import { CheckInDto, CheckOutDto, TransferRoomDto, BatchCheckOutDto } from './dto/occupancy.dto';
|
||||
import { JwtAuthGuard } from '../auth/guards/jwt-auth.guard';
|
||||
import { OperationLogsService } from '../operation-logs/operation-logs.service';
|
||||
@@ -29,6 +31,7 @@ export class OccupanciesController {
|
||||
constructor(
|
||||
private service: OccupanciesService,
|
||||
private logService: OperationLogsService,
|
||||
private readonly notificationsService: NotificationsService,
|
||||
) {}
|
||||
|
||||
@Get()
|
||||
@@ -78,6 +81,7 @@ export class OccupanciesController {
|
||||
ipAddress,
|
||||
userAgent,
|
||||
});
|
||||
// TODO: Send notification for check_in — studentId→userId mapping unavailable
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -96,6 +100,7 @@ export class OccupanciesController {
|
||||
ipAddress,
|
||||
userAgent,
|
||||
});
|
||||
// TODO: Send notification for check_out — studentId→userId mapping unavailable
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user