1export const __webpack_id__=7639;export const __webpack_ids__=[7639];export const __webpack_modules__={56559:(n,e,t)=>{t.r(e),t.d(e,{PendingWithdrawals:()=>F,PendingWithdrawalsBare:()=>V,default:()=>z});var a={};t.r(a),t.d(a,{defaultState:()=>N,reducer:()=>p});var o,c=t(63412),i=t.n(c),s=t(74848),r=t(96540),d=t(46792),l=t(84974),u=t(98017),m=t(37489),h=t(45932),f=t.n(h),v=t(57182),_=t(74294),y=t(1932);!function(n){n.SET_DATA="PENDING_WITHDRAWALS:DATA:SET",n.TOGGLE_LOADING="PENDING_WITHDRAWALS:LOADING:TOGGLE",n.SET_IS_CANCEL_IN_PROGRESS="PENDING_WITHDRAWALS:IS_CANCEL_IN_PROGRESS:SET"}(o||(o={}));const N={isCancelInProgress:!1,isLoading:!0,totalAmount:0,transactions:[]},p=n=>(0,y.jM)(((e,t)=>{switch(t.type){case o.TOGGLE_LOADING:case o.TOGGLE_LOADING+n:e.isLoading=t.payload;break;case o.SET_IS_CANCEL_IN_PROGRESS:case o.SET_IS_CANCEL_IN_PROGRESS+n:e.isCancelInProgress=t.payload;break;case o.SET_DATA:case o.SET_DATA+n:Object.assign(e,t.payload)}}),N),{withDynamicReducer:C,useDynamicReducerSelector:w,useDynamicReducerDispatch:S}=(0,_.X)("PendingWithdrawals",a);var I=t(15424),A=t(27411),g=t(45930),x=t(53108),E=t(83312);const P=n=>({type:o.TOGGLE_LOADING,payload:n}),T=n=>({type:o.SET_IS_CANCEL_IN_PROGRESS,payload:n});var D=t(53806),G=function(n,e,t,a){return new(t||(t=Promise))((function(o,c){function i(n){try{r(a.next(n))}catch(n){c(n)}}function s(n){try{r(a.throw(n))}catch(n){c(n)}}function r(n){n.done?o(n.value):function(n){return n instanceof t?n:new t((function(e){e(n)}))}(n.value).then(i,s)}r((a=a.apply(n,e||[])).next())}))};var L=function(n,e,t,a){return new(t||(t=Promise))((function(o,c){function i(n){try{r(a.next(n))}catch(n){c(n)}}function s(n){try{r(a.throw(n))}catch(n){c(n)}}function r(n){n.done?o(n.value):function(n){return n instanceof t?n:new t((function(e){e(n)}))}(n.value).then(i,s)}r((a=a.apply(n,e||[])).next())}))};const b=()=>{const n=(0,A.a)(),{showComponentError:e}=(0,l.zi)(),t=S(),a=(0,x.Z)(),c=(()=>{const n=(0,D.B)();return(0,r.useCallback)((e=>G(void 0,void 0,void 0,(function*(){const{data:t}=yield n(Object.assign({ID:33026,description:"Get Transaction history",responses:[33027,33028]},e));return t}))),[n])})();return(0,r.useCallback)(((...i)=>L(void 0,[...i],void 0,(function*({isSilent:i=!1}={}){!i&&t(P(!0));try{const{payments:{transaction:n=[]}={}}=yield c({status:"Pending",type:"Withdraw",corrections:!0});t((n=>({type:o.SET_DATA,payload:n}))({transactions:n.map((n=>{var e,t,a,o,c,i;if("BankTransferCH"===(null===(e=null==n?void 0:n.method)||void 0===e?void 0:e.code)){const e=null===(o=null===(a=null===(t=n.method)||void 0===t?void 0:t.account[0])||void 0===a?void 0:a.specificParams)||void 0===o?void 0:o.field1;(null===(i=null===(c=n.method)||void 0===c?void 0:c.account[0])||void 0===i?void 0:i.specificParams)&&e&&(n.method.account[0].specificParams.accountId=`*${e.substring(e.length-4)}`)}return n})),totalAmount:n.reduce(((n,e)=>n+e.amount),0)}))}catch(t){n()&&e(a(t))}finally{!i&&n()&&t(P(!1))}}))),[t,n,a,c,e])};var R=function(n,e,t,a){return new(t||(t=Promise))((function(o,c){function i(n){try{r(a.next(n))}catch(n){c(n)}}function s(n){try{r(a.throw(n))}catch(n){c(n)}}function r(n){n.done?o(n.value):function(n){return n instanceof t?n:new t((function(e){e(n)}))}(n.value).then(i,s)}r((a=a.apply(n,e||[])).next())}))};const j="CancelPendingWithdrawalButton__button--2eI",O=({code:n})=>{const e=(0,v.N)(),t=w(f()("isCancelInProgress")),a=(()=>{const n=(0,A.a)(),e=(0,l.NR)(),t=(0,g.i)(),a=S(),o=(0,x.Z)(),c=(0,E.a)(),i=b();return(0,r.useCallback)((s=>R(void 0,[s],void 0,(function*({transactionCode:s}){a(T(!0));try{yield t({transactionCode:s}),c(e("transaction.cancel.success"),{variant:"success"}),n()&&(yield i({isSilent:!0}))}catch(n){c(o(n),{variant:"error"})}finally{n()&&a(T(!1))}}))),[a,n,e,c,o,t,i])})();return(0,s.jsx)(I.$,{className:j,disabled:t,isNew:!0,onClick:()=>a({transactionCode:n}),size:"medium",type:"button",children:e("transaction.cancel")})},W="PendingWithdrawals__totalsContainer--3f7",B="PendingWithdrawals__totalsAmount--1Jr",k="PendingWithdrawals__date--3c5",$="PendingWithdrawals__amount--3-R";var H=function(n,e,t,a){return new(t||(t=Promise))((function(o,c){function i(n){try{r(a.next(n))}catch(n){c(n)}}function s(n){try{r(a.throw(n))}catch(n){c(n)}}function r(n){n.done?o(n.value):function(n){return n instanceof t?n:new t((function(e){e(n)}))}(n.value).then(i,s)}r((a=a.apply(n,e||[])).next())}))};const V=()=>{const n=(0,l.NR)(),e=(0,d.k)(),t=(()=>
1{const n=(0,d.k)(),e=(0,v.N)(),t=w(f()("transactions"));return(0,r.useMemo)((()=>({accordionView:{rows:t.map((t=>{var a,o,c;const{code:i,time:r,amount:d,method:l,fee:u}=t,m=(null===(o=null===(a=null==t?void 0:t.method)||void 0===a?void 0:a.account)||void 0===o?void 0:o.length)&&(null===(c=t.method.account[0])||void 0===c?void 0:c.specificParams)||{},h=(null==m?void 0:m.alias)?`(${null==m?void 0:m.alias})`:"";return{id:i,tableRowId:i,headerCells:[{id:0,content:n.getDateTimeShort(r),className:`${k} accordionHeaderSmallDetails`},{id:1,content:n.formatCurrency(d),className:`${$} accordionHeaderSmallDetails`}],rowCells:[Boolean((null==m?void 0:m.accountId)||h)&&{id:1,content:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"accordionBodyCellName",children:e("transaction.account")}),(0,s.jsx)("div",{className:"accordionBodyCellValue",children:`${(null==m?void 0:m.accountId)||""} ${h}`})]})},(null==l?void 0:l.name)&&{id:2,content:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"accordionBodyCellName",children:e("transaction.method")}),(0,s.jsx)("div",{className:"accordionBodyCellValue",children:l.name})]})},{id:3,content:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"accordionBodyCellName",children:e("transaction.code")}),(0,s.jsx)("div",{className:"accordionBodyCellValue",children:i})]})},"number"==typeof u&&Number(u)>=0&&{id:4,content:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"accordionBodyCellName",children:e("transaction.fee")}),(0,s.jsx)("div",{className:"accordionBodyCellValue",children:n.formatCurrency(u)})]})},{id:5,content:(0,s.jsx)(O,{code:t.code})}].filter(Boolean)}}))}})),[e,t,n])})(),a=b(),{isLoading:o,totalAmount:c}=w(i()(["isLoading","totalAmount"]));return(0,r.useEffect)((()=>{(()=>{H(void 0,void 0,void 0,(function*(){return yield a()}))})()}),[a]),(0,s.jsx)(u.XI,{beforeTableDataContent:(0,s.jsxs)("p",{className:W,children:[(0,s.jsx)("span",{children:n("totals")}),(0,s.jsx)("span",{className:B,children:e.formatCurrency(c)})]}),className:"cms-pending-withdrawals",emptyTitle:n("noTransactions"),isLoading:o,tableData:t,tableRowView:u.ff.ACCORDION})},F=(0,m.m)({isForLoggedIn:!0,tkPrefix:"playtech.mobile.pending-withdrawals."})(C()(V)),z=F}}; 2//# sourceMappingURL=pending-withdrawals.513d556ab2582fe1cf88.chunk.js.map
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.