1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[99322],{77974:function(t,e,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/hotel/pg/mobile",function(){return r(32573)}])},32573:function(t,e,r){"use strict";r.r(e),r.d(e,{__N_SSP:function(){return O},default:function(){return C}});var n,o,s=r(67194),i=r(67294),u=r(80795),a=r(11163),l=r(44711),c=r(71720),h=r(72936);function d(t){let{error:e}=t,r=(0,a.useRouter)();return(0,s.BX)(u.kC,{sx:{flexDirection:"column",gap:"8px",justifyContent:"center",alignItems:"center"},children:[(0,s.tZ)(h.Z,{width:"150px",height:"106px",src:"/images/hotel/img/payment-fail.png"}),(0,s.BX)(u.kC,{sx:{flexDirection:"column",gap:"28px"},children:[(0,s.BX)(u.kC,{sx:{flexDirection:"column",gap:"4px"},children:[(0,s.tZ)(u.xv,{sx:{marginTop:"8px",textAlign:"center",variant:"typo.bodyNormal.600",color:"gray12"},children:"ê²°ì ì¤í¨"}),(0,s.tZ)(u.xv,{sx:{textAlign:"center",variant:"typo.bodyNormal2.400",color:"gray12"},children:e.message}),(0,s.BX)(u.xv,{sx:{textAlign:"center",variant:"typo.caption.400",color:"gray12"},children:["(ì¤ë¥ì½ë : ",e.code,")"]})]}),(0,s.tZ)(c.Z,{onClick:()=>{r.push({pathname:"/hotel/reservation",query:{...r.query}})},variant:"outline",sx:{padding:"12px 24px",borderRadius:"999px",border:"1px solid",borderColor:"#D7DADC",variant:"typo.bodyNormal.500"},children:"ë¤ì ìëí기"})]})]})}function p(t){let{error:e}=t,r=(0,a.useRouter)(),n=t=>{r.push({pathname:"NO_ROOM"===t?"/hotel/detail":"/hotel/reservation",query:{...r.query}})};return(0,s.BX)(u.kC,{sx:{flexDirection:"column",gap:"8px",justifyContent:"center",alignItems:"center"},children:[(0,s.tZ)(h.Z,{width:"150px",height:"106px",src:"/images/hotel/img/reservation-fail.png"}),(0,s.BX)(u.kC,{sx:{flexDirection:"column",gap:"28px"},children:[(0,s.BX)(u.kC,{sx:{flexDirection:"column",gap:"4px"},children:[(0,s.tZ)(u.xv,{sx:{marginTop:"8px",textAlign:"center",variant:"typo.bodyNormal.600",color:"gray12"},children:"í¸í
ìì½ì ì¤í¨íììµëë¤."}),(0,s.tZ)(u.xv,{sx:{textAlign:"center",variant:"typo.bodyNormal2.400",color:"gray12"},children:(t=>{switch(t){case"NO_ROOM":return(0,s.BX)(s.HY,{children:["í´ë¹ ê°ì¤ì ìì½ì´ 모ëë§ê°ëììµëë¤. ",(0,s.tZ)("br",{}),"ë¤ë¥¸ ê°ì¤ì ì íí´ ì£¼ì¸ì. ",(0,s.tZ)("br",{})]});case"NOT_ENOUGH_EP":case"SYSTEM_ERROR":return(0,s.BX)(s.HY,{children:["ìì¤í
ì¤ë¥ê° ë°ìíììµëë¤. ",(0,s.tZ)("br",{}),"ê³ ê°ì¼í°ì 문ìí´ ì£¼ì¸ì. ",(0,s.tZ)("br",{})]})}})(e.code)}),(0,s.BX)(u.xv,{sx:{textAlign:"center",variant:"typo.caption.400",color:"gray12"},children:["(ì¤ë¥ì½ë : ",e.code,")"]})]}),(0,s.tZ)(c.Z,{onClick:()=>n(e.code),variant:"outline",sx:{padding:"12px 24px",borderRadius:"999px",border:"1px solid",borderColor:"#D7DADC",variant:"typo.bodyNormal.500"},children:"NO_ROOM"===e.code?"ë¤ë¥¸ ê°ì¤ ì°¾ì보기":"ë¤ì ìì½í기"})]})]})}r(97063),(n=o||(o={})).EASYPAY="1",n.INNOPAY="2",n.NHNKCP="3",n.KIWOOMPAY="4",n.WPAY="5",n.POST_PAY="999";var x=r(48228),y=r(25602),f=r(81667);let m=()=>{let t=(0,y._)();return(0,x.D)({mutationKey:f.l.orderMobileReservationForKCP(),mutationFn:async e=>t.orderMobileHotelReservationForKCP(e),retry:0})},v=()=>{let t=(0,y._)();return(0,x.D)({mutationKey:f.l.orderMobileReservationForWPAY(),mutationFn:async e=>t.orderMobileHotelReservationForWPAY(e),retry:0})},b=()=>{let t=(0,y._)();return(0,x.D)({mutationKey:f.l.orderMobileReservationForInnoPay(),mutationFn:async e=>t.orderMobileHotelReservationForInnoPay(e),retry:0})};function g(t){let{pgData:e,agentInfo:r}=t,n=(0,a.useRouter)(),{mutate:c}=m(),{mutate:h}=v(),{mutate:x}=b(),[y,f]=(0,i.useState)({status:"ì§íì¤",error:null}),g=r.pg_type,R=t=>{if("EXPEDIA"===t.errorType){f({status:"ìì½ì¤í¨",error:t});return}if("PG"===t.errorType){f({status:"ê²°ì ì¤í¨",error:t});return}if(!t.errorType)return sessionStorage.removeItem("booker-info"),n.replace("/hotel/reservation/complete/".concat(t.reservationCode))},O=t=>{console.error("\uD83D\uDEA8SYSTEM_ERROR::",t),f({status:"ìì½ì¤í¨",error:{errorType:"EXPEDIA",code:"SYSTEM_ERROR"}})};return(0,i.useEffect)(()=>
1{if(g===o.NHNKCP&&c(e,{onSuccess:R,onError:O}),g===o.WPAY){let t=n.query.orderNo;h({...e,orderNo:t},{onSuccess:R,onError:O})}if(g===o.INNOPAY){if("3001"!==n.query.ResultCode)return f({status:"ê²°ì ì¤í¨",error:{errorType:"PG",code:n.query.ResultCode,message:n.query.ResultMsg}});x(n.query.MOID,{onSuccess:R,onError:O})}},[]),(0,i.useEffect)(()=>(document.body.style.overflow="hidden",()=>{document.body.style.overflow="auto"}),[]),(0,s.tZ)(u.kC,{sx:{position:"fixed",top:-30,left:0,flexDirection:"column",justifyContent:"center",alignItems:"center",height:"100vh",width:"100vw",background:"white",zIndex:100,overflow:"hidden"},children:(()=>{switch(y.status){case"ì§íì¤":return(0,s.tZ)(l.Z,{});case"ê²°ì ì¤í¨":return(0,s.tZ)(d,{error:y.error});case"ìì½ì¤í¨":return(0,s.tZ)(p,{error:y.error})}})()})}var R=r(26317),O=!0;function C(t){let{pgData:e,agentInfo:r,user:n}=t;return(0,s.tZ)(R.Fb,{travelAgentInfo:r,user:n,children:(0,s.tZ)(g,{pgData:e,agentInfo:r})})}},48228:function(t,e,r){"use strict";r.d(e,{D:function(){return d}});var n=r(67294),o=r(32161),s=r(89886),i=r(30081),u=r(33989);class a extends u.l{constructor(t,e){super(),this.client=t,this.setOptions(e),this.bindMethods(),this.updateResult()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){var e;let r=this.options;this.options=this.client.defaultMutationOptions(t),(0,o.VS)(r,this.options)||this.client.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.currentMutation,observer:this}),null==(e=this.currentMutation)||e.setOptions(this.options)}onUnsubscribe(){if(!this.hasListeners()){var t;null==(t=this.currentMutation)||t.removeObserver(this)}}onMutationUpdate(t){this.updateResult();let e={listeners:!0};"success"===t.type?e.onSuccess=!0:"error"===t.type&&(e.onError=!0),this.notify(e)}getCurrentResult(){return this.currentResult}reset(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})}mutate(t,e){return this.mutateOptions=e,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,{...this.options,variables:void 0!==t?t:this.options.variables}),this.currentMutation.addObserver(this),this.currentMutation.execute()}updateResult(){let t=this.currentMutation?this.currentMutation.state:(0,s.R)(),e={...t,isLoading:"loading"===t.status,isSuccess:"success"===t.status,isError:"error"===t.status,isIdle:"idle"===t.status,mutate:this.mutate,reset:this.reset};this.currentResult=e}notify(t){i.V.batch(()=>{if(this.mutateOptions&&this.hasListeners()){var e,r,n,o,s,i,u,a;t.onSuccess?(null==(e=(r=this.mutateOptions).onSuccess)||e.call(r,this.currentResult.data,this.currentResult.variables,this.currentResult.context),null==(n=(o=this.mutateOptions).onSettled)||n.call(o,this.currentResult.data,null,this.currentResult.variables,this.currentResult.context)):t.onError&&(null==(s=(i=this.mutateOptions).onError)||s.call(i,this.currentResult.error,this.currentResult.variables,this.currentResult.context),null==(u=(a=this.mutateOptions).onSettled)||u.call(a,void 0,this.currentResult.error,this.currentResult.variables,this.currentResult.context))}t.listeners&&this.listeners.forEach(({listener:t})=>{t(this.currentResult)})})}}var l=r(464),c=r(85945),h=r(24798);function d(t,e,r){let s=(0,o.lV)(t,e,r),u=(0,c.NL)({context:s.context}),[d]=n.useState(()=>new a(u,s));n.useEffect(()=>{d.setOptions(s)},[d,s]);let x=(0,l.$)(n.useCallback(t=>d.subscribe(i.V.batchCalls(t)),[d]),()=>d.getCurrentResult(),()=>d.getCurrentResult()),y=n.useCallback((t,e)=>{d.mutate(t,e).catch(p)},[d]);if(x.error&&(0,h.L)(d.options.useErrorBoundary,[x.error]))throw x.error;return{...x,mutate:y,mutateAsync:x.mutate}}function p(){}}},function(t){t.O(0,[46091,80129,87536,17e3,9198,49460,6909,37876,40933,71227,26317,92888,49774,40179],function(){return t(t.s=77974)}),_N_E=t.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.