@zeniai/web-app-ui 5.3.67-qa → 5.3.68-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-C3__PMEo.js → AccountMappingScreen-DSZj_uCQ.js} +2 -2
- package/dist/assets/{ActualMatchingMatchDetailScreen-DkhKFUGF.js → ActualMatchingMatchDetailScreen-BQRgUBiV.js} +1 -1
- package/dist/assets/AddressRoutes-BC4juuf4.js +1 -0
- package/dist/assets/{AddressScreen-CVDlEj9z.js → AddressScreen-BQYkT2m3.js} +2 -2
- package/dist/assets/{AiCfoScreen-Bk2obcqM.js → AiCfoScreen-DNMX1_2h.js} +1 -1
- package/dist/assets/{AppDrawer-BPsnMFZN.js → AppDrawer-BpkkZZ__.js} +1 -1
- package/dist/assets/{BillPayApprovalRoutes-C936IiBG.js → BillPayApprovalRoutes-DJXolFor.js} +1 -1
- package/dist/assets/{BillPayRoutes-CP067SBl.js → BillPayRoutes-Bwj63a_R.js} +18 -18
- package/dist/assets/BusinessVerificationPageScreen-D3H22Ycs.js +9 -0
- package/dist/assets/{CardsAiCfoScreen-ymwwPJ2C.js → CardsAiCfoScreen-_x1fFH7I.js} +1 -1
- package/dist/assets/{ChargeCardRoutes-CeBzO12Z.js → ChargeCardRoutes-Dd0GuLnx.js} +1 -1
- package/dist/assets/CompanyPassportScreen-lZWEIVDl.js +1 -0
- package/dist/assets/ConnectionAuthScreen-ue9LJgbU.js +11 -0
- package/dist/assets/CustomerOnboardingAuthScreen-6IBywESu.js +1 -0
- package/dist/assets/{CustomerOnboardingRoutes-DikEhGU3.js → CustomerOnboardingRoutes-C5hH9_2G.js} +3 -3
- package/dist/assets/{DashboardRoutes-DCfbjI9L.js → DashboardRoutes-DEtQqaVs.js} +3 -3
- package/dist/assets/{DefaultTenantHome-BLDQFeha.js → DefaultTenantHome-CCyE91GO.js} +1 -1
- package/dist/assets/{DomesticWireDetailScreen-De7aJutu.js → DomesticWireDetailScreen-B2C3yRyz.js} +4 -4
- package/dist/assets/{DrawerScreen-kd7CUS_n.js → DrawerScreen-CVgBvegK.js} +1 -1
- package/dist/assets/EntityDetailRoutes-BxIXjZHN.js +1 -0
- package/dist/assets/{ExpenseAutomationRoutes-o4JwdrGt.js → ExpenseAutomationRoutes-Kn5gQkyW.js} +7 -7
- package/dist/assets/FeaturePreviewScreen-CsKi-5Np.js +1 -0
- package/dist/assets/HubSpotOAuthCallbackScreen-CSdvQVKy.js +1 -0
- package/dist/assets/{InboxNotificationsProvider-CxBkh6GM.js → InboxNotificationsProvider-BLd671md.js} +1 -1
- package/dist/assets/{InvoicingRoutes-DbmI2BSJ.js → InvoicingRoutes-BkO_wRtc.js} +2 -2
- package/dist/assets/{MagicLinkRoutes-CiUE56E-.js → MagicLinkRoutes-BFQMSIdk.js} +6 -6
- package/dist/assets/MagicLinkSignInScreen-DNABK1wd.js +12 -0
- package/dist/assets/{MobileAppDrawer-B9_UQcQS.js → MobileAppDrawer-CUkRGmov.js} +1 -1
- package/dist/assets/NotFoundScreen-DcIIEjdb.js +1 -0
- package/dist/assets/{NotificationRoutes-Cu_7zzbb.js → NotificationRoutes-BDrKKRmf.js} +1 -1
- package/dist/assets/OAuthConsentScreen-BfqQ59Hm.js +1 -0
- package/dist/assets/PandLWithForecastRoutes-BM_Kx0Gi.js +1 -0
- package/dist/assets/{PaymentLinkScreen-BJZWRry4.js → PaymentLinkScreen-oDUUM_rp.js} +9 -9
- package/dist/assets/PeopleRoutes-CLcQG2z8.js +22 -0
- package/dist/assets/PerformanceRoutes-ZkTu6xdk.js +1 -0
- package/dist/assets/{Preview-C0e56SfV.js → Preview-DjryQabZ.js} +1 -1
- package/dist/assets/{QBOConnectionScreen-B-HvQzFu.js → QBOConnectionScreen-CC1mgdSE.js} +1 -1
- package/dist/assets/ReimbursementApprovalRoutes-DqdHGUab.js +1 -0
- package/dist/assets/{ReimbursementApprovalRuleDetailScreen-DAPGapkf.js → ReimbursementApprovalRuleDetailScreen-DGkJ20Az.js} +1 -1
- package/dist/assets/{ReimbursementRoutes-CnFWI_IU.js → ReimbursementRoutes-CwIONxFo.js} +7 -7
- package/dist/assets/{ReportsRoutes-W5l6wjs-.js → ReportsRoutes-DVA33cfE.js} +1 -1
- package/dist/assets/RewardsRoutes-wgZH1oXi.js +1 -0
- package/dist/assets/{ScheduleDetailsPrepaidExpensesScreen-2qd3xumh.js → ScheduleDetailsPrepaidExpensesScreen-BVhDF7k2.js} +5 -5
- package/dist/assets/ScreenRoutes-BIW4o9AI.js +2 -0
- package/dist/assets/{SettingsRoutes-B9F-JUIi.js → SettingsRoutes-B2D7KOAB.js} +6 -6
- package/dist/assets/SetupPagesScreen-BVuXxhDx.js +29 -0
- package/dist/assets/SignInScreen-CmC92pbo.js +1 -0
- package/dist/assets/SignOutScreen-CyRRVOip.js +9 -0
- package/dist/assets/{TaskListScreen-DLk20tTz.js → TaskListScreen-BbBcN7pH.js} +2 -2
- package/dist/assets/TaskRoutes-YYUAqa-i.js +9 -0
- package/dist/assets/TransactionDetailRoutes-45rDqVHh.js +1 -0
- package/dist/assets/{TransactionDetailScreen-Dy4sg4Bv.js → TransactionDetailScreen-Cqrtgoki.js} +2 -2
- package/dist/assets/TransactionListRoutes-BfvppQmn.js +1 -0
- package/dist/assets/{TreasuryRoutes-Cdsg2iQt.js → TreasuryRoutes-DJXblfti.js} +5 -5
- package/dist/assets/{VendorsRoutes-D-XiikJC.js → VendorsRoutes-iqjJ6KwN.js} +11 -11
- package/dist/assets/WiseConfirmationScreen-CdA1V-kW.js +12 -0
- package/dist/assets/{ZeniAccountRoutes-CIMaXWb6.js → ZeniAccountRoutes-CRqmMO-M.js} +11 -11
- package/dist/assets/ZeniAccountStatementScreen-Ds7h68QG.js +9 -0
- package/dist/assets/{accountMappingHelper-42mDzLtR.js → accountMappingHelper-DDpt4thU.js} +1 -1
- package/dist/assets/{analytics-CmKkcxmz.js → analytics-HUGlc_YA.js} +1 -1
- package/dist/assets/analyticsHelper-C858uUp8.js +1 -0
- package/dist/assets/{core-pDUZcPB0.js → core-BAlzhg_1.js} +1 -1
- package/dist/assets/{decodeURIComponentSafe-DBYvBfqM.js → decodeURIComponentSafe-BlS7R_TX.js} +1 -1
- package/dist/assets/{dnd-Bslfq-ku.js → dnd-CtBfGkHE.js} +1 -1
- package/dist/assets/{empty-COUJOkyp.js → empty-BRHFv2sW.js} +1 -1
- package/dist/assets/{empty-ChYivft5.js → empty-Bi7Yf941.js} +1 -1
- package/dist/assets/{emptyVideoElement-DkcKVFUD.js → emptyVideoElement-63TR5aDR.js} +1 -1
- package/dist/assets/epic-ucHpX8wh.js +2 -0
- package/dist/assets/expenseAutomationHelper-D89gAMsk.js +1 -0
- package/dist/assets/{getLocaleForTenant-CF6oc7pe.js → getLocaleForTenant-D_cnKwPq.js} +1 -1
- package/dist/assets/{index-BnV5dQX_.js → index-1u2aDJ3l.js} +17658 -17581
- package/dist/assets/{index-C7P994Rq.js → index-BvIRHYdj.js} +1 -1
- package/dist/assets/{index-DCm9kFzB.js → index-C3vxNQm5.js} +1 -1
- package/dist/assets/{index-BsYuRUyP.js → index-CGTcDwKM.js} +1 -1
- package/dist/assets/{index-DDEprezU.js → index-CWRZ55RL.js} +1 -1
- package/dist/assets/{index-DF1xpOd3.js → index-DGpWyM9Y.js} +1 -1
- package/dist/assets/{index-BqEm26lC.js → index-Df4gn8fh.js} +2 -2
- package/dist/assets/{index-BL3wAHTU.js → index-DuPam2hY.js} +1 -1
- package/dist/assets/{lexical-BMD9Skdu.js → lexical-CpUvnOjl.js} +1 -1
- package/dist/assets/{liveblocks-BLPKVqHo.js → liveblocks-Cmn0IneY.js} +1 -1
- package/dist/assets/{lottie-DWJdupW0.js → lottie-CqVjxmYG.js} +1 -1
- package/dist/assets/{mui-BiqpQr6x.js → mui-BP68m4Fu.js} +1 -1
- package/dist/assets/{pathToGoBack-Bl5vJY_-.js → pathToGoBack-WCSQSILz.js} +1 -1
- package/dist/assets/{pdf-B3souC9z.js → pdf-DVoBxypI.js} +3 -3
- package/dist/assets/{pdf-lib-qMo5mrxo.js → pdf-lib-CfwiSXQl.js} +1 -1
- package/dist/assets/{plaid-BXFY-KIk.js → plaid-D_c1UYI3.js} +1 -1
- package/dist/assets/{pusher-DEaV-Zmd.js → pusher-HOxR7Sbp.js} +1 -1
- package/dist/assets/{react-B88SuQgy.js → react-AUOblSvr.js} +1 -1
- package/dist/assets/{react-DnL-jdtH.js → react-C7Adach0.js} +1 -1
- package/dist/assets/{react-0LIbF3KH.js → react-CAp25EsP.js} +1 -1
- package/dist/assets/{react-CJK0LLCw.js → react-Deo915rj.js} +1 -1
- package/dist/assets/{react--S1-ZiQC.js → react-DxMuJXc7.js} +1 -1
- package/dist/assets/{react-B1Ev53Dd.js → react-S7mn4-ov.js} +1 -1
- package/dist/assets/{recharts-Dg9FaaKY.js → recharts-BDERfoBp.js} +1 -1
- package/dist/assets/{routePaths-am1hwlBf.js → routePaths-DSGBDygY.js} +1 -1
- package/dist/assets/{sentry-BYwRJ99F.js → sentry-D-L93P51.js} +1 -1
- package/dist/assets/{stripSplatSuffix-5xMPsJCi.js → stripSplatSuffix--MOgwIwN.js} +1 -1
- package/dist/assets/{url-BHkvYei3.js → url-BDV8gAHg.js} +1 -1
- package/dist/assets/{url-BlXMXHHv.js → url-D0vuH2sS.js} +1 -1
- package/dist/assets/useActualMatchingMatchDetail-BbZiVOuy.js +1 -0
- package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-DNTydfIx.js → useAiCfoDashboardSuggestedQuestionsChips-CLtV2UPA.js} +1 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-bvl6a2jc.js +1 -0
- package/dist/assets/{useChargeCardPusherEvents-oOQtL6QB.js → useChargeCardPusherEvents-00JeET2P.js} +1 -1
- package/dist/assets/{useDeviceId-D1mK-mWi.js → useDeviceId-BjLcJw5r.js} +1 -1
- package/dist/assets/useEmailConnectResultRefresh-BfM5did4.js +1 -0
- package/dist/assets/{useInitialThreadRequest-Cf8XTdT7.js → useInitialThreadRequest-BujZmxW_.js} +1 -1
- package/dist/assets/useTaskManagerAccess-EuL6L5n0.js +1 -0
- package/dist/assets/{useTaskManagerPusherEvents-B0rha1LN.js → useTaskManagerPusherEvents-C8CQ-n2I.js} +1 -1
- package/dist/assets/{utils-CJY4ogMD.js → utils-DrMX637r.js} +1 -1
- package/dist/assets/{withTransactionSidePanel-ikhXHA-I.js → withTransactionSidePanel-B22s9Gp7.js} +5 -5
- package/dist/assets/{zeni-epic-state-Bke7DGFg.js → zeni-epic-state-CGi26_dN.js} +3 -3
- package/dist/index.html +1 -1
- package/package.json +3 -3
- package/dist/assets/AddressRoutes-CYM-Yio3.js +0 -1
- package/dist/assets/BusinessVerificationPageScreen-C3rg4lLt.js +0 -9
- package/dist/assets/CompanyPassportScreen-C3LRYZXE.js +0 -1
- package/dist/assets/ConnectionAuthScreen-BQYWng6q.js +0 -11
- package/dist/assets/CustomerOnboardingAuthScreen-DCzfRa5s.js +0 -1
- package/dist/assets/EntityDetailRoutes-B0u3bC3I.js +0 -1
- package/dist/assets/FeaturePreviewScreen-mXuiXem0.js +0 -1
- package/dist/assets/HubSpotOAuthCallbackScreen-BFEMXtVa.js +0 -1
- package/dist/assets/MagicLinkSignInScreen-B7Wzj8j-.js +0 -12
- package/dist/assets/NotFoundScreen-DFgzBFQ7.js +0 -1
- package/dist/assets/OAuthConsentScreen-DPW3NMg4.js +0 -1
- package/dist/assets/PandLWithForecastRoutes-Cwqcjuhs.js +0 -1
- package/dist/assets/PeopleRoutes-DlMb9O4h.js +0 -22
- package/dist/assets/PerformanceRoutes-CYjtSwyr.js +0 -1
- package/dist/assets/ReimbursementApprovalRoutes-DNh7wXIn.js +0 -1
- package/dist/assets/RewardsRoutes-DjiitKT6.js +0 -1
- package/dist/assets/ScreenRoutes-DV55hswc.js +0 -2
- package/dist/assets/SetupPagesScreen-C56QR4fN.js +0 -29
- package/dist/assets/SignInScreen-DuynYtfb.js +0 -1
- package/dist/assets/SignOutScreen-C4vTy67R.js +0 -9
- package/dist/assets/TaskRoutes-D0yD6oUy.js +0 -9
- package/dist/assets/TransactionDetailRoutes-uRxsO3pd.js +0 -1
- package/dist/assets/TransactionListRoutes-RSu-eGQv.js +0 -1
- package/dist/assets/WiseConfirmationScreen-CHeQjtpi.js +0 -12
- package/dist/assets/ZeniAccountStatementScreen-BDSAzcnX.js +0 -9
- package/dist/assets/analyticsHelper-Dj84_Z5c.js +0 -1
- package/dist/assets/epic-YDmGQkJ8.js +0 -2
- package/dist/assets/expenseAutomationHelper-pbEk9tHa.js +0 -1
- package/dist/assets/useActualMatchingMatchDetail-j-HXNN5n.js +0 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-AjAhl7M3.js +0 -1
- package/dist/assets/useEmailConnectResultRefresh-Dx3sdFBt.js +0 -1
- package/dist/assets/useTaskManagerAccess-CFSDkmoA.js +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import{j as o}from"./liveblocks-
|
|
1
|
+
import{j as o}from"./liveblocks-Cmn0IneY.js";import{a as u}from"./sentry-D-L93P51.js";import{h as M,u as G,i as z,j as f,l as N,g as q,n as Oe,o as P,N as L}from"./core-BAlzhg_1.js";import{VW as gt,VX as Ze,RJ as et,VY as vt,fI as U,h1 as ge,VZ as Tt,cF as xt,V_ as bt,FN as yt,V$ as wt,W0 as oe,W1 as te,W2 as ve,Ti as ue,Tj as ke,G1 as pe,Th as he,FQ as tt,Fn as Pe,W3 as It,Tk as Y,m2 as me,W4 as je,Fh as Ct,W5 as Dt,W6 as Et,W7 as Ve,W8 as _e,W9 as Ae,Wa as Re,FX as Te,Wb as nt,FE as at,Wc as Ft,Wd as kt,We as Pt,Wf as jt,Wg as Vt,Wh as _t,Wi as At,Wj as Rt,Cv as Ut,CD as Lt,Cw as Bt,Sp as we,Wk as Wt,Wl as Ot,li as Ie,br as Mt,Wm as Nt,Wn as Gt,n0 as $t,n9 as zt,So as Ce,bF as Me,Wo as ot,R$ as st,Wp as Yt,Wq as Jt,Wr as Kt,nb as qt,Ws as Ne,Wt as Ge,Wu as $e,Wv as ze,Ww as Qt,n7 as Ht,Wx as Xt,na as Zt,Wy as en,Wz as it,SK as rt,mq as tn,WA as nn,WB as De,WC as dt,SI as lt,Iv as an,WD as on,WE as sn,mK as ct,WF as rn,WG as dn,SW as ln,vm as cn,WH as ut,WI as Ye,ST as Ee,WJ as Je,WK as un,SY as pn,WL as hn,WM as mn,WN as fn,WO as Sn,WP as gn,vp as vn,WQ as Tn,Tl as xn,UV as bn,SB as Fe,id as yn,UX as wn,UW as In,ib as Cn,WR as Dn,WS as En,IA as Fn,WT as kn,WU as Pn,WV as jn,WW as Vn,mu as _n,bn as An,e0 as Rn,d$ as Un}from"./zeni-epic-state-CGi26_dN.js";import{E as Ln,a1 as ne,ab as Ue,N as Q,m as O,z as R,a7 as Bn,aM as Wn,k as j,T as Le,c as xe,av as ee,as as se,aN as On,aO as pt,aq as Mn,a8 as Se,aP as Nn,p as K,K as Gn,G as ht,aQ as $n,ae as mt,a4 as zn,j as Ke,aR as Yn,I as J,a9 as Jn,af as ft,ag as Kn,aS as qn,aT as Qn,Q as Be,aU as Hn,aV as Xn,a3 as Zn,aW as ea,aX as ta}from"./index-1u2aDJ3l.js";import{D as na,n as B,S as St}from"./mui-BP68m4Fu.js";import{t as aa,A as oa}from"./AddressScreen-BQYkT2m3.js";import fe from"./NotFoundScreen-DcIIEjdb.js";import{F as sa}from"./FeaturePreviewScreen-CsKi-5Np.js";import{S as ia,a as ra,J as da,b as la,c as ca}from"./ScheduleDetailsPrepaidExpensesScreen-BVhDF7k2.js";import{u as ie}from"./useAskAiCfoHostNavButtonProps-bvl6a2jc.js";import{M as re}from"./MobileAppDrawer-CUkRGmov.js";import{v as We,c as ua,d as pa}from"./routePaths-DSGBDygY.js";import{D as ha}from"./DrawerScreen-CVgBvegK.js";import{a as ma,m as fa}from"./accountMappingHelper-DDpt4thU.js";import"./recharts-BDERfoBp.js";import"./analytics-HUGlc_YA.js";import"./plaid-D_c1UYI3.js";import"./dnd-CtBfGkHE.js";import"./stripe-cKAAJElX.js";import"./lottie-CqVjxmYG.js";import"./lexical-CpUvnOjl.js";import"./pdf-DVoBxypI.js";import"./utils-DrMX637r.js";import"./pathToGoBack-WCSQSILz.js";import"./InboxNotificationsProvider-BLd671md.js";import"./useTaskManagerAccess-EuL6L5n0.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]="90c27c37-758b-4781-8fdd-10ff324fa79e",e._sentryDebugIdIdentifier="sentry-dbid-90c27c37-758b-4781-8fdd-10ff324fa79e")}catch{}})();const Sa={drawerLeftMargin:new Ue(0,0,100,200)},ga=N((function(e,a){const{jeScheduledTransaction:s,selectedJERow:t,scheduleType:n,isVendorBulkUpdateOnTransactionEnabled:i}=a,{scheduleDetailsLocalData:l,updateStatus:p}=Ze(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:j,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"})}}}))(Wn),va=()=>{const e=Ln(),a=M(),s=G(),{scheduleDetailId:t}=z(),n=ne(),i=Sa.drawerLeftMargin.valuePx(n),{scheduleType:l}=z(),{useFeatureGate:p}=Q(),{isFeatureEnabled:h}=p(O.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=>Ze(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=q(),a
|
|
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=q(),a=G(),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},H="accrued_expenses",xa=N((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:H,sortKey:t,sortOrder:n}))},onChangeSubTab:t=>{e(Ae({scheduleType:H,subTab:t}))},onSearchTextChanged:t=>{e(_e({scheduleType:H,searchText:t}))},onReloadReport:()=>{e(tt(H))},onScroll:t=>{e(Ve({scheduleType:H,scrollYOffset:t}))},onClickNewButton:()=>{e(Dt()),e(Et()),j.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(je({scheduleType:H,fetchState:t}))}}}))(On),ba=({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s})=>{const[t,n]=u.useState(!1),[i,l]=u.useState(!1),p=M(),h=G(),{useFeatureGate:v}=Q(),m=xe();ce();const{isFeatureEnabled:r,isFeatureGateLoading:d}=v(O.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))),E=f((S=>ke(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&&E==="Completed"&&h(tt("accrued_expenses",{selectedTimeframe:Pe("accrued_expenses"),selectedCategoryId:"all"},!0))}),[t,E]);const V=f((S=>It(S,H))),{isAiCfoAccessEnabled:W,onAskAiCfoClick:F}=ie({mobileExploreReferrer:"Vendors — Accrued Expenses"});se({isDataReady:V.fetchState==="Completed"});const D=f((S=>Y(S).isReportGenerated));f((S=>Y(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 k=f((S=>ge(S,T.companyId))),$=S=>{l(S)};return o.jsxs(o.Fragment,{children:[o.jsx(re,{isAppContentDrawerOpen:i,handleDrawerToggle:$}),o.jsx(xa,{navigate:p,previousTabPosition:a,setPreviousTabPosition:s,scheduleListReport:V,downloadParams:g,themeState:m,vendorTabsToShow:e,analytics:j,controllerUserDetails:k,isAiCfoAccessEnabled:W,onAskAiCfoClick:F,onClickMenuIcon:()=>$(!0)})]})},X="fixed_assets",ya=N((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(Ve({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(je({scheduleType:X,fetchState:t}))}}}))(pt),wa=({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s})=>{const[t,n]=u.useState(!1),i=M(),l=G();ce();const{useFeatureGate:p}=Q(),h=xe(),{isFeatureEnabled:v,isFeatureGateLoading:m}=p(O.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=>ke(S,"fixed_assets"))),I=e.includes("prepaid_expenses"),E=e.includes("fixed_assets"),C=e.includes("accrued_expenses");u.useEffect((()=>{(I||E||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,E,m,v]),u.useEffect((()=>{t===!1&&b==="Completed"&&l(Te("fixed_assets",{selectedTimeframe:Pe("fixed_assets"),selectedCategoryId:"all"},!0))}),[t,b]);const w=f((S=>nt(S,X))),{isAiCfoAccessEnabled:A,onAskAiCfoClick:V}=ie({mobileExploreReferrer:"Vendors — Fixed Assets"});se({isDataReady:w.fetchState==="Completed"});const W=f((S=>Y(S).isReportGenerated));f((S=>Y(S).fetchState))!=="Completed"||W!==!0||v!==!0||e.includes("operating_expenses_by_vendor")||e.splice(1,0,"operating_expenses_by_vendor"),E||i("../opex");const F=f((S=>ge(S,d.companyId))),[D,k]=u.useState(!1),$=S=>{k(S)};return o.jsxs(o.Fragment,{children:[o.jsx(re,{isAppContentDrawerOpen:D,handleDrawerToggle:$}),o.jsx(ya,{navigate:i,scheduleListReport:w,downloadParams:T,previousTabPosition:a,setPreviousTabPosition:s,themeState:h,vendorTabsToShow:e,analytics:j,controllerUserDetails:F,isAiCfoAccessEnabled:A,onAskAiCfoClick:V,onClickMenuIcon:()=>{$(!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-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
10
10
|
flex-direction: column;
|
|
11
11
|
align-items: center;
|
|
12
12
|
background-color: ${e=>e.theme.colors.grey4};
|
|
13
|
-
`,Ca=N((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=Y(e),h=Ft(e);return{report:p,uiState:h,isAccountingClassesEnabled:me(e),analytics:j,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=
|
|
13
|
+
`,Ca=N((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=Y(e),h=Ft(e);return{report:p,uiState:h,isAccountingClassesEnabled:me(e),analytics:j,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=We(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(Vt(t))},onPageFetchStarted:()=>{e(jt(!0))},updateDownloadStateHandler:t=>{e(Pt(t))},onClearSearch:t=>{e(kt({timeframe:t}))}}}))(Nn);function Da({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s}){const t=M(),n=G(),i=q(),{tenantEmailDomain:l}=z(),p=ne(),h=R.getSignedInUser(),{useFeatureGate:v}=Q(),{isFeatureEnabled:m,isFeatureGateLoading:r}=v(O.isOpexByVendorFeatureEnabled),d=f((F=>Y(F)));if(h==null)throw Error("Can't access opex by vendor page without signing in...");ce();const[c,T]=u.useState(!1),x=f((F=>ue(F))),g=e.includes("prepaid_expenses"),y=e.includes("fixed_assets"),b=e.includes("accrued_expenses"),I=f((F=>oe(F))),{isAiCfoAccessEnabled:E,onAskAiCfoClick:C}=ie({mobileExploreReferrer:"Vendors — Operating Expenses by Vendor"});se({isDataReady:d.fetchState==="Completed"&&d.isReportGenerated===!0});const{areTenantIdsInSync:w}=Mn();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,V]=u.useState(!1),W=F=>{V(F)};return o.jsxs(Ia,{windowSize:p,children:[d.fetchState==="Completed"?o.jsx(Se,{analytics:j,onLoad:F=>{I.previousTab==null?F.trackVendorOperatingExpensesPageLoaded("Side Panel"):F.trackVendorOperatingExpenses(I.currentTab,I.previousTab??null)}}):null,o.jsx(re,{isAppContentDrawerOpen:A,handleDrawerToggle:W}),o.jsx(Ca,{location:i,navigate:t,previousTabPosition:a,setPreviousTabPosition:s,tenantEmailDomain:l,vendorTabsToShow:e,isAiCfoAccessEnabled:E,onAskAiCfoClick:C,onClickMenuIcon:()=>{W(!0)}})]})}const Z="prepaid_expenses",Ea=N((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(Ve({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(je({scheduleType:Z,fetchState:t}))}}}))(pt),Fa=({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s})=>{const[t,n]=u.useState(!1),i=M(),l=G(),{useFeatureGate:p}=Q(),h=xe();ce();const v=R.getSignedInUser(),{isFeatureEnabled:m,isFeatureGateLoading:r}=p(O.isOpexByVendorFeatureEnabled),d=f((S=>U(S))),c=f((S=>ke(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"),E=e.includes("fixed_assets"),C=e.includes("accrued_expenses");u.useEffect((()=>{(I||E||C)&&g===!1&&b!=="Completed"&&(l(pe()),y(!0))}),[g]),u.useEffect((()=>{t===!1&&c==="Completed"&&l(Te("prepaid_expenses",{selectedTimeframe:Pe("prepaid_expenses"),selectedCategoryId:"all"},!0))}),[t,c]),u.useEffect((()=>{r===!1&&(l(he({shouldFetchAccruedExpenses:C,shouldFetchFixedAssets:E,shouldFetchPrepaidExpenses:!0,shouldFetchOpexByVendor:m,shouldFetchVendorsList:!1,shouldFetchFiling1099Vendor:!1})),n(!0))}),[b,E,r,m]);const w=f((S=>nt(S,Z))),{isAiCfoAccessEnabled:A,onAskAiCfoClick:V}=ie({mobileExploreReferrer:"Vendors — Prepaid Expenses"});se({isDataReady:w.fetchState==="Completed"});const W=f((S=>Y(S).isReportGenerated));f((S=>Y(S).fetchState))!=="Completed"||W!==!0||m!==!0||e.includes("operating_expenses_by_vendor")||e.splice(1,0,"operating_expenses_by_vendor"),I||i("../opex");const F=f((S=>ge(S,d.companyId))),[D,k]=u.useState(!1),$=S=>{k(S)};return o.jsxs(o.Fragment,{children:[o.jsx(re,{isAppContentDrawerOpen:D,handleDrawerToggle:$}),o.jsx(Ea,{navigate:i,previousTabPosition:a,setPreviousTabPosition:s,scheduleListReport:w,downloadParams:x,themeState:h,vendorTabsToShow:e,analytics:j,controllerUserDetails:F,isAiCfoAccessEnabled:A,onAskAiCfoClick:V,onClickMenuIcon:()=>{$(!0)}})]})},ka=B.div`
|
|
14
14
|
display: flex;
|
|
15
15
|
min-height: 100%;
|
|
16
16
|
width: 100%;
|
|
@@ -18,7 +18,7 @@ import{j as o}from"./liveblocks-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
18
18
|
flex-direction: column;
|
|
19
19
|
align-items: center;
|
|
20
20
|
background-color: ${e=>e.theme.colors.grey4};
|
|
21
|
-
`,Pa=N((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:Yt(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=zn(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:E,isRecommendedCategorySelected:C,isRecommendedClassSelected:w,categoryRecommendationTypeSelected:A,classRecommendationTypeSelected:V}=en(r,d);c!=null&&j.trackVendorDetailsSave(c,T??"",x,g,y,b,I,E,C,w,A,V)})(t?.vendorViewDetails,t?.vendorViewDetails.ownerList),n!=null&&e(Zt(n,void 0))},onVendorSpendTrendFilterTabClick:r=>{e(Xt(r))},saveVendorDetailLocalData:r=>{n!=null&&e(Ht({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&&j.trackVendorDetailsCancel(r.id??"",r.name,r.account?.accountName,r.class?.className,r.owner?.email),e(Ne()),e(
|
|
21
|
+
`,Pa=N((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:Yt(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=zn(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:E,isRecommendedCategorySelected:C,isRecommendedClassSelected:w,categoryRecommendationTypeSelected:A,classRecommendationTypeSelected:V}=en(r,d);c!=null&&j.trackVendorDetailsSave(c,T??"",x,g,y,b,I,E,C,w,A,V)})(t?.vendorViewDetails,t?.vendorViewDetails.ownerList),n!=null&&e(Zt(n,void 0))},onVendorSpendTrendFilterTabClick:r=>{e(Xt(r))},saveVendorDetailLocalData:r=>{n!=null&&e(Ht({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&&j.trackVendorDetailsCancel(r.id??"",r.name,r.account?.accountName,r.class?.className,r.owner?.email),e(Ne()),e(Ge()),e($e()),e(ze()),m()},handleSpendTrendPercentChangeClick:()=>{var r;t?.vendorViewDetails.vendorView?.vendorBasic!=null&&(r=t.vendorViewDetails.vendorView?.vendorBasic,r.id!=null&&j.trackVendorDetailsSpendTrendHotlinkClicked(r.id??"",r.name,r.account?.accountName,r.class?.className,r.owner?.email))},onSaveSuccess:()=>{n!=null&&e(qt("Not-Started",n)),e(Ne()),e(Ge()),e($e()),e(ze()),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(Jt({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))}}}))($n);function qe({referrerType:e,isFiling1099FeatureEnabled:a}){const s=G(),t=q(),n=M(),i=Gn(),[l,p]=u.useState(!1),[h,v]=u.useState(!1),[m,r]=u.useState(!1),d=z(),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 E=ne(),C=f((_=>U(_))),w=f((_=>c!=null?Wt(_,c,I):void 0)),A=f((_=>_.vendorState.vendorByID[c??""])),V=f((_=>U(_).company?.companyInfo.firstMonthOfFY??1)),W=f((()=>Ot(V,2))),F=Ie({startDate:W.startDate,endDate:Mt()}),D=Nt(V),k=f((_=>Gt(_.trendWithTransactionsState,I,"EntityDetail"))),[$,S]=u.useState(!1),be=l===!1&&m===!1?void 0:k?.selectedPeriod?.timePeriod??D;return u.useEffect((()=>(e==null&&w?.fetchState!=="Not-Started"||c==null||s($t(c,I)),()=>{e!=null&&c!=null&&s(zt(c))})),[c,t.state,s]),u.useEffect((()=>{w?.fetchState==="Completed"&&w?.vendorViewDetails.vendorView?.vendorBasic!=null&&((_,ae,ye)=>{_.id!=null&&j.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"&&$===!1){be!=null&&l===!1&&(s(Ce(I,"EntityDetail",{timeframe:k?.selectedPeriod?.timeframe??"quarter",timePeriod:be},V)),S(!0));const _=ht.getLocalizedStrings().dateFormat.analytics;if(l===!0&&g!=null&&y!=null&&b!=null){S(!0);const ae=g,ye={startDate:Me(y,_.YYYYDashMMDashDDFormat),endDate:Me(b,_.YYYYDashMMDashDDFormat)};s(Ce(I,"EntityDetail",{timeframe:ae,timePeriod:ye}))}}}),[w?.fetchState,be,k?.selectedPeriod?.timeframe,l,V]),u.useEffect((()=>{w?.fetchState==="Completed"&&h===!1&&(s(ot({timePeriod:F,numberOfQuartersFetched:3})),s(st(I,w.allTransactionsTabData?.timePeriod??F,!1,!0)),v(!0))}),[w?.fetchState,h]),c==null?o.jsx(fe,{}):o.jsx(ka,{windowSize:E,children:o.jsx(Pa,{location:t,navigate:n,isFiling1099FeatureEnabled:a,vendorDetailView:w,vendorId:c,currentTenant:C,selectedVendor:A,firstMonthOfFY:V,isTrendPeriodSelected:l,selectedPeriodTimePeriod:k?.selectedPeriod?.timePeriod,defaultTransactionTimePeriod:D,vendorEntity:I,currentUserRoleMap:i?.loggedInUserRoleMap,tenantEmailDomain:x})})}const ja=ht.getLocalizedStrings().spendManagement.billPay.vendorCreation.vendorDetails,Va={containerWidth:new Ue(100,58)},_a=B(Jn)`
|
|
22
22
|
width: ${J.sp4};
|
|
23
23
|
height: ${J.sp4};
|
|
24
24
|
cursor: pointer;
|
|
@@ -35,7 +35,7 @@ import{j as o}from"./liveblocks-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
35
35
|
flex-direction: column;
|
|
36
36
|
width: ${e=>`${Va.containerWidth.value(e.windowSize)}%`};
|
|
37
37
|
${e=>e.windowSize!=="small"?"overflow: auto;":""}
|
|
38
|
-
`,Ua=N((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:j,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:[]}))}}}))(qn);function Qe({appContent:e,showFullScreenSkeletonWhileLoading:a}){const s
|
|
38
|
+
`,Ua=N((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:j,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:[]}))}}}))(qn);function Qe({appContent:e,showFullScreenSkeletonWhileLoading:a}){const s=G(),t=M(),{vendorId:n}=z(),i=ne(),l=xe(),p=R.getSignedInUser(),[h,v]=u.useState(!1),{useFeatureGate:m}=Q(),{isFeatureEnabled:r}=m(O.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 E=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),V=x.vendor?.contactIds,W=V?.[V.length-1],F=f((D=>D.contactState.contactById[W]));if(u.useEffect((()=>{n!=null&&w==="In-Progress"&&y?.fetchState==="Completed"&&x?.vendor!=null&&(s(nn(n,x.vendor,F)),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(Ma,{children:o.jsx(Yn,{})});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(Wa,{showAutofill:!1}),o.jsx(Oa,{showAutofill:!1,children:d})]})]}):null,o.jsx(Ua,{vendorId:n,file:I,showAutofill:!1,type:"w9",isVendorRecommendationEnabled:r,pdfTitle:I?ja.w9FormTitle:void 0,showTitlebar:!0,showTitlebarIcon:!0,vendorLegalName:x?.vendor?.legalName,isLoading:E}),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`
|
|
@@ -45,19 +45,19 @@ import{j as o}from"./liveblocks-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
45
45
|
position: absolute;
|
|
46
46
|
display: flex;
|
|
47
47
|
align-items: center;
|
|
48
|
-
`,
|
|
48
|
+
`,Wa=B.div`
|
|
49
49
|
width: 1px;
|
|
50
50
|
height: ${J.sp3};
|
|
51
51
|
margin: ${J.sp0} ${J.sp3};
|
|
52
52
|
background-color: ${e=>e.showAutofill?ft.neutralGrey1Light:e.theme.colors.hero};
|
|
53
|
-
`,
|
|
53
|
+
`,Oa=B(Kn.StandardMedium)`
|
|
54
54
|
color: ${e=>e.showAutofill?ft.neutralGrey5Light:e.theme.colors.primary};
|
|
55
55
|
`,Ma=B.div`
|
|
56
56
|
width: 100%;
|
|
57
57
|
height: 100vh;
|
|
58
58
|
overflow: hidden;
|
|
59
59
|
background-color: ${e=>e.theme.colors.grey4};
|
|
60
|
-
`,Na=N((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
|
|
60
|
+
`,Na=N((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 Ga(){const e=M();return o.jsx(Na,{navigate:e})}const $a=B.div`
|
|
61
61
|
display: flex;
|
|
62
62
|
min-height: 100%;
|
|
63
63
|
width: 100%;
|
|
@@ -65,7 +65,7 @@ import{j as o}from"./liveblocks-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
65
65
|
flex-direction: column;
|
|
66
66
|
align-items: center;
|
|
67
67
|
background-color: ${e=>e.theme.colors.grey4};
|
|
68
|
-
`,za=N((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:j,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(Ee(t,n,i))},onGlobalMerchantAutoCompleteInputChange:(t,n)=>{t.trim().length>=2?e(vn({searchString:t,globalMerchantType:n??"vendor"})):t.trim().length===0&&e(Je())},onUpdateLocalData:(t,n,i,l)=>{if(n!=null){const p=Ya(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=
|
|
68
|
+
`,za=N((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:j,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(Ee(t,n,i))},onGlobalMerchantAutoCompleteInputChange:(t,n)=>{t.trim().length>=2?e(vn({searchString:t,globalMerchantType:n??"vendor"})):t.trim().length===0&&e(Je())},onUpdateLocalData:(t,n,i,l)=>{if(n!=null){const p=Ya(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=We(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(Je())},onClickRedirectToQBO:()=>{window.open(`${Le.qboRedirectionUrl}/vendors`,"_blank")},updateVendorDetailLocalData:t=>{e(ut({vendorDetails:t})),s(`./vendor/${t.id}`)},onBackClick:()=>{s("../..")},onReloadList:()=>{e(Ee(null))}}}))(Hn);function He(){const e=M(),a=G(),s=q(),{tenantEmailDomain:t}=z(),n=ne(),i=R.getSignedInUser(),{vendorId:l}=z(),p=f((d=>Ye(d))),[h,v]=u.useState(!1),m=f((d=>Ye(d).fetchState));if(u.useEffect((()=>{m==="Not-Started"&&h===!1&&(a(Ee(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:j,onLoad:r}):null,o.jsx(Se,{analytics:j,onLoad:r}),o.jsx(ha,{isOpen:l!=null,drawerLeftMargin:new Ue(0,0,300,600),onClose:()=>{e("../review")},children:o.jsx(Ja,{onClick:d=>d.stopPropagation(),children:o.jsx(Ga,{})})}),o.jsx($a,{windowSize:n,children:o.jsx(za,{location:s,navigate:e,vendorFirstReviewDetails:p,tenantEmailDomain:t})})]})}const Ya=e=>e.recommendedFirst===!0?"recommendedFirst":e.recommendedSecond===!0?"recommendedSecond":e.retain===!0?"retain":e.rename===!0?"rename":e.customMerchant===!0?"customMerchant":null,Ja=B(St)`
|
|
69
69
|
display: flex;
|
|
70
70
|
min-height: 100%;
|
|
71
71
|
flex-direction: column;
|
|
@@ -77,7 +77,7 @@ import{j as o}from"./liveblocks-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
77
77
|
flex-direction: column;
|
|
78
78
|
align-items: center;
|
|
79
79
|
background-color: ${e=>e.theme.colors.grey4};
|
|
80
|
-
`,Ha=N((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(En({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(Fe(!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 Xe({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s}){const t=M(),n
|
|
80
|
+
`,Ha=N((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(En({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(Fe(!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 Xe({vendorTabsToShow:e,previousTabPosition:a,setPreviousTabPosition:s}){const t=M(),n=G(),i=q(),{tenantEmailDomain:l}=z(),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(Fe(!1)))}),[r,d]),u.useEffect((()=>{T.saveState.fetchState==="Completed"&&n(Fe(!1))}),[T.saveState.fetchState]);const y=C=>{m(C)},b=f((C=>U(C))),I={userId:h?.userId??"",sessionId:h?.zeniSessionId??"",tenantId:b.tenantId},E=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:j,onLoad:()=>j.trackPageLoaded(Be.Event.vendor1099ListPage)})}):null,o.jsxs(Qa,{windowSize:p,children:[o.jsx(re,{isAppContentDrawerOpen:v,handleDrawerToggle:y}),o.jsx(Ha,{location:i,navigate:t,previousTabPosition:a,setPreviousTabPosition:s,analytics:j,vendorsFiling1099ListDetails:c,vendorTypeList:c.vendorTypeList,accountMappingView:T,downloadParams:E,tenantEmailDomain:l,vendorTabsToShow:e,isAiCfoAccessEnabled:x,onAskAiCfoClick:g,onClickMenuIcon:()=>{y(!0)}})]})]})}const Xa=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-BLPKVqHo.js";import{a as u}from"./sentry-BYwRJ99
|
|
|
85
85
|
flex-direction: column;
|
|
86
86
|
align-items: center;
|
|
87
87
|
background-color: ${e=>e.theme.colors.grey4};
|
|
88
|
-
`,Za=N((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:j}}),(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(Vn({pageToken:t}))},onUpdateSortUiState:(t,n)=>{e(jn({sortOrder:t,sortkey:n}))},onUpdateCurrentYTDSelection:t=>{e(Pn({ytdSpendSelection:t}))},onVendorRowClick:(t,n)=>{if(a.tenantEmailDomain!=null){const i=
|
|
88
|
+
`,Za=N((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:j}}),(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(Vn({pageToken:t}))},onUpdateSortUiState:(t,n)=>{e(jn({sortOrder:t,sortkey:n}))},onUpdateCurrentYTDSelection:t=>{e(Pn({ytdSpendSelection:t}))},onVendorRowClick:(t,n)=>{if(a.tenantEmailDomain!=null){const i=We(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(kn({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=M(),n=G(),i=q(),{tenantEmailDomain:l}=z(),p=ne(),h=R.getSignedInUser(),{useFeatureGate:v}=Q(),{isFeatureEnabled:m,isFeatureGateLoading:r}=v(O.isOpexByVendorFeatureEnabled);ce();const d=e.includes("prepaid_expenses"),c=e.includes("fixed_assets"),T=e.includes("accrued_expenses"),x=f((k=>oe(k)));let g={};g=f((k=>Fn(k,"vendorsTab")));const[y,b]=u.useState(!1),{isAiCfoAccessEnabled:I,onAskAiCfoClick:E}=ie({mobileExploreReferrer:"Vendors Summary"});se({isDataReady:g.fetchState==="Completed"});const C=f((k=>ue(k))),w=f((k=>Y(k).isReportGenerated));f((k=>Y(k).fetchState))==="Completed"&&w&&m&&!e.includes("operating_expenses_by_vendor")&&e.splice(1,0,"operating_expenses_by_vendor");const[A,V]=u.useState(!1);if(u.useEffect((()=>{(d||c)&&A===!1&&C!=="Completed"&&(n(pe()),V(!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),j.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[W,F]=u.useState(!1),D=k=>{F(k)};return o.jsxs(Xa,{windowSize:p,children:[o.jsx(re,{isAppContentDrawerOpen:W,handleDrawerToggle:D}),o.jsx(Za,{location:i,navigate:t,vendorsListDetails:g,tenantEmailDomain:l,vendorTabsToShow:e,onClickMenuIcon:()=>{D(!0)},previousTabPosition:a,setPreviousTabPosition:s,isAiCfoAccessEnabled:I,onAskAiCfoClick:E})]})}function ko(){const{useFeatureGate:e}=Q(),a=q().state?.referrer,[s,t]=u.useState(!1),[n,i]=u.useState(0),l=R.getSignedInUser(),p=An(l),{isFeatureEnabled:h}=e(O.isOpexByVendorFeatureEnabled),{isFeatureEnabled:v}=e(O.isVendorReviewFeatureEnabled),{isFeatureEnabled:m}=e(O.isScheduledJEPrepaidExpensesFeatureEnabled),{isFeatureEnabled:r}=e(O.isScheduledJEFixedAssetsFeatureEnabled),{isFeatureEnabled:d}=e(O.isScheduledJEAccruedExpensesFeatureEnabled),{isFeatureEnabled:c}=e(O.isFiling1099FeatureEnabled),T=f((E=>U(E))),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(O.isDebitCardFeatureEnabled),b=Rn(y,T),I=Un(T);return b===!0||I===!0?o.jsx(Oe,{children:o.jsx(P,{path:"/*",element:o.jsx(sa,{})})}):o.jsxs(Oe,{children:[o.jsx(P,{path:"/opex",element:h===!0?o.jsx(Da,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../summary"})}),o.jsx(P,{path:"/summary",element:o.jsx(eo,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g})}),o.jsx(P,{path:"schedules/fixed_assets/details/:scheduleDetailId",element:r===!0?o.jsx(ia,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(P,{path:"schedules/accrued_expenses/details/:scheduleDetailId",element:r===!0?o.jsx(ra,{shouldNavigateBack:s,setShouldNavigateBack:t}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(P,{path:"schedules/one_time_accrual/details/:accrualId",element:d===!0?o.jsx(da,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(P,{path:"schedules/:scheduleType/details/:scheduleDetailId",element:m===!0?o.jsx(la,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(P,{path:"schedules/:scheduleType/details/:scheduleDetailId/edit_link",element:m===!0||r===!0?o.jsx(va,{}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(P,{path:"schedules/accrued_expenses/details/:scheduleDetailId/edit_link",element:d===!0?o.jsx(ca,{setShouldNavigateBack:t}):o.jsx(L,{to:"../../vendors/opex"})}),o.jsx(P,{path:"schedules/prepaid_expenses",element:m===!0?o.jsx(Fa,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(P,{path:"schedules/fixed_assets",element:r===!0?o.jsx(wa,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(P,{path:"schedules/accrued_expenses",element:d===!0?o.jsx(ba,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(P,{path:"/filing_1099",element:c&&p?o.jsx(Xe,{previousTabPosition:n,setPreviousTabPosition:i,vendorTabsToShow:g}):o.jsx(L,{to:"../opex"})}),o.jsx(P,{path:"/filing_1099/:vendorId",element:c&&p?o.jsx(Xe,{vendorTabsToShow:g,previousTabPosition:n,setPreviousTabPosition:i}):o.jsx(L,{to:"../opex"})}),o.jsx(P,{path:"/filing_1099/upload/:vendorId/edit",element:c&&p?o.jsx(Qe,{appContent:o.jsx(qa,{}),showFullScreenSkeletonWhileLoading:!0}):o.jsx(L,{to:"../opex"})}),o.jsx(P,{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(P,{path:"/summary/:vendorId/:qboId",element:o.jsx(qe,{referrerType:a,isFiling1099FeatureEnabled:c&&p})}),o.jsx(P,{path:"/summary/:vendorId/:qboId/:timeframe/:startDate/:endDate",element:o.jsx(qe,{referrerType:a,isFiling1099FeatureEnabled:c&&p})}),o.jsx(P,{path:"/review",element:v===!0?o.jsx(He,{}):o.jsx(fe,{})}),o.jsx(P,{path:"/review/vendor/:vendorId",element:v?o.jsx(He,{}):o.jsx(fe,{})}),o.jsx(P,{path:"/",element:o.jsx(L,{to:"summary"})}),o.jsx(P,{path:"*",element:o.jsx(fe,{})})]})}export{ko as default};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import{j as o}from"./liveblocks-Cmn0IneY.js";import{a as f}from"./sentry-D-L93P51.js";import{t as u,u as h,j as y,N as b}from"./core-BAlzhg_1.js";import{UJ as I,gl as w,JJ as j}from"./zeni-epic-state-CGi26_dN.js";import{z as l,a7 as x,af as S,ag as D}from"./index-1u2aDJ3l.js";import{n as g}from"./mui-BP68m4Fu.js";import"./recharts-BDERfoBp.js";import"./analytics-HUGlc_YA.js";import"./plaid-D_c1UYI3.js";import"./dnd-CtBfGkHE.js";import"./stripe-cKAAJElX.js";import"./lottie-CqVjxmYG.js";import"./lexical-CpUvnOjl.js";import"./pdf-DVoBxypI.js";import"./utils-DrMX637r.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]="174777f3-3324-4fdb-b781-87814c7f9584",e._sentryDebugIdIdentifier="sentry-dbid-174777f3-3324-4fdb-b781-87814c7f9584")}catch{}})();const B=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,c]=f.useState(!1),a=h(),i=y((m=>I(m))),r=l.getSignedInUser(),d=l.getSignedInUserTenantWithId(s);if(r==null||d==null)return o.jsx(b,{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||(c(!0),a(j(t,p,s)))}),[n,a]),i.fetchState==="Error"?o.jsx(E,{children:o.jsx(_,{children:i.error?.message??""})}):(i.fetchState==="Completed"&&window.close(),o.jsx(x,{fetchState:"In-Progress"}))},E=g.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
|
+
`,_=g(D.LargeRegular)`
|
|
10
|
+
display: flex;
|
|
11
|
+
color: ${S.important};
|
|
12
|
+
`;export{B as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e}from"./liveblocks-
|
|
1
|
+
import{j as e}from"./liveblocks-Cmn0IneY.js";import{u as _,h as ne,g as N,i as W,j as k,l as ae,N as Q,n as Re,o as x}from"./core-BAlzhg_1.js";import{$w as $e,LB as Ue,$x as Fe,fI as R,GO as _e,$y as wn,cv as ee,cw as ze,GI as An,$z as Dn,$A as kn,GL as In,GS as me,GF as Sn,GC as Pn,Z4 as ce,$B as bn,P9 as vn,X0 as jn,Pb as En,mL as Pe,$C as Tn,v1 as Me,uR as Ve,mC as Ze,mF as be,X1 as ve,X2 as Bn,$D as On,mE as Ln,m$ as Rn,mt as $n,kT as Un,kS as Fn,$E as _n,$F as ge,OS as zn,$G as Mn,$H as Vn,Zk as fe,$I as je,$J as Zn,Pm as Hn,ZH as Gn,MJ as He,Cj as Ge,$K as Nn,Pj as Wn,$L as Ne,db as ye,Pq as We,d$ as Xe,e0 as xe,Po as Xn,MD as Yn,Pg as qn,$M as Ye,$N as qe,OU as Ke,P2 as Ee,$O as Kn,Zy as Jn,Pr as Qn,bq as ea,bK as na,cH as aa,bL as ta,bu as oa,Ur as sa}from"./zeni-epic-state-CGi26_dN.js";import{K as te,N as Z,m as V,z as b,av as Ce,E as $,a7 as le,cX as ra,a1 as z,ab as X,a4 as Je,j as ia,r as Te,k as L,cY as ca,ae as we,cZ as la,a8 as de,c_ as da,Q as Ae,bi as G,c$ as ua,aq as pa,as as Qe,d0 as Be,d1 as ma,p as ie,d2 as ga,ai as ha,d3 as fa,d4 as ya,h as xa,I as Ca}from"./index-1u2aDJ3l.js";import{n as U,D as Y,S as q}from"./mui-BP68m4Fu.js";import J from"./NotFoundScreen-DcIIEjdb.js";import{S as Oe}from"./SetupPagesScreen-BVuXxhDx.js";import{F as en}from"./FeaturePreviewScreen-CsKi-5Np.js";import{a as g}from"./sentry-D-L93P51.js";import{M as ue}from"./MobileAppDrawer-CUkRGmov.js";import{A as wa,D as Aa,V as Da}from"./DomesticWireDetailScreen-B2C3yRyz.js";import{A as ka}from"./AddressScreen-BQYkT2m3.js";import{u as nn}from"./useAskAiCfoHostNavButtonProps-bvl6a2jc.js";import{Z as Ia}from"./ZeniAccountStatementScreen-Ds7h68QG.js";import"./recharts-BDERfoBp.js";import"./analytics-HUGlc_YA.js";import"./plaid-D_c1UYI3.js";import"./dnd-CtBfGkHE.js";import"./stripe-cKAAJElX.js";import"./lottie-CqVjxmYG.js";import"./lexical-CpUvnOjl.js";import"./pdf-DVoBxypI.js";import"./utils-DrMX637r.js";import"./BusinessVerificationPageScreen-D3H22Ycs.js";import"./routePaths-DSGBDygY.js";import"./analyticsHelper-C858uUp8.js";import"./InboxNotificationsProvider-BLd671md.js";import"./useTaskManagerAccess-EuL6L5n0.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]="b7400e2d-e7d0-4f6e-8fb7-9ee2a41ade28",n._sentryDebugIdIdentifier="sentry-dbid-b7400e2d-e7d0-4f6e-8fb7-9ee2a41ade28")}catch{}})();const Sa=U.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
min-height: 100%;
|
|
4
4
|
width: 100%;
|
|
@@ -6,19 +6,19 @@ import{j as e}from"./liveblocks-BLPKVqHo.js";import{u as _,h as ne,g as W,i as N
|
|
|
6
6
|
flex-direction: column;
|
|
7
7
|
align-items: center;
|
|
8
8
|
background-color: ${n=>n.theme.colors.grey4};
|
|
9
|
-
`;function Le({isEditDrawerOpen:n}){const a=$(),[r,t]=g.useState(!1),{autoTransferRulePageProps:o,isLoading:i}=(function({isEditDrawerOpen:d=!1}={}){const c=_(),p=ne(),h=
|
|
9
|
+
`;function Le({isEditDrawerOpen:n}){const a=$(),[r,t]=g.useState(!1),{autoTransferRulePageProps:o,isLoading:i}=(function({isEditDrawerOpen:d=!1}={}){const c=_(),p=ne(),h=N(),{ruleId:y,tenantEmailDomain:s}=W(),l=te(),{useFeatureGate:f}=Z(),m=k((u=>$e(u))),P=k((u=>Ue(u.depositAccountState,u.depositAccountListState))),D=k((u=>Fe(u))),A=k((u=>R(u))),{isFeatureEnabled:I}=f(V.isTreasuryEnabled),C=m?.fetchState??"Not-Started",w=A?.companyId??(s==null?void 0:b.getSignedInUserTenant(s)?.companyId);g.useEffect((()=>{C==="Not-Started"&&w!=null&&c(_e(!0))}),[c,C,w]);const E=m?.fetchState!=="Completed";if(E)return{autoTransferRulePageProps:void 0,isLoading:E};const T=A?.company!=null&&wn(A.company),v=!!(I&&T),j=ee(l?.loggedInUserRoleMap)||ze(l?.loggedInUserRoleMap),O=b.getSignedInUser(),S={userId:O?.userId??"",sessionId:O?.zeniSessionId??"",tenantId:A?.tenantId??""},B=!!h.state?.scrollToAddRule;return{isLoading:E,autoTransferRulePageProps:{autoTransferRuleView:m,companyName:A?.companyName??"",hasAdminLevelAccess:j,includeTreasuryOption:v,transferLimit:5e5,authParams:S,currentTenant:A,depositAccountListView:P,downloadAccountDetailEndPoint:`${Ce}/account_details`,editingRuleId:y,isEditDrawerOpen:d,scrollToAddRule:B,zeniAccountsConfigDetail:D,onBackClick:()=>p(".."),onCreateRule:()=>{c(Pn())},onUpdateRule:u=>{c(me(u))},onDeleteClick:u=>{c(Sn(u))},onPauseClick:u=>{c(me(u,!0,!1))},onResumeClick:u=>{c(me(u,!1,!0))},onActivityClick:(u,M)=>{c(In(u,M))},onUpdateRuleLocalData:u=>{c(kn(u))},clearRuleLocalData:()=>{c(Dn())},onEditClick:u=>{p(`./${u}/edit`)},onEditDrawerClose:()=>{p("../../",{relative:"path"})},onReviewClick:()=>{c(An())}}}})({isEditDrawerOpen:n});return i||o==null?e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:a.colors.grey5}}):e.jsxs(Sa,{children:[e.jsx(ue,{isAppContentDrawerOpen:r,handleDrawerToggle:d=>{t(d)}}),e.jsx(ra,{...o})]})}const Pa={overlayWidth:new X(100,100,58)},ba=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=_(),o=$(),i=z();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(Y,{onClose:()=>{r(!0),t(ce())},anchor:"right",open:a,PaperProps:{style:{width:Pa.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(va,{onClick:d=>d.stopPropagation(),children:e.jsx(wa,{vendorIdParam:n,accountContext:"express-pay"})})})},va=U(q)`
|
|
10
10
|
display: flex;
|
|
11
11
|
min-height: 100%;
|
|
12
12
|
flex-direction: column;
|
|
13
|
-
`,ja={overlayWidth:new
|
|
13
|
+
`,ja={overlayWidth:new X(100,100,58)},Ea=({isDrawerOpen:n,closeDrawerHandler:a})=>{const r=_(),t=$(),o=z();if(b.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return e.jsx(Y,{onClose:()=>{a(!0),r(ce())},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(Ta,{onClick:i=>i.stopPropagation(),children:e.jsx(ka,{accountContext:"express-pay",addressTypeParam:"vendor_address"})})})},Ta=U(q)`
|
|
14
14
|
display: flex;
|
|
15
15
|
min-height: 100%;
|
|
16
16
|
flex-direction: column;
|
|
17
|
-
`,Ba={overlayWidth:new
|
|
17
|
+
`,Ba={overlayWidth:new X(100,100,58)},Oa=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=_(),o=$(),i=z();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(Y,{onClose:()=>{r(!0),t(ce())},anchor:"right",open:a,PaperProps:{style:{width:Ba.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(La,{onClick:d=>d.stopPropagation(),children:e.jsx(Aa,{vendorIdParam:n,accountContext:"express-pay"})})})},La=U(q)`
|
|
18
18
|
display: flex;
|
|
19
19
|
min-height: 100%;
|
|
20
20
|
flex-direction: column;
|
|
21
|
-
`,Ra=
|
|
21
|
+
`,Ra=U.div`
|
|
22
22
|
display: flex;
|
|
23
23
|
height: 100vh;
|
|
24
24
|
width: 100%;
|
|
@@ -26,19 +26,19 @@ import{j as e}from"./liveblocks-BLPKVqHo.js";import{u as _,h as ne,g as W,i as N
|
|
|
26
26
|
flex-direction: column;
|
|
27
27
|
align-items: center;
|
|
28
28
|
background-color: ${n=>n.theme.colors.grey4};
|
|
29
|
-
`,$a=ae((function(n,a){const r=R(n),t=
|
|
29
|
+
`,$a=ae((function(n,a){const r=R(n),t=b.getSignedInUser(),o=r.tenantId,i={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:i,filesEndPoint:`${we.fileMicroServiceBaseUrl}`},vendorSearchAutoCompleteData:{autoCompleteText:c,entityAutoCompleteView:p},analytics:a.analytics}}),(function(n,a){const{navigate:r}=a;return{onSaveVendor:t=>{n(Fn(t,void 0,void 0,!0))},saveVendorDetailLocalData:(t,o)=>{n(be({vendorId:o,localData:t}))},saveExpressPayLocalData:t=>{n(Un({localData:t}))},onVendorSelected:t=>{t!=null&&n($n(t,!1))},updateSelectedVendorForCreate:t=>{n(Rn(t))},initializeVendorAddress:()=>{n(Ln())},resetVendorSaveStatus:t=>{n(On({vendorId:t}))},vendorSearchAutoCompleteActions:{onAutoCompleteInputChange:(t,o)=>{t.trim().length>=2?n(Bn({searchString:t,entityType:o,searchOrigin:"common"})):t.trim().length===0&&n(ve("common"))},onCancelAutoComplete:()=>{n(ve("common"))}},chooseNewVendor:t=>{n(be({localData:{vendorName:t}}))},onClickAddAccount:t=>{t.method.toLowerCase().indexOf("ach")!==-1?r("./add-ach",{relative:"path"}):t.method.toLowerCase().indexOf("wire")!==-1&&t.method.toLowerCase().indexOf("domestic")!==-1&&r("./add-wire",{relative:"path"})},updateFilesEntity:t=>{n(Ze({files:t}))},onDeleteFile:t=>{n(Ve(t))},onEditFileName:(t,o)=>{n(Me(t,o.split(".")[0]))},onBackClick:t=>{t!=null&&n(Pe(t)),n(Pe()),n(Tn()),n(ce()),r("../",{relative:"path"})},onSchedulePayment:()=>{n(En())}}}))(ca);function se({isAddACHDrawerOpen:n,isAddWireDrawerOpen:a,isAddAddressDrawerOpen:r}){const t=ne(),o=N(),i=_(),[d,c]=g.useState(!1),{tenantEmailDomain:p}=W(),h=te(),y=k((u=>u.expressPayState.fetchState)),s=k((u=>R(u))),l=k((u=>bn(u))),f=l.expressPayLocalData?.vendorId,m=s.companyId??b.getSignedInUserTenant(p)?.companyId,[P,D]=g.useState(!1),[A,I]=g.useState(!1),[C,w]=g.useState(!1),E=Je(o.state?.pathnameStackToGoBack),{poppedPathname:T}=E,v=T?.split("/"),j=v?.[v.length-1];g.useEffect((()=>{n===!0?D(!0):(D(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{a===!0?I(!0):(I(!1),document.body.style.overflow="auto")}),[a]),g.useEffect((()=>{r===!0?w(!0):(w(!1),document.body.style.overflow="auto")}),[r]),g.useEffect((()=>{y==="Not-Started"&&i(vn(!0,!0))}),[y,i]);const O=ia(l.vendorViewDetails.bankAccountCreationState?.fetchState);if(g.useEffect((()=>{O==="In-Progress"&&l.vendorViewDetails.bankAccountCreationState?.fetchState==="Completed"&&B()}),[O,l.vendorViewDetails.bankAccountCreationState?.fetchState]),b.getSignedInUser()==null)throw Error("Can't access express pay page without signing in...");const S=u=>{c(u)},B=()=>{D(!1),I(!1),t("../",{relative:"path"})};return e.jsxs(Ra,{children:[Te(o)?e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:S}):null,P===!0?e.jsx(ba,{vendorId:f,closeDrawerHandler:B,isDrawerOpen:P}):null,A===!0?e.jsx(Oa,{vendorId:f,closeDrawerHandler:B,isDrawerOpen:A}):null,C===!0?e.jsx(Ea,{closeDrawerHandler:B,isDrawerOpen:C}):null,e.jsx(Da,{vendorId:f,isExpressPayPage:!0}),e.jsx($a,{navigate:t,location:o,companyId:m,accountId:j,analytics:L,currentTenant:s,vendorId:f,roleMap:h?.loggedInUserRoleMap,isSettings:Te(o),expressPayDetails:l,onClickMenuIcon:()=>{S(!0)}})]})}const Ua={overlayWidth:new X(100,100,58)},Fa=({authParams:n,downloadAccountDetailEndPoint:a,isAccountInfoDrawerOpen:r,zeniBankAccountDetail:t,closeDrawerHandler:o})=>{const i=$(),d=z(),c=k((s=>Fe(s))),p=k((s=>R(s)));if(b.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");const h=()=>{o(!0)},y={depositAccount:t,onDismissClick:h,zeniAccountsConfigDetail:c,authParams:n,downloadAccountDetailEndPoint:a,currentTenant:p};return e.jsx(Y,{anchor:"right",open:r,PaperProps:{style:{width:Ua.overlayWidth.valuePercentage(d),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>h(),children:e.jsx(_a,{onClick:s=>s.stopPropagation(),children:e.jsx(la,{...y})})})},_a=U(q)`
|
|
30
30
|
display: flex;
|
|
31
31
|
min-height: 100%;
|
|
32
32
|
flex-direction: column;
|
|
33
|
-
`,za={overlayWidth:new
|
|
33
|
+
`,za={overlayWidth:new X(100,100,58)},an=({isCheckDepositDrawerOpen:n,closeDrawerHandler:a})=>{const r=$(),t=z(),o=_(),i=k((s=>R(s))),d=b.getSignedInUser(),c=i.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=k((s=>_n(s))),y={analytics:L,checkDeposit:h,filesEndPoint:`${we.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:s=>{o(Mn(s))},updateFilesEntity:s=>{o(Ze({files:s}))},onAnotherTransferClick:()=>{o(ge())},onDeleteFile:s=>{o(Ve(s))},onEditFileName:(s,l)=>{o(Me(s,l.split(".")[0]))},onCheckDpositClick:()=>{o(zn())},onDismissClick:()=>{a(!0),o(ge())}};return e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:s=>(l=>l.trackPageLoaded(Ae.Event.accountsDepositCheckFormViewed))(s)}),e.jsx(Y,{anchor:"right",open:n,PaperProps:{style:{width:za.overlayWidth.valuePercentage(t),boxShadow:"none",zIndex:8}},slotProps:{backdrop:{style:{backgroundColor:r.colors.black,opacity:.75,cursor:"pointer"}}},onClose:(s,l)=>(l==="backdropClick"||l==="escapeKeyDown")&&(a(!0),void o(ge())),children:e.jsx(Ma,{onClick:s=>s.stopPropagation(),children:e.jsx(da,{...y})})})]})},Ma=U(q)`
|
|
34
34
|
display: flex;
|
|
35
35
|
min-height: 100%;
|
|
36
36
|
flex-direction: column;
|
|
37
|
-
`,Va={overlayWidth:new
|
|
37
|
+
`,Va={overlayWidth:new X(100,100,58)},Za=ae((function(n,a){const r=a.currentTenant?.companyId;return{plaidConnectionDetails:Gn(n,r,"zeni_accounts","external_account").plaidConnectionDetails,depositAccountListView:Ue(n.depositAccountState,n.depositAccountListState)}}),(function(n,a){return{onReviewClick:()=>n(Wn()),clearReviewTransferDetail:()=>n(Nn()),onFetchLinkTokenClick:r=>{n(Ge("external_account",r))},onEstablishConnectionClick:r=>{n(He(r,a.currentTenant?.companyId,"external_account",void 0,"link_external_account"))}}}))(ua),tn=({isTransferDrawerOpen:n,authParams:a,downloadAccountDetailEndPoint:r,closeDrawerHandler:t,zeniAccountsConfig:o})=>{const i=k((C=>Vn(C))),d=k((C=>R(C))),c=$(),p=z(),h=_(),{accountId:y}=W(),[s,l]=g.useState("achTransfer"),[f,m]=g.useState(!1);if(b.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const{useDynamicConfig:P}=Z(),{configValue:D}=P(G.zeniAccountsConfig),A=fe(D),I=()=>{t(!0),h(je())};return g.useEffect((()=>{i.reviewTransferDetail.fetchState==="Completed"&&m(!0)}),[m,i.reviewTransferDetail.fetchState]),e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:C=>(w=>w.trackPageLoaded(Ae.Event.zeniAccountsTransferFormViewed))(C)}),e.jsx(Y,{onClose:()=>{(s==="achTransfer"&&f===!1||s==="achTransfer"&&f&&i.fetchState==="Completed")&&I()},anchor:"right",open:n,PaperProps:{style:{width:Va.overlayWidth.valuePercentage(p),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:c.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Ha,{onClick:C=>C.stopPropagation(),children:e.jsx(Za,{analytics:L,transferDetails:i,authParams:a,downloadAccountDetailEndPoint:r,onTransferClick:()=>{L.trackTransferBetweenAccountsFormClicked("Transfer",i.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning?"Review Split Transfer":"Review Transfer",i.transferDetailLocalData.transferFrom?.label,i.transferDetailLocalData.transferTo?.label,i.transferDetailLocalData.amount.amount,i.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning,i.reviewTransferDetail.reviewTransferMoney.transferSchedules.length,i.transferDetailLocalData.transferFrom?.accType==="paymentAccount"&&i.transferDetailLocalData.transferTo?.accType==="depositAccount"&&o.zeniAccountsConfigDetail.depositProductConfig.depositProducts?.[0].range?.[1]!=null&&i.transferDetailLocalData.amount.amount>o.zeniAccountsConfigDetail.depositProductConfig.depositProducts[0].range[1]),h(Hn(y))},onDismissClick:I,onSaveChangesToLocalStore:C=>{h(Zn(C))},onAnotherTransferClick:()=>{m(!1),h(je())},currentTenant:d,zeniAccountsConfigDetail:o,currentDrawerContent:s,setCurrentDrawerContent:l,showReviewContent:f,setShowReviewContent:m,onBackClick:()=>{},maxInsuredAmount:A.maxInsuredAmount})})})]})},Ha=U(q)`
|
|
38
38
|
display: flex;
|
|
39
39
|
min-height: 100%;
|
|
40
40
|
flex-direction: column;
|
|
41
|
-
`,
|
|
41
|
+
`,Ga=U.div`
|
|
42
42
|
display: flex;
|
|
43
43
|
min-height: 100%;
|
|
44
44
|
width: 100%;
|
|
@@ -46,7 +46,7 @@ import{j as e}from"./liveblocks-BLPKVqHo.js";import{u as _,h as ne,g as W,i as N
|
|
|
46
46
|
flex-direction: column;
|
|
47
47
|
align-items: center;
|
|
48
48
|
background-color: ${n=>n.theme.colors.grey4};
|
|
49
|
-
`,
|
|
49
|
+
`,Na=ae((function(n,a){return{zeniAccountListView:Ne(n),isExpressPayEnabled:a.isExpressPayEnabled,analytics:a.analytics}}),(function(n,a){const{navigate:r,currentTenant:t,location:o,companyId:i,handleDrawerToggle:d,analytics:c,isBillPayEnabled:p,isDebitCardFeatureEnabled:h}=a,{tenantEmailDomain:y}=t;return{onZeniAccountClick:(s,l)=>{c.trackAccountsListPageClicked("Accounts Row Item Click",l,"active");const f=Wa(y,s),m=ie(o.state?.pathnameStackToGoBack,o.pathname);r(f,{state:{pathnameStackToGoBack:m}})},onSettingsClick:()=>{c.trackAccountsListPageClicked("Settings Icon"),r("setup")},onReloadTransactions:()=>{n(We(!1))},handleMoveMoneyOptionSelection:(s,l)=>{let f="page-not-found";s==="sendMoney"&&(f=cn(y)),s==="payBill"?f=on(t,p,h):s==="transfer"?(f=sn(y),l!=null&&n(Ye(l))):s==="checkDeposit"&&(f=rn(y));const m=ie(o.state?.pathnameStackToGoBack,o.pathname);r(f,{state:{pathnameStackToGoBack:m}})},unlinkPaymentAccount:(s,l)=>{c.trackAccountsListPageClicked("Unlink Account",l),n(qn(s))},onFetchLinkTokenClick:(s,l)=>{n(Ge("external_account",s,l))},onUpdatePaymentAccountStatus:(s,l,f)=>{n(Yn(s,l,"zeni_accounts","external_account",f))},onEstablishConnectionClick:s=>{n(He(s,i,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:s=>{n(Xn(s))},onClickMenuIcon:()=>{d(!0)},onAutoTransferClick:s=>{const l="./auto-transfer";s?r(l,{state:{...o.state,scrollToAddRule:!0}}):r(l)}}}))(ma);function he({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a}){const r=N(),t=ne(),o=_(),i=z(),{tenantEmailDomain:d}=W(),{useDynamicConfig:c,useFeatureGate:p}=Z(),h=$(),{configValue:y}=c(G.zeniAccountsConfig),{isFeatureEnabled:s}=p(V.isDebitCardFeatureEnabled),{isFeatureEnabled:l}=p(V.isAutoTransferRuleEnabled),f=fe(y),m=k((F=>R(F))),P=m.companyId??b.getSignedInUserTenant(d)?.companyId,{configValue:D}=c(G.expressPayConfig),A=D.is_enable_all_tenants===!0||D.tenant_ids!=null&&D.tenant_ids.includes(m.tenantId),[I,C]=g.useState(!1),[w,E]=g.useState(!1),[T,v]=g.useState(!1),[j,O]=g.useState(!1),S=k((F=>Ne(F))),B=S.fetchState,u=k((F=>$e(F))),M=u?.fetchState??"Not-Started",pe=!!m.companyZeniAccountInfo?.info?.isZeniAccountEnabled,oe=te(),H=!!m.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,K=ee(oe?.loggedInUserRoleMap),ln=ye(oe?.loggedInUserRoleMap),dn=!!m.companyBillPayInfo?.info?.isBillPayEnabled,De=b.getSignedInUser(),un={userId:De?.userId??"",sessionId:De?.zeniSessionId??"",tenantId:m.tenantId??""},pn=`${Ce}/account_details`,{areTenantIdsInSync:ke}=pa();g.useEffect((()=>{!I&&ke&&(C(!0),o(We(!1)))}),[I,o,B,ke]),g.useEffect((()=>{!w&&M==="Not-Started"&&P&&(E(!0),o(_e(!0)))}),[w,M,P,o]),g.useEffect((()=>{n!=null&&n===!0?v(!0):(v(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const Ie=()=>{v(!1),t("..")},[mn,gn]=g.useState(!1),Se=F=>{gn(F)},{isAiCfoAccessEnabled:hn,onAskAiCfoClick:fn}=nn({mobileExploreReferrer:"Checking Accounts"});Qe({isDataReady:B==="Completed"});const yn=Xe(m),xn=xe(s,m);return yn===!0&&xn!==!0?e.jsx(en,{}):pe?e.jsxs(e.Fragment,{children:[S.fetchState==="Completed"&&T===!1&&j===!1?e.jsx(de,{analytics:L,onLoad:F=>(Cn=>{Cn.trackAccountsListPageViewed(S.depositAccountsSelectorView.depositAccounts.length,S.externalAccountsSelectorView.paymentAccounts.length,Be(S.summary?.totalBalance.available.amount??0),Be(S.summary?.totalInterest.available.amount??0),S.zeniAccountsConfig.zeniAccountsConfigDetail.annualPercentageYield)})(F)}):null,T===!0?e.jsx(tn,{closeDrawerHandler:Ie,isTransferDrawerOpen:T,zeniAccountsConfig:S.zeniAccountsConfig,authParams:un,downloadAccountDetailEndPoint:pn}):null,j===!0?e.jsx(an,{closeDrawerHandler:Ie,isCheckDepositDrawerOpen:j}):null,e.jsxs(Ga,{windowSize:i,children:[e.jsx(ue,{isAppContentDrawerOpen:mn,handleDrawerToggle:Se}),e.jsx(Na,{zeniBankListView:S,navigate:t,currentTenant:m,location:r,companyId:P,analytics:L,maxInsuredAmount:f.maxInsuredAmount,isExpressPayEnabled:A,isBillPayEnabled:dn,isDebitCardFeatureEnabled:s,isAutoTransferRuleEnabled:l,handleDrawerToggle:Se,isAiCfoAccessEnabled:hn,onAskAiCfoClick:fn})]})]}):H&&K?e.jsx(Q,{to:"../setup"}):m.companyZeniAccountInfo?.info&&!H&&ln?e.jsx(Q,{to:"../promo",state:r.state}):e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:h.colors.grey5}})}const on=(n,a,r)=>{const t=xe(r,n),{tenantEmailDomain:o}=n;return t===!0||a===!1?`/${o}/bills`:`/${o}/bill/new`},Wa=(n,a)=>`/${n}/checking/${a}`,sn=(n,a)=>a==null?`/${n}/checking/transfer`:`/${n}/checking/${a}/transfer`,rn=(n,a)=>a==null?`/${n}/checking/check-deposit`:`/${n}/checking/${a}/check-deposit`,cn=n=>`/${n}/checking/express-pay`,Xa=U.div`
|
|
50
50
|
display: flex;
|
|
51
51
|
width: 100%;
|
|
52
52
|
flex: 1 1 auto;
|
|
@@ -54,4 +54,4 @@ import{j as e}from"./liveblocks-BLPKVqHo.js";import{u as _,h as ne,g as W,i as N
|
|
|
54
54
|
align-items: center;
|
|
55
55
|
min-height: 100vh;
|
|
56
56
|
background-color: ${n=>n.theme.colors.grey4};
|
|
57
|
-
`,
|
|
57
|
+
`,Ya=ae((function(n,a){const{currentTenant:r}=a,t=qe(n,a.accountId),o=b.getSignedInUser(),i=n.tenantState.currentTenantId,d={userId:o?.userId??"",sessionId:o?.zeniSessionId??"",tenantId:i??""},c=t.accountDetail?.id??"";return{currentTenantCompanyName:r.companyName??"",authParams:d,downloadEndPoint:`${we.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${c}`,zeniAccountDetail:t,isExpressPayEnabled:a.isExpressPayEnabled,fetchState:t.fetchState}}),(function(n,a){const{navigate:r,currentTenant:t,location:o,accountId:i}=a,{tenantEmailDomain:d}=t;return{handleMoveMoneyOptionSelection:(c,p)=>{let h="page-not-found";c==="sendMoney"?h=cn(d):c==="payBill"?h=on(t,a.isBillPayEnabled,a.isDebitCardFeatureEnabled):c==="transfer"?(h=sn(d,i),p!=null&&n(Ye(p))):c==="checkDeposit"?(h=rn(d,i),p!=null&&n(Kn(p))):c==="accountStatement"&&(h=Ka(d,i));const y=ie(o.state?.pathnameStackToGoBack,o.pathname);r(h,{state:{pathnameStackToGoBack:y}})},onAccountDetailClick:()=>{const c=qa(d,i),p=ie(o.state?.pathnameStackToGoBack,o.pathname);r(c,{state:{pathnameStackToGoBack:p}})},onEditNameClick:c=>{n(Ee(i,"editName",c))},onReloadZeniAccountDetailPage:()=>{n(Ke(i,!1))},onCloseAccountClick:()=>{n(Ee(i,"closeAccount",""))},onBackClick:()=>{r("../",{relative:"path"})}}}))(ga);function re({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a,isAccountInfoDrawerOpen:r}){const t=N(),o=ne(),i=_(),d=z(),{tenantEmailDomain:c,accountId:p}=W(),{useDynamicConfig:h}=Z(),{useFeatureGate:y}=Z(),{isFeatureEnabled:s}=y(V.isDebitCardFeatureEnabled),l=k((K=>R(K))),{configValue:f}=h(G.expressPayConfig),m=f.is_enable_all_tenants===!0||f.tenant_ids!=null&&f.tenant_ids.includes(l.tenantId),P=!!l.companyBillPayInfo?.info?.isBillPayEnabled,D=b.getSignedInUser(),A=l.companyId??b.getSignedInUserTenant(c)?.companyId,I={userId:D?.userId??"",sessionId:D?.zeniSessionId??"",tenantId:l.tenantId??""},C=`${Ce}/account_details`,[w,E]=g.useState(!1),[T,v]=g.useState(!1),[j,O]=g.useState(!1),[S,B]=g.useState(!1),u=k((K=>qe(K,p??""))),M=u.fetchState,{isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe}=nn({mobileExploreReferrer:"Checking Account Detail"});Qe({isDataReady:M==="Completed"}),g.useEffect((()=>{w||(i(Ke(p??"",!1)),E(!0))}),[w,i,M]),g.useEffect((()=>{B(r!=null&&r===!0)}),[r]),g.useEffect((()=>{n!=null&&n===!0?v(!0):(v(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const H=()=>{B(!1),o("..")};return e.jsxs(e.Fragment,{children:[S===!0&&u.accountDetail!=null?e.jsx(Fa,{authParams:I,downloadAccountDetailEndPoint:C,closeDrawerHandler:H,isAccountInfoDrawerOpen:S,zeniBankAccountDetail:u.accountDetail}):null,T===!0?e.jsx(tn,{closeDrawerHandler:H,isTransferDrawerOpen:T,zeniAccountsConfig:u.zeniAccountsConfig,authParams:I,downloadAccountDetailEndPoint:C}):null,j===!0?e.jsx(an,{closeDrawerHandler:H,isCheckDepositDrawerOpen:j}):null,e.jsx(Xa,{windowSize:d,children:e.jsx(Ya,{navigate:o,currentTenant:l,location:t,companyId:A,isDebitCardFeatureEnabled:s,accountId:p??"",isBillPayEnabled:P,isExpressPayEnabled:m,isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe})})]})}const qa=(n,a)=>`/${n}/checking/${a}/account-info`,Ka=(n,a)=>`/${n}/checking/${a}/statements`,Ja=ae((function(n,a){const{companyId:r}=a;return{zeniAccountSetupView:Jn(n,r)}}),(function(n,a){const{navigate:r,companyId:t}=a;return{onSetupButtonClick:()=>{L.trackAccountsPromoPageClicked("Setup Accounts"),n(Qn(t))},onBackClick:()=>{r("../..",{relative:"path"})},onSetupZeniAccountSuccess:()=>{r("../setup",{relative:"path"})}}}))(ya),Qa=()=>{const n=ne(),a=N(),{tenantEmailDomain:r}=W(),{useDynamicConfig:t}=Z(),o=ha(),i=$(),[d,c]=g.useState(!1),[p,h]=g.useState(!1),y=k((w=>R(w))),{configValue:s}=t(G.zeniAccountsConfig),l=fe(s);g.useEffect((()=>{p===!1&&a.state?.message==="activation"&&h(!0)}),[a.state]);const f=b.getSignedInUserTenant(r)?.companyId??y.companyId,m=b.getSignedInUser(),P=!!y.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,D=w=>{c(w)};if(m==null)throw Error("Can't access Zeni account promo page without signing in...");const A=te(),I=ee(A?.loggedInUserRoleMap),C=ye(A?.loggedInUserRoleMap);if(P&&I)return e.jsx(Q,{to:"../../checking/setup"});if(y.company?.companyZeniAccountInfo&&(!P&&I||C)){if(a.state?.message==="activation"){const w=Je(a.state?.pathnameStackToGoBack);n(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:w.newStack}})}return e.jsxs(e.Fragment,{children:[e.jsx(fa,{showConfetti:p}),e.jsx(de,{analytics:L,onLoad:w=>(E=>E.trackPageLoaded(Ae.Event.accountsPromoPageViewed))(w)}),e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:D}),e.jsx(Ja,{analytics:L,navigate:n,companyId:f,meetingUrl:o("zeni_accounts_promo"),onClickMenuIcon:()=>{D(!0)},maxAnnualPercentageYield:l.maxAnnualPercentageYield,maxInsuredAmount:l.maxInsuredAmount,exampleBankBalance:3e6})]})}return e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:i.colors.grey5}})};function jt(){const n=N(),a=k((S=>R(S))),r=$(),{useFeatureGate:t,useDynamicConfig:o}=Z(),i=te(),d=ee(i?.loggedInUserRoleMap),c=ye(i?.loggedInUserRoleMap),p=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled,h=!!a.company?.companyZeniAccountInfo?.isZeniAccountTOSAccepted,{isFeatureEnabled:y}=t(V.isChargeCardFeatureEnabled),{isFeatureEnabled:s}=t(V.isDebitCardFeatureEnabled),l=Xe(a),f=xe(s,a),m=a?.userRole!=null&&ea(a?.userRole),P=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!m)&&na(i?.loggedInUserRoleMap),D=aa(i?.loggedInUserRoleMap),A=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!m)&&ta(i?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!m,{configValue:C}=o(G.expressPayConfig),w=C.is_enable_all_tenants===!0||C.tenant_ids!=null&&C.tenant_ids.includes(a.tenantId),{isFeatureEnabled:E}=t(V.isAutoTransferRuleEnabled),T=xa(a,y,s)&&!m&&oa(i?.loggedInUserRoleMap),v=sa(i?.loggedInUserRoleMap),j=I&&ee(i?.loggedInUserRoleMap),O=j||ze(i?.loggedInUserRoleMap);return e.jsxs(Re,{children:[e.jsx(x,{path:"setup",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"setup"})}),e.jsx(x,{path:"verification",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"verification"})}),E?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"auto-transfer",element:e.jsx(Le,{})}),O?e.jsx(x,{path:"auto-transfer/:ruleId/edit",element:e.jsx(Le,{isEditDrawerOpen:!0})}):null]}):e.jsx(x,{path:"auto-transfer",element:e.jsx(J,{})}),w&&d?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"express-pay",element:e.jsx(se,{})}),e.jsx(x,{path:"express-pay/add-ach",element:e.jsx(se,{isAddACHDrawerOpen:!0})}),e.jsx(x,{path:"express-pay/add-wire/add-address",element:e.jsx(se,{isAddAddressDrawerOpen:!0})}),e.jsx(x,{path:"express-pay/add-wire",element:e.jsx(se,{isAddWireDrawerOpen:!0})})]}):e.jsx(x,{path:"express-pay",element:e.jsx(J,{})}),e.jsx(x,{path:"promo",element:e.jsx(Qa,{})}),l&&!f?e.jsx(x,{path:"/*",element:e.jsx(en,{})}):p?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"/",element:e.jsx(he,{})}),e.jsx(x,{path:"transfer",element:e.jsx(he,{isTransferDrawerOpen:!0})}),e.jsx(x,{path:"check-deposit",element:e.jsx(he,{isCheckDepositDrawerOpen:!0})}),e.jsx(x,{path:"cash_management/*",element:e.jsx(J,{})}),e.jsx(x,{path:":accountId/*",element:e.jsx(et,{})}),e.jsx(x,{path:"*",element:e.jsx(J,{})})]}):h&&d?e.jsx(x,{path:"*",element:e.jsx(Q,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&c?e.jsx(x,{path:"*",element:e.jsx(Q,{to:"../promo",state:n.state})}):e.jsx(x,{path:"*",element:e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:r.colors.grey5,boxShadow:`0px 2px ${Ca.sp1} ${r.colors.dropShadowNormal}`}})})]})}function et(){return e.jsxs(Re,{children:[e.jsx(x,{path:"/",element:e.jsx(re,{})}),e.jsx(x,{path:"account-info",element:e.jsx(re,{isAccountInfoDrawerOpen:!0})}),e.jsx(x,{path:"transfer",element:e.jsx(re,{isTransferDrawerOpen:!0})}),e.jsx(x,{path:"check-deposit",element:e.jsx(re,{isCheckDepositDrawerOpen:!0})}),e.jsx(x,{path:"statements",element:e.jsx(Ia,{})}),e.jsx(x,{path:"*",element:e.jsx(J,{})})]})}export{jt as default};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import{j as i}from"./liveblocks-Cmn0IneY.js";import{a as u}from"./sentry-D-L93P51.js";import{h as $,u as x,g as T,i as j,j as p}from"./core-BAlzhg_1.js";import{Tr as s,Tq as v,$P as B,fI as C,$Q as E}from"./zeni-epic-state-CGi26_dN.js";import{a1 as P,ae as g,E as z,z as D,a7 as L,d5 as N,a4 as U}from"./index-1u2aDJ3l.js";import{n as _}from"./mui-BP68m4Fu.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]="49e6578f-b859-41c7-804b-01c339f9a758",e._sentryDebugIdIdentifier="sentry-dbid-49e6578f-b859-41c7-804b-01c339f9a758")}catch{}})();const G=_.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 F(){const e=$(),n=x(),d=P(),l=T();let{accountId:a}=j(),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,y]=u.useState(!1),h=z();u.useEffect((()=>{m||(y(!0),n(v(a??"",!1)))}),[m,n]);const o=p((t=>B(t,a??""))),b=()=>{const t=U(l.state?.pathnameStackToGoBack),S=t.poppedPathname??"..";e(S,{state:{pathnameStackToGoBack:t.newStack}})},r=D.getSignedInUser(),c=p((t=>C(t))),I={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:c.tenantId??""},w=E(a??"")===!0?s:o.zeniAccountDetail?.accountLast4??"",k=c.company?.companyInfo.companyLegalName??c.companyName;if(r==null)throw Error("Can't access address page without signing in...");return o.fetchState!=="Completed"?i.jsx(L,{fetchState:"In-Progress",style:{backgroundColor:h.colors.grey5}}):i.jsx(G,{windowSize:d,children:i.jsx(N,{currentTenantCompanyName:k,statementListView:o,accountLast4:w,onBackClick:b,authParams:I,downloadEndPoint:f})})}export{F as Z};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./sentry-
|
|
1
|
+
import"./sentry-D-L93P51.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};
|