import { Injectable } from '@nestjs/common' ; import { NoticeEntity } from '../entities/notice.entity' ; import { CreateNoticeDto } from '../form/create_notice.dto' ; import { SuccessResponse } from '../../../common/filters/successResponse' ; @ Injectable ( ) export class NoticeService { constructor ( ) { } createNotice ( createNoticeDto , rank , userId ) { return NoticeEntity . createNotice ( createNoticeDto , rank , userId ) ; } getList ( userId , rank ) { return NoticeEntity . getNewNoticeList ( userId , rank ) ; } async setNoticeRead ( noticeId , userId ) { await NoticeEntity . setNoticeRead ( noticeId , userId ) ; return SuccessResponse ; } async setAllNoticeRead ( userId ) { await NoticeEntity . setAllNoticeRead ( userId ) ; return SuccessResponse ; } async deleteNotice ( noticeId , userId ) { await NoticeEntity . deleteNotice ( noticeId , userId ) ; return SuccessResponse ; } }