1"use strict";(self.webpackChunkchc_online_banking_app=self.webpackChunkchc_online_banking_app||[]).push([[619],{49619:function(e,t,n){n.r(t),n.d(t,{default:function(){return k}});var a=n(1413),i=(n(34706),n(58642)),r=n(17485),s=n(21739),c=n(57604),d=n(26186),l=n(19044),m=n(53805),o=n(23588),y=n(2636),p=n(12466),u=n(74689),P=n(13876),h=n(10161),_={SENTTOBANK:"Sent to bank",AWAITINGAPPROVAL:"Awaiting approval",REJECTED:"Rejected"},v=function(e){var t=e.paymentInformation,n=t.paymentCurrency,a=t.amount,i=t.amountCurrency,r=t.valueDate,s=t.status,c=t.remitAccountDetails,d=c.accountNumber,l=c.sortCode,m=t.paymentType;return(0,h.jsxs)("div",{className:"PaymentInformation",children:[(0,h.jsx)("div",{className:"PrintPayment__header","data-testid":"print-payment-header-payment-info",children:"Payment information"}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-payment-account",children:"From account:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-payment-account",children:(0,h.jsx)(u.Z,{bankAccount:{accountNumber:d,sortCode:l},testIdModifier:"from"})})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-payment-currency",children:"Amount:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-payment-currency",children:(0,h.jsx)(P.Z,{value:a,currency:i||n})})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-payment-date",children:"Payment date:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-payment-date",children:(0,p.p6)(r)})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-payment-type",children:"Payment type:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-payment-type",children:y.Z[m]})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-payment-status",children:"Payment status:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-payment-status",children:_[s]||s})]})]})},f=n(18110),j=n(50030),x=function(e){var t=e.paymentDetails,n=t.bulkBeneficiaryDetails,a=t.groupName||t.fileInfo.fileName;return(0,h.jsxs)("div",{className:"BulkBeneficiaryInformation","data-testid":"bulk-beneficiary-information",children:[(0,h.jsx)("div",{className:"PrintPayment__header",children:"Beneficiaries information"}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-to",children:"To:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-to",children:a})]}),(0,h.jsx)("div",{className:"PrintPayment__row",children:(0,h.jsxs)("table",{className:"PrintPayment__table",children:[(0,h.jsx)("thead",{children:(0,h.jsxs)("tr",{children:[(0,h.jsx)("th",{children:"Beneficiary name"}),(0,h.jsx)("th",{children:"Account number"}),(0,h.jsx)("th",{children:"Sort code"}),(0,h.jsx)("th",{children:"Reference"}),(0,h.jsx)("th",{children:"Amount"})]})}),(0,h.jsx)("tbody",{children:n.map((function(e,t){var n=e.name,a=e.accountNumber,i=e.sortCode,r=e.amount,s=e.reference;return(0,h.jsxs)("tr",{children:[(0,h.jsx)("td",{children:n}),(0,h.jsx)("td",{children:a}),(0,h.jsx)("td",{children:i}),(0,h.jsx)("td",{children:(0,h.jsx)("div",{children:s||"No Reference"})}),(0,h.jsx)("td",{children:(0,h.jsx)(P.Z,{value:r,currency:j.hi})})]},t)}))})]})})]})},N=n(76421),w=function(e){var t=e.paymentDetails.beneficiaryDetails,n=t.beneficiaryAccount,a=t.reference,i=t.beneficiaryName,r=(0,N.values)(a).some((function(e){return!!e}));return(0,h.jsxs)("div",{className:"IntlBeneficiaryInformation",children:[(0,h.jsx)("div",{className:"PrintPayment__header","data-testid":"print-payment-header-int-beneficiary-information",children:"Beneficiary information"}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-int-beneficiary-name",children:"Beneficiary:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-int-beneficiary-name",children:i})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-int-beneficiary-account",children:"Beneficiary account:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-int-beneficiary-account",children:(0,h.jsx)(u.Z,{bankAccount:{accountNumber:n},testIdModifier:"to"})})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-int-beneficiary-reference",children:"Reference:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-int-beneficiary-reference",children:r?(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)("div",{"data-testid":"print-payment-int-beneficiary-reference1",children:a.line1}),(0,h.jsx)("div",{"data-testid":"print-payment-int-beneficiary-reference2",children:a.line2}),(0,h.jsx)("div",{"data-testid":"print-payment-int-beneficiary-reference3",children:a.line3}),(0,h.jsx)("div",{"data-testid":"print-payment-int-beneficiary-reference4",children:a.line4})]}):(0,h.jsx)("div",{"data-testid":"print-payment-int-beneficiary-no-reference",children:"No Reference"})})]})]})},b=function(e){var t=e.paymentDetails,n=e.paymentType;if((0,f.Gt)(n)||(0,f.QJ)(n))return(0,h.jsx)(x,{paymentDetails:t});if((0,f._L)(n))return(0,h.jsx)(w,{paymentDetails:t});
1var a=t.beneficiaryDetails,i=a.beneficiaryName,r=a.accountNumber,s=a.sortCode,c=a.reference.line1;return(0,h.jsxs)("div",{className:"BeneficiaryInformation",children:[(0,h.jsx)("div",{className:"PrintPayment__header","data-testid":"print-payment-header-beneficiary-information",children:"Beneficiary information"}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-beneficiary-name",children:"Beneficiary:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-beneficiary-name",children:i})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-beneficiary-account",children:"Beneficiary account:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-beneficiary-account",children:(0,h.jsx)(u.Z,{bankAccount:{accountNumber:r,sortCode:s},testIdModifier:"to"})})]}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-beneficiary-reference",children:"Reference:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-beneficiary-reference",children:(0,h.jsx)("div",{"data-testid":"".concat(c?"print-payment-int-beneficiary-reference":"print-payment-beneficiary-no-reference"),children:c||"No Reference"})})]})]})},A=n(20330),I=n(56884),C=n(20875),D=n(91538),k=function(){(0,l.t)(D.Z.PRINT_PAYMENT);var e=(0,c.l)(),t=e.paymentId,n=e.paymentType,y=(0,d.q)({paymentId:t});if((0,r.v9)(m.lR)===C.N9.FETCHING_PAYMENT_DETAILS)return(0,h.jsx)(o.Z,{content:"Loading..."});if(!y)return null;var p=y.remitAccountDetails,P=p.accountName,_=p.sortCode,f=p.accountNumber,j=y.chargeAccountDetails||y.chargeAccountDetails||y.chargeAccountDetails;return(0,h.jsxs)(i.Z,{children:[(0,h.jsx)(s.q,{children:(0,h.jsx)("title",{"data-testid":"title",children:"Print payment - C. Hoare & Co."})}),(0,h.jsxs)("div",{className:"PrintPayment",children:[(0,h.jsx)("h2",{className:"sr-only",children:"Print payment information"}),(0,h.jsx)(A.Z,{testId:"print-payment-button",variant:"primary",className:"print-button",onClick:function(){window.print()},children:"Print"}),(0,h.jsx)("h1",{className:"PrintPayment__title",children:"Payment"}),(0,h.jsxs)("div",{className:"PrintPayment__account-info",children:[(0,h.jsxs)("div",{className:"PrintPayment__account-holder",children:[P," ",(0,h.jsx)("span",{children:"\xa0\xa0-\xa0\xa0"})]}),(0,h.jsxs)("div",{className:"PrintPayment__account-number",children:[f,_&&(0,h.jsxs)("span",{children:[(0,h.jsx)("span",{children:"\xa0\xa0|\xa0\xa0"})," ",(0,I.IY)(_)]})]})]}),(0,h.jsx)(v,{paymentInformation:(0,a.Z)((0,a.Z)({},y),{},{paymentType:n})}),(0,h.jsx)(b,{paymentDetails:y,paymentType:n}),j&&(0,h.jsxs)("div",{className:"PrintPayment__account-info",children:[(0,h.jsx)("div",{className:"PrintPayment__header",children:"Charge account information"}),(0,h.jsxs)("div",{className:"PrintPayment__row",children:[(0,h.jsx)("div",{className:"PrintPayment__row-title","data-testid":"print-payment-row-title-ch-account",children:"Charge account:"}),(0,h.jsx)("div",{className:"PrintPayment__row-value","data-testid":"print-payment-row-value-ch-account",children:(0,h.jsx)(u.Z,{bankAccount:{accountNumber:j.accountNumber,sortCode:j.sortCode,name:j.accountName},testIdModifier:"charge"})})]})]})]})]})}}}]);
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.