PageSourceSearch

https://dashboard.velocity.in/assets/payment_requests-0Vr6IxXD.js

js velocity.in collected 2026-09-24 09:24:00 UTC 5,124 bytes, 1 lines download raw bytes

1import{j as s,aP as N,aA as g,c as u,u as R,q as A,r as _,eZ as D,U as L,n as S,bk as w,W as q,fa as I}from"./index-2CwtICst.js";import{g as y,a as M}from"./utils-Byo2OGEK.js";import{N as T}from"./new_payment_request-B8V54bjs.js";import{I as z,a as Y,b as F}from"./common_card_components-COGB2mOb.js";import{s as x}from"./pdc_request_card.module-cPafQjEb.js";import{C as l}from"./col-MZTILiOt.js";import{b as v,u as U,c as V}from"./index-keUnVeur.js";import{L as k}from"./index-b1S956hI.js";import{I as H}from"./infinte_scroll_container-CISyZ_Tc.js";import{a as O,s as e}from"./payment_requests.module-4gzMCwOR.js";import{g as $}from"./format_date_utils-BWqE6PUs.js";import{C as B}from"./index-B1EyPq4z.js";import{A as E}from"./index-D3pD5RCc.js";import"./react-number-format.es-Dr0FQMRn.js";import"./index-CbaIGfG_.js";import"./form_utils-BRD3em_d.js";import"./formik_datepicker-BZ3K44eB.js";/* empty css               */import"./index-B3E771uX.js";import"./api-GdgXwhxd.js";import"./forms-DgYER9IY.js";import"./index-B_cFQWv_.js";import"./DeleteOutlined-DFutYCzo.js";import"./DownloadOutlined-DTidZHln.js";import"./progress-BiVrF1Ei.js";import"./rbac_button_wrapper-CHcGGTW3.js";import"./new_payment_request.module-CtIR-xi7.js";import"./modal_component-CQ9TsgKw.js";import"./modal_header-Zzno9Dew.js";import"./index-BC4zRIry.js";import"./DialogWrap-DDRffVA8.js";import"./Portal-m7W4unkL.js";import"./getScrollBarSize-CHB1zEd-.js";import"./useId-BeW6vcu-.js";import"./Skeleton-DmHcwJm8.js";import"./index-DaN20Aem.js";import"./Dropdown-CSDSyzzq.js";import"./PlusOutlined-ByZyTB3m.js";const W="_tabSummaryContainer_1slno_10",K="_summaryLabel_1slno_18",Z="_summaryValue_1slno_22",o={tabSummaryContainer:W,summaryLabel:K,summaryValue:Z},G=({ActionComponents:t,dataTitle1:a,dataValue1:m,dataTitle2:i,dataValue2:r})=>s.jsxs("div",{className:o.tabSummaryContainer,children:[s.jsxs("div",{children:[s.jsx("div",{className:o.summaryLabel,children:a}),s.jsx("div",{className:o.summaryValue,children:m>=0?y(parseFloat(m)):"NA"})]}),s.jsxs("div",{children:[s.jsx("div",{className:o.summaryLabel,children:i}),s.jsx("div",{className:o.summaryValue,children:r>=0?y(parseFloat(r)):"NA"})]}),t&&s.jsx("div",{children:s.jsx(t,{})})]});function J(t){const{item:a}=t;if(a)return s.jsx("div",{className:x.cardContainer,children:s.jsxs(N,{gutter:0,align:"middle",children:[s.jsx(l,{span:8,children:s.jsx(z,{title:a.buyer_name})}),s.jsx(l,{span:8,children:s.jsx(Y,{invoiceAmount:a.amount})}),s.jsx(l,{span:8,children:s.jsx(F,{date:a.due_date})})]})})}const Q=()=>{const t=g().format("YYYY-MM-DD"),{isLoading:a,upcomingPdcRequests:m}=v({status:"authorized",business_type:"seller",due_date:t}),i=m;return a?s.jsx(u,{}):s.jsx(k,{split:!0,rowKey:r=>r.uuid,dataSource:i,renderItem:r=>s.jsx(J,{item:r})})},X=()=>{const t=O();return s.jsx(N,{gutter:0,align:"middle",className:x.headerRow,children:t.map(a=>s.jsx(l,{span:a.size,children:s.jsx("span",{className:x.listHeader,children:a.title})},a.key))})};function Fs(){const[t,a]=R(),m=A(t),{dueAmountOnDateFilter:i,totalPendingAmount:r}=U({business_type:"seller"}),{isLoading:d,pendingApprovalPdcs:c}=V({pending:"true",business_type:"seller"}),f=g().format("YYYY-MM-DD"),{upcomingPdcRequests:p}=v({status:"authorized",business_type:"seller",due_date:f}),j=p==null?void 0:p.length,[b,h]=_.useState(!1),C=()=>{!d&&I(meta)&&a({...m,pageNumber:1})};if(d)return s.jsx(u,{showText:!1});const P=()=>s.jsx(q,{className:e.newPaymentRequest,size:"medium",onClick:()=>h(!0),children:"New Payment Request"});return s.jsxs("div",{className:e.mainContainer,children:[b&&s.jsx(T,{onClose:()=>h(!1)}),s.jsx(G,{dataTitle1:"Total Pending",dataValue1:r,dataTitle2:"Due in 7 days",dataValue2:i,ActionComponents:P}),s.jsx("div",{className:e.totalNewRequestDiv,children:d?s.jsx("div",{className:e.totalRecordsLoading,children:s.jsx(u,{size:"small",showText:!1})}):s.jsxs("div",{className:e.recordsCount,children:[s.jsx(D,{className:e.radioIcon})," Pending Approval (",c==null?void 0:c.length,")"]})}),s.jsx("div",{className:e.pdcRequestsList,children:c.map(n=>s.jsx(l,{span:6,children:s.jsx(B,{className:e.pdcRequestCard,bordered:!0,children:s.jsxs("div",{children:[s.jsxs("div",{className:e.pendingApproval,children:[s.jsx("p",{className:e.requestFrom,children:"Request from"}
1)," ",s.jsx("p",{children:s.jsx(E,{size:"30",className:e.nameAvatar,children:L(n.buyer_name||"User")})})]}),s.jsx("div",{children:s.jsx("p",{className:e.buyerName,children:(n==null?void 0:n.buyer_name)||"User"})}),s.jsxs("p",{className:e.amount,children:[M(n.amount)," "]}),s.jsxs("p",{className:e.dueOn,children:[" ","Due on ",s.jsx("b",{children:$(n.due_date,"DD MMM")})," "]})]})})}))}),s.jsx("div",{className:e.totalNewRequestDiv,children:d?s.jsx("div",{className:e.totalRecordsLoading,children:s.jsx(u,{size:"small",showText:!1})}):s.jsxs("div",{className:e.recordsCount,children:[s.jsx("img",{className:e.paymentReqSuccessImg,src:S("payment_req_success.svg"),alt:"Success"}),s.jsxs("span",{children:["Upcoming ",w("Payment",j)," (",j,")"]})]})}),s.jsx(X,{}),s.jsx(H,{loadMore:C,current_page:"1",PageComponent:Q})]})}export{Fs as Component};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.