import { Action } from '@ngrx/store' ; import { type } from './../utils' ; import { CinemaHall , Showtime } from './../models' ; export const ActionTypes = { SELECT_SHOWTIME : type ( "[Booking] Select Showtime" ) , HALL_LOAD : type ( "[Booking] Hall Load" ) , HALL_LOAD_SUCCESS : type ( "[Booking] Hall Load Success" ) , HALL_LOAD_FAIL : type ( "[Booking] Hall Load Fail" ) , SEAT_TOGGLE : type ( "[Booking] Seat Toggle" ) , CLEAR : type ( "[Booking] Clear" ) , } ; export class SelectShowtimeAction implements Action { readonly type = ActionTypes . SELECT_SHOWTIME ; param payload constructor ( public payload ) { } } export class HallLoadAction implements Action { readonly type = ActionTypes . HALL_LOAD ; constructor ( public payload ) { } } export class HallLoadSuccessAction implements Action { readonly type = ActionTypes . HALL_LOAD_SUCCESS ; constructor ( public payload ) { } } export class HallLoadFailAction implements Action { readonly type = ActionTypes . HALL_LOAD_FAIL ; constructor ( public payload ) { } } export class SeatToggleAction implements Action { readonly type = ActionTypes . SEAT_TOGGLE ; param payload constructor ( public payload ) { } } export class ClearAction implements Action { readonly type = ActionTypes . CLEAR ; constructor ( ) { } } export type Actions = SelectShowtimeAction | HallLoadAction | HallLoadSuccessAction | HallLoadFailAction | SeatToggleAction | ClearAction ;