@zeniai/web-app-ui 5.3.47-dev → 5.3.48-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/AccountMappingScreen-DeHsC__B.js +9 -0
- package/dist/assets/AddressRoutes-Bh2vRJBa.js +1 -0
- package/dist/assets/AddressScreen-C9Fk_Z55.js +9 -0
- package/dist/assets/AiCfoScreen-DB41E0VN.js +22 -0
- package/dist/assets/{AppDrawer-D4O6tn5i.js → AppDrawer-XdZKck2N.js} +3 -3
- package/dist/assets/{BillPayApprovalRoutes-BY4P9AKu.js → BillPayApprovalRoutes-Dyxgp6fW.js} +1 -1
- package/dist/assets/BillPayRoutes-Bp82WT-5.js +119 -0
- package/dist/assets/BusinessVerificationPageScreen-BT5PhS2R.js +9 -0
- package/dist/assets/CardsAiCfoScreen-CgeqAvem.js +14 -0
- package/dist/assets/ChargeCardRoutes-Ds9toMfJ.js +71 -0
- package/dist/assets/CompanyPassportScreen-B2k7aWUB.js +1 -0
- package/dist/assets/ConnectionAuthScreen-DrhuD992.js +11 -0
- package/dist/assets/CustomerOnboardingAuthScreen-CpbSTPlS.js +1 -0
- package/dist/assets/{CustomerOnboardingRoutes-DV3rYEiJ.js → CustomerOnboardingRoutes-RIeFd0Jj.js} +3 -3
- package/dist/assets/{DashboardRoutes-D5hdkebN.js → DashboardRoutes-DqcCIUfr.js} +4 -4
- package/dist/assets/{DefaultTenantHome-DCPi_wXC.js → DefaultTenantHome-DhG1xEfc.js} +1 -1
- package/dist/assets/DomesticWireDetailScreen-BKq5jjLx.js +18 -0
- package/dist/assets/{DrawerScreen-BihZ_PpN.js → DrawerScreen-DsFB_53j.js} +1 -1
- package/dist/assets/EntityDetailRoutes-mt1xcJ7j.js +1 -0
- package/dist/assets/ExpenseAutomationRoutes-lC_JLdAl.js +38 -0
- package/dist/assets/FeaturePreviewScreen-BFU7MG_7.js +1 -0
- package/dist/assets/HubSpotOAuthCallbackScreen-sKmwa_VW.js +1 -0
- package/dist/assets/InboxNotificationsProvider-CLtB_fgp.js +1 -0
- package/dist/assets/InvoicingRoutes-9v2-NT7u.js +2 -0
- package/dist/assets/MagicLinkRoutes-CXFrKDZN.js +72 -0
- package/dist/assets/MagicLinkSignInScreen-dmwIRx3p.js +12 -0
- package/dist/assets/MobileAppDrawer-cBt39NZW.js +1 -0
- package/dist/assets/NotFoundScreen-DFQDCCRn.js +1 -0
- package/dist/assets/NotificationRoutes-DBx2Hpze.js +1 -0
- package/dist/assets/OAuthConsentScreen-Y007Isid.js +1 -0
- package/dist/assets/PandLWithForecastRoutes-C51wwulq.js +1 -0
- package/dist/assets/{PaymentLinkScreen-B8bPleIr.js → PaymentLinkScreen-DJghRBso.js} +7 -7
- package/dist/assets/PeopleRoutes-Bm7sOBGu.js +22 -0
- package/dist/assets/PerformanceRoutes-BqAferL2.js +1 -0
- package/dist/assets/{Preview-DMLQokX_.js → Preview-BTwrFAaN.js} +1 -1
- package/dist/assets/{QBOConnectionScreen-CWU6DFJl.js → QBOConnectionScreen-UblfZAiA.js} +1 -1
- package/dist/assets/ReimbursementApprovalRoutes-DEDn1IHB.js +1 -0
- package/dist/assets/ReimbursementApprovalRuleDetailScreen-QDei_Fzl.js +1 -0
- package/dist/assets/{ReimbursementRoutes-BdJ3oqBf.js → ReimbursementRoutes-BHG-L5Ik.js} +9 -9
- package/dist/assets/ReportsRoutes-1SHXwblc.js +1 -0
- package/dist/assets/RewardsRoutes-bKzfn6ay.js +1 -0
- package/dist/assets/ScheduleDetailsPrepaidExpensesScreen-CdJ2LE-G.js +25 -0
- package/dist/assets/ScreenRoutes-Bz0Iu7E_.js +2 -0
- package/dist/assets/{SettingsRoutes-BGCz0_nd.js → SettingsRoutes-pgiyjQKt.js} +6 -6
- package/dist/assets/{SetupPagesScreen-DzNRL7Y-.js → SetupPagesScreen-Dzk7fHhk.js} +5 -5
- package/dist/assets/SignInScreen-Rmz1EJ3i.js +1 -0
- package/dist/assets/SignOutScreen-BgL1D0p9.js +9 -0
- package/dist/assets/{TaskListScreen-Br-mxkKM.js → TaskListScreen-BjJ59grh.js} +2 -2
- package/dist/assets/TaskRoutes-cixN3J6B.js +9 -0
- package/dist/assets/TransactionDetailRoutes-B_IKz98q.js +1 -0
- package/dist/assets/{TransactionDetailScreen-Bp7IFDK0.js → TransactionDetailScreen-BzVEfQec.js} +2 -2
- package/dist/assets/TransactionListRoutes-DiO8Bs9p.js +1 -0
- package/dist/assets/{TreasuryRoutes-BvvMozYl.js → TreasuryRoutes-DMo68xKo.js} +6 -6
- package/dist/assets/{VendorsRoutes-DsJ_lcDO.js → VendorsRoutes-DcubMsnX.js} +17 -17
- package/dist/assets/WiseConfirmationScreen-C40X1D6g.js +12 -0
- package/dist/assets/ZeniAccountRoutes-B2XcNL7K.js +57 -0
- package/dist/assets/ZeniAccountStatementScreen-B4EqmylS.js +9 -0
- package/dist/assets/{accountMappingHelper-DqBiQF6x.js → accountMappingHelper-C7mDOec7.js} +1 -1
- package/dist/assets/{analytics-D6GpUSOP.js → analytics-D1aMnBue.js} +1 -1
- package/dist/assets/{analyticsHelper-CwB3kQvw.js → analyticsHelper-BefphWIe.js} +1 -1
- package/dist/assets/{core-B5mDy9pu.js → core-DA_GbUVO.js} +1 -1
- package/dist/assets/{decodeURIComponentSafe-DANuhXnG.js → decodeURIComponentSafe-BeWrvHuJ.js} +1 -1
- package/dist/assets/{dnd-CGWe1ZMP.js → dnd-BVDuXkBA.js} +1 -1
- package/dist/assets/{empty-D0y6rZ_X.js → empty-DkYQEFBR.js} +1 -1
- package/dist/assets/{empty-Dj4ZMRNZ.js → empty-kmkuoqGV.js} +1 -1
- package/dist/assets/{emptyVideoElement-BbYSqu6F.js → emptyVideoElement-Dr5ohcS7.js} +1 -1
- package/dist/assets/epic-DZfUNOLM.js +2 -0
- package/dist/assets/expenseAutomationHelper-4Qy8IF7o.js +1 -0
- package/dist/assets/{getLocaleForTenant-DH5Avx3x.js → getLocaleForTenant-BYa6QBcb.js} +1 -1
- package/dist/assets/{index-BQBXaLiB.js → index-B02Uvg0e.js} +1 -1
- package/dist/assets/{index-8s12XWuB.js → index-BVMI-pAw.js} +1 -1
- package/dist/assets/{index-k1-Pd2Ki.js → index-BqUvSiTi.js} +1 -1
- package/dist/assets/{index-fq0DUtem.js → index-BsYcIz8M.js} +1 -1
- package/dist/assets/{index-CI8tXM3D.js → index-C4n_QrNU.js} +1 -1
- package/dist/assets/{index-G6Wb7pfX.js → index-C5j9ulaE.js} +2 -2
- package/dist/assets/index-CY-CsK5V.js +1 -0
- package/dist/assets/{index-6nH5LMe4.js → index-CsnAk3jU.js} +30661 -31464
- package/dist/assets/{lexical-DW4lC8Zx.js → lexical-Czsku2z1.js} +1 -1
- package/dist/assets/{liveblocks-UOzcPsHa.js → liveblocks-DTaiayIC.js} +2 -2
- package/dist/assets/{lottie-C5eNvt0I.js → lottie-CkYI8upo.js} +1 -1
- package/dist/assets/{mui-Do6nLzGb.js → mui-yMDYeeMr.js} +1 -1
- package/dist/assets/{pathToGoBack-DP_bGWF-.js → pathToGoBack-nmNIndUw.js} +1 -1
- package/dist/assets/{pdf-DjwvAC2g.js → pdf-BIYA0Nfl.js} +3 -3
- package/dist/assets/{pdf-lib-CZXOqgb4.js → pdf-lib-DZGnWz6X.js} +1 -1
- package/dist/assets/{plaid-0g_vwjSd.js → plaid-BtwBxM-6.js} +1 -1
- package/dist/assets/{pusher-BwlPp2s7.js → pusher-8BUSKGPT.js} +1 -1
- package/dist/assets/{react-BsXfT48C.js → react-Bs3cqIIe.js} +1 -1
- package/dist/assets/{react-CU01hiuh.js → react-C6ZyRyfn.js} +1 -1
- package/dist/assets/{react-Bja4MeVO.js → react-CxBgzLVF.js} +1 -1
- package/dist/assets/{react-Dex3foBA.js → react-a48nQACt.js} +1 -1
- package/dist/assets/{react-RZilWHYG.js → react-bpjj59R_.js} +1 -1
- package/dist/assets/{react-DkYBVdJJ.js → react-uoYsSJ7d.js} +1 -1
- package/dist/assets/{recharts-uFX1dZS-.js → recharts-D3wE7yHJ.js} +1 -1
- package/dist/assets/{routePaths-uBvxqlLY.js → routePaths-DeWRBZpS.js} +1 -1
- package/dist/assets/{sentry-DHDsO12F.js → sentry-BRmieicQ.js} +1 -1
- package/dist/assets/{url-CLCy7GPP.js → url-BAbGMJa_.js} +1 -1
- package/dist/assets/{url-BxiN6LKq.js → url-DXDQoAPC.js} +1 -1
- package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-D8KJqvT7.js → useAiCfoDashboardSuggestedQuestionsChips-SoHaFZ4W.js} +1 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-BOgWSkqa.js +1 -0
- package/dist/assets/{useChargeCardPusherEvents-BnH8_thb.js → useChargeCardPusherEvents-C1Fc6NgG.js} +1 -1
- package/dist/assets/{useDeviceId-Bi38IJl0.js → useDeviceId-CZzjV8tQ.js} +1 -1
- package/dist/assets/{useEmailConnectResultRefresh-Ba8t-BuL.js → useEmailConnectResultRefresh-DtruKk0s.js} +1 -1
- package/dist/assets/{useInitialThreadRequest-7Q8HJAH2.js → useInitialThreadRequest-BJ6-q-Ev.js} +1 -1
- package/dist/assets/useTaskManagerAccess-Bm40mz18.js +1 -0
- package/dist/assets/{utils-BsODCDYR.js → utils-UMm0RYR6.js} +1 -1
- package/dist/assets/withTransactionSidePanel-aokrUwcT.js +25 -0
- package/dist/assets/{zeni-epic-state-7eY0g-Bc.js → zeni-epic-state-cafsD4rZ.js} +6 -6
- package/dist/index.html +1 -1
- package/package.json +6 -6
- package/dist/assets/AccountMappingScreen-Euit4Ttk.js +0 -9
- package/dist/assets/ActualMatchingMatchDetailScreen-BBYzjOqh.js +0 -1
- package/dist/assets/AddressRoutes-PvYGzHCA.js +0 -1
- package/dist/assets/AddressScreen-DsGvV3N8.js +0 -9
- package/dist/assets/AiCfoScreen-DAEPn0_B.js +0 -22
- package/dist/assets/BillPayRoutes-CWc4tAqm.js +0 -119
- package/dist/assets/BusinessVerificationPageScreen-CSruI1nV.js +0 -9
- package/dist/assets/CardsAiCfoScreen-COoYscKz.js +0 -14
- package/dist/assets/ChargeCardRoutes-BU6-pfJv.js +0 -71
- package/dist/assets/CompanyPassportScreen-BxoatMVb.js +0 -1
- package/dist/assets/ConnectionAuthScreen-zbcvhPbz.js +0 -11
- package/dist/assets/CustomerOnboardingAuthScreen-8IwDeKdF.js +0 -1
- package/dist/assets/DomesticWireDetailScreen-DgE28aJN.js +0 -18
- package/dist/assets/EntityDetailRoutes-BqX-J3vM.js +0 -1
- package/dist/assets/ExpenseAutomationRoutes-DK-U-YTd.js +0 -38
- package/dist/assets/FeaturePreviewScreen-5SleVFKv.js +0 -1
- package/dist/assets/HubSpotOAuthCallbackScreen-2RxbRDTZ.js +0 -1
- package/dist/assets/InboxNotificationsProvider-BmF5-_KA.js +0 -1
- package/dist/assets/InvoicingRoutes-D0S6fDxY.js +0 -2
- package/dist/assets/MagicLinkRoutes-C22EnpRm.js +0 -72
- package/dist/assets/MagicLinkSignInScreen-BVf-rLEH.js +0 -12
- package/dist/assets/MobileAppDrawer-0YtWXA3B.js +0 -1
- package/dist/assets/NotFoundScreen-BkYIKPgh.js +0 -1
- package/dist/assets/NotificationRoutes-CZQRvVbE.js +0 -1
- package/dist/assets/OAuthConsentScreen-Q7ZDvc1F.js +0 -1
- package/dist/assets/PandLWithForecastRoutes-BzO_OgSq.js +0 -1
- package/dist/assets/PeopleRoutes-D_nqmuPM.js +0 -22
- package/dist/assets/PerformanceRoutes-BW6dixVF.js +0 -1
- package/dist/assets/ReimbursementApprovalRoutes-DAusugdf.js +0 -1
- package/dist/assets/ReimbursementApprovalRuleDetailScreen-phJuB98f.js +0 -1
- package/dist/assets/ReportsRoutes-CDSCG28G.js +0 -1
- package/dist/assets/RewardsRoutes-CHkOPz1g.js +0 -1
- package/dist/assets/ScheduleDetailsPrepaidExpensesScreen-DnVEpQsK.js +0 -33
- package/dist/assets/ScreenRoutes-BYAPWka6.js +0 -2
- package/dist/assets/SignInScreen-BREpWd6T.js +0 -1
- package/dist/assets/SignOutScreen-BNCpbut8.js +0 -9
- package/dist/assets/TaskRoutes-CDuiJExM.js +0 -9
- package/dist/assets/TransactionDetailRoutes-CYb-4jKQ.js +0 -1
- package/dist/assets/TransactionListRoutes-B6NIJUWk.js +0 -1
- package/dist/assets/WiseConfirmationScreen-Bg5_g49N.js +0 -12
- package/dist/assets/ZeniAccountRoutes-C3fDjuMG.js +0 -57
- package/dist/assets/ZeniAccountStatementScreen-CbdRQI0p.js +0 -9
- package/dist/assets/epic-mSW644GG.js +0 -2
- package/dist/assets/expenseAutomationHelper-DBDpSggk.js +0 -1
- package/dist/assets/index-6yt3BfRL.js +0 -1
- package/dist/assets/stripSplatSuffix-CQQXAy0N.js +0 -1
- package/dist/assets/useActualMatchingMatchDetail-OCZsPxr6.js +0 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-BsP5fVhq.js +0 -1
- package/dist/assets/useTaskManagerAccess-BG0Fkj9k.js +0 -1
- package/dist/assets/withTransactionSidePanel-DK-Ex27L.js +0 -25
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import{j as o}from"./liveblocks-
|
|
1
|
+
import{j as o}from"./liveblocks-DTaiayIC.js";import{a as u}from"./sentry-BRmieicQ.js";import{h as N,u as $,i as Y,j as f,l as G,g as H,n as Me,o as k,N as L}from"./core-DA_GbUVO.js";import{U_ as gt,U$ as Xe,QO as et,V0 as vt,fE as U,gZ as ge,V1 as Tt,cE as xt,V2 as bt,EZ as yt,V3 as wt,V4 as oe,V5 as te,V6 as ve,Sn as ue,So as Fe,Fd as pe,Sm as he,F0 as tt,Ez as ke,V7 as It,Sp as J,l_ as me,V8 as Pe,Et as Ct,V9 as Dt,Va as Vt,Vb as je,Vc as _e,Vd as Ae,Ve as Re,F7 as Te,Vf as nt,EQ as at,Vg as Et,Vh as Ft,Vi as kt,Vj as Pt,Vk as jt,Vl as _t,Vm as At,Vn as Rt,BJ as Ut,BR as Lt,BK as Bt,Ru as we,Vo as Ot,Vp as Mt,le as Ie,br as Nt,Vq as Gt,Vr as $t,mY as zt,n5 as Yt,Rt as Ce,bE as Ne,Vs as ot,R4 as st,Vt as Jt,Vu as qt,Vv as Kt,n7 as Ht,Vw as Ge,Vx as $e,Vy as ze,Vz as Ye,VA as Qt,n3 as Wt,VB as Zt,n6 as Xt,VC as en,VD as it,RP as rt,mm as tn,VE as nn,VF as De,VG as dt,RN as lt,Hw as an,VH as on,VI as sn,mG as ct,VJ as rn,VK as dn,R$ as ln,uG as cn,VL as ut,VM as Je,RY as Ve,VN as qe,VO as un,S1 as pn,VP as hn,VQ as mn,VR as fn,VS as Sn,VT as gn,uJ as vn,VU as Tn,Sq as xn,TZ as bn,RG as Ee,i9 as yn,T$ as wn,T_ as In,i7 as Cn,VV as Dn,VW as Vn,HB as En,VX as Fn,VY as kn,VZ as Pn,V_ as jn,mq as _n,bn as An,dY as Rn,dX as Un}from"./zeni-epic-state-cafsD4rZ.js";import{E as Ln,a1 as ne,ab as Ue,M as Q,y as M,z as R,a7 as Bn,aM as On,h as P,Y as Le,r as xe,av as ee,as as se,aN as Mn,aO as pt,aq as Nn,a8 as Se,aP as Gn,p as K,V as $n,G as ht,aQ as zn,ae as mt,a4 as Yn,l as Ke,aR as Jn,J as q,a9 as qn,af as ft,ag as Kn,aS as Hn,aT as Qn,S as Be,aU as Wn,aV as Zn,a3 as Xn,aW as ea,aX as ta}from"./index-CsnAk3jU.js";import{D as na,n as B,S as St}from"./mui-yMDYeeMr.js";import{t as aa,A as oa}from"./AddressScreen-C9Fk_Z55.js";import fe from"./NotFoundScreen-DFQDCCRn.js";import{F as sa}from"./FeaturePreviewScreen-BFU7MG_7.js";import{S as ia,a as ra,J as da,b as la,c as ca}from"./ScheduleDetailsPrepaidExpensesScreen-CdJ2LE-G.js";import{u as ie}from"./useAskAiCfoHostNavButtonProps-BOgWSkqa.js";import{M as re}from"./MobileAppDrawer-cBt39NZW.js";import{v as Oe,c as ua,d as pa}from"./routePaths-DeWRBZpS.js";import{D as ha}from"./DrawerScreen-DsFB_53j.js";import{a as ma,m as fa}from"./accountMappingHelper-C7mDOec7.js";import"./recharts-D3wE7yHJ.js";import"./analytics-D1aMnBue.js";import"./plaid-BtwBxM-6.js";import"./dnd-BVDuXkBA.js";import"./stripe-cKAAJElX.js";import"./lottie-CkYI8upo.js";import"./lexical-Czsku2z1.js";import"./pdf-BIYA0Nfl.js";import"./utils-UMm0RYR6.js";import"./pathToGoBack-nmNIndUw.js";import"./InboxNotificationsProvider-CLtB_fgp.js";import"./useTaskManagerAccess-Bm40mz18.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new e.Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="557883f3-1298-41e2-90a6-574caefbcdf2",e._sentryDebugIdIdentifier="sentry-dbid-557883f3-1298-41e2-90a6-574caefbcdf2")}catch{}})();const Sa={drawerLeftMargin:new Ue(0,0,100,200)},ga=G((function(e,a){const{jeScheduledTransaction:s,selectedJERow:t,scheduleType:n,isVendorBulkUpdateOnTransactionEnabled:i}=a,{scheduleDetailsLocalData:l,updateStatus:p}=Xe(e,a.scheduleType),h=U(e),v=l[n].jeScheduleDetails[t].jeLink,m=v.type==="recommended"?v.recommendedTransactionID:v.transactionDetailID,r=m!=null?Tt(e,m):void 0,d=R.getSignedInUser(),c=e.tenantState.currentTenantId,T={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:h.tenantId??c},x=h?.company?.companyInfo?.firstMonthOfFY??1;return{jeScheduledTransaction:s,transactionDetail:r,localData:l[n].jeScheduleDetails[t],saveStatus:p.fetchState,authParams:T,isVendorBulkUpdateOnTransactionEnabled:i,firstMonthOfFY:x,isDisabled:p.fetchState==="In-Progress"?"readonly":void 0,analytics:P,qboAppUrl:xt(Le.qboRedirectionUrl)}}),(function(e,a){const{selectedJERow:s,jeScheduleDetailId:t,navigate:n}=a;return{onUpdateLocalData:i=>{const l=i.linkJETransaction.qboURL;l!=null&&e(wt({scheduleType:a.scheduleType,jeScheduleDetailId:t,rowId:s,jeLink:l}))},onFetchTransactionClick:i=>{e(et(i))},onSaveClick:()=>{e(yt(a.scheduleType,t))},onBackClick:()=>{n("..",{relative:"path"})},onCancelClick:()=>{const i=a.jeScheduledTransaction.scheduledJournalEntry[s];e(bt({scheduleType:a.scheduleType,jeScheduleDetailId:t,rowId:s,originalScheduledJE:i})),n("..",{relative:"path"})}}}))(On),va=()=>{const e=Ln(),a=N(),s=$(),{scheduleDetailId:t}=Y(),n=ne(),i=Sa.drawerLeftMargin.valuePx(n),{scheduleType:l}=Y(),{useFeatureGate:p}=Q(),{isFeatureEnabled:h}=p(M.isVendorBulkUpdateOnTransactionEnabled),v=gt(l)??"prepaid_expenses",[m,r]=u.useState(!1);if(R.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");if(t==null)throw Error("Invalid Schedule Detail Id");const d=f((b=>Xe(b,v)));u.useEffect((()=>{d.fetchState==="Not-Started"&&a("..",{relative:"path"})}),[]);const c=d.selectedJELinkRowIndex,T=c!=null?d.scheduleDetailsLocalData[v].jeScheduleDetails[c]?.jeLink:null,x=T?.type==="recommended"?T.recommendedTransactionID:T?.transactionDetailID;u.useEffect((()=>{x!=null&&s(et(x))}),[]),u.useEffect((()=>{T?.type==="recommended"&&m===!1&&c!=null&&(r(!0),s(vt({scheduleType:v,jeScheduleDetailId:t,rowId:c})))}));const g=f((b=>U(b))),y=f((b=>ge(b,g.companyId)));return o.jsx(na,{anchor:"right",open:!0,PaperProps:{style:{width:`calc(100% - ${i})`,boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:e.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>a("..",{relative:"path"}),children:o.jsx(Ta,{onClick:b=>b.stopPropagation(),children:d.fetchState!=="Completed"||d.selectedJEScheduleTransaction==null||c==null?o.jsx(Bn,{fetchState:d.fetchState}):o.jsx(ga,{scheduleType:v,jeScheduleDetailId:t,selectedJERow:c,jeScheduledTransaction:d.selectedJEScheduleTransaction,isCOTEnabled:!1,navigate:a,scheduleTab:v,controllerUserDetails:y,isVendorBulkUpdateOnTransactionEnabled:h})})})},Ta=B(St)`
|
|
2
2
|
display: flex;
|
|
3
3
|
min-height: 100%;
|
|
4
4
|
flex-direction: column;
|
|
5
|
-
`,de=e=>{switch(e){case"vendors_tab":return"../summary";case"filing_1099":return"../filing_1099";case"prepaid_expenses":return"../schedules/prepaid_expenses";case"fixed_assets":return"../schedules/fixed_assets";case"accrued_expenses":return"../schedules/accrued_expenses";default:return"../opex"}},le=e=>{switch(e){case"prepaid_expenses":return"prepaid_expenses";case"fixed_assets":return"fixed_assets";case"accrued_expenses":return"accrued_expenses";case"operating_expenses_by_vendor":return"operating_expenses";default:return"vendors_list"}},ce=()=>{const e=
|
|
5
|
+
`,de=e=>{switch(e){case"vendors_tab":return"../summary";case"filing_1099":return"../filing_1099";case"prepaid_expenses":return"../schedules/prepaid_expenses";case"fixed_assets":return"../schedules/fixed_assets";case"accrued_expenses":return"../schedules/accrued_expenses";default:return"../opex"}},le=e=>{switch(e){case"prepaid_expenses":return"prepaid_expenses";case"fixed_assets":return"fixed_assets";case"accrued_expenses":return"accrued_expenses";case"operating_expenses_by_vendor":return"operating_expenses";default:return"vendors_list"}},ce=()=>{const e=H(),a=$(),s=f((t=>oe(t)));return u.useEffect((()=>{const t=e.pathname.split("/").pop();if(t!=null){const n=(i=>{switch(i){case"prepaid_expenses":return"prepaid_expenses";case"fixed_assets":return"fixed_assets";case"accrued_expenses":return"accrued_expenses";case"opex":return"operating_expenses";case"filing_1099":return"filing_1099";default:return"vendors_list"}})(t);n!==s.currentTab&&a(te(n))}}),[e.pathname,s.currentTab,a]),s},W="accrued_expenses",xa=G((function(e,a){const s=U(e),t=oe(e);return{tenantName:s.companyName,vendorTabsToShow:a.vendorTabsToShow,report:a.scheduleListReport,downloadParams:a.downloadParams,companyIncorporationDate:a.companyIncDate,vendorTabView:t,isAccountingClassesEnabled:me(e)}}),(function(e,a){const{navigate:s}=a;return{onBackClick:()=>{s("../../..")},onVendorTabSelectionChanged:t=>{const n=de(t);s(n),e(te(le(t)))},onSortOrderChanged:(t,n)=>{e(Re({scheduleType:W,sortKey:t,sortOrder:n}))},onChangeSubTab:t=>{e(Ae({scheduleType:W,subTab:t}))},onSearchTextChanged:t=>{e(_e({scheduleType:W,searchText:t}))},onReloadReport:()=>{e(tt(W))},onScroll:t=>{e(je({scheduleType:W,scrollYOffset:t}))},onClickNewButton:()=>{e(Dt()),e(Vt()),P.trackScheduleAccruedDetailsNewRequested({scheduleType:"accrued_expenses"}),s("details/new")},onClickSchedule:t=>{e(Ct({selectedJEScheduleKey:t}));const n=a.scheduleListReport.jeAccruedSchedules.find((i=>i.jeAccruedScheduleKey===t));s(`details/${n?.jeScheduleId}`)},updateDownloadStateHandler:t=>{e(Pe({scheduleType:W,fetchState:t}))}}}))(Mn),ba=({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s})=>{const[t,n]=u.useState(!1),[i,l]=u.useState(!1),p=N(),h=$(),{useFeatureGate:v}=Q(),m=xe();ce();const{isFeatureEnabled:r,isFeatureGateLoading:d}=v(M.isOpexByVendorFeatureEnabled),c=R.getSignedInUser(),T=f((S=>U(S))),x={userId:c?.userId??"",sessionId:c?.zeniSessionId??"",tenantId:T.tenantId},g=u.useMemo((()=>({authParams:x,jeScheduleEndPoint:`${ee}/jeScheduleReports`,timezone:ve(),companyName:T.companyName})),[]),[y,b]=u.useState(!1),I=f((S=>ue(S))),V=f((S=>Fe(S,"accrued_expenses"))),C=e.includes("prepaid_expenses"),w=e.includes("fixed_assets"),A=e.includes("accrued_expenses");u.useEffect((()=>{(C||w||A)&&y===!1&&I!=="Completed"&&(h(pe()),b(!0))}),[y]),u.useEffect((()=>{d===!1&&(h(he({shouldFetchAccruedExpenses:A,shouldFetchFixedAssets:!0,shouldFetchPrepaidExpenses:C,shouldFetchOpexByVendor:r,shouldFetchVendorsList:!1,shouldFetchFiling1099Vendor:!1})),n(!0))}),[I,w,d,r]),u.useEffect((()=>{t===!1&&V==="Completed"&&h(tt("accrued_expenses",{selectedTimeframe:ke("accrued_expenses"),selectedCategoryId:"all"},!0))}),[t,V]);const j=f((S=>It(S,W))),{isAiCfoAccessEnabled:O,onAskAiCfoClick:E}=ie({mobileExploreReferrer:"Vendors — Accrued Expenses"});se({isDataReady:j.fetchState==="Completed"});const D=f((S=>J(S).isReportGenerated));f((S=>J(S).fetchState))!=="Completed"||D!==!0||r!==!0||e.includes("operating_expenses_by_vendor")||e.splice(1,0,"operating_expenses_by_vendor"),A||p("../opex");const F=f((S=>ge(S,T.companyId))),z=S=>{l(S)};return o.jsxs(o.Fragment,{children:[o.jsx(re,{isAppContentDrawerOpen:i,handleDrawerToggle:z}),o.jsx(xa,{navigate:p,previousTabPosition:a,setPreviousTabPosition:s,scheduleListReport:j,downloadParams:g,themeState:m,vendorTabsToShow:e,analytics:P,controllerUserDetails:F,isAiCfoAccessEnabled:O,onAskAiCfoClick:E,onClickMenuIcon:()=>z(!0)})]})},Z="fixed_assets",ya=G((function(e,a){const s=U(e),t=oe(e);return{tenantName:s.companyName,vendorTabsToShow:a.vendorTabsToShow,report:a.scheduleListReport,downloadParams:a.downloadParams,companyIncorporationDate:a.companyIncDate,controllerUserDetails:a.controllerUserDetails,vendorTabView:t,isAccountingClassesEnabled:me(e)}}),(function(e,a){const{navigate:s}=a;return{onBackClick:()=>{s("../../..")},onVendorTabSelectionChanged:t=>{const n=de(t);s(n),e(te(le(t)))},onSortOrderChanged:(t,n)=>{e(Re({scheduleType:Z,sortKey:t,sortOrder:n}))},onChangeSubTab:t=>{e(Ae({scheduleType:Z,subTab:t}))},onSearchTextChanged:t=>{e(_e({scheduleType:Z,searchText:t}))},onReloadReport:()=>{e(Te(Z))},onScroll:t=>{e(je({scheduleType:Z,scrollYOffset:t}))},onClickSchedule:t=>{e(at({selectedJEScheduleKey:t}));const n=a.scheduleListReport.jeScheduledTransactions.find((i=>i.jeScheduleTransactionKey===t));s(n?.jeScheduleId==null?"details/new":`details/${n.jeScheduleId}`)},updateDownloadStateHandler:t=>{e(Pe({scheduleType:Z,fetchState:t}))}}}))(pt),wa=({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s})=>{const[t,n]=u.useState(!1),i=N(),l=$();ce();const{useFeatureGate:p}=Q(),h=xe(),{isFeatureEnabled:v,isFeatureGateLoading:m}=p(M.isOpexByVendorFeatureEnabled),r=R.getSignedInUser(),d=f((S=>U(S))),c={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:d.tenantId},T=u.useMemo((()=>({authParams:c,jeScheduleEndPoint:`${ee}/jeScheduleReports`,timezone:ve(),companyName:d.companyName})),[]),[x,g]=u.useState(!1),y=f((S=>ue(S))),b=f((S=>Fe(S,"fixed_assets"))),I=e.includes("prepaid_expenses"),V=e.includes("fixed_assets"),C=e.includes("accrued_expenses");u.useEffect((()=>{(I||V||C)&&x===!1&&y!=="Completed"&&(l(pe()),g(!0))}),[x]),u.useEffect((()=>{m===!1&&(l(he({shouldFetchAccruedExpenses:C,shouldFetchFixedAssets:!0,shouldFetchPrepaidExpenses:I,shouldFetchOpexByVendor:v,shouldFetchVendorsList:!1,shouldFetchFiling1099Vendor:!1})),n(!0))}),[y,V,m,v]),u.useEffect((()=>{t===!1&&b==="Completed"&&l(Te("fixed_assets",{selectedTimeframe:ke("fixed_assets"),selectedCategoryId:"all"},!0))}),[t,b]);const w=f((S=>nt(S,Z))),{isAiCfoAccessEnabled:A,onAskAiCfoClick:j}=ie({mobileExploreReferrer:"Vendors — Fixed Assets"});se({isDataReady:w.fetchState==="Completed"});const O=f((S=>J(S).isReportGenerated));f((S=>J(S).fetchState))!=="Completed"||O!==!0||v!==!0||e.includes("operating_expenses_by_vendor")||e.splice(1,0,"operating_expenses_by_vendor"),V||i("../opex");const E=f((S=>ge(S,d.companyId))),[D,F]=u.useState(!1),z=S=>{F(S)};return o.jsxs(o.Fragment,{children:[o.jsx(re,{isAppContentDrawerOpen:D,handleDrawerToggle:z}),o.jsx(ya,{navigate:i,scheduleListReport:w,downloadParams:T,previousTabPosition:a,setPreviousTabPosition:s,themeState:h,vendorTabsToShow:e,analytics:P,controllerUserDetails:E,isAiCfoAccessEnabled:A,onAskAiCfoClick:j,onClickMenuIcon:()=>{z(!0)}})]})},Ia=B.div`
|
|
6
6
|
display: flex;
|
|
7
7
|
min-height: 100%;
|
|
8
8
|
width: 100%;
|
|
@@ -10,7 +10,7 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
10
10
|
flex-direction: column;
|
|
11
11
|
align-items: center;
|
|
12
12
|
background-color: ${e=>e.theme.colors.grey4};
|
|
13
|
-
`,Ca=
|
|
13
|
+
`,Ca=G((function(e,a){const s=R.getSignedInUser(),t=e.tenantState.currentTenantId,n=U(e),i=n?.companyName??"",l={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:t??""},p=J(e),h=Et(e);return{report:p,uiState:h,isAccountingClassesEnabled:me(e),analytics:P,vendorTabsToShow:a.vendorTabsToShow,downloadParams:{downloadState:h.downloadState,currentTenantCompanyName:i,statementEndPoint:`${ee}/opexByVendor`,authParams:l,timezone:ve()}}}),(function(e,a){const{navigate:s}=a;return{onFetchOpExByVendors:(t,n,i)=>{e(Bt(t,n,i))},onVendorNameAndBalanceClicked:(t,n)=>{if(a.tenantEmailDomain!=null){const i=Oe(t.id,t.qboId,a.tenantEmailDomain,n),l=K(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(i,{state:{pathnameStackToGoBack:l,referrer:"Operating Expenses By Vendor"}})}},onRefresh:()=>{e(Lt())},onReloadReport:()=>{e(Ut(!0))},onBackClick:()=>{s("../../dashboard")},onTimeframeSelectionChanged:t=>{e(Rt(t))},onAdditionalBalanceSelectionChanged:(t,n)=>{e(At({isCompareModeOn:t,additionalBalances:n}))},onSortOrderChanged:(t,n,i)=>{e(_t({sortkey:n,sortOrder:t,timeframe:i}))},onVendorTabSelectionChanged:t=>{const n=de(t);s(n),e(te(le(t)))},onSortOrSearchStarted:t=>{e(jt(t))},onPageFetchStarted:()=>{e(Pt(!0))},updateDownloadStateHandler:t=>{e(kt(t))},onClearSearch:t=>{e(Ft({timeframe:t}))}}}))(Gn);function Da({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s}){const t=N(),n=$(),i=H(),{tenantEmailDomain:l}=Y(),p=ne(),h=R.getSignedInUser(),{useFeatureGate:v}=Q(),{isFeatureEnabled:m,isFeatureGateLoading:r}=v(M.isOpexByVendorFeatureEnabled),d=f((E=>J(E)));if(h==null)throw Error("Can't access opex by vendor page without signing in...");ce();const[c,T]=u.useState(!1),x=f((E=>ue(E))),g=e.includes("prepaid_expenses"),y=e.includes("fixed_assets"),b=e.includes("accrued_expenses"),I=f((E=>oe(E))),{isAiCfoAccessEnabled:V,onAskAiCfoClick:C}=ie({mobileExploreReferrer:"Vendors — Operating Expenses by Vendor"});se({isDataReady:d.fetchState==="Completed"&&d.isReportGenerated===!0});const{areTenantIdsInSync:w}=Nn();u.useEffect((()=>{(g||y||b)&&c===!1&&x!=="Completed"&&w&&(n(pe()),T(!0))}),[c,w]),u.useEffect((()=>{w&&n(he({shouldFetchAccruedExpenses:b,shouldFetchFixedAssets:y,shouldFetchPrepaidExpenses:g,shouldFetchOpexByVendor:m===!0&&r===!1,shouldFetchVendorsList:!1,shouldFetchFiling1099Vendor:!1}))}),[x,y,r,m,w]),d.fetchState!=="Completed"||d.isReportGenerated!==!0||m!==!0||e.includes("operating_expenses_by_vendor")||e.splice(1,0,"operating_expenses_by_vendor"),u.useEffect((()=>{w&&(d.isReportGenerated===!1&&d.fetchState==="Completed"||m===!1&&r===!1)&&t("../summary")}),[w,d.isReportGenerated,d.fetchState,m,r,t]);const[A,j]=u.useState(!1),O=E=>{j(E)};return o.jsxs(Ia,{windowSize:p,children:[d.fetchState==="Completed"?o.jsx(Se,{analytics:P,onLoad:E=>{I.previousTab==null?E.trackVendorOperatingExpensesPageLoaded("Side Panel"):E.trackVendorOperatingExpenses(I.currentTab,I.previousTab??null)}}):null,o.jsx(re,{isAppContentDrawerOpen:A,handleDrawerToggle:O}),o.jsx(Ca,{location:i,navigate:t,previousTabPosition:a,setPreviousTabPosition:s,tenantEmailDomain:l,vendorTabsToShow:e,isAiCfoAccessEnabled:V,onAskAiCfoClick:C,onClickMenuIcon:()=>{O(!0)}})]})}const X="prepaid_expenses",Va=G((function(e,a){const s=U(e),t=oe(e);return{tenantName:s.companyName,vendorTabsToShow:a.vendorTabsToShow,report:a.scheduleListReport,downloadParams:a.downloadParams,companyIncorporationDate:a.companyIncDate,controllerUserDetails:a.controllerUserDetails,vendorTabView:t,isAccountingClassesEnabled:me(e)}}),(function(e,a){const{navigate:s}=a;return{onBackClick:()=>{s("../../..")},onVendorTabSelectionChanged:t=>{const n=de(t);s(n),e(te(le(t)))},onSortOrderChanged:(t,n)=>{e(Re({scheduleType:X,sortKey:t,sortOrder:n}))},onChangeSubTab:t=>{e(Ae({scheduleType:X,subTab:t}))},onSearchTextChanged:t=>{e(_e({scheduleType:X,searchText:t}))},onReloadReport:()=>{e(Te(X))},onScroll:t=>{e(je({scheduleType:X,scrollYOffset:t}))},onClickSchedule:t=>{e(at({selectedJEScheduleKey:t}));const n=a.scheduleListReport.jeScheduledTransactions.find((i=>i.jeScheduleTransactionKey===t));s(n?.jeScheduleId==null?"details/new":`details/${n.jeScheduleId}`)},updateDownloadStateHandler:t=>{e(Pe({scheduleType:X,fetchState:t}))}}}))(pt),Ea=({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s})=>{const[t,n]=u.useState(!1),i=N(),l=$(),{useFeatureGate:p}=Q(),h=xe();ce();const v=R.getSignedInUser(),{isFeatureEnabled:m,isFeatureGateLoading:r}=p(M.isOpexByVendorFeatureEnabled),d=f((S=>U(S))),c=f((S=>Fe(S,"prepaid_expenses"))),T={userId:v?.userId??"",sessionId:v?.zeniSessionId??"",tenantId:d.tenantId},x=u.useMemo((()=>({authParams:T,jeScheduleEndPoint:`${ee}/jeScheduleReports`,timezone:ve(),companyName:d.companyName})),[]),[g,y]=u.useState(!1),b=f((S=>ue(S))),I=e.includes("prepaid_expenses"),V=e.includes("fixed_assets"),C=e.includes("accrued_expenses");u.useEffect((()=>{(I||V||C)&&g===!1&&b!=="Completed"&&(l(pe()),y(!0))}),[g]),u.useEffect((()=>{t===!1&&c==="Completed"&&l(Te("prepaid_expenses",{selectedTimeframe:ke("prepaid_expenses"),selectedCategoryId:"all"},!0))}),[t,c]),u.useEffect((()=>{r===!1&&(l(he({shouldFetchAccruedExpenses:C,shouldFetchFixedAssets:V,shouldFetchPrepaidExpenses:!0,shouldFetchOpexByVendor:m,shouldFetchVendorsList:!1,shouldFetchFiling1099Vendor:!1})),n(!0))}),[b,V,r,m]);const w=f((S=>nt(S,X))),{isAiCfoAccessEnabled:A,onAskAiCfoClick:j}=ie({mobileExploreReferrer:"Vendors — Prepaid Expenses"});se({isDataReady:w.fetchState==="Completed"});const O=f((S=>J(S).isReportGenerated));f((S=>J(S).fetchState))!=="Completed"||O!==!0||m!==!0||e.includes("operating_expenses_by_vendor")||e.splice(1,0,"operating_expenses_by_vendor"),I||i("../opex");const E=f((S=>ge(S,d.companyId))),[D,F]=u.useState(!1),z=S=>{F(S)};return o.jsxs(o.Fragment,{children:[o.jsx(re,{isAppContentDrawerOpen:D,handleDrawerToggle:z}),o.jsx(Va,{navigate:i,previousTabPosition:a,setPreviousTabPosition:s,scheduleListReport:w,downloadParams:x,themeState:h,vendorTabsToShow:e,analytics:P,controllerUserDetails:E,isAiCfoAccessEnabled:A,onAskAiCfoClick:j,onClickMenuIcon:()=>{z(!0)}})]})},Fa=B.div`
|
|
14
14
|
display: flex;
|
|
15
15
|
min-height: 100%;
|
|
16
16
|
width: 100%;
|
|
@@ -18,9 +18,9 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
18
18
|
flex-direction: column;
|
|
19
19
|
align-items: center;
|
|
20
20
|
background-color: ${e=>e.theme.colors.grey4};
|
|
21
|
-
`,
|
|
22
|
-
width: ${
|
|
23
|
-
height: ${
|
|
21
|
+
`,ka=G((function(e,a){const{isFiling1099FeatureEnabled:s,vendorDetailView:t,selectedVendor:n,firstMonthOfFY:i,currentTenant:l,currentUserRoleMap:p}=a,h=R.getSignedInUser(),v={userId:h?.userId??"",sessionId:h?.zeniSessionId??"",tenantId:l.tenantId??""};return{firstMonthOfFY:i,isFiling1099FeatureEnabled:s,vendorDetailView:t,allTransactions:t?.allVendorTransactionsView,allTransactionsTabData:t?.allTransactionsTabData!=null?{timePeriod:Jt(t?.allTransactionsTabData.timePeriod),numberOfQuartersFetched:t?.allTransactionsTabData.numberOfQuartersFetched}:void 0,vendorLogo:n?.logo,readOnlyMode:p?.bookkeeping_user===!0,filesEndPoint:mt.fileMicroServiceBaseUrl,authParams:v,scrollToTrend:a.isTrendPeriodSelected}}),(function(e,a){const{navigate:s,vendorDetailView:t,vendorId:n,defaultTransactionTimePeriod:i,vendorEntity:l,tenantEmailDomain:p,location:h,firstMonthOfFY:v}=a,m=()=>{const r=Yn(h.state?.pathnameStackToGoBack),d=r.poppedPathname??((c=2)=>{let T=c;a.isTrendPeriodSelected===!0&&(T=5);let x="../";for(let g=0;g<T;g++)x=`${x}../`;return x})(1);s(d,{state:{pathnameStackToGoBack:r.newStack}})};return{onSaveVendor:()=>{t!=null&&((r,d)=>{const{vendorId:c,vendorName:T,existingCategory:x,existingClass:g,existingOwner:y,selectedCategory:b,selectedClass:I,selectedOwner:V,isRecommendedCategorySelected:C,isRecommendedClassSelected:w,categoryRecommendationTypeSelected:A,classRecommendationTypeSelected:j}=en(r,d);c!=null&&P.trackVendorDetailsSave(c,T??"",x,g,y,b,I,V,C,w,A,j)})(t?.vendorViewDetails,t?.vendorViewDetails.ownerList),n!=null&&e(Xt(n,void 0))},onVendorSpendTrendFilterTabClick:r=>{e(Zt(r))},saveVendorDetailLocalData:r=>{n!=null&&e(Wt({vendorId:n,localData:r}))},saveContactsInVendorTabDetailLocalData:(r,d)=>{e(Qt({vendorId:r,localData:{contacts:d}}))},onCancelClick:()=>{var r;t?.vendorViewDetails.vendorView?.vendorBasic!=null&&(r=t.vendorViewDetails.vendorView.vendorBasic).id!=null&&P.trackVendorDetailsCancel(r.id??"",r.name,r.account?.accountName,r.class?.className,r.owner?.email),e(Ge()),e($e()),e(ze()),e(Ye()),m()},handleSpendTrendPercentChangeClick:()=>{var r;t?.vendorViewDetails.vendorView?.vendorBasic!=null&&(r=t.vendorViewDetails.vendorView?.vendorBasic,r.id!=null&&P.trackVendorDetailsSpendTrendHotlinkClicked(r.id??"",r.name,r.account?.accountName,r.class?.className,r.owner?.email))},onSaveSuccess:()=>{n!=null&&e(Ht("Not-Started",n)),e(Ge()),e($e()),e(ze()),e(Ye()),m()},onTrendSelectedPeriodChange:r=>{if(r==null)i!=null&&e(we(l,"EntityDetail",{timeframe:"quarter",timePeriod:i}));else{const d=r.currentTimePeriod==null?r.addTimePeriod:{startDate:r.addTimePeriod.startDate,endDate:r.currentTimePeriod.endDate};e(Ce(l,"EntityDetail",{timeframe:r.timeframe,timePeriod:r.addTimePeriod},v)),e(we(l,"EntityDetail",{timeframe:r.timeframe,timePeriod:d}))}},onVendorTabSelectionChanged:r=>{e(Kt(r))},onAddressClick:(r,d)=>{if(p==null)return;const c=pa(p,r,d),T=K(h.state?.pathnameStackToGoBack,h.pathname);s(c,{state:{pathnameStackToGoBack:T}})},onVendorDetailUIChange:r=>{e(qt({collapsableStatus:r}))},onTransactionItemClick:r=>{const d=`${ua(r,p)}`,c=K(h.state?.pathnameStackToGoBack,h.pathname);s(d,{state:{pathnameStackToGoBack:c}})},onLoadPreviousTransactionsClick:(r,d)=>{e(ot({timePeriod:Ie(r),numberOfQuartersFetched:d})),e(st(l,Ie(r),!0,!0))}}}))(zn);function He({referrerType:e,isFiling1099FeatureEnabled:a}){const s=$(),t=H(),n=N(),i=$n(),[l,p]=u.useState(!1),[h,v]=u.useState(!1),[m,r]=u.useState(!1),d=Y(),c=d.vendorId,T=d.qboId,{tenantEmailDomain:x,timeframe:g,startDate:y,endDate:b}=d,I={id:T??"",name:"",type:"vendor",zeniId:c??"",qboId:T??""};u.useEffect((()=>{g!=null&&y!=null&&b!=null?p(!0):(p(!1),m===!1&&(r(!0),s(we(I,"EntityDetail"))))}),[g,y,b]);const V=ne(),C=f((_=>U(_))),w=f((_=>c!=null?Ot(_,c,I):void 0)),A=f((_=>_.vendorState.vendorByID[c??""])),j=f((_=>U(_).company?.companyInfo.firstMonthOfFY??1)),O=f((()=>Mt(j,2))),E=Ie({startDate:O.startDate,endDate:Nt()}),D=Gt(j),F=f((_=>$t(_.trendWithTransactionsState,I,"EntityDetail"))),[z,S]=u.useState(!1),be=l===!1&&m===!1?void 0:F?.selectedPeriod?.timePeriod??D;return u.useEffect((()=>(e==null&&w?.fetchState!=="Not-Started"||c==null||s(zt(c,I)),()=>{e!=null&&c!=null&&s(Yt(c))})),[c,t.state,s]),u.useEffect((()=>{w?.fetchState==="Completed"&&w?.vendorViewDetails.vendorView?.vendorBasic!=null&&((_,ae,ye)=>{_.id!=null&&P.trackVendorDetails(_.id,_.name,ye,_.account?.accountName,_.class?.className,_.owner?.email,ae.percentChange,ae.last30DaysSpend,ae.last90DaysSpend,ae.yearToDateSpend)})(w?.vendorViewDetails.vendorView?.vendorBasic,w?.vendorSpend,e),S(!1)}),[w?.fetchState]),u.useEffect((()=>{if(w?.fetchState==="Completed"&&z===!1){be!=null&&l===!1&&(s(Ce(I,"EntityDetail",{timeframe:F?.selectedPeriod?.timeframe??"quarter",timePeriod:be},j)),S(!0));const _=ht.getLocalizedStrings().dateFormat.analytics;if(l===!0&&g!=null&&y!=null&&b!=null){S(!0);const ae=g,ye={startDate:Ne(y,_.YYYYDashMMDashDDFormat),endDate:Ne(b,_.YYYYDashMMDashDDFormat)};s(Ce(I,"EntityDetail",{timeframe:ae,timePeriod:ye}))}}}),[w?.fetchState,be,F?.selectedPeriod?.timeframe,l,j]),u.useEffect((()=>{w?.fetchState==="Completed"&&h===!1&&(s(ot({timePeriod:E,numberOfQuartersFetched:3})),s(st(I,w.allTransactionsTabData?.timePeriod??E,!1,!0)),v(!0))}),[w?.fetchState,h]),c==null?o.jsx(fe,{}):o.jsx(Fa,{windowSize:V,children:o.jsx(ka,{location:t,navigate:n,isFiling1099FeatureEnabled:a,vendorDetailView:w,vendorId:c,currentTenant:C,selectedVendor:A,firstMonthOfFY:j,isTrendPeriodSelected:l,selectedPeriodTimePeriod:F?.selectedPeriod?.timePeriod,defaultTransactionTimePeriod:D,vendorEntity:I,currentUserRoleMap:i?.loggedInUserRoleMap,tenantEmailDomain:x})})}const Pa=ht.getLocalizedStrings().spendManagement.billPay.vendorCreation.vendorDetails,ja={containerWidth:new Ue(100,58)},_a=B(qn)`
|
|
22
|
+
width: ${q.sp4};
|
|
23
|
+
height: ${q.sp4};
|
|
24
24
|
cursor: pointer;
|
|
25
25
|
color: ${e=>e.theme.colors.brandColorJade};
|
|
26
26
|
`,Aa=B.div`
|
|
@@ -35,20 +35,20 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
35
35
|
flex-direction: column;
|
|
36
36
|
width: ${e=>`${ja.containerWidth.value(e.windowSize)}%`};
|
|
37
37
|
${e=>e.windowSize!=="small"?"overflow: auto;":""}
|
|
38
|
-
`,Ua=
|
|
38
|
+
`,Ua=G((function(e,a){const s=R.getSignedInUser(),t=e.tenantState.currentTenantId,n={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:t??""},i=e.vendorFiling1099UploadDetailsState,l=e.vendorFiling1099UploadDetailsState;let p={fetchState:"Not-Started",error:void 0};return a.vendorId!=null&&(p=e.vendorViewState.editVendorStateById[a.vendorId]?.fetchStatus),{uploadInvoiceEndPoint:`${mt.documentAIMicroServiceBaseUrl}`,vendorFiling1099UploadDetailsState:i,vendorFiling1099UploadDetailsViewState:l,uploadStaus:l.w9FormUploadStatus,authParams:n,billId:a.billId,vendorId:a.vendorId,file:a.file,showAutofill:a.showAutofill,type:a.type,analytics:P,entityId:a.billId,fetchVendorFetchStatus:p,vendorLegalName:a.vendorLegalName}}),(function(e,a){const s=a.vendorId;return{onInvoiceUpload:t=>{if((function(n){return n!=null&&"w9_form"in n})(t)&&(e(on({w9FormFile:t.files[0]})),t.w9_form[0]!=null)){e(sn({ocrData:t.w9_form[0],vendorId:s}));const n=(i=>({street:[i.street.join(" ")],city:i.city,state:i.state,postalCode:i.postal_code,countryCode:i.country_code??void 0,country:i.country??""}))(t.w9_form[0].address);e(ct({addressType:"vendor_address",addressToCreate:n}))}},updateInvoiceUploadFetchState:t=>{e(De({fetchState:t,error:void 0}))},onSkipAutofill:t=>{e(an(t))},onVendorFiling1099UploadDetailsSave:t=>{e(lt(t))},onDeleteClick:()=>{e(De({fetchState:"Not-Started",error:void 0})),e(dt({vendorId:s,w9Documents:[]}))}}}))(Hn);function Qe({appContent:e,showFullScreenSkeletonWhileLoading:a}){const s=$(),t=N(),{vendorId:n}=Y(),i=ne(),l=xe(),p=R.getSignedInUser(),[h,v]=u.useState(!1),{useFeatureGate:m}=Q(),{isFeatureEnabled:r}=m(M.isVendorRecommendationFeatureEnabled),d=f((D=>U(D))).companyName,c=new AbortController,T=c.signal;let x,g,y,b,I;if(n==null)throw new Error("Vendor ID not found for Vendor Filing 1099 Details Screen");x=f((D=>it(D,n))),g=f((D=>D.vendorFiling1099UploadDetailsState.vendor1099DetailsSaveStatus)),y=f((D=>D.vendorViewState.editVendorStateById[n]?.fetchStatus)),I=f((D=>D.vendorFiling1099UploadDetailsState.vendor1099DetailsLocalData.w9Documents?.[0])),b=f((D=>D.vendorFiling1099UploadDetailsState));const V=y?.fetchState==="In-Progress"||b?.w9FormUploadStatus?.fetchState==="In-Progress",C=()=>{l.toggle()};u.useEffect((()=>()=>{c.abort(),s(rt(n))}),[]),u.useEffect((()=>{h||n!=null&&(v(!0),s(tn(!1,n,T)))}),[n]);const w=Ke(y?.fetchState),A=Ke(g?.fetchState),j=x.vendor?.contactIds,O=j?.[j.length-1],E=f((D=>D.contactState.contactById[O]));if(u.useEffect((()=>{n!=null&&w==="In-Progress"&&y?.fetchState==="Completed"&&x?.vendor!=null&&(s(nn(n,x.vendor,E)),x?.vendor.filing1099W9Files?.[0]!=null&&s(De({fetchState:"Completed",error:void 0})))}),[n,x?.vendor]),u.useEffect((()=>{A==="In-Progress"&&g?.fetchState==="Completed"&&t("../../vendors/filing_1099")}),[g?.fetchState]),a===!0&&y?.fetchState!=="Completed"&&y?.fetchState!=="Error")return o.jsx(Na,{children:o.jsx(Jn,{})});if(p==null)throw Error("Can't access VendorFiling1099UploadScreen without signing in...");return o.jsxs(Aa,{windowSize:i,children:[i!=="small"?o.jsxs(Ba,{children:[o.jsx(_a,{onClick:C}),o.jsxs(La,{showContent:p.userEmailDomain==="zeni.ai",children:[o.jsx(Oa,{showAutofill:!1}),o.jsx(Ma,{showAutofill:!1,children:d})]})]}):null,o.jsx(Ua,{vendorId:n,file:I,showAutofill:!1,type:"w9",isVendorRecommendationEnabled:r,pdfTitle:I?Pa.w9FormTitle:void 0,showTitlebar:!0,showTitlebarIcon:!0,vendorLegalName:x?.vendor?.legalName,isLoading:V}),o.jsx(Ra,{windowSize:i,children:e})]})}const La=B.div`
|
|
39
39
|
display: ${e=>e.showContent?"flex":"none"};
|
|
40
40
|
align-items: center;
|
|
41
41
|
`,Ba=B.div`
|
|
42
|
-
margin-bottom: ${
|
|
43
|
-
margin-top: ${
|
|
44
|
-
margin-left: ${
|
|
42
|
+
margin-bottom: ${q.sp3};
|
|
43
|
+
margin-top: ${q.sp3};
|
|
44
|
+
margin-left: ${q.sp8};
|
|
45
45
|
position: absolute;
|
|
46
46
|
display: flex;
|
|
47
47
|
align-items: center;
|
|
48
48
|
`,Oa=B.div`
|
|
49
49
|
width: 1px;
|
|
50
|
-
height: ${
|
|
51
|
-
margin: ${
|
|
50
|
+
height: ${q.sp3};
|
|
51
|
+
margin: ${q.sp0} ${q.sp3};
|
|
52
52
|
background-color: ${e=>e.showAutofill?ft.neutralGrey1Light:e.theme.colors.hero};
|
|
53
53
|
`,Ma=B(Kn.StandardMedium)`
|
|
54
54
|
color: ${e=>e.showAutofill?ft.neutralGrey5Light:e.theme.colors.primary};
|
|
@@ -57,7 +57,7 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
57
57
|
height: 100vh;
|
|
58
58
|
overflow: hidden;
|
|
59
59
|
background-color: ${e=>e.theme.colors.grey4};
|
|
60
|
-
`,
|
|
60
|
+
`,Ga=G((function(e){const a=rn(e);return{vendorDetailView:dn(e),globalMerchantView:a}}),(function(e,a){const{navigate:s}=a;return{updateVendorDetailLocalData:t=>{e(ut({vendorDetails:t}))},fetchRecommendation:t=>{e(cn("tenant",t))},onSaveClick:()=>{e(ln())},onBackClick:()=>{s("../review")}}}))(Qn);function $a(){const e=N();return o.jsx(Ga,{navigate:e})}const za=B.div`
|
|
61
61
|
display: flex;
|
|
62
62
|
min-height: 100%;
|
|
63
63
|
width: 100%;
|
|
@@ -65,11 +65,11 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
65
65
|
flex-direction: column;
|
|
66
66
|
align-items: center;
|
|
67
67
|
background-color: ${e=>e.theme.colors.grey4};
|
|
68
|
-
`,
|
|
68
|
+
`,Ya=G((function(e,a){const{vendorFirstReviewDetails:s}=a,t=e.globalMerchantAutoCompleteState.autoCompleteText,n=R.getSignedInUser(),i=e.tenantState.currentTenantId,l={userId:n?.userId??"",sessionId:n?.zeniSessionId??"",tenantId:i??""},p=U(e);return{vendorFirstReviewView:s,globalMerchantAutoCompleteData:{globalMerchantAutoCompleteView:s.globalMerchantAutoCompleteView,autoCompleteText:t},analytics:P,authParams:l,attachmentEndpoint:p.externalConnections?.accounting[0]?.connectionName==="netsuite"?`${ee}/vendor_attachments_accounting_provider`:`${ee}/vendor_attachments`}}),(function(e,a){const{navigate:s}=a;return{onFetchVendorReviewView:(t,n,i)=>{e(Ve(t,n,i))},onGlobalMerchantAutoCompleteInputChange:(t,n)=>{t.trim().length>=2?e(vn({searchString:t,globalMerchantType:n??"vendor"})):t.trim().length===0&&e(qe())},onUpdateLocalData:(t,n,i,l)=>{if(n!=null){const p=Ja(n);e(gn({vendorId:t,currentSelection:p,selectedGlobalMerchantId:i,vendorRenamedText:l}))}},onResetVendorLocalData:t=>{e(Sn({vendorId:t}))},onVendorNameClick:(t,n)=>{if(a.tenantEmailDomain!=null){const i=Oe(t,n,a.tenantEmailDomain),l=K(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(i,{state:{pathnameStackToGoBack:l}})}},onUpdatePageToken:t=>{e(fn({pageToken:t}))},onUpdateSortUiState:(t,n)=>{e(mn({sortOrder:t,sortKey:n}))},onUpdateScrollYOffset:t=>{e(hn({scrollYOffset:t}))},onClickSave:(t,n,i)=>{e(pn(t,n,i))},onClickCancelPopup:()=>{e(un())},onClearGlobalMerchantAutoCompleteResults:()=>{e(qe())},onClickRedirectToQBO:()=>{window.open(`${Le.qboRedirectionUrl}/vendors`,"_blank")},updateVendorDetailLocalData:t=>{e(ut({vendorDetails:t})),s(`./vendor/${t.id}`)},onBackClick:()=>{s("../..")},onReloadList:()=>{e(Ve(null))}}}))(Wn);function We(){const e=N(),a=$(),s=H(),{tenantEmailDomain:t}=Y(),n=ne(),i=R.getSignedInUser(),{vendorId:l}=Y(),p=f((d=>Je(d))),[h,v]=u.useState(!1),m=f((d=>Je(d).fetchState));if(u.useEffect((()=>{m==="Not-Started"&&h===!1&&(a(Ve(null)),v(!0))}),[]),i==null)throw Error("Can't access first review page without signing in...");const r=d=>d.trackPageLoaded(Be.Event.vendorTenantReviewListPage);return o.jsxs(o.Fragment,{children:[m==="Completed"?o.jsx(Se,{analytics:P,onLoad:r}):null,o.jsx(Se,{analytics:P,onLoad:r}),o.jsx(ha,{isOpen:l!=null,drawerLeftMargin:new Ue(0,0,300,600),onClose:()=>{e("../review")},children:o.jsx(qa,{onClick:d=>d.stopPropagation(),children:o.jsx($a,{})})}),o.jsx(za,{windowSize:n,children:o.jsx(Ya,{location:s,navigate:e,vendorFirstReviewDetails:p,tenantEmailDomain:t})})]})}const Ja=e=>e.recommendedFirst===!0?"recommendedFirst":e.recommendedSecond===!0?"recommendedSecond":e.retain===!0?"retain":e.rename===!0?"rename":e.customMerchant===!0?"customMerchant":null,qa=B(St)`
|
|
69
69
|
display: flex;
|
|
70
70
|
min-height: 100%;
|
|
71
71
|
flex-direction: column;
|
|
72
|
-
`,Ka=
|
|
72
|
+
`,Ka=G((function(e,a){const s=R.getSignedInUser(),t=e.tenantState.currentTenantId,n=e.vendorFiling1099UploadDetailsState,i={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:t??""};let l={fetchState:"Not-Started",error:void 0};return a.vendorId!=null&&(l=e.vendorViewState.editVendorStateById[a.vendorId]?.fetchStatus),{analytics:P,vendorFiling1099UploadDetailsViewState:n,authParams:i,googleAPIKey:Le.googleMapsAPIKey,vendorId:a.vendorId,fetchVendorFetchStatus:l,vendor:a.vendorFiling1099UploadDetails?.vendor}}),(function(e,a){const{currentTenant:s,navigate:t,location:n,vendorId:i,vendorFiling1099UploadDetails:l}=a,{tenantEmailDomain:p}=s;return{onVendorFiling1099UploadDetailsSave:h=>{e(lt(h)),P.trackVendor1099DetailSave(l.vendor.legalName??"")},onSaveChangesToLocalStore:h=>{e(dt(h))},onResetVendorFiling1099FormStatus:()=>{e(Tn())},onAddressEditHandler:h=>{const v=aa((m=>({street:m.vendor1099FilingSectionId.street,suite:m.vendor1099FilingSectionId.suite,city:m.vendor1099FilingSectionId.city,state:m.vendor1099FilingSectionId.state,country:m.vendor1099FilingSectionId.country,countryCode:m.vendor1099FilingSectionId.countryCode,postalCode:m.vendor1099FilingSectionId.postalCode,secondaryInfo:m.vendor1099FilingSectionId.secondaryInfo}))(h));e(ct({addressType:"vendor_address",addressToCreate:v}))},goBackToListPage:()=>{e(rt(i));const h=`/${p}/vendors/filing_1099/`,v=K(n.state?.pathnameStackToGoBack,n.pathname);t(h,{state:{pathnameStackToGoBack:v}})},onAddressClick:h=>{const v=(function(r,d,c){let T=`/${r}/vendors/filing_1099/upload/${c}/edit`;return T=T.concat(`/new/${d}`),T})(p,h,i),m=K(n.state?.pathnameStackToGoBack,n.pathname);t(v,{state:{pathnameStackToGoBack:m}})},AddressFormPage:Xn}}))(Zn);function Ha(){const e=N(),a=H(),{vendorId:s}=Y(),t=f((p=>U(p)));let n;if(s==null)throw new Error("Vendor ID not found for Vendor Filing 1099 Details Screen");n=f((p=>it(p,s)));const{tenantEmailDomain:i}=t,l=t.companyId??R.getSignedInUserTenant(i)?.companyId;if(l==null)throw new Error("Company ID not found for Vendor Filing 1099 Details Screen");return o.jsx(Ka,{location:a,navigate:e,currentTenant:t,vendorId:s,vendorFiling1099UploadDetails:n,companyId:l})}const Qa=B.div`
|
|
73
73
|
display: flex;
|
|
74
74
|
min-height: 100%;
|
|
75
75
|
width: 100%;
|
|
@@ -77,7 +77,7 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
77
77
|
flex-direction: column;
|
|
78
78
|
align-items: center;
|
|
79
79
|
background-color: ${e=>e.theme.colors.grey4};
|
|
80
|
-
`,
|
|
80
|
+
`,Wa=G((function(e,a){const{vendorsFiling1099ListDetails:s,accountMappingView:t,analytics:n}=a;return{analytics:n,vendorsFiling1099List:s.vendors,isVendor1099Populated:s.isVendor1099Populated,accountMappingView:t,fetchState:s.fetchState,uiState:s.uiState,lastRefreshSuccessTime:s.lastRefreshSuccessTime,vendorTabsToShow:a.vendorTabsToShow}}),(function(e,a){const{navigate:s,analytics:t}=a;return{onUpdateSortUiState:(n,i)=>{e(Vn({sortOrder:n,sortKey:i}))},onUpdateSearchUiState:n=>{e(Dn({searchString:n}))},onVendorRowClick:n=>{if(a.tenantEmailDomain!=null){const i=`/${a.tenantEmailDomain}/vendors/filing_1099/upload/${encodeURIComponent(n)}/edit`,l=K(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(i,{state:{pathnameStackToGoBack:l}})}},onReloadVendors:()=>{e(Ee(!0))},onBackClick:()=>{e(In()),e(Cn())},onVendorTabSelectionChanged:n=>{const i=de(n);s(i),e(te(le(n)))},onAccountMappingChange:n=>{const{filing1099:i}=n,{bankAccount:l,expenseCategory1099:p}=i,h=ma(a.accountMappingView.bankAccounts1099FilingAccountList,l.selectedOptions),v=fa(a.accountMappingView.expenseAccounts1099FilingAccountList,p),m={selectedBankAccounts1099FilingAccountIds:h.map((r=>r.accountId)),selectedExpenseAccounts1099FilingAccountIds:v};e(wn({data:m}))},onSaveClick:()=>{e(yn()),t.track(Be.Event.vendor1099TabSettingsSave)}}}))(ea);function Ze({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s}){const t=N(),n=$(),i=H(),{tenantEmailDomain:l}=Y(),p=ne(),h=R.getSignedInUser(),[v,m]=u.useState(!1),[r,d]=u.useState(!1);if(h==null)throw Error("Can't access vendor filing 1099 page without signing in...");ce();const c=f((C=>xn(C))),T=f((C=>bn(C))),{isAiCfoAccessEnabled:x,onAskAiCfoClick:g}=ie({mobileExploreReferrer:"Vendors — 1099"});se({isDataReady:c.fetchState==="Completed"}),u.useEffect((()=>{r||(d(!0),n(Ee(!1)))}),[r,d]),u.useEffect((()=>{T.saveState.fetchState==="Completed"&&n(Ee(!1))}),[T.saveState.fetchState]);const y=C=>{m(C)},b=f((C=>U(C))),I={userId:h?.userId??"",sessionId:h?.zeniSessionId??"",tenantId:b.tenantId},V=u.useMemo((()=>({authParams:I,tenantName:b.companyName,filing1099ReportEndPoint:`${ee}/filing1099Reports`})),[]);return o.jsxs(o.Fragment,{children:[c.fetchState==="Completed"?o.jsx(o.Fragment,{children:o.jsx(Se,{analytics:P,onLoad:()=>P.trackPageLoaded(Be.Event.vendor1099ListPage)})}):null,o.jsxs(Qa,{windowSize:p,children:[o.jsx(re,{isAppContentDrawerOpen:v,handleDrawerToggle:y}),o.jsx(Wa,{location:i,navigate:t,previousTabPosition:a,setPreviousTabPosition:s,analytics:P,vendorsFiling1099ListDetails:c,vendorTypeList:c.vendorTypeList,accountMappingView:T,downloadParams:V,tenantEmailDomain:l,vendorTabsToShow:e,isAiCfoAccessEnabled:x,onAskAiCfoClick:g,onClickMenuIcon:()=>{y(!0)}})]})]})}const Za=B.div`
|
|
81
81
|
display: flex;
|
|
82
82
|
min-height: 100%;
|
|
83
83
|
width: 100%;
|
|
@@ -85,4 +85,4 @@ import{j as o}from"./liveblocks-UOzcPsHa.js";import{a as u}from"./sentry-DHDsO12
|
|
|
85
85
|
flex-direction: column;
|
|
86
86
|
align-items: center;
|
|
87
87
|
background-color: ${e=>e.theme.colors.grey4};
|
|
88
|
-
`,Xa=
|
|
88
|
+
`,Xa=G((function(e,a){const{vendorsListDetails:s}=a;return{vendorsList:s.vendors,totalVendorCount:s.totalVendorCount,fetchState:s.fetchState,uiState:s.uiState,searchText:s.searchString,lastRefreshSuccessTime:s.lastRefreshSuccessTime,vendorTabsToShow:a.vendorTabsToShow,isAccountingClassesEnabled:me(e),analytics:P}}),(function(e,a){const{navigate:s}=a;return{onFetchVendorsList:(t="",n,i)=>{e(_n({searchString:t,keepExistingListItems:n,view:"vendorsTab",pageToken:i}))},onUpdatePageToken:t=>{e(jn({pageToken:t}))},onUpdateSortUiState:(t,n)=>{e(Pn({sortOrder:t,sortkey:n}))},onUpdateCurrentYTDSelection:t=>{e(kn({ytdSpendSelection:t}))},onVendorRowClick:(t,n)=>{if(a.tenantEmailDomain!=null){const i=Oe(t,n,a.tenantEmailDomain),l=K(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(i,{state:{pathnameStackToGoBack:l,referrer:"Vendor List"}})}},onReloadVendors:()=>{console.log("Reload vendors")},onUpdateScrollYOffset:t=>{e(Fn({scrollYOffset:t}))},onBackClick:()=>{s("../..")},onVendorTabSelectionChanged:t=>{const n=de(t);s(n),e(te(le(t)))}}}))(ta);function eo({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s}){const t=N(),n=$(),i=H(),{tenantEmailDomain:l}=Y(),p=ne(),h=R.getSignedInUser(),{useFeatureGate:v}=Q(),{isFeatureEnabled:m,isFeatureGateLoading:r}=v(M.isOpexByVendorFeatureEnabled);ce();const d=e.includes("prepaid_expenses"),c=e.includes("fixed_assets"),T=e.includes("accrued_expenses"),x=f((F=>oe(F)));let g={};g=f((F=>En(F,"vendorsTab")));const[y,b]=u.useState(!1),{isAiCfoAccessEnabled:I,onAskAiCfoClick:V}=ie({mobileExploreReferrer:"Vendors Summary"});se({isDataReady:g.fetchState==="Completed"});const C=f((F=>ue(F))),w=f((F=>J(F).isReportGenerated));f((F=>J(F).fetchState))==="Completed"&&w&&m&&!e.includes("operating_expenses_by_vendor")&&e.splice(1,0,"operating_expenses_by_vendor");const[A,j]=u.useState(!1);if(u.useEffect((()=>{(d||c)&&A===!1&&C!=="Completed"&&(n(pe()),j(!0))}),[A]),u.useEffect((()=>{n(he({shouldFetchAccruedExpenses:T,shouldFetchFixedAssets:c,shouldFetchPrepaidExpenses:d,shouldFetchOpexByVendor:m&&r===!1,shouldFetchVendorsList:!0,shouldFetchFiling1099Vendor:!1}))}),[C,c,r,m]),u.useEffect((()=>{y||g.fetchState!=="Completed"||(b(!0),P.trackVendorList(x.currentTab,x.previousTab??null,g.totalVendorCount,g.uiState.sortKey,g.uiState.ytdSpendSelection))}),[g.fetchState]),h==null)throw Error("Can't access address page without signing in...");const[O,E]=u.useState(!1),D=F=>{E(F)};return o.jsxs(Za,{windowSize:p,children:[o.jsx(re,{isAppContentDrawerOpen:O,handleDrawerToggle:D}),o.jsx(Xa,{location:i,navigate:t,vendorsListDetails:g,tenantEmailDomain:l,vendorTabsToShow:e,onClickMenuIcon:()=>{D(!0)},previousTabPosition:a,setPreviousTabPosition:s,isAiCfoAccessEnabled:I,onAskAiCfoClick:V})]})}function Fo(){const{useFeatureGate:e}=Q(),a=H().state?.referrer,[s,t]=u.useState(!1),[n,i]=u.useState(0),l=R.getSignedInUser(),p=An(l),{isFeatureEnabled:h}=e(M.isOpexByVendorFeatureEnabled),{isFeatureEnabled:v}=e(M.isVendorReviewFeatureEnabled),{isFeatureEnabled:m}=e(M.isScheduledJEPrepaidExpensesFeatureEnabled),{isFeatureEnabled:r}=e(M.isScheduledJEFixedAssetsFeatureEnabled),{isFeatureEnabled:d}=e(M.isScheduledJEAccruedExpensesFeatureEnabled),{isFeatureEnabled:c}=e(M.isFiling1099FeatureEnabled),T=f((V=>U(V))),x=T?.externalConnections?.accounting[0]?.connectionName,g=["vendors_tab"];x!=="netsuite"&&m===!0&&g.push("prepaid_expenses"),x!=="netsuite"&&r===!0&&g.push("fixed_assets"),x!=="netsuite"&&d===!0&&g.push("accrued_expenses"),x!=="netsuite"&&c&&p&&(g.push("filing_1099"),h&&g.splice(1,0,"operating_expenses_by_vendor"));const{isFeatureEnabled:y}=e(M.isDebitCardFeatureEnabled),b=Rn(y,T),I=Un(T);return b===!0||I===!0?o.jsx(Me,{children:o.jsx(k,{path:"/*",element:o.jsx(sa,{})})}):o.jsxs(Me,{children:[o.jsx(k,{path:"/opex",element:h===!0?o.jsx(Da,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../summary"})}),o.jsx(k,{path:"/summary",element:o.jsx(eo,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g})}),o.jsx(k,{path:"schedules/fixed_assets/details/:scheduleDetailId",element:r===!0?o.jsx(ia,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(k,{path:"schedules/accrued_expenses/details/:scheduleDetailId",element:r===!0?o.jsx(ra,{shouldNavigateBack:s,setShouldNavigateBack:t}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(k,{path:"schedules/one_time_accrual/details/:accrualId",element:d===!0?o.jsx(da,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(k,{path:"schedules/:scheduleType/details/:scheduleDetailId",element:m===!0?o.jsx(la,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(k,{path:"schedules/:scheduleType/details/:scheduleDetailId/edit_link",element:m===!0||r===!0?o.jsx(va,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(k,{path:"schedules/accrued_expenses/details/:scheduleDetailId/edit_link",element:d===!0?o.jsx(ca,{setShouldNavigateBack:t}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(k,{path:"schedules/prepaid_expenses",element:m===!0?o.jsx(Ea,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"schedules/fixed_assets",element:r===!0?o.jsx(wa,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"schedules/accrued_expenses",element:d===!0?o.jsx(ba,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"/filing_1099",element:c&&p?o.jsx(Ze,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"/filing_1099/:vendorId",element:c&&p?o.jsx(Ze,{vendorTabsToShow:g,previousTabPosition:n,setPreviousTabPosition:i}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"/filing_1099/upload/:vendorId/edit",element:c&&p?o.jsx(Qe,{appContent:o.jsx(Ha,{}),showFullScreenSkeletonWhileLoading:!0}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"/filing_1099/upload/:vendorId/edit/new/:addressType",element:c&&p?o.jsx(Qe,{appContent:o.jsx(oa,{isSubPage:!0,hideAddressBackButton:!0,hideAddressSubTitle:!0})}):o.jsx(L,{to:"../opex"})}),o.jsx(k,{path:"/summary/:vendorId/:qboId",element:o.jsx(He,{referrerType:a,isFiling1099FeatureEnabled:c&&p})}),o.jsx(k,{path:"/summary/:vendorId/:qboId/:timeframe/:startDate/:endDate",element:o.jsx(He,{referrerType:a,isFiling1099FeatureEnabled:c&&p})}),o.jsx(k,{path:"/review",element:v===!0?o.jsx(We,{}):o.jsx(fe,{})}),o.jsx(k,{path:"/review/vendor/:vendorId",element:v?o.jsx(We,{}):o.jsx(fe,{})}),o.jsx(k,{path:"/",element:o.jsx(L,{to:"summary"})}),o.jsx(k,{path:"*",element:o.jsx(fe,{})})]})}export{Fo as default};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import{j as o}from"./liveblocks-DTaiayIC.js";import{a as f}from"./sentry-BRmieicQ.js";import{t as u,u as h,j as y,N as I}from"./core-DA_GbUVO.js";import{TO as b,gh as w,IR as j}from"./zeni-epic-state-cafsD4rZ.js";import{z as l,a7 as x,af as S,ag as D}from"./index-CsnAk3jU.js";import{n as c}from"./mui-yMDYeeMr.js";import"./recharts-D3wE7yHJ.js";import"./analytics-D1aMnBue.js";import"./plaid-BtwBxM-6.js";import"./dnd-BVDuXkBA.js";import"./stripe-cKAAJElX.js";import"./lottie-CkYI8upo.js";import"./lexical-Czsku2z1.js";import"./pdf-BIYA0Nfl.js";import"./utils-UMm0RYR6.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="41614c2c-2140-4e43-8f7e-1fe006b206d2",e._sentryDebugIdIdentifier="sentry-dbid-41614c2c-2140-4e43-8f7e-1fe006b206d2")}catch{}})();const B=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",g=e.get("profileId")??"",[n,p]=f.useState(!1),a=h(),i=y((m=>b(m))),r=l.getSignedInUser(),d=l.getSignedInUserTenantWithId(s);if(r==null||d==null)return o.jsx(I,{to:"/signin/auth",replace:!0});if(r==null)throw Error("Can't access this page without signing in...");return w(r.userId,r.zeniSessionId,d?.tenantId),f.useEffect((()=>{n||(p(!0),a(j(t,g,s)))}),[n,a]),i.fetchState==="Error"?o.jsx(E,{children:o.jsx(T,{children:i.error?.message??""})}):(i.fetchState==="Completed"&&window.close(),o.jsx(x,{fetchState:"In-Progress"}))},E=c.div`
|
|
2
|
+
display: flex;
|
|
3
|
+
width: 100%;
|
|
4
|
+
height: 100vh;
|
|
5
|
+
flex-direction: row;
|
|
6
|
+
justify-content: center;
|
|
7
|
+
align-items: center;
|
|
8
|
+
background-color: ${e=>e.theme.colors.grey5};
|
|
9
|
+
`,T=c(D.LargeRegular)`
|
|
10
|
+
display: flex;
|
|
11
|
+
color: ${S.important};
|
|
12
|
+
`;export{B as default};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import{j as e}from"./liveblocks-DTaiayIC.js";import{u as M,h as ae,g as W,i as G,j as D,l as te,N as ee,n as Fe,o as C}from"./core-DA_GbUVO.js";import{_A as Re,KJ as Ue,_B as ze,fE as L,F$ as Me,_C as wn,cu as ne,cv as Ve,FV as kn,_D as Dn,_E as In,FY as Sn,G3 as ge,FS as bn,FP as vn,Y7 as le,_F as Pn,Oe as En,W4 as jn,Og as Tn,mH as ve,_G as On,ul as $e,u9 as Ze,my as He,mB as Pe,W5 as Ee,W6 as _n,_H as Bn,mA as Ln,mX as Fn,mp as Rn,kP as Un,kO as zn,_I as Mn,_J as he,NX as Vn,_K as $n,_L as Zn,Yn as ye,_M as je,_N as Hn,Or as Nn,YJ as Wn,LO as Ne,Bx as We,_O as Gn,Oo as Yn,_P as Ge,d9 as xe,Ov as Ye,dX as Je,dY as Ce,Ot as Jn,LI as Kn,Ol as Xn,_Q as Ke,_R as Xe,NZ as qe,O7 as Te,_S as qn,YA as Qn,Ow as ea,bq as na,bJ as aa,cG as ta,bK as oa,bt as sa,Tw as ia}from"./zeni-epic-state-cafsD4rZ.js";import{V as oe,M as Z,y as z,z as b,av as Ae,E as F,a7 as de,cW as ra,a1 as $,ab as Y,a4 as Qe,l as ca,n as Oe,h as O,cX as la,ae as we,cY as da,a8 as ue,cZ as ua,S as ke,bi as N,c_ as pa,aq as ma,as as en,c$ as _e,d0 as ga,p as ce,d1 as ha,ai as fa,d2 as ya,d3 as xa,f as Ca,J as Aa}from"./index-CsnAk3jU.js";import{n as R,D as J,S as K}from"./mui-yMDYeeMr.js";import Q from"./NotFoundScreen-DFQDCCRn.js";import{S as Be}from"./SetupPagesScreen-Dzk7fHhk.js";import{F as nn}from"./FeaturePreviewScreen-BFU7MG_7.js";import{a as m}from"./sentry-BRmieicQ.js";import{M as pe}from"./MobileAppDrawer-cBt39NZW.js";import{A as wa,D as ka,V as Da}from"./DomesticWireDetailScreen-BKq5jjLx.js";import{A as Ia}from"./AddressScreen-C9Fk_Z55.js";import{u as an}from"./useAskAiCfoHostNavButtonProps-BOgWSkqa.js";import{Z as Sa}from"./ZeniAccountStatementScreen-B4EqmylS.js";import"./recharts-D3wE7yHJ.js";import"./analytics-D1aMnBue.js";import"./plaid-BtwBxM-6.js";import"./dnd-BVDuXkBA.js";import"./stripe-cKAAJElX.js";import"./lottie-CkYI8upo.js";import"./lexical-Czsku2z1.js";import"./pdf-BIYA0Nfl.js";import"./utils-UMm0RYR6.js";import"./BusinessVerificationPageScreen-BT5PhS2R.js";import"./routePaths-DeWRBZpS.js";import"./analyticsHelper-BefphWIe.js";import"./InboxNotificationsProvider-CLtB_fgp.js";import"./useTaskManagerAccess-Bm40mz18.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new n.Error().stack;a&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[a]="9f3ca6b0-ba62-4950-9913-4c10568b2403",n._sentryDebugIdIdentifier="sentry-dbid-9f3ca6b0-ba62-4950-9913-4c10568b2403")}catch{}})();const ba=R.div`
|
|
2
|
+
display: flex;
|
|
3
|
+
min-height: 100%;
|
|
4
|
+
width: 100%;
|
|
5
|
+
flex: 1 1 auto;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
align-items: center;
|
|
8
|
+
background-color: ${n=>n.theme.colors.grey4};
|
|
9
|
+
`;function Le({isEditDrawerOpen:n}){const a=F(),[i,t]=m.useState(!1),{autoTransferRulePageProps:o,isLoading:r}=(function({isEditDrawerOpen:d=!1}={}){const c=M(),p=ae(),h=W(),{ruleId:f,tenantEmailDomain:s}=G(),l=oe(),{useFeatureGate:g}=Z(),y=D((u=>Re(u))),A=D((u=>Ue(u.depositAccountState,u.depositAccountListState))),I=D((u=>ze(u))),w=D((u=>L(u))),{isFeatureEnabled:v}=g(z.isTreasuryEnabled),x=y?.fetchState??"Not-Started",k=w?.companyId??(s==null?void 0:b.getSignedInUserTenant(s)?.companyId);m.useEffect((()=>{x==="Not-Started"&&k!=null&&c(Me(!0))}),[c,x,k]);const P=y?.fetchState!=="Completed";if(P)return{autoTransferRulePageProps:void 0,isLoading:P};const _=w?.company!=null&&wn(w.company),E=!!(v&&_),j=ne(l?.loggedInUserRoleMap)||Ve(l?.loggedInUserRoleMap),T=b.getSignedInUser(),B={userId:T?.userId??"",sessionId:T?.zeniSessionId??"",tenantId:w?.tenantId??""},S=!!h.state?.scrollToAddRule;return{isLoading:P,autoTransferRulePageProps:{autoTransferRuleView:y,companyName:w?.companyName??"",hasAdminLevelAccess:j,includeTreasuryOption:E,transferLimit:5e5,authParams:B,currentTenant:w,depositAccountListView:A,downloadAccountDetailEndPoint:`${Ae}/account_details`,editingRuleId:f,isEditDrawerOpen:d,scrollToAddRule:S,zeniAccountsConfigDetail:I,onBackClick:()=>p(".."),onCreateRule:()=>{c(vn())},onUpdateRule:u=>{c(ge(u))},onDeleteClick:u=>{c(bn(u))},onPauseClick:u=>{c(ge(u,!0,!1))},onResumeClick:u=>{c(ge(u,!1,!0))},onActivityClick:(u,V)=>{c(Sn(u,V))},onUpdateRuleLocalData:u=>{c(In(u))},clearRuleLocalData:()=>{c(Dn())},onEditClick:u=>{p(`./${u}/edit`)},onEditDrawerClose:()=>{p("../../",{relative:"path"})},onReviewClick:()=>{c(kn())}}}})({isEditDrawerOpen:n});return r||o==null?e.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:a.colors.grey5}}):e.jsxs(ba,{children:[e.jsx(pe,{isAppContentDrawerOpen:i,handleDrawerToggle:d=>{t(d)}}),e.jsx(ra,{...o})]})}const va={overlayWidth:new Y(100,100,58)},Pa=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:i})=>{const t=M(),o=F(),r=$();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(J,{onClose:()=>{i(!0),t(le())},anchor:"right",open:a,PaperProps:{style:{width:va.overlayWidth.valuePercentage(r),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Ea,{onClick:d=>d.stopPropagation(),children:e.jsx(wa,{vendorIdParam:n,accountContext:"express-pay"})})})},Ea=R(K)`
|
|
10
|
+
display: flex;
|
|
11
|
+
min-height: 100%;
|
|
12
|
+
flex-direction: column;
|
|
13
|
+
`,ja={overlayWidth:new Y(100,100,58)},Ta=({isDrawerOpen:n,closeDrawerHandler:a})=>{const i=M(),t=F(),o=$();if(b.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return e.jsx(J,{onClose:()=>{a(!0),i(le())},anchor:"right",open:n,PaperProps:{style:{width:ja.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:t.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Oa,{onClick:r=>r.stopPropagation(),children:e.jsx(Ia,{accountContext:"express-pay",addressTypeParam:"vendor_address"})})})},Oa=R(K)`
|
|
14
|
+
display: flex;
|
|
15
|
+
min-height: 100%;
|
|
16
|
+
flex-direction: column;
|
|
17
|
+
`,_a={overlayWidth:new Y(100,100,58)},Ba=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:i})=>{const t=M(),o=F(),r=$();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(J,{onClose:()=>{i(!0),t(le())},anchor:"right",open:a,PaperProps:{style:{width:_a.overlayWidth.valuePercentage(r),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(La,{onClick:d=>d.stopPropagation(),children:e.jsx(ka,{vendorIdParam:n,accountContext:"express-pay"})})})},La=R(K)`
|
|
18
|
+
display: flex;
|
|
19
|
+
min-height: 100%;
|
|
20
|
+
flex-direction: column;
|
|
21
|
+
`,Fa=R.div`
|
|
22
|
+
display: flex;
|
|
23
|
+
height: 100vh;
|
|
24
|
+
width: 100%;
|
|
25
|
+
flex: 1 1 auto;
|
|
26
|
+
flex-direction: column;
|
|
27
|
+
align-items: center;
|
|
28
|
+
background-color: ${n=>n.theme.colors.grey4};
|
|
29
|
+
`,Ra=te((function(n,a){const i=L(n),t=b.getSignedInUser(),o=i.tenantId,r={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:o??""},d=a.expressPayDetails,c=n.entityAutoCompleteState.autoCompleteText.common,p=jn(n,"common");return{expressPayDetails:d,fileProps:{authParams:r,filesEndPoint:`${we.fileMicroServiceBaseUrl}`},vendorSearchAutoCompleteData:{autoCompleteText:c,entityAutoCompleteView:p},analytics:a.analytics}}),(function(n,a){const{navigate:i}=a;return{onSaveVendor:t=>{n(zn(t,void 0,void 0,!0))},saveVendorDetailLocalData:(t,o)=>{n(Pe({vendorId:o,localData:t}))},saveExpressPayLocalData:t=>{n(Un({localData:t}))},onVendorSelected:t=>{t!=null&&n(Rn(t,!1))},updateSelectedVendorForCreate:t=>{n(Fn(t))},initializeVendorAddress:()=>{n(Ln())},resetVendorSaveStatus:t=>{n(Bn({vendorId:t}))},vendorSearchAutoCompleteActions:{onAutoCompleteInputChange:(t,o)=>{t.trim().length>=2?n(_n({searchString:t,entityType:o,searchOrigin:"common"})):t.trim().length===0&&n(Ee("common"))},onCancelAutoComplete:()=>{n(Ee("common"))}},chooseNewVendor:t=>{n(Pe({localData:{vendorName:t}}))},onClickAddAccount:t=>{t.method.toLowerCase().indexOf("ach")!==-1?i("./add-ach",{relative:"path"}):t.method.toLowerCase().indexOf("wire")!==-1&&t.method.toLowerCase().indexOf("domestic")!==-1&&i("./add-wire",{relative:"path"})},updateFilesEntity:t=>{n(He({files:t}))},onDeleteFile:t=>{n(Ze(t))},onEditFileName:(t,o)=>{n($e(t,o.split(".")[0]))},onBackClick:t=>{t!=null&&n(ve(t)),n(ve()),n(On()),n(le()),i("../",{relative:"path"})},onSchedulePayment:()=>{n(Tn())}}}))(la);function ie({isAddACHDrawerOpen:n,isAddWireDrawerOpen:a,isAddAddressDrawerOpen:i}){const t=ae(),o=W(),r=M(),[d,c]=m.useState(!1),{tenantEmailDomain:p}=G(),h=oe(),f=D((u=>u.expressPayState.fetchState)),s=D((u=>L(u))),l=D((u=>Pn(u))),g=l.expressPayLocalData?.vendorId,y=s.companyId??b.getSignedInUserTenant(p)?.companyId,[A,I]=m.useState(!1),[w,v]=m.useState(!1),[x,k]=m.useState(!1),P=Qe(o.state?.pathnameStackToGoBack),{poppedPathname:_}=P,E=_?.split("/"),j=E?.[E.length-1];m.useEffect((()=>{n===!0?I(!0):(I(!1),document.body.style.overflow="auto")}),[n]),m.useEffect((()=>{a===!0?v(!0):(v(!1),document.body.style.overflow="auto")}),[a]),m.useEffect((()=>{i===!0?k(!0):(k(!1),document.body.style.overflow="auto")}),[i]),m.useEffect((()=>{f==="Not-Started"&&r(En(!0,!0))}),[f,r]);const T=ca(l.vendorViewDetails.bankAccountCreationState?.fetchState);if(m.useEffect((()=>{T==="In-Progress"&&l.vendorViewDetails.bankAccountCreationState?.fetchState==="Completed"&&S()}),[T,l.vendorViewDetails.bankAccountCreationState?.fetchState]),b.getSignedInUser()==null)throw Error("Can't access express pay page without signing in...");const B=u=>{c(u)},S=()=>{I(!1),v(!1),t("../",{relative:"path"})};return e.jsxs(Fa,{children:[Oe(o)?e.jsx(pe,{isAppContentDrawerOpen:d,handleDrawerToggle:B}):null,A===!0?e.jsx(Pa,{vendorId:g,closeDrawerHandler:S,isDrawerOpen:A}):null,w===!0?e.jsx(Ba,{vendorId:g,closeDrawerHandler:S,isDrawerOpen:w}):null,x===!0?e.jsx(Ta,{closeDrawerHandler:S,isDrawerOpen:x}):null,e.jsx(Da,{vendorId:g,isExpressPayPage:!0}),e.jsx(Ra,{navigate:t,location:o,companyId:y,accountId:j,analytics:O,currentTenant:s,vendorId:g,roleMap:h?.loggedInUserRoleMap,isSettings:Oe(o),expressPayDetails:l,onClickMenuIcon:()=>{B(!0)}})]})}const Ua={overlayWidth:new Y(100,100,58)},za=({authParams:n,downloadAccountDetailEndPoint:a,isAccountInfoDrawerOpen:i,zeniBankAccountDetail:t,closeDrawerHandler:o})=>{const r=F(),d=$(),c=D((s=>ze(s))),p=D((s=>L(s)));if(b.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");const h=()=>{o(!0)},f={depositAccount:t,onDismissClick:h,zeniAccountsConfigDetail:c,authParams:n,downloadAccountDetailEndPoint:a,currentTenant:p};return e.jsx(J,{anchor:"right",open:i,PaperProps:{style:{width:Ua.overlayWidth.valuePercentage(d),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:r.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>h(),children:e.jsx(Ma,{onClick:s=>s.stopPropagation(),children:e.jsx(da,{...f})})})},Ma=R(K)`
|
|
30
|
+
display: flex;
|
|
31
|
+
min-height: 100%;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
`,Va={overlayWidth:new Y(100,100,58)},tn=({isCheckDepositDrawerOpen:n,closeDrawerHandler:a})=>{const i=F(),t=$(),o=M(),r=D((s=>L(s))),d=b.getSignedInUser(),c=r.tenantId,p={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c??""};if(d==null)throw Error("Can't access check deposit page without signing in...");const h=D((s=>Mn(s))),f={analytics:O,checkDeposit:h,filesEndPoint:`${we.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:s=>{o($n(s))},updateFilesEntity:s=>{o(He({files:s}))},onAnotherTransferClick:()=>{o(he())},onDeleteFile:s=>{o(Ze(s))},onEditFileName:(s,l)=>{o($e(s,l.split(".")[0]))},onCheckDpositClick:()=>{o(Vn())},onDismissClick:()=>{a(!0),o(he())}};return e.jsxs(e.Fragment,{children:[e.jsx(ue,{analytics:O,onLoad:s=>(l=>l.trackPageLoaded(ke.Event.accountsDepositCheckFormViewed))(s)}),e.jsx(J,{anchor:"right",open:n,PaperProps:{style:{width:Va.overlayWidth.valuePercentage(t),boxShadow:"none",zIndex:8}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:(s,l)=>(l==="backdropClick"||l==="escapeKeyDown")&&(a(!0),void o(he())),children:e.jsx($a,{onClick:s=>s.stopPropagation(),children:e.jsx(ua,{...f})})})]})},$a=R(K)`
|
|
34
|
+
display: flex;
|
|
35
|
+
min-height: 100%;
|
|
36
|
+
flex-direction: column;
|
|
37
|
+
`,Za={overlayWidth:new Y(100,100,58)},Ha=te((function(n,a){const i=a.currentTenant?.companyId;return{plaidConnectionDetails:Wn(n,i,"zeni_accounts","external_account").plaidConnectionDetails,depositAccountListView:Ue(n.depositAccountState,n.depositAccountListState)}}),(function(n,a){return{onReviewClick:()=>n(Yn()),clearReviewTransferDetail:()=>n(Gn()),onFetchLinkTokenClick:i=>{n(We("external_account",i))},onEstablishConnectionClick:i=>{n(Ne(i,a.currentTenant?.companyId,"external_account",void 0,"link_external_account"))}}}))(pa),on=({isTransferDrawerOpen:n,authParams:a,downloadAccountDetailEndPoint:i,closeDrawerHandler:t,zeniAccountsConfig:o})=>{const r=D((x=>Zn(x))),d=D((x=>L(x))),c=F(),p=$(),h=M(),{accountId:f}=G(),[s,l]=m.useState("achTransfer"),[g,y]=m.useState(!1);if(b.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const{useDynamicConfig:A}=Z(),{configValue:I}=A(N.zeniAccountsConfig),w=ye(I),v=()=>{t(!0),h(je())};return m.useEffect((()=>{r.reviewTransferDetail.fetchState==="Completed"&&y(!0)}),[y,r.reviewTransferDetail.fetchState]),e.jsxs(e.Fragment,{children:[e.jsx(ue,{analytics:O,onLoad:x=>(k=>k.trackPageLoaded(ke.Event.zeniAccountsTransferFormViewed))(x)}),e.jsx(J,{onClose:()=>{(s==="achTransfer"&&g===!1||s==="achTransfer"&&g&&r.fetchState==="Completed")&&v()},anchor:"right",open:n,PaperProps:{style:{width:Za.overlayWidth.valuePercentage(p),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:c.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Na,{onClick:x=>x.stopPropagation(),children:e.jsx(Ha,{analytics:O,transferDetails:r,authParams:a,downloadAccountDetailEndPoint:i,onTransferClick:()=>{O.trackTransferBetweenAccountsFormClicked("Transfer",r.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning?"Review Split Transfer":"Review Transfer",r.transferDetailLocalData.transferFrom?.label,r.transferDetailLocalData.transferTo?.label,r.transferDetailLocalData.amount.amount,r.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning,r.reviewTransferDetail.reviewTransferMoney.transferSchedules.length,r.transferDetailLocalData.transferFrom?.accType==="paymentAccount"&&r.transferDetailLocalData.transferTo?.accType==="depositAccount"&&o.zeniAccountsConfigDetail.depositProductConfig.depositProducts?.[0].range?.[1]!=null&&r.transferDetailLocalData.amount.amount>o.zeniAccountsConfigDetail.depositProductConfig.depositProducts[0].range[1]),h(Nn(f))},onDismissClick:v,onSaveChangesToLocalStore:x=>{h(Hn(x))},onAnotherTransferClick:()=>{y(!1),h(je())},currentTenant:d,zeniAccountsConfigDetail:o,currentDrawerContent:s,setCurrentDrawerContent:l,showReviewContent:g,setShowReviewContent:y,onBackClick:()=>{},maxInsuredAmount:w.maxInsuredAmount})})})]})},Na=R(K)`
|
|
38
|
+
display: flex;
|
|
39
|
+
min-height: 100%;
|
|
40
|
+
flex-direction: column;
|
|
41
|
+
`,Wa=R.div`
|
|
42
|
+
display: flex;
|
|
43
|
+
min-height: 100%;
|
|
44
|
+
width: 100%;
|
|
45
|
+
flex: 1 1 auto;
|
|
46
|
+
flex-direction: column;
|
|
47
|
+
align-items: center;
|
|
48
|
+
background-color: ${n=>n.theme.colors.grey4};
|
|
49
|
+
`,Ga=te((function(n,a){return{zeniAccountListView:Ge(n),isExpressPayEnabled:a.isExpressPayEnabled,analytics:a.analytics}}),(function(n,a){const{navigate:i,currentTenant:t,location:o,companyId:r,handleDrawerToggle:d,analytics:c,isBillPayEnabled:p,isDebitCardFeatureEnabled:h}=a,{tenantEmailDomain:f}=t;return{onZeniAccountClick:(s,l)=>{c.trackAccountsListPageClicked("Accounts Row Item Click",l,"active");const g=Ya(f,s),y=ce(o.state?.pathnameStackToGoBack,o.pathname);i(g,{state:{pathnameStackToGoBack:y}})},onSettingsClick:()=>{c.trackAccountsListPageClicked("Settings Icon"),i("setup")},onReloadTransactions:()=>{n(Ye(!1))},handleMoveMoneyOptionSelection:(s,l)=>{let g="page-not-found";s==="sendMoney"&&(g=ln(f)),s==="payBill"?g=sn(t,p,h):s==="transfer"?(g=rn(f),l!=null&&n(Ke(l))):s==="checkDeposit"&&(g=cn(f));const y=ce(o.state?.pathnameStackToGoBack,o.pathname);i(g,{state:{pathnameStackToGoBack:y}})},unlinkPaymentAccount:(s,l)=>{c.trackAccountsListPageClicked("Unlink Account",l),n(Xn(s))},onFetchLinkTokenClick:(s,l)=>{n(We("external_account",s,l))},onUpdatePaymentAccountStatus:(s,l,g)=>{n(Kn(s,l,"zeni_accounts","external_account",g))},onEstablishConnectionClick:s=>{n(Ne(s,r,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:s=>{n(Jn(s))},onClickMenuIcon:()=>{d(!0)},onAutoTransferClick:s=>{const l="./auto-transfer";s?i(l,{state:{...o.state,scrollToAddRule:!0}}):i(l)}}}))(ga);function fe({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a}){const i=W(),t=ae(),o=M(),r=$(),{tenantEmailDomain:d}=G(),{useDynamicConfig:c,useFeatureGate:p}=Z(),h=F(),{configValue:f}=c(N.zeniAccountsConfig),{isFeatureEnabled:s}=p(z.isDebitCardFeatureEnabled),{isFeatureEnabled:l}=p(z.isAutoTransferRuleEnabled),{isFeatureEnabled:g}=p(z.isCheckingCommentingEnabled),y=ye(f),A=D((U=>L(U))),I=A.companyId??b.getSignedInUserTenant(d)?.companyId,{configValue:w}=c(N.expressPayConfig),v=w.is_enable_all_tenants===!0||w.tenant_ids!=null&&w.tenant_ids.includes(A.tenantId),[x,k]=m.useState(!1),[P,_]=m.useState(!1),[E,j]=m.useState(!1),[T,B]=m.useState(!1),S=D((U=>Ge(U))),u=S.fetchState,V=D((U=>Re(U))),X=V?.fetchState??"Not-Started",me=!!A.companyZeniAccountInfo?.info?.isZeniAccountEnabled,se=oe(),H=!!A.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,q=ne(se?.loggedInUserRoleMap),dn=xe(se?.loggedInUserRoleMap),un=!!A.companyBillPayInfo?.info?.isBillPayEnabled,De=b.getSignedInUser(),pn={userId:De?.userId??"",sessionId:De?.zeniSessionId??"",tenantId:A.tenantId??""},mn=`${Ae}/account_details`,{areTenantIdsInSync:Ie}=ma();m.useEffect((()=>{!x&&Ie&&(k(!0),o(Ye(!1)))}),[x,o,u,Ie]),m.useEffect((()=>{!P&&X==="Not-Started"&&I&&(_(!0),o(Me(!0)))}),[P,X,I,o]),m.useEffect((()=>{n!=null&&n===!0?j(!0):(j(!1),document.body.style.overflow="auto")}),[n]),m.useEffect((()=>{B(a!=null&&a===!0)}),[a]);const Se=()=>{j(!1),t("..")},[gn,hn]=m.useState(!1),be=U=>{hn(U)},{isAiCfoAccessEnabled:fn,onAskAiCfoClick:yn}=an({mobileExploreReferrer:"Checking Accounts"});en({isDataReady:u==="Completed"});const xn=Je(A),Cn=Ce(s,A);return xn===!0&&Cn!==!0?e.jsx(nn,{}):me?e.jsxs(e.Fragment,{children:[S.fetchState==="Completed"&&E===!1&&T===!1?e.jsx(ue,{analytics:O,onLoad:U=>(An=>{An.trackAccountsListPageViewed(S.depositAccountsSelectorView.depositAccounts.length,S.externalAccountsSelectorView.paymentAccounts.length,_e(S.summary?.totalBalance.available.amount??0),_e(S.summary?.totalInterest.available.amount??0),S.zeniAccountsConfig.zeniAccountsConfigDetail.annualPercentageYield)})(U)}):null,E===!0?e.jsx(on,{closeDrawerHandler:Se,isTransferDrawerOpen:E,zeniAccountsConfig:S.zeniAccountsConfig,authParams:pn,downloadAccountDetailEndPoint:mn}):null,T===!0?e.jsx(tn,{closeDrawerHandler:Se,isCheckDepositDrawerOpen:T}):null,e.jsxs(Wa,{windowSize:r,children:[e.jsx(pe,{isAppContentDrawerOpen:gn,handleDrawerToggle:be}),e.jsx(Ga,{zeniBankListView:S,navigate:t,currentTenant:A,location:i,companyId:I,analytics:O,maxInsuredAmount:y.maxInsuredAmount,isExpressPayEnabled:v,isBillPayEnabled:un,isCheckingCommentingEnabled:g,isDebitCardFeatureEnabled:s,isAutoTransferRuleEnabled:l,handleDrawerToggle:be,isAiCfoAccessEnabled:fn,onAskAiCfoClick:yn})]})]}):H&&q?e.jsx(ee,{to:"../setup"}):A.companyZeniAccountInfo?.info&&!H&&dn?e.jsx(ee,{to:"../promo",state:i.state}):e.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:h.colors.grey5}})}const sn=(n,a,i)=>{const t=Ce(i,n),{tenantEmailDomain:o}=n;return t===!0||a===!1?`/${o}/bills`:`/${o}/bill/new`},Ya=(n,a)=>`/${n}/checking/${a}`,rn=(n,a)=>a==null?`/${n}/checking/transfer`:`/${n}/checking/${a}/transfer`,cn=(n,a)=>a==null?`/${n}/checking/check-deposit`:`/${n}/checking/${a}/check-deposit`,ln=n=>`/${n}/checking/express-pay`,Ja=R.div`
|
|
50
|
+
display: flex;
|
|
51
|
+
width: 100%;
|
|
52
|
+
flex: 1 1 auto;
|
|
53
|
+
flex-direction: column;
|
|
54
|
+
align-items: center;
|
|
55
|
+
min-height: 100vh;
|
|
56
|
+
background-color: ${n=>n.theme.colors.grey4};
|
|
57
|
+
`,Ka=te((function(n,a){const{currentTenant:i}=a,t=Xe(n,a.accountId),o=b.getSignedInUser(),r=n.tenantState.currentTenantId,d={userId:o?.userId??"",sessionId:o?.zeniSessionId??"",tenantId:r??""},c=t.accountDetail?.id??"";return{currentTenantCompanyName:i.companyName??"",authParams:d,downloadEndPoint:`${we.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${c}`,zeniAccountDetail:t,isExpressPayEnabled:a.isExpressPayEnabled,fetchState:t.fetchState}}),(function(n,a){const{navigate:i,currentTenant:t,location:o,accountId:r}=a,{tenantEmailDomain:d}=t;return{handleMoveMoneyOptionSelection:(c,p)=>{let h="page-not-found";c==="sendMoney"?h=ln(d):c==="payBill"?h=sn(t,a.isBillPayEnabled,a.isDebitCardFeatureEnabled):c==="transfer"?(h=rn(d,r),p!=null&&n(Ke(p))):c==="checkDeposit"?(h=cn(d,r),p!=null&&n(qn(p))):c==="accountStatement"&&(h=qa(d,r));const f=ce(o.state?.pathnameStackToGoBack,o.pathname);i(h,{state:{pathnameStackToGoBack:f}})},onAccountDetailClick:()=>{const c=Xa(d,r),p=ce(o.state?.pathnameStackToGoBack,o.pathname);i(c,{state:{pathnameStackToGoBack:p}})},onEditNameClick:c=>{n(Te(r,"editName",c))},onReloadZeniAccountDetailPage:()=>{n(qe(r,!1))},onCloseAccountClick:()=>{n(Te(r,"closeAccount",""))},onBackClick:()=>{i("../",{relative:"path"})}}}))(ha);function re({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a,isAccountInfoDrawerOpen:i}){const t=W(),o=ae(),r=M(),d=$(),{tenantEmailDomain:c,accountId:p}=G(),{useDynamicConfig:h}=Z(),{useFeatureGate:f}=Z(),{isFeatureEnabled:s}=f(z.isDebitCardFeatureEnabled),{isFeatureEnabled:l}=f(z.isCheckingCommentingEnabled),g=D((q=>L(q))),{configValue:y}=h(N.expressPayConfig),A=y.is_enable_all_tenants===!0||y.tenant_ids!=null&&y.tenant_ids.includes(g.tenantId),I=!!g.companyBillPayInfo?.info?.isBillPayEnabled,w=b.getSignedInUser(),v=g.companyId??b.getSignedInUserTenant(c)?.companyId,x={userId:w?.userId??"",sessionId:w?.zeniSessionId??"",tenantId:g.tenantId??""},k=`${Ae}/account_details`,[P,_]=m.useState(!1),[E,j]=m.useState(!1),[T,B]=m.useState(!1),[S,u]=m.useState(!1),V=D((q=>Xe(q,p??""))),X=V.fetchState,{isAiCfoAccessEnabled:me,onAskAiCfoClick:se}=an({mobileExploreReferrer:"Checking Account Detail"});en({isDataReady:X==="Completed"}),m.useEffect((()=>{P||(r(qe(p??"",!1)),_(!0))}),[P,r,X]),m.useEffect((()=>{u(i!=null&&i===!0)}),[i]),m.useEffect((()=>{n!=null&&n===!0?j(!0):(j(!1),document.body.style.overflow="auto")}),[n]),m.useEffect((()=>{B(a!=null&&a===!0)}),[a]);const H=()=>{u(!1),o("..")};return e.jsxs(e.Fragment,{children:[S===!0&&V.accountDetail!=null?e.jsx(za,{authParams:x,downloadAccountDetailEndPoint:k,closeDrawerHandler:H,isAccountInfoDrawerOpen:S,zeniBankAccountDetail:V.accountDetail}):null,E===!0?e.jsx(on,{closeDrawerHandler:H,isTransferDrawerOpen:E,zeniAccountsConfig:V.zeniAccountsConfig,authParams:x,downloadAccountDetailEndPoint:k}):null,T===!0?e.jsx(tn,{closeDrawerHandler:H,isCheckDepositDrawerOpen:T}):null,e.jsx(Ja,{windowSize:d,children:e.jsx(Ka,{navigate:o,currentTenant:g,location:t,companyId:v,isDebitCardFeatureEnabled:s,accountId:p??"",isBillPayEnabled:I,isCheckingCommentingEnabled:l,isExpressPayEnabled:A,isAiCfoAccessEnabled:me,onAskAiCfoClick:se})})]})}const Xa=(n,a)=>`/${n}/checking/${a}/account-info`,qa=(n,a)=>`/${n}/checking/${a}/statements`,Qa=te((function(n,a){const{companyId:i}=a;return{zeniAccountSetupView:Qn(n,i)}}),(function(n,a){const{navigate:i,companyId:t}=a;return{onSetupButtonClick:()=>{O.trackAccountsPromoPageClicked("Setup Accounts"),n(ea(t))},onBackClick:()=>{i("../..",{relative:"path"})},onSetupZeniAccountSuccess:()=>{i("../setup",{relative:"path"})}}}))(xa),et=()=>{const n=ae(),a=W(),{tenantEmailDomain:i}=G(),{useDynamicConfig:t}=Z(),o=fa(),r=F(),[d,c]=m.useState(!1),[p,h]=m.useState(!1),f=D((k=>L(k))),{configValue:s}=t(N.zeniAccountsConfig),l=ye(s);m.useEffect((()=>{p===!1&&a.state?.message==="activation"&&h(!0)}),[a.state]);const g=b.getSignedInUserTenant(i)?.companyId??f.companyId,y=b.getSignedInUser(),A=!!f.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,I=k=>{c(k)};if(y==null)throw Error("Can't access Zeni account promo page without signing in...");const w=oe(),v=ne(w?.loggedInUserRoleMap),x=xe(w?.loggedInUserRoleMap);if(A&&v)return e.jsx(ee,{to:"../../checking/setup"});if(f.company?.companyZeniAccountInfo&&(!A&&v||x)){if(a.state?.message==="activation"){const k=Qe(a.state?.pathnameStackToGoBack);n(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:k.newStack}})}return e.jsxs(e.Fragment,{children:[e.jsx(ya,{showConfetti:p}),e.jsx(ue,{analytics:O,onLoad:k=>(P=>P.trackPageLoaded(ke.Event.accountsPromoPageViewed))(k)}),e.jsx(pe,{isAppContentDrawerOpen:d,handleDrawerToggle:I}),e.jsx(Qa,{analytics:O,navigate:n,companyId:g,meetingUrl:o("zeni_accounts_promo"),onClickMenuIcon:()=>{I(!0)},maxAnnualPercentageYield:l.maxAnnualPercentageYield,maxInsuredAmount:l.maxInsuredAmount,exampleBankBalance:3e6})]})}return e.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:r.colors.grey5}})};function jt(){const n=W(),a=D((B=>L(B))),i=F(),{useFeatureGate:t,useDynamicConfig:o}=Z(),r=oe(),d=ne(r?.loggedInUserRoleMap),c=xe(r?.loggedInUserRoleMap),p=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled,h=!!a.company?.companyZeniAccountInfo?.isZeniAccountTOSAccepted,{isFeatureEnabled:f}=t(z.isChargeCardFeatureEnabled),{isFeatureEnabled:s}=t(z.isDebitCardFeatureEnabled),l=Je(a),g=Ce(s,a),y=a?.userRole!=null&&na(a?.userRole),A=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!y)&&aa(r?.loggedInUserRoleMap),I=ta(r?.loggedInUserRoleMap),w=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!y)&&oa(r?.loggedInUserRoleMap),v=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!y,{configValue:x}=o(N.expressPayConfig),k=x.is_enable_all_tenants===!0||x.tenant_ids!=null&&x.tenant_ids.includes(a.tenantId),{isFeatureEnabled:P}=t(z.isAutoTransferRuleEnabled),_=Ca(a,f,s)&&!y&&sa(r?.loggedInUserRoleMap),E=ia(r?.loggedInUserRoleMap),j=v&&ne(r?.loggedInUserRoleMap),T=j||Ve(r?.loggedInUserRoleMap);return e.jsxs(Fe,{children:[e.jsx(C,{path:"setup",element:e.jsx(Be,{isBillPayAdminLevelAccess:A,isUserHasOnlyBillPayAccess:I,isReimbursementAdminLevelAccess:w,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:_,isUserHasOnlyCardAccess:E,productType:"zeni_accounts",type:"setup"})}),e.jsx(C,{path:"verification",element:e.jsx(Be,{isBillPayAdminLevelAccess:A,isUserHasOnlyBillPayAccess:I,isReimbursementAdminLevelAccess:w,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:_,isUserHasOnlyCardAccess:E,productType:"zeni_accounts",type:"verification"})}),P?e.jsxs(e.Fragment,{children:[e.jsx(C,{path:"auto-transfer",element:e.jsx(Le,{})}),T?e.jsx(C,{path:"auto-transfer/:ruleId/edit",element:e.jsx(Le,{isEditDrawerOpen:!0})}):null]}):e.jsx(C,{path:"auto-transfer",element:e.jsx(Q,{})}),k&&d?e.jsxs(e.Fragment,{children:[e.jsx(C,{path:"express-pay",element:e.jsx(ie,{})}),e.jsx(C,{path:"express-pay/add-ach",element:e.jsx(ie,{isAddACHDrawerOpen:!0})}),e.jsx(C,{path:"express-pay/add-wire/add-address",element:e.jsx(ie,{isAddAddressDrawerOpen:!0})}),e.jsx(C,{path:"express-pay/add-wire",element:e.jsx(ie,{isAddWireDrawerOpen:!0})})]}):e.jsx(C,{path:"express-pay",element:e.jsx(Q,{})}),e.jsx(C,{path:"promo",element:e.jsx(et,{})}),l&&!g?e.jsx(C,{path:"/*",element:e.jsx(nn,{})}):p?e.jsxs(e.Fragment,{children:[e.jsx(C,{path:"/",element:e.jsx(fe,{})}),e.jsx(C,{path:"transfer",element:e.jsx(fe,{isTransferDrawerOpen:!0})}),e.jsx(C,{path:"check-deposit",element:e.jsx(fe,{isCheckDepositDrawerOpen:!0})}),e.jsx(C,{path:"cash_management/*",element:e.jsx(Q,{})}),e.jsx(C,{path:":accountId/*",element:e.jsx(nt,{})}),e.jsx(C,{path:"*",element:e.jsx(Q,{})})]}):h&&d?e.jsx(C,{path:"*",element:e.jsx(ee,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&c?e.jsx(C,{path:"*",element:e.jsx(ee,{to:"../promo",state:n.state})}):e.jsx(C,{path:"*",element:e.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:i.colors.grey5,boxShadow:`0px 2px ${Aa.sp1} ${i.colors.dropShadowNormal}`}})})]})}function nt(){return e.jsxs(Fe,{children:[e.jsx(C,{path:"/",element:e.jsx(re,{})}),e.jsx(C,{path:"account-info",element:e.jsx(re,{isAccountInfoDrawerOpen:!0})}),e.jsx(C,{path:"transfer",element:e.jsx(re,{isTransferDrawerOpen:!0})}),e.jsx(C,{path:"check-deposit",element:e.jsx(re,{isCheckDepositDrawerOpen:!0})}),e.jsx(C,{path:"statements",element:e.jsx(Sa,{})}),e.jsx(C,{path:"*",element:e.jsx(Q,{})})]})}export{jt as default};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import{j as c}from"./liveblocks-DTaiayIC.js";import{a as u}from"./sentry-BRmieicQ.js";import{h as x,u as j,g as v,i as E,j as p}from"./core-DA_GbUVO.js";import{Sw as s,Sv as T,_T as $,fE as B,_U as C}from"./zeni-epic-state-cafsD4rZ.js";import{a1 as _,ae as g,E as z,z as D,a7 as L,d4 as P,a4 as U}from"./index-CsnAk3jU.js";import{n as N}from"./mui-yMDYeeMr.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new e.Error().stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="3d7bd891-4646-4f6e-935d-c73364ba8786",e._sentryDebugIdIdentifier="sentry-dbid-3d7bd891-4646-4f6e-935d-c73364ba8786")}catch{}})();const G=N.div`
|
|
2
|
+
display: flex;
|
|
3
|
+
height: 100vh;
|
|
4
|
+
width: 100%;
|
|
5
|
+
flex: 1 1 auto;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
align-items: center;
|
|
8
|
+
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
+
`;function H(){const e=x(),n=j(),d=_(),l=v();let{accountId:a}=E(),f=`${g.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${a}`;a==null&&l.pathname.includes(`${s}/statements`)&&(a=s,f=`${g.bankingMicroServiceBaseUrl}/1.0/${s}`);const[m,h]=u.useState(!1),y=z();u.useEffect((()=>{m||(h(!0),n(T(a??"",!1)))}),[m,n]);const o=p((t=>$(t,a??""))),b=()=>{const t=U(l.state?.pathnameStackToGoBack),k=t.poppedPathname??"..";e(k,{state:{pathnameStackToGoBack:t.newStack}})},r=D.getSignedInUser(),i=p((t=>B(t))),I={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:i.tenantId??""},w=C(a??"")===!0?s:o.zeniAccountDetail?.accountLast4??"",S=i.company?.companyInfo.companyLegalName??i.companyName;if(r==null)throw Error("Can't access address page without signing in...");return o.fetchState!=="Completed"?c.jsx(L,{fetchState:"In-Progress",style:{backgroundColor:y.colors.grey5}}):c.jsx(G,{windowSize:d,children:c.jsx(P,{currentTenantCompanyName:S,statementListView:o,accountLast4:w,onBackClick:b,authParams:I,downloadEndPoint:f})})}export{H as Z};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./sentry-
|
|
1
|
+
import"./sentry-BRmieicQ.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="459d6150-40e4-4fe0-88f2-7336312ca00a",e._sentryDebugIdIdentifier="sentry-dbid-459d6150-40e4-4fe0-88f2-7336312ca00a")}catch{}})();function d(e,t){if(t!=null)return e.find((n=>n.qboId===t))}function i(e,t){return e.filter((n=>n.qboId!=null&&t.includes(n.qboId)))}function s(e,t){return t.map((n=>({accountId:d(e,n.accountId.selectedOption)?.accountId??"",expenseType:n.expenseType.selectedOption??"",type1099:n.type1099.selectedOption??"",boxType:n.boxType.selectedOption??""})))}export{i as a,d as g,s as m};
|