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qBAAqB;EAAA,IAAAC,sBAAA;EAA5B,MAAOD,qBAAqB;2BAArBA,qBAAqB;EAAAnC,4GAAA,CAArBmC,qBAAqB;qBAArBA,sBAAqB;EAAA;EAAAnC,4GAAA,CAArBmC,qBAAqB;UAArBA;EAAqB;EAAAnC,4GAAA,CAArBmC,qBAAqB;cAJpBP,yDAAY,CAACS,QAAQ,CAACN,SAAS,CAAC,EAChCH,yDAAY;EAAA;EAAA,OAGbO,qBAAqB;AAAA;;sHAArBA,qBAAqB;IAAAG,YAAA,GALf1C,iFAAwB;IAAA2C,OAAA,GAAAtB,yDAAA;IAAAuB,OAAA,GAE7BZ,yDAAY;EAAA;AAAA","sources":["./src/app/routes/payment-redirect/payment-redirect.component.ts","./src/app/routes/payment-redirect/payment-redirect.component.html","./src/app/routes/payment-redirect/payment-redirect.module.ts"],"sourcesContent":["import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-payment-redirect',\r\n templateUrl: './payment-redirect.component.html',\r\n styleUrls: ['./payment-redirect.component.less'],\r\n})\r\nexport class PaymentRedirectComponent implements OnInit {\r\n constructor(private route: ActivatedRoute) {}\r\n\r\n ngOnInit() {\r\n const token = this.route.snapshot.queryParams.token;\r\n const cardMask = this.route.snapshot.queryParams.cardMask;\r\n const bookingId = this.route.snapshot.queryParams.bookingId;\r\n const paymentNo = this.route.snapshot.queryParams.paymentNo;\r\n const functionId = this.route.snapshot.queryParams.functionId;\r\n const paymentStatus = this.route.snapshot.queryParams.paymentStatus;\r\n const bookingStatus = this.route.snapshot.queryParams.bookingStatus; \r\n\r\n if (token) {\r\n // window.parent.postMessage({token, cardMask}, '*');\r\n // return;\r\n setTimeout(() => {\r\n window.top.postMessage({ token, cardMask }, '*');\r\n // window.opener.postMessage({token, cardMask}, '*');\r\n return;\r\n }, 0);\r\n }\r\n\r\n if (bookingId && paymentStatus) { \r\n setTimeout(() => {\r\n window.top.postMessage({ bookingId, paymentStatus }, '*'); \r\n return;\r\n }, 0);\r\n }\r\n\r\n if (bookingId && paymentNo) { \r\n setTimeout(() => {\r\n window.top.postMessage({ bookingId, paymentNo }, '*'); \r\n return;\r\n }, 0);\r\n }\r\n\r\n if (bookingStatus){\r\n setTimeout(() => {\r\n window.top.postMessage({ bookingStatus }, '*'); \r\n return;\r\n }, 0);\r\n }\r\n\r\n if (functionId) { \r\n setTimeout(() => {\r\n window.top.postMessage({ functionId, paymentNo }, '*'); \r\n return;\r\n }, 0);\r\n }\r\n\r\n // none of them so error\r\n setTimeout(() => {\r\n window.top.postMessage({ 'error': 'processing' }, '*');\r\n // window.opener.postMessage({bookingId, paymentNo}, '*');\r\n return;\r\n }, 0);\r\n }\r\n}\r\n","
\r\n","import { PaymentRedirectComponent } from './payment-redirect.component';\r\nimport { NgModule } from '@angular/core';\r\nimport { RouterModule, Routes, mapToCanActivate } from '@angular/router';\r\nimport { AuthGuardCompleteUser } from '../../shared/auth-guards/auth-guard.service';\r\n\r\nconst appRoutes: Routes = [{ path: '', canActivate: mapToCanActivate([AuthGuardCompleteUser]), component: PaymentRedirectComponent }];\r\n\r\n@NgModule({\r\n declarations: [PaymentRedirectComponent],\r\n imports: [RouterModule.forChild(appRoutes)],\r\n exports: [RouterModule],\r\n providers: [],\r\n})\r\nexport class PaymentRedirectModule {}\r\n"],"names":["PaymentRedirectComponent","_PaymentRedirectComponent","constructor","route","_defineProperty","ngOnInit","token","snapshot","queryParams","cardMask","bookingId","paymentNo","functionId","paymentStatus","bookingStatus","setTimeout","window","top","postMessage","i0","ɵɵdirectiveInject","i1","ActivatedRoute","selectors","decls","vars","consts","template","PaymentRedirectComponent_Template","rf","ctx","ɵɵelement","RouterModule","mapToCanActivate","AuthGuardCompleteUser","appRoutes","path","canActivate","component","PaymentRedirectModule","_PaymentRedirectModule","forChild","declarations","imports","exports"],"sourceRoot":"webpack:///","x_google_ignoreList":[]}