@@ -49,6 +49,7 @@ import { AccountingResultDto } from "@src/accounting/dto/confirm-accounting.dto"
4949import { toDateFormatWithTimezone } from "@src/global/utils/convert-date" ;
5050import { ko } from "date-fns/locale" ;
5151import { formatInTimeZone } from "date-fns-tz" ;
52+ import { ConfirmDepartureTimeDto } from "@src/pot/dto/confirm-departure-time.pot.dto" ;
5253
5354@Injectable ( )
5455export class PotService {
@@ -593,7 +594,7 @@ export class PotService {
593594 */
594595 async confirmDepartureTime (
595596 potPk : string ,
596- departureTime : Date ,
597+ req : ConfirmDepartureTimeDto ,
597598 userCtx : UserContext ,
598599 ) : Promise < BaseResultDto > {
599600 const pot = await this . getPot ( potPk ) ;
@@ -608,7 +609,7 @@ export class PotService {
608609 {
609610 potRoomPk : potPk ,
610611 userPk : userCtx . userId ,
611- departureTime : departureTime ,
612+ departureTime : req . departure_time ,
612613 } ,
613614 ) ;
614615
@@ -673,22 +674,22 @@ export class PotService {
673674 ) ;
674675
675676 // 출발 확정을 20분 안으로 했을 경우 바로 발송
676- if ( subMinutes ( departureTime , 20 ) < new Date ( ) ) {
677+ if ( subMinutes ( req . departure_time , 20 ) < new Date ( ) ) {
677678 this . popoService . asyncSendPopoChatMsgToPotRoom (
678679 taxiCallPopoChatMsg ,
679680 null ,
680681 pot ,
681682 {
682683 remainDepartureTime : Math . floor (
683- ( departureTime . getTime ( ) - new Date ( ) . getTime ( ) ) / 60000 ,
684+ ( req . departure_time . getTime ( ) - new Date ( ) . getTime ( ) ) / 60000 ,
684685 ) ,
685686 } ,
686687 ) ;
687688 } else {
688689 // departureTime 시간 20분 전 taxi call reminder 메세지 발송 예약
689690 this . popoService . asyncReservePopoChatMsg (
690691 taxiCallPopoChatMsg ,
691- subMinutes ( departureTime , 20 ) ,
692+ subMinutes ( req . departure_time , 20 ) ,
692693 null ,
693694 pot ,
694695 {
@@ -704,7 +705,7 @@ export class PotService {
704705 // departureTime 시간 2시간 후 accounting reminder 메세지 발송 예약
705706 this . popoService . asyncReservePopoChatMsg (
706707 accountingPopoChatMsg ,
707- addHours ( departureTime , 2 ) ,
708+ addHours ( req . departure_time , 2 ) ,
708709 null ,
709710 pot ,
710711 ) ;
0 commit comments