@hmcts/ccpay-web-component 5.2.10-beta4 → 5.2.10-beta5
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/bundles/hmcts-ccpay-web-component.umd.js +6 -6
- package/bundles/hmcts-ccpay-web-component.umd.js.map +1 -1
- package/bundles/hmcts-ccpay-web-component.umd.min.js +1 -1
- package/bundles/hmcts-ccpay-web-component.umd.min.js.map +1 -1
- package/esm2015/lib/components/case-transactions/case-transactions.component.js +7 -7
- package/fesm2015/hmcts-ccpay-web-component.js +6 -6
- package/fesm2015/hmcts-ccpay-web-component.js.map +1 -1
- package/hmcts-ccpay-web-component.metadata.json +1 -1
- package/lib/components/case-transactions/case-transactions.component.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["PaymentLibService","prototype","setApiRootUrl","apiRoot","this","API_ROOT","getApiRootUrl","setBulkScanApiRootUrl","bulkscanapiRoot","BULKSCAN_API_ROOT","getBulkScanApiRootUrl","setRefundndsApiRootUrl","refundsapiRoot","REFUNDS_API_ROOT","getRefundsApiRootUrl","setNoticationApiRootUrl","notificationapiRoot","NOTIFICATION_API_ROOT","getNoticationApiRootUrl","setCardPaymentReturnUrl","cardPaymentReturnUrl","CARDPAYMENTRETURNURL","getCardPaymentReturnUrl","type","Injectable","args","providedIn","OrderslistService","ordersList","BehaviorSubject","refundView","caseType","getcaseType","asObservable","feeExists","getFeeExist","ccdCaseNumber","getCCDCaseNumberforRefund","isFromServiceRequestPage","getisFromServiceRequestPage","OrderRefId","getOrderRefId","navigationPage","getnavigationPage","orderRef","getorderRef","orderCCDEvent","getorderCCDEvent","orderCreated","getorderCreated","orderParty","getorderParty","orderRemissionTotal","getorderRemissionTotal","orderFeesTotal","getorderFeesTotal","orderTotalPayments","getorderTotalPayments","rolesList","orderDetail","paymentPageView","setOrdersList","orderLevelFees","next","Object","assign","getOrdersList","setRefundView","refundList","getRefundView","setCaseType","getCaseType","setCCDCaseNumber","getCCDCaseNumber","setFeeExists","getFeeExists","setisFromServiceRequestPage","getisFromServiceRequestPages","setOrderRefId","getSelectedOrderRefId","setnavigationPage","getnavigationPageValue","setpaymentPageView","paymentpageList","getpaymentPageView","setUserRolesList","getUserRolesList","setorderDetail","getorderDetail","setOrderRef","getorderRefs","setorderCCDEvent","getorderCCDEvents","setorderCreated","getorderCreateds","setorderParty","getorderPartys","setorderRemissionTotal","getorderRemissionTotals","setorderFeesTotal","getorderFeesTotals","setorderTotalPayments","getoorderTotalPaymentss","PaymentLibComponent","paymentLibService","cd","unProcessedPaymentServiceId","isFromPayBubble","unProcessedPayment","orderPendingPayments","ngAfterContentChecked","detectChanges","ngOnInit","LOGGEDINUSERROLES","length","PAYMENT_GROUP_REF","paymentGroupReference","DCN_NUMBER","bspaymentdcn","REFUNDLIST","VIEW","viewName","isTakePayment","TAKEPAYMENT","Component","selector","template","ChangeDetectorRef","Input","CCD_CASE_NUMBER","EXC_REFERENCE","PAYMENT_METHOD","VIEWSERVICE","SERVICEREQUEST","SELECTED_OPTION","ISBSENABLE","ISSFENABLE","ISTURNOFF","CASETYPE","ISPAYMENTSTATUSENABLED","rootUrl","USERID","LOGGEDINUSEREMAIL","ErrorHandlerService","handleError","err","errorMessage","error","Error","message","status","undefined","JSON","parse","statusCode","messsage","stringify","throwError","getServerErrorMessage","isErrorExist","isDataNotExist","title","body","showError","LoggerService","invokeConsoleMethod","PaymentListService","http","logger","errorHandlerService","getPaymentByCcdCaseNumber","paymentMethod","info","get","withCredentials","pipe","catchError","HttpClient","PaymentListComponent","paymentListService","paymentLibComponent","_this","subscribe","payments","loadPaymentViewComponent","paymentReference","create","__values","o","s","Symbol","iterator","m","i","call","value","done","TypeError","WebComponentHttpClient","meta","post","url","options","opts","addHeaders","put","delete","patch","csrfToken","getTag","headers","forEach","element","document","cookie","split","find","row","startsWith","content","HttpHeaders","responseType","Meta","PaymentViewService","https","getPaymentDetails","getPaymentGroupDetails","getApportionPaymentDetails","getPBAaccountDetails","postWays2PayCardPayment","serviceRef","rurl","replace","postPBAaccountPayment","randomKey","Math","random","toString","join","postBSPayments","postBSUnidentifiedPayments","postBSUnsolicitedPayments","postBSAllocationPayments","postPaymentGroupWithRemissions","feeId","deleteFeeFromPaymentGroup","postPaymentToPayHub","paymentGroupRef","postPaymentAntennaToPayHub","downloadSelectedReport","reportName","startDate","endDate","downloadFailureReport","getBSfeature","getSiteID","getPartyDetails","caseNumber","postRefundsReason","postPaymentGroupWithRetroRemissions","postRefundRetroRemission","getPaymentFailure","NotificationService","getRefundNotification","reference","getAddressByPostcode","postcode","getNotificationPreview","getNotificationInstructionType","paymentChannel","PostRefundRetroRemission","contact_details","fees","payment_reference","refund_reason","total_refund_amount","is_over_payment","PaymentViewComponent","paymentViewService","notificationService","isRefundRemission","isAddFeeBtnEnabled","isIssueRefunfBtnEnable","allowedRolesToAccessRefund","remissions","allPaymentsFailure","isContinueBtnDisabled","selectedOption","dcnNumber","isTurnOff","serviceReference","viewStatus","paymentGroup","fee","isRemissionsMatch","rem","fee_code","code","push","paymentFees","filter","paymentGroupObj","includes","paymentAllocation","payment_allocation","isStatusAllocated","allocation_status","res","payment_failure_list","reverse","payment_failure_initiated","payment_failure_closed","e","errorMsg","defineProperty","method","channel","goToPaymentList","getOverPaymentValue","feesOverPayment","over_payment","goToServiceRequestPage","window","location","reload","goToCaseTransationPage","event","preventDefault","data","resetOrderData","addRemission","chkIsAddRemissionBtnEnable","payment","isFromPaymentDetailPage","checkForFees","processRefund","isConfirmationBtnDisabled","obj","id","version","apportion_amount","calculated_amount","updated_volume","volume","refund_amount","requestBody","contactDetailsObj","response","viewCompStatus","refundReference","refund_reference","refundAmount","gotoAddressPage","note","notification","notification_type","addRefundForRemission","remission","remissionFeeAmt","net_amount","goToPaymentViewComponent","issueRefund","paymentgrp","chkIsIssueRefundBtnEnable","getRemissionByFeeCode","feeCode","remissions_1","remissions_1_1","issue_refund","refund_enable","chkIsAddRefundBtnEnable","add_refund","add_remission","remission_enable","selectPymentOption","paymentType","continuePayment","isFullyRefund","gotoPaymentSelectPage","getContactDetails","notificationPreview","getTemplateInstructionType","goToPaymentFailuePage","selectedPaymentsStatus","goBackToPaymentView","templateInstructionType","showNotificationPreview","hideNotificationPreview","isServiceRequest","RefundsService","getRefundReasons","getRefundRejectReasons","getRefundActions","patchRefundActions","reviewerAction","getRefundList","refundstatus","selfexclusive","getRefundStatusHistory","getRefundStatusList","getUserDetails","postIssueRefund","putResendOrEdit","refundRef","notificationType","patchResubmitRefund","ProcessRefundComponent","formBuilder","router","activeRoute","getErrorMessage","sendmeback","refundActionList","refundRejectReasonList","isSendMeBackClicked","isRejectClicked","isOtherClicked","isSuccesspageEnable","refundActionsHasError","refundRejectReasonHasError","isReasonFieldEmpty","isReasonFieldInvalid","reasonFieldMinHasError","reasonFieldMaxHasError","isReasonEmpty","isReasonInvalid","successMsg","cpoDetails","isConfirmButtondisabled","processRefundForm","group","refundActionField","FormControl","Validators","compose","required","refundRejectReasonField","sendMeBackField","minLength","maxLength","pattern","enterReasonField","refundlistsource","ccd_case_number","isFromRefundListPage","isCPODown","paymentObj","checkRefundActions","getNotificationPreviewObj","notificationPreviewObj","processRefundSubmit","processRefundRequest","resetForm","controls","processFormError","errors","dirty","valid","reason","template_preview","from","from_email_address","from_mail_address","address_line","city","country","county","postal_code","html","template_id","subject","template_type","invalid","minlength","actualLength","maxlength","bodyTxt","loadRefundListPage","navigationpage","isRefundStatusView","loadRefundsHomePage","redirecttoRefundListPage","loadCaseTransactionPage","vals","field","goToCaseReview","navigate","relativeTo","FormBuilder","Router","ActivatedRoute","RefundListComponent","refundService","submittedRefundList","rejectedRefundList","approvalStatus","rejectStatus","isAuthorized","userLst","some","isApproveTableVisible","tableApprovalHeader","tableRejectedHeader","isRejectTableVisible","CardDetailsService","getCardDetails","CardDetailsComponent","cardDetailsService","pageTitle","cardDetails","PageNotFoundComponent","StatusHistoryService","getPaymentStatusesByReference","StatusHistoryComponent","statusHistoryService","statuses","ContactDetailsComponent","assignContactDetails","EventEmitter","assignContactDetailsInFefundsList","redirectToIssueRefund","isEmailSAddressClicked","isShowPickAddress","isPostcodeClicked","isManualAddressClicked","addressPostcodeList","isAddressBoxEmpty","isEmailEmpty","emailHasError","isPostcodeEmpty","postcodeHasError","isaddressLine1Empty","addressLine1HasError","addressLine2HasError","isTownOrCityEmpty","townOrCityHasError","isCountyEmpty","countyHasError","isMPostcodeEmpty","mpostcodeHasError","isCountryEmpty","emailAddressForm","email","postCodeForm","manualAddressForm","addressl1","addressl2","townorcity","mpostcode","addressObj","setEditDetails","isEditOperationInRefundList","setValue","patchValue","selectContactOption","isLinkedClied","finalFormSubmit","emailField","emit","postcodeValidation","fieldCtrls","str","postcodeField","refundsNotification","totalresults","postcodeAddress","addressLine","addressArray","ADDRESS","addressObject","POST_TOWN","LOCAL_CUSTODIAN_CODE_DESCRIPTION","POSTCODE","redirection","val","isEditOperation","Output","PbaDetailsComponent","noop","ConsoleLoggerService","console","log","apply","CaseTransactionsService","getPaymentGroups","BulkScaningPaymentService","getBSPaymentsByCCD","getBSPaymentsByDCN","dcn","postBSAllocatePayment","paymentRef","postBSPaymentStrategic","postBSWoPGStrategic","patchBSChangeStatus","calculateOutStandingAmount","feesTotal","paymentsTotal","remissionsTotal","toUpperCase","amount","hwf_amount","removeUnwantedString","input","replaceText","CaseTransactionsComponent","bulkScaningPaymentService","caseTransactionsService","paymentGroups","nonPayments","allPayments","totalPayments","totalRemissions","isExceptionRecord","isUnprocessedRecordSelected","isAnyFeeGroupAvilable","isHistoricGroupAvailable","isRemoveBtnDisabled","clAmountDue","overPaymentAmount","isFeeRecordsExist","isGrpOutstandingAmtPositive","isAddRemissionEnable","orderRemissionDetails","ispaymentGroupApisuccess","isPBA","isAddRemissionBtnEnabled","isRefundRemissionBtnEnable","isEligible4PBAPayment","currentDate","Date","check4AllowedRoles2AccessRefund","role","indexOf","check4AllowedRoles2AccessPBApayment","allowFurtherAccessAfter4Days","tmp4DayAgo","setDate","getDate","date_created","paymentView","payment_group_reference","goToPayementView","excReference","takePayment","serviceRequest","serviceRequestValue","isBulkScanEnable","toLocaleLowerCase","isStrategicFixEnable","calculateAmounts","calculateOrderFeesAmounts","totalRefundAmount","calculateRefundAmount","setDefaults","goToOrderViewDetailSection","checkForExceptionRecord","totalNonOffPayments","totalFees","getAllocationStatus","recordData","exception_record_reference","ccd_reference","case_reference","index","resetOrderVariables","isFeeOverPaymentExist_1","service_request_status","orderStatus","orderAddBtnEnable","orderRefId","orderTotalFees","responsibleParty","action","orderReferenceObj","x","redirectToOrderFeeSearchPage","orderef","nonOffLinePayment","a","amount_due","b","allocationLen","remisison","totalRefundAmount_1","isFeeAmountZero_1","grpOutstandingAmount","isNewPaymentGroup_1","getGroupOutstandingAmount","redirectToFeeSearchPage","navigateByUrl","chkForAddRemission","redirectToremissionPage","redirectToReportsPage","loadFeeSummaryPage","selectedUnprocessedFeeEvent","unprocessedRecordId","getUnprocessedFeeCount","unProcessedRecordCount","unprocessedRecordCount","calculateAmountDue","confirmRemoveFee","cancelRemoval","removeFee","success","isCheckAmountdueExist","amountDue","chkIssueRefundBtnEnable","chkForPBAPayment","_b","_c","chkIsRefundRemissionBtnEnable","loadPBAAccountPage","pbaPayOrderRef","PaymentToPayhubRequest","currency","description","provider","toFixed","case_type","PayhubAntennaRequest","BS_ENABLE_FLAG","FeeSummaryComponent","service","platForm","isBackButtonEnable","isFeeAmountZero","totalAfterRemission","isPaymentExist","isRemissionsExist","bsPaymentDcnNumber","features","result","feature","uid","enable","getUnassignedPaymentlist","getPaymentGroup","unassignedPayments","responsible_service_id","upPaymentErrorMessage","currentFee","outStandingAmount","partUrl","cancelRemission","page","antennaReqBody","href","goToAllocatePage","Location","ErrorBannerComponent","UnidentifiedPaymentsRequest","unidentified_reason","payment_allocation_status","name","AllocatePaymentRequest","unAllocatedPayment","exceptionRecord","allocatedRequest","banked_date","date_banked","exception_record","document_control_number","dcn_reference","external_provider","giro_slip_no","bgc_reference","payer_name","payment_channel","payment_status","payment_method","payment_allocation_dto","MarkUnidentifiedPaymentComponent","isInvesticationDetailEmpty","investicationDetailHasError","investicationDetailMinHasError","investicationDetailMaxHasError","siteID","ccdReference","exceptionReference","getUnassignedPayment","markPaymentUnidentifiedForm","investicationDetail","unassignedRecord","beCcdNumber","beExceptionNumber","trimUnderscore","saveAndContinue","investicationField","formerror","investigationComment","confirmPayments","res1","res2","response2","reqBody","res3","gotoCasetransationPage","user_id","postStrategicBody","cancelMarkUnidentifiedPayments","UnsolicitedPaymentsRequest","responsible_office","responsible_person","email_id","receiving_office","receiving_email_address","sending_email_address","MarkUnsolicitedPaymentComponent","reasonHasError","reasonMinHasError","reasonMaxHasError","responsibleOfficeHasError","isResponsibleOfficeEmpty","isContinueButtondisabled","siteids","siteIDList","scrollTo","markPaymentUnsolicitedForm","responsibleOffice","responsiblePerson","emailId","selectedSiteId","reasonField","officeIdField","cancelMarkUnsolicitedPayments","checkingFormValue","formFields","valueExists","hasOwnProperty","selectchange","target","selectedSiteName","selectedIndex","text","UnprocessedPaymentsComponent","recordId","isRecordExist","isAllocateToExistingFeebtnEnabled","isMarkAsUnidentifiedbtnEnabled","isAllocatedToNewFeebtnEnabled","isExceptionCase","serviceId","unassignedRecordListLength","isStFixEnable","FEE_RECORDS_EXISTS","setValuesForUnassignedRecord","unassignedRecordList","unprocessedPaymentSelectEvent","formatUnassignedRecordId","ID","loadUnsolicitedPage","selectedRecordReference","validateButtons","resetButtons","PAYMENTREF","setTimeout","IS_OS_AMT_AVAILABLE","unprocessedPaymentUnSelectEvent","showDetailRow","unassignedRecordSelectedList","IS_BUTTON_ENABLE","PAYMENTSLENGTH","LEVEL","ProcessedPaymentsComponent","redirectToPaymentViewPage","NONPAYMENTS","IAllocationPaymentsRequest","explanation","userName","user_name","AllocatePaymentsComponent","isMoreDetailsBoxHide","otherPaymentExplanation","paymentReasonHasError","paymentExplanationHasError","isPaymentDetailsEmpty","isPaymentDetailsInvalid","paymentDetailsMinHasError","paymentDetailsMaxHasError","isUserNameEmpty","isUserNameInvalid","paymentReason","paymentExplanation","cookieUserName","userNameField","reasonList","overPayment","hwfReward","wrongFee","notIssueCase","otherDeduction","shortFall","helpWithFee","other","explanationList","referRefund","noRefund","noCase","holdCase","heldCase","refund","duplicate","humanerror","caseWithdrawn","overUnderPaymentForm","moreDetails","fstCon","scndCn","selectedPaymentGroup","gotoSummaryPage","cancelAllocatePayment","confirmAllocatePayement","enCookieUserName","decodeURIComponent","fullName","paymentDetailsField","paymentFormError","isEmptyCondtion","isOtherOptionSelected","isRemainingAmountGtZero","isRemainingAmountLtZero","finalServiceCall","reset","GroupOutstandingAmount","remainingToBeAssigned","paymentSectionLabel","feedbackUrlLabel","remainingAmount","afterFeeAllocateOutstanding","amountForAllocation","selectRadioButton","key","OrderListSelectEvent","AddRemissionRequest","hwf_reference","AddRetroRemissionRequest","PostIssueRefundRetroRemission","remissionReference","contactDeatils","AddRemissionComponent","Promise","resolve","refundListReason","refundListAmount","refundFees","hasErrors","option","selectedValue","retroRemission","isRemissionCodeEmpty","remissionCodeHasError","isAmountEmpty","amountHasError","isRemissionLessThanFeeError","refundHasError","isPaymentSuccess","isRemissionApplied","commonRefundReasons","class","Array","default","pattern1","pattern2","remessionPayment","remissionForm","remissionCode","refundReason","refundDDReason","feeAmount","feesList","array","onlySelf","refundPaymentReference","refundFeesList","refundReasons","recently_used","sort","localeCompare","changeRefundReason","creds","selected","noneSelected","item","querySelectorAll","el","classList","remove","check_en","v1","AppAmt","Volume","ele","getElementById","formArray","checked","at","removeAttribute","setAttribute","resetRemissionForm","remissionctrls","isRemissionLessThanFee","setErrors","confirmRemission","newNetAmount","remissionAmount","trim","LDUrl","routeReuseStrategy","shouldReuseRoute","onSameUrlNavigation","addRemissionCode","isFromCheckAnsPage","gotoAddRetroRemissionCodePage","isFromRefundStatusPage","iscancelClicked","selectedRefundReason","gotoCheckRetroRemissionPage","gotoAmountRetroRemission","gotoProcessRetroRemissionPage","gotoProcessRetroRemission","confirmRetroRemission","remissionamt","remission_reference","gotoIssueRefundConfirmation","reduce","c","displayRefundReason","gotoIssueRefundPage","gotoIssuePage","checkboxs","getElementsByTagName","j","fullRefund","quantity","amountToRefund","apportionAmount","elementId","getErrorClass","quantityUpdated","refundAmtForFeeVolumes","innerText","allowedRefundAmount","calAmtToRefund","amtToRefund","gotoContactDetailsPage","add","changeIssueRefundReason","confirmIssueRefund","map","gotoRefundReasonPage","localStorage","setItem","isRefundReasonsSelected","showReasonText","selectedRefundReasonCode","reasonLength","gotoPartialFeeRefundScreen","gotoServiceRequestPage","sendOrderDetail","sendOrderRef","gotoRemissionSuccess","gotoCasetransationPageCancelBtnClicked","changeRefundAmount","getFormattedCurrency","concat","CcdHyphensPipe","transform","match","Pipe","CapitalizePipe","slice","keyValuePipe","keys","SanitizeHtmlPipe","sanitizer","bypassSecurityTrustHtml","DomSanitizer","XlFileService","exportAsExcelFile","json","excelFileName","worksheet","workbook","XLSX","utils","json_to_sheet","header","setDataLossReportHeaders","autoFitColumns","setUnprocessedReportHeaders","setProcessedUnallocatedReportHeaders","setPaymentFailureReportHeaders","setShortFallReportHeaders","Sheets","SheetNames","excelBuffer","write","bookType","saveAsExcelFile","objectMaxLength","ColWidth","values","width","A1","v","B1","C1","D1","E1","F1","G1","H1","I1","J1","K1","L1","M1","N1","O1","buffer","fileName","Blob","FileSaver","saveAs","ReportsComponent","xlFileService","fmt","loc","isDownLoadButtondisabled","isStartDateLesthanEndDate","isDateBetwnMonth","isDateRangeBetnWeek","fromValidation","getToday","toISOString","getSelectedFromDate","validateDates","reportsForm","selectedStartDate","tranformDate","selectedEndDate","isDateRangeMoreThanWeek","isDateRangeMoreThanMonth","selectedreport","downloadReport","dataLossRptDefault","loss_resp","payment_asset_dcn","env_ref","env_item","resp_service_id","resp_service_name","bgc_batch","unProcessedRptDefault","exception_ref","ccd_ref","processedUnallocated","allocation_reason","ccd_exception_ref","ccd_case_ref","updated_by","shortFallsRptDefault","surplus_shortfall","balance","payment_amount","ccd_case_reference","ccd_exception_reference","processed_date","selectedReportName","applyDateFormat","substr","convertToFloatValue","Op","getFileName","toLowerCase","errorContent","stDt","formatDate","enDt","now","timestamp","getTwodigit","getHours","getMinutes","getSeconds","getCamelCaseString","strDate","parts","multiDateFormater","dateStr","date","amt","Number","parseFloat","TableComponent","cdRef","displayedColumns","STATUS","isApprovalFlow","DATASOURCE","dataSource","MatTableDataSource","actualcount","r","_a","user_full_name","serviceLst","service_type","ngAfterViewInit","paginator","applyFilter","filterValue","goToRefundProcessComponent","refundData","goToRefundViewComponent","isCallFromRefundList","ViewChild","MatPaginator","MatSort","IPutNotificationRequest","contactDetails","recipient_email_address","recipient_postal_address","IResubmitRefundRequest","refund_fees","RefundStatusComponent","refundButtonState","isResendOperationSuccess","isEditDetailsClicked","isEditAddressDeatilsClicked","isRefundBtnDisabled","isLastUpdatedByCurrentUser","isProcessRefund","notificationSentViewIndex","notificationSentView","refundlist","refundStatusForm","getRefundsNotification","getRefundsStatusHistoryList","refund_status","statusHistoryList","refundStatusHistories","status_history_dto_list","last_updated_by_current_user","notificationList","goToRefundView","gotoReviewDetailsPage","gotoReviewAndReSubmitPage","oldRefundReason","changedAmount","refundreason","notes","gotoAmountPage","goToReviewAndSubmitView","getRefundListReason","reason_code","refundCode","getRefundAmount","getRefundFees","fee_id","gotoReviewRefundConfirmationPage","resubmitRequest","gotoEditAddressDetails","addressDetails","getContactDetailsForRefundList","gotoEditDetailsPage","view","submitEditDetail","resendRequest","putResend","gotoRefundViewPageCancelBtnClicked","gotoRefundReviewAndSubmitViewPageCancelBtnClicked","showNotificationSentView","hideNotificationSentView","ServiceRequestComponent","goToServiceRquestComponent","paymentGroupList","goToPaymentViewComp","IserviceRequestCardPayment","language","IserviceRequestPbaPayment","account_number","customer_reference","orgName","organisation_name","PbaPaymentComponent","isPBAAccountHold","isCardPaymentSuccess","isInSufficiantFund","isPBAAccountNotExist","isPBAServerError","isGetPBAAccountSucceed","selectedPbaAccount","pbaAccountRef","isPbaAccountSelected","isCardPaymentSelected","isPBADropdownSelected","isPBAAccountPaymentSuccess","organisationEntityResponse","pbaAccountList","paymentAccount","selectpbaaccount","currentTarget","requestBody_1","pbaAccountrPaymentResult","cardPayment","paymentUrl","next_url","selectPaymentMethod","NotificationPreviewRequest","service_name","personalisation","NotificationPreviewComponent","notificationPreviewEvent","today","previewJourney","notificationSent","notficationPreviewRequestBody","PaymentLibModule","NgModule","imports","CommonModule","HttpClientModule","FormsModule","ReactiveFormsModule","MatTableModule","MatPaginatorModule","MatSortModule","MatFormFieldModule","MatInputModule","declarations","exports","providers","provide","useClass"],"sources":["../../../projects/payment-lib/src/lib/payment-lib.service.ts","../../../projects/payment-lib/src/lib/services/orderslist.service.ts","../../../projects/payment-lib/src/lib/payment-lib.component.ts","../../../projects/payment-lib/src/lib/services/shared/error-handler.service.ts","../../../projects/payment-lib/src/lib/services/shared/logger/logger.service.ts","../../../projects/payment-lib/src/lib/services/payment-list/payment-list.service.ts","../../../projects/payment-lib/src/lib/components/payment-list/payment-list.component.ts","../../../node_modules/tslib/tslib.es6.js","../../../projects/payment-lib/src/lib/services/shared/httpclient/webcomponent.http.client.ts","../../../projects/payment-lib/src/lib/services/payment-view/payment-view.service.ts","../../../projects/payment-lib/src/lib/services/notification/notification.service.ts","../../../projects/payment-lib/src/lib/interfaces/PostRefundRetroRemission.ts","../../../projects/payment-lib/src/lib/components/payment-view/payment-view.component.ts","../../../projects/payment-lib/src/lib/services/refunds/refunds.service.ts","../../../projects/payment-lib/src/lib/components/process-refund/process-refund.component.ts","../../../projects/payment-lib/src/lib/components/refund-list/refund-list.component.ts","../../../projects/payment-lib/src/lib/services/card-details/card-details.service.ts","../../../projects/payment-lib/src/lib/components/card-details/card-details.component.ts","../../../projects/payment-lib/src/lib/components/page-not-found.component.ts","../../../projects/payment-lib/src/lib/services/status-history/status-history.service.ts","../../../projects/payment-lib/src/lib/components/status-history/status-history.component.ts","../../../projects/payment-lib/src/lib/components/contact-details/contact-details.component.ts","../../../projects/payment-lib/src/lib/components/pba-details/pba-details.component.ts","../../../projects/payment-lib/src/lib/services/shared/logger/console-logger.service.ts","../../../projects/payment-lib/src/lib/services/case-transactions/case-transactions.service.ts","../../../projects/payment-lib/src/lib/services/bulk-scaning-payment/bulk-scaning-payment.service.ts","../../../projects/payment-lib/src/lib/components/case-transactions/case-transactions.component.ts","../../../projects/payment-lib/src/lib/interfaces/PaymentToPayhubRequest.ts","../../../projects/payment-lib/src/lib/interfaces/PayhubAntennaRequest.ts","../../../projects/payment-lib/src/lib/components/fee-summary/fee-summary.component.ts","../../../projects/payment-lib/src/lib/components/error-banner/error-banner.component.ts","../../../projects/payment-lib/src/lib/interfaces/UnidentifiedPaymentsRequest.ts","../../../projects/payment-lib/src/lib/interfaces/AllocatePaymentRequest.ts","../../../projects/payment-lib/src/lib/components/mark-unidentified-payment/mark-unidentified-payment.component.ts","../../../projects/payment-lib/src/lib/interfaces/UnsolicitedPaymentsRequest.ts","../../../projects/payment-lib/src/lib/components/mark-unsolicited-payment/mark-unsolicited-payment.component.ts","../../../projects/payment-lib/src/lib/components/unprocessed-payments/unprocessed-payments.component.ts","../../../projects/payment-lib/src/lib/components/processed-payments/processed-payments.component.ts","../../../projects/payment-lib/src/lib/interfaces/IAllocationPaymentsRequest.ts","../../../projects/payment-lib/src/lib/components/allocate-payments/allocate-payments.component.ts","../../../projects/payment-lib/src/lib/interfaces/AddRemissionRequest.ts","../../../projects/payment-lib/src/lib/interfaces/AddRetroRemissionRequest.ts","../../../projects/payment-lib/src/lib/interfaces/PostIssueRefundRetroRemission.ts","../../../projects/payment-lib/src/lib/components/add-remission/add-remission.component.ts","../../../projects/payment-lib/src/lib/pipes/ccd-hyphens.pipe.ts","../../../projects/payment-lib/src/lib/pipes/capitalize.pipe.ts","../../../projects/payment-lib/src/lib/pipes/key-value.pipe.ts","../../../projects/payment-lib/src/lib/pipes/sanitize-html.pipe.ts","../../../projects/payment-lib/src/lib/services/xl-file/xl-file.service.ts","../../../projects/payment-lib/src/lib/components/reports/reports.component.ts","../../../projects/payment-lib/src/lib/components/table/table.component.ts","../../../projects/payment-lib/src/lib/interfaces/IPutNotificationRequest.ts","../../../projects/payment-lib/src/lib/interfaces/IResubmitRefundRequest.ts","../../../projects/payment-lib/src/lib/components/refund-status/refund-status.component.ts","../../../projects/payment-lib/src/lib/components/service-request/service-request.component.ts","../../../projects/payment-lib/src/lib/interfaces/IserviceRequestCardPayment.ts","../../../projects/payment-lib/src/lib/interfaces/IserviceRequestPbaPayment.ts","../../../projects/payment-lib/src/lib/components/pba-payment/pba-payment.component.ts","../../../projects/payment-lib/src/lib/interfaces/NotificationPreviewRequest.ts","../../../projects/payment-lib/src/lib/components/notification-preview/notification-preview.component.ts","../../../projects/payment-lib/src/lib/payment-lib.module.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root'\n})\n\nexport class PaymentLibService {\n API_ROOT: string;\n BULKSCAN_API_ROOT: string;\n REFUNDS_API_ROOT: string;\n NOTIFICATION_API_ROOT: string;\n CARDPAYMENTRETURNURL: string;\n\n constructor() { }\n\n setApiRootUrl(apiRoot: string): void {\n this.API_ROOT = apiRoot;\n }\n\n getApiRootUrl(): string {\n return this.API_ROOT;\n }\n\n setBulkScanApiRootUrl(bulkscanapiRoot: string): void {\n this.BULKSCAN_API_ROOT = bulkscanapiRoot;\n }\n\n getBulkScanApiRootUrl(): string {\n return this.BULKSCAN_API_ROOT;\n }\n\n setRefundndsApiRootUrl(refundsapiRoot: string): void {\n this.REFUNDS_API_ROOT = refundsapiRoot;\n }\n\n getRefundsApiRootUrl(): string {\n return this.REFUNDS_API_ROOT;\n }\n setNoticationApiRootUrl(notificationapiRoot: string): void {\n this.NOTIFICATION_API_ROOT = notificationapiRoot;\n }\n\n getNoticationApiRootUrl(): string {\n return this.NOTIFICATION_API_ROOT;\n }\n setCardPaymentReturnUrl(cardPaymentReturnUrl: string):void {\n this.CARDPAYMENTRETURNURL = cardPaymentReturnUrl;\n }\n getCardPaymentReturnUrl(): string {\n return this.CARDPAYMENTRETURNURL;\n }\n}\n","import { Injectable } from '@angular/core';\nimport { Observable, BehaviorSubject } from 'rxjs';\nimport {IOrderReferenceFee} from '../interfaces/IOrderReferenceFee';\nimport { IRefundList } from '../interfaces/IRefundList';\nimport { IPaymentView } from '../interfaces/IPaymentView'; \n\n@Injectable({\n providedIn: 'root'\n})\nexport class OrderslistService {\n private ordersList: BehaviorSubject<IOrderReferenceFee[]> = new BehaviorSubject<IOrderReferenceFee[]>(null);\n private refundView: BehaviorSubject<IRefundList> = new BehaviorSubject<IRefundList>(null);\n private caseType = new BehaviorSubject(\"\");\n getcaseType = this.caseType.asObservable();\n private feeExists = new BehaviorSubject<boolean>(null);\n getFeeExist = this.feeExists.asObservable();\n private ccdCaseNumber = new BehaviorSubject(\"\");\n getCCDCaseNumberforRefund = this.ccdCaseNumber.asObservable();\n private isFromServiceRequestPage = new BehaviorSubject<boolean>(null);\n getisFromServiceRequestPage = this.isFromServiceRequestPage.asObservable();\n private OrderRefId = new BehaviorSubject(\"\");\n getOrderRefId = this.OrderRefId.asObservable();\n private navigationPage = new BehaviorSubject(\"\");\n getnavigationPage = this.navigationPage.asObservable();\n\n private orderRef = new BehaviorSubject(\"\");\n getorderRef = this.orderRef.asObservable();\n private orderCCDEvent = new BehaviorSubject(\"\");\n getorderCCDEvent = this.caseType.asObservable();\n private orderCreated = new BehaviorSubject<Date>(null);\n getorderCreated = this.orderCreated.asObservable();\n private orderParty = new BehaviorSubject(\"\");\n getorderParty = this.orderParty.asObservable();\n private orderRemissionTotal = new BehaviorSubject<number>(null);\n getorderRemissionTotal = this.orderRemissionTotal.asObservable();\n private orderFeesTotal = new BehaviorSubject<number>(null);\n getorderFeesTotal = this.orderFeesTotal.asObservable();\n private orderTotalPayments = new BehaviorSubject<number>(null);\n getorderTotalPayments = this.orderTotalPayments.asObservable();\n private rolesList: BehaviorSubject<any[]> = new BehaviorSubject<any[]>(null);\n\n private orderDetail: BehaviorSubject<any[]> = new BehaviorSubject<any[]>(null);\n\n private paymentPageView: BehaviorSubject<IPaymentView> = new BehaviorSubject<IPaymentView>(null);\n\n constructor() { }\n\n setOrdersList(orderLevelFees: IOrderReferenceFee[]): void {\n this.ordersList.next(Object.assign([], orderLevelFees));\n }\n getOrdersList() {\n return this.ordersList;\n }\n\n setRefundView(refundList: IRefundList): void {\n this.refundView.next(Object.assign([], refundList));\n }\n getRefundView() {\n return this.refundView;\n }\n\n setCaseType(caseType: string){\n this.caseType.next(caseType);\n }\n getCaseType(){\n return this.caseType;\n }\n\n setCCDCaseNumber(ccdCaseNumber: string){\n this.ccdCaseNumber.next(ccdCaseNumber);\n }\n getCCDCaseNumber(){\n return this.ccdCaseNumber;\n }\n\n setFeeExists(feeExists: boolean){\n this.feeExists.next(feeExists);\n }\n getFeeExists(){\n return this.feeExists;\n } \n\n setisFromServiceRequestPage(isFromServiceRequestPage: boolean){\n this.isFromServiceRequestPage.next(isFromServiceRequestPage);\n }\n getisFromServiceRequestPages(){\n return this.isFromServiceRequestPage;\n }\n\n setOrderRefId(OrderRefId: string){\n this.OrderRefId.next(OrderRefId);\n }\n getSelectedOrderRefId(){\n return this.OrderRefId;\n }\n\n setnavigationPage(navigationPage: string){\n this.navigationPage.next(navigationPage);\n }\n getnavigationPageValue(){\n return this.navigationPage;\n }\n\n setpaymentPageView(paymentpageList: IPaymentView): void {\n this.paymentPageView.next(Object.assign([], paymentpageList));\n }\n getpaymentPageView() {\n return this.paymentPageView;\n }\n\n setUserRolesList(rolesList:any[]): void {\n this.rolesList.next(Object.assign([], rolesList));\n }\n getUserRolesList() {\n return this.rolesList;\n }\n\n setorderDetail(orderDetail:any[]): void {\n this.orderDetail.next(Object.assign([], orderDetail));\n }\n getorderDetail() {\n return this.orderDetail;\n }\n\n setOrderRef(orderRef: string){\n this.orderRef.next(orderRef);\n }\n getorderRefs(){\n return this.orderRef;\n }\n\n setorderCCDEvent(orderCCDEvent: string){\n this.orderCCDEvent.next(orderCCDEvent);\n }\n getorderCCDEvents(){\n return this.orderCCDEvent;\n }\n\n setorderCreated(orderCreated: Date){\n this.orderCreated.next(orderCreated);\n }\n getorderCreateds(){\n return this.orderCreated;\n }\n\n setorderParty(orderParty: string){\n this.orderParty.next(orderParty);\n }\n getorderPartys(){\n return this.orderParty;\n }\n\n setorderRemissionTotal(orderRemissionTotal: number){\n this.orderRemissionTotal.next(orderRemissionTotal);\n }\n getorderRemissionTotals(){\n return this.orderRemissionTotal;\n }\n\n setorderFeesTotal(orderFeesTotal: number){\n this.orderFeesTotal.next(orderFeesTotal);\n }\n getorderFeesTotals(){\n return this.orderFeesTotal;\n }\n\n setorderTotalPayments(orderTotalPayments: number){\n this.orderTotalPayments.next(orderTotalPayments);\n }\n getoorderTotalPaymentss(){\n return this.orderTotalPayments;\n }\n}\n","import { ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\nimport { PaymentLibService } from './payment-lib.service';\nimport { IBSPayments } from './interfaces/IBSPayments';\nimport { OrderslistService } from './services/orderslist.service';\nimport { IPayment } from './interfaces/IPayment';\n\n@Component({\n selector: 'ccpay-payment-lib',\n template: `\n <ccpay-refund-list [USERID]=\"USERID\" [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\" [LOGGEDINUSEREMAIL]=\"LOGGEDINUSEREMAIL\" *ngIf=\"viewName === 'refund-list'\"></ccpay-refund-list>\n <ccpay-payment-list *ngIf=\"viewName === 'payment-list'\"></ccpay-payment-list>\n <ccpay-refund-status\n [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\"\n [API_ROOT]=\"API_ROOT\"\n *ngIf=\"viewName === 'refundstatuslist'\"> </ccpay-refund-status >\n <ccpay-payment-view [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\" *ngIf=\"viewName === 'payment-view'\"\n [isTurnOff]=\"ISTURNOFF\" [isTakePayment]=\"TAKEPAYMENT\" [caseType]=\"CASETYPE\"\n [ISPAYMENTSTATUSENABLED] = \"ISPAYMENTSTATUSENABLED\"\n ></ccpay-payment-view>\n\n <ccpay-process-refund *ngIf=\"viewName === 'process-refund'\"\n [refundReference]=\"refundReference\"\n [refundlistsource]=\"refundlistsource\"\n ></ccpay-process-refund>\n <ccpay-pba-payment *ngIf=\"viewName === 'pba-payment'\"\n [pbaPayOrderRef]=\"pbaPayOrderRef\"\n ></ccpay-pba-payment>\n <ccpay-case-transactions [isTakePayment]=\"isTakePayment\" [isFromServiceRequestPage]=\"isFromServiceRequestPage\" [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\" *ngIf=\"viewName === 'case-transactions'\"></ccpay-case-transactions>\n <app-mark-unidentified-payment *ngIf=\"viewName === 'unidentifiedPage'\"\n [caseType]=\"CASETYPE\"></app-mark-unidentified-payment>\n <app-mark-unsolicited-payment *ngIf=\"viewName === 'unsolicitedPage'\"\n [caseType]=\"CASETYPE\"></app-mark-unsolicited-payment>\n <app-allocate-payments *ngIf=\"viewName === 'allocate-payments'\"\n [isTurnOff]=\"ISTURNOFF\"\n [caseType]=\"CASETYPE\"\n ></app-allocate-payments>\n <ccpay-fee-summary *ngIf=\"viewName === 'fee-summary'\"\n [ccdCaseNumber]=\"CCD_CASE_NUMBER\"\n [paymentGroupRef]=\"paymentGroupReference\"\n [isTurnOff]=\"ISTURNOFF\"\n [caseType]=\"CASETYPE\"\n ></ccpay-fee-summary>\n <ccpay-reports *ngIf=\"viewName === 'reports'\"\n [ISPAYMENTSTATUSENABLED] = \"ISPAYMENTSTATUSENABLED\"\n ></ccpay-reports>\n `\n})\n\nexport class PaymentLibComponent implements OnInit {\n @Input('API_ROOT') API_ROOT: string;\n @Input('BULKSCAN_API_ROOT') BULKSCAN_API_ROOT: string;\n @Input('REFUNDS_API_ROOT') REFUNDS_API_ROOT: string;\n @Input('NOTIFICATION_API_ROOT') NOTIFICATION_API_ROOT: string;\n @Input('CARDPAYMENTRETURNURL') CARDPAYMENTRETURNURL: string;\n @Input('CCD_CASE_NUMBER') CCD_CASE_NUMBER: string;\n @Input('EXC_REFERENCE') EXC_REFERENCE: string;\n @Input('PAYMENT_METHOD') PAYMENT_METHOD: string;\n @Input('VIEW') VIEW: string;\n @Input('VIEWSERVICE') VIEWSERVICE: string;\n @Input('PAYMENT_GROUP_REF') PAYMENT_GROUP_REF?: string;\n @Input('TAKEPAYMENT') TAKEPAYMENT: boolean;\n @Input('SERVICEREQUEST') SERVICEREQUEST: string;\n @Input('DCN_NUMBER') DCN_NUMBER: string;\n @Input('SELECTED_OPTION') SELECTED_OPTION: string;\n @Input('ISBSENABLE') ISBSENABLE: Boolean;\n @Input('ISSFENABLE') ISSFENABLE: boolean;\n @Input('ISTURNOFF') ISTURNOFF: boolean;\n @Input('CASETYPE') CASETYPE: string;\n @Input('ISPAYMENTSTATUSENABLED') ISPAYMENTSTATUSENABLED: boolean;\n @Input('rootUrl') rootUrl: boolean;\n @Input('REFUNDLIST') REFUNDLIST: string;\n @Input('USERID') USERID: string;\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: any[];\n @Input('LOGGEDINUSEREMAIL') LOGGEDINUSEREMAIL: string;\n @Input('isFromServiceRequestPage') isFromServiceRequestPage: boolean;\n\n paymentMethod: string;\n bspaymentdcn: string;\n unProcessedPaymentServiceId: string = null;\n paymentGroupReference: string;\n paymentReference: string;\n refundReference: string;\n isFromPayBubble: boolean = false;\n refundlistsource: any;\n viewName: string;\n isTurnOff: boolean;\n caseType: string;\n unProcessedPayment: IBSPayments = null;\n isRefundStatusView: boolean;\n isRedirectFromCaseTransactionPage: string;\n isCallFromRefundList: boolean;\n isFromRefundStatusPage: boolean;\n iscancelClicked : boolean;\n isFromPaymentDetailPage: boolean;\n pbaPayOrderRef: IPayment;\n isTakePayment: boolean;\n\n orderDetail: any[];\n orderRef: string;\n orderStatus: string;\n orderParty: string;\n orderCreated: Date;\n orderCCDEvent: string;\n serviceRequestValue: string;\n orderAddBtnEnable: boolean;\n orderFeesTotal: number = 0.00;\n orderRemissionTotal: number = 0.00;\n orderTotalPayments: number = 0.00;\n orderPendingPayments: number = 0.00;\n\n constructor(private paymentLibService: PaymentLibService,\n private cd: ChangeDetectorRef,\n private OrderslistService: OrderslistService) { }\n ngAfterContentChecked(): void {\n this.cd.detectChanges();\n }\n\n\n ngOnInit() {\n\n this.paymentLibService.setApiRootUrl(this.API_ROOT);\n this.paymentLibService.setBulkScanApiRootUrl(this.BULKSCAN_API_ROOT);\n this.paymentLibService.setRefundndsApiRootUrl(this.REFUNDS_API_ROOT);\n this.paymentLibService.setNoticationApiRootUrl(this.NOTIFICATION_API_ROOT);\n this.paymentLibService.setCardPaymentReturnUrl(this.CARDPAYMENTRETURNURL);\n\n if(this.LOGGEDINUSERROLES.length > 0) {\n this.OrderslistService.setUserRolesList(this.LOGGEDINUSERROLES);\n }\n if (this.PAYMENT_GROUP_REF) {\n this.paymentGroupReference = this.PAYMENT_GROUP_REF;\n }\n if (this.DCN_NUMBER) {\n this.bspaymentdcn = this.DCN_NUMBER;\n }\n if (this.REFUNDLIST === \"true\") {\n this.VIEW = 'refund-list';\n this.viewName = this.VIEW;\n }\n if (this.VIEW === 'fee-summary') {\n this.viewName = 'fee-summary';\n } else if (this.VIEW !== 'reports' && this.VIEW !== 'refund-list') {\n this.viewName = 'case-transactions';\n } else {\n this.viewName = this.VIEW;\n }\n\n if (this.isTakePayment) {\n this.TAKEPAYMENT = true;\n }\n if(this.API_ROOT == 'api/payment-history') {\n this.isFromPayBubble = true;\n }\n }\n}\n","import { Injectable } from '@angular/core';\nimport { HttpErrorResponse } from '@angular/common/http';\nimport { Observable, throwError } from 'rxjs';\n\n@Injectable({\n providedIn: 'root'\n})\n\n\nexport class ErrorHandlerService {\n\n constructor() { }\n\n\n handleError(err: HttpErrorResponse): Observable<any> {\n let errorMessage: string;\n if (err.error instanceof Error) {\n // A client-side or network error occurred.\n errorMessage = `An error occurred: ${err.error.message}`;\n } else {\n // The backend returned an unsuccessful response code.\n if (err.status === 404) {\n\n if (typeof err.error === 'string' && err.error !== undefined) {\n\n if(err.error.length > 60) {\n if (JSON.parse(err.error).statusCode !== undefined && JSON.parse(err.error).statusCode === 500)\n {\n errorMessage = 'Internal server error';\n } else {\n if(err.error.length > 60) {\n errorMessage = JSON.parse(err.error).error;\n } else {\n errorMessage = err.error;\n }\n\n }\n } else {\n errorMessage = err.error;\n }\n } else {\n errorMessage = JSON.parse(err.error).error;\n }\n\n }\n else if (err.status === 500) {\n errorMessage = 'Internal server error';\n } else if (err.error.messsage === undefined) {\n if( typeof err.error === 'object') {\n errorMessage = JSON.parse(JSON.stringify(err.error)).error;\n } else {\n if (typeof err.error === 'string' && err.error !== undefined) {\n\n if(err.error.length > 60) {\n if (JSON.parse(err.error).statusCode !== undefined && JSON.parse(err.error).statusCode === 500)\n {\n errorMessage = 'Internal server error';\n } else {\n if(err.error.length > 60) {\n errorMessage = JSON.parse(err.error).error;\n } else {\n errorMessage = err.error;\n }\n\n }\n } else {\n errorMessage = err.error;\n }\n } else {\n errorMessage = JSON.parse(err.error).error;\n }\n\n }\n\n } else {\n if (err.error.message !== undefined) {\n errorMessage = `${err.error.message}`;\n } else {\n errorMessage = `${err.error}`;\n }\n\n }\n }\n return throwError(errorMessage);\n }\n\n\n getServerErrorMessage(isErrorExist, isDataNotExist = false, error='') {\n const bodyContent = isDataNotExist ? error : 'Try again later';\n return {\n title: \"There is a problem with the service\",\n body: bodyContent,\n showError: isErrorExist\n };\n }\n}\n","import { Injectable } from '@angular/core';\n\nconst noop = (): any => undefined;\n\nexport abstract class Logger {\n\n info: any;\n warn: any;\n error: any;\n}\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LoggerService implements Logger {\n\n info: any;\n warn: any;\n error: any;\n\n invokeConsoleMethod(type: string, args?: any): void {}\n}\n","import { Injectable } from '@angular/core';\nimport { HttpClient } from '@angular/common/http';\n\nimport { Observable } from 'rxjs/internal/Observable';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport { IPayments } from '../../interfaces/IPayments';\nimport { catchError } from 'rxjs/operators';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { LoggerService } from '../shared/logger/logger.service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class PaymentListService {\n payments: IPayments;\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n\n getPaymentByCcdCaseNumber(ccdCaseNumber: string, paymentMethod: string): Observable<IPayments> {\n this.logger.info('Payment-list-service getPaymentByCcdCaseNumber for: ', ccdCaseNumber);\n\n return this.http.get<IPayments>(`${this.paymentLibService.API_ROOT}/cases/${ccdCaseNumber}/payments`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import {Component, OnInit} from '@angular/core';\n\nimport {PaymentListService} from '../../services/payment-list/payment-list.service';\nimport {IPayments} from '../../interfaces/IPayments';\nimport {PaymentLibComponent} from '../../payment-lib.component';\nimport {IStatusHistory} from '../../interfaces/IStatusHistory';\n\n@Component({\n selector: 'ccpay-payment-list',\n templateUrl: './payment-list.component.html',\n styleUrls: ['./payment-list.component.css']\n})\nexport class PaymentListComponent implements OnInit {\n payments: IPayments;\n errorMessage: string;\n code: string;\n\n constructor(private paymentListService: PaymentListService,\n private paymentLibComponent: PaymentLibComponent) {\n }\n\n ngOnInit() {\n this.paymentListService.getPaymentByCcdCaseNumber(this.paymentLibComponent.CCD_CASE_NUMBER, this.paymentLibComponent.PAYMENT_METHOD)\n .subscribe(\n payments => this.payments = payments,\n (error: any) => this.errorMessage = <any>error\n );\n }\n\n loadPaymentViewComponent(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.paymentLibComponent.paymentMethod = paymentMethod;\n this.paymentLibComponent.paymentGroupReference = paymentGroupReference;\n this.paymentLibComponent.paymentReference = paymentReference;\n this.paymentLibComponent.viewName = 'payment-view';\n }\n}\n","/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n var desc = Object.getOwnPropertyDescriptor(m, k);\r\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\r\n desc = { enumerable: true, get: function() { return m[k]; } };\r\n }\r\n Object.defineProperty(o, k2, desc);\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n\r\nexport function __classPrivateFieldIn(state, receiver) {\r\n if (receiver === null || (typeof receiver !== \"object\" && typeof receiver !== \"function\")) throw new TypeError(\"Cannot use 'in' operator on non-object\");\r\n return typeof state === \"function\" ? receiver === state : state.has(receiver);\r\n}\r\n","import { Injectable } from '@angular/core';\nimport { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Meta } from '@angular/platform-browser';\nimport { Observable } from 'rxjs';\n\n@Injectable()\nexport class WebComponentHttpClient {\n constructor(\n private http: HttpClient,\n private meta: Meta\n ) { }\n\n post(url: string, body: any | null, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.post(url, body, opts);\n }\n\n put(url: string, body: any | null, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.put(url, body, opts);\n }\n\n get(url: string, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.get(url, opts);\n }\n\n delete(url: string, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.delete(url, opts);\n }\n \n patch(url: string, body: any | null, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.patch(url, body, opts);\n }\n\n addHeaders(options: any): any {\n const csrfToken = this.meta.getTag('name=csrf-token');\n const headers = {};\n \n if (options.headers) {\n options.headers.forEach(element => {\n headers[element] = options.headers.get(element);\n });\n }\n headers['X-Requested-With'] = 'XMLHttpRequest';\n if (csrfToken === null) {\n if( document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')) !== undefined ) {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')).split('=')[1]; \n } else {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith(' XSRF-TOKEN')).split('=')[1];\n }\n \n } else {\n headers['CSRF-Token'] = csrfToken.content;\n }\n options.headers = new HttpHeaders(headers);\n options.responseType = 'text';\n return options;\n }\n}\n","import { Injectable } from '@angular/core';\nimport { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Observable } from 'rxjs/internal/Observable';\nimport { v4 as uuidv4 } from 'uuid';\nimport {IPayment} from '../../interfaces/IPayment';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { catchError } from 'rxjs/operators';\nimport { LoggerService } from '../shared/logger/logger.service';\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport { AddRemissionRequest } from '../../interfaces/AddRemissionRequest';\nimport { PaymentToPayhubRequest } from '../../interfaces/PaymentToPayhubRequest';\nimport { PayhubAntennaRequest } from '../../interfaces/PayhubAntennaRequest';\nimport { UnidentifiedPaymentsRequest } from '../../interfaces/UnidentifiedPaymentsRequest';\nimport { UnsolicitedPaymentsRequest } from '../../interfaces/UnsolicitedPaymentsRequest';\nimport { Meta } from '@angular/platform-browser';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\nimport { IAllocationPaymentsRequest } from '../../interfaces/IAllocationPaymentsRequest';\nimport {IOrderReferenceFee} from '../../interfaces/IOrderReferenceFee';\nimport { BehaviorSubject } from 'rxjs';\nimport { IserviceRequestPbaPayment } from '../../interfaces/IserviceRequestPbaPayment';\nimport { IserviceRequestCardPayment } from '../../interfaces/IserviceRequestCardPayment';\nimport { RefundsRequest } from '../../interfaces/RefundsRequest';\nimport { AddRetroRemissionRequest } from '../../interfaces/AddRetroRemissionRequest';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\nimport { PostIssueRefundRetroRemission } from '../../interfaces/PostIssueRefundRetroRemission';\nimport { error } from '@angular/compiler/src/util';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class PaymentViewService {\n private ordersList = <BehaviorSubject<IOrderReferenceFee[]>>new BehaviorSubject([]);\n\n private meta: Meta;\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n getPaymentDetails(paymentReference: string, paymentMethod?: string): Observable<IPayment> {\n\n\n this.logger.info('Payment-view-service getPaymentDetails for: ', paymentReference);\n\n if(paymentMethod == undefined || paymentMethod == null){\n return this.http.get<IPayment>(`${this.paymentLibService.API_ROOT}/payments/${paymentReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }else{\n return this.http.get<IPayment>(paymentMethod === 'card' || paymentMethod === 'cash' || paymentMethod === 'cheque' || paymentMethod === 'postal order' ?\n `${this.paymentLibService.API_ROOT}/card-payments/${paymentReference}` :\n `${this.paymentLibService.API_ROOT}/credit-account-payments/${paymentReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n\n }\n }\n\n getPaymentGroupDetails(paymentGroupReference: string): Observable<IPaymentGroup> {\n this.logger.info('Payment-view-service getPaymentGroupDetails for: ', paymentGroupReference);\n\n return this.http.get<IPayment>(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getApportionPaymentDetails(paymentReference: string): Observable<IPaymentGroup> {\n this.logger.info('Payment-view-service getPaymentGroupDetails for: ', paymentReference);\n\n return this.http.get<IPayment>(`${this.paymentLibService.API_ROOT}/payment-groups/fee-pay-apportion/${paymentReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getPBAaccountDetails(): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/pba-accounts`;\n return this.http.get(url, { withCredentials: true }).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postWays2PayCardPayment(serviceRef: string, body: IserviceRequestCardPayment): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/service-request/${serviceRef}/card-payments`;\n const rurl = this.paymentLibService.CARDPAYMENTRETURNURL.replace('.prod', '');\n body['return-url'] = `${rurl}/payment`;\n return this.https.post(url, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n \n postPBAaccountPayment(serviceRef: string, body: IserviceRequestPbaPayment): Observable<any> {\n let randomKey = 'idam-key-' + Math.random().toString().split('.').join('-');\n body['idempotency_key'] = randomKey;\n const url = `${this.paymentLibService.API_ROOT}/service-request/${serviceRef}/pba-payments`;\n return this.https.post(url, body);\n }\n\n postBSPayments(body: AllocatePaymentRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/bulk-scan-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSUnidentifiedPayments(body: UnidentifiedPaymentsRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-allocations`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSUnsolicitedPayments(body: UnsolicitedPaymentsRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-allocations`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSAllocationPayments(body: IAllocationPaymentsRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-allocations`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postPaymentGroupWithRemissions(paymentGroupReference: string, feeId: number, body: AddRemissionRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupReference}/fees/${feeId}/remissions`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n deleteFeeFromPaymentGroup(feeId: number): Observable<any> {\n this.logger.info('Payment-view-service deleteFeeFromPaymentGroup for: ', feeId);\n return this.https.delete(`${this.paymentLibService.API_ROOT}/fees/${feeId}`).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postPaymentToPayHub(body: PaymentToPayhubRequest, paymentGroupRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupRef}/card-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postPaymentAntennaToPayHub(body: PayhubAntennaRequest, paymentGroupRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupRef}/telephony-card-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n downloadSelectedReport(reportName: string, startDate: string, endDate:string): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/report/data?date_from=${startDate}&date_to=${endDate}&report_type=${reportName}`;\n return this.https.get(url, { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n downloadFailureReport(startDate: string, endDate:string): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/payment-failures/failure-report?date_from=${startDate}&date_to=${endDate}`;\n return this.https.get(url, { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n getBSfeature(): Observable<any> {\n return this.https.get('api/payment-history/bulk-scan-feature', { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n getSiteID(): Observable<any> {\n return this.https.get('api/payment-history/refdata/legacy-sites', { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n getPartyDetails(caseNumber: string): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/case-payment-orders?case_ids=${caseNumber}`;\n return this.https.get(url, { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n \n setOrdersList(orderLevelFees: IOrderReferenceFee[]): void {\n this.ordersList.next(Object.assign([], orderLevelFees));\n}\n getOrdersList() {\n return this.ordersList;\n }\n\n //issue refund\n postRefundsReason(body: PostRefundRetroRemission): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/refund-for-payment`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n // retro remissions\n postPaymentGroupWithRetroRemissions(paymentGroupReference: string, feeId: number, body: AddRetroRemissionRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupReference}/fees/${feeId}/retro-remission`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postRefundRetroRemission(body:PostIssueRefundRetroRemission) {\n return this.https.post(`${this.paymentLibService.API_ROOT}/refund-retro-remission`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getPaymentFailure(paymentReference: string): Observable<any> {\n return this.https.get(`${this.paymentLibService.API_ROOT}/payment-failures/${paymentReference}`, {\n withCredentials: true\n }).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {catchError} from 'rxjs/operators';\nimport { IRefundsNotifications } from '../../interfaces/IRefundsNotifications';\nimport { NotificationPreviewRequest } from '../../interfaces/NotificationPreviewRequest';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class NotificationService {\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService\n ) { }\n\n getRefundNotification(reference: string): Observable<IRefundsNotifications> {\n return this.http.get<IRefundsNotifications>(`${this.paymentLibService.NOTIFICATION_API_ROOT}/${reference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getAddressByPostcode(postcode: string): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.NOTIFICATION_API_ROOT}/postcode-lookup/${postcode}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getNotificationPreview(body: NotificationPreviewRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.NOTIFICATION_API_ROOT}/doc-preview`, body).pipe(\n catchError(this.errorHandlerService.handleError));\n }\n\n getNotificationInstructionType(paymentChannel: string, paymentMethod: string): any {\n if (paymentChannel === 'bulk scan' && paymentMethod === 'postal order') {\n return 'RefundWhenContacted';\n } else if (paymentChannel === 'bulk scan' && paymentMethod === 'cash') {\n return 'RefundWhenContacted';\n } else if (paymentChannel === 'online' && paymentMethod === 'card') {\n return 'SendRefund';\n } else if (paymentChannel === 'telephony' && paymentMethod === 'card') {\n return 'SendRefund';\n } else if (paymentChannel === 'online' && paymentMethod === 'payment by account') {\n return 'SendRefund';\n } else if (paymentChannel === 'bulk scan' && paymentMethod === 'cheque') {\n return 'SendRefund';\n }else {\n return 'Template'\n }\n }\n\n}\n","import { IFee } from \"./IFee\";\nimport { IRefundContactDetails } from \"./IRefundContactDetails\";\n\nexport class PostRefundRetroRemission {\n ccd_case_number: string;\n payment_reference: string;\n refund_reason: string;\n total_refund_amount: any;\n fees: any[];\n is_over_payment: boolean;\n contact_details: IRefundContactDetails\n \n constructor(contact_details:any,fees: any[], payment_reference : string,refund_reason:string, total_refund_amount : any, is_over_payment: string ) {\n this.contact_details = contact_details;\n this.fees = fees;\n this.payment_reference= payment_reference;\n this.refund_reason = refund_reason;\n\t this.total_refund_amount = total_refund_amount;\n this.is_over_payment = is_over_payment === 'op';\n } \n}","import { Component, OnInit, Input } from '@angular/core';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { IFee } from '../../interfaces/IFee';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\nimport { ChangeDetectorRef } from '@angular/core';\nimport { IPaymentFailure } from '../../interfaces/IPaymentFailure';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\n\n@Component({\n selector: 'ccpay-payment-view',\n templateUrl: './payment-view.component.html',\n styleUrls: ['./payment-view.component.scss']\n})\n\nexport class PaymentViewComponent implements OnInit {\n @Input() isTurnOff: boolean;\n @Input() isTakePayment: boolean;\n @Input() caseType: boolean;\n @Input() orderRef: string;\n @Input() orderStatus: string;\n @Input() orderTotalPayments: number;\n @Input() payment: IPayment;\n @Input() LOGGEDINUSERROLES: string[];\n @Input() ISPAYMENTSTATUSENABLED: string;\n @Input() orderParty: string;\n @Input() orderCreated: Date;\n @Input() orderCCDEvent: string;\n @Input() orderFeesTotal: number;\n @Input() orderRemissionTotal: number;\n @Input() orderDetail: any[];\n fees: any;\n isFullyRefund: boolean;\n @Input(\"isServiceRequest\") isServiceRequest: string;\n errorMsg: string;\n paymentGroup: IPaymentGroup;\n errorMessage: string;\n ccdCaseNumber: string;\n selectedOption: string;\n dcnNumber: string;\n isStatusAllocated: boolean;\n isRemissionsMatch: boolean;\n feeId: IFee;\n viewStatus: string;\n isRefundRemission: boolean = false;\n isStrategicFixEnable: boolean;\n isAddFeeBtnEnabled: boolean = false;\n isIssueRefunfBtnEnable: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund'];\n remissions: IRemission[] = [];\n allPaymentsFailure: IPaymentFailure[] = [];\n selectedPaymentsStatus: IPaymentFailure;\n remissionFeeAmt: number;\n isRefundRemissionBtnEnable: boolean;\n serviceReference: string;\n isFromServiceRequestPage: boolean;\n isFromPaymentDetailPage: boolean;\n paymentFees: IFee[];\n paymentType: string;\n isContinueBtnDisabled: boolean = true;\n viewCompStatus: string;\n contactDetailsObj: IRefundContactDetails\n notification: any;\n isConfirmationBtnDisabled: boolean;\n refundReference: string;\n refundAmount: string;\n templateInstructionType: string;\n notificationPreview: boolean;\n constructor(private paymentViewService: PaymentViewService,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private cd: ChangeDetectorRef,\n private OrderslistService: OrderslistService) {\n }\n\n ngAfterContentChecked(): void {\n this.cd.detectChanges();\n }\n\n ngOnInit() {\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION;\n this.dcnNumber = this.paymentLibComponent.DCN_NUMBER;\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.serviceReference = this.paymentLibComponent.paymentGroupReference;\n this.viewStatus = 'paymentview';\n this.paymentViewService.getApportionPaymentDetails(this.paymentLibComponent.paymentReference).subscribe(\n paymentGroup => {\n let fees = [];\n paymentGroup.fees.forEach(fee => {\n this.isRemissionsMatch = false;\n\n paymentGroup.remissions.forEach(rem => {\n if (rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n fees.push(fee);\n }\n });\n if (!this.isRemissionsMatch) {\n fees.push(fee);\n }\n });\n paymentGroup.fees = fees\n this.paymentFees =fees;\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n\n },\n (error: any) => this.errorMessage = error\n );\n this.paymentViewService.getPaymentFailure(this.paymentLibComponent.paymentReference).subscribe({\n next: (res) => {\n JSON.parse(res).payment_failure_list.reverse().forEach(payments => {\n\n this.allPaymentsFailure.push(payments.payment_failure_initiated);\n if(payments.payment_failure_closed) {\n this.allPaymentsFailure.push(payments.payment_failure_closed);\n }\n });\n this.allPaymentsFailure = this.allPaymentsFailure.reverse();\n },\n error: (e) => {\n this.allPaymentsFailure = [];\n this.errorMsg = \"Server error\"\n }\n })\n }\n\n get isCardPayment(): boolean {\n return this.paymentGroup.payments[0].method === 'card';\n }\n\n get isTelephonyPayment(): boolean {\n return this.paymentGroup.payments[0].channel === 'telephony';\n }\n\n public goToPaymentList(): void {\n this.paymentLibComponent.viewName = 'payment-list';\n }\n getOverPaymentValue() {\n let feesOverPayment = 0;\n this.paymentGroup.fees.forEach(fee => {\n feesOverPayment += fee.over_payment;\n });\n return feesOverPayment > 0 ? feesOverPayment : this.paymentGroup.payments[0].over_payment;\n\n }\n goToServiceRequestPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = false;\n this.paymentLibComponent.SERVICEREQUEST = 'true';\n this.paymentLibComponent.isFromServiceRequestPage = true;\n window.location.reload();\n }\n goToCaseTransationPage(event: any) {\n event.preventDefault();\n if (!this.paymentLibComponent.isFromServiceRequestPage) {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.resetOrderData();\n } else {\n this.OrderslistService.getorderRefs().subscribe((data) => this.orderRef = data);\n this.OrderslistService.getorderCCDEvents().subscribe((data) => this.orderCCDEvent = data);\n this.OrderslistService.getorderCreateds().subscribe((data) => this.orderCreated = data);\n this.OrderslistService.getorderDetail().subscribe((data) => this.orderDetail = data);\n this.OrderslistService.getorderPartys().subscribe((data) => this.orderParty = data);\n this.OrderslistService.getorderRemissionTotals().subscribe((data) => this.orderRemissionTotal = data);\n this.OrderslistService.getorderFeesTotals().subscribe((data) => this.orderFeesTotal = data);\n this.OrderslistService.getoorderTotalPaymentss().subscribe((data) => this.orderTotalPayments = data);\n this.viewStatus = 'order-full-view';\n }\n\n }\n\n addRemission(fee: IFee) {\n if(this.chkIsAddRemissionBtnEnable(fee)) {\n this.feeId = fee;\n this.paymentViewService.getApportionPaymentDetails(this.paymentGroup.payments[0].reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n this.payment = this.paymentGroup.payments[0];\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.viewStatus = 'addremission';\n this.isRefundRemission = true;\n this.cd.detectChanges();\n },\n (error: any) => this.errorMessage = error\n );\n }\n }\n\n checkForFees(paymentGroup: any) {\n if(paymentGroup !== null && paymentGroup !== undefined)\n {\n if (paymentGroup.fees !== null && paymentGroup.fees !== undefined) {\n return true;\n }\n\n }\n return false;\n }\n processRefund() {\n this.isConfirmationBtnDisabled = true;\n this.errorMessage = '';\n const obj = this.paymentGroup.fees[0];\n this.fees = [{ id: obj.id, \n code: obj.code,\n version:obj.version, \n apportion_amount: obj.apportion_amount,\n calculated_amount: obj.calculated_amount,\n updated_volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n volume: obj.volume,\n refund_amount: this.getOverPaymentValue() }];\n const requestBody = new PostRefundRetroRemission(this.contactDetailsObj,this.fees, this.paymentGroup.payments[0].reference, 'RR037', \n this.getOverPaymentValue(), 'op');\n this.paymentViewService.postRefundsReason(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n })\n }\n gotoAddressPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewCompStatus = 'overPaymentAddressCapture';\n }\n addRefundForRemission(payment: IPayment, remission: IRemission[],fees:any) {\n //if(!this.chkIsIssueRefundBtnEnable(payment)) {\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(payment.reference));\n this.payment = this.paymentGroup.payments[0];\n this.remissions = remission;\n this.remissionFeeAmt = fees.filter(data=>data.code === this.remissions['fee_code'])[0].net_amount;\n this.viewStatus = 'addrefundforremission';\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error\n );\n //}\n }\n\n goToPaymentViewComponent() {\n this.viewCompStatus = '';\n this.viewStatus = 'paymentview';\n }\n issueRefund(paymentgrp: IPaymentGroup) {\n if (paymentgrp !== null && paymentgrp !== undefined) {\n if(this.chkIsIssueRefundBtnEnable(paymentgrp.payments[0])) {\n if(paymentgrp.payments[0].over_payment > 0) {\n this.viewCompStatus = 'overpayment';\n } else {\n this.paymentGroup = paymentgrp;\n this.viewStatus = 'issuerefund';\n this.isRefundRemission = true;\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.isFromPaymentDetailPage = true;\n this.isFromServiceRequestPage = false;\n }\n }\n }\n }\n getRemissionByFeeCode(feeCode: string, remissions: IRemission[]): IRemission {\n if (remissions && remissions.length > 0) {\n for (const remission of remissions) {\n if (remission.fee_code === feeCode) {\n return remission;\n }\n }\n }\n return null;\n }\n\n chkIsIssueRefundBtnEnable(payment: IPayment): boolean {\n if (payment !== null && payment !== undefined) {\n return payment.issue_refund && payment.refund_enable\n } else {\n return false;\n }\n }\n\n chkIsAddRefundBtnEnable(remission: IRemission): boolean {\n if (remission !== null && remission !== undefined) {\n return remission.add_refund;\n } else {\n return false;\n }\n }\n\n chkIsAddRemissionBtnEnable(fee: IFee): boolean {\n if (fee !== null && fee !== undefined) {\n return fee.add_remission && fee.remission_enable;\n } else {\n return false\n }\n}\n selectPymentOption(paymentType: string) {\n this.paymentType = paymentType;\n this.isContinueBtnDisabled = false;\n }\n continuePayment(paymentgrp: IPaymentGroup) {\n \n if (this.paymentType === 'op') {\n this.isFullyRefund = false\n this.viewCompStatus = 'overPaymentAddressCapture';\n } else if(this.paymentType === 'fp') {\n this.isFullyRefund = true\n this.paymentGroup = paymentgrp;\n this.viewStatus = 'issuerefund';\n this.viewCompStatus = \"\";\n this.isRefundRemission = true;\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.isFromPaymentDetailPage = true;\n this.isFromServiceRequestPage = this.paymentLibComponent.isFromServiceRequestPage;\n }\n }\n gotoPaymentSelectPage(event: Event) {\n event.preventDefault();\n this.viewCompStatus = 'overpayment';\n }\n getContactDetails(obj:IRefundContactDetails) {\n this.contactDetailsObj = obj;\n this.notificationPreview = false;\n this.getTemplateInstructionType(this.paymentGroup.payments[0]);\n this.viewCompStatus = 'overpaymentcheckandanswer';\n \n }\n\n resetOrderData() {\n this.OrderslistService.setOrderRef(null);\n this.OrderslistService.setorderCCDEvent(null);\n this.OrderslistService.setorderCreated(null);\n this.OrderslistService.setorderDetail(null);\n this.OrderslistService.setorderParty(null);\n this.OrderslistService.setorderTotalPayments(null);\n this.OrderslistService.setorderRemissionTotal(null);\n this.OrderslistService.setorderFeesTotal(null);\n }\n\n goToPaymentFailuePage(payment: any) {\n this.viewStatus = 'payment-failure';\n this.selectedPaymentsStatus = payment;\n }\n goBackToPaymentView(event: any) {\n event.preventDefault();\n this.viewStatus = 'paymentview';\n }\n\n getTemplateInstructionType(payment: IPayment): void {\n\n if (payment == undefined || payment == null) {\n this.templateInstructionType = 'Template';\n }else{\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n \n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient, HttpHeaders} from '@angular/common/http';\nimport { Meta } from '@angular/platform-browser';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {catchError} from 'rxjs/operators';\nimport { IRefundReasons } from '../../interfaces/IRefundReasons';\nimport { IPatchRefundAction } from '../../interfaces/IPatchRefundAction';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { IssueRefundRequest } from '../../interfaces/IssueRefundRequest';\nimport { IResubmitRefundRequest } from '../../interfaces/IResubmitRefundRequest';\nimport { IRefundStatusHistory } from '../../interfaces/IRefundStatusHistory';\nimport { IPutNotificationRequest } from '../../interfaces/IPutNotificationRequest';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class RefundsService {\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService,\n private meta: Meta\n ) { }\n\n getRefundReasons(): Observable<IRefundReasons[]> {\n return this.http.get<IRefundReasons[]>(`${this.paymentLibService.REFUNDS_API_ROOT}/reasons`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getRefundRejectReasons(): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.REFUNDS_API_ROOT}/rejection-reasons`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getRefundActions(refundReference: string): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.REFUNDS_API_ROOT}/${refundReference}/actions`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\npatchRefundActions(body:IPatchRefundAction, refundReference: string, reviewerAction: string): Observable<any> {\n // const opts = this.addHeaders({});\n return this.https.patch(`${this.paymentLibService.REFUNDS_API_ROOT}/${refundReference}/action/${reviewerAction}`, body)\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetRefundList(refundstatus?: string, selfexclusive?:boolean): Observable<IRefundList[]> {\n return this.http.get<IRefundList[]>(`${this.paymentLibService.REFUNDS_API_ROOT}?status=${refundstatus}&excludeCurrentUser=${selfexclusive}`, \n {\n withCredentials: true\n})\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetRefundStatusHistory(reference?: string) {\n return this.http.get<IRefundStatusHistory>(`${this.paymentLibService.REFUNDS_API_ROOT}/${reference}/status-history`, \n {\n withCredentials: true\n})\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetRefundStatusList(ccdCaseNumber:string): Observable<IRefundList[]> {\n return this.http.get<IRefundList[]>(`${this.paymentLibService.REFUNDS_API_ROOT}?ccdCaseNumber=${ccdCaseNumber}`, {\n withCredentials: true\n})\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetUserDetails(): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.REFUNDS_API_ROOT}/get-user-details`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n \npostIssueRefund(body: IssueRefundRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.REFUNDS_API_ROOT}/refund`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\nputResendOrEdit(body: IPutNotificationRequest, refundRef:string, notificationType:string): Observable<any> {\n return this.https.put(`${this.paymentLibService.REFUNDS_API_ROOT}/resend/notification/${refundRef}?notificationType=${notificationType}`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\npatchResubmitRefund(body: IResubmitRefundRequest, refund_reference: string): Observable<any> {\n // const opts = this.addHeaders({});\n return this.https.patch(`${this.paymentLibService.REFUNDS_API_ROOT}/resubmit/${refund_reference}`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\naddHeaders(options: any): any {\n const csrfToken = this.meta.getTag('name=csrf-token');\n const headers = {};\n if (options.headers) {\n options.headers.forEach(element => {\n headers[element] = options.headers.get(element);\n });\n }\n headers['X-Requested-With'] = 'XMLHttpRequest';\n if (csrfToken.content === null) {\n if( document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')) !== undefined ) {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')).split('=')[1]; \n } else {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith(' XSRF-TOKEN')).split('=')[1];\n }\n } else {\n headers['CSRF-Token'] = csrfToken.content;\n }\n options.headers = new HttpHeaders(headers);\n options.responseType = 'text';\n return options;\n}\n}\n","import {Component, OnInit, Input} from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport {RefundsService} from '../../services/refunds/refunds.service';\nimport { IRefundAction } from '../../interfaces/IRefundAction';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRefundRejectReason } from '../../interfaces/IRefundRejectReason';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { ActivatedRoute,Router } from '@angular/router';\nimport { INotificationPreview } from '../../interfaces/INotificationPreview';\n\n@Component({\n selector: 'ccpay-process-refund',\n templateUrl: './process-refund.component.html',\n styleUrls: ['./process-refund.component.css']\n})\nexport class ProcessRefundComponent implements OnInit {\n @Input() refundReference: string;\n @Input() refundlistsource: IRefundList;\n\n processRefundForm: FormGroup;\n\n errorMessage = this.getErrorMessage(false, '', '', '');\n sendmeback: string = null;\n viewStatus: string;\n refundActionList: IRefundAction[] = [];\n refundRejectReasonList: IRefundRejectReason[] = [];\n isSendMeBackClicked: boolean = false;\n isRejectClicked: boolean = false;\n isOtherClicked: boolean = false;\n isSuccesspageEnable: boolean = false;\n\n refundActionsHasError: boolean = false;\n refundRejectReasonHasError: boolean = false;\n isReasonFieldEmpty: boolean = false;\n isReasonFieldInvalid: boolean = false;\n reasonFieldMinHasError: boolean = false;\n reasonFieldMaxHasError: boolean = false;\n isReasonEmpty: boolean = false;\n isReasonInvalid: boolean = false;\n successMsg: string = null;\n navigationpage: string;\n ccdCaseNumber: string;\n isFromRefundListPage: boolean;\n cpoDetails:any = [];\n isCPODown: boolean;\n isConfirmButtondisabled: boolean = true;\n paymentObj: IPayment;\n templateInstructionType: string;\n notificationPreview: boolean = false;\n notificationPreviewObj: INotificationPreview;\n constructor(private RefundsService: RefundsService,\n private paymentViewService: PaymentViewService,\n private formBuilder: FormBuilder,\n private OrderslistService: OrderslistService,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private router: Router,\n private activeRoute: ActivatedRoute) {\n }\n\n ngOnInit() {\n this.viewStatus = 'RefundProcess';\n this.RefundsService.getRefundActions(this.refundReference).subscribe(\n refundActionList => {\n this.refundActionList = <any>refundActionList;\n },\n err => {\n this.errorMessage = this.getErrorMessage(true, err.statusCode, err.err, err);\n }\n );\n this.processRefundForm = this.formBuilder.group({\n refundActionField: new FormControl('', Validators.compose([\n Validators.required\n ])),\n refundRejectReasonField: new FormControl('', Validators.compose([\n Validators.required\n ])),\n sendMeBackField: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$'),\n\n ])),\n enterReasonField: new FormControl('', Validators.compose([\n Validators.required,\n Validators.maxLength(30),\n Validators.pattern('^([a-zA-Z0-9.\\\\s]*)$'),\n ])),\n });\n this.ccdCaseNumber = this.refundlistsource.ccd_case_number;\n\n if((typeof this.paymentLibComponent.TAKEPAYMENT === 'string' && this.paymentLibComponent.TAKEPAYMENT === 'false') || (typeof this.paymentLibComponent.TAKEPAYMENT === 'boolean' && !this.paymentLibComponent.TAKEPAYMENT) ) {\n this.isFromRefundListPage = true;\n }\n this.paymentViewService.getPartyDetails(this.ccdCaseNumber).subscribe(\n response => {\n this.cpoDetails = JSON.parse(response).content;\n\n },\n (error: any) => {\n this.errorMessage = <any>error.replace(/\"/g,\"\");\n this.isCPODown = true;\n }\n );\n this.getTemplateInstructionType(this.paymentObj,this.refundlistsource.payment_reference);\n }\n\n checkRefundActions(code: string) {\n this.refundActionsHasError = false;\n this.isReasonFieldEmpty = false;\n this.isReasonEmpty = false;\n this.isReasonInvalid = false;\n this.refundRejectReasonHasError = false;\n if(code === 'Return to caseworker') {\n this.isConfirmButtondisabled = true;\n this.isSendMeBackClicked = true;\n this.isRejectClicked = false;\n this.isOtherClicked = false;\n\n } else if (code === 'Approve') {\n this.isSendMeBackClicked = false;\n this.isConfirmButtondisabled = false;\n this.isRejectClicked = false;\n this.isOtherClicked = false;\n\n } else if (code === 'Reject') {\n this.isRejectClicked = true;\n this.isSendMeBackClicked = false;\n this.isOtherClicked = false;\n this.RefundsService.getRefundRejectReasons().subscribe(\n refundRejectReasonList => {\n this.refundRejectReasonList = <any>refundRejectReasonList;\n },\n err => {\n this.errorMessage = this.getErrorMessage(true, err.statusCode, err.err, err);\n }\n );\n } else if (code === 'RE005') {\n this.isOtherClicked = true;\n } else if (code !== 'RE005') {\n this.isOtherClicked = false;\n }\n }\n\n getNotificationPreviewObj(notificationPreviewObj : INotificationPreview){\n this.notificationPreviewObj = notificationPreviewObj;\n }\n\n processRefundSubmit() {\n let processRefundRequest;\n let status;\n this.resetForm([false, false, false, false, false, false, false, false], 'all');\n const controls = this.processRefundForm.controls;\n const processFormError = controls.sendMeBackField.errors;\n\n if (this.processRefundForm.dirty && controls.refundActionField.valid\n && (controls.refundActionField.value == 'Approve'\n || (controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.valid && controls.refundRejectReasonField.value != 'RE005')\n || (controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.value == 'RE005' && controls.enterReasonField.valid)\n || (controls.refundActionField.value == 'Return to caseworker' && controls.sendMeBackField.valid))) {\n if (controls.refundActionField.value === 'Approve'){\n status = 'APPROVE';\n if (this.notificationPreviewObj) {\n processRefundRequest = {\n code: '',\n reason: '',\n template_preview: {\n body: this.notificationPreviewObj.body,\n from: {\n from_email_address: this.notificationPreviewObj.from.from_email_address,\n from_mail_address: {\n address_line: this.notificationPreviewObj.from.from_mail_address.address_line,\n city: this.notificationPreviewObj.from.from_mail_address.city,\n country: this.notificationPreviewObj.from.from_mail_address.country,\n county: this.notificationPreviewObj.from.from_mail_address.county,\n postal_code: this.notificationPreviewObj.from.from_mail_address.postal_code\n }\n },\n html: this.notificationPreviewObj.html,\n id: this.notificationPreviewObj.template_id,\n subject: this.notificationPreviewObj.subject,\n template_type: this.notificationPreviewObj.template_type,\n version: 0\n }\n };\n\n } else {\n processRefundRequest = {\n code: '',\n reason: ''\n };\n }\n } else if (controls.refundActionField.value === 'Reject') {\n status = 'REJECT';\n\n if (this.notificationPreviewObj) {\n processRefundRequest = {\n code: controls.refundRejectReasonField.value ? controls.refundRejectReasonField.value : '',\n reason: controls.refundRejectReasonField.value == 'RE005' ? controls.enterReasonField.value : '',\n template_preview: {\n body: this.notificationPreviewObj.body,\n from: {\n from_email_address: this.notificationPreviewObj.from.from_email_address,\n from_mail_address: {\n address_line: this.notificationPreviewObj.from.from_mail_address.address_line,\n city: this.notificationPreviewObj.from.from_mail_address.city,\n country: this.notificationPreviewObj.from.from_mail_address.country,\n county: this.notificationPreviewObj.from.from_mail_address.county,\n postal_code: this.notificationPreviewObj.from.from_mail_address.postal_code\n }\n },\n html: this.notificationPreviewObj.html,\n id: this.notificationPreviewObj.template_id,\n subject: this.notificationPreviewObj.subject,\n template_type: this.notificationPreviewObj.template_type,\n version: 0\n }\n };\n } else {\n processRefundRequest = {\n code: controls.refundRejectReasonField.value ? controls.refundRejectReasonField.value : '',\n reason: controls.refundRejectReasonField.value == 'RE005' ? controls.enterReasonField.value : ''\n };\n }\n\n\n } else if (controls.refundActionField.value === 'Return to caseworker') {\n status = 'SENDBACK';\n\n if (this.notificationPreviewObj) {\n processRefundRequest = {\n code: '',\n reason: controls.sendMeBackField.value,\n template_preview: {\n body: this.notificationPreviewObj.body,\n from: {\n from_email_address: this.notificationPreviewObj.from.from_email_address,\n from_mail_address: {\n address_line: this.notificationPreviewObj.from.from_mail_address.address_line,\n city: this.notificationPreviewObj.from.from_mail_address.city,\n country: this.notificationPreviewObj.from.from_mail_address.country,\n county: this.notificationPreviewObj.from.from_mail_address.county,\n postal_code: this.notificationPreviewObj.from.from_mail_address.postal_code\n }\n },\n html: this.notificationPreviewObj.html,\n id: this.notificationPreviewObj.template_id,\n subject: this.notificationPreviewObj.subject,\n template_type: this.notificationPreviewObj.template_type,\n version: 0\n }\n };\n } else {\n processRefundRequest = {\n code: '',\n reason: controls.sendMeBackField.value\n };\n\n }\n\n\n }\n this.RefundsService.patchRefundActions(processRefundRequest, this.refundReference, status).subscribe(\n response => {\n this.isSuccesspageEnable = true;\n // this.successMsg = JSON.parse(response)['data'];\n this.successMsg = response.replace(/['\"]+/g, '');\n },\n err => {\n this.errorMessage = this.getErrorMessage(true, err.statusCode, err.err, err);\n }\n );\n } else {\n if(controls.refundActionField.value == \"\") {\n this.resetForm([true, false, false, false, false, false, false, false], 'action');\n }\n if(controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.value == \"\") {\n this.resetForm([false, true, false, false, false, false, false, false], 'rejectReason');\n }\n if(controls.refundActionField.value == 'Return to caseworker') {\n if(controls.sendMeBackField.value == '' ) {\n this.resetForm([false, false, true, false, false, false, false, false], 'addAreason');\n }\n if(controls.sendMeBackField.value != '' && controls.sendMeBackField.invalid ) {\n this.resetForm([false, false, false, true, false, false, false, false], 'addAreason');\n }\n if(processFormError && processFormError.minlength && processFormError.minlength.actualLength < 3 ) {\n this.resetForm([false, false, false, false, true, false, false, false], 'addAreason');\n }\n if(processFormError && processFormError.maxlength && processFormError.maxlength.actualLength > 255 ) {\n this.resetForm([false, false, false, false, false, true, false, false], 'addAreason');\n }\n }\n if(controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.value == 'RE005') {\n if(controls.enterReasonField.value === \"\") {\n this.resetForm([false, false, false, false, false, false, true, false], 'enterReason');\n }\n if(controls.enterReasonField.value!== \"\" && controls.enterReasonField.invalid) {\n this.resetForm([false, false, false, false, false, false, false, true], 'enterReason');\n }\n }\n }\n\n }\n getErrorMessage(isErrorExist, status, errorMsg, err) {\n let bodyTxt = 'Please try again later';\n if (status !== 500) {\n if (errorMsg !== undefined) {\n bodyTxt = errorMsg;\n } else {\n bodyTxt = err;\n }\n\n }\n return {\n title: 'Something went wrong',\n body: bodyTxt,\n showError: isErrorExist\n };\n }\n loadRefundListPage() {\n this.OrderslistService.getnavigationPageValue().subscribe((data) => this.navigationpage = data);\n if (this.navigationpage === 'casetransactions') {\n // window.location.href='/refund-list?takePayment=false&refundlist=true';\n // // this.OrderslistService.setnavigationPage('casetransactions');\n // // this.OrderslistService.setisFromServiceRequestPage(false);\n // // this.paymentLibComponent.VIEW ='case-transactions';\n // // this.paymentLibComponent.viewName = 'case-transactions';\n // // this.paymentLibComponent.ISBSENABLE = true;\n // // this.paymentLibComponent.isRefundStatusView = false;\n this.paymentLibComponent.viewName = 'refundstatuslist';\n this.paymentLibComponent.isRefundStatusView = true;\n } else {\n this.paymentLibComponent.viewName = 'refundstatuslist';\n this.paymentLibComponent.isRefundStatusView = true;\n }\n }\n loadRefundsHomePage() {\n if(typeof this.paymentLibComponent.TAKEPAYMENT === 'string' && this.paymentLibComponent.TAKEPAYMENT === 'false') {\n //window.location.href='/refund-list?takePayment=false&refundlist=true';\n this.paymentLibComponent.viewName = 'refund-list';\n }\n else {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.VIEW ='case-transactions';\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n }\n }\n redirecttoRefundListPage() {\n if((typeof this.paymentLibComponent.TAKEPAYMENT === 'string' && this.paymentLibComponent.TAKEPAYMENT === 'false') || (typeof this.paymentLibComponent.TAKEPAYMENT === 'boolean' && !this.paymentLibComponent.TAKEPAYMENT) ) {\n // window.location.href='/refund-list?takePayment=false&refundlist=true';\n this.paymentLibComponent.viewName = 'refund-list';\n }\n else {\n this.loadRefundListPage();\n }\n }\n loadCaseTransactionPage() {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n }\n\n resetForm(vals, field) {\n if(field==='action' || field==='all') {\n this.refundActionsHasError = vals[0];\n }\n if(field==='rejectReason' || field==='all') {\n this.refundRejectReasonHasError = vals[1];\n }\n if(field==='addAreason' || field==='all') {\n this.isReasonFieldEmpty = vals[2];\n this.isReasonFieldInvalid = vals[3];\n this.reasonFieldMinHasError = vals[4];\n this.reasonFieldMaxHasError = vals[5];\n }\n if(field==='enterReason' || field==='all') {\n this.isReasonEmpty = vals[6];\n this.isReasonInvalid = vals[7];\n }\n }\n\n goToCaseReview() {\n const isPayBubble = this.paymentLibComponent.isFromPayBubble;\n if(isPayBubble) {\n this.loadCaseTransactionPage();\n } else {\n this.router.navigate([`/cases/case-details/${this.ccdCaseNumber}`], {relativeTo: this.activeRoute});\n }\n }\n\n getTemplateInstructionType(payment: IPayment, paymentReference: string): void {\n\n if (payment == undefined || payment == null || payment.reference != paymentReference) {\n\n this.paymentViewService.getPaymentDetails(paymentReference).subscribe(\n payment => {\n this.paymentObj = payment;\n this.paymentObj.reference = paymentReference;\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(this.paymentObj.channel, this.paymentObj.method);\n },\n (error: any) => {\n this.templateInstructionType = 'Template';\n })\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n}\n","import {Component, OnInit, Input} from '@angular/core';\nimport { RefundsService } from '../../services/refunds/refunds.service';\nimport { IRefundList } from '../../interfaces/IRefundList';\n\n@Component({\n selector: 'ccpay-refund-list',\n templateUrl: './refund-list.component.html',\n styleUrls: ['./refund-list.component.css']\n})\nexport class RefundListComponent implements OnInit {\n @Input('USERID') USERID: string;\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: any[];\n @Input('LOGGEDINUSEREMAIL') LOGGEDINUSEREMAIL:string;\n\n constructor(private refundService: RefundsService) {\n }\n\n tableApprovalHeader: string;\n tableRejectedHeader: string;\n submittedRefundList: IRefundList[] = [];\n rejectedRefundList: IRefundList[] = [];\n // approvalStatus = 'Sent for approval';\n // rejectStatus = 'Update required';\n approvalStatus = 'Sent for approval';\n rejectStatus = 'Update required';\n errorMessage = null;\n isApproveTableVisible:boolean;\n isRejectTableVisible:boolean;\n dropdownvalue: string;\n isAuthorized: boolean = true;\n userLst\n ngOnInit() {\n \n this.userLst = this.LOGGEDINUSERROLES;\n\n \n if(this.LOGGEDINUSERROLES.some(i =>i.includes('payments-refund-approver'))){\n this.isAuthorized = true;\n } else {\n this.isApproveTableVisible = false;\n this.isAuthorized = false;\n }\n\n \n this.tableApprovalHeader = 'Refunds to be approved';\n this.tableRejectedHeader = 'Refunds returned to caseworker';\n\n if(this.isAuthorized) {\n this.refundService.getRefundList(this.approvalStatus,true).subscribe(\n refundList => {\n this.submittedRefundList = refundList['refund_list'];\n this.isApproveTableVisible = true;\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n };\n }\n\n this.refundService.getRefundList(this.rejectStatus,false).subscribe(\n refundList => {\n this.rejectedRefundList = refundList['refund_list'];\n this.isRejectTableVisible = true;\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n };\n\n }\n \n}","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {Observable} from 'rxjs/internal/Observable';\n\nimport {ICardDetails} from '../../interfaces/ICardDetails';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport { catchError } from 'rxjs/operators';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { LoggerService } from '../shared/logger/logger.service';\n\n\n@Injectable({\n providedIn: 'root'\n})\nexport class CardDetailsService {\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n getCardDetails(paymentReference: string): Observable<ICardDetails> {\n this.logger.info('Card-detail-service getCardDetails for: ', paymentReference);\n\n return this.http.get<ICardDetails>(`${this.paymentLibService.API_ROOT}/card-payments/${paymentReference}/details`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Component, OnInit } from '@angular/core';\nimport { CardDetailsService } from '../../services/card-details/card-details.service';\nimport {ICardDetails} from '../../interfaces/ICardDetails';\nimport { PaymentLibComponent } from '../../payment-lib.component';\n\n@Component({\n selector: 'ccpay-card-details',\n templateUrl: './card-details.component.html',\n styleUrls: ['./card-details.component.css']\n})\nexport class CardDetailsComponent implements OnInit {\n pageTitle: string = 'Card details';\n cardDetails: ICardDetails;\n paymentReference: string;\n errorMessage: string;\n\n constructor(private cardDetailsService: CardDetailsService,\n private paymentLibComponent: PaymentLibComponent) { }\n\n ngOnInit() {\n this.cardDetailsService.getCardDetails(this.paymentLibComponent.paymentReference).subscribe(\n cardDetails => this.cardDetails = cardDetails,\n (error: any) => this.errorMessage = <any>error\n );\n }\n\n get getPaymentReference(): string {\n return this.paymentReference;\n }\n\n}\n","import { Component } from '@angular/core';\n\n@Component({\n template: `\n <h1>This is not the page you were looking for!</h1>\n `\n})\nexport class PageNotFoundComponent { }\n","import { Injectable } from '@angular/core';\nimport { PaymentLibService } from '../../payment-lib.service';\nimport { HttpClient } from '@angular/common/http';\nimport { IStatusHistories } from '../../interfaces/IStatusHistories';\nimport { Observable } from 'rxjs/internal/Observable';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { catchError } from 'rxjs/operators';\nimport { LoggerService } from '../shared/logger/logger.service';\n\n\n@Injectable({\n providedIn: 'root'\n})\nexport class StatusHistoryService {\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n getPaymentStatusesByReference(paymentReference: string, paymentMethod: string): Observable<IStatusHistories> {\n this.logger.info('Status-history-service getPaymentStatusesByReference for: ', paymentReference);\n\n return this.http.get<IStatusHistories>(paymentMethod === 'card' || paymentMethod === 'cash' || paymentMethod === 'cheque' || paymentMethod === 'postal order' ?\n `${this.paymentLibService.API_ROOT}/card-payments/${paymentReference}/statuses` :\n `${this.paymentLibService.API_ROOT}/credit-account-payments/${paymentReference}/statuses`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { IStatusHistories } from '../../interfaces/IStatusHistories';\nimport { StatusHistoryService } from '../../services/status-history/status-history.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\n\n@Component({\n selector: 'ccpay-payment-statuses',\n templateUrl: './status-history.component.html',\n styleUrls: ['./status-history.component.css']\n})\nexport class StatusHistoryComponent implements OnInit {\n @Input() isTakePayment: boolean;\n pageTitle: string = 'Payment status history';\n statuses: IStatusHistories;\n errorMessage: string;\n\n constructor(private statusHistoryService: StatusHistoryService,\n private paymentLibComponent: PaymentLibComponent) { }\n\n ngOnInit() {\n this.statusHistoryService.getPaymentStatusesByReference(this.paymentLibComponent.paymentReference, this.paymentLibComponent.paymentMethod).subscribe(\n statuses => this.statuses = statuses,\n (error: any) => this.errorMessage = <any>error.replace(/\"/g,\"\")\n );\n \n }\n\n}\n","import { Component, OnInit, Output, EventEmitter, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { NotificationService } from '../../services/notification/notification.service';\n\n@Component({\n selector: 'ccpay-contact-details',\n templateUrl: './contact-details.component.html',\n styleUrls: ['./contact-details.component.css']\n})\nexport class ContactDetailsComponent implements OnInit {\n @Input('isEditOperation') isEditOperation: boolean;\n @Input('isEditOperationInRefundList') isEditOperationInRefundList: boolean;\n @Input('addressObj') addressObj: any;\n @Output() assignContactDetails: EventEmitter<any> = new EventEmitter();\n @Output() assignContactDetailsInFefundsList: EventEmitter<any> = new EventEmitter();\n @Output() redirectToIssueRefund: EventEmitter<any> = new EventEmitter();\n pageTitle: string = 'Payment status history';\n errorMessage: string;\n isEmailSAddressClicked: boolean = true;\n isShowPickAddress: boolean = false;\n isPostcodeClicked: boolean = false;\n isManualAddressClicked: boolean = false;\n emailAddressForm: FormGroup;\n postCodeForm: FormGroup;\n manualAddressForm: FormGroup;\n addressPostcodeList:any[] = [];\n postcodeAddress:any;\n isAddressBoxEmpty: boolean = false;\n\n isEmailEmpty: boolean = false;\n emailHasError: boolean = false;\n isPostcodeEmpty: boolean = false;\n postcodeHasError: boolean = false;\n isaddressLine1Empty: boolean = false;\n addressLine1HasError: boolean = false;\n addressLine2HasError: boolean = false;\n isTownOrCityEmpty: boolean = false;\n townOrCityHasError: boolean = false;\n isCountyEmpty: boolean = false;\n countyHasError: boolean = false;\n isMPostcodeEmpty: boolean = false;\n mpostcodeHasError: boolean = false;\n isCountryEmpty: boolean = false;\n\n constructor(private formBuilder: FormBuilder,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent) { }\n\n ngOnInit() {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n\n this.emailAddressForm = this.formBuilder.group({\n email: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('.+@+.+\\\\.+.+')\n ]))\n });\n this.postCodeForm = this.formBuilder.group({\n postcode: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([A-Za-z]{1,2}[0-9]{1,2}[A-Za-z]{0,1} ?[0-9][A-Za-z]{2})')\n ]))\n });\n this.manualAddressForm = this.formBuilder.group({\n addressl1: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n addressl2: new FormControl('', Validators.compose([\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n townorcity: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n county: new FormControl('', Validators.compose([\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n mpostcode: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([A-Za-z]{1,2}[0-9]{1,2}[A-Za-z]{0,1} ?[0-9][A-Za-z]{2})')\n ])),\n country: new FormControl('', Validators.compose([\n Validators.required\n ]))\n });\n if(this.addressObj !== undefined && this.addressObj !== '') {\n this.setEditDetails();\n }\n if(this.isEditOperationInRefundList === undefined) {\n this.isEditOperationInRefundList = false;\n }\n }\n setEditDetails() {\n if(this.addressObj.notification_type === 'EMAIL') {\n this.isEmailSAddressClicked = true;\n this.isPostcodeClicked = false;\n this.isManualAddressClicked = false;\n this.emailAddressForm.setValue({ email: this.addressObj.contact_details.email });\n } else if(this.addressObj.notification_type === 'LETTER') {\n this.isEmailSAddressClicked = false;\n this.isPostcodeClicked = true;\n this.isManualAddressClicked = true;\n this.manualAddressForm.patchValue({ \n addressl1: this.addressObj.contact_details.address_line,\n townorcity: this.addressObj.contact_details.city,\n county: this.addressObj.contact_details.county,\n country: this.addressObj.contact_details.country,\n mpostcode: this.addressObj.contact_details.postal_code\n });\n }\n }\n\n selectContactOption(type, isLinkedClied) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n if( type === 'Email' && isLinkedClied === 'false'){\n this.isEmailSAddressClicked = true;\n this.isPostcodeClicked = false;\n this.isManualAddressClicked = false;\n } else if(type === 'Postcode' && isLinkedClied === 'false') {\n this.isEmailSAddressClicked = false;\n this.isPostcodeClicked = true;\n this.isManualAddressClicked = false;\n } else if(type === 'Postcode' && isLinkedClied === 'true') {\n this.isEmailSAddressClicked = false;\n this.isPostcodeClicked = true;\n this.isManualAddressClicked = true;\n\n }\n }\n\n finalFormSubmit() {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n if( this.isEmailSAddressClicked ){\n const emailField = this.emailAddressForm.controls.email;\n if (this.emailAddressForm.valid) {\n if(!this.isEditOperationInRefundList) {\n this.assignContactDetails.emit( {\n email: emailField.value,\n notification_type: 'EMAIL'\n } );\n } else {\n this.assignContactDetailsInFefundsList.emit({\n email: emailField.value,\n notification_type: 'EMAIL'\n } );\n }\n } else {\n if( emailField.value == '' ) {\n this.resetForm([true,false,false,false,false,false,false,false,false,false,false,false,false,false], 'email');\n }\n if(emailField.value != '' && emailField.invalid ) {\n this.resetForm([false,true,false,false,false,false,false,false,false,false,false,false,false,false], 'email');\n }\n }\n } else if( this.isPostcodeClicked && !this.isManualAddressClicked ) {\n this.postcodeValidation('FS');\n } else if(this.isPostcodeClicked && this.isManualAddressClicked) {\n const fieldCtrls = this.manualAddressForm.controls;\n if (this.manualAddressForm.valid) {\n if(!this.isEditOperationInRefundList) {\n this.assignContactDetails.emit({\n address_line: fieldCtrls.addressl1.value+' '+fieldCtrls.addressl2.value,\n city: fieldCtrls.townorcity.value,\n county: fieldCtrls.county.value,\n postal_code: fieldCtrls.mpostcode.value,\n country: fieldCtrls.country.value,\n notification_type: 'LETTER'\n });\n } else {\n this.assignContactDetailsInFefundsList.emit({\n address_line: fieldCtrls.addressl1.value+' '+fieldCtrls.addressl2.value,\n city: fieldCtrls.townorcity.value,\n county: fieldCtrls.county.value,\n postal_code: fieldCtrls.mpostcode.value,\n country: fieldCtrls.country.value,\n notification_type: 'LETTER'\n });\n }\n } else {\n if( fieldCtrls.addressl1.value == '' ) {\n this.resetForm([false,false,false,false,true,false,false,false,false,false,false,false,false,false], 'address1');\n }\n if(fieldCtrls.addressl1.value != '' && fieldCtrls.addressl1.invalid ) {\n this.resetForm([false,false,false,false,false,true,false,false,false,false,false,false,false,false], 'address1');\n }\n if(fieldCtrls.addressl2.value != '' && fieldCtrls.addressl2.invalid ) {\n this.resetForm([false,false,false,false,false,false,true,false,false,false,false,false,false,false], 'address2');\n }\n if( fieldCtrls.townorcity.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,true,false,false,false,false,false,false], 'town');\n }\n if(fieldCtrls.townorcity.value != '' && fieldCtrls.townorcity.invalid ) {\n this.resetForm([false,false,false,false,false,false,false,false,true,false,false,false,false,false], 'town');\n }\n if( fieldCtrls.county.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,true,false,false,false,false], 'county');\n }\n if(fieldCtrls.county.value != '' && fieldCtrls.county.invalid ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,true,false,false,false], 'county');\n }\n if( fieldCtrls.mpostcode.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,true,false,false], 'mpostcode');\n }\n if(fieldCtrls.mpostcode.value != '' && fieldCtrls.mpostcode.invalid ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,true,false], 'mpostcode');\n }\n if( fieldCtrls.country.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,true], 'country');\n }\n }\n\n }\n\n }\n\n postcodeValidation(str) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n const postcodeField = this.postCodeForm.controls.postcode;\n if (this.postCodeForm.valid) {\n if(str === 'FA') {\n this.notificationService.getAddressByPostcode(postcodeField.value).subscribe(\n refundsNotification => {\n this.addressPostcodeList = refundsNotification['results'];\n this.isShowPickAddress = refundsNotification['header'].totalresults > 0;\n if(!this.isShowPickAddress) {\n this.resetForm([false,false,false,true,false,false,false,false,false,false,false,false,false], 'postcode');\n }\n }\n ),\n (error: any) => {\n this.isShowPickAddress = false;\n this.errorMessage = error.replace(/\"/g,\"\");\n }; \n } else if (str === 'FS') {\n if(this.postcodeAddress !== undefined && this.postcodeAddress) {\n this.isAddressBoxEmpty = false;\n let addressLine=\"\";\n let addressArray = this.postcodeAddress.ADDRESS.split(\",\");\n for( let i=0; i<addressArray.length-2; i++ ) {\n addressLine +=addressArray[i]; \n }\n const addressObject = {\n address_line: addressLine,\n city: this.postcodeAddress.POST_TOWN,\n county: this.postcodeAddress.LOCAL_CUSTODIAN_CODE_DESCRIPTION,\n postal_code: this.postcodeAddress.POSTCODE,\n country: 'United Kingdom',\n notification_type: 'LETTER'\n };\n if(!this.isEditOperationInRefundList) {\n this.assignContactDetails.emit(addressObject);\n } else {\n this.assignContactDetailsInFefundsList.emit(addressObject);\n }\n } else {\n this.isAddressBoxEmpty = true;\n }\n }\n } else {\n if( postcodeField.value == '' ) {\n this.resetForm([false,false,true,false,false,false,false,false,false,false,false,false,false], 'postcode');\n }\n if(postcodeField.value != '' && postcodeField.invalid ) {\n this.resetForm([false,false,false,true,false,false,false,false,false,false,false,false,false], 'postcode');\n }\n }\n }\n redirection(event:any) {\n this.redirectToIssueRefund.emit(event);\n }\n resetForm(val, field) {\n if(field==='email' || field==='all') {\n this.isEmailEmpty = val[0];\n this.emailHasError = val[1];\n }\n if(field==='postcode' || field==='all') {\n this.isPostcodeEmpty = val[2];\n this.postcodeHasError = val[3];\n }\n if(field==='address1' || field==='all') {\n this.isaddressLine1Empty = val[4];\n this.addressLine1HasError = val[5];\n }\n if(field==='address2' || field==='all') {\n this.addressLine2HasError = val[6];\n }\n if(field==='town' || field==='all') {\n this.isTownOrCityEmpty = val[7];\n this.townOrCityHasError = val[8];\n }\n if(field==='county' || field==='all') {\n this.isCountyEmpty = val[9];\n this.countyHasError = val[10];\n }\n if(field==='mpostcode' || field==='all') {\n this.isMPostcodeEmpty = val[11];\n this.mpostcodeHasError = val[12];\n }\n if(field==='country' || field==='all') {\n this.isCountryEmpty = val[13];\n }\n \n }\n}\n","import { Component, Input, OnInit } from '@angular/core';\nimport { IPayment } from '../../interfaces/IPayment';\n\n@Component({\n selector: 'ccpay-pba-details',\n templateUrl: './pba-details.component.html',\n styleUrls: ['./pba-details.component.css']\n})\nexport class PbaDetailsComponent implements OnInit {\n @Input() payment: IPayment;\n\n constructor() { }\n\n ngOnInit() {\n }\n\n}\n","import { Injectable } from '@angular/core';\nimport { Logger } from './logger.service';\n\nexport let isDebugMode = false;\n\nconst noop = (): any => undefined;\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ConsoleLoggerService implements Logger {\n\n get info() {\n if (isDebugMode) {\n return console.info.bind(console);\n } else {\n return noop;\n }\n }\n\n get warn() {\n if (isDebugMode) {\n return console.warn.bind(console);\n } else {\n return noop;\n }\n }\n\n get error() {\n if (isDebugMode) {\n return console.error.bind(console);\n } else {\n return noop;\n }\n }\n\n invokeConsoleMethod(type: string, args?: any): void {\n const logFn: Function = (console)[type] || console.log || noop;\n logFn.apply(console, [args]);\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {LoggerService} from '../shared/logger/logger.service';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport {catchError} from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class CaseTransactionsService {\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService\n ) { }\n\n getPaymentGroups(ccdCaseNumber: string): Observable<IPaymentGroup[]> {\n this.logger.info('Case-transactions-service getPaymentGroups for: ', ccdCaseNumber);\n\n return this.http.get<IPaymentGroup[]>(`${this.paymentLibService.API_ROOT}/cases/${ccdCaseNumber}/paymentgroups`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {catchError} from 'rxjs/operators';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\n\n\n@Injectable({\n providedIn: 'root'\n})\nexport class BulkScaningPaymentService {\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService\n ) { }\n\n getBSPaymentsByCCD(ccdCaseNumber: string): Observable<IBSPayments> {\n return this.http.get<IBSPayments>(`${this.paymentLibService.BULKSCAN_API_ROOT}/cases/${ccdCaseNumber}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getBSPaymentsByDCN(dcn: string): Observable<IBSPayments> {\n return this.http.get<IBSPayments>(`${this.paymentLibService.BULKSCAN_API_ROOT}/cases?document_control_number=${dcn}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSAllocatePayment(body: AllocatePaymentRequest, paymentRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentRef}/bulk-scan-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSPaymentStrategic(body: AllocatePaymentRequest, paymentGroupRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupRef}/bulk-scan-payments-strategic`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSWoPGStrategic(body: AllocatePaymentRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/bulk-scan-payments-strategic`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n patchBSChangeStatus(dcnNumber: string, status: string): Observable<any> {\n return this.https.patch(`${this.paymentLibService.API_ROOT}/bulk-scan-payments/${dcnNumber}/status/${status}`, status).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n calculateOutStandingAmount(paymentGroup: IPaymentGroup): number {\n let feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00;\n\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n feesTotal = feesTotal + fee.calculated_amount;\n });\n }\n\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n }\n });\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n remissionsTotal = remissionsTotal + remission.hwf_amount;\n });\n } \n return (feesTotal - remissionsTotal) - paymentsTotal;\n }\n\n removeUnwantedString(input: string, replaceText: string) {\n const pattern = /[\\_]/gi;\n return input.replace(pattern, replaceText);\n }\n\n downloadSelectedReport(reportName: string, startDate: string, endDate:string): Observable<any> {\n return this.https.get(`${this.paymentLibService.BULKSCAN_API_ROOT}/report/data?date_from=${startDate}&date_to=${endDate}&report_type=${reportName}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { CaseTransactionsService } from '../../services/case-transactions/case-transactions.service';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IFee } from '../../interfaces/IFee';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { IPaymentView } from '../../interfaces/IPaymentView';\nimport { IOrderReferenceFee } from '../../interfaces/IOrderReferenceFee';\nimport { Router } from '@angular/router';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\n\n@Component({\n selector: 'ccpay-case-transactions',\n templateUrl: './case-transactions.component.html',\n styleUrls: ['./case-transactions.component.css']\n})\nexport class CaseTransactionsComponent implements OnInit {\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[];\n @Input() isTakePayment: boolean;\n @Input() isFromServiceRequestPage: boolean;\n takePayment: boolean;\n ccdCaseNumber: string;\n excReference: string;\n paymentGroups: any[] = [];\n payments: IPayment[] = [];\n nonPayments: IPayment[] = [];\n allPayments: IPayment[] = [];\n remissions: IRemission[] = [];\n fees: IFee[] = [];\n errorMessage: string;\n totalFees: number;\n totalPayments: number = 0;\n totalNonOffPayments: number;\n totalRemissions: number = 0;\n selectedOption: string;\n dcnNumber: string;\n paymentRef: string;\n isTurnOff: boolean;\n isRefundRemission: boolean = true;\n isStrategicFixEnable: boolean;\n isAddFeeBtnEnabled: boolean = true;\n isExceptionRecord: boolean = false;\n isUnprocessedRecordSelected: boolean = false;\n exceptionRecordReference: string;\n isAnyFeeGroupAvilable: boolean = true;\n isHistoricGroupAvailable: boolean = false;\n isBulkScanEnable;\n isRemissionsMatch: boolean;\n viewStatus = 'main';\n isRemoveBtnDisabled: boolean = false;\n feeId: IFee;\n clAmountDue: number = 0;\n overPaymentAmount: number = 0;\n unprocessedRecordCount: number;\n isFeeRecordsExist: boolean = false;\n isGrpOutstandingAmtPositive: boolean = false;\n totalRefundAmount: number;\n caseType: String;\n // lsCcdNumber: any = ls.get<any>('ccdNumber');\n payment: IPayment;\n paymentGroup: IPaymentGroup;\n paymentView: IPaymentView;\n\n //Order changes\n orderDetail: any[] = [];\n\n isAddRemissionEnable: boolean = false;\n orderRemissionDetails: any[] = [];\n orderLevelFees: IOrderReferenceFee[] = [];\n ispaymentGroupApisuccess: boolean = false;\n cpoDetails: any[] = [];\n orderRef: string;\n orderStatus: string;\n orderParty: string;\n orderCreated: Date;\n orderCCDEvent: string;\n serviceRequestValue: string;\n orderAddBtnEnable: boolean;\n orderFeesTotal: number = 0.00;\n orderRemissionTotal: number = 0.00;\n orderTotalPayments: number = 0.00;\n orderPendingPayments: number = 0.00;\n isCPODown: boolean;\n test: boolean;\n isPBA: boolean = false;\n isIssueRefunfBtnEnable: boolean = false;\n isAddRemissionBtnEnabled: boolean = false;\n isRefundRemissionBtnEnable: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund'];\n isEligible4PBAPayment = ['pui-finance-manager', 'pui-user-manager', 'pui-organisation-manager', 'pui-case-manager'];\n currentDate = new Date();\n //isFromServiceRequestPage: boolean;\n navigationpage: string;\n remissionFeeAmt: number;\n constructor(private router: Router,\n private paymentViewService: PaymentViewService,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private caseTransactionsService: CaseTransactionsService,\n private paymentLibComponent: PaymentLibComponent,\n private OrderslistService: OrderslistService\n ) { }\n\n ngOnInit() {\n this.navigationpage = '';\n if(this.OrderslistService.getpaymentPageView() !== null) {\n this.OrderslistService.getpaymentPageView().subscribe((data) => this.paymentView = data);\n }\n if((this.LOGGEDINUSERROLES === undefined || this.LOGGEDINUSERROLES.length === 0 )&&this.OrderslistService.getUserRolesList() !== null) {\n this.OrderslistService.getUserRolesList().subscribe((data) => this.LOGGEDINUSERROLES = data);\n }\n if(this.OrderslistService.getnavigationPageValue() !== null) {\n this.OrderslistService.getnavigationPageValue().subscribe((data) => this.navigationpage = data);\n }\n\n if (this.paymentView !== undefined && this.paymentView !== null && this.paymentView.payment_group_reference !== undefined && this.navigationpage === 'paymentdetailspage') {\n this.goToPayementView(this.paymentView.payment_group_reference, this.paymentView.reference, this.paymentView.method);\n }\n this.isGrpOutstandingAmtPositive = false;\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.caseType = this.paymentLibComponent.CASETYPE;\n if (this.paymentLibComponent.CCD_CASE_NUMBER === '') {\n this.ccdCaseNumber = this.paymentLibComponent.EXC_REFERENCE;\n }\n this.excReference = this.paymentLibComponent.EXC_REFERENCE;\n this.takePayment = this.paymentLibComponent.TAKEPAYMENT;\n\n const serviceRequest = this.paymentLibComponent.SERVICEREQUEST;\n if ( serviceRequest !== undefined && serviceRequest.toString() === 'true' ) {\n this.serviceRequestValue = 'true';\n } else {\n this.serviceRequestValue = 'false';\n this.paymentLibComponent.isFromServiceRequestPage = false;\n }\n this.isBulkScanEnable = this.paymentLibComponent.ISBSENABLE;\n this.dcnNumber = this.paymentLibComponent.DCN_NUMBER;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION.toLocaleLowerCase();\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n if (!this.isTurnOff) {\n // if (this.lsCcdNumber !== this.ccdCaseNumber) {\n // this.router.navigateByUrl(`/ccd-search?takePayment=true`);\n // }\n\n this.caseTransactionsService.getPaymentGroups(this.ccdCaseNumber).subscribe(\n paymentGroups => {\n this.isAnyFeeGroupAvilable =true;\n this.paymentGroups = paymentGroups['payment_groups'];\n this.calculateAmounts();\n this.calculateOrderFeesAmounts();\n this.calculateRefundAmount();\n if (this.isFromServiceRequestPage) {\n this.OrderslistService.getSelectedOrderRefId().subscribe((data) => this.orderRef = data);\n this.goToOrderViewDetailSection(this.orderRef);\n } else {\n this.paymentViewService.getPartyDetails(this.ccdCaseNumber).subscribe(\n response => {\n this.cpoDetails = JSON.parse(response).content;\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.isCPODown = true;\n }\n );\n\n }\n\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.isAnyFeeGroupAvilable = false;\n this.setDefaults();\n }\n );\n } else {\n this.caseTransactionsService.getPaymentGroups(this.ccdCaseNumber).subscribe(\n paymentGroups => {\n this.isAnyFeeGroupAvilable =true;\n this.paymentGroups = paymentGroups['payment_groups'];\n this.calculateAmounts();\n this.calculateOrderFeesAmounts();\n this.totalRefundAmount = this.calculateRefundAmount();\n this.paymentViewService.getPartyDetails(this.ccdCaseNumber).subscribe(\n response => {\n this.cpoDetails = JSON.parse(response).content;\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.setDefaults();\n this.isCPODown = true;\n }\n );\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.isAnyFeeGroupAvilable = false;\n this.setDefaults();\n }\n );\n }\n\n if( this.paymentGroups !== undefined) {\n this.checkForExceptionRecord();\n }\n\n if(this.OrderslistService.getisFromServiceRequestPages() !== null) {\n this.OrderslistService.getisFromServiceRequestPages().subscribe((data) => this.isFromServiceRequestPage = data);\n }\n\n }\n\n setDefaults(): void {\n this.totalPayments = 0.00;\n this.totalRemissions = 0.00;\n this.totalNonOffPayments = 0.00;\n this.totalFees = 0.00;\n }\n\n getAllocationStatus(payments: any) {\n\n let paymentAllocation = payments.payment_allocation,\n isAllocationStatusExist = paymentAllocation.length > 0;\n return isAllocationStatusExist ? paymentAllocation[0].allocation_status : '-';\n //return \"-\";\n\n }\n\n checkForExceptionRecord(): void {\n\n if (this.paymentGroups.length === 0 && (this.selectedOption.toLocaleLowerCase() === 'ccdorexception' || this.selectedOption.toLocaleLowerCase() === 'rc')) {\n this.bulkScaningPaymentService.getBSPaymentsByCCD(this.ccdCaseNumber).subscribe(\n recordData => {\n if (recordData['data'] && recordData['data'].exception_record_reference && recordData['data'].exception_record_reference.length > 0 && recordData['data'].ccd_reference > 0) {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n\n if (recordData['data'] && recordData['data'].exception_record_reference && recordData['data'].exception_record_reference.length > 0 && recordData['data'].ccd_reference === undefined) {\n this.isExceptionRecord = true;\n this.isAddFeeBtnEnabled = false;\n }\n\n if (recordData['data'] && recordData['data'].exception_record_reference && recordData['data'].exception_record_reference.length === undefined && recordData['data'].ccd_reference > 0) {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n });\n }\n\n if (this.paymentGroups.length === 0 && this.selectedOption.toLocaleLowerCase() === 'dcn') {\n if (this.paymentLibComponent.CCD_CASE_NUMBER.length > 0 && this.paymentLibComponent.EXC_REFERENCE.length > 0) {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n } else if (this.paymentLibComponent.CCD_CASE_NUMBER.length === 0 && this.paymentLibComponent.EXC_REFERENCE.length > 0) {\n this.isExceptionRecord = true;\n this.isAddFeeBtnEnabled = false;\n } else {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n }\n if (this.paymentGroups.length > 0)\n this.paymentGroups.forEach(paymentGroup => {\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.case_reference !== undefined && payment.ccd_case_number === undefined) {\n this.isExceptionRecord = true;\n this.isAddFeeBtnEnabled = false;\n } else {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n\n });\n }\n });\n }\n\n calculateOrderFeesAmounts(): void {\n let feesTotal = 0.00;\n this.paymentGroups.forEach((paymentGroup, index) => {\n\n this.resetOrderVariables();\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n this.orderFeesTotal = this.orderFeesTotal + fee.calculated_amount\n this.overPaymentAmount = this.overPaymentAmount + fee.over_payment\n }\n )\n }\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n this.orderRemissionTotal = this.orderRemissionTotal + remission.hwf_amount;\n });\n }\n\n if (paymentGroup.payments) {\n const isFeeOverPaymentExist = this.overPaymentAmount === 0;\n paymentGroup.payments.forEach((payment) => {\n if(isFeeOverPaymentExist) {\n this.overPaymentAmount = this.overPaymentAmount + payment.over_payment\n }\n if (payment.status.toUpperCase() === 'SUCCESS') {\n this.orderTotalPayments = this.orderTotalPayments + payment.amount;\n }\n });\n }\n\n // this.orderPendingPayments = (this.orderFeesTotal - this.orderRemissionTotal) - this.orderTotalPayments;\n if (paymentGroup.service_request_status === 'Paid') {\n this.orderStatus = paymentGroup.service_request_status;\n this.orderAddBtnEnable = false;\n } else if (paymentGroup.service_request_status === 'Partially paid' || paymentGroup.service_request_status === 'Not paid') {\n this.orderStatus = paymentGroup.service_request_status;\n this.orderAddBtnEnable = true;\n } else if (paymentGroup.service_request_status === 'Disputed'){\n this.orderStatus = paymentGroup.service_request_status;\n this.orderAddBtnEnable = true;\n }\n\n //this.orderLevelFees.push({orderRefId:paymentGroup['payment_group_reference'],orderTotalFees: this.orderFeesTotal,orderStatus: this.orderStatus,orderParty:'Santosh', orderCCDEvent:'Case Creation',orderCreated: new Date(), orderAddBtnEnable: this.orderAddBtnEnable}); this.cpoDetails['createdTimestamp']\n if (this.cpoDetails !== null && this.cpoDetails.length !== 0) {\n this.orderLevelFees.push({ orderRefId: paymentGroup['payment_group_reference'], orderTotalFees: this.orderFeesTotal, orderStatus: this.orderStatus, orderParty: this.cpoDetails[index].responsibleParty, orderCCDEvent: this.cpoDetails[index].action, orderCreated: paymentGroup['date_created'], orderAddBtnEnable: this.orderAddBtnEnable });\n\n } else {\n this.orderLevelFees.push({ orderRefId: paymentGroup['payment_group_reference'], orderTotalFees: this.orderFeesTotal, orderStatus: this.orderStatus, orderParty: '', orderCCDEvent: '', orderCreated: paymentGroup['date_created'], orderAddBtnEnable: this.orderAddBtnEnable });\n }\n\n if (this.orderStatus !== 'Paid') {\n this.OrderslistService.setOrdersList(this.orderLevelFees);\n }\n });\n };\n\n resetOrderVariables(): void {\n this.orderFeesTotal = 0.00;\n this.orderTotalPayments = 0.00;\n this.orderRemissionTotal = 0.00;\n this.orderPendingPayments = 0.00;\n this.isAddFeeBtnEnabled = true;\n\n };\n\n goToOrderViewDetailSection(orderReferenceObj: any) {\n if (this.isFromServiceRequestPage) {\n this.OrderslistService.setOrderRefId(orderReferenceObj);\n this.orderRef = orderReferenceObj;\n } else {\n this.OrderslistService.setOrderRefId(orderReferenceObj.orderRefId);\n this.orderRef = orderReferenceObj.orderRefId;\n }\n\n this.orderFeesTotal = 0.00;\n this.orderRemissionTotal = 0.00;\n this.orderTotalPayments = 0.00;\n this.orderPendingPayments = 0.00;\n\n this.orderDetail = this.paymentGroups.filter(x => x.payment_group_reference === this.orderRef);\n this.orderDetail.forEach(orderDetail => {\n if (orderDetail.fees) {\n orderDetail.fees.forEach(fee => {\n this.orderFeesTotal = this.orderFeesTotal + fee.calculated_amount;\n });\n }\n if (orderDetail.remissions) {\n orderDetail.remissions.forEach(remission => {\n this.orderRemissionTotal = this.orderRemissionTotal + remission.hwf_amount;\n });\n if (orderDetail.payments) {\n this.payment = orderDetail.payments[0];\n orderDetail.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n this.orderTotalPayments = this.orderTotalPayments + payment.amount;\n }\n });\n }\n }\n this.orderStatus = orderDetail.service_request_status;\n });\n //this.orderPendingPayments = (this.orderFeesTotal - this.orderRemissionTotal) - this.orderTotalPayments;\n // this.orderRef = orderReferenceObj.orderRefId;\n // if (this.orderPendingPayments <= 0.00) {\n // this.orderStatus = 'Paid';\n // } else if (this.orderFeesTotal > 0 && (this.orderTotalPayments > 0 || this.orderRemissionTotal > 0) && (this.orderTotalPayments < this.orderPendingPayments)) {\n // this.orderStatus = 'Partially paid'\n // } else {\n // this.orderStatus = 'Not paid'\n // }\n\n\n if (this.cpoDetails !== null) {\n this.orderParty = this.cpoDetails['responsibleParty'];\n this.orderCreated = this.cpoDetails['createdTimestamp'];\n this.orderCCDEvent = this.cpoDetails['action'];\n } else {\n this.orderParty = '';\n this.orderCCDEvent = '';\n this.orderCreated = orderReferenceObj.orderCreated;\n }\n this.viewStatus = 'order-full-view';\n }\n\n redirectToOrderFeeSearchPage(event: any, orderef: any) {\n if(orderef.orderAddBtnEnable) {\n event.preventDefault();\n this.paymentLibComponent.bspaymentdcn = null;\n this.paymentLibComponent.paymentGroupReference = orderef.orderRefId;\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.viewName = 'fee-summary';\n }\n }\n\n\n\n\n calculateAmounts(): void {\n let feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00,\n nonOffLinePayment = 0.00;\n\n this.paymentGroups.forEach(paymentGroup => {\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n // new feature Apportionment toggle changes\n if (!this.isTurnOff) {\n if (fee.date_created) {\n let a = fee.amount_due === undefined;\n let b = fee.amount_due <= 0;\n this.clAmountDue = a ? this.clAmountDue + fee.net_amount : b ? this.clAmountDue + 0 : this.clAmountDue + fee.amount_due;\n }\n fee['payment_group_reference'] = paymentGroup['payment_group_reference'];\n this.fees.push(fee);\n } else {\n feesTotal = feesTotal + fee.calculated_amount;\n this.fees.push(fee);\n }\n\n });\n }\n if (this.isTurnOff) {\n this.totalFees = feesTotal;\n }\n\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n // new feature Apportionment toggle changes\n if (!this.isTurnOff) {\n let allocationLen = payment.payment_allocation;\n\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n if (allocationLen.length === 0 || allocationLen.length > 0 && allocationLen[0].allocation_status === 'Allocated') {\n nonOffLinePayment = nonOffLinePayment + payment.amount;\n }\n if (allocationLen.length > 0) {\n this.nonPayments.push(payment);\n }\n }\n if (allocationLen.length === 0) {\n this.payments.push(payment);\n }\n payment.paymentGroupReference = paymentGroup.payment_group_reference\n this.allPayments.push(payment);\n } else {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n this.payments.push(payment);\n }\n payment.paymentGroupReference = paymentGroup.payment_group_reference\n this.allPayments.push(payment);\n }\n });\n }\n this.totalPayments = paymentsTotal;\n // new feature Apportionment toggle changes\n if (!this.isTurnOff) {\n this.totalNonOffPayments = nonOffLinePayment;\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remisison => {\n remissionsTotal = remissionsTotal + remisison.hwf_amount;\n this.remissions.push(remisison);\n });\n }\n this.totalRemissions = remissionsTotal;\n });\n\n }\n\n calculateRefundAmount() {\n if (!this.isTurnOff) {\n let isNewPaymentGroup = false;\n\n this.paymentGroups.forEach((paymentGroup, index) => {\n let grpOutstandingAmount = 0.00,\n feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00,\n fees = [];\n\n if (paymentGroup.fees) {\n // this.isFeeRecordsExist = true;\n paymentGroup.fees.forEach(fee => {\n feesTotal = feesTotal + fee.calculated_amount;\n\n this.isRemissionsMatch = false;\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(rem => {\n if (rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n // if(!fees.find(k => k.code=fee.code))\n // {\n fees.push(fee);\n //}\n }\n });\n }\n if (!this.isRemissionsMatch) {\n fees.push(fee);\n }\n\n if (fee.date_created) {\n isNewPaymentGroup = true;\n } else {\n this.isHistoricGroupAvailable = true;\n this.paymentGroups[index]['old'] = true;\n }\n });\n this.paymentGroups[index].fees = fees;\n }\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n }\n });\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n remissionsTotal = remissionsTotal + remission.hwf_amount;\n });\n }\n grpOutstandingAmount = (feesTotal - remissionsTotal) - paymentsTotal;\n if (grpOutstandingAmount > 0 && isNewPaymentGroup) {\n this.isAnyFeeGroupAvilable = true;\n this.isFeeRecordsExist = true;\n this.paymentRef = paymentGroup.payment_group_reference;\n }\n if (paymentGroup.fees && paymentGroup.fees.length > 0 && grpOutstandingAmount <= 0 && isNewPaymentGroup) {\n this.isAnyFeeGroupAvilable = false;\n }\n });\n if ((!isNewPaymentGroup && this.isHistoricGroupAvailable) || (!isNewPaymentGroup && !this.isHistoricGroupAvailable)) {\n this.isAnyFeeGroupAvilable = false;\n }\n } else {\n let totalRefundAmount = 0,\n isFeeAmountZero = false;\n this.paymentGroups.forEach(paymentGroup => {\n let grpOutstandingAmount = 0.00,\n feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00;\n if (paymentGroup.fees) {\n this.isFeeRecordsExist = true;\n paymentGroup.fees.forEach(fee => {\n feesTotal = feesTotal + fee.calculated_amount;\n if (fee.calculated_amount === 0) {\n isFeeAmountZero = true\n }\n });\n\n }\n\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n }\n });\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n remissionsTotal = remissionsTotal + remission.hwf_amount;\n });\n }\n grpOutstandingAmount = (feesTotal - remissionsTotal) - paymentsTotal;\n if (grpOutstandingAmount < 0) {\n if (totalRefundAmount === 0) {\n totalRefundAmount = grpOutstandingAmount;\n } else {\n totalRefundAmount = (totalRefundAmount + grpOutstandingAmount);\n }\n }\n else if (grpOutstandingAmount > 0 || (grpOutstandingAmount === 0 && isFeeAmountZero)) {\n this.isGrpOutstandingAmtPositive = true;\n }\n });\n return totalRefundAmount * -1;\n }\n }\n\n getGroupOutstandingAmount(paymentGroup: IPaymentGroup): number {\n return this.bulkScaningPaymentService.calculateOutStandingAmount(paymentGroup);\n }\n\n redirectToFeeSearchPage(event: any) {\n event.preventDefault();\n let url = this.isBulkScanEnable ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n url += this.isTurnOff ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n url += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n url += `&caseType=${this.caseType}`\n this.router.navigateByUrl(`/fee-search?selectedOption=${this.selectedOption}&ccdCaseNumber=${this.ccdCaseNumber}${url}`);\n }\n\n addRemission(fee: IFee) {\n if(this.chkForAddRemission(fee.code)) {\n this.feeId = fee;\n this.viewStatus = 'addremission';\n this.paymentViewService.getApportionPaymentDetails(this.payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n this.payment = this.paymentGroup.payments[0];\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error? error.replace(/\"/g,\"\") : \"\"\n );\n }\n }\n\n addRefundForRemission(payment: IPayment, remission: IRemission[],fees:any) {\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n this.paymentGroup.payments = paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj.reference === payment.reference);\n this.payment = this.paymentGroup.payments[0];\n this.remissions = remission;\n this.remissionFeeAmt = fees.filter(data=>data.code === this.remissions['fee_code'])[0].net_amount;\n this.viewStatus = 'addrefundforremission';\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error\n );\n }\n\n redirectToremissionPage(event: any) {\n event.preventDefault();\n this.paymentLibComponent.viewName = 'remission'\n }\n goToServiceRequestPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = false;\n this.paymentLibComponent.SERVICEREQUEST = 'true';\n this.paymentLibComponent.isFromServiceRequestPage = true;\n window.location.reload();\n }\n redirectToReportsPage(event: any) {\n event.preventDefault();\n this.router.navigateByUrl(`/reports?selectedOption=${this.selectedOption}&ccdCaseNumber=${this.ccdCaseNumber}`);\n }\n\n loadFeeSummaryPage(paymentGroup: IPaymentGroup) {\n this.paymentLibComponent.bspaymentdcn = null;\n this.paymentLibComponent.paymentGroupReference = paymentGroup.payment_group_reference;\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.viewName = 'fee-summary';\n }\n\n goToPaymentViewComponent(paymentGroup: any) {\n this.paymentLibComponent.paymentMethod = paymentGroup.paymentMethod;\n this.paymentLibComponent.paymentGroupReference = paymentGroup.paymentGroupReference;\n this.paymentLibComponent.paymentReference = paymentGroup.paymentReference;\n this.paymentLibComponent.viewName = 'payment-view';\n }\n\n goToPayementView(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.goToPaymentViewComponent({ paymentGroupReference, paymentReference, paymentMethod });\n }\n\n selectedUnprocessedFeeEvent(unprocessedRecordId: string) {\n if (unprocessedRecordId) {\n if (this.isTurnOff) {\n this.isAddFeeBtnEnabled = false;\n }\n this.isUnprocessedRecordSelected = true;\n } else {\n if (this.isTurnOff) {\n this.isAddFeeBtnEnabled = true;\n }\n this.isUnprocessedRecordSelected = false;\n }\n }\n\n getUnprocessedFeeCount(unProcessedRecordCount: number) {\n this.unprocessedRecordCount = unProcessedRecordCount;\n }\n\n calculateAmountDue(fee: IFee) {\n\n if (fee.date_created) {\n return fee.amount_due !== undefined ? fee.amount_due : fee.net_amount;\n } else {\n return \"0.00\";\n }\n }\n\n confirmRemoveFee(fee: IFee) {\n this.isRemoveBtnDisabled = false;\n this.feeId = fee;\n this.viewStatus = 'feeRemovalConfirmation';\n }\n\n cancelRemoval() {\n this.viewStatus = 'main';\n }\n\n removeFee(fee: any) {\n this.isRemoveBtnDisabled = true;\n this.paymentViewService.deleteFeeFromPaymentGroup(fee).subscribe(\n (success: any) => {\n window.location.reload();\n },\n (error: any) => {\n this.errorMessage = error;\n this.isRemoveBtnDisabled = false;\n }\n );\n }\n\n isCheckAmountdueExist(amountDue: any) {\n return typeof amountDue === 'undefined';\n }\n\n issueRefund(payment: IPayment) {\n if (payment !== null && payment !== undefined) {\n if(this.chkIssueRefundBtnEnable(payment)) {\n this.viewStatus = 'issuerefund';\n this.payment = payment;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.isRefundRemission = true;\n }\n }\n }\n\n chkForAddRemission(feeCode: string): boolean {\n if (this.chkForPBAPayment() && this.check4AllowedRoles2AccessRefund()) {\n if (this.orderDetail[0]['remissions'].length > 0) {\n for (const remission of this.orderDetail[0]['remissions']) {\n if (remission.fee_code === feeCode) {\n return false;\n }\n }\n }\n return true;\n } else {\n return false;\n }\n }\n\n chkForPBAPayment(): boolean {\n if (this.orderDetail !== null && this.orderDetail !== undefined) {\n this.orderDetail.forEach(orderDetail => {\n if (orderDetail.payments) {\n orderDetail.payments.forEach(payment => {\n if (payment.method.toLocaleLowerCase() === 'payment by account' && this.allowFurtherAccessAfter4Days(payment)) {\n this.isPBA = true;\n }\n });\n }\n });\n if (this.isPBA) {\n return true;\n } else {\n return false;\n };\n }\n }\n\n chkIssueRefundBtnEnable(payment: IPayment): boolean {\n if (payment !== null && payment !== undefined) {\n return payment.issue_refund && payment.refund_enable\n } else {\n return false;\n }\n // if (this.check4AllowedRoles2AccessRefund() && this.allowFurtherAccessAfter4Days(payment) &&\n // payment.method === 'payment by account' && payment.status.toLocaleLowerCase() === 'success') {\n // this.isIssueRefunfBtnEnable = true;\n // }\n // if (this.isIssueRefunfBtnEnable) {\n // return true;\n // } else {\n // return false;\n // };\n }\n\n chkIsRefundRemissionBtnEnable(): boolean {\n if (this.orderDetail !== null && this.orderDetail !== undefined) {\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.orderDetail.forEach(orderDetail => {\n if (orderDetail.payments) {\n orderDetail.payments.forEach(payment => {\n if (payment.method.toLocaleLowerCase() === 'payment by account' && payment.status.toLocaleLowerCase() === 'success' && this.allowFurtherAccessAfter4Days(payment)) {\n this.isRefundRemissionBtnEnable = true;\n }\n });\n }\n });\n if (this.isRefundRemissionBtnEnable) {\n return true;\n } else {\n return false;\n };\n }\n }\n\n check4AllowedRoles2AccessRefund = (): boolean => {\n return this.allowedRolesToAccessRefund.some(role =>\n this.LOGGEDINUSERROLES.indexOf(role) !== -1\n );\n }\n check4AllowedRoles2AccessPBApayment = (): boolean => {\n return this.isEligible4PBAPayment.some(role =>\n this.LOGGEDINUSERROLES.indexOf(role) !== -1\n );\n }\n\n allowFurtherAccessAfter4Days = (payment: IPayment): boolean => {\n if (payment !== null && payment !== undefined) {\n let tmp4DayAgo = new Date();\n tmp4DayAgo.setDate(tmp4DayAgo.getDate() - 4);\n return tmp4DayAgo >= new Date(payment.date_created);\n }\n }\n\n loadPBAAccountPage(orderRef: IPayment) {\n this.paymentLibComponent.pbaPayOrderRef = orderRef;\n this.paymentLibComponent.viewName = 'pba-payment';\n }\n}\n","export class PaymentToPayhubRequest {\n currency = 'GBP';\n description = 'PayBubble payment';\n channel = 'telephony';\n provider = 'pci pal';\n case_type: string;\n\n ccd_case_number: string;\n amount: number;\n\n constructor(ccd_case_number: string, amount: number, caseType: string) {\n this.ccd_case_number = ccd_case_number;\n this.amount = <any>amount.toFixed(2);\n this.case_type= caseType;\n }\n}\n","export class PayhubAntennaRequest {\n currency = 'GBP';\n case_type: string;\n ccd_case_number: string;\n amount: number;\n\n constructor(ccd_case_number: string, amount: number, caseType: string) {\n this.ccd_case_number = ccd_case_number;\n this.amount = <any>amount.toFixed(2);\n this.case_type= caseType;\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { IFee } from '../../interfaces/IFee';\nimport { PaymentToPayhubRequest } from '../../interfaces/PaymentToPayhubRequest';\nimport { PayhubAntennaRequest } from '../../interfaces/PayhubAntennaRequest';\nimport { SafeHtml } from '@angular/platform-browser';\nimport {Router} from '@angular/router';\nimport {Location} from '@angular/common';\nimport { OrderslistService } from '../../services/orderslist.service';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\n\n@Component({\n selector: 'ccpay-fee-summary',\n templateUrl: './fee-summary.component.html',\n styleUrls: ['./fee-summary.component.scss']\n})\n\nexport class FeeSummaryComponent implements OnInit {\n @Input() paymentGroupRef: string;\n @Input() ccdCaseNumber: string;\n @Input() isTurnOff: string;\n @Input() caseType: string;\n\n\n bsPaymentDcnNumber: string;\n paymentGroup: IPaymentGroup;\n errorMessage: string;\n viewStatus = 'main';\n currentFee: IFee;\n totalFee: number;\n payhubHtml: SafeHtml;\n service: string = \"\";\n platForm: string = \"\";\n upPaymentErrorMessage: string;\n selectedOption:string;\n isBackButtonEnable: boolean = true;\n outStandingAmount: number;\n isFeeAmountZero: boolean = false;\n totalAfterRemission: number = 0;\n isConfirmationBtnDisabled: boolean = false;\n isRemoveBtnDisabled: boolean = false;\n isPaymentExist: boolean = false;\n isRemissionsExist: Boolean = false;\n isRemissionsMatch = false;\n isStrategicFixEnable: boolean;\n\n constructor(\n private router: Router,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private location: Location,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private OrderslistService: OrderslistService\n ) {}\n\n ngOnInit() {\n this.viewStatus = 'main';\n this.caseType = this.paymentLibComponent.CASETYPE;\n this.bsPaymentDcnNumber = this.paymentLibComponent.bspaymentdcn;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION.toLocaleLowerCase();\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.OrderslistService.setCaseType(this.paymentLibComponent.CASETYPE);\n\n this.platForm = 'Antenna';\n\n this.paymentViewService.getBSfeature().subscribe(\n features => {\n let result = JSON.parse(features).filter(feature => feature.uid === BS_ENABLE_FLAG);\n this.paymentLibComponent.ISBSENABLE = result[0] ? result[0].enable : false;\n },\n err => {\n this.paymentLibComponent.ISBSENABLE = false;\n }\n );\n if (this.bsPaymentDcnNumber) {\n this.getUnassignedPaymentlist();\n }\n this.getPaymentGroup();\n }\n\n getUnassignedPaymentlist() {\n if (this.selectedOption === 'dcn') {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.paymentLibComponent.DCN_NUMBER).subscribe(\n unassignedPayments => {\n if(unassignedPayments['data'].payments) {\n this.service = unassignedPayments['data'].responsible_service_id;\n } else {\n this.upPaymentErrorMessage = 'error';\n }\n },\n (error: any) => this.upPaymentErrorMessage = error\n );\n } else {\n this.bulkScaningPaymentService.getBSPaymentsByCCD(this.ccdCaseNumber).subscribe(\n unassignedPayments => {\n if(unassignedPayments['data'].payments) {\n this.service = unassignedPayments['data'].responsible_service_id;\n } else {\n this.upPaymentErrorMessage = 'error';\n }\n },\n (error: any) => this.upPaymentErrorMessage = error\n );\n }\n\n }\n\n getRemissionByFeeCode(feeCode: string): IRemission {\n if (this.paymentGroup && this.paymentGroup.remissions && this.paymentGroup.remissions.length > 0) {\n for (const remission of this.paymentGroup.remissions) {\n if (remission.fee_code === feeCode) {\n return remission;\n }\n }\n }\n return null;\n }\n\n addRemission(fee: IFee) {\n this.currentFee = fee;\n this.viewStatus = 'add_remission';\n }\n\n getPaymentGroup() {\n let fees = [];\n this.paymentViewService.getPaymentGroupDetails(this.paymentGroupRef).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n this.isPaymentExist = paymentGroup.payments ? paymentGroup.payments.length > 0 : false;\n this.isRemissionsExist = paymentGroup.remissions ? paymentGroup.remissions.length > 0 : false;\n\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n this.totalAfterRemission = this.totalAfterRemission + fee.net_amount;\n if(fee.calculated_amount === 0) {\n this.isFeeAmountZero = true;\n }\n if(paymentGroup.remissions) {\n this.isRemissionsMatch = false;\n paymentGroup.remissions.forEach(rem => {\n if(rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n fees.push(fee);\n }\n });\n\n if(!this.isRemissionsMatch) {\n fees.push(fee);\n }\n } else {\n fees.push(fee);\n }\n });\n paymentGroup.fees = fees;\n }\n\n this.outStandingAmount = this.bulkScaningPaymentService.calculateOutStandingAmount(paymentGroup);\n },\n (error: any) => this.errorMessage = error.replace(/\"/g,\"\")\n );\n }\n\n confirmRemoveFee(fee: IFee){\n this.isRemoveBtnDisabled = false;\n this.currentFee = fee;\n this.viewStatus = 'feeRemovalConfirmation';\n }\n\n removeFee(fee: any){\n this.isRemoveBtnDisabled = true;\n this.paymentViewService.deleteFeeFromPaymentGroup(fee).subscribe(\n (success: any) => {\n if (this.paymentGroup.fees && this.paymentGroup.fees.length > 1){\n this.totalAfterRemission = 0;\n this.getPaymentGroup();\n this.viewStatus = 'main';\n return;\n }\n this.loadCaseTransactionPage();\n },\n (error: any) => {\n this.errorMessage = error;\n this.isRemoveBtnDisabled = false;\n }\n );\n }\n\n loadCaseTransactionPage() {\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentViewService.getBSfeature().subscribe(\n features => {\n let result = JSON.parse(features).filter(feature => feature.uid === BS_ENABLE_FLAG);\n this.paymentLibComponent.ISBSENABLE = result[0] ? result[0].enable : false;\n },\n err => {\n this.paymentLibComponent.ISBSENABLE = false;\n }\n );\n\n let partUrl = `selectedOption=${this.paymentLibComponent.SELECTED_OPTION}`;\n partUrl +=this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl +=this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl +=this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl +=this.paymentLibComponent.ISSFENABLE ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl +=`&caseType=${this.paymentLibComponent.CASETYPE}`;\n\n let url = `/payment-history/${this.ccdCaseNumber}?view=case-transactions&takePayment=true&${partUrl}`;\n this.router.navigateByUrl(url);\n }\n cancelRemission() {\n this.viewStatus = 'main';\n }\n redirectToFeeSearchPage(event: any, page?: string) {\n event.preventDefault();\n let partUrl =this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl +=this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl +=this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl +=this.paymentLibComponent.ISSFENABLE ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl +=`&caseType=${this.paymentLibComponent.CASETYPE}`;\n\n if(this.viewStatus === 'feeRemovalConfirmation' || this.viewStatus === 'add_remission') {\n this.viewStatus = 'main';\n return;\n }\n let url = `/fee-search?ccdCaseNumber=${this.ccdCaseNumber}&selectedOption=${this.paymentLibComponent.SELECTED_OPTION}&paymentGroupRef=${this.paymentGroupRef}${partUrl}`;\n this.router.navigateByUrl(url);\n }\n takePayment() {\n this.isConfirmationBtnDisabled = true;\n const requestBody = new PaymentToPayhubRequest(this.ccdCaseNumber, this.outStandingAmount, this.caseType),\n antennaReqBody = new PayhubAntennaRequest(this.ccdCaseNumber, this.outStandingAmount, this.caseType);\n\n if(this.platForm === 'Antenna') {\n\n this.paymentViewService.postPaymentAntennaToPayHub(antennaReqBody, this.paymentGroupRef).subscribe(\n response => {\n this.isBackButtonEnable=false;\n window.location.href = '/makePaymentByTelephoneyProvider';\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.router.navigateByUrl('/pci-pal-failure');\n }\n );\n }\n\n }\n\n goToAllocatePage(outStandingAmount: number, isFeeAmountZero: Boolean) {\n if (outStandingAmount > 0 || (outStandingAmount === 0 && isFeeAmountZero)) {\n this.paymentLibComponent.paymentGroupReference = this.paymentGroupRef;\n this.paymentLibComponent.viewName = 'allocate-payments';\n } else {\n this.loadCaseTransactionPage();\n }\n }\n isCheckAmountdueExist(amountDue: any) {\n return typeof amountDue === 'undefined';\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\n\n\n\n@Component({\n selector: 'ccpay-error-banner',\n templateUrl: './error-banner.component.html',\n styleUrls: ['./error-banner.component.scss']\n})\n\nexport class ErrorBannerComponent implements OnInit {\n @Input('errorMessage') errorMessage;\n\n constructor(\n ) {}\n\n ngOnInit() {\n\n }\n}\n","\nexport class UnidentifiedPaymentsRequest {\n payment_allocation_status: any;\n payment_group_reference: string;\n payment_reference: string;\n unidentified_reason: string;\n\n constructor(payment_group_reference: string, payment_reference : string, unidentified_reason: any) {\n this.payment_allocation_status = {\n description: '',\n name: \"Unidentified\"\n };\n this.payment_group_reference = payment_group_reference ;\n this.payment_reference= payment_reference;\n this.unidentified_reason= unidentified_reason;\n\n }\n\n\n\n}\n","import { IBSPayments } from \"./IBSPayments\";\n\nexport class AllocatePaymentRequest {\n amount: Number;\n banked_date: String;\n ccd_case_number: String;\n exception_record: string;\n currency: String;\n document_control_number: String;\n external_provider: String;\n giro_slip_no: String;\n payer_name: String;\n payment_channel: Object;\n payment_status: Object;\n payment_method: String;\n case_type: String;\n payment_allocation_dto?: {\n allocation_reason: String,\n allocation_status: String,\n explanation: String,\n payment_allocation_status: Object,\n payment_group_reference: String,\n payment_reference: String,\n reason: String,\n receiving_office: String,\n unidentified_reason: String,\n user_id: String,\n user_name: String,\n case_type: String\n }\n\n constructor(ccd_case_number : string, unAllocatedPayment: IBSPayments, caseType: string, exceptionRecord: string, allocatedRequest?: any) {\n this.amount = unAllocatedPayment.amount;\n this.banked_date = unAllocatedPayment.date_banked;\n this.ccd_case_number = ccd_case_number;\n this.exception_record = exceptionRecord;\n this.currency= unAllocatedPayment.currency;\n this.document_control_number = unAllocatedPayment.dcn_reference;\n this.external_provider = 'exela';\n this.giro_slip_no = unAllocatedPayment.bgc_reference;\n this.payer_name = unAllocatedPayment.payer_name;\n this.payment_channel = {\n description: '',\n name: 'bulk scan'\n };\n this.payment_status ={\n description: 'bulk scan payment completed',\n name: 'success'\n }\n this.payment_method = unAllocatedPayment.payment_method;\n this.case_type= caseType;\n if(allocatedRequest) {\n this.payment_allocation_dto = allocatedRequest;\n }\n\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport {BulkScaningPaymentService} from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport { UnidentifiedPaymentsRequest } from '../../interfaces/UnidentifiedPaymentsRequest';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\n\n@Component({\n selector: 'app-mark-unidentified-payment',\n templateUrl: './mark-unidentified-payment.component.html',\n styleUrls: ['./mark-unidentified-payment.component.scss']\n})\nexport class MarkUnidentifiedPaymentComponent implements OnInit {\n @Input() caseType: string;\n markPaymentUnidentifiedForm: FormGroup;\n viewStatus: string;\n ccdCaseNumber: string;\n bspaymentdcn: string;\n isInvesticationDetailEmpty: boolean = false;\n investicationDetailHasError: boolean = false;\n investicationDetailMinHasError: boolean = false;\n investicationDetailMaxHasError: boolean = false;\n errorMessage = this.getErrorMessage(false);\n unassignedRecord:IBSPayments;\n siteID: string = null;\n investigationComment: string;\n isConfirmButtondisabled:Boolean = false;\n ccdReference: string = null;\n exceptionReference: string = null;\n isStrategicFixEnable: boolean = true;\n\n constructor(private formBuilder: FormBuilder,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private bulkScaningPaymentService: BulkScaningPaymentService) { }\n\n ngOnInit() {\n this.viewStatus = 'mainForm';\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.bspaymentdcn = this.paymentLibComponent.bspaymentdcn;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.getUnassignedPayment();\n\n this.markPaymentUnidentifiedForm = this.formBuilder.group({\n investicationDetail: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$')\n ]))\n });\n }\n getUnassignedPayment() {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.bspaymentdcn).subscribe(\n unassignedPayments => {\n this.errorMessage = this.getErrorMessage(false);\n this.unassignedRecord = unassignedPayments['data'].payments.filter(payment => {\n return payment && payment.dcn_reference == this.bspaymentdcn;\n })[0];\n this.siteID = unassignedPayments['data'].responsible_service_id;\n const beCcdNumber = unassignedPayments['data'].ccd_reference,\n beExceptionNumber = unassignedPayments['data'].exception_record_reference,\n exceptionReference = beCcdNumber ? beCcdNumber === this.ccdCaseNumber ? null : this.ccdCaseNumber : this.ccdCaseNumber;\n this.ccdReference = beCcdNumber ? beCcdNumber : null;\n this.exceptionReference = beExceptionNumber ? beExceptionNumber : exceptionReference;\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n }\n );\n }\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n saveAndContinue() {\n this.resetForm([false, false, false, false]);\n const investicationField = this.markPaymentUnidentifiedForm.controls.investicationDetail;\n const formerror = investicationField.errors;\n if (this.markPaymentUnidentifiedForm.dirty && this.markPaymentUnidentifiedForm.valid) {\n this.investigationComment = this.markPaymentUnidentifiedForm.controls.investicationDetail.value;\n this.viewStatus = 'unidentifiedContinueConfirm';\n }else {\n if(investicationField.value == '' ) {\n this.resetForm([true, false, false, false]);\n }\n if(investicationField.value != '' && investicationField.invalid ) {\n this.resetForm([false, true, false, false]);\n }\n if(formerror && formerror.minlength && formerror.minlength.actualLength < 3 ) {\n this.resetForm([false, false, true, false]);\n }\n if(formerror && formerror.maxlength && formerror.maxlength.actualLength > 255 ) {\n this.resetForm([false, false, false, true]);\n }\n }\n }\n resetForm(val) {\n this.isInvesticationDetailEmpty = val[0];\n this.investicationDetailHasError = val[1];\n this.investicationDetailMinHasError = val[2];\n this.investicationDetailMaxHasError = val[3];\n }\n confirmPayments() {\n this.isConfirmButtondisabled = true;\n const reason = this.markPaymentUnidentifiedForm.get('investicationDetail').value;\n\n if(!this.isStrategicFixEnable) {\n let allocatedRequest = {\n allocation_status:'Unidentified',\n payment_allocation_status: {\n description: '',\n name: 'Unidentified'\n },\n unidentified_reason: reason,\n user_id: this.caseType,\n }\n const postStrategicBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.caseType, this.exceptionReference, allocatedRequest);\n this.bulkScaningPaymentService.postBSWoPGStrategic(postStrategicBody).subscribe(\n res => {\n this.errorMessage = this.getErrorMessage(false);\n let response = JSON.parse(res);\n if (response.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n });\n } else {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'PROCESSED').subscribe(\n res1 => {\n this.errorMessage = this.getErrorMessage(false);\n const requestBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.siteID, this.exceptionReference)\n this.paymentViewService.postBSPayments(requestBody).subscribe(\n res2 => {\n this.errorMessage = this.getErrorMessage(false);\n const response2 = JSON.parse(res2),\n reqBody = new UnidentifiedPaymentsRequest\n (response2['data'].payment_group_reference, response2['data'].reference, reason);\n if (response2.success) {\n this.paymentViewService.postBSUnidentifiedPayments(reqBody).subscribe(\n res3 => {\n this.errorMessage = this.getErrorMessage(false);\n const response3 = JSON.parse(res3);\n if (response3.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n }\n cancelMarkUnidentifiedPayments(type?:string){\n if(type && type === 'cancel') {\n if(this.markPaymentUnidentifiedForm.get('investicationDetail').value!==\"\"){\n this.viewStatus = 'unidentifiedCancelConfirm';\n } else {\n this.gotoCasetransationPage();\n }\n } else {\n this.viewStatus = 'mainForm';\n }\n }\n\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n getErrorMessage(isErrorExist) {\n return {\n title: \"There is a problem with the service\",\n body: \"Try again later\",\n showError: isErrorExist\n };\n }\n}\n","\nexport class UnsolicitedPaymentsRequest {\n payment_allocation_status: any;\n payment_group_reference: string;\n payment_reference: string;\n receiving_office: string;\n receiving_email_address: string;\n sending_email_address: string;\n unidentified_reason: string;\n constructor(payment_group_reference: string, payment_reference : string, reason: string,responsible_office: string, responsible_person:string,email_id: string) {\n this.payment_allocation_status = {\n description: '',\n name: \"Transferred\"\n };\n this.payment_group_reference = payment_group_reference;\n this.payment_reference= payment_reference;\n this.unidentified_reason= reason;\n this.receiving_office= responsible_office;\n this.receiving_email_address= email_id;\n this.sending_email_address= responsible_person;\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport { UnsolicitedPaymentsRequest } from '../../interfaces/UnsolicitedPaymentsRequest';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\n\n\n@Component({\n selector: 'app-mark-unsolicited-payment',\n templateUrl: './mark-unsolicited-payment.component.html',\n styleUrls: ['./mark-unsolicited-payment.component.scss']\n})\nexport class MarkUnsolicitedPaymentComponent implements OnInit {\n @Input() caseType: string;\n markPaymentUnsolicitedForm: FormGroup;\n viewStatus: string;\n reasonHasError: boolean = false;\n isReasonEmpty: boolean = false;\n reasonMinHasError: boolean = false;\n reasonMaxHasError: boolean = false;\n responsibleOfficeHasError: boolean = false;\n isResponsibleOfficeEmpty: boolean = false;\n errorMessage = this.getErrorMessage(false);\n ccdCaseNumber: string;\n bspaymentdcn: string;\n unassignedRecord: IBSPayments;\n siteID: string = null;\n reason: string;\n responsiblePerson: string;\n responsibleOffice: string;\n emailId: string;\n isConfirmButtondisabled: Boolean = false;\n isContinueButtondisabled: Boolean = false;\n ccdReference: string = null;\n exceptionReference: string = null;\n selectedSiteId: string;\n selectedSiteName: string;\n isStrategicFixEnable: boolean = true;\n siteIDList;\n\n constructor(private formBuilder: FormBuilder,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private bulkScaningPaymentService: BulkScaningPaymentService) { }\n\n ngOnInit() {\n this.resetForm([false,false,false,false,false,false], 'all');\n this.viewStatus = 'mainForm';\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.bspaymentdcn = this.paymentLibComponent.bspaymentdcn;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.getUnassignedPayment();\n\n this.paymentViewService.getSiteID().subscribe(\n siteids => {\n this.isContinueButtondisabled = false;\n this.errorMessage = this.getErrorMessage(false);\n this.siteIDList = JSON.parse(siteids);\n },\n err => {\n window.scrollTo(0, 0);\n this.isContinueButtondisabled = true;\n this.errorMessage = this.getErrorMessage(true);\n }\n );\n \n this.markPaymentUnsolicitedForm = this.formBuilder.group({\n reason: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$')\n ])),\n responsibleOffice: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([a-zA-Z0-9\\\\s\\\\n,\\\\.-:]*)$')\n ])),\n responsiblePerson: new FormControl(''),\n emailId: new FormControl('')\n });\n }\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n confirmPayments() {\n this.isConfirmButtondisabled = true;\n const controls = this.markPaymentUnsolicitedForm.controls;\n if(!this.isStrategicFixEnable) {\n let allocatedRequest = {\n allocation_status:'Transferred',\n payment_allocation_status: {\n description: '',\n name: 'Transferred'\n },\n unidentified_reason: controls.reason.value,\n receiving_office: this.selectedSiteId,\n user_id: this.caseType,\n }\n const postStrategicBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.caseType, this.exceptionReference, allocatedRequest);\n this.bulkScaningPaymentService.postBSWoPGStrategic(postStrategicBody).subscribe(\n res => {\n this.errorMessage = this.getErrorMessage(false);\n let response = JSON.parse(res);\n if (response.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n });\n } else {\n // controls.responsibleOffice.setValue('P219');\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'PROCESSED').subscribe(\n res1 => {\n this.errorMessage = this.getErrorMessage(false);\n const response1 = JSON.parse(res1),\n requestBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.siteID, this.exceptionReference)\n this.paymentViewService.postBSPayments(requestBody).subscribe(\n res2 => {\n this.errorMessage = this.getErrorMessage(false);\n const response2 = JSON.parse(res2),\n reqBody = new UnsolicitedPaymentsRequest\n (response2['data'].payment_group_reference, response2['data'].reference, controls.reason.value, this.selectedSiteId, controls.responsiblePerson.value, controls.emailId.value);\n if (response2.success) {\n this.paymentViewService.postBSUnsolicitedPayments(reqBody).subscribe(\n res3 => {\n this.errorMessage = this.getErrorMessage(false);\n const response3 = JSON.parse(res3);\n if (response3.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n }\n saveAndContinue() {\n this.resetForm([false,false,false,false,false,false], 'all');\n const formerror = this.markPaymentUnsolicitedForm.controls.reason.errors;\n const reasonField = this.markPaymentUnsolicitedForm.controls.reason;\n //const officeIdField = this.selectedSiteId;\n const officeIdField = this.markPaymentUnsolicitedForm.controls.responsibleOffice;\n if (this.markPaymentUnsolicitedForm.dirty && this.markPaymentUnsolicitedForm.valid) {\n const controls = this.markPaymentUnsolicitedForm.controls;\n this.emailId = controls.emailId.value;\n this.responsibleOffice = officeIdField.value;\n this.responsiblePerson = controls.responsiblePerson.value;\n this.reason = controls.reason.value;\n this.viewStatus = 'unsolicitedContinueConfirm';\n }else {\n if( reasonField.value == '' ) {\n this.resetForm([true,false,false,false,false,false], 'reason');\n }\n if(reasonField.value != '' && this.markPaymentUnsolicitedForm.controls.reason.invalid ) {\n this.resetForm([false,true,false,false,false,false], 'reason');\n }\n if(formerror && formerror.minlength && formerror.minlength.actualLength < 3 ) {\n this.resetForm([false,false,true,false,false,false], 'reason');\n }\n if(formerror && formerror.maxlength && formerror.maxlength.actualLength > 255 ) {\n this.resetForm([false,false,false,true,false,false], 'reason');\n }\n if(officeIdField.value == '') {\n this.resetForm([false,false,false,false,true,false], 'responsibleOffice');\n }\n if(officeIdField.value != '' && officeIdField.invalid) {\n this.resetForm([false,false,false,false,false,true],'responsibleOffice');\n }\n }\n }\n resetForm(val, field) {\n if(field==='reason' || field==='all') {\n this.isReasonEmpty = val[0];\n this.reasonHasError = val[1];\n this.reasonMinHasError = val[2];\n this.reasonMaxHasError = val[3];\n }\n if(field==='responsibleOffice' || field==='all') {\n this.isResponsibleOfficeEmpty = val[4];\n this.responsibleOfficeHasError = val[5];\n }\n }\n\ncancelMarkUnsolicitedPayments(type?:string){\n if(type && type === 'cancel') {\n if(this.checkingFormValue()){\n this.viewStatus = 'unsolicitedCancelConfirm';\n } else {\n this.gotoCasetransationPage();\n }\n } else {\n this.markPaymentUnsolicitedForm.controls.responsibleOffice.setValue('');\n this.viewStatus = 'mainForm';\n }\n }\n checkingFormValue(){\n const formFields = this.markPaymentUnsolicitedForm.value;\n let valueExists = false;\n\n for (var field in formFields) {\n if (formFields.hasOwnProperty(field) && formFields[field] !==\"\") {\n valueExists = true;\n break;\n }\n }\n return valueExists;\n }\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n getUnassignedPayment() {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.bspaymentdcn).subscribe(\n unassignedPayments => {\n \n this.unassignedRecord = unassignedPayments['data'].payments.filter(payment => {\n return payment && payment.dcn_reference == this.bspaymentdcn;\n })[0];\n this.siteID = unassignedPayments['data'].responsible_service_id;\n const beCcdNumber = unassignedPayments['data'].ccd_reference,\n beExceptionNumber = unassignedPayments['data'].exception_record_reference,\n exceptionReference = beCcdNumber ? beCcdNumber === this.ccdCaseNumber ? null : this.ccdCaseNumber : this.ccdCaseNumber;\n this.ccdReference = beCcdNumber ? beCcdNumber : null;\n this.exceptionReference = beExceptionNumber ? beExceptionNumber : exceptionReference;\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n }\n );\n }\n\n getErrorMessage(isErrorExist) {\n return {\n title: \"Something went wrong.\",\n body: \"Please try again later.\",\n showError: isErrorExist\n };\n }\n\n selectchange(args){ \n this.selectedSiteId = args.target.value; \n this.selectedSiteName = args.target.options[args.target.selectedIndex].text; \n } \n\n}\n","import { Component, OnInit, Output,Input, EventEmitter } from '@angular/core';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport {Router} from '@angular/router';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { OrderslistService } from '../../services/orderslist.service';\n\n@Component({\n selector: 'ccpay-app-unprocessed-payments',\n templateUrl: './unprocessed-payments.component.html',\n styleUrls: ['./unprocessed-payments.component.scss']\n})\nexport class UnprocessedPaymentsComponent implements OnInit {\n\n @Input('FEE_RECORDS_EXISTS') FEE_RECORDS_EXISTS: boolean;\n @Input('PAYMENTREF') PAYMENTREF: string;\n @Input('ISTURNOFF') ISTURNOFF: boolean;\n @Input('IS_BUTTON_ENABLE') IS_BUTTON_ENABLE: boolean;\n @Input('IS_OS_AMT_AVAILABLE') IS_OS_AMT_AVAILABLE: boolean;\n @Input('ISSFENABLE') ISSFENABLE: boolean;\n @Input('PAYMENTSLENGTH') PAYMENTSLENGTH:Number;\n @Input('LEVEL')LEVEL:Number;\n\n @Output() selectedUnprocessedFeeEvent: EventEmitter<string> = new EventEmitter();\n @Output() getUnprocessedFeeCount: EventEmitter<string> = new EventEmitter();\n\n viewStatus = 'main';\n unassignedRecordList: IBSPayments;\n upPaymentErrorMessage: string = null;\n ccdCaseNumber: string;\n recordId: string = null;\n isRecordExist: boolean = false;\n dcnNumber: string = null;\n selectedOption: string;\n isUnprocessedRecordSelected: boolean = true;\n isAllocateToExistingFeebtnEnabled: boolean = false;\n isMarkAsUnidentifiedbtnEnabled: boolean = false;\n isAllocatedToNewFeebtnEnabled: boolean = false;\n isExceptionCase: boolean = false;\n serviceId: string = null;\n isBulkScanEnable;\n isTurnOff: boolean = true;\n isStFixEnable;\n unassignedRecordSelectedList: IBSPayments;\n unassignedRecordListLength: number = 0;\n showContent: boolean;\n\n constructor(private router: Router,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private paymentLibComponent: PaymentLibComponent,\n private paymentViewService: PaymentViewService,\n private OrderslistService: OrderslistService\n ) { }\n\n ngOnInit() {\n // Todo ...\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION.toLocaleLowerCase();\n this.dcnNumber = this.paymentLibComponent.DCN_NUMBER;\n this.isBulkScanEnable = this.paymentLibComponent.ISBSENABLE;\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.isStFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.OrderslistService.getFeeExists().subscribe( (data) => this.FEE_RECORDS_EXISTS = data);\n this.getUnassignedPaymentlist();\n\n }\n\n getUnassignedPaymentlist() {\n if (this.selectedOption === 'dcn') {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.dcnNumber).subscribe(\n unassignedPayments => {\n // unassignedPayments['data'].map(data => data.expandable=false);\n if(unassignedPayments['data'] && unassignedPayments['data'].payments) {\n this.setValuesForUnassignedRecord(unassignedPayments['data']);\n } else if(unassignedPayments['payments']) {\n this.setValuesForUnassignedRecord(unassignedPayments);\n } else {\n this.upPaymentErrorMessage = 'error';\n this.getUnprocessedFeeCount.emit('0');\n }\n },\n (error: any) => {\n this.upPaymentErrorMessage = error;\n this.getUnprocessedFeeCount.emit('0');\n }\n );\n } else {\n this.bulkScaningPaymentService.getBSPaymentsByCCD(this.ccdCaseNumber).subscribe(\n unassignedPayments => {\n // unassignedPayments['data'].map(data => data.expandable=false);\n if(unassignedPayments['data'] && unassignedPayments['data'].payments) {\n this.setValuesForUnassignedRecord(unassignedPayments['data']);\n } else if(unassignedPayments['payments']) {\n this.setValuesForUnassignedRecord(unassignedPayments);\n } else {\n this.upPaymentErrorMessage = 'error';\n this.getUnprocessedFeeCount.emit('0');\n }\n },\n (error: any) => {\n this.upPaymentErrorMessage = error;\n this.getUnprocessedFeeCount.emit('0');\n }\n );\n }\n\n }\n\n setValuesForUnassignedRecord(unassignedPayments) {\n\n this.unassignedRecordList = unassignedPayments.payments;\n if(this.unassignedRecordList){\n this.unassignedRecordListLength = unassignedPayments.payments.length\n }\n this.serviceId = unassignedPayments.responsible_service_id;\n if (unassignedPayments['ccd_reference'] === undefined) {\n this.isExceptionCase = true;\n }\n // this.isRecordExist = this.unassignedRecordList.length === 0;\n this.getUnprocessedFeeCount.emit(<any>this.unassignedRecordList.length);\n this.unprocessedPaymentSelectEvent(this.unassignedRecordList);\n }\n\n formatUnassignedRecordId(ID: Number) {\n return `unassignrecord-${ID}`;\n }\n\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n\n redirectToFeeSearchPage(event: any, dcn_reference:any) {\n event.preventDefault();\n this.recordId = dcn_reference;\n let url = this.isBulkScanEnable ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n url += this.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n url += this.isStFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n url +=`&caseType=${this.paymentLibComponent.CASETYPE}`;\n\n this.router.navigateByUrl(`/fee-search?selectedOption=${this.selectedOption}&ccdCaseNumber=${this.ccdCaseNumber}&dcn=${this.recordId}${url}`);\n }\n\n loadUnsolicitedPage(viewName: string, dcn_reference:any) {\n this.recordId = dcn_reference;\n this.paymentLibComponent.bspaymentdcn = this.recordId;\n this.paymentLibComponent.viewName = viewName;\n }\n\n unprocessedPaymentSelectEvent(selectedRecordReference: any) {\n this.isUnprocessedRecordSelected = true;\n this.validateButtons();\n this.selectedUnprocessedFeeEvent.emit(selectedRecordReference);\n }\n\n resetButtons() {\n this.isUnprocessedRecordSelected = false;\n this.isAllocateToExistingFeebtnEnabled = false;\n this.isMarkAsUnidentifiedbtnEnabled = false;\n this.isAllocatedToNewFeebtnEnabled = false;\n }\n\n goToAllocatePage(dcn_reference:any) {\n this.paymentLibComponent.bspaymentdcn = dcn_reference;\n this.paymentLibComponent.unProcessedPaymentServiceId = this.serviceId\n this.paymentLibComponent.isTurnOff = this.ISTURNOFF;\n this.paymentLibComponent.ISSFENABLE = this.isStFixEnable;\n\n if(this.ISTURNOFF) {\n this.paymentLibComponent.paymentGroupReference = this.PAYMENTREF;\n this.paymentLibComponent.viewName = 'fee-summary';\n }else {\n this.paymentLibComponent.paymentGroupReference = null;\n this.paymentLibComponent.viewName = 'allocate-payments';\n }\n\n }\n\n validateButtons() {\n setTimeout(() => {\n if ( this.isUnprocessedRecordSelected && this.isExceptionCase) {\n this.isMarkAsUnidentifiedbtnEnabled = true;\n } else if ( this.isUnprocessedRecordSelected && !this.isExceptionCase && !this.FEE_RECORDS_EXISTS) {\n this.isAllocateToExistingFeebtnEnabled = false;\n this.isAllocatedToNewFeebtnEnabled = true;\n } else if( this.isUnprocessedRecordSelected && !this.isExceptionCase && this.FEE_RECORDS_EXISTS) {\n if(!this.ISTURNOFF) {\n this.isAllocateToExistingFeebtnEnabled = true;\n this.isAllocatedToNewFeebtnEnabled = false;\n } else {\n this.isAllocateToExistingFeebtnEnabled = this.IS_OS_AMT_AVAILABLE;\n this.isAllocatedToNewFeebtnEnabled = true;\n }\n }\n },4000);\n }\n\n unprocessedPaymentUnSelectEvent(event: any) {\n event.preventDefault();\n this.recordId = null;\n this.isUnprocessedRecordSelected = false;\n this.isAllocateToExistingFeebtnEnabled = false;\n this.isAllocatedToNewFeebtnEnabled = false;\n this.isMarkAsUnidentifiedbtnEnabled = false;\n //this.validateButtons();\n this.selectedUnprocessedFeeEvent.emit('');\n }\n\n showDetailRow(event: any,obj: any, i: any) {\n event.preventDefault();\n\n this.unassignedRecordSelectedList = obj;\n\n }\n}\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport {IPayment} from '../../interfaces/IPayment';\nimport {Router} from '@angular/router';\n\n@Component({\n selector: 'ccpay-app-processed-payments',\n templateUrl: './processed-payments.component.html',\n styleUrls: ['./processed-payments.component.scss']\n})\nexport class ProcessedPaymentsComponent implements OnInit {\n\n @Input('NONPAYMENTS') NONPAYMENTS: IPayment[];\n @Output() goToPaymentViewComponent: EventEmitter<any> = new EventEmitter();\n\n constructor(\n private router: Router,\n private bulkScaningPaymentService: BulkScaningPaymentService\n ) { }\n ngOnInit() {\n }\n\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n redirectToPaymentViewPage(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.goToPaymentViewComponent.emit({paymentGroupReference, paymentReference, paymentMethod});\n }\n}\n","\nexport class IAllocationPaymentsRequest {\n payment_allocation_status: any;\n payment_group_reference: string;\n payment_reference: string;\n reason: string;\n explanation: string;\n user_name: string;\n constructor(payment_group_reference: string, payment_reference : string, reason? : string, explanation? : string, userName? : string) {\n this.payment_allocation_status = {\n description: '',\n name: \"Allocated\"\n };\n this.payment_group_reference = payment_group_reference;\n this.payment_reference= payment_reference;\n this.reason = reason ? reason : null;\n this.explanation = explanation ? explanation : null;\n this.user_name = userName ? userName : null;\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport {CaseTransactionsService} from '../../services/case-transactions/case-transactions.service'; \nimport {BulkScaningPaymentService} from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport {IBSPayments} from '../../interfaces/IBSPayments';\nimport {AllocatePaymentRequest} from '../../interfaces/AllocatePaymentRequest';\nimport {IAllocationPaymentsRequest} from '../../interfaces/IAllocationPaymentsRequest';\nimport { IOrderReferenceFee } from '../../interfaces/IOrderReferenceFee';\nimport { OrderslistService } from '../../services/orderslist.service';\n\n\n\n@Component({\n selector: 'app-allocate-payments',\n templateUrl: './allocate-payments.component.html',\n styleUrls: ['./allocate-payments.component.scss']\n})\nexport class AllocatePaymentsComponent implements OnInit {\n @Input() isTurnOff: boolean;\n @Input() caseType: string;\n\n overUnderPaymentForm: FormGroup;\n viewStatus: string;\n ccdCaseNumber: string;\n bspaymentdcn: string;\n recordId:string;\n feedbackUrlLabel:string;\n unAllocatedPayment: IBSPayments = {\n amount: 0\n };\n siteID: string = null;\n errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n paymentGroup: IPaymentGroup;\n paymentGroups: IPaymentGroup[] = [];\t\n remainingAmount: number;\n isRemainingAmountGtZero: boolean;\n isMoreDetailsBoxHide: boolean = true;\n isRemainingAmountLtZero: boolean;\n afterFeeAllocateOutstanding: number;\n amountForAllocation: number;\n isConfirmButtondisabled: boolean = false;\n isContinueButtondisabled: boolean = true;\n otherPaymentExplanation: string = null;\n selectedOption: string = null;\n isFeeAmountZero: boolean = false;\t\n\n paymentReasonHasError: boolean = false;\n paymentExplanationHasError: boolean = false;\n isPaymentDetailsEmpty: boolean = false;\n isPaymentDetailsInvalid: boolean = false;\n paymentDetailsMinHasError: boolean = false;\n paymentDetailsMaxHasError: boolean = false;\n isUserNameEmpty: boolean = false;\n isUserNameInvalid: boolean = false;\n ccdReference: string = null;\n exceptionReference: string = null;\n paymentReason: string = null;\n paymentExplanation: string = null;\n userName: string = null;\n paymentSectionLabel: any;\n paymentRef: string = null;\n isStrategicFixEnable: boolean = true;\n orderLevelFees: IOrderReferenceFee[] = [];\n cookieUserName: string[] = [];\n enCookieUserName: any;\n userNameField: string = null;\n\n reasonList: { [key: string]: { [key: string]: string } }= {\n overPayment: {\n hwfReward: 'Help with Fees (HWF) awarded. Please include the HWF reference number in the explanatory note',\n wrongFee: 'Incorrect payment received',\n notIssueCase: 'Unable to issue case',\n otherDeduction: 'Other'\n },\n shortFall: {\n helpWithFee: 'Help with Fees (HWF) application declined',\n wrongFee: 'Incorrect payment received',\n other: 'Other'\n }\n }\n explanationList = {\n overPayment: {\n referRefund: 'Details in case notes. Refund due',\n noRefund: 'Details in case notes. No refund due',\n noCase: 'No case created. Refund due',\n other: 'Other'\n },\n shortFall: {\n holdCase: 'I have put a stop on the case and contacted the applicant requesting the balance of payment',\n heldCase: 'I have put a stop on the case. The applicant needs to be contacted to request the balance of payment',\n other: 'Other'\n }\n }\n\n refund = {\n reason: {\n duplicate: 'Duplicate payment',\n humanerror: 'Human error',\n caseWithdrawn: 'Case withdrawn',\n other: 'Other'\n }\n }\n\n\n constructor(\n private errorHandlerService: ErrorHandlerService,\n private caseTransactionsService: CaseTransactionsService,\n private formBuilder: FormBuilder,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private OrderslistService: OrderslistService) { }\n\n ngOnInit() {\n this.viewStatus = 'mainForm';\n if (this.paymentLibComponent.paymentGroupReference !== null) {\n this.viewStatus = 'allocatePaymentConfirmation';\n }\n \n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.bspaymentdcn = this.paymentLibComponent.bspaymentdcn;\n this.paymentRef = this.paymentLibComponent.paymentGroupReference;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.isTurnOff = this.paymentLibComponent.isTurnOff;\n this.overUnderPaymentForm = this.formBuilder.group({\n moreDetails: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$')\n ])),\n userName: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([a-zA-Z0-9\\\\s]*)$')\n ])),\n });\n this.OrderslistService.getOrdersList().subscribe( (data) =>\n this.orderLevelFees = data.filter(data => data.orderStatus !== 'Paid'));\n this.OrderslistService.getCaseType().subscribe( (data) => this.caseType = data);\n this.getUnassignedPayment();\n }\n getGroupOutstandingAmount(paymentGroup: IPaymentGroup): number {\n return this.bulkScaningPaymentService.calculateOutStandingAmount(paymentGroup);\n }\n\n getPaymentGroupDetails(){\n\n if(!this.isTurnOff){\n this.paymentViewService.getPaymentGroupDetails(this.paymentRef).subscribe(\n paymentGroup => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.paymentGroup = paymentGroup;\n this.saveAndContinue();\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n );\n }else {\n this.caseTransactionsService.getPaymentGroups(this.ccdCaseNumber).subscribe(\n paymentGroups => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.paymentGroups = paymentGroups['payment_groups'].filter(paymentGroup => {\n paymentGroup.fees.forEach(fee => {\n if(fee.calculated_amount === 0) {\n this.isFeeAmountZero = true\n }\n });\n let fstCon = this.getGroupOutstandingAmount(<IPaymentGroup>paymentGroup),\n scndCn = fstCon > 0 || (fstCon == 0 && this.isFeeAmountZero) && paymentGroup.payment_group_reference === this.paymentRef;\n return this.paymentRef ? scndCn : fstCon > 0 || (fstCon == 0 && this.isFeeAmountZero);\n });\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n );\n }\n\n }\n\n selectedPaymentGroup(paymentGroup: IPaymentGroup) {\t\n this.isContinueButtondisabled = false;\t\n this.paymentGroup = paymentGroup;\t\n }\t\n\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n\n gotoSummaryPage(event: any) { \n event.preventDefault();\n this.paymentLibComponent.viewName = 'fee-summary';\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n\n cancelAllocatePayment(event: any){\n event.preventDefault();\n this.resetForm([false, false, false, false, false, false, false, false], 'all');\n if(!this.isTurnOff){\n this.paymentLibComponent.viewName = 'fee-summary';\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n } else {\n this.viewStatus = 'mainForm';\t\n }\n }\n confirmAllocatePayement(){\n this.enCookieUserName = document.cookie.split(\";\").find(row => row.includes(\"user-info\")).split(\"=\")[1].split(\";\");\n this.cookieUserName = JSON.parse(decodeURIComponent(this.enCookieUserName));\n \n const fullName = this.cookieUserName['forename'] + ' ' + this.cookieUserName['surname'];\n\n const paymentDetailsField = this.overUnderPaymentForm.controls.moreDetails,\n paymentFormError = this.overUnderPaymentForm.controls.moreDetails.errors,\n userNameField = fullName,\n isEmptyCondtion = this.paymentReason && this.paymentExplanation,\n isOtherOptionSelected = this.paymentExplanation === 'Other';\n\n this.resetForm([false, false, false, false, false, false, false, false], 'all');\n if ( (!this.isRemainingAmountGtZero && !this.isRemainingAmountLtZero) || isEmptyCondtion && (!isOtherOptionSelected && userNameField.length > 0 || isOtherOptionSelected && userNameField.length > 0 && paymentDetailsField.valid)) {\n this.isConfirmButtondisabled = true;\n this.otherPaymentExplanation = this.paymentExplanation === 'Other' ? paymentDetailsField.value : this.paymentExplanation;\n this.userName = userNameField;\n this.finalServiceCall();\n }else {\n if(!this.paymentReason) {\n this.resetForm([true, false, false, false, false, false, false, false], 'reason');\n }\n if(!this.paymentExplanation) {\n this.resetForm([false, true, false, false, false, false, false, false], 'explanation');\n }\n if(this.paymentExplanation && isOtherOptionSelected) {\n if(paymentDetailsField.value == '' ) {\n this.resetForm([false, false, true, false, false, false, false, false], 'other');\n }\n if(paymentDetailsField.value != '' && paymentDetailsField.invalid ) {\n this.resetForm([false, false, false, true, false, false, false, false], 'other');\n }\n if(paymentFormError && paymentFormError.minlength && paymentFormError.minlength.actualLength < 3 ) {\n this.resetForm([false, false, false, false, true, false, false, false], 'other');\n }\n if(paymentFormError && paymentFormError.maxlength && paymentFormError.maxlength.actualLength > 255 ) {\n this.resetForm([false, false, false, false, false, true, false, false], 'other');\n }\n }\n if(userNameField.length === 0) {\n this.resetForm([false, false, false, false, false, false, true, false], 'username');\n }\n }\n }\n resetForm(vals, field) {\n if(field==='reason' || field==='all') {\n this.paymentReasonHasError = vals[0];\n }\n if(field==='explanation' || field==='all') {\n this.paymentExplanationHasError = vals[1];\n }\n if(field==='other' || field==='all') {\n this.isPaymentDetailsEmpty = vals[2];\n this.isPaymentDetailsInvalid = vals[3];\n this.paymentDetailsMinHasError = vals[4];\n this.paymentDetailsMaxHasError = vals[5];\n }\n if(field==='username' || field==='all') {\n this.isUserNameEmpty = vals[6];\n this.isUserNameInvalid = vals[7];\n }\n }\n finalServiceCall() {\n if(!this.isStrategicFixEnable) {\n let allocatedRequest = {\n reason: this.paymentReason,\n allocation_status:'Allocated',\n explanation: this.otherPaymentExplanation,\n payment_allocation_status: {\n description: '',\n name: 'Allocated'\n },\n payment_group_reference: this.paymentGroup.payment_group_reference,\n case_type: this.caseType,\n user_name: this.userName\n }\n const postStrategicBody = new AllocatePaymentRequest\n (this.ccdReference, this.unAllocatedPayment, this.caseType, this.exceptionReference, allocatedRequest);\n this.bulkScaningPaymentService.postBSPaymentStrategic(postStrategicBody , this.paymentGroup.payment_group_reference).subscribe(\n res => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response = JSON.parse(res);\n if (response.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n });\n\n } else {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unAllocatedPayment.dcn_reference, 'PROCESSED').subscribe(\n res1 => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response1 = JSON.parse(res1);\n if (response1.success) {\n const requestBody = new AllocatePaymentRequest\n (this.ccdReference, this.unAllocatedPayment, this.siteID, this.exceptionReference);\n this.bulkScaningPaymentService.postBSAllocatePayment(requestBody, this.paymentGroup.payment_group_reference).subscribe(\n res2 => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response2 = JSON.parse(res2);\n const reqBody = new IAllocationPaymentsRequest\n (response2['data'].payment_group_reference, response2['data'].reference, this.paymentReason, this.otherPaymentExplanation, this.userName);\n if (response2.success) {\n this.paymentViewService.postBSAllocationPayments(reqBody).subscribe(\n \n res3 => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response3 = JSON.parse(res3);\n if (response3.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unAllocatedPayment.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unAllocatedPayment.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n }\n ); \n }\n }\n\n saveAndContinue(){\n if(this.paymentGroup) {\n this.isMoreDetailsBoxHide = true;\n this.overUnderPaymentForm.get('moreDetails').reset();\n this.overUnderPaymentForm.get('moreDetails').setValue('');\n this.overUnderPaymentForm.get('userName').reset();\n this.overUnderPaymentForm.get('userName').setValue('');\n this.paymentReason = '';\n this.paymentExplanation = '';\n let GroupOutstandingAmount = this.getGroupOutstandingAmount(this.paymentGroup);\n const remainingToBeAssigned = this.unAllocatedPayment.amount - GroupOutstandingAmount;\n this.isRemainingAmountGtZero = remainingToBeAssigned > 0;\n this.isRemainingAmountLtZero = remainingToBeAssigned < 0;\n this.paymentSectionLabel = this.isRemainingAmountGtZero ? { \n title: 'There is an Over payment of',\n reason: 'Provide a reason. This will be used in the Refund process.',\n }: this.isRemainingAmountLtZero ? { \n title: 'There is an Under payment of',\n reason: 'Provide a reason',\n }: { \n title:'Amount left to be allocated',\n reason:'',\n };\n this.feedbackUrlLabel = this.isRemainingAmountGtZero ? 'CONFIRMALLOCATION_SURPLUS' : this.isRemainingAmountLtZero ? 'CONFIRMALLOCATION_SHORTFALL' : 'CONFIRMALLOCATION';\n this.remainingAmount = this.isRemainingAmountGtZero ? remainingToBeAssigned : this.isRemainingAmountLtZero ? remainingToBeAssigned * -1 : 0;\n this.afterFeeAllocateOutstanding = remainingToBeAssigned >= 0 ? 0 : (remainingToBeAssigned * -1);\n this.amountForAllocation = GroupOutstandingAmount >= this.unAllocatedPayment.amount ? this.unAllocatedPayment.amount : GroupOutstandingAmount;\n if(this.isTurnOff){\n this.viewStatus = 'allocatePaymentConfirmation';\t\n }\n }\n }\n getUnassignedPayment() {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.bspaymentdcn).subscribe(\n unassignedPayments => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.unAllocatedPayment = unassignedPayments['data'].payments.filter(payment => {\n return payment && payment.dcn_reference == this.bspaymentdcn;\n })[0];\n this.siteID = unassignedPayments['data'].responsible_service_id;\n const beCcdNumber = unassignedPayments['data'].ccd_reference,\n beExceptionNumber = unassignedPayments['data'].exception_record_reference,\n exceptionReference = beCcdNumber ? beCcdNumber === this.ccdCaseNumber ? null : this.ccdCaseNumber : this.ccdCaseNumber;\n this.ccdReference = beCcdNumber ? beCcdNumber : null;\n this.exceptionReference = beExceptionNumber ? beExceptionNumber : exceptionReference;\n this.getPaymentGroupDetails();\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n );\n }\n selectRadioButton(key, type) {\n this.isMoreDetailsBoxHide = true;\n if( type === 'explanation' && key === 'other' ){\n this.isPaymentDetailsEmpty = false;\n this.isPaymentDetailsInvalid = false;\n this.paymentDetailsMinHasError = false;\n this.paymentDetailsMaxHasError = false;\n this.isMoreDetailsBoxHide = false;\n }\n }\n OrderListSelectEvent(orderef: any){\n this.isContinueButtondisabled = false;\n this.recordId= orderef;\n }\n\n redirectToOrderFeeSearchPage() {\n // this.paymentLibComponent.bspaymentdcn = null;\n this.paymentLibComponent.paymentGroupReference = this.recordId;\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.viewName = 'fee-summary';\n}\n}\n","import { IFee } from './IFee';\n\nexport class AddRemissionRequest {\n beneficiary_name: string;\n ccd_case_number: string;\n fee: IFee;\n hwf_amount: number;\n hwf_reference: string;\n payment_group_reference: string;\n case_type: string;\n\n constructor(ccd_case_number: string, fee: IFee, hwf_amount: number, hwf_reference: string, caseType: string) {\n this.ccd_case_number = ccd_case_number;\n this.fee = fee;\n this.hwf_amount = hwf_amount;\n this.hwf_reference = hwf_reference;\n this.case_type = caseType;\n }\n}\n","export class AddRetroRemissionRequest {\n hwf_amount: number;\n hwf_reference: string;\n\n constructor(hwf_amount: number, hwf_reference: string) {\n this.hwf_amount = hwf_amount;\n this.hwf_reference = hwf_reference;\n }\n}\n","import { IRefundContactDetails } from './IRefundContactDetails';\n\nexport class PostIssueRefundRetroRemission {\n remissionReference: string;\n contact_details: IRefundContactDetails;\n\n constructor(remissionReference : string, contactDeatils: any) {\n this.remissionReference= remissionReference;\n this.contact_details = contactDeatils;\n } \n}","import { Component, OnInit, Input, Output, EventEmitter} from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl, RequiredValidator, FormArray } from '@angular/forms';\nimport { IFee } from '../../interfaces/IFee';\nimport {Router} from '@angular/router';\nimport { AddRemissionRequest } from '../../interfaces/AddRemissionRequest';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\n\nimport { IPayment } from '../../interfaces/IPayment';\nimport { RefundsService } from '../../services/refunds/refunds.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { IRefundReasons } from '../../interfaces/IRefundReasons';\nimport { AddRetroRemissionRequest } from '../../interfaces/AddRetroRemissionRequest';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\nimport { PostIssueRefundRetroRemission } from '../../interfaces/PostIssueRefundRetroRemission';\nimport {ChangeDetectorRef} from '@angular/core';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\nconst resolvedPromise = Promise.resolve(null);\n\n@Component({\n selector: 'ccpay-add-remission',\n templateUrl: './add-remission.component.html',\n styleUrls: ['./add-remission.component.scss']\n})\nexport class AddRemissionComponent implements OnInit {\n @Input() fee: IFee;\n @Input() fees: any [];\n @Input() payment: IPayment;\n @Input() remission: IRemission;\n @Input() ccdCaseNumber: string;\n @Input() caseType: string;\n @Input() viewCompStatus: string;\n @Input() paymentGroupRef: string;\n @Input() isTurnOff: boolean;\n @Input() isRefundRemission: boolean;\n @Input() isStrategicFixEnable: boolean;\n @Input() paidAmount: any;\n @Input() isFromRefundListPage: boolean;\n @Input() isFromPaymentDetailPage: boolean;\n @Input() isFromServiceRequestPage: boolean;\n @Input('isFullyRefund') isFullyRefund: boolean;\n @Input() feeamount: number;\n @Input() refundPaymentReference: string;\n @Input() isFromRefundStatusPage: boolean;\n @Input() changeRefundReason: string;\n @Input(\"isServiceRequest\") isServiceRequest: string;\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[];\n @Input('orderDetail') orderDetail: any[];\n @Input('orderRef') orderRef: string;\n @Input('orderStatus') orderStatus: string;\n @Input('orderParty') orderParty: string;\n @Input('orderCreated') orderCreated: Date;\n @Input('orderCCDEvent') orderCCDEvent: string;\n @Input('takepayment') takePayment: boolean;\n @Input('orderFeesTotal') orderFeesTotal: number;\n @Input('orderTotalPayments') orderTotalPayments: number;\n @Input('orderRemissionTotal') orderRemissionTotal: number;\n @Output() cancelRemission: EventEmitter<void> = new EventEmitter();\n //@Output() refundListReason: EventEmitter<any> = new EventEmitter({reason:string, code:string});\n @Output() refundListReason = new EventEmitter<{reason: string, code: string}>();\n @Output() refundListAmount: EventEmitter<string> = new EventEmitter();\n @Output() refundFees: EventEmitter<IFee[]> = new EventEmitter<IFee[]>();\n refund = {\n reason: {\n duplicate: 'Duplicate payment',\n humanerror: 'Human error',\n caseWithdrawn: 'Case withdrawn',\n other: 'Other'\n }\n }\n contactDetailsObj: IRefundContactDetails;\n notification: any;\n remissionForm: FormGroup;\n hasErrors = false;\n viewStatus = 'main';\n errorMessage = null;\n option: string = null;\n isConfirmationBtnDisabled: boolean = false;\n bsPaymentDcnNumber: string;\n selectedValue = 'yes';\n amount: any;\n retroRemission: boolean = false;\n remissionReference: string = '';\n refundReference: string;\n refundAmount: string;\n paymentExplanationHasError: boolean = false;\n refundReason:string;\n selectedRefundReason: string;\n selectedRefundReasonCode: string;\n displayRefundReason: string;\n refundCode:string;\n remessionPayment:IPayment;\n isRemissionCodeEmpty: boolean = false;\n remissionCodeHasError: boolean = false;\n isAmountEmpty: boolean = false;\n isReasonEmpty: boolean = false;\n amountHasError: boolean = false;\n isRemissionLessThanFeeError: boolean = false;\n refundHasError:boolean = false;\n isPaymentSuccess: boolean = false;\n isRemissionApplied: boolean = false;\n remissionamt:number;\n elementId:any;\n // refundReasons: any[] = [];\n commonRefundReasons: any[] = [];\n showReasonText: boolean;\n isRefundReasonsSelected: boolean;\n default: string;\n reasonLength: number;\n refundReasons:IRefundReasons[];\n pattern1: string;\n pattern2: string;\n sendOrderDetail: any[];\n sendOrderRef: string;\n paymentReference : string;\n class='';\n errorMsg = new Array();\n totalRefundAmount: number;\n quantityUpdated: number;\n fullRefund: boolean;\n allowedRefundAmount: number;\n isRemissionsMatch: boolean;\n paymentFees: IFee[];\n paymentGroup: IPaymentGroup;\n isStatusAllocated: boolean;\n isFromCheckAnsPage: boolean;\n refundAmtForFeeVolumes: number;\n paymentObj: IPayment;\n templateInstructionType: string;\n notificationPreview: boolean;\n \n component: { account_number: string; amount: number; case_reference: string; ccd_case_number: string; channel: string; currency: string; customer_reference: string; date_created: string; date_updated: string; description: string; method: string; organisation_name: string; payment_allocation: any[]; reference: string; service_name: string; site_id: string; status: string; };\n\n constructor(private formBuilder: FormBuilder,\n private router: Router,\n private paymentViewService: PaymentViewService,\n private notificationService : NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private refundService: RefundsService,\n private cd: ChangeDetectorRef,\n private OrderslistService: OrderslistService) { }\n\n ngOnInit() {\n this.errorMessage = '';\n this.errorMsg = [];\n this.default = 'Select a different reason';\n this.pattern1 = '^([a-zA-Z0-9]{3})-([a-zA-Z0-9]{3})-([a-zA-Z0-9]{3})$';\n this.pattern2 = '^([A-Za-z]{2}[0-9]{2})-([0-9]{6})$';\n if(this.viewCompStatus !== '' && this.viewCompStatus !== undefined){\n this.viewStatus = '';\n }\n if(this.remission) {\n }\n if(this.fee) {\n this.amount = (this.fee.volume * this.fee.calculated_amount);\n }\n \n if (this.payment){\n this.paymentReference = this.payment.reference;\n this.remessionPayment = this.payment;\n if(this.payment.status === 'Success') {\n this.isPaymentSuccess = true;\n }\n }\n this.option = this.paymentLibComponent.SELECTED_OPTION;\n this.bsPaymentDcnNumber = this.paymentLibComponent.bspaymentdcn;\n this.remissionForm = this.formBuilder.group({\n remissionCode: new FormControl('',\n Validators.compose([\n Validators.required,\n Validators.pattern(`(${this.pattern1})|(${this.pattern2})`)\n ])\n ),\n amount: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[0-9]+(\\.[0-9]{1,2})?$')\n ])),\n refundReason: new FormControl('', Validators.compose([Validators.required])),\n refundDDReason: new FormControl('', Validators.compose([Validators.required])),\n reason: new FormControl(),\n feeAmount: new FormControl(),\n feesList: this.formBuilder.array([])\n });\n const remissionctrls=this.remissionForm.controls;\n remissionctrls['refundDDReason'].setValue('Select a different reason', {onlySelf: true});\n if(this.refundPaymentReference !== undefined && this.refundPaymentReference.length >0) {\n this.paymentReference = this.refundPaymentReference\n } else {\n this.paymentReference = (this.payment !== undefined) ? this.payment.reference : ''; \n }\n \n\n if(this.isFromServiceRequestPage) {\n this.paymentViewService.getApportionPaymentDetails(this.paymentReference).subscribe(\n paymentGroup => {\n let fees = [];\n paymentGroup.fees.forEach(fee => {\n this.isRemissionsMatch = false;\n \n paymentGroup.remissions.forEach(rem => {\n if (rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n fees.push(fee);\n }\n });\n if (!this.isRemissionsMatch) {\n fees.push(fee);\n }\n });\n paymentGroup.fees = fees\n this.paymentFees =fees;\n this.fees = fees;\n this.paymentGroup = paymentGroup;\n \n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n this.refundFeesList();\n },\n (error: any) => this.errorMessage = error\n );\n }\n\n \n if (this.fees && this.viewCompStatus === 'issuerefund') {\n this.refundFeesList();\n }\n\n if(this.viewCompStatus === ''){\n this.viewStatus = 'main';\n }\n \n if(this.viewCompStatus === 'issuerefundpage1'){\n this.refundService.getRefundReasons().subscribe(\n refundReasons => {\n this.refundReasons = refundReasons.filter((data) => data.recently_used === false);\n this.refundReasons = this.refundReasons.filter((data) => data.name !== 'Retrospective remission' && data.name !== 'Overpayment');\n this.cd.detectChanges();\n this.commonRefundReasons = refundReasons.filter((data) => data.recently_used === true);\n this.commonRefundReasons.sort((a, b) => a.toString().localeCompare(b));\n this.cd.detectChanges();\n } );\n this.refundReason = this.changeRefundReason;\n }\n\n if(this.viewCompStatus === 'processretroremissonpage' && this.isFromRefundListPage){\n this.viewStatus = 'processretroremissonpage';\n }\n if(this.orderDetail !== undefined){\n this.paymentViewService.getApportionPaymentDetails(this.orderDetail[0].payments[0].reference).subscribe(\n paymentGroup => {\n this.fees = paymentGroup.fees;\n this.paymentReference = paymentGroup.payments[0].reference;\n },\n (error: any) => this.errorMessage = error\n );\n }\n\n }\n goToPaymentViewComponent() {\n this.paymentLibComponent.paymentMethod = this.payment.method;\n this.paymentLibComponent.paymentGroupReference = this.paymentGroupRef;\n this.paymentLibComponent.paymentReference = this.paymentReference;\n //this.PaymentViewComponent.viewCompStatus = 'overpayment';\n this.paymentLibComponent.viewName = 'payment-view';\n }\n refundFeesList() {\n const creds = this.remissionForm.controls.feesList as FormArray;\n // if(creds.controls.length > 0) {\n for(var i=0;i<this.fees.length;i++) {\n creds.push(this.formBuilder.group({\n id: this.fees[i].id,\n code: this.fees[i].code,\n volume: this.fees[i].volume,\n calculated_amount: this.fees[i].calculated_amount,\n apportion_amount: this.fees[i].apportion_amount,\n ccd_case_number: this.fees[i].ccd_case_number,\n description: this.fees[i].description,\n net_amount: this.fees[i].net_amount,\n version: this.fees[i].version,\n refund_amount : [''],\n selected:[''] ,\n updated_volume: this.fees[i].volume\n }));\n }\n this.cd.detectChanges();\n //}\n }\n\n get feesList()\n {\n const dd =this.remissionForm.get('feesList') as FormArray ;\n return this.remissionForm.get('feesList') as FormArray;\n }\n\n noneSelected(){\n if(this.isFullyRefund) {\n return false;\n } else {\n if(!this.feesList.controls.some(item => item.get('selected').value === true)) {\n this.errorMsg = [];\n [].forEach.call(document.querySelectorAll('input'), function (el) {\n el.classList.remove('inline-error-class');\n });\n }\n return !this.feesList.controls.some(item => item.get('selected').value === true);\n }\n }\n \n check_en (i,v1: any, AppAmt,Volume) {\n const ele = document.getElementById(v1) as HTMLInputElement;\n const formArray = this.remissionForm.controls.feesList as FormArray;\n \n if(ele.checked){\n formArray.at(i).get('refund_amount').setValue(AppAmt);\n formArray.at(i).get('volume').setValue(Volume);\n formArray.at(i).get('selected').setValue(true);\n formArray.at(i).get('updated_volume').setValue(Volume);\n (<HTMLInputElement>document.getElementById('feeAmount_'+v1)).value = AppAmt;\n document.getElementById('feeAmount_'+v1).removeAttribute(\"disabled\"); \n if(Volume === 1) {\n (<HTMLInputElement>document.getElementById('VolumeUpdated_'+v1)).value = Volume;\n } else {\n (<HTMLInputElement>document.getElementById('feeVolumeUpdated_'+v1)).value = Volume;\n }\n \n if (document.getElementById('feeVolumeUpdated_'+v1) !== null) {\n document.getElementById('feeAmount_'+v1).removeAttribute(\"disabled\"); \n document.getElementById('feeVolumeUpdated_'+v1).removeAttribute(\"disabled\"); \n } \n this.cd.detectChanges(); \n } else {\n this.errorMsg = []; \n document.getElementById('feeAmount_'+v1).setAttribute(\"disabled\", \"true\"); \n this.remissionForm.value.feesList[i][\"refund_amount\"] = ''; \n this.remissionForm.value.feesList[i][\"volume\"] = ''; \n this.remissionForm.value.feesList[i][\"selected\"] = false; \n (<HTMLInputElement>document.getElementById('feeAmount_'+v1)).value = '';\n if(Volume>1) {\n this.remissionForm.value.feesList[i][\"volume\"] = ''; \n (<HTMLInputElement>document.getElementById('feeVolumeUpdated_'+v1)).value = '';\n }\n \n if (document.getElementById('feeVolumeUpdated_'+v1) !== null) {\n document.getElementById('feeVolumeUpdated_'+v1).removeAttribute(\"disabled\"); \n }\n this.cd.detectChanges();\n } \n }\n\n\n addRemission() {\n this.resetRemissionForm([false, false, false, false, false, false], 'All');\n const remissionctrls=this.remissionForm.controls,\n isRemissionLessThanFee = this.fee.calculated_amount > remissionctrls.amount.value;\n this.remissionForm.controls['refundReason'].setErrors(null);\n this.remissionForm.controls['refundDDReason'].setErrors(null);\n if (this.remissionForm.dirty && this.remissionForm.valid && isRemissionLessThanFee) {\n this.viewStatus = 'confirmation';\n }else {\n\n if(remissionctrls['remissionCode'].value == '' ) {\n this.resetRemissionForm([true, false, false, false, false, false], 'remissionCode');\n }\n if(remissionctrls['remissionCode'].value != '' && remissionctrls['remissionCode'].invalid ) {\n this.resetRemissionForm([false, true, false, false, false, false], 'remissionCode');\n }\n if(remissionctrls['amount'].value == '' ) {\n this.resetRemissionForm([false, false, true, false, false, false], 'amount');\n }\n if(remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid ) {\n this.resetRemissionForm([false, true, false, true, false, false], 'amount');\n }\n if(remissionctrls.amount.valid && !isRemissionLessThanFee){\n this.resetRemissionForm([false, false, false, false, true, false], 'amount');\n }\n }\n }\n\n confirmRemission() {\n this.isConfirmationBtnDisabled = true;\n const newNetAmount = this.remissionForm.controls.amount.value,\n remissionAmount = this.fee.net_amount - newNetAmount,\n requestBody = new AddRemissionRequest\n (this.ccdCaseNumber, this.fee, remissionAmount, this.remissionForm.controls.remissionCode.value, this.caseType);\n this.paymentViewService.postPaymentGroupWithRemissions(decodeURIComponent(this.paymentGroupRef).trim(), this.fee.id, requestBody).subscribe(\n response => {\n if (JSON.parse(response).success) {\n let LDUrl = this.isTurnOff ? '&isTurnOff=Enable' : '&isTurnOff=Disable'\n LDUrl += `&caseType=${this.caseType}`\n if (this.paymentLibComponent.bspaymentdcn) {\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(`/payment-history/${this.ccdCaseNumber}?view=fee-summary&selectedOption=${this.option}&paymentGroupRef=${this.paymentGroupRef}&dcn=${this.paymentLibComponent.bspaymentdcn}${LDUrl}`);\n }else {\n this.gotoCasetransationPage();\n }\n\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n }\n );\n }\n\n resetRemissionForm(val, field){\n if (field==='All'){\n this.isRemissionCodeEmpty = val[0];\n this.remissionCodeHasError = val[1];\n this.isAmountEmpty = val[2];\n this.amountHasError = val[3];\n this.isRemissionLessThanFeeError = val[4];\n this.isReasonEmpty = val[5];\n } else if(field==='remissionCode' || field==='All') {\n this.isRemissionCodeEmpty = val[0];\n this.remissionCodeHasError = val[1];\n } else if (field==='amount' || field==='All'){\n this.isAmountEmpty = val[2];\n this.amountHasError = val[3];\n this.isRemissionLessThanFeeError = val[4];\n } else if (field==='reason' || field==='All'){\n this.isReasonEmpty = val[5];\n }\n }\n\n // Add retro remission changes\n addRemissionCode() {\n this.errorMessage = false;\n // this.isFromCheckAnsPage = true;\n this.errorMsg = [];\n this.viewStatus = '';\n this.isRefundRemission = false;\n this.resetRemissionForm([false, false, false, false, false, false], 'All');\n const remissionctrls=this.remissionForm.controls\n // isRemissionLessThanFee = this.fee.calculated_amount >= remissionctrls.amount.value;\n this.remissionForm.controls['refundReason'].setErrors(null);\n this.remissionForm.controls['refundDDReason'].setErrors(null);\n this.remissionForm.controls['amount'].setErrors(null);\n if (this.remissionForm.dirty && this.remissionForm.valid ) {\n if (!this.isFromCheckAnsPage) {\n this.viewCompStatus = '';\n this.viewStatus = \"processretroremissonpage\";\n } else {\n this.viewCompStatus = '';\n this.viewStatus = 'checkretroremissionpage';\n }\n \n }else {\n\n if(remissionctrls['remissionCode'].value == '' ) {\n this.resetRemissionForm([true, false, false, false, false], 'remissionCode');\n }\n if(remissionctrls['remissionCode'].value != '' && remissionctrls['remissionCode'].invalid ) {\n this.resetRemissionForm([false, true, false, false, false], 'remissionCode');\n }\n if(remissionctrls['amount'].value == '' ) {\n this.resetRemissionForm([false, false, true, false, false], 'amount');\n }\n if(remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid ) {\n this.resetRemissionForm([false, true, false, true, false], 'amount');\n }\n if(remissionctrls['reason'].value == '') {\n this.resetRemissionForm([false, false, false, true, false, true], 'reason');\n }\n if(remissionctrls.amount.valid){\n this.resetRemissionForm([false, false, false, false, true], 'amount');\n }\n\n }\n }\n\n\n gotoAddRetroRemissionCodePage() {\n this.errorMessage = false;\n this.isFromCheckAnsPage = false;\n this.errorMsg = [];\n if(this.isRefundRemission) {\n this.refundListAmount.emit();\n this.paymentLibComponent.isFromRefundStatusPage = true;\n return;\n }\n if ( this.isFromRefundListPage ) {\n this.paymentLibComponent.iscancelClicked = true;\n this.refundListReason.emit({reason: this.selectedRefundReason, code: this.refundReason});\n this.paymentLibComponent.isFromRefundStatusPage = true;\n return;\n }\n this.viewStatus = '';\n this.selectedValue = 'yes';\n this.viewCompStatus = \"addremission\";\n this.isRefundRemission = true;\n this.errorMessage = '';\n this.errorMsg = [];\n if(this.isFromPaymentDetailPage) {\n this.paymentLibComponent.viewName = 'payment-view';\n }\n }\n\n gotoCheckRetroRemissionPage(payment: IPayment) {\n this.paymentLibComponent.iscancelClicked = false;\n this.errorMessage = '';\n this.resetRemissionForm([false, false, false, false, false], 'All');\n if( !this.isRefundRemission) {\n var remissionctrls=this.remissionForm.controls,\n isRemissionLessThanFee = this.fee.calculated_amount >= remissionctrls.amount.value;\n if (this.remissionForm.dirty ) {\n if(remissionctrls['amount'].value == '' || remissionctrls['amount'].value < 0) {\n this.resetRemissionForm([false, false, true, false, false], 'amount');\n } else if(remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid ) {\n this.resetRemissionForm([false, false, false, true, false], 'amount');\n } else if(remissionctrls.amount.valid && !isRemissionLessThanFee){\n this.resetRemissionForm([false, false, false, false, true], 'amount');\n } else {\n this.viewCompStatus = '';\n this.viewStatus = \"checkretroremissionpage\";\n }\n }\n } else {\n var remissionctrls=this.remissionForm.controls;\n //if (this.remissionForm.dirty ) {\n if(remissionctrls['amount'].value == '' || remissionctrls['amount'].value < 0 ) {\n this.resetRemissionForm([false, false, true, false, false], 'amount');\n } else {\n this.viewCompStatus = '';\n this.viewStatus = \"checkretroremissionpage\";\n this.refundListAmount.emit(remissionctrls['amount'].value);\n }\n //}\n\n }\n }\n gotoAmountRetroRemission() {\n this.isFromCheckAnsPage = false;\n this.viewStatus = 'processretroremissonpage';\n this.viewCompStatus = '';\n // this.isRefundRemission = true;\n this.errorMessage = '';\n }\n gotoProcessRetroRemissionPage() {\n this.isFromCheckAnsPage = true;\n this.viewStatus = '';\n this.viewCompStatus = 'addremission';\n this.isRefundRemission = true;\n this.errorMessage = '';\n this.errorMsg = [];\n }\n\n gotoProcessRetroRemission(note?: IRefundContactDetails) {\n if(note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.isFromCheckAnsPage = true;\n this.viewStatus = 'remissionAddressPage';\n this.viewCompStatus = '';\n this.isRefundRemission = true;\n this.errorMessage = '';\n }\n\n confirmRetroRemission() {\n if(!this.isConfirmationBtnDisabled) {\n this.retroRemission = true;\n this.remissionamt = this.remissionForm.controls.amount.value;\n const requestBody = new AddRetroRemissionRequest(this.remissionamt,this.remissionForm.controls.remissionCode.value )\n this.paymentViewService.postPaymentGroupWithRetroRemissions(decodeURIComponent(this.paymentGroupRef).trim(), this.fee.id, requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.isRemissionApplied = true;\n this.viewCompStatus = '';\n this.viewStatus = 'retroremissionconfirmationpage';\n this.remissionReference =JSON.parse(response).remission_reference;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n }\n );\n }\n }\n\n processRefund() {\n this.errorMessage = '';\n this.errorMsg = [];\n this.isConfirmationBtnDisabled = true;\n if( this.isRefundRemission) {\n this.retroRemission = true;\n }\n if (this.remissionReference === undefined || this.remissionReference === '') {\n this.remissionReference = this.remission.remission_reference;\n }\n const requestBody = new PostIssueRefundRetroRemission(this.remissionReference, this.contactDetailsObj);\n this.paymentViewService.postRefundRetroRemission(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n })\n }\n\n // Issue Refund changes\n\n gotoIssueRefundConfirmation(payment: IPayment) {\n \n this.paymentLibComponent.iscancelClicked = false;\n if(this.paymentLibComponent.REFUNDLIST === \"true\") {\n this.isFromRefundListPage = true;\n }\n\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n\n\n this.errorMessage = '';\n this.errorMsg = [];\n this.refundReason = this.remissionForm.controls['refundReason'].value === null ? this.remissionForm.controls['refundDDReason'].value : this.remissionForm.controls['refundReason'].value;\n if(!this.refundReason || this.refundReason === 'Select a different reason') {\n this.refundHasError = true;\n } else if(this.selectedRefundReason.includes('Other') && (this.remissionForm.controls['reason'].value == '' || this.remissionForm.controls['reason'].value == null)) {\n this.resetRemissionForm([false, false, false, true, false, true], 'reason');\n } else if (this.selectedRefundReason.includes('Other') && this.remissionForm.controls['reason'].value !== '') {\n this.refundHasError = false;\n this.refundReason += '-' + this.remissionForm.controls['reason'].value;\n this.displayRefundReason = this.selectedRefundReason + '-' + this.remissionForm.controls['reason'].value;\n if ( this.isFromRefundListPage ) {\n this.refundListReason.emit({reason: this.displayRefundReason, code: this.refundReason});\n } else {\n if(this.isFromCheckAnsPage) {\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.isFromCheckAnsPage = false;\n this.viewStatus = 'checkissuerefundpage';\n this.viewCompStatus = '';\n this.notificationPreview = false;\n return;\n }\n this.viewCompStatus = '';\n this.viewStatus = 'contactDetailsPage';\n }\n\n } else {\n this.displayRefundReason = this.selectedRefundReason;\n if(this.isFromCheckAnsPage) {\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.isFromCheckAnsPage = false;\n this.viewStatus = 'checkissuerefundpage';\n this.viewCompStatus = '';\n this.notificationPreview = false;\n return;\n }\n if ( this.isFromRefundListPage ) {\n this.paymentLibComponent.isFromRefundStatusPage = true;\n this.refundListReason.emit({reason: this.selectedRefundReason, code: this.refundReason});\n } else {\n this.viewCompStatus = '';\n this.viewStatus = 'contactDetailsPage';\n }\n\n }\n }\n\n gotoIssueRefundPage() {\n this.errorMessage = '';\n this.viewCompStatus = 'issuerefund';\n this.viewStatus = '';\n this.isRefundRemission = true;\n this.errorMessage = false;\n this.errorMsg = [];\n this.refundHasError = false;\n this.isReasonEmpty = false;\n }\n\n gotoIssuePage(isFullyRefund: any){\nif(isFullyRefund) {\n this.viewCompStatus = 'issuerefundpage1';\n this.getRefundReasons();\n} else {\n [].forEach.call(document.querySelectorAll('input'), function (el) {\n el.classList.remove('inline-error-class');\n });\n\n\t var checkboxs = document.getElementsByTagName('input');\n\t this.errorMessage = '';\n this.totalRefundAmount = 0;\n this.errorMsg = []; \n\t\t\tfor (var j=0;j<checkboxs.length;j++)\n\t\t\t{\n\t\t\t\tif(checkboxs[j].checked)\n\t\t\t\t{\n\t\t\t\t\tthis.fullRefund = false;\n\t\t\t\t\tlet quantity: number = +(<HTMLInputElement>document.getElementById('feeVolume_'+checkboxs[j].value)).value;\n let amountToRefund: number = +(<HTMLInputElement>document.getElementById('feeAmount_'+checkboxs[j].value)).value;\n\t\t\t\t\tlet apportionAmount: number = +(<HTMLInputElement>document.getElementById('feeApportionAmount_'+checkboxs[j].value)).value;\n\t\t\t\t\tlet calculatedAmount: number = +(<HTMLInputElement>document.getElementById('calculatedAmount_'+checkboxs[j].value)).value; \n \n if( amountToRefund === apportionAmount) {\n this.fullRefund = true;\n }\n\n if(amountToRefund === 0){\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('You need to enter a refund amount');\n this.getErrorClass(this.elementId);\n\t\t\t\t\t}\n\n \n\n if (quantity === 1)\n {\n if(amountToRefund > 0 && amountToRefund > apportionAmount){\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('The amount you want to refund is more than the amount paid');\n this.getErrorClass(this.elementId);\n }\n } \n\n\t\t\t\t\tif(quantity > 1) {\n\n\t\t\t\t\t\tthis.quantityUpdated = +(<HTMLInputElement>document.getElementById('feeVolumeUpdated_'+checkboxs[j].value)).value;\n\n if(this.quantityUpdated === 0){\n this.elementId = 'feeVolumeUpdated_'+checkboxs[j].value;\n this.errorMsg.push('You need to enter quantity')\n this.getErrorClass(this.elementId);\n }\n\n if (this.fullRefund && quantity !== this.quantityUpdated) {\n this.elementId = 'feeVolumeUpdated_'+checkboxs[j].value;\n this.errorMsg.push('The quantity you want to refund should be maximun available quantity');\n this.getErrorClass(this.elementId);\n }\n\n if (!this.fullRefund && this.quantityUpdated > 0 && amountToRefund > 0) {\n this.refundAmtForFeeVolumes = +(<HTMLInputElement>document.getElementById('feeVOl_'+checkboxs[j].value)).innerText;\n this.allowedRefundAmount = this.quantityUpdated * this.refundAmtForFeeVolumes;\n if( this.allowedRefundAmount !== amountToRefund) \n {\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('The Amount to Refund should be equal to the product of Fee Amount and quantity');\n this.getErrorClass(this.elementId);\n }\n }\n\n if(!this.fullRefund && amountToRefund > apportionAmount)\n {\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('The amount you want to refund is more than the amount paid');\n this.getErrorClass(this.elementId);\n }\n\t\n if( !this.fullRefund && this.quantityUpdated >0 && this.quantityUpdated > quantity){\n this.elementId = 'feeVolumeUpdated_'+checkboxs[j].value;\n this.errorMsg.push('The quantity you want to refund is more than the available quantity');\n this.getErrorClass(this.elementId);\n }\n }\n //this.remissionForm.value.feesList.find(id=>id=checkboxs[j].value)['refund_amount'] = apportionAmount;\n\t\t\t\t}\n\t\t\t}\n\n if(this.errorMsg.length === 0) {\n if (this.isFromCheckAnsPage) {\n this.isFromCheckAnsPage = false;\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.fees = this.remissionForm.value.feesList.filter(value => value.selected===true);\n this.viewStatus = 'checkissuerefundpage'\n this.viewCompStatus = '';\n this.notificationPreview = false;\n return;\n } else if (this.isFromRefundStatusPage){\n var remissionctrls=this.remissionForm.controls;\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.refundListAmount.emit(this.totalRefundAmount.toString());\n this.fees = this.remissionForm.value.feesList.filter(value => value.selected===true);\n this.refundFees.emit(this.fees);\n return;\n }\n this.viewCompStatus = 'issuerefundpage1';\n this.getRefundReasons();\n }\n }\n }\n\n calAmtToRefund(value,amount,volume, i: any) {\n const volumeFee = amount/volume;\n const amtToRefund = value * volumeFee;\n const formArray = this.remissionForm.controls.feesList as FormArray;\n formArray.at(i).get('refund_amount').setValue(amtToRefund);\n // formArray.at(i).get('volume').setValue(value);\n // (<HTMLInputElement>document.getElementById('feeAmount_'+i)).value = +amtToRefund;\n // const formControl = this.remissionForm.controls.feesList['volume'].at(i);\n // formControl.setValue(value);\n\n }\n gotoContactDetailsPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewCompStatus = '';\n this.viewStatus = 'contactDetailsPage';\n this.isRefundRemission = true;\n this.errorMessage = false;\n }\n \n getRefundReasons(){\n if(this.viewCompStatus === 'issuerefundpage1'){\n this.refundService.getRefundReasons().subscribe(\n refundReasons => { \n this.refundReasons = refundReasons.filter((data) => data.recently_used === false);\n this.refundReasons = this.refundReasons.filter((data) => data.name !== 'Retrospective remission');\n this.cd.detectChanges();\n this.commonRefundReasons = refundReasons.filter((data) => data.recently_used === true);\n this.commonRefundReasons.sort((a, b) => a.toString().localeCompare(b));\n this.cd.detectChanges();\n } );\n }\n}\n getErrorClass(elementId) {\n if(this.errorMsg.length > 0) {\n const ele = document.getElementById(elementId);\n ele.classList.add('inline-error-class');\n }\n \n }\n\n changeIssueRefundReason() {\n this.isFromCheckAnsPage = true;\n this.errorMessage = '';\n this.errorMsg = [];\n this.refundHasError = false;\n this.isReasonEmpty = false;\n this.viewCompStatus = 'issuerefundpage1';\n this.viewStatus = '';\n this.isRefundRemission = true;\n }\n\n confirmIssueRefund(isFullyRefund: any) {\n this.isConfirmationBtnDisabled = true;\n this.errorMessage = '';\n this.errorMsg = [];\n if( this.isRefundRemission) {\n this.retroRemission = true;\n }\n if(isFullyRefund) {\n this.totalRefundAmount = this.payment.amount;\n }\n if(!isFullyRefund) {\n this.fees = this.remissionForm.value.feesList.filter(value => value.selected===true);\n }\n this.fees = this.fees.map(obj => ({ id: obj.id, \n code: obj.code,\n version:obj.version, \n apportion_amount: obj.apportion_amount,\n calculated_amount: obj.calculated_amount,\n updated_volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n refund_amount:obj.refund_amount ? obj.refund_amount : this.totalRefundAmount }));\n \n \n const requestBody = new PostRefundRetroRemission(this.contactDetailsObj, this.fees,this.payment.reference, this.refundReason, \n this.totalRefundAmount, 'op');\n this.paymentViewService.postRefundsReason(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference =JSON.parse(response).refund_reference;\n if(JSON.parse(response).refund_amount) {\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n })\n }\n\n gotoRefundReasonPage () {\n this.viewStatus = '';\n this.viewCompStatus = 'issuerefundpage1';\n \n }\n\n// Retro Refund\n\n // confirmRetroRefund() {\n // this.isConfirmationBtnDisabled = true;\n // this.errorMessage = '';\n // this.errorMsg = [];\n // if( this.isRefundRemission) {\n // this.retroRemission = true;\n // }\n\n // const requestBody = new PostRefundRetroRemission(this.payment.reference,'RR004-Retrospective remission', this.contactDetailsObj);\n // this.paymentViewService.postRefundsReason(requestBody).subscribe(\n // response => {\n // if (JSON.parse(response)) {\n // this.viewCompStatus = '';\n // this.viewStatus = 'retrorefundconfirmationpage';\n // this.refundReference =JSON.parse(response).refund_reference;\n // if(JSON.parse(response).refund_amount) {\n // this.refundAmount = JSON.parse(response).refund_amount;\n // }\n // }\n // },\n // (error: any) => {\n // this.errorMessage = error;\n // this.isConfirmationBtnDisabled = false;\n // });\n // }\n\n selectRadioButton(key, value) {\n localStorage.setItem(\"myradio\", value);\n const remissionctrls=this.remissionForm.controls;\n remissionctrls['refundDDReason'].setValue('Select a different reason', {onlySelf: true});\n remissionctrls['reason'].reset();\n this.isRefundReasonsSelected = true;\n this.errorMessage = false;\n this.errorMsg = [];\n this.isReasonEmpty = false;\n this.showReasonText = false;\n this.refundHasError = false;\n this.selectedRefundReason = value;\n this.selectedRefundReasonCode = key;\n if(this.selectedRefundReason.includes('Other')) {\n this.showReasonText = true;\n this.refundHasError = false;\n this.refundReason = value;\n }\n }\n\n selectchange(args) {\n const remissionctrls=this.remissionForm.controls;\n remissionctrls['refundReason'].reset();\n remissionctrls['reason'].reset();\n this.isRefundReasonsSelected = false;\n this.showReasonText = false;\n this.refundHasError = false;\n this.selectedRefundReason = args.target.options[args.target.options.selectedIndex].id;\n this.selectedRefundReasonCode = args.target.options[args.target.options.selectedIndex].value;\n this.reasonLength = (29-this.selectedRefundReason.split('- ')[1].length);\n\n if(this.selectedRefundReason.includes('Other')) {\n this.showReasonText = true;\n this.refundHasError = false;\n this.refundReason = args.target.options[args.target.options.selectedIndex].id;\n }\n\n\n }\n getContactDetails(obj:IRefundContactDetails, type) {\n this.contactDetailsObj = obj;\n this.viewCompStatus = '';\n this.notificationPreview = false;\n if(type == 'checkaddRefundpage'){\n this.getTemplateInstructionType(this.remessionPayment.reference,this.remessionPayment);\n }else if (type == 'checkissuerefundpage'){\n this.getTemplateInstructionType(this.payment.reference, this.payment);\n }else if(type == 'addrefundcheckandanswer'){\n this.getTemplateInstructionType(this.paymentReference, this.paymentObj);\n }\n this.viewStatus = type;\n }\n\n gotoPartialFeeRefundScreen() {\n\n if (this.isFromRefundStatusPage){\n var remissionctrls=this.remissionForm.controls;\n this.refundListReason.emit({reason: this.displayRefundReason, code: this.refundReason});\n return;\n }\n this.refundHasError = false;\n this.viewCompStatus = 'issuerefund';\n this.viewStatus = '';\n }\n\n \n\n gotoServiceRequestPage(event: any) {\n this.errorMessage ='';\n this.errorMsg = [];\n this.isFromCheckAnsPage = false;\n event.preventDefault();\n\n if (this.isFromRefundStatusPage){\n var remissionctrls=this.remissionForm.controls;\n this.totalRefundAmount = 0;\n this.refundListAmount.emit(this.totalRefundAmount.toString());\n return;\n }\n if (this.isFromServiceRequestPage && !this.isFromPaymentDetailPage) {\n this.viewStatus = 'order-full-view';\n this.viewCompStatus = '';\n } else if ( this.isFromRefundListPage ) {\n this.paymentLibComponent.iscancelClicked = true;\n this.refundListReason.emit({reason: this.selectedRefundReason, code: this.refundReason});\n this.paymentLibComponent.isFromRefundStatusPage = true;\n } else {\n this.paymentLibComponent.paymentMethod = this.payment.method;\n this.paymentLibComponent.paymentGroupReference = this.paymentLibComponent.paymentGroupReference\n this.paymentLibComponent.paymentReference = this.payment.reference;\n this.paymentLibComponent.viewName = 'payment-view';\n this.OrderslistService.setOrderRef(this.orderRef);\n this.OrderslistService.setorderCCDEvent(this.orderCCDEvent);\n this.OrderslistService.setorderCreated(this.orderCreated);\n this.OrderslistService.setorderDetail(this.orderDetail);\n this.OrderslistService.setorderParty(this.orderParty);\n this.OrderslistService.setorderTotalPayments(this.orderTotalPayments);\n this.OrderslistService.setorderRemissionTotal(this.orderRemissionTotal);\n this.OrderslistService.setorderFeesTotal(this.orderFeesTotal);\n this.viewStatus = 'payment-view';\n this.sendOrderDetail = this.orderDetail;\n this.sendOrderRef = this.orderRef;\n if(this.LOGGEDINUSERROLES === undefined) {\n this.OrderslistService.getUserRolesList().subscribe((data) => this.LOGGEDINUSERROLES = data);\n }\n this.viewCompStatus = '';\n }\n\n }\n gotoAddressPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewCompStatus = 'addrefundforremission';\n this.viewStatus = '';\n this.isRefundRemission = true;\n this.errorMessage = false;\n }\n gotoRemissionSuccess(event: Event) {\n event.preventDefault();\n this.errorMessage = '';\n this.viewCompStatus = '';\n this.viewStatus = 'retroremissionconfirmationpage';\n this.isRefundRemission = true;\n this.errorMessage = false;\n }\n\n gotoCasetransationPage() {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.errorMessage = '';\n this.errorMsg = [];\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.VIEW = 'case-transactions';\n this.paymentLibComponent.ISTURNOFF = this.isTurnOff;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.resetOrderData();\n let partUrl = this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl += this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl += this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl += `&caseType=${this.caseType}`;\n const url = `/payment-history/${this.ccdCaseNumber}?view=case-transactions&takePayment=${this.paymentLibComponent.TAKEPAYMENT}&selectedOption=${this.option}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n }\n\n gotoCasetransationPageCancelBtnClicked(event: Event) {\n event.preventDefault();\n this.errorMsg = [];\n if( this.paymentLibComponent.isFromServiceRequestPage !== undefined && !this.paymentLibComponent.isFromServiceRequestPage) {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.VIEW ='case-transactions';\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n } else { \n\n if (this.paymentLibComponent.REFUNDLIST) {\n this.paymentLibComponent.viewName = 'refund-list';\n return;\n }\n if (this.paymentLibComponent.TAKEPAYMENT === undefined && this.paymentLibComponent.SERVICEREQUEST === undefined) {\n this.paymentLibComponent.SERVICEREQUEST = 'false';\n }\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.OrderslistService.setpaymentPageView({method: '',payment_group_reference: '', reference:''});\n this.OrderslistService.setnavigationPage('casetransactions');\n this.errorMessage = '';\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISTURNOFF = this.isTurnOff;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.paymentLibComponent.ISBSENABLE = true;\n let partUrl = this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl += this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl += this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl += `&caseType=${this.caseType}`;\n if(this.isFromPaymentDetailPage) {\n partUrl += this.paymentLibComponent.isFromPaymentDetailPage\n }\n\n if(!this.paymentLibComponent.SERVICEREQUEST) {\n const url = `/payment-history/${this.ccdCaseNumber}?view=case-transactions&takePayment=${this.paymentLibComponent.TAKEPAYMENT}&selectedOption=${this.option}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n } else {\n const url =`/payment-history/${this.ccdCaseNumber}?selectedOption=${this.option}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n }\n }\n\n }\n\n resetOrderData() {\n this.OrderslistService.setOrderRef(null);\n this.OrderslistService.setorderCCDEvent(null);\n this.OrderslistService.setorderCreated(null);\n this.OrderslistService.setorderDetail(null);\n this.OrderslistService.setorderParty(null);\n this.OrderslistService.setorderTotalPayments(null);\n this.OrderslistService.setorderRemissionTotal(null);\n this.OrderslistService.setorderFeesTotal(null);\n }\n\n changeRefundAmount() { \n this.isFromCheckAnsPage = true;\n this.viewCompStatus = 'issuerefund';\n this.viewStatus = '';\n }\n\n getFormattedCurrency(currency:number){\n if(currency.toString().includes(\".\")){\n return currency\n }\n return currency.toString().concat(\".00\");\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n\n getTemplateInstructionType(paymentReference: string, payment?: IPayment): void {\n\n if (payment == undefined || payment == null || payment.reference != paymentReference) {\n this.paymentViewService.getPaymentDetails(paymentReference).subscribe(\n payment => {\n this.paymentObj = payment;\n this.paymentObj.reference = paymentReference;\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(this.paymentObj.channel, this.paymentObj.method);\n },\n (error: any) => { \n this.templateInstructionType = 'Template';\n })\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n }\n\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n@Pipe({\n name: 'ccdHyphens'\n})\nexport class CcdHyphensPipe implements PipeTransform {\n constructor() {}\n transform(value: any, args?: any): any {\n const pattern = /^([0-9]{4})+([0-9]{4})+([0-9]{4})+([0-9]{4})$/;\n if ( value.match(pattern)) {\n return value.replace(pattern,'$1-$2-$3-$4') \n }\n return value;\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n@Pipe({\n name: 'capitalize'\n})\nexport class CapitalizePipe implements PipeTransform {\n constructor() { }\n transform(s: any, args?: any): any {\n return s && s[0].toUpperCase() + s.slice(1) || \"\";\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n@Pipe({\n name: 'keyValue'\n})\nexport class keyValuePipe implements PipeTransform {\n constructor() {}\n transform(input: any): any {\n let keys = [];\n for (let key in input) {\n if (input.hasOwnProperty(key)) {\n keys.push({ key: key, value: input[key]});\n }\n }\n return keys;\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\n\n@Pipe({ name: 'sanitizeHtml' })\nexport class SanitizeHtmlPipe implements PipeTransform {\n constructor(private sanitizer: DomSanitizer) {}\n transform(value: any): SafeHtml {\n return this.sanitizer.bypassSecurityTrustHtml(value);\n }\n}\n","import { Injectable } from '@angular/core';\nimport * as FileSaver from 'file-saver';\nimport * as XLSX from 'xlsx';\nimport * as XLSXStyle from 'xlsx-style';\n\n\nconst EXCEL_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8';\nconst EXCEL_EXTENSION = '.xlsx';\n\n@Injectable()\nexport class XlFileService {\n\n constructor() { }\n\n public exportAsExcelFile(json: any[], excelFileName: string): void {\n let worksheet: XLSX.WorkSheet; \n let workbook: XLSX.WorkBook; \n if(excelFileName.match('Data_Loss')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['loss_resp','payment_asset_dcn','env_ref','env_item','resp_service_id','resp_service_name','date_banked','bgc_batch','payment_method','amount']});\n worksheet = this.setDataLossReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else if(excelFileName.match('Unprocessed')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['resp_service_id','resp_service_name','exception_ref','ccd_ref','date_banked','bgc_batch','payment_asset_dcn','env_ref','env_item','payment_method','amount']});\n worksheet = this.setUnprocessedReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else if(excelFileName.match('Processed_Unallocated')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['resp_service_id','resp_service_name','allocation_status','receiving_office','allocation_reason','ccd_exception_reference','ccd_case_reference','payment_asset_dcn','env_ref','env_item','date_banked','bgc_batch','payment_method','amount']});\n worksheet = this.setProcessedUnallocatedReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else if(excelFileName.match('Payment failure')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['payment_reference','ccd_reference','document_control_number','org_id','service_name','failure_reference','failure_reason','disputed_amount','event_name','event_date','representment_status','representment_date','refund_reference','refund_amount','refund_date']});\n worksheet = this.setPaymentFailureReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else {\n worksheet = XLSX.utils.json_to_sheet(json,{header:['resp_service_id','resp_service_name','surplus_shortfall','balance','payment_amount','ccd_case_reference', 'ccd_exception_reference', 'processed_date', 'reason', 'explanation', 'user_name']});\n worksheet = this.setShortFallReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n }\n workbook = { Sheets: { 'data': worksheet }, SheetNames: ['data'] };\n const excelBuffer: any = XLSX.write(workbook, { bookType: 'xlsx', type: 'array' });\n this.saveAsExcelFile(excelBuffer, excelFileName);\n }\n\n\nprivate autoFitColumns (worksheet: XLSX.WorkSheet,json:any) : XLSX.WorkSheet {\n let objectMaxLength = []; \n let ColWidth = [];\n let obj = <any>Object;\n for (let i = 0; i < json.length; i++) {\n let value = obj.values(json[i]);\n let key = obj.keys(json[i]);\n for (let j = 0; j < value.length; j++) {\n if(value[j] === null){\n value[j] = '';\n }\n objectMaxLength[j] =\n key[j].length >= value[j].length\n ? key[j].length+2\n : value[j].length+1;\n if( value[j].length === undefined){\n objectMaxLength[j] = key[j].length+2;\n }\n ColWidth.push({'width': +objectMaxLength[j]});\n }\n }\n worksheet['!cols'] = ColWidth;\n return worksheet;\n}\n\n\nprivate setDataLossReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Loss_Resp\";\n worksheet.B1.v = \"Payment_Asset_DCN\";\n worksheet.C1.v = \"Envelope_Ref\";\n worksheet.D1.v = \"Envelope_Item\";\n worksheet.E1.v = \"Resp_Service ID\";\n worksheet.F1.v = \"Resp_Service Name\";\n worksheet.G1.v = \"Date_Banked\";\n worksheet.H1.v = \"BGC_Batch\";\n worksheet.I1.v = \"Payment_Method\";\n worksheet.J1.v = \"Amount\";\n return worksheet;\n}\n\nprivate setUnprocessedReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Resp_Service ID\";\n worksheet.B1.v = \"Resp_Service Name\";\n worksheet.C1.v = \"Exception_Ref\";\n worksheet.D1.v = \"CCD_Ref\";\n worksheet.E1.v = \"Date_Banked\";\n worksheet.F1.v = \"BGC_Batch\";\n worksheet.G1.v = \"Payment_Asset_DCN\";\n worksheet.H1.v = \"Envelope_Ref\";\n worksheet.I1.v = \"Envelope_Item\";\n worksheet.J1.v = \"Payment_Method\";\n worksheet.K1.v = \"Amount\";\n return worksheet;\n}\n\nprivate setProcessedUnallocatedReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Resp_Service ID\";\n worksheet.B1.v = \"Resp_Service Name\";\n worksheet.C1.v = \"Allocation_Status\";\n worksheet.D1.v = \"Receiving_Office\";\n worksheet.E1.v = \"Allocation_Reason\";\n worksheet.F1.v = \"CCD_Exception_Ref\";\n worksheet.G1.v = \"CCD_Case_Ref\";\n worksheet.H1.v = \"Payment_Asset_DCN\";\n worksheet.I1.v = \"Envelope_Ref\";\n worksheet.J1.v = \"Envelope_Item\";\n worksheet.K1.v = \"Date_Banked\";\n worksheet.L1.v = \"BGC_Batch\";\n worksheet.M1.v = \"Payment_Method\";\n worksheet.N1.v = \"Amount\";\n return worksheet;\n}\n\nprivate setPaymentFailureReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Payment reference\";\n worksheet.B1.v = \"CCD reference\";\n worksheet.C1.v = \"Document Control Number\";\n worksheet.D1.v = \"OrgID\";\n worksheet.E1.v = \"Service name\";\n worksheet.F1.v = \"Failure reference\";\n worksheet.G1.v = \"Failure reason\";\n worksheet.H1.v = \"Disputed amount\";\n worksheet.I1.v = \"Event name\";\n worksheet.J1.v = \"Event date\";\n worksheet.K1.v = \"Representment status\";\n worksheet.L1.v = \"Representment date\";\n worksheet.M1.v = \"Refund reference\";\n worksheet.N1.v = \"Refund amount\";\n worksheet.O1.v = \"Refund date\";\n return worksheet;\n}\nprivate setShortFallReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Resp_Service ID\";\n worksheet.B1.v = \"Resp_Service Name\";\n worksheet.C1.v = \"Over Payment_Under Payment\";\n worksheet.D1.v = \"Balance\";\n worksheet.E1.v = \"Payment_Amount\";\n worksheet.F1.v = \"CCD_Case_Ref\";\n worksheet.G1.v = \"Exception_Ref\";\n worksheet.H1.v = \"Processed_Date\";\n worksheet.I1.v = \"Reason\";\n worksheet.J1.v = \"Explanation\";\n worksheet.K1.v = \"Updated Name\";\n return worksheet;\n}\n\nprivate saveAsExcelFile(buffer: any, fileName: string): void {\n const data: Blob = new Blob([buffer], {\n type: EXCEL_TYPE\n });\n FileSaver.saveAs(data, fileName + EXCEL_EXTENSION);\n }\n}\n","import { Component, Input, OnInit } from '@angular/core';\nimport { FormBuilder, FormGroup, FormControl } from '@angular/forms';\nimport { formatDate } from \"@angular/common\";\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport {XlFileService} from '../../services/xl-file/xl-file.service';\nimport { FindValueSubscriber } from 'rxjs/internal/operators/find';\n\n@Component({\n selector: 'ccpay-reports',\n templateUrl: './reports.component.html',\n styleUrls: ['./reports.component.scss']\n})\nexport class ReportsComponent implements OnInit {\n @Input() ISPAYMENTSTATUSENABLED: string;\n fmt = 'dd/MM/yyyy';\n loc = 'en-US';\n reportsForm: FormGroup;\n startDate: string;\n endDate: string;\n errorMeaagse: string;\n ccdCaseNumber: string;\n isDownLoadButtondisabled:Boolean = false;\n isStartDateLesthanEndDate: Boolean = false;\n isDateBetwnMonth: Boolean = false;\n isDateRangeBetnWeek: Boolean = false;\n errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n paymentGroups: IPaymentGroup[] = [];\n\n constructor(\n private xlFileService: XlFileService,\n private errorHandlerService: ErrorHandlerService,\n private formBuilder: FormBuilder,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private paymentViewService: PaymentViewService) { }\n \n\n ngOnInit() {\n this.fromValidation();\n\n }\n\n getToday(): string {\n return new Date().toISOString().split('T')[0];\n }\n\n getSelectedFromDate(): void {\n this.validateDates(this.reportsForm.get('selectedreport').value);\n }\n\n validateDates(reportName){\n const selectedStartDate = this.tranformDate(this.reportsForm.get('startDate').value),\n selectedEndDate = this.tranformDate(this.reportsForm.get('endDate').value);\n const isDateRangeMoreThanWeek = (<any>new Date(selectedStartDate) - <any>new Date(selectedEndDate))/(1000 * 3600 * -24) > 7;\n const isDateRangeMoreThanMonth = (<any>new Date(selectedStartDate) - <any>new Date(selectedEndDate))/(1000 * 3600 * -24) > 30;\n if(new Date(selectedStartDate) > new Date(selectedEndDate) && selectedEndDate !== ''){\n this.reportsForm.get('startDate').setValue('');\n this.isDateRangeBetnWeek = false;\n this.isDateBetwnMonth = false;\n this.isStartDateLesthanEndDate = true;\n } else if(reportName && reportName ==='SURPLUS_AND_SHORTFALL' && isDateRangeMoreThanWeek ) {\n this.isDateRangeBetnWeek = true;\n this.isDateBetwnMonth = false;\n this.isStartDateLesthanEndDate = false;\n } else if(reportName && reportName ==='PAYMENT_FAILURE_EVENT' && isDateRangeMoreThanMonth ) {\n this.isDateRangeBetnWeek = false;\n this.isDateBetwnMonth = true;\n this.isStartDateLesthanEndDate = false;\n } else {\n this.isDateBetwnMonth = false;\n this.isDateRangeBetnWeek = false;\n this.isStartDateLesthanEndDate = false;\n }\n\n }\n\n fromValidation() {\n this.reportsForm = this.formBuilder.group({\n selectedreport: new FormControl('') ,\n startDate: new FormControl(''),\n endDate: new FormControl('') \n });\n}\n\ndownloadReport(){\n this.isDownLoadButtondisabled = true;\n const dataLossRptDefault = [{loss_resp:'',payment_asset_dcn:'',env_ref:'',env_item:'',resp_service_id:'',resp_service_name:'',date_banked:'',bgc_batch:'',payment_method:'',amount:''}],\n unProcessedRptDefault = [{resp_service_id:'',resp_service_name:'',exception_ref:'',ccd_ref:'',date_banked:'',bgc_batch:'',payment_asset_dcn:'',env_ref:'',env_item:'',payment_method:'',amount:''}],\n processedUnallocated =[{resp_service_id:'',resp_service_name:'',allocation_status:'',receiving_office:'',allocation_reason:'',ccd_exception_ref:'',ccd_case_ref:'',payment_asset_dcn:'',env_ref:'',env_item:'',date_banked:'',bgc_batch:'',payment_method:'',amount:'',updated_by:''}],\n shortFallsRptDefault = [{resp_service_id:'',resp_service_name:'',surplus_shortfall:'',balance:'',payment_amount:'',ccd_case_reference:'',ccd_exception_reference:'',processed_date:'', reason:'', explanation:'', user_name:''}],\n selectedReportName = this.reportsForm.get('selectedreport').value,\n selectedStartDate = this.tranformDate(this.reportsForm.get('startDate').value),\n selectedEndDate = this.tranformDate(this.reportsForm.get('endDate').value);\n\n if(selectedReportName === 'PROCESSED_UNALLOCATED' || selectedReportName === 'SURPLUS_AND_SHORTFALL' ){\n this.paymentViewService.downloadSelectedReport(selectedReportName,selectedStartDate,selectedEndDate).subscribe(\n response => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n const result = JSON.parse(response);\n let res= {data: this.applyDateFormat(result)};\n if(res['data'].length === 0 && selectedReportName === 'PROCESSED_UNALLOCATED' ){\n res.data= processedUnallocated;\n } else if(res['data'].length === 0 && selectedReportName === 'SURPLUS_AND_SHORTFALL' ) {\n res.data= shortFallsRptDefault;\n } \n if(result['data'].length > 0) {\n for( var i=0; i< res['data'].length; i++) {\n if(res['data'][i][\"payment_asset_dcn\"] !== undefined) {\n res['data'][i]['env_ref'] = res['data'][i][\"payment_asset_dcn\"].substr(0,13);\n res['data'][i]['env_item'] = res['data'][i][\"payment_asset_dcn\"].substr(13,21);\n }\n if(res['data'][i][\"amount\"] !== undefined) {\n res['data'][i]['amount'] = this.convertToFloatValue(res['data'][i]['amount']);\n }\n if(res['data'][i][\"balance\"] !== undefined) {\n res['data'][i]['balance'] = this.convertToFloatValue(res['data'][i][\"balance\"]);\n }\n let Op = res['data'][i][\"surplus_shortfall\"];\n if(Op !== undefined) {\n res['data'][i]['surplus_shortfall'] = Op ==\"Surplus\" ? \"Over payment\":\"Under payment\";\n }\n if(res['data'][i][\"payment_amount\"] !== undefined) {\n res['data'][i]['payment_amount'] = this.convertToFloatValue(res['data'][i]['payment_amount']);\n }\n }\n } \n this.isDownLoadButtondisabled = false;\n this.xlFileService.exportAsExcelFile(res['data'], this.getFileName(this.reportsForm.get('selectedreport').value, selectedStartDate, selectedEndDate));\n },\n (error: any) => {\n this.isDownLoadButtondisabled = false;\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n })\n\n } else if(selectedReportName === 'PAYMENT_FAILURE_EVENT') {\n\n this.paymentViewService.downloadFailureReport(selectedStartDate,selectedEndDate).subscribe(\n response => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n const result = {data: JSON.parse(response)['payment_failure_report_list']};\n let res = {data: this.applyDateFormat(result)};\n if (result['data'].length > 0) {\n for ( var i=0; i< res['data'].length; i++) {\n if (res['data'][i][\"disputed_amount\"] !== undefined) {\n res['data'][i]['disputed_amount'] = this.convertToFloatValue(res['data'][i][\"disputed_amount\"]);\n }\n if (res['data'][i][\"representment_status\"] !== undefined) {\n res['data'][i]['representment_status'] = res['data'][i][\"representment_status\"].toLowerCase() === 'yes' ? 'Success' : 'Failure';\n }\n if (res['data'][i]['representment_status'] === undefined) {\n res['data'][i]['representment_status'] = 'No representment received';\n }\n if (res['data'][i]['representment_date'] === undefined) {\n res['data'][i]['representment_date'] = 'N/A';\n }\n if (res['data'][i]['refund_reference'] === undefined) {\n res['data'][i]['refund_reference'] = 'No refund available';\n }\n if (res['data'][i]['refund_amount'] === undefined) {\n res['data'][i]['refund_amount'] = 'N/A';\n }\n if (res['data'][i]['refund_date'] === undefined) {\n res['data'][i]['refund_date'] = 'N/A';\n }\n if (res['data'][i]['document_control_number'] === undefined) {\n res['data'][i]['document_control_number'] = 'N/A';\n }\n }\n }\n this.isDownLoadButtondisabled = false;\n this.xlFileService.exportAsExcelFile(res['data'], this.getFileName(this.reportsForm.get('selectedreport').value, selectedStartDate, selectedEndDate ));\n\n },\n (error: any) => {\n this.isDownLoadButtondisabled = false;\n const errorContent = error.replace(/[^a-zA-Z ]/g, '').trim();\n const statusCode = error.replace(/[^a-zA-Z0-9 ]/g, '').trim().split(' ')[0];\n if(statusCode === '404') {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, true, errorContent);\n }else {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n })\n\n } else {\n this.bulkScaningPaymentService.downloadSelectedReport(selectedReportName,selectedStartDate,selectedEndDate).subscribe(\n response => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n const result = JSON.parse(response);\n let res = {data: this.applyDateFormat(result)};\n if(res['data'].length === 0 && selectedReportName === 'DATA_LOSS' ){\n res.data= dataLossRptDefault;\n } else if(res['data'].length === 0 && selectedReportName === 'UNPROCESSED'){\n res.data = unProcessedRptDefault;\n }\n if(result['data'].length > 0) {\n for( var i=0; i< res['data'].length; i++) {\n if(res['data'][i][\"amount\"] !== undefined) {\n res['data'][i]['amount'] = this.convertToFloatValue(res['data'][i]['amount']);\n }\n if(res['data'][i][\"payment_asset_dcn\"] !== undefined) {\n res['data'][i]['env_ref'] = res['data'][i][\"payment_asset_dcn\"].substr(0,13);\n res['data'][i]['env_item'] = res['data'][i][\"payment_asset_dcn\"].substr(13,21);\n }\n }\n }\n this.isDownLoadButtondisabled = false;\n this.xlFileService.exportAsExcelFile(res['data'], this.getFileName(this.reportsForm.get('selectedreport').value, selectedStartDate, selectedEndDate ));\n },\n (error: any) => {\n this.isDownLoadButtondisabled = false;\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n })\n }\n }\n\n getFileName(selectedOption: string, startDate: string, endDate: string ) {\n const loc = 'en-US',\n stDt = formatDate(startDate, 'ddMMyy', loc),\n enDt = formatDate(endDate, 'ddMMyy', loc),\n now = new Date(),\n currentDate = formatDate(now, 'ddMMyy', loc),\n timestamp = `${currentDate}_${this.getTwodigit(now.getHours())}${this.getTwodigit(now.getMinutes())}${this.getTwodigit(now.getSeconds())}`,\n selectedOptionTxt = this.getCamelCaseString(selectedOption);\n \n return selectedOptionTxt+'_'+stDt+'_To_'+enDt+'_Run_'+ timestamp;\n } \n tranformDate(strDate: string) {\n let result = '';\n if (strDate) {\n let parts = strDate.split('-');\n result = `${parts[1]}/${parts[2]}/${parts[0]}`;\n }\n return result;\n }\n getTwodigit(input: number){\n return (\"0\" + input).slice(-2);\n }\n getCamelCaseString(selectedOption) {\n let result;\n switch(selectedOption) { \n case 'UNPROCESSED': { \n result = 'Unprocessed';\n break; \n } \n case 'DATA_LOSS': { \n result = 'Data_Loss';\n break; \n } \n case 'PROCESSED_UNALLOCATED': { \n result = 'Processed_Unallocated';\n break; \n } \n case 'SURPLUS_AND_SHORTFALL': { \n result = 'Over Payment_Under Payment';\n break; \n } \n case 'PAYMENT_FAILURE_EVENT': { \n result = 'Payment failure event';\n break; \n }\n default: { \n result = selectedOption;\n break; \n } \n } \n return result;\n }\n applyDateFormat(res) {\n return res['data'].map(value => {\n if (value['date_banked']) {\n value['date_banked'] = formatDate(value['date_banked'], this.fmt, this.loc);\n }\n if (value['event_date'] && value['event_date'].indexOf(',') === -1) {\n value['event_date'] = formatDate(value['event_date'], this.fmt, this.loc);\n } else if (value['event_date'] && value['event_date'].indexOf(',') !== -1) {\n value['event_date'] = this.multiDateFormater(value['event_date'])\n }\n\n if (value['representment_date'] && value['representment_date'].indexOf(',') === -1) {\n value['representment_date'] = formatDate(value['representment_date'], this.fmt, this.loc);\n } else if (value['representment_date'] && value['representment_date'].indexOf(',') !== -1) {\n value['representment_date'] = this.multiDateFormater(value['representment_date'])\n }\n\n if (value['refund_date'] && value['refund_date'].indexOf(',') === -1) {\n value['refund_date'] = formatDate(value['refund_date'], this.fmt, this.loc);\n } else if (value['refund_date'] && value['refund_date'].indexOf(',') !== -1) {\n value['refund_date'] = this.multiDateFormater(value['refund_date'])\n }\n return value;\n });\n }\n multiDateFormater(dateStr) {\n return dateStr.split(',').map((date) => formatDate(date, this.fmt, this.loc)).join(',');\n }\n \n convertToFloatValue(amt) {\n return amt ? Number.parseFloat(amt).toFixed(2): '0.00';\n }\n}\n","import {Component, ViewChild, Input, ChangeDetectorRef} from '@angular/core';\nimport {PaymentLibComponent} from '../../payment-lib.component';\nimport { MatTableDataSource} from '@angular/material/table';\nimport {MatSort } from '@angular/material/sort';\nimport {Sort } from '@angular/material/sort';\nimport {MatPaginator } from '@angular/material/paginator';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { THIS_EXPR } from '@angular/compiler/src/output/output_ast';\nimport { ActivatedRoute,Router } from '@angular/router';\n@Component({\n selector: 'ccpay-table',\n templateUrl: './table.component.html',\n styleUrls: ['./table.component.css']\n})\nexport class TableComponent {\n @Input('DATASOURCE') DATASOURCE: any[];\n @Input('STATUS') STATUS: string;\n @Input('errorMessage') errorMessage: string;\n isApprovalFlow: boolean;\n // displayedColumns = ['ccdCaseNumber', 'refundReference', 'reason', 'createBy', 'updateDate', 'Action'];\n displayedColumns = ['ccd_case_number', 'refund_reference', 'user_full_name','date_created', 'date_updated', 'Action'];\n \n dataSource: MatTableDataSource<any>;\n userLst;\n serviceLst;\n actualcount: number;\n count: number;\n refundList: IRefundList[];\n @ViewChild(MatPaginator) paginator: MatPaginator;\n @ViewChild(MatSort) sort: MatSort;\n constructor(\n private paymentLibComponent: PaymentLibComponent,\n private cdRef: ChangeDetectorRef,\n private OrderslistService: OrderslistService,\n private router: Router,\n private activeRoute: ActivatedRoute\n ) {}\n ngOnInit() {\n this.errorMessage = this.errorMessage;\n if(this.STATUS.toLowerCase() === 'sent for approval') {\n this.isApprovalFlow = true;\n } else {\n this.isApprovalFlow = false;\n }\n this.refundList = this.DATASOURCE;\n this.dataSource = new MatTableDataSource(this.refundList);\n this.actualcount = this.dataSource.data.length;\n if( this.refundList !== undefined) {\n this.userLst = this.refundList.reduce((r,{user_full_name}) => (r[user_full_name]='', r) , {});\n this.userLst = Object.keys(this.userLst);\n this.userLst.sort((a, b) => a.toString().localeCompare(b));\n this.serviceLst = this.refundList.reduce((r,{service_type}) => (r[service_type]='', r) , {});\n this.serviceLst = Object.keys(this.serviceLst);\n this.serviceLst.sort((a, b) => a.toString().localeCompare(b));\n }\n \n }\n \n /**\n * Set the paginator and sort after the view init since this component will\n * be able to query its view for the initialized paginator and sort.\n */\n ngAfterViewInit() {\n \n this.dataSource.sort = this.sort;\n\n //const sortState: Sort = {active: 'date_updated', direction: 'desc'};\n // this.sort.active = sortState.active;\n // this.sort.direction = sortState.direction;\n // this.sort.sortChange.emit(sortState);\n this.dataSource.paginator = this.paginator;\n this.dataSource.sort = this.sort;\n this.cdRef.detectChanges();\n }\n applyFilter(filterValue: string) {\n filterValue = filterValue.trim(); // Remove whitespace\n filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches\n this.dataSource.filter = filterValue;\n }\n selectchange(args){\n this.dataSource.filter = args.target.value;\n this.actualcount = this.dataSource.data.length;\n this.dataSource.paginator = this.paginator;\n }\n goToRefundProcessComponent(refundReference: string, refundData: IRefundList ) {\n this.paymentLibComponent.refundlistsource = refundData;\n this.paymentLibComponent.refundReference = refundReference;\n this.paymentLibComponent.viewName = 'process-refund';\n }\n goToRefundViewComponent(refundReference: string, refundData: IRefundList ) {\n this.OrderslistService.setRefundView(refundData);\n this.paymentLibComponent.viewName='refundstatuslist';\n this.paymentLibComponent.CCD_CASE_NUMBER = refundData.ccd_case_number;\n this.paymentLibComponent.isRefundStatusView = true;\n this.paymentLibComponent.isCallFromRefundList = true;\n }\n goToCaseReview(ccdCaseNumber: string, refundData: IRefundList ) {\n this.router.navigate([`/cases/case-details/${ccdCaseNumber}`], {relativeTo: this.activeRoute});\n }\n}","import { IRefundContactDetails } from './IRefundContactDetails';\n\nexport class IPutNotificationRequest {\n recipient_email_address?: string;\n recipient_postal_address?: IRefundContactDetails\n \n constructor(contactDetails: any, notificationType: string) {\n if(notificationType === 'EMAIL') {\n this.recipient_email_address = contactDetails;\n } else if(notificationType === 'LETTER') {\n this.recipient_postal_address = contactDetails;\n }\n } \n}","import { IFee } from \"./IFee\";\nimport { IRefundContactDetails } from \"./IRefundContactDetails\";\nexport class IResubmitRefundRequest {\n refund_reason: string;\n amount: number;\n contact_details: IRefundContactDetails;\n refund_fees: IFee[];\n \n constructor(refund_reason : string, amount: number,contact_details:any,refund_fees: any[]) {\n this.refund_reason= refund_reason;\n this.amount = amount;\n this.contact_details = contact_details;\n this.refund_fees = refund_fees;\n } \n }\n ","import { Component, OnInit, Input } from '@angular/core';\nimport { RefundsService } from '../../services/refunds/refunds.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { IRefundsNotifications } from '../../interfaces/IRefundsNotifications';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IPutNotificationRequest } from '../../interfaces/IPutNotificationRequest';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { IRefundStatus } from '../../interfaces/IRefundStatus';\nimport { IResubmitRefundRequest } from '../../interfaces/IResubmitRefundRequest';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IFee } from '../../interfaces/IFee';\nimport { IRefundFee } from '../../interfaces/IRefundFee';\n\n@Component({\n selector: 'ccpay-refund-status',\n templateUrl: './refund-status.component.html',\n styleUrls: ['./refund-status.component.css']\n})\nexport class RefundStatusComponent implements OnInit {\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[] = [];\n @Input('API_ROOT') API_ROOT: string;\n @Input() ccdCaseNumber: string;\n @Input() isTurnOff: boolean;\n @Input() orderParty: string;\n refundStatusForm: FormGroup;\n selectedRefundReason: string;\n rejectedRefundList: IRefundList[] = [];\n notificationList: any;\n notification:any;\n approvalStatus = 'Sent for approval';\n rejectStatus = 'Update required';\n errorMessage = null;\n viewName: string;\n refundReason: string;\n refundlist: IRefundList;\n bsPaymentDcnNumber: string;\n isCallFromRefundList: boolean;\n refundButtonState: string = '';\n isAmountEmpty: boolean = false;\n isReasonEmpty: boolean = false;\n amountHasError: boolean = false;\n isRemissionLessThanFeeError: boolean = false;\n refundHasError: boolean = false;\n refundReasons: any[] = [];\n refundStatusHistories: IRefundStatus[];\n refundNotifications: IRefundStatus[];\n isResendOperationSuccess: boolean = false;\n isEditDetailsClicked: boolean = false;\n isEditAddressDeatilsClicked: boolean = false;\n addressDetails: IRefundContactDetails;\n refundReference: string;\n refundAmount: string;\n refundCode: string;\n isRefundBtnDisabled: boolean = true;\n isFromPayBubble: boolean = false;\n oldRefundReason: string;\n refundreason: string;\n navigationpage: string;\n isLastUpdatedByCurrentUser: boolean = true;\n isProcessRefund: boolean = false;\n changedAmount: number;\n isRemissionsMatch: boolean;\n payment: IPayment;\n changeRefundReason: string;\n fees: IFee [];\n refundFees: IRefundFee[];\n paymentObj: IPayment;\n templateInstructionType: string;\n notificationSentViewIndex: number = -1;\n notificationPreview: boolean = false;\n notificationSentView: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund', 'payments'];\n\n constructor(private formBuilder: FormBuilder,\n private refundService: RefundsService,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private OrderslistService: OrderslistService,\n private paymentViewService: PaymentViewService) { }\n\n ngOnInit() {\n\n this.resetRemissionForm([false, false, false, false], 'All');\n this.bsPaymentDcnNumber = this.paymentLibComponent.bspaymentdcn;\n this.isCallFromRefundList = this.paymentLibComponent.isCallFromRefundList;\n if(this.API_ROOT == 'api/payment-history') {\n this.isFromPayBubble = true;\n }\n if (this.paymentLibComponent.isRefundStatusView) {\n this.viewName = 'refundview';\n this.OrderslistService.getRefundView().subscribe((data) => this.refundlist = data);\n this.OrderslistService.getCCDCaseNumberforRefund.subscribe((data) => this.ccdCaseNumber = data);\n } else {\n this.viewName = 'refundstatuslist';\n this.refundService.getRefundStatusList(this.ccdCaseNumber).subscribe(\n refundList => {\n this.rejectedRefundList = refundList['refund_list'];\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g, \"\");\n };\n }\n\n\n this.refundStatusForm = this.formBuilder.group({\n amount: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[0-9]+(\\.[0-9]{1,2})?$')\n ])),\n refundReason: new FormControl('', Validators.compose([Validators.required])),\n reason: new FormControl()\n });\n\n if(this.refundlist !== undefined) {\n this.getRefundsNotification();\n this.getRefundsStatusHistoryList();\n\n if (this.LOGGEDINUSERROLES.some(i => i.includes('payments-refund-approver'))) {\n this.isProcessRefund = true;\n this.refundButtonState = this.refundlist.refund_status.name;\n return;\n }\n\n if (this.LOGGEDINUSERROLES.some(i => i.includes('payments-refund'))) {\n this.isProcessRefund = false;\n this.refundButtonState = this.refundlist.refund_status.name;\n }\n }\n \n }\n\n getRefundsStatusHistoryList() {\n if(this.refundlist !== undefined) {\n this.refundService.getRefundStatusHistory(this.refundlist.refund_reference).subscribe(\n statusHistoryList => {\n this.refundStatusHistories = statusHistoryList.status_history_dto_list;\n this.isLastUpdatedByCurrentUser = statusHistoryList.last_updated_by_current_user;\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n };\n }\n }\n\n getRefundsNotification() {\n this.notificationService.getRefundNotification(this.refundlist.refund_reference).subscribe(\n refundsNotification => {\n this.notificationList = refundsNotification['notifications'];\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n }; \n }\n\n goToRefundView(refundlist: IRefundList, navigationpage: string) {\n this.OrderslistService.setRefundView(refundlist);\n this.OrderslistService.setCCDCaseNumber(this.ccdCaseNumber);\n this.paymentLibComponent.viewName = 'refundstatuslist';\n this.paymentLibComponent.isRefundStatusView = true;\n this.refundlist = refundlist;\n this.OrderslistService.setnavigationPage(navigationpage);\n }\n\n loadCaseTransactionPage() {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n }\n\n loadRefundListPage() {\n this.OrderslistService.getnavigationPageValue().subscribe((data) => this.navigationpage = data);\n if (this.navigationpage === 'casetransactions') {\n this.loadCaseTransactionPage();\n } else {\n this.paymentLibComponent.viewName = 'refund-list';\n }\n }\n\n gotoReviewDetailsPage(event:any) {\n // event.preventDefault();\n this.errorMessage = false;\n this.paymentLibComponent.isRefundStatusView = true;\n this.ngOnInit();\n }\n\n gotoReviewAndReSubmitPage() {\n this.viewName = 'reviewandsubmitview';\n this.getTemplateInstructionType(this.paymentObj, this.refundlist.payment_reference);\n this.oldRefundReason = this.refundlist.reason;\n this.changedAmount = this.refundlist.amount;\n this.refundreason = this.refundStatusHistories.filter(data => data.status.toLowerCase() === 'update required')[0].notes;\n this.refundService.getRefundReasons().subscribe(\n refundReasons => {\n this.refundReasons = refundReasons;\n });\n }\n gotoRefundReasonPage(refundReason:string) {\n this.isRefundBtnDisabled = false;\n this.paymentLibComponent.REFUNDLIST = \"true\";\n this.paymentLibComponent.isFromRefundStatusPage = true;\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.errorMessage = false;\n this.changeRefundReason = refundReason;\n this.viewName = 'issuerefundpage1';\n }\n\n gotoAmountPage() {\n this.errorMessage = false;\n this.paymentLibComponent.REFUNDLIST = \"true\";\n this.isRefundBtnDisabled = false;\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.paymentLibComponent.isFromRefundStatusPage = true;\n if(this.refundlist.reason == 'Retrospective remission') {\n this.viewName = 'processretroremissonpage';\n } else {\n this.viewName = 'issuerefund';\n }\n }\n\n goToReviewAndSubmitView() {\n const remissionctrls = this.refundStatusForm.controls\n if (this.refundStatusForm.dirty) {\n if (remissionctrls['amount'].value == '') {\n this.resetRemissionForm([true, false, false, false], 'amount');\n }\n else if (remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid) {\n this.resetRemissionForm([false, true, false, false], 'amount');\n }\n else if (remissionctrls['reason'].value == '') {\n this.resetRemissionForm([false, false, false, true], 'reason');\n } else {\n this.refundlist.reason = remissionctrls['reason'].value;\n this.viewName = 'reviewandsubmitview';\n }\n }\n\n }\n\n resetRemissionForm(val, field) {\n if (field === 'All') {\n this.isAmountEmpty = val[0];\n this.amountHasError = val[1];\n this.isRemissionLessThanFeeError = val[2];\n this.isReasonEmpty = val[3];\n } else if (field === 'amount' || field === 'All') {\n this.isAmountEmpty = val[0];\n this.amountHasError = val[1];\n this.isRemissionLessThanFeeError = val[2];\n } else if (field === 'reason' || field === 'All') {\n this.isReasonEmpty = val[3];\n }\n }\n\n selectRadioButton(key, value) {\n this.refundHasError = false;\n this.selectedRefundReason = key;\n if (key === 'Other') {\n this.refundHasError = false;\n this.refundReason = key;\n }\n }\n\n getRefundListReason(refundListReason: any) {\n if (this.paymentLibComponent.isFromRefundStatusPage && !this.paymentLibComponent.iscancelClicked) {\n if(refundListReason.reason != undefined && refundListReason.reason != null && refundListReason.reason != this.refundlist.reason){\n this.refundlist.reason = refundListReason.reason;\n this.refundlist.reason_code = refundListReason.code.split('-')[0].trim();\n this.refundlist.code = refundListReason.code;\n this.refundCode = refundListReason.code;\n }\n } else {\n this.isRefundBtnDisabled = true;\n }\n this.notificationPreview = false;\n this.viewName = 'reviewandsubmitview';\n this.paymentLibComponent.CCD_CASE_NUMBER = this.ccdCaseNumber;\n }\n\n getRefundAmount(amount: number) {\n if (this.paymentLibComponent.isFromRefundStatusPage && !this.paymentLibComponent.iscancelClicked) {\n if (amount > 0) {\n this.changedAmount = amount;\n // this.refundlist.amount = amount;\n }\n } else {\n this.isRefundBtnDisabled = true;\n }\n this.notificationPreview = false;\n this.viewName = 'reviewandsubmitview';\n this.paymentLibComponent.CCD_CASE_NUMBER = this.ccdCaseNumber;\n }\n\n getRefundFees(fees: IFee[])\n {\n this.fees = fees;\n this.refundFees = this.fees.map(obj => ({\n fee_id: obj.id,\n code: obj.code,\n version: obj.version,\n volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n refund_amount: obj.refund_amount\n }));\n }\n\n gotoReviewRefundConfirmationPage() {\n // if (this.oldRefundReason === this.refundlist.reason) {\n // this.refundCode = '';\n // }\n if (this.refundFees === undefined) {\n this.refundFees = this.refundlist['refund_fees'];\n }\n if(this.refundlist.reason == 'Retrospective remission') {\n this.refundFees[0].refund_amount = this.changedAmount;\n }\n this.refundCode = this.refundlist.code;\n const resubmitRequest = new IResubmitRefundRequest(this.refundCode, this.changedAmount, this.refundlist.contact_details, this.refundFees);\n this.refundService.patchResubmitRefund(resubmitRequest, this.refundlist.refund_reference).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n this.viewName = 'reviewrefundconfirmationpage';\n }\n },\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n }\n );\n }\n\n gotoEditAddressDetails(note: IRefundsNotifications) {\n this.notification = note;\n this.isEditDetailsClicked = true;\n this.viewName = 'refundEditView'\n }\n getContactDetails(obj:IRefundContactDetails) {\n this.addressDetails = obj;\n this.getTemplateInstructionType(this.paymentObj,this.refundlist.payment_reference);\n this.notificationPreview = false;\n this.viewName = 'revieweditdetailsconfirmationpage';\n }\n getContactDetailsForRefundList(obj:IRefundContactDetails) {\n this.refundlist.contact_details = obj;\n this.getTemplateInstructionType(this.paymentObj,this.refundlist.payment_reference);\n this.notificationPreview = false;\n this.isEditDetailsClicked = false;\n this.isRefundBtnDisabled = false;\n this.viewName = 'reviewandsubmitview';\n }\n gotoEditDetailsPage(note?: any, view?: string) {\n if(note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.isEditDetailsClicked = true;\n this.viewName = view;\n }\n submitEditDetail() {\n this.isResendOperationSuccess = false;\n const contactDetails = this.addressDetails.notification_type === 'EMAIL' ? this.addressDetails.email :\n {\n address_line: this.addressDetails.address_line,\n city: this.addressDetails.city,\n county: this.addressDetails.county,\n country: this.addressDetails.country,\n postal_code: this.addressDetails.postal_code,\n };\n const resendRequest = new IPutNotificationRequest(contactDetails, this.addressDetails.notification_type);\n\n this.refundService.putResendOrEdit(resendRequest, this.refundlist.refund_reference, this.addressDetails.notification_type).subscribe(\n (response) => {\n this.isResendOperationSuccess = response;\n },\n (error: any) => {\n this.isResendOperationSuccess = false;\n this.errorMessage = error.replace(/\"/g,\"\");\n }\n );\n }\n putResend(notification: IRefundsNotifications) {\n this.isResendOperationSuccess = false;\n const contactDetails = notification.notification_type === 'EMAIL' ? notification.contact_details.email :\n {\n address_line :notification.contact_details.address_line,\n city: notification.contact_details.city,\n county: notification.contact_details.county,\n country: notification.contact_details.country,\n postal_code: notification.contact_details.postal_code,\n };\n const resendRequest = new IPutNotificationRequest(contactDetails, notification.notification_type);\n\n this.refundService.putResendOrEdit(resendRequest, this.refundlist.refund_reference, notification.notification_type).subscribe(\n (response) => {\n this.isResendOperationSuccess = response;\n },\n (error: any) => {\n this.isResendOperationSuccess = false;\n this.errorMessage = error.replace(/\"/g,\"\");\n }\n );\n\n }\n\n gotoRefundViewPageCancelBtnClicked(event: Event) {\n event.preventDefault();\n this.isEditDetailsClicked = false;\n this.viewName = 'refundview';\n }\n\n gotoRefundReviewAndSubmitViewPageCancelBtnClicked(event: Event) {\n event.preventDefault();\n this.isEditDetailsClicked = false;\n this.viewName = 'reviewandsubmitview';\n }\n\n goToRefundProcessComponent(refundReference: string, refundList: IRefundList) {\n this.paymentLibComponent.refundlistsource = refundList;\n this.paymentLibComponent.refundReference = refundReference;\n this.paymentLibComponent.isFromPayBubble = true;\n this.paymentLibComponent.viewName = 'process-refund';\n }\n\n getTemplateInstructionType(payment: IPayment, paymentReference: string): void {\n\n if (payment == undefined || payment == null || payment.reference != paymentReference) {\n\n this.paymentViewService.getPaymentDetails(paymentReference).subscribe(\n payment => {\n this.paymentObj = payment;\n this.paymentObj.reference = paymentReference;\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(this.paymentObj.channel, this.paymentObj.method);\n },\n (error: any) => {\n this.templateInstructionType = 'Template';\n })\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n\n showNotificationSentView(index: number): void {\n this.notificationSentViewIndex = index;\n this.notificationSentView = true;\n }\n\n hideNotificationSentView(): void {\n this.notificationSentViewIndex = -1;\n this.notificationSentView = false;\n }\n\n}\n","import { THIS_EXPR } from '@angular/compiler/src/output/output_ast';\nimport { Component, Input, OnInit, Output, EventEmitter, ChangeDetectorRef } from '@angular/core';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { IPaymentView } from '../../interfaces/IPaymentView';\nimport { IOrderReferenceFee } from '../../interfaces/IOrderReferenceFee';\nimport { IFee } from '../../interfaces/IFee';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { Router } from '@angular/router';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\n\n@Component({\n selector: 'ccpay-service-request',\n templateUrl: './service-request.component.html',\n styleUrls: ['./service-request.component.scss']\n})\nexport class ServiceRequestComponent implements OnInit {\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[];\n @Input('viewStatus') viewStatus: string;\n @Input('orderDetail') orderDetail: any[];\n @Input('orderRef') orderRef: string;\n @Input('orderStatus') orderStatus: string;\n @Input('orderParty') orderParty: string;\n @Input('orderCreated') orderCreated: Date;\n @Input('orderCCDEvent') orderCCDEvent: string;\n @Input('orderFeesTotal') orderFeesTotal: number;\n @Input('orderTotalPayments') orderTotalPayments: number;\n @Input('orderRemissionTotal') orderRemissionTotal: number;\n @Input('paymentGroupList') paymentGroupList: IPaymentGroup;\n @Input('takePayment') takePayment: boolean;\n @Input('ccdCaseNumber') ccdCaseNumber: boolean;\n @Input(\"isServiceRequest\") isServiceRequest: string;\n @Output() goToServiceRquestComponent: EventEmitter<any> = new EventEmitter();\n\n viewCompStatus;\n servicerequest: string;\n paymentType: string;\n excReference: string;\n paymentGroups: any[] = [];\n payments: IPayment[] = [];\n nonPayments: IPayment[] = [];\n allPayments: IPayment[] = [];\n remissions: IRemission[] = [];\n paymentFees: IFee[];\n fees: any;\n errorMessage: string;\n totalFees: number;\n totalPayments: number;\n totalNonOffPayments: number;\n totalRemissions: number;\n selectedOption: string;\n dcnNumber: string;\n paymentRef: string;\n isTurnOff: boolean;\n isRefundRemission: boolean = true;\n isStrategicFixEnable: boolean;\n isAddFeeBtnEnabled: boolean = true;\n isExceptionRecord: boolean = false;\n isUnprocessedRecordSelected: boolean = false;\n exceptionRecordReference: string;\n isAnyFeeGroupAvilable: boolean = true;\n isHistoricGroupAvailable: boolean = false;\n isBulkScanEnable;\n isRemissionsMatch: boolean;\n isRemoveBtnDisabled: boolean = false;\n feeId: IFee;\n clAmountDue: number = 0;\n unprocessedRecordCount: number;\n isFeeRecordsExist: boolean = false;\n isGrpOutstandingAmtPositive: boolean = false;\n totalRefundAmount: Number;\n caseType: String;\n isConfirmationBtnDisabled: boolean;\n refundReference: string;\n refundAmount: string;\n payment: IPayment;\n paymentGroup: IPaymentGroup;\n paymentView: IPaymentView;\n\n isAddRemissionEnable: boolean = false;\n orderRemissionDetails: any[] = [];\n orderLevelFees: IOrderReferenceFee[] = [];\n cpoDetails: any []= [];\n serviceRequestValue: string;\n orderAddBtnEnable: boolean;\n isFromPaymentDetailPage: boolean;\n contactDetailsObj: IRefundContactDetails\n notification: any;\n isCPODown: boolean;\n test: boolean;\n isPBA: boolean = false;\n isIssueRefunfBtnEnable: boolean = false;\n isAddRemissionBtnEnabled: boolean = false;\n isRefundRemissionBtnEnable: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund'];\n isFromServiceRequestPage: boolean;\n navigationpage: string;\n remissionFeeAmt: number;\n isContinueBtnDisabled: boolean = true;\n isFullyRefund: boolean;\n templateInstructionType: string;\n notificationPreview: boolean;\n\n constructor(\n private paymentLibComponent: PaymentLibComponent,\n private paymentViewService: PaymentViewService,\n private OrderslistService: OrderslistService,\n private notificationService: NotificationService,\n private cd: ChangeDetectorRef,\n private router: Router) { }\n\n ngOnInit() {\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.isServiceRequest = 'false';\n if (this.viewStatus === undefined) {\n this.viewStatus = this.paymentLibComponent.viewName;\n }\n if(this.paymentLibComponent.isFromServiceRequestPage && this.paymentLibComponent.isFromPaymentDetailPage) {\n this.OrderslistService.getorderRefs().subscribe((data) => this.orderRef = data);\n this.OrderslistService.getorderCCDEvents().subscribe((data) => this.orderCCDEvent = data);\n this.OrderslistService.getorderCreateds().subscribe((data) => this.orderCreated = data);\n this.OrderslistService.getorderDetail().subscribe((data) => this.orderDetail = data);\n this.OrderslistService.getorderPartys().subscribe((data) => this.orderParty = data);\n this.OrderslistService.getorderRemissionTotals().subscribe((data) => this.orderRemissionTotal = data);\n this.OrderslistService.getorderFeesTotals().subscribe((data) => this.orderFeesTotal = data);\n this.OrderslistService.getoorderTotalPaymentss().subscribe((data) => this.orderTotalPayments = data);\n }\n if(this.paymentLibComponent.isFromServiceRequestPage && this.paymentLibComponent.TAKEPAYMENT) {\n this.isServiceRequest = 'false';\n }\n\n }\n goToServiceRequestPage() {\n this.goToServiceRquestComponent.emit();\n }\n\n goToCaseTransationPage(event: any) {\n event.preventDefault();\n this.OrderslistService.setnavigationPage('servicerequestpage');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isTakePayment = this.paymentLibComponent.TAKEPAYMENT;\n if (this.takePayment) {\n this.paymentLibComponent.isTakePayment = this.takePayment;\n }\n //this.paymentLibComponent.SERVICEREQUEST = \"true\";\n this.paymentLibComponent.isFromServiceRequestPage = false;\n if(this.isServiceRequest !== 'false') {\n this.paymentLibComponent.isFromServiceRequestPage = true;\n }\n this.paymentLibComponent.isFromRefundStatusPage = false;\n this.paymentLibComponent.viewName = 'case-transactions';\n this.resetOrderData();\n\n // Check we on XUI\n if(this.router.url.startsWith('/cases/case-details/')) {\n // Use ccpay-case-transactions component\n this.viewStatus = 'case-transactions';\n } else {\n // Reload Paybubble case-transactions page.\n let partUrl = this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl += this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n if(this.isServiceRequest === 'false') {\n partUrl += this.paymentLibComponent.TAKEPAYMENT ? '&takePayment=true' : '&takePayment=false';\n }\n partUrl += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl += this.isServiceRequest !== 'false' ? '&servicerequest=true' : '&servicerequest=false';\n partUrl += `&caseType=${this.paymentLibComponent.CASETYPE}`;\n const url = `/payment-history/${this.paymentLibComponent.CCD_CASE_NUMBER}?view=case-transactions&selectedOption=${this.paymentLibComponent.SELECTED_OPTION}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n }\n }\n\n addRemission(fee: IFee) {\n if(this.chkIsAddRemissionBtnEnable(fee)) {\n this.feeId = fee;\n this.viewStatus = 'addremission';\n this.payment = this.orderDetail[0].payments[0];\n this.paymentViewService.getApportionPaymentDetails(this.orderDetail[0].payments[0].reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n this.payment = this.paymentGroup.payments[0];\n\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n\n },\n (error: any) => this.errorMessage = error.replace(/\"/g,\"\")\n );\n }\n }\n\n addRefundForRemission(payment: IPayment, remission: IRemission[],fees:any) {\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj.reference === payment.reference);\n this.payment = this.paymentGroup.payments[0];\n this.remissions = remission;\n this.remissionFeeAmt = fees.filter(data=>data.code === this.remissions['fee_code'])[0].net_amount;\n this.viewStatus = 'addrefundforremission';\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error\n );\n }\n cancelRemoval() {\n this.viewStatus = 'main';\n }\n\n removeFee(fee: any) {\n this.isRemoveBtnDisabled = true;\n this.paymentViewService.deleteFeeFromPaymentGroup(fee).subscribe(\n (success: any) => {\n window.location.reload();\n },\n (error: any) => {\n this.errorMessage = error;\n this.isRemoveBtnDisabled = false;\n }\n );\n }\n\n issueRefund(payment: IPayment) {\n if (payment !== null && payment !== undefined) {\n if( this.chkIsIssueRefundBtnEnable(payment)) {\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n paymentGroup.payments = paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(payment.reference));\n if(payment.over_payment > 0) {\n this.viewStatus = '';\n this.payment = payment;\n this.paymentGroupList = paymentGroup;\n this.viewCompStatus = 'overpayment';\n } else {\n this.viewStatus = 'issuerefund';\n this.viewCompStatus = '';\n this.paymentFees = paymentGroup.fees;\n this.payment = payment;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.isRefundRemission = true;\n }\n },\n (error: any) => this.errorMessage = error\n );\n }\n }\n }\n\n goToPayementView(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.goToPaymentViewComponent({ paymentGroupReference, paymentReference, paymentMethod });\n }\n\n goToPaymentViewComponent(paymentGroup: any) {\n this.paymentLibComponent.paymentMethod = paymentGroup.paymentMethod;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.paymentLibComponent.paymentGroupReference = paymentGroup.paymentGroupReference;\n this.paymentLibComponent.paymentReference = paymentGroup.paymentReference;\n this.OrderslistService.setOrderRef(this.orderRef);\n this.OrderslistService.setorderCCDEvent(this.orderCCDEvent);\n this.OrderslistService.setorderCreated(this.orderCreated);\n this.OrderslistService.setorderDetail(this.orderDetail);\n this.OrderslistService.setorderParty(this.orderParty);\n this.OrderslistService.setorderTotalPayments(this.orderTotalPayments);\n this.OrderslistService.setorderRemissionTotal(this.orderRemissionTotal);\n this.OrderslistService.setorderFeesTotal(this.orderFeesTotal);\n this.viewStatus = 'payment-view';\n }\n\n chkIsIssueRefundBtnEnable(payment: IPayment): boolean {\n if (payment !== null && payment !== undefined) {\n return payment.issue_refund && payment.refund_enable\n } else {\n return false;\n }\n }\n\n chkIsAddRefundBtnEnable(remission: IRemission): boolean {\n if (remission !== null && remission !== undefined) {\n return remission.add_refund;\n } else {\n return false;\n }\n }\n\n chkIsAddRemissionBtnEnable(fee: IFee): boolean {\n if (fee !== null && fee !== undefined) {\n return fee.add_remission && fee.remission_enable;\n } else {\n return false\n }\n }\n resetOrderData() {\n this.OrderslistService.setOrderRef(null);\n this.OrderslistService.setorderCCDEvent(null);\n this.OrderslistService.setorderCreated(null);\n this.OrderslistService.setorderDetail(null);\n this.OrderslistService.setorderParty(null);\n this.OrderslistService.setorderTotalPayments(null);\n this.OrderslistService.setorderRemissionTotal(null);\n this.OrderslistService.setorderFeesTotal(null);\n }\n\n selectPymentOption(paymentType: string) {\n this.paymentType = paymentType;\n this.isContinueBtnDisabled = false;\n }\n goToPaymentViewComp() {\n this.viewCompStatus = '';\n this.viewStatus = 'paymentview';\n }\n continuePayment(paymentgrp: IPaymentGroup) {\n\n if (this.paymentType === 'op') {\n this.isFullyRefund = false\n this.viewStatus = '';\n this.viewCompStatus = 'overPaymentAddressCapture';\n } else if(this.paymentType === 'fp') {\n this.isFullyRefund = true\n this.paymentGroupList = paymentgrp;\n this.viewStatus = 'issuerefund';\n this.viewCompStatus = \"\";\n this.isRefundRemission = true;\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.isFromPaymentDetailPage = true;\n this.isFromServiceRequestPage = this.paymentLibComponent.isFromServiceRequestPage;\n }\n }\n getContactDetails(obj:IRefundContactDetails) {\n this.contactDetailsObj = obj;\n this.viewStatus = '';\n this.viewCompStatus = 'overpaymentcheckandanswer';\n this.getTemplateInstructionType(this.paymentGroupList.payments[0]);\n this.notificationPreview = false;\n }\n gotoPaymentSelectPage(event: Event) {\n event.preventDefault();\n this.viewStatus = '';\n this.viewCompStatus = 'overpayment';\n }\n gotoAddressPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewStatus = '';\n this.viewCompStatus = 'overPaymentAddressCapture';\n }\n processRefund() {\n this.isConfirmationBtnDisabled = true;\n this.errorMessage = '';\n const obj = this.paymentGroupList.fees[0];\n this.fees = [{ id: obj.id,\n code: obj.code,\n version:obj.version,\n apportion_amount: obj.apportion_amount,\n calculated_amount: obj.calculated_amount,\n updated_volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n volume: obj.volume,\n refund_amount: this.getOverPaymentValue() }];\n const requestBody = new PostRefundRetroRemission(this.contactDetailsObj,this.fees, this.paymentGroupList.payments[0].reference, 'RR037',\n this.getOverPaymentValue(), 'op');\n this.paymentViewService.postRefundsReason(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n })\n }\n\n getOverPaymentValue() {\n let feesOverPayment = 0;\n this.paymentGroupList.fees.forEach(fee => {\n feesOverPayment += fee.over_payment;\n });\n return feesOverPayment > 0 ? feesOverPayment : this.paymentGroupList.payments[0].over_payment;\n\n }\n\n getTemplateInstructionType(payment: IPayment): void {\n\n if (payment == undefined || payment == null) {\n this.templateInstructionType = 'Template';\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n}\n","export class IserviceRequestCardPayment {\n amount: string\n currency: string\n language: string\n \n constructor(amount : string) {\n this.amount = amount;\n this.currency = 'GBP';\n this.language = 'string';\n } \n}\n ","export class IserviceRequestPbaPayment {\n account_number: string;\n amount: string\n currency: string\n customer_reference: string\n organisation_name: string\n \n constructor(account_number : string, amount : string, customer_reference: string, orgName: string) {\n this.account_number = account_number;\n this.amount = amount;\n this.currency = 'GBP';\n this.customer_reference = customer_reference;\n this.organisation_name = orgName;\n } \n}\n ","import { Component, OnInit, Input} from '@angular/core';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IserviceRequestCardPayment } from '../../interfaces/IserviceRequestCardPayment';\nimport { IserviceRequestPbaPayment } from '../../interfaces/IserviceRequestPbaPayment';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\n\n@Component({\n selector: 'ccpay-pba-payment',\n templateUrl: './pba-payment.component.html',\n styleUrls: ['./pba-payment.component.scss']\n})\nexport class PbaPaymentComponent implements OnInit {\n @Input() pbaPayOrderRef: any;\n viewStatus: string;\n pbaAccountList: string[];\n isPBAAccountHold: boolean = false;\n errorMsg: any;\n isCardPaymentSuccess: boolean = true;\n isInSufficiantFund: boolean = false;\n isPBAAccountNotExist: boolean = false;\n isPBAServerError: boolean = false;\n isGetPBAAccountSucceed: boolean = false;\n selectedPbaAccount: string = '';\n pbaAccountRef: string = '';\n isPbaAccountSelected: boolean = false;\n isCardPaymentSelected: boolean = false;\n isPBADropdownSelected: boolean = false;\n isContinueButtondisabled: boolean = true;\n isPBAAccountPaymentSuccess: boolean = false;\n pbaAccountrPaymentResult: any;\n orgName: string = '';\n\n constructor(private paymentLibComponent: PaymentLibComponent,\n private paymentViewService: PaymentViewService) {}\n\n ngOnInit() {\n this.pbaPayOrderRef = this.paymentLibComponent.pbaPayOrderRef;\n this.viewStatus = 'pba-payment';\n this.errorMsg = null;\n this.paymentViewService.getPBAaccountDetails()\n .subscribe(\n result => {\n this.isGetPBAAccountSucceed = true;\n this.orgName = result.organisationEntityResponse.name;\n this.pbaAccountList = result.organisationEntityResponse.paymentAccount;\n },\n error => {\n this.errorMsg = error;\n }\n );\n\n }\n selectpbaaccount(args) {\n if(args.currentTarget.id === 'pbaAccountNumber') {\n this.isPBADropdownSelected = true;\n this.selectedPbaAccount = args.target.value; \n }\n if(args.currentTarget.id === 'pbaAccountRef') {\n this.pbaAccountRef = args.target.value; \n }\n if(this.selectedPbaAccount !== '' && this.pbaAccountRef !== \"\") {\n this.isContinueButtondisabled = false;\n } else {\n this.isContinueButtondisabled = true;\n }\n }\n\n saveAndContinue() {\n\n if(this.isPbaAccountSelected) {\n this.isInSufficiantFund = false;\n this.isPBAAccountNotExist = false;\n this.isPBAServerError = false;\n this.isPBAAccountPaymentSuccess = false;\n this.isContinueButtondisabled = true;\n if ( this.pbaAccountList.indexOf(this.selectedPbaAccount) !== -1 ) {\n const requestBody = new IserviceRequestPbaPayment(\n this.selectedPbaAccount, this.pbaPayOrderRef.orderTotalFees, this.pbaAccountRef, this.orgName);\n\n setTimeout(() => {\n this.paymentViewService.postPBAaccountPayment(this.pbaPayOrderRef.orderRefId, requestBody)\n .subscribe(\n r => {\n try {\n this.pbaAccountrPaymentResult = JSON.parse(r);\n } catch(e) {\n this.pbaAccountrPaymentResult = r;\n }\n this.isPBAAccountPaymentSuccess = true;\n },\n e => {\n if(e.status == '402') {\n this.isInSufficiantFund = true;\n } else if(e.status == '410') {\n this.isPBAAccountNotExist = true;\n } else if(e.status == '412') {\n this.isPBAAccountHold = true;\n } else {\n this.isPBAServerError = true;\n }\n }\n );\n\n }, 5000);\n } else {\n this.isPBAServerError = true;\n }\n } else if (this.isCardPaymentSelected) {\n this.cardPayment();\n }\n\n }\n cardPayment() {\n this.isCardPaymentSuccess = true;\n const requestBody = new IserviceRequestCardPayment (\n this.pbaPayOrderRef.orderTotalFees);\n this.paymentViewService.postWays2PayCardPayment(this.pbaPayOrderRef.orderRefId, requestBody)\n .subscribe(\n result => {\n const paymentUrl = JSON.parse(result).next_url;\n window.location.href = paymentUrl;\n },\n error => {\n this.isCardPaymentSuccess = false;\n }\n );\n\n }\n selectPaymentMethod(type: string) {\n if(type === 'PBA') {\n this.isPbaAccountSelected = true;\n this.isCardPaymentSelected = false;\n this.isPBADropdownSelected = false\n this.isContinueButtondisabled = true;\n this.selectedPbaAccount = null;\n } else if (type === 'CARD') {\n this.isPbaAccountSelected = false;\n this.isCardPaymentSelected = true;\n this.isPBADropdownSelected = false\n this.isContinueButtondisabled = false;\n }\n }\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = false;\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n }\n}\n","import { IPayment } from './IPayment';\nimport { IRefundContactDetails } from './IRefundContactDetails';\n\nexport class NotificationPreviewRequest {\n notification_type?: string;\n payment_channel?: string;\n payment_method?: string;\n payment_reference?: string;\n personalisation?: {\n ccd_case_number?: string;\n refund_amount?: number;\n refund_reason?: string;\n refund_reference?: string;\n }\n recipient_email_address?: string;\n recipient_postal_address?: {\n address_line?: string;\n city?: string;\n county?: string;\n country?: string;\n postal_code?: string;\n }\n service_name?: string;\n\n constructor(payment: IPayment, contactDetails: IRefundContactDetails, refund_reason: string, refund_amount: number, refund_reference: string, payment_reference: string) {\n \n if (contactDetails !== undefined && contactDetails !== null) {\n this.notification_type = contactDetails.notification_type.toUpperCase();\n }\n\n if (payment !== undefined && payment !== null) {\n this.payment_reference = payment.reference;\n this.payment_method = payment.method;\n this.payment_channel = payment.channel;\n this.service_name = payment.service_name;\n } else {\n this.payment_reference = payment_reference;\n }\n\n this.personalisation = {\n ccd_case_number: (payment !== undefined && payment !== null) ? payment.ccd_case_number : '',\n refund_reason: refund_reason,\n refund_amount: refund_amount,\n refund_reference: refund_reference\n };\n\n if (this.notification_type === \"EMAIL\") {\n this.recipient_email_address = contactDetails.email;\n this.recipient_postal_address = null;\n } else if (this.notification_type === \"LETTER\") {\n this.recipient_postal_address = {\n address_line: contactDetails.address_line,\n city: contactDetails.city,\n county: contactDetails.county,\n country: contactDetails.country,\n postal_code: contactDetails.postal_code\n };\n this.recipient_email_address = null;\n }\n\n }\n}","import { Component, Input, OnInit } from '@angular/core';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { INotificationPreview } from '../../interfaces/INotificationPreview';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { NotificationPreviewRequest } from '../../interfaces/NotificationPreviewRequest';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\nimport { Output, EventEmitter } from '@angular/core';\n\n@Component({\n selector: 'app-notification-preview',\n templateUrl: './notification-preview.component.html',\n styleUrls: ['./notification-preview.component.scss']\n})\nexport class NotificationPreviewComponent implements OnInit {\n @Input() payment: IPayment;\n @Input() contactDetails: IRefundContactDetails;\n @Input() refundReason: string;\n @Input() refundAmount: number;\n @Input() paymentReference: string;\n @Input() refundReference: string;\n @Input() previewJourney: string;\n @Input() notificationSent: INotificationPreview;\n\n @Output() notificationPreviewEvent = new EventEmitter<INotificationPreview>();\n\n notification: INotificationPreview;\n notificationPreviewRequest: NotificationPreviewRequest;\n today: number = Date.now();\n errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n\n constructor(private errorHandlerService: ErrorHandlerService,\n private notificationService: NotificationService) { }\n\n ngOnInit() {\n\n if (this.previewJourney != undefined && this.previewJourney != null && this.previewJourney === 'Notifications sent') {\n\n this.notification = this.notificationSent;\n\n if (this.notification != undefined && this.notification != null && this.notification.template_type === 'letter') {\n this.notification.body = this.notification.body.replace(/\\r\\n/g, '<br/>');\n }\n } else {\n\n const notficationPreviewRequestBody = new NotificationPreviewRequest(this.payment, this.contactDetails,\n this.refundReason, this.refundAmount, this.refundReference, this.paymentReference);\n\n this.notificationService.getNotificationPreview(notficationPreviewRequestBody).subscribe(\n res => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.notification = JSON.parse(res);\n\n if (this.notification != undefined && this.notification != null && this.notification.template_type === 'letter') {\n this.notification.body = this.notification.body.replace(/\\r\\n/g, '<br/>');\n }\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n console.log(this.errorMessage);\n }\n );\n\n this.notificationPreviewEvent.emit(this.notification);\n\n }\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { HttpClientModule } from '@angular/common/http';\nimport { CommonModule } from '@angular/common';\n\nimport { PaymentListComponent } from './components/payment-list/payment-list.component';\nimport { PaymentViewComponent } from './components/payment-view/payment-view.component';\nimport { ProcessRefundComponent } from './components/process-refund/process-refund.component';\nimport { RefundListComponent } from './components/refund-list/refund-list.component';\n\nimport { CardDetailsComponent } from './components/card-details/card-details.component';\nimport { PageNotFoundComponent } from './components/page-not-found.component';\nimport { PaymentLibComponent } from './payment-lib.component';\nimport { StatusHistoryComponent } from './components/status-history/status-history.component';\nimport { ContactDetailsComponent } from './components/contact-details/contact-details.component';\nimport { PbaDetailsComponent } from './components/pba-details/pba-details.component';\nimport { LoggerService } from './services/shared/logger/logger.service';\nimport { ConsoleLoggerService } from './services/shared/logger/console-logger.service';\nimport { WebComponentHttpClient } from './services/shared/httpclient/webcomponent.http.client';\nimport { CaseTransactionsComponent } from './components/case-transactions/case-transactions.component';\nimport { FeeSummaryComponent } from './components/fee-summary/fee-summary.component';\nimport { ErrorBannerComponent } from './components/error-banner/error-banner.component';\nimport { MarkUnidentifiedPaymentComponent } from './components/mark-unidentified-payment/mark-unidentified-payment.component';\nimport { MarkUnsolicitedPaymentComponent } from './components/mark-unsolicited-payment/mark-unsolicited-payment.component';\nimport { UnprocessedPaymentsComponent } from './components/unprocessed-payments/unprocessed-payments.component';\nimport { ProcessedPaymentsComponent } from './components/processed-payments/processed-payments.component';\nimport { AllocatePaymentsComponent } from './components/allocate-payments/allocate-payments.component';\nimport { AddRemissionComponent } from './components/add-remission/add-remission.component';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { CcdHyphensPipe } from './pipes/ccd-hyphens.pipe';\nimport { CapitalizePipe } from './pipes/capitalize.pipe';\nimport { keyValuePipe } from './pipes/key-value.pipe';\nimport { SanitizeHtmlPipe } from './pipes/sanitize-html.pipe';\nimport { ReportsComponent } from './components/reports/reports.component';\nimport { XlFileService } from './services/xl-file/xl-file.service';\nimport { TableComponent } from './components/table/table.component';\nimport { MatTableModule } from '@angular/material/table';\nimport { MatPaginatorModule } from '@angular/material/paginator';\nimport { MatSortModule } from '@angular/material/sort';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\n// import { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n// import { NoopAnimationsModule } from '@angular/platform-browser/animations';\nimport { RefundStatusComponent } from './components/refund-status/refund-status.component';\nimport { ServiceRequestComponent } from './components/service-request/service-request.component';\nimport { PbaPaymentComponent } from './components/pba-payment/pba-payment.component';\nimport { NotificationPreviewComponent } from './components/notification-preview/notification-preview.component';\n\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n FormsModule,\n ReactiveFormsModule,\n MatTableModule,\n MatPaginatorModule,\n MatSortModule,\n MatFormFieldModule,\n MatInputModule,\n // BrowserAnimationsModule,\n // NoopAnimationsModule\n ],\n declarations: [\n PaymentLibComponent,\n PaymentListComponent,\n PaymentViewComponent,\n PbaPaymentComponent,\n ContactDetailsComponent,\n ProcessRefundComponent,\n RefundListComponent,\n CardDetailsComponent,\n PageNotFoundComponent,\n StatusHistoryComponent,\n MarkUnidentifiedPaymentComponent,\n MarkUnsolicitedPaymentComponent,\n UnprocessedPaymentsComponent,\n ProcessedPaymentsComponent,\n AllocatePaymentsComponent,\n PbaDetailsComponent,\n CaseTransactionsComponent,\n FeeSummaryComponent,\n AddRemissionComponent,\n CcdHyphensPipe,\n CapitalizePipe,\n keyValuePipe,\n SanitizeHtmlPipe,\n ReportsComponent,\n ErrorBannerComponent,\n TableComponent,\n RefundStatusComponent,\n ServiceRequestComponent,\n NotificationPreviewComponent\n ],\n exports: [PaymentLibComponent],\n providers: [\n { provide: LoggerService, useClass: ConsoleLoggerService },\n XlFileService,\n WebComponentHttpClient\n ]\n})\n\nexport class PaymentLibModule { }\n"],"mappings":"umDAMAA,EAAA,WAOE,SAAAA,I,QAEAA,EAAaC,UAAAC,cAAb,SAAcC,GACZC,KAAKC,SAAWF,C,EAGlBH,EAAAC,UAAAK,cAAA,WACE,OAAOF,KAAKC,Q,EAGdL,EAAqBC,UAAAM,sBAArB,SAAsBC,GACpBJ,KAAKK,kBAAoBD,C,EAG3BR,EAAAC,UAAAS,sBAAA,WACE,OAAON,KAAKK,iB,EAGdT,EAAsBC,UAAAU,uBAAtB,SAAuBC,GACrBR,KAAKS,iBAAmBD,C,EAG1BZ,EAAAC,UAAAa,qBAAA,WACE,OAAOV,KAAKS,gB,EAEdb,EAAuBC,UAAAc,wBAAvB,SAAwBC,GACtBZ,KAAKa,sBAAwBD,C,EAG/BhB,EAAAC,UAAAiB,wBAAA,WACE,OAAOd,KAAKa,qB,EAEdjB,EAAuBC,UAAAkB,wBAAvB,SAAwBC,GACtBhB,KAAKiB,qBAAuBD,C,EAE9BpB,EAAAC,UAAAqB,wBAAA,WACE,OAAOlB,KAAKiB,oB,IA3ChB,G,yGAJC,CAAAE,KAAAC,aAAWC,KAAA,EACVC,WAAY,W,sCCMd,IAAAC,EAAA,WAoCE,SAAAA,IAnCQvB,KAAAwB,WAAoD,IAAIC,kBAAsC,MAC9FzB,KAAA0B,WAA2C,IAAID,kBAA6B,MAC5EzB,KAAA2B,SAAW,IAA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B,KAAK8V,aAEzC,C,IAnDL,G,eALC,CAAA3U,KAAAqG,YAAUnG,KAAA,EACToG,SAAU,2BACVC,SAAoD,4qF,mHAL7CiB,G,MADAuH,G,oCAUNtI,U,sBACAA,U,oBACAA,U,oBACAA,U,wBACAA,U,uBACAA,U,sBACAA,U,wBACAA,U,gCAEAgc,YC4EH,IAAAsuB,GAAA,W,iBArDC,CAAA/wC,KAAAgxC,WAAS9wC,KAAA,EACR+wC,QAAS,CACPC,eACAC,mBACAC,cACAC,sBACAC,iBACAC,qBACAC,gBACAC,qBACAC,kBAIFC,aAAc,CACZ3sC,EACA2E,EACAmG,EACAg/B,GACAjwB,EACA9G,EACAqF,EACAe,EACAI,EACAG,EACAkQ,GACAoC,GACA2B,GACA6B,GACAO,GACArS,EACA2B,EACAqH,EACA0N,GACA8H,GACAI,GACAE,GACAE,GACAmD,GACAvX,GACA6b,GACA+B,GACAiD,GACAsC,IAEFmB,QAAS,CAAC5sC,GACV6sC,UAAW,CACT,CAAEC,QAASjpC,EAAekpC,SAAUnvB,GACpCkf,GACA/2B,O"}
|
|
1
|
+
{"version":3,"names":["PaymentLibService","prototype","setApiRootUrl","apiRoot","this","API_ROOT","getApiRootUrl","setBulkScanApiRootUrl","bulkscanapiRoot","BULKSCAN_API_ROOT","getBulkScanApiRootUrl","setRefundndsApiRootUrl","refundsapiRoot","REFUNDS_API_ROOT","getRefundsApiRootUrl","setNoticationApiRootUrl","notificationapiRoot","NOTIFICATION_API_ROOT","getNoticationApiRootUrl","setCardPaymentReturnUrl","cardPaymentReturnUrl","CARDPAYMENTRETURNURL","getCardPaymentReturnUrl","type","Injectable","args","providedIn","OrderslistService","ordersList","BehaviorSubject","refundView","caseType","getcaseType","asObservable","feeExists","getFeeExist","ccdCaseNumber","getCCDCaseNumberforRefund","isFromServiceRequestPage","getisFromServiceRequestPage","OrderRefId","getOrderRefId","navigationPage","getnavigationPage","orderRef","getorderRef","orderCCDEvent","getorderCCDEvent","orderCreated","getorderCreated","orderParty","getorderParty","orderRemissionTotal","getorderRemissionTotal","orderFeesTotal","getorderFeesTotal","orderTotalPayments","getorderTotalPayments","rolesList","orderDetail","paymentPageView","setOrdersList","orderLevelFees","next","Object","assign","getOrdersList","setRefundView","refundList","getRefundView","setCaseType","getCaseType","setCCDCaseNumber","getCCDCaseNumber","setFeeExists","getFeeExists","setisFromServiceRequestPage","getisFromServiceRequestPages","setOrderRefId","getSelectedOrderRefId","setnavigationPage","getnavigationPageValue","setpaymentPageView","paymentpageList","getpaymentPageView","setUserRolesList","getUserRolesList","setorderDetail","getorderDetail","setOrderRef","getorderRefs","setorderCCDEvent","getorderCCDEvents","setorderCreated","getorderCreateds","setorderParty","getorderPartys","setorderRemissionTotal","getorderRemissionTotals","setorderFeesTotal","getorderFeesTotals","setorderTotalPayments","getoorderTotalPaymentss","PaymentLibComponent","paymentLibService","cd","unProcessedPaymentServiceId","isFromPayBubble","unProcessedPayment","orderPendingPayments","ngAfterContentChecked","detectChanges","ngOnInit","LOGGEDINUSERROLES","length","PAYMENT_GROUP_REF","paymentGroupReference","DCN_NUMBER","bspaymentdcn","REFUNDLIST","VIEW","viewName","isTakePayment","TAKEPAYMENT","Component","selector","template","ChangeDetectorRef","Input","CCD_CASE_NUMBER","EXC_REFERENCE","PAYMENT_METHOD","VIEWSERVICE","SERVICEREQUEST","SELECTED_OPTION","ISBSENABLE","ISSFENABLE","ISTURNOFF","CASETYPE","ISPAYMENTSTATUSENABLED","rootUrl","USERID","LOGGEDINUSEREMAIL","ErrorHandlerService","handleError","err","errorMessage","error","Error","message","status","undefined","JSON","parse","statusCode","messsage","stringify","throwError","getServerErrorMessage","isErrorExist","isDataNotExist","title","body","showError","LoggerService","invokeConsoleMethod","PaymentListService","http","logger","errorHandlerService","getPaymentByCcdCaseNumber","paymentMethod","info","get","withCredentials","pipe","catchError","HttpClient","PaymentListComponent","paymentListService","paymentLibComponent","_this","subscribe","payments","loadPaymentViewComponent","paymentReference","create","__values","o","s","Symbol","iterator","m","i","call","value","done","TypeError","WebComponentHttpClient","meta","post","url","options","opts","addHeaders","put","delete","patch","csrfToken","getTag","headers","forEach","element","document","cookie","split","find","row","startsWith","content","HttpHeaders","responseType","Meta","PaymentViewService","https","getPaymentDetails","getPaymentGroupDetails","getApportionPaymentDetails","getPBAaccountDetails","postWays2PayCardPayment","serviceRef","rurl","replace","postPBAaccountPayment","randomKey","Math","random","toString","join","postBSPayments","postBSUnidentifiedPayments","postBSUnsolicitedPayments","postBSAllocationPayments","postPaymentGroupWithRemissions","feeId","deleteFeeFromPaymentGroup","postPaymentToPayHub","paymentGroupRef","postPaymentAntennaToPayHub","downloadSelectedReport","reportName","startDate","endDate","downloadFailureReport","getBSfeature","getSiteID","getPartyDetails","caseNumber","postRefundsReason","postPaymentGroupWithRetroRemissions","postRefundRetroRemission","getPaymentFailure","NotificationService","getRefundNotification","reference","getAddressByPostcode","postcode","getNotificationPreview","getNotificationInstructionType","paymentChannel","PostRefundRetroRemission","contact_details","fees","payment_reference","refund_reason","total_refund_amount","is_over_payment","PaymentViewComponent","paymentViewService","notificationService","isRefundRemission","isAddFeeBtnEnabled","isIssueRefunfBtnEnable","allowedRolesToAccessRefund","remissions","allPaymentsFailure","isContinueBtnDisabled","selectedOption","dcnNumber","isTurnOff","serviceReference","viewStatus","paymentGroup","fee","isRemissionsMatch","rem","fee_code","code","push","paymentFees","filter","paymentGroupObj","includes","paymentAllocation","payment_allocation","isStatusAllocated","allocation_status","res","payment_failure_list","reverse","payment_failure_initiated","payment_failure_closed","e","errorMsg","defineProperty","method","channel","goToPaymentList","getOverPaymentValue","feesOverPayment","over_payment","goToServiceRequestPage","window","location","reload","goToCaseTransationPage","event","preventDefault","data","resetOrderData","addRemission","chkIsAddRemissionBtnEnable","payment","isFromPaymentDetailPage","checkForFees","processRefund","isConfirmationBtnDisabled","obj","id","version","apportion_amount","calculated_amount","updated_volume","volume","refund_amount","requestBody","contactDetailsObj","response","viewCompStatus","refundReference","refund_reference","refundAmount","gotoAddressPage","note","notification","notification_type","addRefundForRemission","remission","remissionFeeAmt","net_amount","goToPaymentViewComponent","issueRefund","paymentgrp","chkIsIssueRefundBtnEnable","getRemissionByFeeCode","feeCode","remissions_1","remissions_1_1","issue_refund","refund_enable","chkIsAddRefundBtnEnable","add_refund","add_remission","remission_enable","selectPymentOption","paymentType","continuePayment","isFullyRefund","gotoPaymentSelectPage","getContactDetails","notificationPreview","getTemplateInstructionType","goToPaymentFailuePage","selectedPaymentsStatus","goBackToPaymentView","templateInstructionType","showNotificationPreview","hideNotificationPreview","isServiceRequest","RefundsService","getRefundReasons","getRefundRejectReasons","getRefundActions","patchRefundActions","reviewerAction","getRefundList","refundstatus","selfexclusive","getRefundStatusHistory","getRefundStatusList","getUserDetails","postIssueRefund","putResendOrEdit","refundRef","notificationType","patchResubmitRefund","ProcessRefundComponent","formBuilder","router","activeRoute","getErrorMessage","sendmeback","refundActionList","refundRejectReasonList","isSendMeBackClicked","isRejectClicked","isOtherClicked","isSuccesspageEnable","refundActionsHasError","refundRejectReasonHasError","isReasonFieldEmpty","isReasonFieldInvalid","reasonFieldMinHasError","reasonFieldMaxHasError","isReasonEmpty","isReasonInvalid","successMsg","cpoDetails","isConfirmButtondisabled","processRefundForm","group","refundActionField","FormControl","Validators","compose","required","refundRejectReasonField","sendMeBackField","minLength","maxLength","pattern","enterReasonField","refundlistsource","ccd_case_number","isFromRefundListPage","isCPODown","paymentObj","checkRefundActions","getNotificationPreviewObj","notificationPreviewObj","processRefundSubmit","processRefundRequest","resetForm","controls","processFormError","errors","dirty","valid","reason","template_preview","from","from_email_address","from_mail_address","address_line","city","country","county","postal_code","html","template_id","subject","template_type","invalid","minlength","actualLength","maxlength","bodyTxt","loadRefundListPage","navigationpage","isRefundStatusView","loadRefundsHomePage","redirecttoRefundListPage","loadCaseTransactionPage","vals","field","goToCaseReview","navigate","relativeTo","FormBuilder","Router","ActivatedRoute","RefundListComponent","refundService","submittedRefundList","rejectedRefundList","approvalStatus","rejectStatus","isAuthorized","userLst","some","isApproveTableVisible","tableApprovalHeader","tableRejectedHeader","isRejectTableVisible","CardDetailsService","getCardDetails","CardDetailsComponent","cardDetailsService","pageTitle","cardDetails","PageNotFoundComponent","StatusHistoryService","getPaymentStatusesByReference","StatusHistoryComponent","statusHistoryService","statuses","ContactDetailsComponent","assignContactDetails","EventEmitter","assignContactDetailsInFefundsList","redirectToIssueRefund","isEmailSAddressClicked","isShowPickAddress","isPostcodeClicked","isManualAddressClicked","addressPostcodeList","isAddressBoxEmpty","isEmailEmpty","emailHasError","isPostcodeEmpty","postcodeHasError","isaddressLine1Empty","addressLine1HasError","addressLine2HasError","isTownOrCityEmpty","townOrCityHasError","isCountyEmpty","countyHasError","isMPostcodeEmpty","mpostcodeHasError","isCountryEmpty","emailAddressForm","email","postCodeForm","manualAddressForm","addressl1","addressl2","townorcity","mpostcode","addressObj","setEditDetails","isEditOperationInRefundList","setValue","patchValue","selectContactOption","isLinkedClied","finalFormSubmit","emailField","emit","postcodeValidation","fieldCtrls","str","postcodeField","refundsNotification","totalresults","postcodeAddress","addressLine","addressArray","ADDRESS","addressObject","POST_TOWN","LOCAL_CUSTODIAN_CODE_DESCRIPTION","POSTCODE","redirection","val","isEditOperation","Output","PbaDetailsComponent","noop","ConsoleLoggerService","console","log","apply","CaseTransactionsService","getPaymentGroups","BulkScaningPaymentService","getBSPaymentsByCCD","getBSPaymentsByDCN","dcn","postBSAllocatePayment","paymentRef","postBSPaymentStrategic","postBSWoPGStrategic","patchBSChangeStatus","calculateOutStandingAmount","feesTotal","paymentsTotal","remissionsTotal","toUpperCase","amount","hwf_amount","removeUnwantedString","input","replaceText","CaseTransactionsComponent","bulkScaningPaymentService","caseTransactionsService","paymentGroups","nonPayments","allPayments","totalPayments","totalRemissions","isExceptionRecord","isUnprocessedRecordSelected","isAnyFeeGroupAvilable","isHistoricGroupAvailable","isRemoveBtnDisabled","clAmountDue","overPaymentAmount","isFeeRecordsExist","isGrpOutstandingAmtPositive","isAddRemissionEnable","orderRemissionDetails","ispaymentGroupApisuccess","isPBA","isAddRemissionBtnEnabled","isRefundRemissionBtnEnable","isEligible4PBAPayment","currentDate","Date","check4AllowedRoles2AccessRefund","role","indexOf","check4AllowedRoles2AccessPBApayment","allowFurtherAccessAfter4Days","tmp4DayAgo","setDate","getDate","date_created","paymentView","payment_group_reference","goToPayementView","excReference","takePayment","serviceRequest","serviceRequestValue","isBulkScanEnable","toLocaleLowerCase","isStrategicFixEnable","calculateAmounts","calculateOrderFeesAmounts","totalRefundAmount","calculateRefundAmount","setDefaults","goToOrderViewDetailSection","checkForExceptionRecord","totalNonOffPayments","totalFees","getAllocationStatus","recordData","exception_record_reference","ccd_reference","case_reference","index","resetOrderVariables","isFeeOverPaymentExist_1","service_request_status","orderStatus","orderAddBtnEnable","orderRefId","orderTotalFees","responsibleParty","action","orderReferenceObj","x","createdTimestamp","redirectToOrderFeeSearchPage","orderef","nonOffLinePayment","a","amount_due","b","allocationLen","remisison","totalRefundAmount_1","isFeeAmountZero_1","grpOutstandingAmount","isNewPaymentGroup_1","getGroupOutstandingAmount","redirectToFeeSearchPage","navigateByUrl","chkForAddRemission","redirectToremissionPage","redirectToReportsPage","loadFeeSummaryPage","selectedUnprocessedFeeEvent","unprocessedRecordId","getUnprocessedFeeCount","unProcessedRecordCount","unprocessedRecordCount","calculateAmountDue","confirmRemoveFee","cancelRemoval","removeFee","success","isCheckAmountdueExist","amountDue","chkIssueRefundBtnEnable","chkForPBAPayment","_b","_c","chkIsRefundRemissionBtnEnable","loadPBAAccountPage","pbaPayOrderRef","PaymentToPayhubRequest","currency","description","provider","toFixed","case_type","PayhubAntennaRequest","BS_ENABLE_FLAG","FeeSummaryComponent","service","platForm","isBackButtonEnable","isFeeAmountZero","totalAfterRemission","isPaymentExist","isRemissionsExist","bsPaymentDcnNumber","features","result","feature","uid","enable","getUnassignedPaymentlist","getPaymentGroup","unassignedPayments","responsible_service_id","upPaymentErrorMessage","currentFee","outStandingAmount","partUrl","cancelRemission","page","antennaReqBody","href","goToAllocatePage","Location","ErrorBannerComponent","UnidentifiedPaymentsRequest","unidentified_reason","payment_allocation_status","name","AllocatePaymentRequest","unAllocatedPayment","exceptionRecord","allocatedRequest","banked_date","date_banked","exception_record","document_control_number","dcn_reference","external_provider","giro_slip_no","bgc_reference","payer_name","payment_channel","payment_status","payment_method","payment_allocation_dto","MarkUnidentifiedPaymentComponent","isInvesticationDetailEmpty","investicationDetailHasError","investicationDetailMinHasError","investicationDetailMaxHasError","siteID","ccdReference","exceptionReference","getUnassignedPayment","markPaymentUnidentifiedForm","investicationDetail","unassignedRecord","beCcdNumber","beExceptionNumber","trimUnderscore","saveAndContinue","investicationField","formerror","investigationComment","confirmPayments","res1","res2","response2","reqBody","res3","gotoCasetransationPage","user_id","postStrategicBody","cancelMarkUnidentifiedPayments","UnsolicitedPaymentsRequest","responsible_office","responsible_person","email_id","receiving_office","receiving_email_address","sending_email_address","MarkUnsolicitedPaymentComponent","reasonHasError","reasonMinHasError","reasonMaxHasError","responsibleOfficeHasError","isResponsibleOfficeEmpty","isContinueButtondisabled","siteids","siteIDList","scrollTo","markPaymentUnsolicitedForm","responsibleOffice","responsiblePerson","emailId","selectedSiteId","reasonField","officeIdField","cancelMarkUnsolicitedPayments","checkingFormValue","formFields","valueExists","hasOwnProperty","selectchange","target","selectedSiteName","selectedIndex","text","UnprocessedPaymentsComponent","recordId","isRecordExist","isAllocateToExistingFeebtnEnabled","isMarkAsUnidentifiedbtnEnabled","isAllocatedToNewFeebtnEnabled","isExceptionCase","serviceId","unassignedRecordListLength","isStFixEnable","FEE_RECORDS_EXISTS","setValuesForUnassignedRecord","unassignedRecordList","unprocessedPaymentSelectEvent","formatUnassignedRecordId","ID","loadUnsolicitedPage","selectedRecordReference","validateButtons","resetButtons","PAYMENTREF","setTimeout","IS_OS_AMT_AVAILABLE","unprocessedPaymentUnSelectEvent","showDetailRow","unassignedRecordSelectedList","IS_BUTTON_ENABLE","PAYMENTSLENGTH","LEVEL","ProcessedPaymentsComponent","redirectToPaymentViewPage","NONPAYMENTS","IAllocationPaymentsRequest","explanation","userName","user_name","AllocatePaymentsComponent","isMoreDetailsBoxHide","otherPaymentExplanation","paymentReasonHasError","paymentExplanationHasError","isPaymentDetailsEmpty","isPaymentDetailsInvalid","paymentDetailsMinHasError","paymentDetailsMaxHasError","isUserNameEmpty","isUserNameInvalid","paymentReason","paymentExplanation","cookieUserName","userNameField","reasonList","overPayment","hwfReward","wrongFee","notIssueCase","otherDeduction","shortFall","helpWithFee","other","explanationList","referRefund","noRefund","noCase","holdCase","heldCase","refund","duplicate","humanerror","caseWithdrawn","overUnderPaymentForm","moreDetails","fstCon","scndCn","selectedPaymentGroup","gotoSummaryPage","cancelAllocatePayment","confirmAllocatePayement","enCookieUserName","decodeURIComponent","fullName","paymentDetailsField","paymentFormError","isEmptyCondtion","isOtherOptionSelected","isRemainingAmountGtZero","isRemainingAmountLtZero","finalServiceCall","reset","GroupOutstandingAmount","remainingToBeAssigned","paymentSectionLabel","feedbackUrlLabel","remainingAmount","afterFeeAllocateOutstanding","amountForAllocation","selectRadioButton","key","OrderListSelectEvent","AddRemissionRequest","hwf_reference","AddRetroRemissionRequest","PostIssueRefundRetroRemission","remissionReference","contactDeatils","AddRemissionComponent","Promise","resolve","refundListReason","refundListAmount","refundFees","hasErrors","option","selectedValue","retroRemission","isRemissionCodeEmpty","remissionCodeHasError","isAmountEmpty","amountHasError","isRemissionLessThanFeeError","refundHasError","isPaymentSuccess","isRemissionApplied","commonRefundReasons","class","Array","default","pattern1","pattern2","remessionPayment","remissionForm","remissionCode","refundReason","refundDDReason","feeAmount","feesList","array","onlySelf","refundPaymentReference","refundFeesList","refundReasons","recently_used","sort","localeCompare","changeRefundReason","creds","selected","noneSelected","item","querySelectorAll","el","classList","remove","check_en","v1","AppAmt","Volume","ele","getElementById","formArray","checked","at","removeAttribute","setAttribute","resetRemissionForm","remissionctrls","isRemissionLessThanFee","setErrors","confirmRemission","newNetAmount","remissionAmount","trim","LDUrl","routeReuseStrategy","shouldReuseRoute","onSameUrlNavigation","addRemissionCode","isFromCheckAnsPage","gotoAddRetroRemissionCodePage","isFromRefundStatusPage","iscancelClicked","selectedRefundReason","gotoCheckRetroRemissionPage","gotoAmountRetroRemission","gotoProcessRetroRemissionPage","gotoProcessRetroRemission","confirmRetroRemission","remissionamt","remission_reference","gotoIssueRefundConfirmation","reduce","c","displayRefundReason","gotoIssueRefundPage","gotoIssuePage","checkboxs","getElementsByTagName","j","fullRefund","quantity","amountToRefund","apportionAmount","elementId","getErrorClass","quantityUpdated","refundAmtForFeeVolumes","innerText","allowedRefundAmount","calAmtToRefund","amtToRefund","gotoContactDetailsPage","add","changeIssueRefundReason","confirmIssueRefund","map","gotoRefundReasonPage","localStorage","setItem","isRefundReasonsSelected","showReasonText","selectedRefundReasonCode","reasonLength","gotoPartialFeeRefundScreen","gotoServiceRequestPage","sendOrderDetail","sendOrderRef","gotoRemissionSuccess","gotoCasetransationPageCancelBtnClicked","changeRefundAmount","getFormattedCurrency","concat","CcdHyphensPipe","transform","match","Pipe","CapitalizePipe","slice","keyValuePipe","keys","SanitizeHtmlPipe","sanitizer","bypassSecurityTrustHtml","DomSanitizer","XlFileService","exportAsExcelFile","json","excelFileName","worksheet","workbook","XLSX","utils","json_to_sheet","header","setDataLossReportHeaders","autoFitColumns","setUnprocessedReportHeaders","setProcessedUnallocatedReportHeaders","setPaymentFailureReportHeaders","setShortFallReportHeaders","Sheets","SheetNames","excelBuffer","write","bookType","saveAsExcelFile","objectMaxLength","ColWidth","values","width","A1","v","B1","C1","D1","E1","F1","G1","H1","I1","J1","K1","L1","M1","N1","O1","buffer","fileName","Blob","FileSaver","saveAs","ReportsComponent","xlFileService","fmt","loc","isDownLoadButtondisabled","isStartDateLesthanEndDate","isDateBetwnMonth","isDateRangeBetnWeek","fromValidation","getToday","toISOString","getSelectedFromDate","validateDates","reportsForm","selectedStartDate","tranformDate","selectedEndDate","isDateRangeMoreThanWeek","isDateRangeMoreThanMonth","selectedreport","downloadReport","dataLossRptDefault","loss_resp","payment_asset_dcn","env_ref","env_item","resp_service_id","resp_service_name","bgc_batch","unProcessedRptDefault","exception_ref","ccd_ref","processedUnallocated","allocation_reason","ccd_exception_ref","ccd_case_ref","updated_by","shortFallsRptDefault","surplus_shortfall","balance","payment_amount","ccd_case_reference","ccd_exception_reference","processed_date","selectedReportName","applyDateFormat","substr","convertToFloatValue","Op","getFileName","toLowerCase","errorContent","stDt","formatDate","enDt","now","timestamp","getTwodigit","getHours","getMinutes","getSeconds","getCamelCaseString","strDate","parts","multiDateFormater","dateStr","date","amt","Number","parseFloat","TableComponent","cdRef","displayedColumns","STATUS","isApprovalFlow","DATASOURCE","dataSource","MatTableDataSource","actualcount","r","_a","user_full_name","serviceLst","service_type","ngAfterViewInit","paginator","applyFilter","filterValue","goToRefundProcessComponent","refundData","goToRefundViewComponent","isCallFromRefundList","ViewChild","MatPaginator","MatSort","IPutNotificationRequest","contactDetails","recipient_email_address","recipient_postal_address","IResubmitRefundRequest","refund_fees","RefundStatusComponent","refundButtonState","isResendOperationSuccess","isEditDetailsClicked","isEditAddressDeatilsClicked","isRefundBtnDisabled","isLastUpdatedByCurrentUser","isProcessRefund","notificationSentViewIndex","notificationSentView","refundlist","refundStatusForm","getRefundsNotification","getRefundsStatusHistoryList","refund_status","statusHistoryList","refundStatusHistories","status_history_dto_list","last_updated_by_current_user","notificationList","goToRefundView","gotoReviewDetailsPage","gotoReviewAndReSubmitPage","oldRefundReason","changedAmount","refundreason","notes","gotoAmountPage","goToReviewAndSubmitView","getRefundListReason","reason_code","refundCode","getRefundAmount","getRefundFees","fee_id","gotoReviewRefundConfirmationPage","resubmitRequest","gotoEditAddressDetails","addressDetails","getContactDetailsForRefundList","gotoEditDetailsPage","view","submitEditDetail","resendRequest","putResend","gotoRefundViewPageCancelBtnClicked","gotoRefundReviewAndSubmitViewPageCancelBtnClicked","showNotificationSentView","hideNotificationSentView","ServiceRequestComponent","goToServiceRquestComponent","paymentGroupList","goToPaymentViewComp","IserviceRequestCardPayment","language","IserviceRequestPbaPayment","account_number","customer_reference","orgName","organisation_name","PbaPaymentComponent","isPBAAccountHold","isCardPaymentSuccess","isInSufficiantFund","isPBAAccountNotExist","isPBAServerError","isGetPBAAccountSucceed","selectedPbaAccount","pbaAccountRef","isPbaAccountSelected","isCardPaymentSelected","isPBADropdownSelected","isPBAAccountPaymentSuccess","organisationEntityResponse","pbaAccountList","paymentAccount","selectpbaaccount","currentTarget","requestBody_1","pbaAccountrPaymentResult","cardPayment","paymentUrl","next_url","selectPaymentMethod","NotificationPreviewRequest","service_name","personalisation","NotificationPreviewComponent","notificationPreviewEvent","today","previewJourney","notificationSent","notficationPreviewRequestBody","PaymentLibModule","NgModule","imports","CommonModule","HttpClientModule","FormsModule","ReactiveFormsModule","MatTableModule","MatPaginatorModule","MatSortModule","MatFormFieldModule","MatInputModule","declarations","exports","providers","provide","useClass"],"sources":["../../../projects/payment-lib/src/lib/payment-lib.service.ts","../../../projects/payment-lib/src/lib/services/orderslist.service.ts","../../../projects/payment-lib/src/lib/payment-lib.component.ts","../../../projects/payment-lib/src/lib/services/shared/error-handler.service.ts","../../../projects/payment-lib/src/lib/services/shared/logger/logger.service.ts","../../../projects/payment-lib/src/lib/services/payment-list/payment-list.service.ts","../../../projects/payment-lib/src/lib/components/payment-list/payment-list.component.ts","../../../node_modules/tslib/tslib.es6.js","../../../projects/payment-lib/src/lib/services/shared/httpclient/webcomponent.http.client.ts","../../../projects/payment-lib/src/lib/services/payment-view/payment-view.service.ts","../../../projects/payment-lib/src/lib/services/notification/notification.service.ts","../../../projects/payment-lib/src/lib/interfaces/PostRefundRetroRemission.ts","../../../projects/payment-lib/src/lib/components/payment-view/payment-view.component.ts","../../../projects/payment-lib/src/lib/services/refunds/refunds.service.ts","../../../projects/payment-lib/src/lib/components/process-refund/process-refund.component.ts","../../../projects/payment-lib/src/lib/components/refund-list/refund-list.component.ts","../../../projects/payment-lib/src/lib/services/card-details/card-details.service.ts","../../../projects/payment-lib/src/lib/components/card-details/card-details.component.ts","../../../projects/payment-lib/src/lib/components/page-not-found.component.ts","../../../projects/payment-lib/src/lib/services/status-history/status-history.service.ts","../../../projects/payment-lib/src/lib/components/status-history/status-history.component.ts","../../../projects/payment-lib/src/lib/components/contact-details/contact-details.component.ts","../../../projects/payment-lib/src/lib/components/pba-details/pba-details.component.ts","../../../projects/payment-lib/src/lib/services/shared/logger/console-logger.service.ts","../../../projects/payment-lib/src/lib/services/case-transactions/case-transactions.service.ts","../../../projects/payment-lib/src/lib/services/bulk-scaning-payment/bulk-scaning-payment.service.ts","../../../projects/payment-lib/src/lib/components/case-transactions/case-transactions.component.ts","../../../projects/payment-lib/src/lib/interfaces/PaymentToPayhubRequest.ts","../../../projects/payment-lib/src/lib/interfaces/PayhubAntennaRequest.ts","../../../projects/payment-lib/src/lib/components/fee-summary/fee-summary.component.ts","../../../projects/payment-lib/src/lib/components/error-banner/error-banner.component.ts","../../../projects/payment-lib/src/lib/interfaces/UnidentifiedPaymentsRequest.ts","../../../projects/payment-lib/src/lib/interfaces/AllocatePaymentRequest.ts","../../../projects/payment-lib/src/lib/components/mark-unidentified-payment/mark-unidentified-payment.component.ts","../../../projects/payment-lib/src/lib/interfaces/UnsolicitedPaymentsRequest.ts","../../../projects/payment-lib/src/lib/components/mark-unsolicited-payment/mark-unsolicited-payment.component.ts","../../../projects/payment-lib/src/lib/components/unprocessed-payments/unprocessed-payments.component.ts","../../../projects/payment-lib/src/lib/components/processed-payments/processed-payments.component.ts","../../../projects/payment-lib/src/lib/interfaces/IAllocationPaymentsRequest.ts","../../../projects/payment-lib/src/lib/components/allocate-payments/allocate-payments.component.ts","../../../projects/payment-lib/src/lib/interfaces/AddRemissionRequest.ts","../../../projects/payment-lib/src/lib/interfaces/AddRetroRemissionRequest.ts","../../../projects/payment-lib/src/lib/interfaces/PostIssueRefundRetroRemission.ts","../../../projects/payment-lib/src/lib/components/add-remission/add-remission.component.ts","../../../projects/payment-lib/src/lib/pipes/ccd-hyphens.pipe.ts","../../../projects/payment-lib/src/lib/pipes/capitalize.pipe.ts","../../../projects/payment-lib/src/lib/pipes/key-value.pipe.ts","../../../projects/payment-lib/src/lib/pipes/sanitize-html.pipe.ts","../../../projects/payment-lib/src/lib/services/xl-file/xl-file.service.ts","../../../projects/payment-lib/src/lib/components/reports/reports.component.ts","../../../projects/payment-lib/src/lib/components/table/table.component.ts","../../../projects/payment-lib/src/lib/interfaces/IPutNotificationRequest.ts","../../../projects/payment-lib/src/lib/interfaces/IResubmitRefundRequest.ts","../../../projects/payment-lib/src/lib/components/refund-status/refund-status.component.ts","../../../projects/payment-lib/src/lib/components/service-request/service-request.component.ts","../../../projects/payment-lib/src/lib/interfaces/IserviceRequestCardPayment.ts","../../../projects/payment-lib/src/lib/interfaces/IserviceRequestPbaPayment.ts","../../../projects/payment-lib/src/lib/components/pba-payment/pba-payment.component.ts","../../../projects/payment-lib/src/lib/interfaces/NotificationPreviewRequest.ts","../../../projects/payment-lib/src/lib/components/notification-preview/notification-preview.component.ts","../../../projects/payment-lib/src/lib/payment-lib.module.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root'\n})\n\nexport class PaymentLibService {\n API_ROOT: string;\n BULKSCAN_API_ROOT: string;\n REFUNDS_API_ROOT: string;\n NOTIFICATION_API_ROOT: string;\n CARDPAYMENTRETURNURL: string;\n\n constructor() { }\n\n setApiRootUrl(apiRoot: string): void {\n this.API_ROOT = apiRoot;\n }\n\n getApiRootUrl(): string {\n return this.API_ROOT;\n }\n\n setBulkScanApiRootUrl(bulkscanapiRoot: string): void {\n this.BULKSCAN_API_ROOT = bulkscanapiRoot;\n }\n\n getBulkScanApiRootUrl(): string {\n return this.BULKSCAN_API_ROOT;\n }\n\n setRefundndsApiRootUrl(refundsapiRoot: string): void {\n this.REFUNDS_API_ROOT = refundsapiRoot;\n }\n\n getRefundsApiRootUrl(): string {\n return this.REFUNDS_API_ROOT;\n }\n setNoticationApiRootUrl(notificationapiRoot: string): void {\n this.NOTIFICATION_API_ROOT = notificationapiRoot;\n }\n\n getNoticationApiRootUrl(): string {\n return this.NOTIFICATION_API_ROOT;\n }\n setCardPaymentReturnUrl(cardPaymentReturnUrl: string):void {\n this.CARDPAYMENTRETURNURL = cardPaymentReturnUrl;\n }\n getCardPaymentReturnUrl(): string {\n return this.CARDPAYMENTRETURNURL;\n }\n}\n","import { Injectable } from '@angular/core';\nimport { Observable, BehaviorSubject } from 'rxjs';\nimport {IOrderReferenceFee} from '../interfaces/IOrderReferenceFee';\nimport { IRefundList } from '../interfaces/IRefundList';\nimport { IPaymentView } from '../interfaces/IPaymentView'; \n\n@Injectable({\n providedIn: 'root'\n})\nexport class OrderslistService {\n private ordersList: BehaviorSubject<IOrderReferenceFee[]> = new BehaviorSubject<IOrderReferenceFee[]>(null);\n private refundView: BehaviorSubject<IRefundList> = new BehaviorSubject<IRefundList>(null);\n private caseType = new BehaviorSubject(\"\");\n getcaseType = this.caseType.asObservable();\n private feeExists = new BehaviorSubject<boolean>(null);\n getFeeExist = this.feeExists.asObservable();\n private ccdCaseNumber = new BehaviorSubject(\"\");\n getCCDCaseNumberforRefund = this.ccdCaseNumber.asObservable();\n private isFromServiceRequestPage = new BehaviorSubject<boolean>(null);\n getisFromServiceRequestPage = this.isFromServiceRequestPage.asObservable();\n private OrderRefId = new BehaviorSubject(\"\");\n getOrderRefId = this.OrderRefId.asObservable();\n private navigationPage = new BehaviorSubject(\"\");\n getnavigationPage = this.navigationPage.asObservable();\n\n private orderRef = new BehaviorSubject(\"\");\n getorderRef = this.orderRef.asObservable();\n private orderCCDEvent = new BehaviorSubject(\"\");\n getorderCCDEvent = this.caseType.asObservable();\n private orderCreated = new BehaviorSubject<Date>(null);\n getorderCreated = this.orderCreated.asObservable();\n private orderParty = new BehaviorSubject(\"\");\n getorderParty = this.orderParty.asObservable();\n private orderRemissionTotal = new BehaviorSubject<number>(null);\n getorderRemissionTotal = this.orderRemissionTotal.asObservable();\n private orderFeesTotal = new BehaviorSubject<number>(null);\n getorderFeesTotal = this.orderFeesTotal.asObservable();\n private orderTotalPayments = new BehaviorSubject<number>(null);\n getorderTotalPayments = this.orderTotalPayments.asObservable();\n private rolesList: BehaviorSubject<any[]> = new BehaviorSubject<any[]>(null);\n\n private orderDetail: BehaviorSubject<any[]> = new BehaviorSubject<any[]>(null);\n\n private paymentPageView: BehaviorSubject<IPaymentView> = new BehaviorSubject<IPaymentView>(null);\n\n constructor() { }\n\n setOrdersList(orderLevelFees: IOrderReferenceFee[]): void {\n this.ordersList.next(Object.assign([], orderLevelFees));\n }\n getOrdersList() {\n return this.ordersList;\n }\n\n setRefundView(refundList: IRefundList): void {\n this.refundView.next(Object.assign([], refundList));\n }\n getRefundView() {\n return this.refundView;\n }\n\n setCaseType(caseType: string){\n this.caseType.next(caseType);\n }\n getCaseType(){\n return this.caseType;\n }\n\n setCCDCaseNumber(ccdCaseNumber: string){\n this.ccdCaseNumber.next(ccdCaseNumber);\n }\n getCCDCaseNumber(){\n return this.ccdCaseNumber;\n }\n\n setFeeExists(feeExists: boolean){\n this.feeExists.next(feeExists);\n }\n getFeeExists(){\n return this.feeExists;\n } \n\n setisFromServiceRequestPage(isFromServiceRequestPage: boolean){\n this.isFromServiceRequestPage.next(isFromServiceRequestPage);\n }\n getisFromServiceRequestPages(){\n return this.isFromServiceRequestPage;\n }\n\n setOrderRefId(OrderRefId: string){\n this.OrderRefId.next(OrderRefId);\n }\n getSelectedOrderRefId(){\n return this.OrderRefId;\n }\n\n setnavigationPage(navigationPage: string){\n this.navigationPage.next(navigationPage);\n }\n getnavigationPageValue(){\n return this.navigationPage;\n }\n\n setpaymentPageView(paymentpageList: IPaymentView): void {\n this.paymentPageView.next(Object.assign([], paymentpageList));\n }\n getpaymentPageView() {\n return this.paymentPageView;\n }\n\n setUserRolesList(rolesList:any[]): void {\n this.rolesList.next(Object.assign([], rolesList));\n }\n getUserRolesList() {\n return this.rolesList;\n }\n\n setorderDetail(orderDetail:any[]): void {\n this.orderDetail.next(Object.assign([], orderDetail));\n }\n getorderDetail() {\n return this.orderDetail;\n }\n\n setOrderRef(orderRef: string){\n this.orderRef.next(orderRef);\n }\n getorderRefs(){\n return this.orderRef;\n }\n\n setorderCCDEvent(orderCCDEvent: string){\n this.orderCCDEvent.next(orderCCDEvent);\n }\n getorderCCDEvents(){\n return this.orderCCDEvent;\n }\n\n setorderCreated(orderCreated: Date){\n this.orderCreated.next(orderCreated);\n }\n getorderCreateds(){\n return this.orderCreated;\n }\n\n setorderParty(orderParty: string){\n this.orderParty.next(orderParty);\n }\n getorderPartys(){\n return this.orderParty;\n }\n\n setorderRemissionTotal(orderRemissionTotal: number){\n this.orderRemissionTotal.next(orderRemissionTotal);\n }\n getorderRemissionTotals(){\n return this.orderRemissionTotal;\n }\n\n setorderFeesTotal(orderFeesTotal: number){\n this.orderFeesTotal.next(orderFeesTotal);\n }\n getorderFeesTotals(){\n return this.orderFeesTotal;\n }\n\n setorderTotalPayments(orderTotalPayments: number){\n this.orderTotalPayments.next(orderTotalPayments);\n }\n getoorderTotalPaymentss(){\n return this.orderTotalPayments;\n }\n}\n","import { ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\nimport { PaymentLibService } from './payment-lib.service';\nimport { IBSPayments } from './interfaces/IBSPayments';\nimport { OrderslistService } from './services/orderslist.service';\nimport { IPayment } from './interfaces/IPayment';\n\n@Component({\n selector: 'ccpay-payment-lib',\n template: `\n <ccpay-refund-list [USERID]=\"USERID\" [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\" [LOGGEDINUSEREMAIL]=\"LOGGEDINUSEREMAIL\" *ngIf=\"viewName === 'refund-list'\"></ccpay-refund-list>\n <ccpay-payment-list *ngIf=\"viewName === 'payment-list'\"></ccpay-payment-list>\n <ccpay-refund-status\n [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\"\n [API_ROOT]=\"API_ROOT\"\n *ngIf=\"viewName === 'refundstatuslist'\"> </ccpay-refund-status >\n <ccpay-payment-view [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\" *ngIf=\"viewName === 'payment-view'\"\n [isTurnOff]=\"ISTURNOFF\" [isTakePayment]=\"TAKEPAYMENT\" [caseType]=\"CASETYPE\"\n [ISPAYMENTSTATUSENABLED] = \"ISPAYMENTSTATUSENABLED\"\n ></ccpay-payment-view>\n\n <ccpay-process-refund *ngIf=\"viewName === 'process-refund'\"\n [refundReference]=\"refundReference\"\n [refundlistsource]=\"refundlistsource\"\n ></ccpay-process-refund>\n <ccpay-pba-payment *ngIf=\"viewName === 'pba-payment'\"\n [pbaPayOrderRef]=\"pbaPayOrderRef\"\n ></ccpay-pba-payment>\n <ccpay-case-transactions [isTakePayment]=\"isTakePayment\" [isFromServiceRequestPage]=\"isFromServiceRequestPage\" [LOGGEDINUSERROLES]=\"LOGGEDINUSERROLES\" *ngIf=\"viewName === 'case-transactions'\"></ccpay-case-transactions>\n <app-mark-unidentified-payment *ngIf=\"viewName === 'unidentifiedPage'\"\n [caseType]=\"CASETYPE\"></app-mark-unidentified-payment>\n <app-mark-unsolicited-payment *ngIf=\"viewName === 'unsolicitedPage'\"\n [caseType]=\"CASETYPE\"></app-mark-unsolicited-payment>\n <app-allocate-payments *ngIf=\"viewName === 'allocate-payments'\"\n [isTurnOff]=\"ISTURNOFF\"\n [caseType]=\"CASETYPE\"\n ></app-allocate-payments>\n <ccpay-fee-summary *ngIf=\"viewName === 'fee-summary'\"\n [ccdCaseNumber]=\"CCD_CASE_NUMBER\"\n [paymentGroupRef]=\"paymentGroupReference\"\n [isTurnOff]=\"ISTURNOFF\"\n [caseType]=\"CASETYPE\"\n ></ccpay-fee-summary>\n <ccpay-reports *ngIf=\"viewName === 'reports'\"\n [ISPAYMENTSTATUSENABLED] = \"ISPAYMENTSTATUSENABLED\"\n ></ccpay-reports>\n `\n})\n\nexport class PaymentLibComponent implements OnInit {\n @Input('API_ROOT') API_ROOT: string;\n @Input('BULKSCAN_API_ROOT') BULKSCAN_API_ROOT: string;\n @Input('REFUNDS_API_ROOT') REFUNDS_API_ROOT: string;\n @Input('NOTIFICATION_API_ROOT') NOTIFICATION_API_ROOT: string;\n @Input('CARDPAYMENTRETURNURL') CARDPAYMENTRETURNURL: string;\n @Input('CCD_CASE_NUMBER') CCD_CASE_NUMBER: string;\n @Input('EXC_REFERENCE') EXC_REFERENCE: string;\n @Input('PAYMENT_METHOD') PAYMENT_METHOD: string;\n @Input('VIEW') VIEW: string;\n @Input('VIEWSERVICE') VIEWSERVICE: string;\n @Input('PAYMENT_GROUP_REF') PAYMENT_GROUP_REF?: string;\n @Input('TAKEPAYMENT') TAKEPAYMENT: boolean;\n @Input('SERVICEREQUEST') SERVICEREQUEST: string;\n @Input('DCN_NUMBER') DCN_NUMBER: string;\n @Input('SELECTED_OPTION') SELECTED_OPTION: string;\n @Input('ISBSENABLE') ISBSENABLE: Boolean;\n @Input('ISSFENABLE') ISSFENABLE: boolean;\n @Input('ISTURNOFF') ISTURNOFF: boolean;\n @Input('CASETYPE') CASETYPE: string;\n @Input('ISPAYMENTSTATUSENABLED') ISPAYMENTSTATUSENABLED: boolean;\n @Input('rootUrl') rootUrl: boolean;\n @Input('REFUNDLIST') REFUNDLIST: string;\n @Input('USERID') USERID: string;\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: any[];\n @Input('LOGGEDINUSEREMAIL') LOGGEDINUSEREMAIL: string;\n @Input('isFromServiceRequestPage') isFromServiceRequestPage: boolean;\n\n paymentMethod: string;\n bspaymentdcn: string;\n unProcessedPaymentServiceId: string = null;\n paymentGroupReference: string;\n paymentReference: string;\n refundReference: string;\n isFromPayBubble: boolean = false;\n refundlistsource: any;\n viewName: string;\n isTurnOff: boolean;\n caseType: string;\n unProcessedPayment: IBSPayments = null;\n isRefundStatusView: boolean;\n isRedirectFromCaseTransactionPage: string;\n isCallFromRefundList: boolean;\n isFromRefundStatusPage: boolean;\n iscancelClicked : boolean;\n isFromPaymentDetailPage: boolean;\n pbaPayOrderRef: IPayment;\n isTakePayment: boolean;\n\n orderDetail: any[];\n orderRef: string;\n orderStatus: string;\n orderParty: string;\n orderCreated: Date;\n orderCCDEvent: string;\n serviceRequestValue: string;\n orderAddBtnEnable: boolean;\n orderFeesTotal: number = 0.00;\n orderRemissionTotal: number = 0.00;\n orderTotalPayments: number = 0.00;\n orderPendingPayments: number = 0.00;\n\n constructor(private paymentLibService: PaymentLibService,\n private cd: ChangeDetectorRef,\n private OrderslistService: OrderslistService) { }\n ngAfterContentChecked(): void {\n this.cd.detectChanges();\n }\n\n\n ngOnInit() {\n\n this.paymentLibService.setApiRootUrl(this.API_ROOT);\n this.paymentLibService.setBulkScanApiRootUrl(this.BULKSCAN_API_ROOT);\n this.paymentLibService.setRefundndsApiRootUrl(this.REFUNDS_API_ROOT);\n this.paymentLibService.setNoticationApiRootUrl(this.NOTIFICATION_API_ROOT);\n this.paymentLibService.setCardPaymentReturnUrl(this.CARDPAYMENTRETURNURL);\n\n if(this.LOGGEDINUSERROLES.length > 0) {\n this.OrderslistService.setUserRolesList(this.LOGGEDINUSERROLES);\n }\n if (this.PAYMENT_GROUP_REF) {\n this.paymentGroupReference = this.PAYMENT_GROUP_REF;\n }\n if (this.DCN_NUMBER) {\n this.bspaymentdcn = this.DCN_NUMBER;\n }\n if (this.REFUNDLIST === \"true\") {\n this.VIEW = 'refund-list';\n this.viewName = this.VIEW;\n }\n if (this.VIEW === 'fee-summary') {\n this.viewName = 'fee-summary';\n } else if (this.VIEW !== 'reports' && this.VIEW !== 'refund-list') {\n this.viewName = 'case-transactions';\n } else {\n this.viewName = this.VIEW;\n }\n\n if (this.isTakePayment) {\n this.TAKEPAYMENT = true;\n }\n if(this.API_ROOT == 'api/payment-history') {\n this.isFromPayBubble = true;\n }\n }\n}\n","import { Injectable } from '@angular/core';\nimport { HttpErrorResponse } from '@angular/common/http';\nimport { Observable, throwError } from 'rxjs';\n\n@Injectable({\n providedIn: 'root'\n})\n\n\nexport class ErrorHandlerService {\n\n constructor() { }\n\n\n handleError(err: HttpErrorResponse): Observable<any> {\n let errorMessage: string;\n if (err.error instanceof Error) {\n // A client-side or network error occurred.\n errorMessage = `An error occurred: ${err.error.message}`;\n } else {\n // The backend returned an unsuccessful response code.\n if (err.status === 404) {\n\n if (typeof err.error === 'string' && err.error !== undefined) {\n\n if(err.error.length > 60) {\n if (JSON.parse(err.error).statusCode !== undefined && JSON.parse(err.error).statusCode === 500)\n {\n errorMessage = 'Internal server error';\n } else {\n if(err.error.length > 60) {\n errorMessage = JSON.parse(err.error).error;\n } else {\n errorMessage = err.error;\n }\n\n }\n } else {\n errorMessage = err.error;\n }\n } else {\n errorMessage = JSON.parse(err.error).error;\n }\n\n }\n else if (err.status === 500) {\n errorMessage = 'Internal server error';\n } else if (err.error.messsage === undefined) {\n if( typeof err.error === 'object') {\n errorMessage = JSON.parse(JSON.stringify(err.error)).error;\n } else {\n if (typeof err.error === 'string' && err.error !== undefined) {\n\n if(err.error.length > 60) {\n if (JSON.parse(err.error).statusCode !== undefined && JSON.parse(err.error).statusCode === 500)\n {\n errorMessage = 'Internal server error';\n } else {\n if(err.error.length > 60) {\n errorMessage = JSON.parse(err.error).error;\n } else {\n errorMessage = err.error;\n }\n\n }\n } else {\n errorMessage = err.error;\n }\n } else {\n errorMessage = JSON.parse(err.error).error;\n }\n\n }\n\n } else {\n if (err.error.message !== undefined) {\n errorMessage = `${err.error.message}`;\n } else {\n errorMessage = `${err.error}`;\n }\n\n }\n }\n return throwError(errorMessage);\n }\n\n\n getServerErrorMessage(isErrorExist, isDataNotExist = false, error='') {\n const bodyContent = isDataNotExist ? error : 'Try again later';\n return {\n title: \"There is a problem with the service\",\n body: bodyContent,\n showError: isErrorExist\n };\n }\n}\n","import { Injectable } from '@angular/core';\n\nconst noop = (): any => undefined;\n\nexport abstract class Logger {\n\n info: any;\n warn: any;\n error: any;\n}\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LoggerService implements Logger {\n\n info: any;\n warn: any;\n error: any;\n\n invokeConsoleMethod(type: string, args?: any): void {}\n}\n","import { Injectable } from '@angular/core';\nimport { HttpClient } from '@angular/common/http';\n\nimport { Observable } from 'rxjs/internal/Observable';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport { IPayments } from '../../interfaces/IPayments';\nimport { catchError } from 'rxjs/operators';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { LoggerService } from '../shared/logger/logger.service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class PaymentListService {\n payments: IPayments;\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n\n getPaymentByCcdCaseNumber(ccdCaseNumber: string, paymentMethod: string): Observable<IPayments> {\n this.logger.info('Payment-list-service getPaymentByCcdCaseNumber for: ', ccdCaseNumber);\n\n return this.http.get<IPayments>(`${this.paymentLibService.API_ROOT}/cases/${ccdCaseNumber}/payments`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import {Component, OnInit} from '@angular/core';\n\nimport {PaymentListService} from '../../services/payment-list/payment-list.service';\nimport {IPayments} from '../../interfaces/IPayments';\nimport {PaymentLibComponent} from '../../payment-lib.component';\nimport {IStatusHistory} from '../../interfaces/IStatusHistory';\n\n@Component({\n selector: 'ccpay-payment-list',\n templateUrl: './payment-list.component.html',\n styleUrls: ['./payment-list.component.css']\n})\nexport class PaymentListComponent implements OnInit {\n payments: IPayments;\n errorMessage: string;\n code: string;\n\n constructor(private paymentListService: PaymentListService,\n private paymentLibComponent: PaymentLibComponent) {\n }\n\n ngOnInit() {\n this.paymentListService.getPaymentByCcdCaseNumber(this.paymentLibComponent.CCD_CASE_NUMBER, this.paymentLibComponent.PAYMENT_METHOD)\n .subscribe(\n payments => this.payments = payments,\n (error: any) => this.errorMessage = <any>error\n );\n }\n\n loadPaymentViewComponent(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.paymentLibComponent.paymentMethod = paymentMethod;\n this.paymentLibComponent.paymentGroupReference = paymentGroupReference;\n this.paymentLibComponent.paymentReference = paymentReference;\n this.paymentLibComponent.viewName = 'payment-view';\n }\n}\n","/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n var desc = Object.getOwnPropertyDescriptor(m, k);\r\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\r\n desc = { enumerable: true, get: function() { return m[k]; } };\r\n }\r\n Object.defineProperty(o, k2, desc);\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n\r\nexport function __classPrivateFieldIn(state, receiver) {\r\n if (receiver === null || (typeof receiver !== \"object\" && typeof receiver !== \"function\")) throw new TypeError(\"Cannot use 'in' operator on non-object\");\r\n return typeof state === \"function\" ? receiver === state : state.has(receiver);\r\n}\r\n","import { Injectable } from '@angular/core';\nimport { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Meta } from '@angular/platform-browser';\nimport { Observable } from 'rxjs';\n\n@Injectable()\nexport class WebComponentHttpClient {\n constructor(\n private http: HttpClient,\n private meta: Meta\n ) { }\n\n post(url: string, body: any | null, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.post(url, body, opts);\n }\n\n put(url: string, body: any | null, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.put(url, body, opts);\n }\n\n get(url: string, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.get(url, opts);\n }\n\n delete(url: string, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.delete(url, opts);\n }\n \n patch(url: string, body: any | null, options?: any): Observable<any> {\n const opts = this.addHeaders(options || {});\n return this.http.patch(url, body, opts);\n }\n\n addHeaders(options: any): any {\n const csrfToken = this.meta.getTag('name=csrf-token');\n const headers = {};\n \n if (options.headers) {\n options.headers.forEach(element => {\n headers[element] = options.headers.get(element);\n });\n }\n headers['X-Requested-With'] = 'XMLHttpRequest';\n if (csrfToken === null) {\n if( document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')) !== undefined ) {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')).split('=')[1]; \n } else {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith(' XSRF-TOKEN')).split('=')[1];\n }\n \n } else {\n headers['CSRF-Token'] = csrfToken.content;\n }\n options.headers = new HttpHeaders(headers);\n options.responseType = 'text';\n return options;\n }\n}\n","import { Injectable } from '@angular/core';\nimport { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Observable } from 'rxjs/internal/Observable';\nimport { v4 as uuidv4 } from 'uuid';\nimport {IPayment} from '../../interfaces/IPayment';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { catchError } from 'rxjs/operators';\nimport { LoggerService } from '../shared/logger/logger.service';\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport { AddRemissionRequest } from '../../interfaces/AddRemissionRequest';\nimport { PaymentToPayhubRequest } from '../../interfaces/PaymentToPayhubRequest';\nimport { PayhubAntennaRequest } from '../../interfaces/PayhubAntennaRequest';\nimport { UnidentifiedPaymentsRequest } from '../../interfaces/UnidentifiedPaymentsRequest';\nimport { UnsolicitedPaymentsRequest } from '../../interfaces/UnsolicitedPaymentsRequest';\nimport { Meta } from '@angular/platform-browser';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\nimport { IAllocationPaymentsRequest } from '../../interfaces/IAllocationPaymentsRequest';\nimport {IOrderReferenceFee} from '../../interfaces/IOrderReferenceFee';\nimport { BehaviorSubject } from 'rxjs';\nimport { IserviceRequestPbaPayment } from '../../interfaces/IserviceRequestPbaPayment';\nimport { IserviceRequestCardPayment } from '../../interfaces/IserviceRequestCardPayment';\nimport { RefundsRequest } from '../../interfaces/RefundsRequest';\nimport { AddRetroRemissionRequest } from '../../interfaces/AddRetroRemissionRequest';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\nimport { PostIssueRefundRetroRemission } from '../../interfaces/PostIssueRefundRetroRemission';\nimport { error } from '@angular/compiler/src/util';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class PaymentViewService {\n private ordersList = <BehaviorSubject<IOrderReferenceFee[]>>new BehaviorSubject([]);\n\n private meta: Meta;\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n getPaymentDetails(paymentReference: string, paymentMethod?: string): Observable<IPayment> {\n\n\n this.logger.info('Payment-view-service getPaymentDetails for: ', paymentReference);\n\n if(paymentMethod == undefined || paymentMethod == null){\n return this.http.get<IPayment>(`${this.paymentLibService.API_ROOT}/payments/${paymentReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }else{\n return this.http.get<IPayment>(paymentMethod === 'card' || paymentMethod === 'cash' || paymentMethod === 'cheque' || paymentMethod === 'postal order' ?\n `${this.paymentLibService.API_ROOT}/card-payments/${paymentReference}` :\n `${this.paymentLibService.API_ROOT}/credit-account-payments/${paymentReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n\n }\n }\n\n getPaymentGroupDetails(paymentGroupReference: string): Observable<IPaymentGroup> {\n this.logger.info('Payment-view-service getPaymentGroupDetails for: ', paymentGroupReference);\n\n return this.http.get<IPayment>(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getApportionPaymentDetails(paymentReference: string): Observable<IPaymentGroup> {\n this.logger.info('Payment-view-service getPaymentGroupDetails for: ', paymentReference);\n\n return this.http.get<IPayment>(`${this.paymentLibService.API_ROOT}/payment-groups/fee-pay-apportion/${paymentReference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getPBAaccountDetails(): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/pba-accounts`;\n return this.http.get(url, { withCredentials: true }).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postWays2PayCardPayment(serviceRef: string, body: IserviceRequestCardPayment): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/service-request/${serviceRef}/card-payments`;\n const rurl = this.paymentLibService.CARDPAYMENTRETURNURL.replace('.prod', '');\n body['return-url'] = `${rurl}/payment`;\n return this.https.post(url, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n \n postPBAaccountPayment(serviceRef: string, body: IserviceRequestPbaPayment): Observable<any> {\n let randomKey = 'idam-key-' + Math.random().toString().split('.').join('-');\n body['idempotency_key'] = randomKey;\n const url = `${this.paymentLibService.API_ROOT}/service-request/${serviceRef}/pba-payments`;\n return this.https.post(url, body);\n }\n\n postBSPayments(body: AllocatePaymentRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/bulk-scan-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSUnidentifiedPayments(body: UnidentifiedPaymentsRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-allocations`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSUnsolicitedPayments(body: UnsolicitedPaymentsRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-allocations`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSAllocationPayments(body: IAllocationPaymentsRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-allocations`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postPaymentGroupWithRemissions(paymentGroupReference: string, feeId: number, body: AddRemissionRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupReference}/fees/${feeId}/remissions`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n deleteFeeFromPaymentGroup(feeId: number): Observable<any> {\n this.logger.info('Payment-view-service deleteFeeFromPaymentGroup for: ', feeId);\n return this.https.delete(`${this.paymentLibService.API_ROOT}/fees/${feeId}`).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postPaymentToPayHub(body: PaymentToPayhubRequest, paymentGroupRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupRef}/card-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postPaymentAntennaToPayHub(body: PayhubAntennaRequest, paymentGroupRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupRef}/telephony-card-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n downloadSelectedReport(reportName: string, startDate: string, endDate:string): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/report/data?date_from=${startDate}&date_to=${endDate}&report_type=${reportName}`;\n return this.https.get(url, { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n downloadFailureReport(startDate: string, endDate:string): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/payment-failures/failure-report?date_from=${startDate}&date_to=${endDate}`;\n return this.https.get(url, { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n getBSfeature(): Observable<any> {\n return this.https.get('api/payment-history/bulk-scan-feature', { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n getSiteID(): Observable<any> {\n return this.https.get('api/payment-history/refdata/legacy-sites', { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n getPartyDetails(caseNumber: string): Observable<any> {\n const url = `${this.paymentLibService.API_ROOT}/case-payment-orders?case_ids=${caseNumber}`;\n return this.https.get(url, { withCredentials: true }).pipe( catchError(this.errorHandlerService.handleError));\n }\n \n setOrdersList(orderLevelFees: IOrderReferenceFee[]): void {\n this.ordersList.next(Object.assign([], orderLevelFees));\n}\n getOrdersList() {\n return this.ordersList;\n }\n\n //issue refund\n postRefundsReason(body: PostRefundRetroRemission): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/refund-for-payment`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n // retro remissions\n postPaymentGroupWithRetroRemissions(paymentGroupReference: string, feeId: number, body: AddRetroRemissionRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupReference}/fees/${feeId}/retro-remission`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n postRefundRetroRemission(body:PostIssueRefundRetroRemission) {\n return this.https.post(`${this.paymentLibService.API_ROOT}/refund-retro-remission`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getPaymentFailure(paymentReference: string): Observable<any> {\n return this.https.get(`${this.paymentLibService.API_ROOT}/payment-failures/${paymentReference}`, {\n withCredentials: true\n }).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {catchError} from 'rxjs/operators';\nimport { IRefundsNotifications } from '../../interfaces/IRefundsNotifications';\nimport { NotificationPreviewRequest } from '../../interfaces/NotificationPreviewRequest';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class NotificationService {\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService\n ) { }\n\n getRefundNotification(reference: string): Observable<IRefundsNotifications> {\n return this.http.get<IRefundsNotifications>(`${this.paymentLibService.NOTIFICATION_API_ROOT}/${reference}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getAddressByPostcode(postcode: string): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.NOTIFICATION_API_ROOT}/postcode-lookup/${postcode}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getNotificationPreview(body: NotificationPreviewRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.NOTIFICATION_API_ROOT}/doc-preview`, body).pipe(\n catchError(this.errorHandlerService.handleError));\n }\n\n getNotificationInstructionType(paymentChannel: string, paymentMethod: string): any {\n if (paymentChannel === 'bulk scan' && paymentMethod === 'postal order') {\n return 'RefundWhenContacted';\n } else if (paymentChannel === 'bulk scan' && paymentMethod === 'cash') {\n return 'RefundWhenContacted';\n } else if (paymentChannel === 'online' && paymentMethod === 'card') {\n return 'SendRefund';\n } else if (paymentChannel === 'telephony' && paymentMethod === 'card') {\n return 'SendRefund';\n } else if (paymentChannel === 'online' && paymentMethod === 'payment by account') {\n return 'SendRefund';\n } else if (paymentChannel === 'bulk scan' && paymentMethod === 'cheque') {\n return 'SendRefund';\n }else {\n return 'Template'\n }\n }\n\n}\n","import { IFee } from \"./IFee\";\nimport { IRefundContactDetails } from \"./IRefundContactDetails\";\n\nexport class PostRefundRetroRemission {\n ccd_case_number: string;\n payment_reference: string;\n refund_reason: string;\n total_refund_amount: any;\n fees: any[];\n is_over_payment: boolean;\n contact_details: IRefundContactDetails\n \n constructor(contact_details:any,fees: any[], payment_reference : string,refund_reason:string, total_refund_amount : any, is_over_payment: string ) {\n this.contact_details = contact_details;\n this.fees = fees;\n this.payment_reference= payment_reference;\n this.refund_reason = refund_reason;\n\t this.total_refund_amount = total_refund_amount;\n this.is_over_payment = is_over_payment === 'op';\n } \n}","import { Component, OnInit, Input } from '@angular/core';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { IFee } from '../../interfaces/IFee';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\nimport { ChangeDetectorRef } from '@angular/core';\nimport { IPaymentFailure } from '../../interfaces/IPaymentFailure';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\n\n@Component({\n selector: 'ccpay-payment-view',\n templateUrl: './payment-view.component.html',\n styleUrls: ['./payment-view.component.scss']\n})\n\nexport class PaymentViewComponent implements OnInit {\n @Input() isTurnOff: boolean;\n @Input() isTakePayment: boolean;\n @Input() caseType: boolean;\n @Input() orderRef: string;\n @Input() orderStatus: string;\n @Input() orderTotalPayments: number;\n @Input() payment: IPayment;\n @Input() LOGGEDINUSERROLES: string[];\n @Input() ISPAYMENTSTATUSENABLED: string;\n @Input() orderParty: string;\n @Input() orderCreated: Date;\n @Input() orderCCDEvent: string;\n @Input() orderFeesTotal: number;\n @Input() orderRemissionTotal: number;\n @Input() orderDetail: any[];\n fees: any;\n isFullyRefund: boolean;\n @Input(\"isServiceRequest\") isServiceRequest: string;\n errorMsg: string;\n paymentGroup: IPaymentGroup;\n errorMessage: string;\n ccdCaseNumber: string;\n selectedOption: string;\n dcnNumber: string;\n isStatusAllocated: boolean;\n isRemissionsMatch: boolean;\n feeId: IFee;\n viewStatus: string;\n isRefundRemission: boolean = false;\n isStrategicFixEnable: boolean;\n isAddFeeBtnEnabled: boolean = false;\n isIssueRefunfBtnEnable: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund'];\n remissions: IRemission[] = [];\n allPaymentsFailure: IPaymentFailure[] = [];\n selectedPaymentsStatus: IPaymentFailure;\n remissionFeeAmt: number;\n isRefundRemissionBtnEnable: boolean;\n serviceReference: string;\n isFromServiceRequestPage: boolean;\n isFromPaymentDetailPage: boolean;\n paymentFees: IFee[];\n paymentType: string;\n isContinueBtnDisabled: boolean = true;\n viewCompStatus: string;\n contactDetailsObj: IRefundContactDetails\n notification: any;\n isConfirmationBtnDisabled: boolean;\n refundReference: string;\n refundAmount: string;\n templateInstructionType: string;\n notificationPreview: boolean;\n constructor(private paymentViewService: PaymentViewService,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private cd: ChangeDetectorRef,\n private OrderslistService: OrderslistService) {\n }\n\n ngAfterContentChecked(): void {\n this.cd.detectChanges();\n }\n\n ngOnInit() {\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION;\n this.dcnNumber = this.paymentLibComponent.DCN_NUMBER;\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.serviceReference = this.paymentLibComponent.paymentGroupReference;\n this.viewStatus = 'paymentview';\n this.paymentViewService.getApportionPaymentDetails(this.paymentLibComponent.paymentReference).subscribe(\n paymentGroup => {\n let fees = [];\n paymentGroup.fees.forEach(fee => {\n this.isRemissionsMatch = false;\n\n paymentGroup.remissions.forEach(rem => {\n if (rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n fees.push(fee);\n }\n });\n if (!this.isRemissionsMatch) {\n fees.push(fee);\n }\n });\n paymentGroup.fees = fees\n this.paymentFees =fees;\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n\n },\n (error: any) => this.errorMessage = error\n );\n this.paymentViewService.getPaymentFailure(this.paymentLibComponent.paymentReference).subscribe({\n next: (res) => {\n JSON.parse(res).payment_failure_list.reverse().forEach(payments => {\n\n this.allPaymentsFailure.push(payments.payment_failure_initiated);\n if(payments.payment_failure_closed) {\n this.allPaymentsFailure.push(payments.payment_failure_closed);\n }\n });\n this.allPaymentsFailure = this.allPaymentsFailure.reverse();\n },\n error: (e) => {\n this.allPaymentsFailure = [];\n this.errorMsg = \"Server error\"\n }\n })\n }\n\n get isCardPayment(): boolean {\n return this.paymentGroup.payments[0].method === 'card';\n }\n\n get isTelephonyPayment(): boolean {\n return this.paymentGroup.payments[0].channel === 'telephony';\n }\n\n public goToPaymentList(): void {\n this.paymentLibComponent.viewName = 'payment-list';\n }\n getOverPaymentValue() {\n let feesOverPayment = 0;\n this.paymentGroup.fees.forEach(fee => {\n feesOverPayment += fee.over_payment;\n });\n return feesOverPayment > 0 ? feesOverPayment : this.paymentGroup.payments[0].over_payment;\n\n }\n goToServiceRequestPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = false;\n this.paymentLibComponent.SERVICEREQUEST = 'true';\n this.paymentLibComponent.isFromServiceRequestPage = true;\n window.location.reload();\n }\n goToCaseTransationPage(event: any) {\n event.preventDefault();\n if (!this.paymentLibComponent.isFromServiceRequestPage) {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.resetOrderData();\n } else {\n this.OrderslistService.getorderRefs().subscribe((data) => this.orderRef = data);\n this.OrderslistService.getorderCCDEvents().subscribe((data) => this.orderCCDEvent = data);\n this.OrderslistService.getorderCreateds().subscribe((data) => this.orderCreated = data);\n this.OrderslistService.getorderDetail().subscribe((data) => this.orderDetail = data);\n this.OrderslistService.getorderPartys().subscribe((data) => this.orderParty = data);\n this.OrderslistService.getorderRemissionTotals().subscribe((data) => this.orderRemissionTotal = data);\n this.OrderslistService.getorderFeesTotals().subscribe((data) => this.orderFeesTotal = data);\n this.OrderslistService.getoorderTotalPaymentss().subscribe((data) => this.orderTotalPayments = data);\n this.viewStatus = 'order-full-view';\n }\n\n }\n\n addRemission(fee: IFee) {\n if(this.chkIsAddRemissionBtnEnable(fee)) {\n this.feeId = fee;\n this.paymentViewService.getApportionPaymentDetails(this.paymentGroup.payments[0].reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n this.payment = this.paymentGroup.payments[0];\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.viewStatus = 'addremission';\n this.isRefundRemission = true;\n this.cd.detectChanges();\n },\n (error: any) => this.errorMessage = error\n );\n }\n }\n\n checkForFees(paymentGroup: any) {\n if(paymentGroup !== null && paymentGroup !== undefined)\n {\n if (paymentGroup.fees !== null && paymentGroup.fees !== undefined) {\n return true;\n }\n\n }\n return false;\n }\n processRefund() {\n this.isConfirmationBtnDisabled = true;\n this.errorMessage = '';\n const obj = this.paymentGroup.fees[0];\n this.fees = [{ id: obj.id, \n code: obj.code,\n version:obj.version, \n apportion_amount: obj.apportion_amount,\n calculated_amount: obj.calculated_amount,\n updated_volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n volume: obj.volume,\n refund_amount: this.getOverPaymentValue() }];\n const requestBody = new PostRefundRetroRemission(this.contactDetailsObj,this.fees, this.paymentGroup.payments[0].reference, 'RR037', \n this.getOverPaymentValue(), 'op');\n this.paymentViewService.postRefundsReason(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n })\n }\n gotoAddressPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewCompStatus = 'overPaymentAddressCapture';\n }\n addRefundForRemission(payment: IPayment, remission: IRemission[],fees:any) {\n //if(!this.chkIsIssueRefundBtnEnable(payment)) {\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(payment.reference));\n this.payment = this.paymentGroup.payments[0];\n this.remissions = remission;\n this.remissionFeeAmt = fees.filter(data=>data.code === this.remissions['fee_code'])[0].net_amount;\n this.viewStatus = 'addrefundforremission';\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error\n );\n //}\n }\n\n goToPaymentViewComponent() {\n this.viewCompStatus = '';\n this.viewStatus = 'paymentview';\n }\n issueRefund(paymentgrp: IPaymentGroup) {\n if (paymentgrp !== null && paymentgrp !== undefined) {\n if(this.chkIsIssueRefundBtnEnable(paymentgrp.payments[0])) {\n if(paymentgrp.payments[0].over_payment > 0) {\n this.viewCompStatus = 'overpayment';\n } else {\n this.paymentGroup = paymentgrp;\n this.viewStatus = 'issuerefund';\n this.isRefundRemission = true;\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.isFromPaymentDetailPage = true;\n this.isFromServiceRequestPage = false;\n }\n }\n }\n }\n getRemissionByFeeCode(feeCode: string, remissions: IRemission[]): IRemission {\n if (remissions && remissions.length > 0) {\n for (const remission of remissions) {\n if (remission.fee_code === feeCode) {\n return remission;\n }\n }\n }\n return null;\n }\n\n chkIsIssueRefundBtnEnable(payment: IPayment): boolean {\n if (payment !== null && payment !== undefined) {\n return payment.issue_refund && payment.refund_enable\n } else {\n return false;\n }\n }\n\n chkIsAddRefundBtnEnable(remission: IRemission): boolean {\n if (remission !== null && remission !== undefined) {\n return remission.add_refund;\n } else {\n return false;\n }\n }\n\n chkIsAddRemissionBtnEnable(fee: IFee): boolean {\n if (fee !== null && fee !== undefined) {\n return fee.add_remission && fee.remission_enable;\n } else {\n return false\n }\n}\n selectPymentOption(paymentType: string) {\n this.paymentType = paymentType;\n this.isContinueBtnDisabled = false;\n }\n continuePayment(paymentgrp: IPaymentGroup) {\n \n if (this.paymentType === 'op') {\n this.isFullyRefund = false\n this.viewCompStatus = 'overPaymentAddressCapture';\n } else if(this.paymentType === 'fp') {\n this.isFullyRefund = true\n this.paymentGroup = paymentgrp;\n this.viewStatus = 'issuerefund';\n this.viewCompStatus = \"\";\n this.isRefundRemission = true;\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.isFromPaymentDetailPage = true;\n this.isFromServiceRequestPage = this.paymentLibComponent.isFromServiceRequestPage;\n }\n }\n gotoPaymentSelectPage(event: Event) {\n event.preventDefault();\n this.viewCompStatus = 'overpayment';\n }\n getContactDetails(obj:IRefundContactDetails) {\n this.contactDetailsObj = obj;\n this.notificationPreview = false;\n this.getTemplateInstructionType(this.paymentGroup.payments[0]);\n this.viewCompStatus = 'overpaymentcheckandanswer';\n \n }\n\n resetOrderData() {\n this.OrderslistService.setOrderRef(null);\n this.OrderslistService.setorderCCDEvent(null);\n this.OrderslistService.setorderCreated(null);\n this.OrderslistService.setorderDetail(null);\n this.OrderslistService.setorderParty(null);\n this.OrderslistService.setorderTotalPayments(null);\n this.OrderslistService.setorderRemissionTotal(null);\n this.OrderslistService.setorderFeesTotal(null);\n }\n\n goToPaymentFailuePage(payment: any) {\n this.viewStatus = 'payment-failure';\n this.selectedPaymentsStatus = payment;\n }\n goBackToPaymentView(event: any) {\n event.preventDefault();\n this.viewStatus = 'paymentview';\n }\n\n getTemplateInstructionType(payment: IPayment): void {\n\n if (payment == undefined || payment == null) {\n this.templateInstructionType = 'Template';\n }else{\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n \n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient, HttpHeaders} from '@angular/common/http';\nimport { Meta } from '@angular/platform-browser';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {catchError} from 'rxjs/operators';\nimport { IRefundReasons } from '../../interfaces/IRefundReasons';\nimport { IPatchRefundAction } from '../../interfaces/IPatchRefundAction';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { IssueRefundRequest } from '../../interfaces/IssueRefundRequest';\nimport { IResubmitRefundRequest } from '../../interfaces/IResubmitRefundRequest';\nimport { IRefundStatusHistory } from '../../interfaces/IRefundStatusHistory';\nimport { IPutNotificationRequest } from '../../interfaces/IPutNotificationRequest';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class RefundsService {\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService,\n private meta: Meta\n ) { }\n\n getRefundReasons(): Observable<IRefundReasons[]> {\n return this.http.get<IRefundReasons[]>(`${this.paymentLibService.REFUNDS_API_ROOT}/reasons`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getRefundRejectReasons(): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.REFUNDS_API_ROOT}/rejection-reasons`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\n getRefundActions(refundReference: string): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.REFUNDS_API_ROOT}/${refundReference}/actions`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n\npatchRefundActions(body:IPatchRefundAction, refundReference: string, reviewerAction: string): Observable<any> {\n // const opts = this.addHeaders({});\n return this.https.patch(`${this.paymentLibService.REFUNDS_API_ROOT}/${refundReference}/action/${reviewerAction}`, body)\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetRefundList(refundstatus?: string, selfexclusive?:boolean): Observable<IRefundList[]> {\n return this.http.get<IRefundList[]>(`${this.paymentLibService.REFUNDS_API_ROOT}?status=${refundstatus}&excludeCurrentUser=${selfexclusive}`, \n {\n withCredentials: true\n})\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetRefundStatusHistory(reference?: string) {\n return this.http.get<IRefundStatusHistory>(`${this.paymentLibService.REFUNDS_API_ROOT}/${reference}/status-history`, \n {\n withCredentials: true\n})\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetRefundStatusList(ccdCaseNumber:string): Observable<IRefundList[]> {\n return this.http.get<IRefundList[]>(`${this.paymentLibService.REFUNDS_API_ROOT}?ccdCaseNumber=${ccdCaseNumber}`, {\n withCredentials: true\n})\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\ngetUserDetails(): Observable<any> {\n return this.http.get<any>(`${this.paymentLibService.REFUNDS_API_ROOT}/get-user-details`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n \npostIssueRefund(body: IssueRefundRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.REFUNDS_API_ROOT}/refund`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\nputResendOrEdit(body: IPutNotificationRequest, refundRef:string, notificationType:string): Observable<any> {\n return this.https.put(`${this.paymentLibService.REFUNDS_API_ROOT}/resend/notification/${refundRef}?notificationType=${notificationType}`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\npatchResubmitRefund(body: IResubmitRefundRequest, refund_reference: string): Observable<any> {\n // const opts = this.addHeaders({});\n return this.https.patch(`${this.paymentLibService.REFUNDS_API_ROOT}/resubmit/${refund_reference}`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n\naddHeaders(options: any): any {\n const csrfToken = this.meta.getTag('name=csrf-token');\n const headers = {};\n if (options.headers) {\n options.headers.forEach(element => {\n headers[element] = options.headers.get(element);\n });\n }\n headers['X-Requested-With'] = 'XMLHttpRequest';\n if (csrfToken.content === null) {\n if( document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')) !== undefined ) {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith('XSRF-TOKEN')).split('=')[1]; \n } else {\n headers['CSRF-Token'] = document.cookie.split(';').find(row => row.startsWith(' XSRF-TOKEN')).split('=')[1];\n }\n } else {\n headers['CSRF-Token'] = csrfToken.content;\n }\n options.headers = new HttpHeaders(headers);\n options.responseType = 'text';\n return options;\n}\n}\n","import {Component, OnInit, Input} from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport {RefundsService} from '../../services/refunds/refunds.service';\nimport { IRefundAction } from '../../interfaces/IRefundAction';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRefundRejectReason } from '../../interfaces/IRefundRejectReason';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { ActivatedRoute,Router } from '@angular/router';\nimport { INotificationPreview } from '../../interfaces/INotificationPreview';\n\n@Component({\n selector: 'ccpay-process-refund',\n templateUrl: './process-refund.component.html',\n styleUrls: ['./process-refund.component.css']\n})\nexport class ProcessRefundComponent implements OnInit {\n @Input() refundReference: string;\n @Input() refundlistsource: IRefundList;\n\n processRefundForm: FormGroup;\n\n errorMessage = this.getErrorMessage(false, '', '', '');\n sendmeback: string = null;\n viewStatus: string;\n refundActionList: IRefundAction[] = [];\n refundRejectReasonList: IRefundRejectReason[] = [];\n isSendMeBackClicked: boolean = false;\n isRejectClicked: boolean = false;\n isOtherClicked: boolean = false;\n isSuccesspageEnable: boolean = false;\n\n refundActionsHasError: boolean = false;\n refundRejectReasonHasError: boolean = false;\n isReasonFieldEmpty: boolean = false;\n isReasonFieldInvalid: boolean = false;\n reasonFieldMinHasError: boolean = false;\n reasonFieldMaxHasError: boolean = false;\n isReasonEmpty: boolean = false;\n isReasonInvalid: boolean = false;\n successMsg: string = null;\n navigationpage: string;\n ccdCaseNumber: string;\n isFromRefundListPage: boolean;\n cpoDetails:any = [];\n isCPODown: boolean;\n isConfirmButtondisabled: boolean = true;\n paymentObj: IPayment;\n templateInstructionType: string;\n notificationPreview: boolean = false;\n notificationPreviewObj: INotificationPreview;\n constructor(private RefundsService: RefundsService,\n private paymentViewService: PaymentViewService,\n private formBuilder: FormBuilder,\n private OrderslistService: OrderslistService,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private router: Router,\n private activeRoute: ActivatedRoute) {\n }\n\n ngOnInit() {\n this.viewStatus = 'RefundProcess';\n this.RefundsService.getRefundActions(this.refundReference).subscribe(\n refundActionList => {\n this.refundActionList = <any>refundActionList;\n },\n err => {\n this.errorMessage = this.getErrorMessage(true, err.statusCode, err.err, err);\n }\n );\n this.processRefundForm = this.formBuilder.group({\n refundActionField: new FormControl('', Validators.compose([\n Validators.required\n ])),\n refundRejectReasonField: new FormControl('', Validators.compose([\n Validators.required\n ])),\n sendMeBackField: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$'),\n\n ])),\n enterReasonField: new FormControl('', Validators.compose([\n Validators.required,\n Validators.maxLength(30),\n Validators.pattern('^([a-zA-Z0-9.\\\\s]*)$'),\n ])),\n });\n this.ccdCaseNumber = this.refundlistsource.ccd_case_number;\n\n if((typeof this.paymentLibComponent.TAKEPAYMENT === 'string' && this.paymentLibComponent.TAKEPAYMENT === 'false') || (typeof this.paymentLibComponent.TAKEPAYMENT === 'boolean' && !this.paymentLibComponent.TAKEPAYMENT) ) {\n this.isFromRefundListPage = true;\n }\n this.paymentViewService.getPartyDetails(this.ccdCaseNumber).subscribe(\n response => {\n this.cpoDetails = JSON.parse(response).content;\n\n },\n (error: any) => {\n this.errorMessage = <any>error.replace(/\"/g,\"\");\n this.isCPODown = true;\n }\n );\n this.getTemplateInstructionType(this.paymentObj,this.refundlistsource.payment_reference);\n }\n\n checkRefundActions(code: string) {\n this.refundActionsHasError = false;\n this.isReasonFieldEmpty = false;\n this.isReasonEmpty = false;\n this.isReasonInvalid = false;\n this.refundRejectReasonHasError = false;\n if(code === 'Return to caseworker') {\n this.isConfirmButtondisabled = true;\n this.isSendMeBackClicked = true;\n this.isRejectClicked = false;\n this.isOtherClicked = false;\n\n } else if (code === 'Approve') {\n this.isSendMeBackClicked = false;\n this.isConfirmButtondisabled = false;\n this.isRejectClicked = false;\n this.isOtherClicked = false;\n\n } else if (code === 'Reject') {\n this.isRejectClicked = true;\n this.isSendMeBackClicked = false;\n this.isOtherClicked = false;\n this.RefundsService.getRefundRejectReasons().subscribe(\n refundRejectReasonList => {\n this.refundRejectReasonList = <any>refundRejectReasonList;\n },\n err => {\n this.errorMessage = this.getErrorMessage(true, err.statusCode, err.err, err);\n }\n );\n } else if (code === 'RE005') {\n this.isOtherClicked = true;\n } else if (code !== 'RE005') {\n this.isOtherClicked = false;\n }\n }\n\n getNotificationPreviewObj(notificationPreviewObj : INotificationPreview){\n this.notificationPreviewObj = notificationPreviewObj;\n }\n\n processRefundSubmit() {\n let processRefundRequest;\n let status;\n this.resetForm([false, false, false, false, false, false, false, false], 'all');\n const controls = this.processRefundForm.controls;\n const processFormError = controls.sendMeBackField.errors;\n\n if (this.processRefundForm.dirty && controls.refundActionField.valid\n && (controls.refundActionField.value == 'Approve'\n || (controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.valid && controls.refundRejectReasonField.value != 'RE005')\n || (controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.value == 'RE005' && controls.enterReasonField.valid)\n || (controls.refundActionField.value == 'Return to caseworker' && controls.sendMeBackField.valid))) {\n if (controls.refundActionField.value === 'Approve'){\n status = 'APPROVE';\n if (this.notificationPreviewObj) {\n processRefundRequest = {\n code: '',\n reason: '',\n template_preview: {\n body: this.notificationPreviewObj.body,\n from: {\n from_email_address: this.notificationPreviewObj.from.from_email_address,\n from_mail_address: {\n address_line: this.notificationPreviewObj.from.from_mail_address.address_line,\n city: this.notificationPreviewObj.from.from_mail_address.city,\n country: this.notificationPreviewObj.from.from_mail_address.country,\n county: this.notificationPreviewObj.from.from_mail_address.county,\n postal_code: this.notificationPreviewObj.from.from_mail_address.postal_code\n }\n },\n html: this.notificationPreviewObj.html,\n id: this.notificationPreviewObj.template_id,\n subject: this.notificationPreviewObj.subject,\n template_type: this.notificationPreviewObj.template_type,\n version: 0\n }\n };\n\n } else {\n processRefundRequest = {\n code: '',\n reason: ''\n };\n }\n } else if (controls.refundActionField.value === 'Reject') {\n status = 'REJECT';\n\n if (this.notificationPreviewObj) {\n processRefundRequest = {\n code: controls.refundRejectReasonField.value ? controls.refundRejectReasonField.value : '',\n reason: controls.refundRejectReasonField.value == 'RE005' ? controls.enterReasonField.value : '',\n template_preview: {\n body: this.notificationPreviewObj.body,\n from: {\n from_email_address: this.notificationPreviewObj.from.from_email_address,\n from_mail_address: {\n address_line: this.notificationPreviewObj.from.from_mail_address.address_line,\n city: this.notificationPreviewObj.from.from_mail_address.city,\n country: this.notificationPreviewObj.from.from_mail_address.country,\n county: this.notificationPreviewObj.from.from_mail_address.county,\n postal_code: this.notificationPreviewObj.from.from_mail_address.postal_code\n }\n },\n html: this.notificationPreviewObj.html,\n id: this.notificationPreviewObj.template_id,\n subject: this.notificationPreviewObj.subject,\n template_type: this.notificationPreviewObj.template_type,\n version: 0\n }\n };\n } else {\n processRefundRequest = {\n code: controls.refundRejectReasonField.value ? controls.refundRejectReasonField.value : '',\n reason: controls.refundRejectReasonField.value == 'RE005' ? controls.enterReasonField.value : ''\n };\n }\n\n\n } else if (controls.refundActionField.value === 'Return to caseworker') {\n status = 'SENDBACK';\n\n if (this.notificationPreviewObj) {\n processRefundRequest = {\n code: '',\n reason: controls.sendMeBackField.value,\n template_preview: {\n body: this.notificationPreviewObj.body,\n from: {\n from_email_address: this.notificationPreviewObj.from.from_email_address,\n from_mail_address: {\n address_line: this.notificationPreviewObj.from.from_mail_address.address_line,\n city: this.notificationPreviewObj.from.from_mail_address.city,\n country: this.notificationPreviewObj.from.from_mail_address.country,\n county: this.notificationPreviewObj.from.from_mail_address.county,\n postal_code: this.notificationPreviewObj.from.from_mail_address.postal_code\n }\n },\n html: this.notificationPreviewObj.html,\n id: this.notificationPreviewObj.template_id,\n subject: this.notificationPreviewObj.subject,\n template_type: this.notificationPreviewObj.template_type,\n version: 0\n }\n };\n } else {\n processRefundRequest = {\n code: '',\n reason: controls.sendMeBackField.value\n };\n\n }\n\n\n }\n this.RefundsService.patchRefundActions(processRefundRequest, this.refundReference, status).subscribe(\n response => {\n this.isSuccesspageEnable = true;\n // this.successMsg = JSON.parse(response)['data'];\n this.successMsg = response.replace(/['\"]+/g, '');\n },\n err => {\n this.errorMessage = this.getErrorMessage(true, err.statusCode, err.err, err);\n }\n );\n } else {\n if(controls.refundActionField.value == \"\") {\n this.resetForm([true, false, false, false, false, false, false, false], 'action');\n }\n if(controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.value == \"\") {\n this.resetForm([false, true, false, false, false, false, false, false], 'rejectReason');\n }\n if(controls.refundActionField.value == 'Return to caseworker') {\n if(controls.sendMeBackField.value == '' ) {\n this.resetForm([false, false, true, false, false, false, false, false], 'addAreason');\n }\n if(controls.sendMeBackField.value != '' && controls.sendMeBackField.invalid ) {\n this.resetForm([false, false, false, true, false, false, false, false], 'addAreason');\n }\n if(processFormError && processFormError.minlength && processFormError.minlength.actualLength < 3 ) {\n this.resetForm([false, false, false, false, true, false, false, false], 'addAreason');\n }\n if(processFormError && processFormError.maxlength && processFormError.maxlength.actualLength > 255 ) {\n this.resetForm([false, false, false, false, false, true, false, false], 'addAreason');\n }\n }\n if(controls.refundActionField.value == 'Reject' && controls.refundRejectReasonField.value == 'RE005') {\n if(controls.enterReasonField.value === \"\") {\n this.resetForm([false, false, false, false, false, false, true, false], 'enterReason');\n }\n if(controls.enterReasonField.value!== \"\" && controls.enterReasonField.invalid) {\n this.resetForm([false, false, false, false, false, false, false, true], 'enterReason');\n }\n }\n }\n\n }\n getErrorMessage(isErrorExist, status, errorMsg, err) {\n let bodyTxt = 'Please try again later';\n if (status !== 500) {\n if (errorMsg !== undefined) {\n bodyTxt = errorMsg;\n } else {\n bodyTxt = err;\n }\n\n }\n return {\n title: 'Something went wrong',\n body: bodyTxt,\n showError: isErrorExist\n };\n }\n loadRefundListPage() {\n this.OrderslistService.getnavigationPageValue().subscribe((data) => this.navigationpage = data);\n if (this.navigationpage === 'casetransactions') {\n // window.location.href='/refund-list?takePayment=false&refundlist=true';\n // // this.OrderslistService.setnavigationPage('casetransactions');\n // // this.OrderslistService.setisFromServiceRequestPage(false);\n // // this.paymentLibComponent.VIEW ='case-transactions';\n // // this.paymentLibComponent.viewName = 'case-transactions';\n // // this.paymentLibComponent.ISBSENABLE = true;\n // // this.paymentLibComponent.isRefundStatusView = false;\n this.paymentLibComponent.viewName = 'refundstatuslist';\n this.paymentLibComponent.isRefundStatusView = true;\n } else {\n this.paymentLibComponent.viewName = 'refundstatuslist';\n this.paymentLibComponent.isRefundStatusView = true;\n }\n }\n loadRefundsHomePage() {\n if(typeof this.paymentLibComponent.TAKEPAYMENT === 'string' && this.paymentLibComponent.TAKEPAYMENT === 'false') {\n //window.location.href='/refund-list?takePayment=false&refundlist=true';\n this.paymentLibComponent.viewName = 'refund-list';\n }\n else {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.VIEW ='case-transactions';\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n }\n }\n redirecttoRefundListPage() {\n if((typeof this.paymentLibComponent.TAKEPAYMENT === 'string' && this.paymentLibComponent.TAKEPAYMENT === 'false') || (typeof this.paymentLibComponent.TAKEPAYMENT === 'boolean' && !this.paymentLibComponent.TAKEPAYMENT) ) {\n // window.location.href='/refund-list?takePayment=false&refundlist=true';\n this.paymentLibComponent.viewName = 'refund-list';\n }\n else {\n this.loadRefundListPage();\n }\n }\n loadCaseTransactionPage() {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n }\n\n resetForm(vals, field) {\n if(field==='action' || field==='all') {\n this.refundActionsHasError = vals[0];\n }\n if(field==='rejectReason' || field==='all') {\n this.refundRejectReasonHasError = vals[1];\n }\n if(field==='addAreason' || field==='all') {\n this.isReasonFieldEmpty = vals[2];\n this.isReasonFieldInvalid = vals[3];\n this.reasonFieldMinHasError = vals[4];\n this.reasonFieldMaxHasError = vals[5];\n }\n if(field==='enterReason' || field==='all') {\n this.isReasonEmpty = vals[6];\n this.isReasonInvalid = vals[7];\n }\n }\n\n goToCaseReview() {\n const isPayBubble = this.paymentLibComponent.isFromPayBubble;\n if(isPayBubble) {\n this.loadCaseTransactionPage();\n } else {\n this.router.navigate([`/cases/case-details/${this.ccdCaseNumber}`], {relativeTo: this.activeRoute});\n }\n }\n\n getTemplateInstructionType(payment: IPayment, paymentReference: string): void {\n\n if (payment == undefined || payment == null || payment.reference != paymentReference) {\n\n this.paymentViewService.getPaymentDetails(paymentReference).subscribe(\n payment => {\n this.paymentObj = payment;\n this.paymentObj.reference = paymentReference;\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(this.paymentObj.channel, this.paymentObj.method);\n },\n (error: any) => {\n this.templateInstructionType = 'Template';\n })\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n}\n","import {Component, OnInit, Input} from '@angular/core';\nimport { RefundsService } from '../../services/refunds/refunds.service';\nimport { IRefundList } from '../../interfaces/IRefundList';\n\n@Component({\n selector: 'ccpay-refund-list',\n templateUrl: './refund-list.component.html',\n styleUrls: ['./refund-list.component.css']\n})\nexport class RefundListComponent implements OnInit {\n @Input('USERID') USERID: string;\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: any[];\n @Input('LOGGEDINUSEREMAIL') LOGGEDINUSEREMAIL:string;\n\n constructor(private refundService: RefundsService) {\n }\n\n tableApprovalHeader: string;\n tableRejectedHeader: string;\n submittedRefundList: IRefundList[] = [];\n rejectedRefundList: IRefundList[] = [];\n // approvalStatus = 'Sent for approval';\n // rejectStatus = 'Update required';\n approvalStatus = 'Sent for approval';\n rejectStatus = 'Update required';\n errorMessage = null;\n isApproveTableVisible:boolean;\n isRejectTableVisible:boolean;\n dropdownvalue: string;\n isAuthorized: boolean = true;\n userLst\n ngOnInit() {\n \n this.userLst = this.LOGGEDINUSERROLES;\n\n \n if(this.LOGGEDINUSERROLES.some(i =>i.includes('payments-refund-approver'))){\n this.isAuthorized = true;\n } else {\n this.isApproveTableVisible = false;\n this.isAuthorized = false;\n }\n\n \n this.tableApprovalHeader = 'Refunds to be approved';\n this.tableRejectedHeader = 'Refunds returned to caseworker';\n\n if(this.isAuthorized) {\n this.refundService.getRefundList(this.approvalStatus,true).subscribe(\n refundList => {\n this.submittedRefundList = refundList['refund_list'];\n this.isApproveTableVisible = true;\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n };\n }\n\n this.refundService.getRefundList(this.rejectStatus,false).subscribe(\n refundList => {\n this.rejectedRefundList = refundList['refund_list'];\n this.isRejectTableVisible = true;\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n };\n\n }\n \n}","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {Observable} from 'rxjs/internal/Observable';\n\nimport {ICardDetails} from '../../interfaces/ICardDetails';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport { catchError } from 'rxjs/operators';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { LoggerService } from '../shared/logger/logger.service';\n\n\n@Injectable({\n providedIn: 'root'\n})\nexport class CardDetailsService {\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n getCardDetails(paymentReference: string): Observable<ICardDetails> {\n this.logger.info('Card-detail-service getCardDetails for: ', paymentReference);\n\n return this.http.get<ICardDetails>(`${this.paymentLibService.API_ROOT}/card-payments/${paymentReference}/details`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Component, OnInit } from '@angular/core';\nimport { CardDetailsService } from '../../services/card-details/card-details.service';\nimport {ICardDetails} from '../../interfaces/ICardDetails';\nimport { PaymentLibComponent } from '../../payment-lib.component';\n\n@Component({\n selector: 'ccpay-card-details',\n templateUrl: './card-details.component.html',\n styleUrls: ['./card-details.component.css']\n})\nexport class CardDetailsComponent implements OnInit {\n pageTitle: string = 'Card details';\n cardDetails: ICardDetails;\n paymentReference: string;\n errorMessage: string;\n\n constructor(private cardDetailsService: CardDetailsService,\n private paymentLibComponent: PaymentLibComponent) { }\n\n ngOnInit() {\n this.cardDetailsService.getCardDetails(this.paymentLibComponent.paymentReference).subscribe(\n cardDetails => this.cardDetails = cardDetails,\n (error: any) => this.errorMessage = <any>error\n );\n }\n\n get getPaymentReference(): string {\n return this.paymentReference;\n }\n\n}\n","import { Component } from '@angular/core';\n\n@Component({\n template: `\n <h1>This is not the page you were looking for!</h1>\n `\n})\nexport class PageNotFoundComponent { }\n","import { Injectable } from '@angular/core';\nimport { PaymentLibService } from '../../payment-lib.service';\nimport { HttpClient } from '@angular/common/http';\nimport { IStatusHistories } from '../../interfaces/IStatusHistories';\nimport { Observable } from 'rxjs/internal/Observable';\nimport { ErrorHandlerService } from '../shared/error-handler.service';\nimport { catchError } from 'rxjs/operators';\nimport { LoggerService } from '../shared/logger/logger.service';\n\n\n@Injectable({\n providedIn: 'root'\n})\nexport class StatusHistoryService {\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService) { }\n\n getPaymentStatusesByReference(paymentReference: string, paymentMethod: string): Observable<IStatusHistories> {\n this.logger.info('Status-history-service getPaymentStatusesByReference for: ', paymentReference);\n\n return this.http.get<IStatusHistories>(paymentMethod === 'card' || paymentMethod === 'cash' || paymentMethod === 'cheque' || paymentMethod === 'postal order' ?\n `${this.paymentLibService.API_ROOT}/card-payments/${paymentReference}/statuses` :\n `${this.paymentLibService.API_ROOT}/credit-account-payments/${paymentReference}/statuses`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { IStatusHistories } from '../../interfaces/IStatusHistories';\nimport { StatusHistoryService } from '../../services/status-history/status-history.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\n\n@Component({\n selector: 'ccpay-payment-statuses',\n templateUrl: './status-history.component.html',\n styleUrls: ['./status-history.component.css']\n})\nexport class StatusHistoryComponent implements OnInit {\n @Input() isTakePayment: boolean;\n pageTitle: string = 'Payment status history';\n statuses: IStatusHistories;\n errorMessage: string;\n\n constructor(private statusHistoryService: StatusHistoryService,\n private paymentLibComponent: PaymentLibComponent) { }\n\n ngOnInit() {\n this.statusHistoryService.getPaymentStatusesByReference(this.paymentLibComponent.paymentReference, this.paymentLibComponent.paymentMethod).subscribe(\n statuses => this.statuses = statuses,\n (error: any) => this.errorMessage = <any>error.replace(/\"/g,\"\")\n );\n \n }\n\n}\n","import { Component, OnInit, Output, EventEmitter, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { NotificationService } from '../../services/notification/notification.service';\n\n@Component({\n selector: 'ccpay-contact-details',\n templateUrl: './contact-details.component.html',\n styleUrls: ['./contact-details.component.css']\n})\nexport class ContactDetailsComponent implements OnInit {\n @Input('isEditOperation') isEditOperation: boolean;\n @Input('isEditOperationInRefundList') isEditOperationInRefundList: boolean;\n @Input('addressObj') addressObj: any;\n @Output() assignContactDetails: EventEmitter<any> = new EventEmitter();\n @Output() assignContactDetailsInFefundsList: EventEmitter<any> = new EventEmitter();\n @Output() redirectToIssueRefund: EventEmitter<any> = new EventEmitter();\n pageTitle: string = 'Payment status history';\n errorMessage: string;\n isEmailSAddressClicked: boolean = true;\n isShowPickAddress: boolean = false;\n isPostcodeClicked: boolean = false;\n isManualAddressClicked: boolean = false;\n emailAddressForm: FormGroup;\n postCodeForm: FormGroup;\n manualAddressForm: FormGroup;\n addressPostcodeList:any[] = [];\n postcodeAddress:any;\n isAddressBoxEmpty: boolean = false;\n\n isEmailEmpty: boolean = false;\n emailHasError: boolean = false;\n isPostcodeEmpty: boolean = false;\n postcodeHasError: boolean = false;\n isaddressLine1Empty: boolean = false;\n addressLine1HasError: boolean = false;\n addressLine2HasError: boolean = false;\n isTownOrCityEmpty: boolean = false;\n townOrCityHasError: boolean = false;\n isCountyEmpty: boolean = false;\n countyHasError: boolean = false;\n isMPostcodeEmpty: boolean = false;\n mpostcodeHasError: boolean = false;\n isCountryEmpty: boolean = false;\n\n constructor(private formBuilder: FormBuilder,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent) { }\n\n ngOnInit() {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n\n this.emailAddressForm = this.formBuilder.group({\n email: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('.+@+.+\\\\.+.+')\n ]))\n });\n this.postCodeForm = this.formBuilder.group({\n postcode: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([A-Za-z]{1,2}[0-9]{1,2}[A-Za-z]{0,1} ?[0-9][A-Za-z]{2})')\n ]))\n });\n this.manualAddressForm = this.formBuilder.group({\n addressl1: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n addressl2: new FormControl('', Validators.compose([\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n townorcity: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n county: new FormControl('', Validators.compose([\n Validators.pattern('^[a-zA-Z0-9\\\\s,\\'-]*$')\n ])),\n mpostcode: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([A-Za-z]{1,2}[0-9]{1,2}[A-Za-z]{0,1} ?[0-9][A-Za-z]{2})')\n ])),\n country: new FormControl('', Validators.compose([\n Validators.required\n ]))\n });\n if(this.addressObj !== undefined && this.addressObj !== '') {\n this.setEditDetails();\n }\n if(this.isEditOperationInRefundList === undefined) {\n this.isEditOperationInRefundList = false;\n }\n }\n setEditDetails() {\n if(this.addressObj.notification_type === 'EMAIL') {\n this.isEmailSAddressClicked = true;\n this.isPostcodeClicked = false;\n this.isManualAddressClicked = false;\n this.emailAddressForm.setValue({ email: this.addressObj.contact_details.email });\n } else if(this.addressObj.notification_type === 'LETTER') {\n this.isEmailSAddressClicked = false;\n this.isPostcodeClicked = true;\n this.isManualAddressClicked = true;\n this.manualAddressForm.patchValue({ \n addressl1: this.addressObj.contact_details.address_line,\n townorcity: this.addressObj.contact_details.city,\n county: this.addressObj.contact_details.county,\n country: this.addressObj.contact_details.country,\n mpostcode: this.addressObj.contact_details.postal_code\n });\n }\n }\n\n selectContactOption(type, isLinkedClied) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n if( type === 'Email' && isLinkedClied === 'false'){\n this.isEmailSAddressClicked = true;\n this.isPostcodeClicked = false;\n this.isManualAddressClicked = false;\n } else if(type === 'Postcode' && isLinkedClied === 'false') {\n this.isEmailSAddressClicked = false;\n this.isPostcodeClicked = true;\n this.isManualAddressClicked = false;\n } else if(type === 'Postcode' && isLinkedClied === 'true') {\n this.isEmailSAddressClicked = false;\n this.isPostcodeClicked = true;\n this.isManualAddressClicked = true;\n\n }\n }\n\n finalFormSubmit() {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n if( this.isEmailSAddressClicked ){\n const emailField = this.emailAddressForm.controls.email;\n if (this.emailAddressForm.valid) {\n if(!this.isEditOperationInRefundList) {\n this.assignContactDetails.emit( {\n email: emailField.value,\n notification_type: 'EMAIL'\n } );\n } else {\n this.assignContactDetailsInFefundsList.emit({\n email: emailField.value,\n notification_type: 'EMAIL'\n } );\n }\n } else {\n if( emailField.value == '' ) {\n this.resetForm([true,false,false,false,false,false,false,false,false,false,false,false,false,false], 'email');\n }\n if(emailField.value != '' && emailField.invalid ) {\n this.resetForm([false,true,false,false,false,false,false,false,false,false,false,false,false,false], 'email');\n }\n }\n } else if( this.isPostcodeClicked && !this.isManualAddressClicked ) {\n this.postcodeValidation('FS');\n } else if(this.isPostcodeClicked && this.isManualAddressClicked) {\n const fieldCtrls = this.manualAddressForm.controls;\n if (this.manualAddressForm.valid) {\n if(!this.isEditOperationInRefundList) {\n this.assignContactDetails.emit({\n address_line: fieldCtrls.addressl1.value+' '+fieldCtrls.addressl2.value,\n city: fieldCtrls.townorcity.value,\n county: fieldCtrls.county.value,\n postal_code: fieldCtrls.mpostcode.value,\n country: fieldCtrls.country.value,\n notification_type: 'LETTER'\n });\n } else {\n this.assignContactDetailsInFefundsList.emit({\n address_line: fieldCtrls.addressl1.value+' '+fieldCtrls.addressl2.value,\n city: fieldCtrls.townorcity.value,\n county: fieldCtrls.county.value,\n postal_code: fieldCtrls.mpostcode.value,\n country: fieldCtrls.country.value,\n notification_type: 'LETTER'\n });\n }\n } else {\n if( fieldCtrls.addressl1.value == '' ) {\n this.resetForm([false,false,false,false,true,false,false,false,false,false,false,false,false,false], 'address1');\n }\n if(fieldCtrls.addressl1.value != '' && fieldCtrls.addressl1.invalid ) {\n this.resetForm([false,false,false,false,false,true,false,false,false,false,false,false,false,false], 'address1');\n }\n if(fieldCtrls.addressl2.value != '' && fieldCtrls.addressl2.invalid ) {\n this.resetForm([false,false,false,false,false,false,true,false,false,false,false,false,false,false], 'address2');\n }\n if( fieldCtrls.townorcity.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,true,false,false,false,false,false,false], 'town');\n }\n if(fieldCtrls.townorcity.value != '' && fieldCtrls.townorcity.invalid ) {\n this.resetForm([false,false,false,false,false,false,false,false,true,false,false,false,false,false], 'town');\n }\n if( fieldCtrls.county.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,true,false,false,false,false], 'county');\n }\n if(fieldCtrls.county.value != '' && fieldCtrls.county.invalid ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,true,false,false,false], 'county');\n }\n if( fieldCtrls.mpostcode.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,true,false,false], 'mpostcode');\n }\n if(fieldCtrls.mpostcode.value != '' && fieldCtrls.mpostcode.invalid ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,true,false], 'mpostcode');\n }\n if( fieldCtrls.country.value == '' ) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,true], 'country');\n }\n }\n\n }\n\n }\n\n postcodeValidation(str) {\n this.resetForm([false,false,false,false,false,false,false,false,false,false,false,false,false,false,false], 'all');\n const postcodeField = this.postCodeForm.controls.postcode;\n if (this.postCodeForm.valid) {\n if(str === 'FA') {\n this.notificationService.getAddressByPostcode(postcodeField.value).subscribe(\n refundsNotification => {\n this.addressPostcodeList = refundsNotification['results'];\n this.isShowPickAddress = refundsNotification['header'].totalresults > 0;\n if(!this.isShowPickAddress) {\n this.resetForm([false,false,false,true,false,false,false,false,false,false,false,false,false], 'postcode');\n }\n }\n ),\n (error: any) => {\n this.isShowPickAddress = false;\n this.errorMessage = error.replace(/\"/g,\"\");\n }; \n } else if (str === 'FS') {\n if(this.postcodeAddress !== undefined && this.postcodeAddress) {\n this.isAddressBoxEmpty = false;\n let addressLine=\"\";\n let addressArray = this.postcodeAddress.ADDRESS.split(\",\");\n for( let i=0; i<addressArray.length-2; i++ ) {\n addressLine +=addressArray[i]; \n }\n const addressObject = {\n address_line: addressLine,\n city: this.postcodeAddress.POST_TOWN,\n county: this.postcodeAddress.LOCAL_CUSTODIAN_CODE_DESCRIPTION,\n postal_code: this.postcodeAddress.POSTCODE,\n country: 'United Kingdom',\n notification_type: 'LETTER'\n };\n if(!this.isEditOperationInRefundList) {\n this.assignContactDetails.emit(addressObject);\n } else {\n this.assignContactDetailsInFefundsList.emit(addressObject);\n }\n } else {\n this.isAddressBoxEmpty = true;\n }\n }\n } else {\n if( postcodeField.value == '' ) {\n this.resetForm([false,false,true,false,false,false,false,false,false,false,false,false,false], 'postcode');\n }\n if(postcodeField.value != '' && postcodeField.invalid ) {\n this.resetForm([false,false,false,true,false,false,false,false,false,false,false,false,false], 'postcode');\n }\n }\n }\n redirection(event:any) {\n this.redirectToIssueRefund.emit(event);\n }\n resetForm(val, field) {\n if(field==='email' || field==='all') {\n this.isEmailEmpty = val[0];\n this.emailHasError = val[1];\n }\n if(field==='postcode' || field==='all') {\n this.isPostcodeEmpty = val[2];\n this.postcodeHasError = val[3];\n }\n if(field==='address1' || field==='all') {\n this.isaddressLine1Empty = val[4];\n this.addressLine1HasError = val[5];\n }\n if(field==='address2' || field==='all') {\n this.addressLine2HasError = val[6];\n }\n if(field==='town' || field==='all') {\n this.isTownOrCityEmpty = val[7];\n this.townOrCityHasError = val[8];\n }\n if(field==='county' || field==='all') {\n this.isCountyEmpty = val[9];\n this.countyHasError = val[10];\n }\n if(field==='mpostcode' || field==='all') {\n this.isMPostcodeEmpty = val[11];\n this.mpostcodeHasError = val[12];\n }\n if(field==='country' || field==='all') {\n this.isCountryEmpty = val[13];\n }\n \n }\n}\n","import { Component, Input, OnInit } from '@angular/core';\nimport { IPayment } from '../../interfaces/IPayment';\n\n@Component({\n selector: 'ccpay-pba-details',\n templateUrl: './pba-details.component.html',\n styleUrls: ['./pba-details.component.css']\n})\nexport class PbaDetailsComponent implements OnInit {\n @Input() payment: IPayment;\n\n constructor() { }\n\n ngOnInit() {\n }\n\n}\n","import { Injectable } from '@angular/core';\nimport { Logger } from './logger.service';\n\nexport let isDebugMode = false;\n\nconst noop = (): any => undefined;\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ConsoleLoggerService implements Logger {\n\n get info() {\n if (isDebugMode) {\n return console.info.bind(console);\n } else {\n return noop;\n }\n }\n\n get warn() {\n if (isDebugMode) {\n return console.warn.bind(console);\n } else {\n return noop;\n }\n }\n\n get error() {\n if (isDebugMode) {\n return console.error.bind(console);\n } else {\n return noop;\n }\n }\n\n invokeConsoleMethod(type: string, args?: any): void {\n const logFn: Function = (console)[type] || console.log || noop;\n logFn.apply(console, [args]);\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {LoggerService} from '../shared/logger/logger.service';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport {catchError} from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class CaseTransactionsService {\n\n constructor(private http: HttpClient,\n private logger: LoggerService,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService\n ) { }\n\n getPaymentGroups(ccdCaseNumber: string): Observable<IPaymentGroup[]> {\n this.logger.info('Case-transactions-service getPaymentGroups for: ', ccdCaseNumber);\n\n return this.http.get<IPaymentGroup[]>(`${this.paymentLibService.API_ROOT}/cases/${ccdCaseNumber}/paymentgroups`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport {HttpClient} from '@angular/common/http';\nimport {ErrorHandlerService} from '../shared/error-handler.service';\nimport { WebComponentHttpClient } from '../shared/httpclient/webcomponent.http.client';\nimport {PaymentLibService} from '../../payment-lib.service';\nimport {Observable} from 'rxjs/Observable';\nimport {catchError} from 'rxjs/operators';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\n\n\n@Injectable({\n providedIn: 'root'\n})\nexport class BulkScaningPaymentService {\n\n constructor(private http: HttpClient,\n private https: WebComponentHttpClient,\n private errorHandlerService: ErrorHandlerService,\n private paymentLibService: PaymentLibService\n ) { }\n\n getBSPaymentsByCCD(ccdCaseNumber: string): Observable<IBSPayments> {\n return this.http.get<IBSPayments>(`${this.paymentLibService.BULKSCAN_API_ROOT}/cases/${ccdCaseNumber}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n getBSPaymentsByDCN(dcn: string): Observable<IBSPayments> {\n return this.http.get<IBSPayments>(`${this.paymentLibService.BULKSCAN_API_ROOT}/cases?document_control_number=${dcn}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSAllocatePayment(body: AllocatePaymentRequest, paymentRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentRef}/bulk-scan-payments`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSPaymentStrategic(body: AllocatePaymentRequest, paymentGroupRef: string): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/${paymentGroupRef}/bulk-scan-payments-strategic`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n postBSWoPGStrategic(body: AllocatePaymentRequest): Observable<any> {\n return this.https.post(`${this.paymentLibService.API_ROOT}/payment-groups/bulk-scan-payments-strategic`, body).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n patchBSChangeStatus(dcnNumber: string, status: string): Observable<any> {\n return this.https.patch(`${this.paymentLibService.API_ROOT}/bulk-scan-payments/${dcnNumber}/status/${status}`, status).pipe(\n catchError(this.errorHandlerService.handleError)\n );\n }\n calculateOutStandingAmount(paymentGroup: IPaymentGroup): number {\n let feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00;\n\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n feesTotal = feesTotal + fee.calculated_amount;\n });\n }\n\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n }\n });\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n remissionsTotal = remissionsTotal + remission.hwf_amount;\n });\n } \n return (feesTotal - remissionsTotal) - paymentsTotal;\n }\n\n removeUnwantedString(input: string, replaceText: string) {\n const pattern = /[\\_]/gi;\n return input.replace(pattern, replaceText);\n }\n\n downloadSelectedReport(reportName: string, startDate: string, endDate:string): Observable<any> {\n return this.https.get(`${this.paymentLibService.BULKSCAN_API_ROOT}/report/data?date_from=${startDate}&date_to=${endDate}&report_type=${reportName}`, {\n withCredentials: true\n })\n .pipe(\n catchError(this.errorHandlerService.handleError)\n );\n}\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { CaseTransactionsService } from '../../services/case-transactions/case-transactions.service';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IFee } from '../../interfaces/IFee';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { IPaymentView } from '../../interfaces/IPaymentView';\nimport { IOrderReferenceFee } from '../../interfaces/IOrderReferenceFee';\nimport { Router } from '@angular/router';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\n\n@Component({\n selector: 'ccpay-case-transactions',\n templateUrl: './case-transactions.component.html',\n styleUrls: ['./case-transactions.component.css']\n})\nexport class CaseTransactionsComponent implements OnInit {\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[];\n @Input() isTakePayment: boolean;\n @Input() isFromServiceRequestPage: boolean;\n takePayment: boolean;\n ccdCaseNumber: string;\n excReference: string;\n paymentGroups: any[] = [];\n payments: IPayment[] = [];\n nonPayments: IPayment[] = [];\n allPayments: IPayment[] = [];\n remissions: IRemission[] = [];\n fees: IFee[] = [];\n errorMessage: string;\n totalFees: number;\n totalPayments: number = 0;\n totalNonOffPayments: number;\n totalRemissions: number = 0;\n selectedOption: string;\n dcnNumber: string;\n paymentRef: string;\n isTurnOff: boolean;\n isRefundRemission: boolean = true;\n isStrategicFixEnable: boolean;\n isAddFeeBtnEnabled: boolean = true;\n isExceptionRecord: boolean = false;\n isUnprocessedRecordSelected: boolean = false;\n exceptionRecordReference: string;\n isAnyFeeGroupAvilable: boolean = true;\n isHistoricGroupAvailable: boolean = false;\n isBulkScanEnable;\n isRemissionsMatch: boolean;\n viewStatus = 'main';\n isRemoveBtnDisabled: boolean = false;\n feeId: IFee;\n clAmountDue: number = 0;\n overPaymentAmount: number = 0;\n unprocessedRecordCount: number;\n isFeeRecordsExist: boolean = false;\n isGrpOutstandingAmtPositive: boolean = false;\n totalRefundAmount: number;\n caseType: String;\n // lsCcdNumber: any = ls.get<any>('ccdNumber');\n payment: IPayment;\n paymentGroup: IPaymentGroup;\n paymentView: IPaymentView;\n\n //Order changes\n orderDetail: any[] = [];\n\n isAddRemissionEnable: boolean = false;\n orderRemissionDetails: any[] = [];\n orderLevelFees: IOrderReferenceFee[] = [];\n ispaymentGroupApisuccess: boolean = false;\n cpoDetails: any[] = null;\n orderRef: string;\n orderStatus: string;\n orderParty: string;\n orderCreated: Date;\n orderCCDEvent: string;\n serviceRequestValue: string;\n orderAddBtnEnable: boolean;\n orderFeesTotal: number = 0.00;\n orderRemissionTotal: number = 0.00;\n orderTotalPayments: number = 0.00;\n orderPendingPayments: number = 0.00;\n isCPODown: boolean;\n test: boolean;\n isPBA: boolean = false;\n isIssueRefunfBtnEnable: boolean = false;\n isAddRemissionBtnEnabled: boolean = false;\n isRefundRemissionBtnEnable: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund'];\n isEligible4PBAPayment = ['pui-finance-manager', 'pui-user-manager', 'pui-organisation-manager', 'pui-case-manager'];\n currentDate = new Date();\n //isFromServiceRequestPage: boolean;\n navigationpage: string;\n remissionFeeAmt: number;\n constructor(private router: Router,\n private paymentViewService: PaymentViewService,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private caseTransactionsService: CaseTransactionsService,\n private paymentLibComponent: PaymentLibComponent,\n private OrderslistService: OrderslistService\n ) { }\n\n ngOnInit() {\n this.navigationpage = '';\n if(this.OrderslistService.getpaymentPageView() !== null) {\n this.OrderslistService.getpaymentPageView().subscribe((data) => this.paymentView = data);\n }\n if((this.LOGGEDINUSERROLES === undefined || this.LOGGEDINUSERROLES.length === 0 )&&this.OrderslistService.getUserRolesList() !== null) {\n this.OrderslistService.getUserRolesList().subscribe((data) => this.LOGGEDINUSERROLES = data);\n }\n if(this.OrderslistService.getnavigationPageValue() !== null) {\n this.OrderslistService.getnavigationPageValue().subscribe((data) => this.navigationpage = data);\n }\n\n if (this.paymentView !== undefined && this.paymentView !== null && this.paymentView.payment_group_reference !== undefined && this.navigationpage === 'paymentdetailspage') {\n this.goToPayementView(this.paymentView.payment_group_reference, this.paymentView.reference, this.paymentView.method);\n }\n this.isGrpOutstandingAmtPositive = false;\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.caseType = this.paymentLibComponent.CASETYPE;\n if (this.paymentLibComponent.CCD_CASE_NUMBER === '') {\n this.ccdCaseNumber = this.paymentLibComponent.EXC_REFERENCE;\n }\n this.excReference = this.paymentLibComponent.EXC_REFERENCE;\n this.takePayment = this.paymentLibComponent.TAKEPAYMENT;\n\n const serviceRequest = this.paymentLibComponent.SERVICEREQUEST;\n if ( serviceRequest !== undefined && serviceRequest.toString() === 'true' ) {\n this.serviceRequestValue = 'true';\n } else {\n this.serviceRequestValue = 'false';\n this.paymentLibComponent.isFromServiceRequestPage = false;\n }\n this.isBulkScanEnable = this.paymentLibComponent.ISBSENABLE;\n this.dcnNumber = this.paymentLibComponent.DCN_NUMBER;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION.toLocaleLowerCase();\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n if (!this.isTurnOff) {\n // if (this.lsCcdNumber !== this.ccdCaseNumber) {\n // this.router.navigateByUrl(`/ccd-search?takePayment=true`);\n // }\n\n this.caseTransactionsService.getPaymentGroups(this.ccdCaseNumber).subscribe(\n paymentGroups => {\n this.isAnyFeeGroupAvilable =true;\n this.paymentGroups = paymentGroups['payment_groups'];\n this.calculateAmounts();\n this.calculateOrderFeesAmounts();\n this.calculateRefundAmount();\n if (this.isFromServiceRequestPage) {\n this.OrderslistService.getSelectedOrderRefId().subscribe((data) => this.orderRef = data);\n this.goToOrderViewDetailSection(this.orderRef);\n } else {\n this.paymentViewService.getPartyDetails(this.ccdCaseNumber).subscribe(\n response => {\n this.cpoDetails = JSON.parse(response).content;\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.isCPODown = true;\n }\n );\n\n }\n\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.isAnyFeeGroupAvilable = false;\n this.setDefaults();\n }\n );\n } else {\n this.caseTransactionsService.getPaymentGroups(this.ccdCaseNumber).subscribe(\n paymentGroups => {\n this.isAnyFeeGroupAvilable =true;\n this.paymentGroups = paymentGroups['payment_groups'];\n this.calculateAmounts();\n this.calculateOrderFeesAmounts();\n this.totalRefundAmount = this.calculateRefundAmount();\n this.paymentViewService.getPartyDetails(this.ccdCaseNumber).subscribe(\n response => {\n this.cpoDetails = JSON.parse(response).content;\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.setDefaults();\n this.isCPODown = true;\n }\n );\n\n },\n (error: any) => {\n this.errorMessage = <any>error ? error.replace(/\"/g,\"\") : \"\";\n this.isAnyFeeGroupAvilable = false;\n this.setDefaults();\n }\n );\n }\n\n if( this.paymentGroups !== undefined) {\n this.checkForExceptionRecord();\n }\n\n if(this.OrderslistService.getisFromServiceRequestPages() !== null) {\n this.OrderslistService.getisFromServiceRequestPages().subscribe((data) => this.isFromServiceRequestPage = data);\n }\n\n }\n\n setDefaults(): void {\n this.totalPayments = 0.00;\n this.totalRemissions = 0.00;\n this.totalNonOffPayments = 0.00;\n this.totalFees = 0.00;\n }\n\n getAllocationStatus(payments: any) {\n\n let paymentAllocation = payments.payment_allocation,\n isAllocationStatusExist = paymentAllocation.length > 0;\n return isAllocationStatusExist ? paymentAllocation[0].allocation_status : '-';\n //return \"-\";\n\n }\n\n checkForExceptionRecord(): void {\n\n if (this.paymentGroups.length === 0 && (this.selectedOption.toLocaleLowerCase() === 'ccdorexception' || this.selectedOption.toLocaleLowerCase() === 'rc')) {\n this.bulkScaningPaymentService.getBSPaymentsByCCD(this.ccdCaseNumber).subscribe(\n recordData => {\n if (recordData['data'] && recordData['data'].exception_record_reference && recordData['data'].exception_record_reference.length > 0 && recordData['data'].ccd_reference > 0) {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n\n if (recordData['data'] && recordData['data'].exception_record_reference && recordData['data'].exception_record_reference.length > 0 && recordData['data'].ccd_reference === undefined) {\n this.isExceptionRecord = true;\n this.isAddFeeBtnEnabled = false;\n }\n\n if (recordData['data'] && recordData['data'].exception_record_reference && recordData['data'].exception_record_reference.length === undefined && recordData['data'].ccd_reference > 0) {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n });\n }\n\n if (this.paymentGroups.length === 0 && this.selectedOption.toLocaleLowerCase() === 'dcn') {\n if (this.paymentLibComponent.CCD_CASE_NUMBER.length > 0 && this.paymentLibComponent.EXC_REFERENCE.length > 0) {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n } else if (this.paymentLibComponent.CCD_CASE_NUMBER.length === 0 && this.paymentLibComponent.EXC_REFERENCE.length > 0) {\n this.isExceptionRecord = true;\n this.isAddFeeBtnEnabled = false;\n } else {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n }\n if (this.paymentGroups.length > 0)\n this.paymentGroups.forEach(paymentGroup => {\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.case_reference !== undefined && payment.ccd_case_number === undefined) {\n this.isExceptionRecord = true;\n this.isAddFeeBtnEnabled = false;\n } else {\n this.isExceptionRecord = false;\n this.isAddFeeBtnEnabled = true;\n }\n\n });\n }\n });\n }\n\n calculateOrderFeesAmounts(): void {\n let feesTotal = 0.00;\n this.paymentGroups.forEach((paymentGroup, index) => {\n\n this.resetOrderVariables();\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n this.orderFeesTotal = this.orderFeesTotal + fee.calculated_amount\n this.overPaymentAmount = this.overPaymentAmount + fee.over_payment\n }\n )\n }\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n this.orderRemissionTotal = this.orderRemissionTotal + remission.hwf_amount;\n });\n }\n\n if (paymentGroup.payments) {\n const isFeeOverPaymentExist = this.overPaymentAmount === 0;\n paymentGroup.payments.forEach((payment) => {\n if(isFeeOverPaymentExist) {\n this.overPaymentAmount = this.overPaymentAmount + payment.over_payment\n }\n if (payment.status.toUpperCase() === 'SUCCESS') {\n this.orderTotalPayments = this.orderTotalPayments + payment.amount;\n }\n });\n }\n\n // this.orderPendingPayments = (this.orderFeesTotal - this.orderRemissionTotal) - this.orderTotalPayments;\n if (paymentGroup.service_request_status === 'Paid') {\n this.orderStatus = paymentGroup.service_request_status;\n this.orderAddBtnEnable = false;\n } else if (paymentGroup.service_request_status === 'Partially paid' || paymentGroup.service_request_status === 'Not paid') {\n this.orderStatus = paymentGroup.service_request_status;\n this.orderAddBtnEnable = true;\n } else if (paymentGroup.service_request_status === 'Disputed'){\n this.orderStatus = paymentGroup.service_request_status;\n this.orderAddBtnEnable = true;\n }\n\n //this.orderLevelFees.push({orderRefId:paymentGroup['payment_group_reference'],orderTotalFees: this.orderFeesTotal,orderStatus: this.orderStatus,orderParty:'Santosh', orderCCDEvent:'Case Creation',orderCreated: new Date(), orderAddBtnEnable: this.orderAddBtnEnable}); this.cpoDetails['createdTimestamp']\n if (this.cpoDetails !== null && this.cpoDetails.length !== 0) {\n this.orderLevelFees.push({ orderRefId: paymentGroup['payment_group_reference'], orderTotalFees: this.orderFeesTotal, orderStatus: this.orderStatus, orderParty: this.cpoDetails[index].responsibleParty, orderCCDEvent: this.cpoDetails[index].action, orderCreated: paymentGroup['date_created'], orderAddBtnEnable: this.orderAddBtnEnable });\n\n } else {\n this.orderLevelFees.push({ orderRefId: paymentGroup['payment_group_reference'], orderTotalFees: this.orderFeesTotal, orderStatus: this.orderStatus, orderParty: '', orderCCDEvent: '', orderCreated: paymentGroup['date_created'], orderAddBtnEnable: this.orderAddBtnEnable });\n }\n\n if (this.orderStatus !== 'Paid') {\n this.OrderslistService.setOrdersList(this.orderLevelFees);\n }\n });\n };\n\n resetOrderVariables(): void {\n this.orderFeesTotal = 0.00;\n this.orderTotalPayments = 0.00;\n this.orderRemissionTotal = 0.00;\n this.orderPendingPayments = 0.00;\n this.isAddFeeBtnEnabled = true;\n\n };\n\n goToOrderViewDetailSection(orderReferenceObj: any) {\n if (this.isFromServiceRequestPage) {\n this.OrderslistService.setOrderRefId(orderReferenceObj);\n this.orderRef = orderReferenceObj;\n } else {\n this.OrderslistService.setOrderRefId(orderReferenceObj.orderRefId);\n this.orderRef = orderReferenceObj.orderRefId;\n }\n\n this.orderFeesTotal = 0.00;\n this.orderRemissionTotal = 0.00;\n this.orderTotalPayments = 0.00;\n this.orderPendingPayments = 0.00;\n\n this.orderDetail = this.paymentGroups.filter(x => x.payment_group_reference === this.orderRef);\n this.orderDetail.forEach(orderDetail => {\n if (orderDetail.fees) {\n orderDetail.fees.forEach(fee => {\n this.orderFeesTotal = this.orderFeesTotal + fee.calculated_amount;\n });\n }\n if (orderDetail.remissions) {\n orderDetail.remissions.forEach(remission => {\n this.orderRemissionTotal = this.orderRemissionTotal + remission.hwf_amount;\n });\n if (orderDetail.payments) {\n this.payment = orderDetail.payments[0];\n orderDetail.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n this.orderTotalPayments = this.orderTotalPayments + payment.amount;\n }\n });\n }\n }\n this.orderStatus = orderDetail.service_request_status;\n });\n //this.orderPendingPayments = (this.orderFeesTotal - this.orderRemissionTotal) - this.orderTotalPayments;\n // this.orderRef = orderReferenceObj.orderRefId;\n // if (this.orderPendingPayments <= 0.00) {\n // this.orderStatus = 'Paid';\n // } else if (this.orderFeesTotal > 0 && (this.orderTotalPayments > 0 || this.orderRemissionTotal > 0) && (this.orderTotalPayments < this.orderPendingPayments)) {\n // this.orderStatus = 'Partially paid'\n // } else {\n // this.orderStatus = 'Not paid'\n // }\n\n\n if (this.cpoDetails !== null && this.cpoDetails.length !==0) {\n this.orderParty = this.cpoDetails[0].responsibleParty;\n this.orderCreated = this.cpoDetails[0].createdTimestamp;\n this.orderCCDEvent = this.cpoDetails[0].action;\n } else {\n this.orderParty = '';\n this.orderCCDEvent = '';\n this.orderCreated = orderReferenceObj.orderCreated;\n }\n this.viewStatus = 'order-full-view';\n }\n\n redirectToOrderFeeSearchPage(event: any, orderef: any) {\n if(orderef.orderAddBtnEnable) {\n event.preventDefault();\n this.paymentLibComponent.bspaymentdcn = null;\n this.paymentLibComponent.paymentGroupReference = orderef.orderRefId;\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.viewName = 'fee-summary';\n }\n }\n\n\n\n\n calculateAmounts(): void {\n let feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00,\n nonOffLinePayment = 0.00;\n\n this.paymentGroups.forEach(paymentGroup => {\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n // new feature Apportionment toggle changes\n if (!this.isTurnOff) {\n if (fee.date_created) {\n let a = fee.amount_due === undefined;\n let b = fee.amount_due <= 0;\n this.clAmountDue = a ? this.clAmountDue + fee.net_amount : b ? this.clAmountDue + 0 : this.clAmountDue + fee.amount_due;\n }\n fee['payment_group_reference'] = paymentGroup['payment_group_reference'];\n this.fees.push(fee);\n } else {\n feesTotal = feesTotal + fee.calculated_amount;\n this.fees.push(fee);\n }\n\n });\n }\n if (this.isTurnOff) {\n this.totalFees = feesTotal;\n }\n\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n // new feature Apportionment toggle changes\n if (!this.isTurnOff) {\n let allocationLen = payment.payment_allocation;\n\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n if (allocationLen.length === 0 || allocationLen.length > 0 && allocationLen[0].allocation_status === 'Allocated') {\n nonOffLinePayment = nonOffLinePayment + payment.amount;\n }\n if (allocationLen.length > 0) {\n this.nonPayments.push(payment);\n }\n }\n if (allocationLen.length === 0) {\n this.payments.push(payment);\n }\n payment.paymentGroupReference = paymentGroup.payment_group_reference\n this.allPayments.push(payment);\n } else {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n this.payments.push(payment);\n }\n payment.paymentGroupReference = paymentGroup.payment_group_reference\n this.allPayments.push(payment);\n }\n });\n }\n this.totalPayments = paymentsTotal;\n // new feature Apportionment toggle changes\n if (!this.isTurnOff) {\n this.totalNonOffPayments = nonOffLinePayment;\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remisison => {\n remissionsTotal = remissionsTotal + remisison.hwf_amount;\n this.remissions.push(remisison);\n });\n }\n this.totalRemissions = remissionsTotal;\n });\n\n }\n\n calculateRefundAmount() {\n if (!this.isTurnOff) {\n let isNewPaymentGroup = false;\n\n this.paymentGroups.forEach((paymentGroup, index) => {\n let grpOutstandingAmount = 0.00,\n feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00,\n fees = [];\n\n if (paymentGroup.fees) {\n // this.isFeeRecordsExist = true;\n paymentGroup.fees.forEach(fee => {\n feesTotal = feesTotal + fee.calculated_amount;\n\n this.isRemissionsMatch = false;\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(rem => {\n if (rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n // if(!fees.find(k => k.code=fee.code))\n // {\n fees.push(fee);\n //}\n }\n });\n }\n if (!this.isRemissionsMatch) {\n fees.push(fee);\n }\n\n if (fee.date_created) {\n isNewPaymentGroup = true;\n } else {\n this.isHistoricGroupAvailable = true;\n this.paymentGroups[index]['old'] = true;\n }\n });\n this.paymentGroups[index].fees = fees;\n }\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n }\n });\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n remissionsTotal = remissionsTotal + remission.hwf_amount;\n });\n }\n grpOutstandingAmount = (feesTotal - remissionsTotal) - paymentsTotal;\n if (grpOutstandingAmount > 0 && isNewPaymentGroup) {\n this.isAnyFeeGroupAvilable = true;\n this.isFeeRecordsExist = true;\n this.paymentRef = paymentGroup.payment_group_reference;\n }\n if (paymentGroup.fees && paymentGroup.fees.length > 0 && grpOutstandingAmount <= 0 && isNewPaymentGroup) {\n this.isAnyFeeGroupAvilable = false;\n }\n });\n if ((!isNewPaymentGroup && this.isHistoricGroupAvailable) || (!isNewPaymentGroup && !this.isHistoricGroupAvailable)) {\n this.isAnyFeeGroupAvilable = false;\n }\n } else {\n let totalRefundAmount = 0,\n isFeeAmountZero = false;\n this.paymentGroups.forEach(paymentGroup => {\n let grpOutstandingAmount = 0.00,\n feesTotal = 0.00,\n paymentsTotal = 0.00,\n remissionsTotal = 0.00;\n if (paymentGroup.fees) {\n this.isFeeRecordsExist = true;\n paymentGroup.fees.forEach(fee => {\n feesTotal = feesTotal + fee.calculated_amount;\n if (fee.calculated_amount === 0) {\n isFeeAmountZero = true\n }\n });\n\n }\n\n if (paymentGroup.payments) {\n paymentGroup.payments.forEach(payment => {\n if (payment.status.toUpperCase() === 'SUCCESS') {\n paymentsTotal = paymentsTotal + payment.amount;\n }\n });\n }\n\n if (paymentGroup.remissions) {\n paymentGroup.remissions.forEach(remission => {\n remissionsTotal = remissionsTotal + remission.hwf_amount;\n });\n }\n grpOutstandingAmount = (feesTotal - remissionsTotal) - paymentsTotal;\n if (grpOutstandingAmount < 0) {\n if (totalRefundAmount === 0) {\n totalRefundAmount = grpOutstandingAmount;\n } else {\n totalRefundAmount = (totalRefundAmount + grpOutstandingAmount);\n }\n }\n else if (grpOutstandingAmount > 0 || (grpOutstandingAmount === 0 && isFeeAmountZero)) {\n this.isGrpOutstandingAmtPositive = true;\n }\n });\n return totalRefundAmount * -1;\n }\n }\n\n getGroupOutstandingAmount(paymentGroup: IPaymentGroup): number {\n return this.bulkScaningPaymentService.calculateOutStandingAmount(paymentGroup);\n }\n\n redirectToFeeSearchPage(event: any) {\n event.preventDefault();\n let url = this.isBulkScanEnable ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n url += this.isTurnOff ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n url += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n url += `&caseType=${this.caseType}`\n this.router.navigateByUrl(`/fee-search?selectedOption=${this.selectedOption}&ccdCaseNumber=${this.ccdCaseNumber}${url}`);\n }\n\n addRemission(fee: IFee) {\n if(this.chkForAddRemission(fee.code)) {\n this.feeId = fee;\n this.viewStatus = 'addremission';\n this.paymentViewService.getApportionPaymentDetails(this.payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n this.payment = this.paymentGroup.payments[0];\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error? error.replace(/\"/g,\"\") : \"\"\n );\n }\n }\n\n addRefundForRemission(payment: IPayment, remission: IRemission[],fees:any) {\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n this.paymentGroup.payments = paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj.reference === payment.reference);\n this.payment = this.paymentGroup.payments[0];\n this.remissions = remission;\n this.remissionFeeAmt = fees.filter(data=>data.code === this.remissions['fee_code'])[0].net_amount;\n this.viewStatus = 'addrefundforremission';\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error\n );\n }\n\n redirectToremissionPage(event: any) {\n event.preventDefault();\n this.paymentLibComponent.viewName = 'remission'\n }\n goToServiceRequestPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = false;\n this.paymentLibComponent.SERVICEREQUEST = 'true';\n this.paymentLibComponent.isFromServiceRequestPage = true;\n window.location.reload();\n }\n redirectToReportsPage(event: any) {\n event.preventDefault();\n this.router.navigateByUrl(`/reports?selectedOption=${this.selectedOption}&ccdCaseNumber=${this.ccdCaseNumber}`);\n }\n\n loadFeeSummaryPage(paymentGroup: IPaymentGroup) {\n this.paymentLibComponent.bspaymentdcn = null;\n this.paymentLibComponent.paymentGroupReference = paymentGroup.payment_group_reference;\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.viewName = 'fee-summary';\n }\n\n goToPaymentViewComponent(paymentGroup: any) {\n this.paymentLibComponent.paymentMethod = paymentGroup.paymentMethod;\n this.paymentLibComponent.paymentGroupReference = paymentGroup.paymentGroupReference;\n this.paymentLibComponent.paymentReference = paymentGroup.paymentReference;\n this.paymentLibComponent.viewName = 'payment-view';\n }\n\n goToPayementView(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.goToPaymentViewComponent({ paymentGroupReference, paymentReference, paymentMethod });\n }\n\n selectedUnprocessedFeeEvent(unprocessedRecordId: string) {\n if (unprocessedRecordId) {\n if (this.isTurnOff) {\n this.isAddFeeBtnEnabled = false;\n }\n this.isUnprocessedRecordSelected = true;\n } else {\n if (this.isTurnOff) {\n this.isAddFeeBtnEnabled = true;\n }\n this.isUnprocessedRecordSelected = false;\n }\n }\n\n getUnprocessedFeeCount(unProcessedRecordCount: number) {\n this.unprocessedRecordCount = unProcessedRecordCount;\n }\n\n calculateAmountDue(fee: IFee) {\n\n if (fee.date_created) {\n return fee.amount_due !== undefined ? fee.amount_due : fee.net_amount;\n } else {\n return \"0.00\";\n }\n }\n\n confirmRemoveFee(fee: IFee) {\n this.isRemoveBtnDisabled = false;\n this.feeId = fee;\n this.viewStatus = 'feeRemovalConfirmation';\n }\n\n cancelRemoval() {\n this.viewStatus = 'main';\n }\n\n removeFee(fee: any) {\n this.isRemoveBtnDisabled = true;\n this.paymentViewService.deleteFeeFromPaymentGroup(fee).subscribe(\n (success: any) => {\n window.location.reload();\n },\n (error: any) => {\n this.errorMessage = error;\n this.isRemoveBtnDisabled = false;\n }\n );\n }\n\n isCheckAmountdueExist(amountDue: any) {\n return typeof amountDue === 'undefined';\n }\n\n issueRefund(payment: IPayment) {\n if (payment !== null && payment !== undefined) {\n if(this.chkIssueRefundBtnEnable(payment)) {\n this.viewStatus = 'issuerefund';\n this.payment = payment;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.isRefundRemission = true;\n }\n }\n }\n\n chkForAddRemission(feeCode: string): boolean {\n if (this.chkForPBAPayment() && this.check4AllowedRoles2AccessRefund()) {\n if (this.orderDetail[0]['remissions'].length > 0) {\n for (const remission of this.orderDetail[0]['remissions']) {\n if (remission.fee_code === feeCode) {\n return false;\n }\n }\n }\n return true;\n } else {\n return false;\n }\n }\n\n chkForPBAPayment(): boolean {\n if (this.orderDetail !== null && this.orderDetail !== undefined) {\n this.orderDetail.forEach(orderDetail => {\n if (orderDetail.payments) {\n orderDetail.payments.forEach(payment => {\n if (payment.method.toLocaleLowerCase() === 'payment by account' && this.allowFurtherAccessAfter4Days(payment)) {\n this.isPBA = true;\n }\n });\n }\n });\n if (this.isPBA) {\n return true;\n } else {\n return false;\n };\n }\n }\n\n chkIssueRefundBtnEnable(payment: IPayment): boolean {\n if (payment !== null && payment !== undefined) {\n return payment.issue_refund && payment.refund_enable\n } else {\n return false;\n }\n // if (this.check4AllowedRoles2AccessRefund() && this.allowFurtherAccessAfter4Days(payment) &&\n // payment.method === 'payment by account' && payment.status.toLocaleLowerCase() === 'success') {\n // this.isIssueRefunfBtnEnable = true;\n // }\n // if (this.isIssueRefunfBtnEnable) {\n // return true;\n // } else {\n // return false;\n // };\n }\n\n chkIsRefundRemissionBtnEnable(): boolean {\n if (this.orderDetail !== null && this.orderDetail !== undefined) {\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.orderDetail.forEach(orderDetail => {\n if (orderDetail.payments) {\n orderDetail.payments.forEach(payment => {\n if (payment.method.toLocaleLowerCase() === 'payment by account' && payment.status.toLocaleLowerCase() === 'success' && this.allowFurtherAccessAfter4Days(payment)) {\n this.isRefundRemissionBtnEnable = true;\n }\n });\n }\n });\n if (this.isRefundRemissionBtnEnable) {\n return true;\n } else {\n return false;\n };\n }\n }\n\n check4AllowedRoles2AccessRefund = (): boolean => {\n return this.allowedRolesToAccessRefund.some(role =>\n this.LOGGEDINUSERROLES.indexOf(role) !== -1\n );\n }\n check4AllowedRoles2AccessPBApayment = (): boolean => {\n return this.isEligible4PBAPayment.some(role =>\n this.LOGGEDINUSERROLES.indexOf(role) !== -1\n );\n }\n\n allowFurtherAccessAfter4Days = (payment: IPayment): boolean => {\n if (payment !== null && payment !== undefined) {\n let tmp4DayAgo = new Date();\n tmp4DayAgo.setDate(tmp4DayAgo.getDate() - 4);\n return tmp4DayAgo >= new Date(payment.date_created);\n }\n }\n\n loadPBAAccountPage(orderRef: IPayment) {\n this.paymentLibComponent.pbaPayOrderRef = orderRef;\n this.paymentLibComponent.viewName = 'pba-payment';\n }\n}\n","export class PaymentToPayhubRequest {\n currency = 'GBP';\n description = 'PayBubble payment';\n channel = 'telephony';\n provider = 'pci pal';\n case_type: string;\n\n ccd_case_number: string;\n amount: number;\n\n constructor(ccd_case_number: string, amount: number, caseType: string) {\n this.ccd_case_number = ccd_case_number;\n this.amount = <any>amount.toFixed(2);\n this.case_type= caseType;\n }\n}\n","export class PayhubAntennaRequest {\n currency = 'GBP';\n case_type: string;\n ccd_case_number: string;\n amount: number;\n\n constructor(ccd_case_number: string, amount: number, caseType: string) {\n this.ccd_case_number = ccd_case_number;\n this.amount = <any>amount.toFixed(2);\n this.case_type= caseType;\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { IFee } from '../../interfaces/IFee';\nimport { PaymentToPayhubRequest } from '../../interfaces/PaymentToPayhubRequest';\nimport { PayhubAntennaRequest } from '../../interfaces/PayhubAntennaRequest';\nimport { SafeHtml } from '@angular/platform-browser';\nimport {Router} from '@angular/router';\nimport {Location} from '@angular/common';\nimport { OrderslistService } from '../../services/orderslist.service';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\n\n@Component({\n selector: 'ccpay-fee-summary',\n templateUrl: './fee-summary.component.html',\n styleUrls: ['./fee-summary.component.scss']\n})\n\nexport class FeeSummaryComponent implements OnInit {\n @Input() paymentGroupRef: string;\n @Input() ccdCaseNumber: string;\n @Input() isTurnOff: string;\n @Input() caseType: string;\n\n\n bsPaymentDcnNumber: string;\n paymentGroup: IPaymentGroup;\n errorMessage: string;\n viewStatus = 'main';\n currentFee: IFee;\n totalFee: number;\n payhubHtml: SafeHtml;\n service: string = \"\";\n platForm: string = \"\";\n upPaymentErrorMessage: string;\n selectedOption:string;\n isBackButtonEnable: boolean = true;\n outStandingAmount: number;\n isFeeAmountZero: boolean = false;\n totalAfterRemission: number = 0;\n isConfirmationBtnDisabled: boolean = false;\n isRemoveBtnDisabled: boolean = false;\n isPaymentExist: boolean = false;\n isRemissionsExist: Boolean = false;\n isRemissionsMatch = false;\n isStrategicFixEnable: boolean;\n\n constructor(\n private router: Router,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private location: Location,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private OrderslistService: OrderslistService\n ) {}\n\n ngOnInit() {\n this.viewStatus = 'main';\n this.caseType = this.paymentLibComponent.CASETYPE;\n this.bsPaymentDcnNumber = this.paymentLibComponent.bspaymentdcn;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION.toLocaleLowerCase();\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.OrderslistService.setCaseType(this.paymentLibComponent.CASETYPE);\n\n this.platForm = 'Antenna';\n\n this.paymentViewService.getBSfeature().subscribe(\n features => {\n let result = JSON.parse(features).filter(feature => feature.uid === BS_ENABLE_FLAG);\n this.paymentLibComponent.ISBSENABLE = result[0] ? result[0].enable : false;\n },\n err => {\n this.paymentLibComponent.ISBSENABLE = false;\n }\n );\n if (this.bsPaymentDcnNumber) {\n this.getUnassignedPaymentlist();\n }\n this.getPaymentGroup();\n }\n\n getUnassignedPaymentlist() {\n if (this.selectedOption === 'dcn') {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.paymentLibComponent.DCN_NUMBER).subscribe(\n unassignedPayments => {\n if(unassignedPayments['data'].payments) {\n this.service = unassignedPayments['data'].responsible_service_id;\n } else {\n this.upPaymentErrorMessage = 'error';\n }\n },\n (error: any) => this.upPaymentErrorMessage = error\n );\n } else {\n this.bulkScaningPaymentService.getBSPaymentsByCCD(this.ccdCaseNumber).subscribe(\n unassignedPayments => {\n if(unassignedPayments['data'].payments) {\n this.service = unassignedPayments['data'].responsible_service_id;\n } else {\n this.upPaymentErrorMessage = 'error';\n }\n },\n (error: any) => this.upPaymentErrorMessage = error\n );\n }\n\n }\n\n getRemissionByFeeCode(feeCode: string): IRemission {\n if (this.paymentGroup && this.paymentGroup.remissions && this.paymentGroup.remissions.length > 0) {\n for (const remission of this.paymentGroup.remissions) {\n if (remission.fee_code === feeCode) {\n return remission;\n }\n }\n }\n return null;\n }\n\n addRemission(fee: IFee) {\n this.currentFee = fee;\n this.viewStatus = 'add_remission';\n }\n\n getPaymentGroup() {\n let fees = [];\n this.paymentViewService.getPaymentGroupDetails(this.paymentGroupRef).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n this.isPaymentExist = paymentGroup.payments ? paymentGroup.payments.length > 0 : false;\n this.isRemissionsExist = paymentGroup.remissions ? paymentGroup.remissions.length > 0 : false;\n\n if (paymentGroup.fees) {\n paymentGroup.fees.forEach(fee => {\n this.totalAfterRemission = this.totalAfterRemission + fee.net_amount;\n if(fee.calculated_amount === 0) {\n this.isFeeAmountZero = true;\n }\n if(paymentGroup.remissions) {\n this.isRemissionsMatch = false;\n paymentGroup.remissions.forEach(rem => {\n if(rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n fees.push(fee);\n }\n });\n\n if(!this.isRemissionsMatch) {\n fees.push(fee);\n }\n } else {\n fees.push(fee);\n }\n });\n paymentGroup.fees = fees;\n }\n\n this.outStandingAmount = this.bulkScaningPaymentService.calculateOutStandingAmount(paymentGroup);\n },\n (error: any) => this.errorMessage = error.replace(/\"/g,\"\")\n );\n }\n\n confirmRemoveFee(fee: IFee){\n this.isRemoveBtnDisabled = false;\n this.currentFee = fee;\n this.viewStatus = 'feeRemovalConfirmation';\n }\n\n removeFee(fee: any){\n this.isRemoveBtnDisabled = true;\n this.paymentViewService.deleteFeeFromPaymentGroup(fee).subscribe(\n (success: any) => {\n if (this.paymentGroup.fees && this.paymentGroup.fees.length > 1){\n this.totalAfterRemission = 0;\n this.getPaymentGroup();\n this.viewStatus = 'main';\n return;\n }\n this.loadCaseTransactionPage();\n },\n (error: any) => {\n this.errorMessage = error;\n this.isRemoveBtnDisabled = false;\n }\n );\n }\n\n loadCaseTransactionPage() {\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentViewService.getBSfeature().subscribe(\n features => {\n let result = JSON.parse(features).filter(feature => feature.uid === BS_ENABLE_FLAG);\n this.paymentLibComponent.ISBSENABLE = result[0] ? result[0].enable : false;\n },\n err => {\n this.paymentLibComponent.ISBSENABLE = false;\n }\n );\n\n let partUrl = `selectedOption=${this.paymentLibComponent.SELECTED_OPTION}`;\n partUrl +=this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl +=this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl +=this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl +=this.paymentLibComponent.ISSFENABLE ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl +=`&caseType=${this.paymentLibComponent.CASETYPE}`;\n\n let url = `/payment-history/${this.ccdCaseNumber}?view=case-transactions&takePayment=true&${partUrl}`;\n this.router.navigateByUrl(url);\n }\n cancelRemission() {\n this.viewStatus = 'main';\n }\n redirectToFeeSearchPage(event: any, page?: string) {\n event.preventDefault();\n let partUrl =this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl +=this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl +=this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl +=this.paymentLibComponent.ISSFENABLE ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl +=`&caseType=${this.paymentLibComponent.CASETYPE}`;\n\n if(this.viewStatus === 'feeRemovalConfirmation' || this.viewStatus === 'add_remission') {\n this.viewStatus = 'main';\n return;\n }\n let url = `/fee-search?ccdCaseNumber=${this.ccdCaseNumber}&selectedOption=${this.paymentLibComponent.SELECTED_OPTION}&paymentGroupRef=${this.paymentGroupRef}${partUrl}`;\n this.router.navigateByUrl(url);\n }\n takePayment() {\n this.isConfirmationBtnDisabled = true;\n const requestBody = new PaymentToPayhubRequest(this.ccdCaseNumber, this.outStandingAmount, this.caseType),\n antennaReqBody = new PayhubAntennaRequest(this.ccdCaseNumber, this.outStandingAmount, this.caseType);\n\n if(this.platForm === 'Antenna') {\n\n this.paymentViewService.postPaymentAntennaToPayHub(antennaReqBody, this.paymentGroupRef).subscribe(\n response => {\n this.isBackButtonEnable=false;\n window.location.href = '/makePaymentByTelephoneyProvider';\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.router.navigateByUrl('/pci-pal-failure');\n }\n );\n }\n\n }\n\n goToAllocatePage(outStandingAmount: number, isFeeAmountZero: Boolean) {\n if (outStandingAmount > 0 || (outStandingAmount === 0 && isFeeAmountZero)) {\n this.paymentLibComponent.paymentGroupReference = this.paymentGroupRef;\n this.paymentLibComponent.viewName = 'allocate-payments';\n } else {\n this.loadCaseTransactionPage();\n }\n }\n isCheckAmountdueExist(amountDue: any) {\n return typeof amountDue === 'undefined';\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\n\n\n\n@Component({\n selector: 'ccpay-error-banner',\n templateUrl: './error-banner.component.html',\n styleUrls: ['./error-banner.component.scss']\n})\n\nexport class ErrorBannerComponent implements OnInit {\n @Input('errorMessage') errorMessage;\n\n constructor(\n ) {}\n\n ngOnInit() {\n\n }\n}\n","\nexport class UnidentifiedPaymentsRequest {\n payment_allocation_status: any;\n payment_group_reference: string;\n payment_reference: string;\n unidentified_reason: string;\n\n constructor(payment_group_reference: string, payment_reference : string, unidentified_reason: any) {\n this.payment_allocation_status = {\n description: '',\n name: \"Unidentified\"\n };\n this.payment_group_reference = payment_group_reference ;\n this.payment_reference= payment_reference;\n this.unidentified_reason= unidentified_reason;\n\n }\n\n\n\n}\n","import { IBSPayments } from \"./IBSPayments\";\n\nexport class AllocatePaymentRequest {\n amount: Number;\n banked_date: String;\n ccd_case_number: String;\n exception_record: string;\n currency: String;\n document_control_number: String;\n external_provider: String;\n giro_slip_no: String;\n payer_name: String;\n payment_channel: Object;\n payment_status: Object;\n payment_method: String;\n case_type: String;\n payment_allocation_dto?: {\n allocation_reason: String,\n allocation_status: String,\n explanation: String,\n payment_allocation_status: Object,\n payment_group_reference: String,\n payment_reference: String,\n reason: String,\n receiving_office: String,\n unidentified_reason: String,\n user_id: String,\n user_name: String,\n case_type: String\n }\n\n constructor(ccd_case_number : string, unAllocatedPayment: IBSPayments, caseType: string, exceptionRecord: string, allocatedRequest?: any) {\n this.amount = unAllocatedPayment.amount;\n this.banked_date = unAllocatedPayment.date_banked;\n this.ccd_case_number = ccd_case_number;\n this.exception_record = exceptionRecord;\n this.currency= unAllocatedPayment.currency;\n this.document_control_number = unAllocatedPayment.dcn_reference;\n this.external_provider = 'exela';\n this.giro_slip_no = unAllocatedPayment.bgc_reference;\n this.payer_name = unAllocatedPayment.payer_name;\n this.payment_channel = {\n description: '',\n name: 'bulk scan'\n };\n this.payment_status ={\n description: 'bulk scan payment completed',\n name: 'success'\n }\n this.payment_method = unAllocatedPayment.payment_method;\n this.case_type= caseType;\n if(allocatedRequest) {\n this.payment_allocation_dto = allocatedRequest;\n }\n\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport {BulkScaningPaymentService} from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport { UnidentifiedPaymentsRequest } from '../../interfaces/UnidentifiedPaymentsRequest';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\n\n@Component({\n selector: 'app-mark-unidentified-payment',\n templateUrl: './mark-unidentified-payment.component.html',\n styleUrls: ['./mark-unidentified-payment.component.scss']\n})\nexport class MarkUnidentifiedPaymentComponent implements OnInit {\n @Input() caseType: string;\n markPaymentUnidentifiedForm: FormGroup;\n viewStatus: string;\n ccdCaseNumber: string;\n bspaymentdcn: string;\n isInvesticationDetailEmpty: boolean = false;\n investicationDetailHasError: boolean = false;\n investicationDetailMinHasError: boolean = false;\n investicationDetailMaxHasError: boolean = false;\n errorMessage = this.getErrorMessage(false);\n unassignedRecord:IBSPayments;\n siteID: string = null;\n investigationComment: string;\n isConfirmButtondisabled:Boolean = false;\n ccdReference: string = null;\n exceptionReference: string = null;\n isStrategicFixEnable: boolean = true;\n\n constructor(private formBuilder: FormBuilder,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private bulkScaningPaymentService: BulkScaningPaymentService) { }\n\n ngOnInit() {\n this.viewStatus = 'mainForm';\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.bspaymentdcn = this.paymentLibComponent.bspaymentdcn;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.getUnassignedPayment();\n\n this.markPaymentUnidentifiedForm = this.formBuilder.group({\n investicationDetail: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$')\n ]))\n });\n }\n getUnassignedPayment() {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.bspaymentdcn).subscribe(\n unassignedPayments => {\n this.errorMessage = this.getErrorMessage(false);\n this.unassignedRecord = unassignedPayments['data'].payments.filter(payment => {\n return payment && payment.dcn_reference == this.bspaymentdcn;\n })[0];\n this.siteID = unassignedPayments['data'].responsible_service_id;\n const beCcdNumber = unassignedPayments['data'].ccd_reference,\n beExceptionNumber = unassignedPayments['data'].exception_record_reference,\n exceptionReference = beCcdNumber ? beCcdNumber === this.ccdCaseNumber ? null : this.ccdCaseNumber : this.ccdCaseNumber;\n this.ccdReference = beCcdNumber ? beCcdNumber : null;\n this.exceptionReference = beExceptionNumber ? beExceptionNumber : exceptionReference;\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n }\n );\n }\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n saveAndContinue() {\n this.resetForm([false, false, false, false]);\n const investicationField = this.markPaymentUnidentifiedForm.controls.investicationDetail;\n const formerror = investicationField.errors;\n if (this.markPaymentUnidentifiedForm.dirty && this.markPaymentUnidentifiedForm.valid) {\n this.investigationComment = this.markPaymentUnidentifiedForm.controls.investicationDetail.value;\n this.viewStatus = 'unidentifiedContinueConfirm';\n }else {\n if(investicationField.value == '' ) {\n this.resetForm([true, false, false, false]);\n }\n if(investicationField.value != '' && investicationField.invalid ) {\n this.resetForm([false, true, false, false]);\n }\n if(formerror && formerror.minlength && formerror.minlength.actualLength < 3 ) {\n this.resetForm([false, false, true, false]);\n }\n if(formerror && formerror.maxlength && formerror.maxlength.actualLength > 255 ) {\n this.resetForm([false, false, false, true]);\n }\n }\n }\n resetForm(val) {\n this.isInvesticationDetailEmpty = val[0];\n this.investicationDetailHasError = val[1];\n this.investicationDetailMinHasError = val[2];\n this.investicationDetailMaxHasError = val[3];\n }\n confirmPayments() {\n this.isConfirmButtondisabled = true;\n const reason = this.markPaymentUnidentifiedForm.get('investicationDetail').value;\n\n if(!this.isStrategicFixEnable) {\n let allocatedRequest = {\n allocation_status:'Unidentified',\n payment_allocation_status: {\n description: '',\n name: 'Unidentified'\n },\n unidentified_reason: reason,\n user_id: this.caseType,\n }\n const postStrategicBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.caseType, this.exceptionReference, allocatedRequest);\n this.bulkScaningPaymentService.postBSWoPGStrategic(postStrategicBody).subscribe(\n res => {\n this.errorMessage = this.getErrorMessage(false);\n let response = JSON.parse(res);\n if (response.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n });\n } else {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'PROCESSED').subscribe(\n res1 => {\n this.errorMessage = this.getErrorMessage(false);\n const requestBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.siteID, this.exceptionReference)\n this.paymentViewService.postBSPayments(requestBody).subscribe(\n res2 => {\n this.errorMessage = this.getErrorMessage(false);\n const response2 = JSON.parse(res2),\n reqBody = new UnidentifiedPaymentsRequest\n (response2['data'].payment_group_reference, response2['data'].reference, reason);\n if (response2.success) {\n this.paymentViewService.postBSUnidentifiedPayments(reqBody).subscribe(\n res3 => {\n this.errorMessage = this.getErrorMessage(false);\n const response3 = JSON.parse(res3);\n if (response3.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n }\n cancelMarkUnidentifiedPayments(type?:string){\n if(type && type === 'cancel') {\n if(this.markPaymentUnidentifiedForm.get('investicationDetail').value!==\"\"){\n this.viewStatus = 'unidentifiedCancelConfirm';\n } else {\n this.gotoCasetransationPage();\n }\n } else {\n this.viewStatus = 'mainForm';\n }\n }\n\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n getErrorMessage(isErrorExist) {\n return {\n title: \"There is a problem with the service\",\n body: \"Try again later\",\n showError: isErrorExist\n };\n }\n}\n","\nexport class UnsolicitedPaymentsRequest {\n payment_allocation_status: any;\n payment_group_reference: string;\n payment_reference: string;\n receiving_office: string;\n receiving_email_address: string;\n sending_email_address: string;\n unidentified_reason: string;\n constructor(payment_group_reference: string, payment_reference : string, reason: string,responsible_office: string, responsible_person:string,email_id: string) {\n this.payment_allocation_status = {\n description: '',\n name: \"Transferred\"\n };\n this.payment_group_reference = payment_group_reference;\n this.payment_reference= payment_reference;\n this.unidentified_reason= reason;\n this.receiving_office= responsible_office;\n this.receiving_email_address= email_id;\n this.sending_email_address= responsible_person;\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport { UnsolicitedPaymentsRequest } from '../../interfaces/UnsolicitedPaymentsRequest';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { AllocatePaymentRequest } from '../../interfaces/AllocatePaymentRequest';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\n\n\n@Component({\n selector: 'app-mark-unsolicited-payment',\n templateUrl: './mark-unsolicited-payment.component.html',\n styleUrls: ['./mark-unsolicited-payment.component.scss']\n})\nexport class MarkUnsolicitedPaymentComponent implements OnInit {\n @Input() caseType: string;\n markPaymentUnsolicitedForm: FormGroup;\n viewStatus: string;\n reasonHasError: boolean = false;\n isReasonEmpty: boolean = false;\n reasonMinHasError: boolean = false;\n reasonMaxHasError: boolean = false;\n responsibleOfficeHasError: boolean = false;\n isResponsibleOfficeEmpty: boolean = false;\n errorMessage = this.getErrorMessage(false);\n ccdCaseNumber: string;\n bspaymentdcn: string;\n unassignedRecord: IBSPayments;\n siteID: string = null;\n reason: string;\n responsiblePerson: string;\n responsibleOffice: string;\n emailId: string;\n isConfirmButtondisabled: Boolean = false;\n isContinueButtondisabled: Boolean = false;\n ccdReference: string = null;\n exceptionReference: string = null;\n selectedSiteId: string;\n selectedSiteName: string;\n isStrategicFixEnable: boolean = true;\n siteIDList;\n\n constructor(private formBuilder: FormBuilder,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private bulkScaningPaymentService: BulkScaningPaymentService) { }\n\n ngOnInit() {\n this.resetForm([false,false,false,false,false,false], 'all');\n this.viewStatus = 'mainForm';\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.bspaymentdcn = this.paymentLibComponent.bspaymentdcn;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.getUnassignedPayment();\n\n this.paymentViewService.getSiteID().subscribe(\n siteids => {\n this.isContinueButtondisabled = false;\n this.errorMessage = this.getErrorMessage(false);\n this.siteIDList = JSON.parse(siteids);\n },\n err => {\n window.scrollTo(0, 0);\n this.isContinueButtondisabled = true;\n this.errorMessage = this.getErrorMessage(true);\n }\n );\n \n this.markPaymentUnsolicitedForm = this.formBuilder.group({\n reason: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$')\n ])),\n responsibleOffice: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([a-zA-Z0-9\\\\s\\\\n,\\\\.-:]*)$')\n ])),\n responsiblePerson: new FormControl(''),\n emailId: new FormControl('')\n });\n }\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n confirmPayments() {\n this.isConfirmButtondisabled = true;\n const controls = this.markPaymentUnsolicitedForm.controls;\n if(!this.isStrategicFixEnable) {\n let allocatedRequest = {\n allocation_status:'Transferred',\n payment_allocation_status: {\n description: '',\n name: 'Transferred'\n },\n unidentified_reason: controls.reason.value,\n receiving_office: this.selectedSiteId,\n user_id: this.caseType,\n }\n const postStrategicBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.caseType, this.exceptionReference, allocatedRequest);\n this.bulkScaningPaymentService.postBSWoPGStrategic(postStrategicBody).subscribe(\n res => {\n this.errorMessage = this.getErrorMessage(false);\n let response = JSON.parse(res);\n if (response.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n });\n } else {\n // controls.responsibleOffice.setValue('P219');\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'PROCESSED').subscribe(\n res1 => {\n this.errorMessage = this.getErrorMessage(false);\n const response1 = JSON.parse(res1),\n requestBody = new AllocatePaymentRequest\n (this.ccdReference, this.unassignedRecord, this.siteID, this.exceptionReference)\n this.paymentViewService.postBSPayments(requestBody).subscribe(\n res2 => {\n this.errorMessage = this.getErrorMessage(false);\n const response2 = JSON.parse(res2),\n reqBody = new UnsolicitedPaymentsRequest\n (response2['data'].payment_group_reference, response2['data'].reference, controls.reason.value, this.selectedSiteId, controls.responsiblePerson.value, controls.emailId.value);\n if (response2.success) {\n this.paymentViewService.postBSUnsolicitedPayments(reqBody).subscribe(\n res3 => {\n this.errorMessage = this.getErrorMessage(false);\n const response3 = JSON.parse(res3);\n if (response3.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unassignedRecord.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n }\n saveAndContinue() {\n this.resetForm([false,false,false,false,false,false], 'all');\n const formerror = this.markPaymentUnsolicitedForm.controls.reason.errors;\n const reasonField = this.markPaymentUnsolicitedForm.controls.reason;\n //const officeIdField = this.selectedSiteId;\n const officeIdField = this.markPaymentUnsolicitedForm.controls.responsibleOffice;\n if (this.markPaymentUnsolicitedForm.dirty && this.markPaymentUnsolicitedForm.valid) {\n const controls = this.markPaymentUnsolicitedForm.controls;\n this.emailId = controls.emailId.value;\n this.responsibleOffice = officeIdField.value;\n this.responsiblePerson = controls.responsiblePerson.value;\n this.reason = controls.reason.value;\n this.viewStatus = 'unsolicitedContinueConfirm';\n }else {\n if( reasonField.value == '' ) {\n this.resetForm([true,false,false,false,false,false], 'reason');\n }\n if(reasonField.value != '' && this.markPaymentUnsolicitedForm.controls.reason.invalid ) {\n this.resetForm([false,true,false,false,false,false], 'reason');\n }\n if(formerror && formerror.minlength && formerror.minlength.actualLength < 3 ) {\n this.resetForm([false,false,true,false,false,false], 'reason');\n }\n if(formerror && formerror.maxlength && formerror.maxlength.actualLength > 255 ) {\n this.resetForm([false,false,false,true,false,false], 'reason');\n }\n if(officeIdField.value == '') {\n this.resetForm([false,false,false,false,true,false], 'responsibleOffice');\n }\n if(officeIdField.value != '' && officeIdField.invalid) {\n this.resetForm([false,false,false,false,false,true],'responsibleOffice');\n }\n }\n }\n resetForm(val, field) {\n if(field==='reason' || field==='all') {\n this.isReasonEmpty = val[0];\n this.reasonHasError = val[1];\n this.reasonMinHasError = val[2];\n this.reasonMaxHasError = val[3];\n }\n if(field==='responsibleOffice' || field==='all') {\n this.isResponsibleOfficeEmpty = val[4];\n this.responsibleOfficeHasError = val[5];\n }\n }\n\ncancelMarkUnsolicitedPayments(type?:string){\n if(type && type === 'cancel') {\n if(this.checkingFormValue()){\n this.viewStatus = 'unsolicitedCancelConfirm';\n } else {\n this.gotoCasetransationPage();\n }\n } else {\n this.markPaymentUnsolicitedForm.controls.responsibleOffice.setValue('');\n this.viewStatus = 'mainForm';\n }\n }\n checkingFormValue(){\n const formFields = this.markPaymentUnsolicitedForm.value;\n let valueExists = false;\n\n for (var field in formFields) {\n if (formFields.hasOwnProperty(field) && formFields[field] !==\"\") {\n valueExists = true;\n break;\n }\n }\n return valueExists;\n }\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n getUnassignedPayment() {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.bspaymentdcn).subscribe(\n unassignedPayments => {\n \n this.unassignedRecord = unassignedPayments['data'].payments.filter(payment => {\n return payment && payment.dcn_reference == this.bspaymentdcn;\n })[0];\n this.siteID = unassignedPayments['data'].responsible_service_id;\n const beCcdNumber = unassignedPayments['data'].ccd_reference,\n beExceptionNumber = unassignedPayments['data'].exception_record_reference,\n exceptionReference = beCcdNumber ? beCcdNumber === this.ccdCaseNumber ? null : this.ccdCaseNumber : this.ccdCaseNumber;\n this.ccdReference = beCcdNumber ? beCcdNumber : null;\n this.exceptionReference = beExceptionNumber ? beExceptionNumber : exceptionReference;\n },\n (error: any) => {\n this.errorMessage = this.getErrorMessage(true);\n }\n );\n }\n\n getErrorMessage(isErrorExist) {\n return {\n title: \"Something went wrong.\",\n body: \"Please try again later.\",\n showError: isErrorExist\n };\n }\n\n selectchange(args){ \n this.selectedSiteId = args.target.value; \n this.selectedSiteName = args.target.options[args.target.selectedIndex].text; \n } \n\n}\n","import { Component, OnInit, Output,Input, EventEmitter } from '@angular/core';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IBSPayments } from '../../interfaces/IBSPayments';\nimport {Router} from '@angular/router';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { OrderslistService } from '../../services/orderslist.service';\n\n@Component({\n selector: 'ccpay-app-unprocessed-payments',\n templateUrl: './unprocessed-payments.component.html',\n styleUrls: ['./unprocessed-payments.component.scss']\n})\nexport class UnprocessedPaymentsComponent implements OnInit {\n\n @Input('FEE_RECORDS_EXISTS') FEE_RECORDS_EXISTS: boolean;\n @Input('PAYMENTREF') PAYMENTREF: string;\n @Input('ISTURNOFF') ISTURNOFF: boolean;\n @Input('IS_BUTTON_ENABLE') IS_BUTTON_ENABLE: boolean;\n @Input('IS_OS_AMT_AVAILABLE') IS_OS_AMT_AVAILABLE: boolean;\n @Input('ISSFENABLE') ISSFENABLE: boolean;\n @Input('PAYMENTSLENGTH') PAYMENTSLENGTH:Number;\n @Input('LEVEL')LEVEL:Number;\n\n @Output() selectedUnprocessedFeeEvent: EventEmitter<string> = new EventEmitter();\n @Output() getUnprocessedFeeCount: EventEmitter<string> = new EventEmitter();\n\n viewStatus = 'main';\n unassignedRecordList: IBSPayments;\n upPaymentErrorMessage: string = null;\n ccdCaseNumber: string;\n recordId: string = null;\n isRecordExist: boolean = false;\n dcnNumber: string = null;\n selectedOption: string;\n isUnprocessedRecordSelected: boolean = true;\n isAllocateToExistingFeebtnEnabled: boolean = false;\n isMarkAsUnidentifiedbtnEnabled: boolean = false;\n isAllocatedToNewFeebtnEnabled: boolean = false;\n isExceptionCase: boolean = false;\n serviceId: string = null;\n isBulkScanEnable;\n isTurnOff: boolean = true;\n isStFixEnable;\n unassignedRecordSelectedList: IBSPayments;\n unassignedRecordListLength: number = 0;\n showContent: boolean;\n\n constructor(private router: Router,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private paymentLibComponent: PaymentLibComponent,\n private paymentViewService: PaymentViewService,\n private OrderslistService: OrderslistService\n ) { }\n\n ngOnInit() {\n // Todo ...\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION.toLocaleLowerCase();\n this.dcnNumber = this.paymentLibComponent.DCN_NUMBER;\n this.isBulkScanEnable = this.paymentLibComponent.ISBSENABLE;\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.isStFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.OrderslistService.getFeeExists().subscribe( (data) => this.FEE_RECORDS_EXISTS = data);\n this.getUnassignedPaymentlist();\n\n }\n\n getUnassignedPaymentlist() {\n if (this.selectedOption === 'dcn') {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.dcnNumber).subscribe(\n unassignedPayments => {\n // unassignedPayments['data'].map(data => data.expandable=false);\n if(unassignedPayments['data'] && unassignedPayments['data'].payments) {\n this.setValuesForUnassignedRecord(unassignedPayments['data']);\n } else if(unassignedPayments['payments']) {\n this.setValuesForUnassignedRecord(unassignedPayments);\n } else {\n this.upPaymentErrorMessage = 'error';\n this.getUnprocessedFeeCount.emit('0');\n }\n },\n (error: any) => {\n this.upPaymentErrorMessage = error;\n this.getUnprocessedFeeCount.emit('0');\n }\n );\n } else {\n this.bulkScaningPaymentService.getBSPaymentsByCCD(this.ccdCaseNumber).subscribe(\n unassignedPayments => {\n // unassignedPayments['data'].map(data => data.expandable=false);\n if(unassignedPayments['data'] && unassignedPayments['data'].payments) {\n this.setValuesForUnassignedRecord(unassignedPayments['data']);\n } else if(unassignedPayments['payments']) {\n this.setValuesForUnassignedRecord(unassignedPayments);\n } else {\n this.upPaymentErrorMessage = 'error';\n this.getUnprocessedFeeCount.emit('0');\n }\n },\n (error: any) => {\n this.upPaymentErrorMessage = error;\n this.getUnprocessedFeeCount.emit('0');\n }\n );\n }\n\n }\n\n setValuesForUnassignedRecord(unassignedPayments) {\n\n this.unassignedRecordList = unassignedPayments.payments;\n if(this.unassignedRecordList){\n this.unassignedRecordListLength = unassignedPayments.payments.length\n }\n this.serviceId = unassignedPayments.responsible_service_id;\n if (unassignedPayments['ccd_reference'] === undefined) {\n this.isExceptionCase = true;\n }\n // this.isRecordExist = this.unassignedRecordList.length === 0;\n this.getUnprocessedFeeCount.emit(<any>this.unassignedRecordList.length);\n this.unprocessedPaymentSelectEvent(this.unassignedRecordList);\n }\n\n formatUnassignedRecordId(ID: Number) {\n return `unassignrecord-${ID}`;\n }\n\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n\n redirectToFeeSearchPage(event: any, dcn_reference:any) {\n event.preventDefault();\n this.recordId = dcn_reference;\n let url = this.isBulkScanEnable ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n url += this.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n url += this.isStFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n url +=`&caseType=${this.paymentLibComponent.CASETYPE}`;\n\n this.router.navigateByUrl(`/fee-search?selectedOption=${this.selectedOption}&ccdCaseNumber=${this.ccdCaseNumber}&dcn=${this.recordId}${url}`);\n }\n\n loadUnsolicitedPage(viewName: string, dcn_reference:any) {\n this.recordId = dcn_reference;\n this.paymentLibComponent.bspaymentdcn = this.recordId;\n this.paymentLibComponent.viewName = viewName;\n }\n\n unprocessedPaymentSelectEvent(selectedRecordReference: any) {\n this.isUnprocessedRecordSelected = true;\n this.validateButtons();\n this.selectedUnprocessedFeeEvent.emit(selectedRecordReference);\n }\n\n resetButtons() {\n this.isUnprocessedRecordSelected = false;\n this.isAllocateToExistingFeebtnEnabled = false;\n this.isMarkAsUnidentifiedbtnEnabled = false;\n this.isAllocatedToNewFeebtnEnabled = false;\n }\n\n goToAllocatePage(dcn_reference:any) {\n this.paymentLibComponent.bspaymentdcn = dcn_reference;\n this.paymentLibComponent.unProcessedPaymentServiceId = this.serviceId\n this.paymentLibComponent.isTurnOff = this.ISTURNOFF;\n this.paymentLibComponent.ISSFENABLE = this.isStFixEnable;\n\n if(this.ISTURNOFF) {\n this.paymentLibComponent.paymentGroupReference = this.PAYMENTREF;\n this.paymentLibComponent.viewName = 'fee-summary';\n }else {\n this.paymentLibComponent.paymentGroupReference = null;\n this.paymentLibComponent.viewName = 'allocate-payments';\n }\n\n }\n\n validateButtons() {\n setTimeout(() => {\n if ( this.isUnprocessedRecordSelected && this.isExceptionCase) {\n this.isMarkAsUnidentifiedbtnEnabled = true;\n } else if ( this.isUnprocessedRecordSelected && !this.isExceptionCase && !this.FEE_RECORDS_EXISTS) {\n this.isAllocateToExistingFeebtnEnabled = false;\n this.isAllocatedToNewFeebtnEnabled = true;\n } else if( this.isUnprocessedRecordSelected && !this.isExceptionCase && this.FEE_RECORDS_EXISTS) {\n if(!this.ISTURNOFF) {\n this.isAllocateToExistingFeebtnEnabled = true;\n this.isAllocatedToNewFeebtnEnabled = false;\n } else {\n this.isAllocateToExistingFeebtnEnabled = this.IS_OS_AMT_AVAILABLE;\n this.isAllocatedToNewFeebtnEnabled = true;\n }\n }\n },4000);\n }\n\n unprocessedPaymentUnSelectEvent(event: any) {\n event.preventDefault();\n this.recordId = null;\n this.isUnprocessedRecordSelected = false;\n this.isAllocateToExistingFeebtnEnabled = false;\n this.isAllocatedToNewFeebtnEnabled = false;\n this.isMarkAsUnidentifiedbtnEnabled = false;\n //this.validateButtons();\n this.selectedUnprocessedFeeEvent.emit('');\n }\n\n showDetailRow(event: any,obj: any, i: any) {\n event.preventDefault();\n\n this.unassignedRecordSelectedList = obj;\n\n }\n}\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport {IPayment} from '../../interfaces/IPayment';\nimport {Router} from '@angular/router';\n\n@Component({\n selector: 'ccpay-app-processed-payments',\n templateUrl: './processed-payments.component.html',\n styleUrls: ['./processed-payments.component.scss']\n})\nexport class ProcessedPaymentsComponent implements OnInit {\n\n @Input('NONPAYMENTS') NONPAYMENTS: IPayment[];\n @Output() goToPaymentViewComponent: EventEmitter<any> = new EventEmitter();\n\n constructor(\n private router: Router,\n private bulkScaningPaymentService: BulkScaningPaymentService\n ) { }\n ngOnInit() {\n }\n\n trimUnderscore(method: string){\n return this.bulkScaningPaymentService.removeUnwantedString(method,' ');\n }\n redirectToPaymentViewPage(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.goToPaymentViewComponent.emit({paymentGroupReference, paymentReference, paymentMethod});\n }\n}\n","\nexport class IAllocationPaymentsRequest {\n payment_allocation_status: any;\n payment_group_reference: string;\n payment_reference: string;\n reason: string;\n explanation: string;\n user_name: string;\n constructor(payment_group_reference: string, payment_reference : string, reason? : string, explanation? : string, userName? : string) {\n this.payment_allocation_status = {\n description: '',\n name: \"Allocated\"\n };\n this.payment_group_reference = payment_group_reference;\n this.payment_reference= payment_reference;\n this.reason = reason ? reason : null;\n this.explanation = explanation ? explanation : null;\n this.user_name = userName ? userName : null;\n }\n}\n","import { Component, OnInit, Input } from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport {CaseTransactionsService} from '../../services/case-transactions/case-transactions.service'; \nimport {BulkScaningPaymentService} from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport {IBSPayments} from '../../interfaces/IBSPayments';\nimport {AllocatePaymentRequest} from '../../interfaces/AllocatePaymentRequest';\nimport {IAllocationPaymentsRequest} from '../../interfaces/IAllocationPaymentsRequest';\nimport { IOrderReferenceFee } from '../../interfaces/IOrderReferenceFee';\nimport { OrderslistService } from '../../services/orderslist.service';\n\n\n\n@Component({\n selector: 'app-allocate-payments',\n templateUrl: './allocate-payments.component.html',\n styleUrls: ['./allocate-payments.component.scss']\n})\nexport class AllocatePaymentsComponent implements OnInit {\n @Input() isTurnOff: boolean;\n @Input() caseType: string;\n\n overUnderPaymentForm: FormGroup;\n viewStatus: string;\n ccdCaseNumber: string;\n bspaymentdcn: string;\n recordId:string;\n feedbackUrlLabel:string;\n unAllocatedPayment: IBSPayments = {\n amount: 0\n };\n siteID: string = null;\n errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n paymentGroup: IPaymentGroup;\n paymentGroups: IPaymentGroup[] = [];\t\n remainingAmount: number;\n isRemainingAmountGtZero: boolean;\n isMoreDetailsBoxHide: boolean = true;\n isRemainingAmountLtZero: boolean;\n afterFeeAllocateOutstanding: number;\n amountForAllocation: number;\n isConfirmButtondisabled: boolean = false;\n isContinueButtondisabled: boolean = true;\n otherPaymentExplanation: string = null;\n selectedOption: string = null;\n isFeeAmountZero: boolean = false;\t\n\n paymentReasonHasError: boolean = false;\n paymentExplanationHasError: boolean = false;\n isPaymentDetailsEmpty: boolean = false;\n isPaymentDetailsInvalid: boolean = false;\n paymentDetailsMinHasError: boolean = false;\n paymentDetailsMaxHasError: boolean = false;\n isUserNameEmpty: boolean = false;\n isUserNameInvalid: boolean = false;\n ccdReference: string = null;\n exceptionReference: string = null;\n paymentReason: string = null;\n paymentExplanation: string = null;\n userName: string = null;\n paymentSectionLabel: any;\n paymentRef: string = null;\n isStrategicFixEnable: boolean = true;\n orderLevelFees: IOrderReferenceFee[] = [];\n cookieUserName: string[] = [];\n enCookieUserName: any;\n userNameField: string = null;\n\n reasonList: { [key: string]: { [key: string]: string } }= {\n overPayment: {\n hwfReward: 'Help with Fees (HWF) awarded. Please include the HWF reference number in the explanatory note',\n wrongFee: 'Incorrect payment received',\n notIssueCase: 'Unable to issue case',\n otherDeduction: 'Other'\n },\n shortFall: {\n helpWithFee: 'Help with Fees (HWF) application declined',\n wrongFee: 'Incorrect payment received',\n other: 'Other'\n }\n }\n explanationList = {\n overPayment: {\n referRefund: 'Details in case notes. Refund due',\n noRefund: 'Details in case notes. No refund due',\n noCase: 'No case created. Refund due',\n other: 'Other'\n },\n shortFall: {\n holdCase: 'I have put a stop on the case and contacted the applicant requesting the balance of payment',\n heldCase: 'I have put a stop on the case. The applicant needs to be contacted to request the balance of payment',\n other: 'Other'\n }\n }\n\n refund = {\n reason: {\n duplicate: 'Duplicate payment',\n humanerror: 'Human error',\n caseWithdrawn: 'Case withdrawn',\n other: 'Other'\n }\n }\n\n\n constructor(\n private errorHandlerService: ErrorHandlerService,\n private caseTransactionsService: CaseTransactionsService,\n private formBuilder: FormBuilder,\n private paymentViewService: PaymentViewService,\n private paymentLibComponent: PaymentLibComponent,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private OrderslistService: OrderslistService) { }\n\n ngOnInit() {\n this.viewStatus = 'mainForm';\n if (this.paymentLibComponent.paymentGroupReference !== null) {\n this.viewStatus = 'allocatePaymentConfirmation';\n }\n \n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.bspaymentdcn = this.paymentLibComponent.bspaymentdcn;\n this.paymentRef = this.paymentLibComponent.paymentGroupReference;\n this.selectedOption = this.paymentLibComponent.SELECTED_OPTION;\n this.isStrategicFixEnable = this.paymentLibComponent.ISSFENABLE;\n this.isTurnOff = this.paymentLibComponent.isTurnOff;\n this.overUnderPaymentForm = this.formBuilder.group({\n moreDetails: new FormControl('', Validators.compose([\n Validators.required,\n Validators.minLength(3),\n Validators.maxLength(255),\n Validators.pattern('^([a-zA-Z0-9\\\\s,\\\\.]*)$')\n ])),\n userName: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^([a-zA-Z0-9\\\\s]*)$')\n ])),\n });\n this.OrderslistService.getOrdersList().subscribe( (data) =>\n this.orderLevelFees = data.filter(data => data.orderStatus !== 'Paid'));\n this.OrderslistService.getCaseType().subscribe( (data) => this.caseType = data);\n this.getUnassignedPayment();\n }\n getGroupOutstandingAmount(paymentGroup: IPaymentGroup): number {\n return this.bulkScaningPaymentService.calculateOutStandingAmount(paymentGroup);\n }\n\n getPaymentGroupDetails(){\n\n if(!this.isTurnOff){\n this.paymentViewService.getPaymentGroupDetails(this.paymentRef).subscribe(\n paymentGroup => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.paymentGroup = paymentGroup;\n this.saveAndContinue();\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n );\n }else {\n this.caseTransactionsService.getPaymentGroups(this.ccdCaseNumber).subscribe(\n paymentGroups => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.paymentGroups = paymentGroups['payment_groups'].filter(paymentGroup => {\n paymentGroup.fees.forEach(fee => {\n if(fee.calculated_amount === 0) {\n this.isFeeAmountZero = true\n }\n });\n let fstCon = this.getGroupOutstandingAmount(<IPaymentGroup>paymentGroup),\n scndCn = fstCon > 0 || (fstCon == 0 && this.isFeeAmountZero) && paymentGroup.payment_group_reference === this.paymentRef;\n return this.paymentRef ? scndCn : fstCon > 0 || (fstCon == 0 && this.isFeeAmountZero);\n });\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n );\n }\n\n }\n\n selectedPaymentGroup(paymentGroup: IPaymentGroup) {\t\n this.isContinueButtondisabled = false;\t\n this.paymentGroup = paymentGroup;\t\n }\t\n\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n\n gotoSummaryPage(event: any) { \n event.preventDefault();\n this.paymentLibComponent.viewName = 'fee-summary';\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n }\n\n cancelAllocatePayment(event: any){\n event.preventDefault();\n this.resetForm([false, false, false, false, false, false, false, false], 'all');\n if(!this.isTurnOff){\n this.paymentLibComponent.viewName = 'fee-summary';\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.TAKEPAYMENT = true;\n this.paymentLibComponent.ISBSENABLE = true;\n } else {\n this.viewStatus = 'mainForm';\t\n }\n }\n confirmAllocatePayement(){\n this.enCookieUserName = document.cookie.split(\";\").find(row => row.includes(\"user-info\")).split(\"=\")[1].split(\";\");\n this.cookieUserName = JSON.parse(decodeURIComponent(this.enCookieUserName));\n \n const fullName = this.cookieUserName['forename'] + ' ' + this.cookieUserName['surname'];\n\n const paymentDetailsField = this.overUnderPaymentForm.controls.moreDetails,\n paymentFormError = this.overUnderPaymentForm.controls.moreDetails.errors,\n userNameField = fullName,\n isEmptyCondtion = this.paymentReason && this.paymentExplanation,\n isOtherOptionSelected = this.paymentExplanation === 'Other';\n\n this.resetForm([false, false, false, false, false, false, false, false], 'all');\n if ( (!this.isRemainingAmountGtZero && !this.isRemainingAmountLtZero) || isEmptyCondtion && (!isOtherOptionSelected && userNameField.length > 0 || isOtherOptionSelected && userNameField.length > 0 && paymentDetailsField.valid)) {\n this.isConfirmButtondisabled = true;\n this.otherPaymentExplanation = this.paymentExplanation === 'Other' ? paymentDetailsField.value : this.paymentExplanation;\n this.userName = userNameField;\n this.finalServiceCall();\n }else {\n if(!this.paymentReason) {\n this.resetForm([true, false, false, false, false, false, false, false], 'reason');\n }\n if(!this.paymentExplanation) {\n this.resetForm([false, true, false, false, false, false, false, false], 'explanation');\n }\n if(this.paymentExplanation && isOtherOptionSelected) {\n if(paymentDetailsField.value == '' ) {\n this.resetForm([false, false, true, false, false, false, false, false], 'other');\n }\n if(paymentDetailsField.value != '' && paymentDetailsField.invalid ) {\n this.resetForm([false, false, false, true, false, false, false, false], 'other');\n }\n if(paymentFormError && paymentFormError.minlength && paymentFormError.minlength.actualLength < 3 ) {\n this.resetForm([false, false, false, false, true, false, false, false], 'other');\n }\n if(paymentFormError && paymentFormError.maxlength && paymentFormError.maxlength.actualLength > 255 ) {\n this.resetForm([false, false, false, false, false, true, false, false], 'other');\n }\n }\n if(userNameField.length === 0) {\n this.resetForm([false, false, false, false, false, false, true, false], 'username');\n }\n }\n }\n resetForm(vals, field) {\n if(field==='reason' || field==='all') {\n this.paymentReasonHasError = vals[0];\n }\n if(field==='explanation' || field==='all') {\n this.paymentExplanationHasError = vals[1];\n }\n if(field==='other' || field==='all') {\n this.isPaymentDetailsEmpty = vals[2];\n this.isPaymentDetailsInvalid = vals[3];\n this.paymentDetailsMinHasError = vals[4];\n this.paymentDetailsMaxHasError = vals[5];\n }\n if(field==='username' || field==='all') {\n this.isUserNameEmpty = vals[6];\n this.isUserNameInvalid = vals[7];\n }\n }\n finalServiceCall() {\n if(!this.isStrategicFixEnable) {\n let allocatedRequest = {\n reason: this.paymentReason,\n allocation_status:'Allocated',\n explanation: this.otherPaymentExplanation,\n payment_allocation_status: {\n description: '',\n name: 'Allocated'\n },\n payment_group_reference: this.paymentGroup.payment_group_reference,\n case_type: this.caseType,\n user_name: this.userName\n }\n const postStrategicBody = new AllocatePaymentRequest\n (this.ccdReference, this.unAllocatedPayment, this.caseType, this.exceptionReference, allocatedRequest);\n this.bulkScaningPaymentService.postBSPaymentStrategic(postStrategicBody , this.paymentGroup.payment_group_reference).subscribe(\n res => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response = JSON.parse(res);\n if (response.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n });\n\n } else {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unAllocatedPayment.dcn_reference, 'PROCESSED').subscribe(\n res1 => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response1 = JSON.parse(res1);\n if (response1.success) {\n const requestBody = new AllocatePaymentRequest\n (this.ccdReference, this.unAllocatedPayment, this.siteID, this.exceptionReference);\n this.bulkScaningPaymentService.postBSAllocatePayment(requestBody, this.paymentGroup.payment_group_reference).subscribe(\n res2 => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response2 = JSON.parse(res2);\n const reqBody = new IAllocationPaymentsRequest\n (response2['data'].payment_group_reference, response2['data'].reference, this.paymentReason, this.otherPaymentExplanation, this.userName);\n if (response2.success) {\n this.paymentViewService.postBSAllocationPayments(reqBody).subscribe(\n \n res3 => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n let response3 = JSON.parse(res3);\n if (response3.success) {\n this.gotoCasetransationPage();\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unAllocatedPayment.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.bulkScaningPaymentService.patchBSChangeStatus(this.unAllocatedPayment.dcn_reference, 'COMPLETE').subscribe();\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n }\n );\n }\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n window.scrollTo(0, 0);\n this.isConfirmButtondisabled = false;\n }\n ); \n }\n }\n\n saveAndContinue(){\n if(this.paymentGroup) {\n this.isMoreDetailsBoxHide = true;\n this.overUnderPaymentForm.get('moreDetails').reset();\n this.overUnderPaymentForm.get('moreDetails').setValue('');\n this.overUnderPaymentForm.get('userName').reset();\n this.overUnderPaymentForm.get('userName').setValue('');\n this.paymentReason = '';\n this.paymentExplanation = '';\n let GroupOutstandingAmount = this.getGroupOutstandingAmount(this.paymentGroup);\n const remainingToBeAssigned = this.unAllocatedPayment.amount - GroupOutstandingAmount;\n this.isRemainingAmountGtZero = remainingToBeAssigned > 0;\n this.isRemainingAmountLtZero = remainingToBeAssigned < 0;\n this.paymentSectionLabel = this.isRemainingAmountGtZero ? { \n title: 'There is an Over payment of',\n reason: 'Provide a reason. This will be used in the Refund process.',\n }: this.isRemainingAmountLtZero ? { \n title: 'There is an Under payment of',\n reason: 'Provide a reason',\n }: { \n title:'Amount left to be allocated',\n reason:'',\n };\n this.feedbackUrlLabel = this.isRemainingAmountGtZero ? 'CONFIRMALLOCATION_SURPLUS' : this.isRemainingAmountLtZero ? 'CONFIRMALLOCATION_SHORTFALL' : 'CONFIRMALLOCATION';\n this.remainingAmount = this.isRemainingAmountGtZero ? remainingToBeAssigned : this.isRemainingAmountLtZero ? remainingToBeAssigned * -1 : 0;\n this.afterFeeAllocateOutstanding = remainingToBeAssigned >= 0 ? 0 : (remainingToBeAssigned * -1);\n this.amountForAllocation = GroupOutstandingAmount >= this.unAllocatedPayment.amount ? this.unAllocatedPayment.amount : GroupOutstandingAmount;\n if(this.isTurnOff){\n this.viewStatus = 'allocatePaymentConfirmation';\t\n }\n }\n }\n getUnassignedPayment() {\n this.bulkScaningPaymentService.getBSPaymentsByDCN(this.bspaymentdcn).subscribe(\n unassignedPayments => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.unAllocatedPayment = unassignedPayments['data'].payments.filter(payment => {\n return payment && payment.dcn_reference == this.bspaymentdcn;\n })[0];\n this.siteID = unassignedPayments['data'].responsible_service_id;\n const beCcdNumber = unassignedPayments['data'].ccd_reference,\n beExceptionNumber = unassignedPayments['data'].exception_record_reference,\n exceptionReference = beCcdNumber ? beCcdNumber === this.ccdCaseNumber ? null : this.ccdCaseNumber : this.ccdCaseNumber;\n this.ccdReference = beCcdNumber ? beCcdNumber : null;\n this.exceptionReference = beExceptionNumber ? beExceptionNumber : exceptionReference;\n this.getPaymentGroupDetails();\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n );\n }\n selectRadioButton(key, type) {\n this.isMoreDetailsBoxHide = true;\n if( type === 'explanation' && key === 'other' ){\n this.isPaymentDetailsEmpty = false;\n this.isPaymentDetailsInvalid = false;\n this.paymentDetailsMinHasError = false;\n this.paymentDetailsMaxHasError = false;\n this.isMoreDetailsBoxHide = false;\n }\n }\n OrderListSelectEvent(orderef: any){\n this.isContinueButtondisabled = false;\n this.recordId= orderef;\n }\n\n redirectToOrderFeeSearchPage() {\n // this.paymentLibComponent.bspaymentdcn = null;\n this.paymentLibComponent.paymentGroupReference = this.recordId;\n this.paymentLibComponent.isTurnOff = this.isTurnOff;\n this.paymentLibComponent.viewName = 'fee-summary';\n}\n}\n","import { IFee } from './IFee';\n\nexport class AddRemissionRequest {\n beneficiary_name: string;\n ccd_case_number: string;\n fee: IFee;\n hwf_amount: number;\n hwf_reference: string;\n payment_group_reference: string;\n case_type: string;\n\n constructor(ccd_case_number: string, fee: IFee, hwf_amount: number, hwf_reference: string, caseType: string) {\n this.ccd_case_number = ccd_case_number;\n this.fee = fee;\n this.hwf_amount = hwf_amount;\n this.hwf_reference = hwf_reference;\n this.case_type = caseType;\n }\n}\n","export class AddRetroRemissionRequest {\n hwf_amount: number;\n hwf_reference: string;\n\n constructor(hwf_amount: number, hwf_reference: string) {\n this.hwf_amount = hwf_amount;\n this.hwf_reference = hwf_reference;\n }\n}\n","import { IRefundContactDetails } from './IRefundContactDetails';\n\nexport class PostIssueRefundRetroRemission {\n remissionReference: string;\n contact_details: IRefundContactDetails;\n\n constructor(remissionReference : string, contactDeatils: any) {\n this.remissionReference= remissionReference;\n this.contact_details = contactDeatils;\n } \n}","import { Component, OnInit, Input, Output, EventEmitter} from '@angular/core';\nimport { FormBuilder, FormGroup, Validators, FormControl, RequiredValidator, FormArray } from '@angular/forms';\nimport { IFee } from '../../interfaces/IFee';\nimport {Router} from '@angular/router';\nimport { AddRemissionRequest } from '../../interfaces/AddRemissionRequest';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\n\nimport { IPayment } from '../../interfaces/IPayment';\nimport { RefundsService } from '../../services/refunds/refunds.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { IRefundReasons } from '../../interfaces/IRefundReasons';\nimport { AddRetroRemissionRequest } from '../../interfaces/AddRetroRemissionRequest';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\nimport { PostIssueRefundRetroRemission } from '../../interfaces/PostIssueRefundRetroRemission';\nimport {ChangeDetectorRef} from '@angular/core';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\nconst resolvedPromise = Promise.resolve(null);\n\n@Component({\n selector: 'ccpay-add-remission',\n templateUrl: './add-remission.component.html',\n styleUrls: ['./add-remission.component.scss']\n})\nexport class AddRemissionComponent implements OnInit {\n @Input() fee: IFee;\n @Input() fees: any [];\n @Input() payment: IPayment;\n @Input() remission: IRemission;\n @Input() ccdCaseNumber: string;\n @Input() caseType: string;\n @Input() viewCompStatus: string;\n @Input() paymentGroupRef: string;\n @Input() isTurnOff: boolean;\n @Input() isRefundRemission: boolean;\n @Input() isStrategicFixEnable: boolean;\n @Input() paidAmount: any;\n @Input() isFromRefundListPage: boolean;\n @Input() isFromPaymentDetailPage: boolean;\n @Input() isFromServiceRequestPage: boolean;\n @Input('isFullyRefund') isFullyRefund: boolean;\n @Input() feeamount: number;\n @Input() refundPaymentReference: string;\n @Input() isFromRefundStatusPage: boolean;\n @Input() changeRefundReason: string;\n @Input(\"isServiceRequest\") isServiceRequest: string;\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[];\n @Input('orderDetail') orderDetail: any[];\n @Input('orderRef') orderRef: string;\n @Input('orderStatus') orderStatus: string;\n @Input('orderParty') orderParty: string;\n @Input('orderCreated') orderCreated: Date;\n @Input('orderCCDEvent') orderCCDEvent: string;\n @Input('takepayment') takePayment: boolean;\n @Input('orderFeesTotal') orderFeesTotal: number;\n @Input('orderTotalPayments') orderTotalPayments: number;\n @Input('orderRemissionTotal') orderRemissionTotal: number;\n @Output() cancelRemission: EventEmitter<void> = new EventEmitter();\n //@Output() refundListReason: EventEmitter<any> = new EventEmitter({reason:string, code:string});\n @Output() refundListReason = new EventEmitter<{reason: string, code: string}>();\n @Output() refundListAmount: EventEmitter<string> = new EventEmitter();\n @Output() refundFees: EventEmitter<IFee[]> = new EventEmitter<IFee[]>();\n refund = {\n reason: {\n duplicate: 'Duplicate payment',\n humanerror: 'Human error',\n caseWithdrawn: 'Case withdrawn',\n other: 'Other'\n }\n }\n contactDetailsObj: IRefundContactDetails;\n notification: any;\n remissionForm: FormGroup;\n hasErrors = false;\n viewStatus = 'main';\n errorMessage = null;\n option: string = null;\n isConfirmationBtnDisabled: boolean = false;\n bsPaymentDcnNumber: string;\n selectedValue = 'yes';\n amount: any;\n retroRemission: boolean = false;\n remissionReference: string = '';\n refundReference: string;\n refundAmount: string;\n paymentExplanationHasError: boolean = false;\n refundReason:string;\n selectedRefundReason: string;\n selectedRefundReasonCode: string;\n displayRefundReason: string;\n refundCode:string;\n remessionPayment:IPayment;\n isRemissionCodeEmpty: boolean = false;\n remissionCodeHasError: boolean = false;\n isAmountEmpty: boolean = false;\n isReasonEmpty: boolean = false;\n amountHasError: boolean = false;\n isRemissionLessThanFeeError: boolean = false;\n refundHasError:boolean = false;\n isPaymentSuccess: boolean = false;\n isRemissionApplied: boolean = false;\n remissionamt:number;\n elementId:any;\n // refundReasons: any[] = [];\n commonRefundReasons: any[] = [];\n showReasonText: boolean;\n isRefundReasonsSelected: boolean;\n default: string;\n reasonLength: number;\n refundReasons:IRefundReasons[];\n pattern1: string;\n pattern2: string;\n sendOrderDetail: any[];\n sendOrderRef: string;\n paymentReference : string;\n class='';\n errorMsg = new Array();\n totalRefundAmount: number;\n quantityUpdated: number;\n fullRefund: boolean;\n allowedRefundAmount: number;\n isRemissionsMatch: boolean;\n paymentFees: IFee[];\n paymentGroup: IPaymentGroup;\n isStatusAllocated: boolean;\n isFromCheckAnsPage: boolean;\n refundAmtForFeeVolumes: number;\n paymentObj: IPayment;\n templateInstructionType: string;\n notificationPreview: boolean;\n \n component: { account_number: string; amount: number; case_reference: string; ccd_case_number: string; channel: string; currency: string; customer_reference: string; date_created: string; date_updated: string; description: string; method: string; organisation_name: string; payment_allocation: any[]; reference: string; service_name: string; site_id: string; status: string; };\n\n constructor(private formBuilder: FormBuilder,\n private router: Router,\n private paymentViewService: PaymentViewService,\n private notificationService : NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private refundService: RefundsService,\n private cd: ChangeDetectorRef,\n private OrderslistService: OrderslistService) { }\n\n ngOnInit() {\n this.errorMessage = '';\n this.errorMsg = [];\n this.default = 'Select a different reason';\n this.pattern1 = '^([a-zA-Z0-9]{3})-([a-zA-Z0-9]{3})-([a-zA-Z0-9]{3})$';\n this.pattern2 = '^([A-Za-z]{2}[0-9]{2})-([0-9]{6})$';\n if(this.viewCompStatus !== '' && this.viewCompStatus !== undefined){\n this.viewStatus = '';\n }\n if(this.remission) {\n }\n if(this.fee) {\n this.amount = (this.fee.volume * this.fee.calculated_amount);\n }\n \n if (this.payment){\n this.paymentReference = this.payment.reference;\n this.remessionPayment = this.payment;\n if(this.payment.status === 'Success') {\n this.isPaymentSuccess = true;\n }\n }\n this.option = this.paymentLibComponent.SELECTED_OPTION;\n this.bsPaymentDcnNumber = this.paymentLibComponent.bspaymentdcn;\n this.remissionForm = this.formBuilder.group({\n remissionCode: new FormControl('',\n Validators.compose([\n Validators.required,\n Validators.pattern(`(${this.pattern1})|(${this.pattern2})`)\n ])\n ),\n amount: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[0-9]+(\\.[0-9]{1,2})?$')\n ])),\n refundReason: new FormControl('', Validators.compose([Validators.required])),\n refundDDReason: new FormControl('', Validators.compose([Validators.required])),\n reason: new FormControl(),\n feeAmount: new FormControl(),\n feesList: this.formBuilder.array([])\n });\n const remissionctrls=this.remissionForm.controls;\n remissionctrls['refundDDReason'].setValue('Select a different reason', {onlySelf: true});\n if(this.refundPaymentReference !== undefined && this.refundPaymentReference.length >0) {\n this.paymentReference = this.refundPaymentReference\n } else {\n this.paymentReference = (this.payment !== undefined) ? this.payment.reference : ''; \n }\n \n\n if(this.isFromServiceRequestPage) {\n this.paymentViewService.getApportionPaymentDetails(this.paymentReference).subscribe(\n paymentGroup => {\n let fees = [];\n paymentGroup.fees.forEach(fee => {\n this.isRemissionsMatch = false;\n \n paymentGroup.remissions.forEach(rem => {\n if (rem.fee_code === fee.code) {\n this.isRemissionsMatch = true;\n fee['remissions'] = rem;\n fees.push(fee);\n }\n });\n if (!this.isRemissionsMatch) {\n fees.push(fee);\n }\n });\n paymentGroup.fees = fees\n this.paymentFees =fees;\n this.fees = fees;\n this.paymentGroup = paymentGroup;\n \n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n this.refundFeesList();\n },\n (error: any) => this.errorMessage = error\n );\n }\n\n \n if (this.fees && this.viewCompStatus === 'issuerefund') {\n this.refundFeesList();\n }\n\n if(this.viewCompStatus === ''){\n this.viewStatus = 'main';\n }\n \n if(this.viewCompStatus === 'issuerefundpage1'){\n this.refundService.getRefundReasons().subscribe(\n refundReasons => {\n this.refundReasons = refundReasons.filter((data) => data.recently_used === false);\n this.refundReasons = this.refundReasons.filter((data) => data.name !== 'Retrospective remission' && data.name !== 'Overpayment');\n this.cd.detectChanges();\n this.commonRefundReasons = refundReasons.filter((data) => data.recently_used === true);\n this.commonRefundReasons.sort((a, b) => a.toString().localeCompare(b));\n this.cd.detectChanges();\n } );\n this.refundReason = this.changeRefundReason;\n }\n\n if(this.viewCompStatus === 'processretroremissonpage' && this.isFromRefundListPage){\n this.viewStatus = 'processretroremissonpage';\n }\n if(this.orderDetail !== undefined){\n this.paymentViewService.getApportionPaymentDetails(this.orderDetail[0].payments[0].reference).subscribe(\n paymentGroup => {\n this.fees = paymentGroup.fees;\n this.paymentReference = paymentGroup.payments[0].reference;\n },\n (error: any) => this.errorMessage = error\n );\n }\n\n }\n goToPaymentViewComponent() {\n this.paymentLibComponent.paymentMethod = this.payment.method;\n this.paymentLibComponent.paymentGroupReference = this.paymentGroupRef;\n this.paymentLibComponent.paymentReference = this.paymentReference;\n //this.PaymentViewComponent.viewCompStatus = 'overpayment';\n this.paymentLibComponent.viewName = 'payment-view';\n }\n refundFeesList() {\n const creds = this.remissionForm.controls.feesList as FormArray;\n // if(creds.controls.length > 0) {\n for(var i=0;i<this.fees.length;i++) {\n creds.push(this.formBuilder.group({\n id: this.fees[i].id,\n code: this.fees[i].code,\n volume: this.fees[i].volume,\n calculated_amount: this.fees[i].calculated_amount,\n apportion_amount: this.fees[i].apportion_amount,\n ccd_case_number: this.fees[i].ccd_case_number,\n description: this.fees[i].description,\n net_amount: this.fees[i].net_amount,\n version: this.fees[i].version,\n refund_amount : [''],\n selected:[''] ,\n updated_volume: this.fees[i].volume\n }));\n }\n this.cd.detectChanges();\n //}\n }\n\n get feesList()\n {\n const dd =this.remissionForm.get('feesList') as FormArray ;\n return this.remissionForm.get('feesList') as FormArray;\n }\n\n noneSelected(){\n if(this.isFullyRefund) {\n return false;\n } else {\n if(!this.feesList.controls.some(item => item.get('selected').value === true)) {\n this.errorMsg = [];\n [].forEach.call(document.querySelectorAll('input'), function (el) {\n el.classList.remove('inline-error-class');\n });\n }\n return !this.feesList.controls.some(item => item.get('selected').value === true);\n }\n }\n \n check_en (i,v1: any, AppAmt,Volume) {\n const ele = document.getElementById(v1) as HTMLInputElement;\n const formArray = this.remissionForm.controls.feesList as FormArray;\n \n if(ele.checked){\n formArray.at(i).get('refund_amount').setValue(AppAmt);\n formArray.at(i).get('volume').setValue(Volume);\n formArray.at(i).get('selected').setValue(true);\n formArray.at(i).get('updated_volume').setValue(Volume);\n (<HTMLInputElement>document.getElementById('feeAmount_'+v1)).value = AppAmt;\n document.getElementById('feeAmount_'+v1).removeAttribute(\"disabled\"); \n if(Volume === 1) {\n (<HTMLInputElement>document.getElementById('VolumeUpdated_'+v1)).value = Volume;\n } else {\n (<HTMLInputElement>document.getElementById('feeVolumeUpdated_'+v1)).value = Volume;\n }\n \n if (document.getElementById('feeVolumeUpdated_'+v1) !== null) {\n document.getElementById('feeAmount_'+v1).removeAttribute(\"disabled\"); \n document.getElementById('feeVolumeUpdated_'+v1).removeAttribute(\"disabled\"); \n } \n this.cd.detectChanges(); \n } else {\n this.errorMsg = []; \n document.getElementById('feeAmount_'+v1).setAttribute(\"disabled\", \"true\"); \n this.remissionForm.value.feesList[i][\"refund_amount\"] = ''; \n this.remissionForm.value.feesList[i][\"volume\"] = ''; \n this.remissionForm.value.feesList[i][\"selected\"] = false; \n (<HTMLInputElement>document.getElementById('feeAmount_'+v1)).value = '';\n if(Volume>1) {\n this.remissionForm.value.feesList[i][\"volume\"] = ''; \n (<HTMLInputElement>document.getElementById('feeVolumeUpdated_'+v1)).value = '';\n }\n \n if (document.getElementById('feeVolumeUpdated_'+v1) !== null) {\n document.getElementById('feeVolumeUpdated_'+v1).removeAttribute(\"disabled\"); \n }\n this.cd.detectChanges();\n } \n }\n\n\n addRemission() {\n this.resetRemissionForm([false, false, false, false, false, false], 'All');\n const remissionctrls=this.remissionForm.controls,\n isRemissionLessThanFee = this.fee.calculated_amount > remissionctrls.amount.value;\n this.remissionForm.controls['refundReason'].setErrors(null);\n this.remissionForm.controls['refundDDReason'].setErrors(null);\n if (this.remissionForm.dirty && this.remissionForm.valid && isRemissionLessThanFee) {\n this.viewStatus = 'confirmation';\n }else {\n\n if(remissionctrls['remissionCode'].value == '' ) {\n this.resetRemissionForm([true, false, false, false, false, false], 'remissionCode');\n }\n if(remissionctrls['remissionCode'].value != '' && remissionctrls['remissionCode'].invalid ) {\n this.resetRemissionForm([false, true, false, false, false, false], 'remissionCode');\n }\n if(remissionctrls['amount'].value == '' ) {\n this.resetRemissionForm([false, false, true, false, false, false], 'amount');\n }\n if(remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid ) {\n this.resetRemissionForm([false, true, false, true, false, false], 'amount');\n }\n if(remissionctrls.amount.valid && !isRemissionLessThanFee){\n this.resetRemissionForm([false, false, false, false, true, false], 'amount');\n }\n }\n }\n\n confirmRemission() {\n this.isConfirmationBtnDisabled = true;\n const newNetAmount = this.remissionForm.controls.amount.value,\n remissionAmount = this.fee.net_amount - newNetAmount,\n requestBody = new AddRemissionRequest\n (this.ccdCaseNumber, this.fee, remissionAmount, this.remissionForm.controls.remissionCode.value, this.caseType);\n this.paymentViewService.postPaymentGroupWithRemissions(decodeURIComponent(this.paymentGroupRef).trim(), this.fee.id, requestBody).subscribe(\n response => {\n if (JSON.parse(response).success) {\n let LDUrl = this.isTurnOff ? '&isTurnOff=Enable' : '&isTurnOff=Disable'\n LDUrl += `&caseType=${this.caseType}`\n if (this.paymentLibComponent.bspaymentdcn) {\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(`/payment-history/${this.ccdCaseNumber}?view=fee-summary&selectedOption=${this.option}&paymentGroupRef=${this.paymentGroupRef}&dcn=${this.paymentLibComponent.bspaymentdcn}${LDUrl}`);\n }else {\n this.gotoCasetransationPage();\n }\n\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n }\n );\n }\n\n resetRemissionForm(val, field){\n if (field==='All'){\n this.isRemissionCodeEmpty = val[0];\n this.remissionCodeHasError = val[1];\n this.isAmountEmpty = val[2];\n this.amountHasError = val[3];\n this.isRemissionLessThanFeeError = val[4];\n this.isReasonEmpty = val[5];\n } else if(field==='remissionCode' || field==='All') {\n this.isRemissionCodeEmpty = val[0];\n this.remissionCodeHasError = val[1];\n } else if (field==='amount' || field==='All'){\n this.isAmountEmpty = val[2];\n this.amountHasError = val[3];\n this.isRemissionLessThanFeeError = val[4];\n } else if (field==='reason' || field==='All'){\n this.isReasonEmpty = val[5];\n }\n }\n\n // Add retro remission changes\n addRemissionCode() {\n this.errorMessage = false;\n // this.isFromCheckAnsPage = true;\n this.errorMsg = [];\n this.viewStatus = '';\n this.isRefundRemission = false;\n this.resetRemissionForm([false, false, false, false, false, false], 'All');\n const remissionctrls=this.remissionForm.controls\n // isRemissionLessThanFee = this.fee.calculated_amount >= remissionctrls.amount.value;\n this.remissionForm.controls['refundReason'].setErrors(null);\n this.remissionForm.controls['refundDDReason'].setErrors(null);\n this.remissionForm.controls['amount'].setErrors(null);\n if (this.remissionForm.dirty && this.remissionForm.valid ) {\n if (!this.isFromCheckAnsPage) {\n this.viewCompStatus = '';\n this.viewStatus = \"processretroremissonpage\";\n } else {\n this.viewCompStatus = '';\n this.viewStatus = 'checkretroremissionpage';\n }\n \n }else {\n\n if(remissionctrls['remissionCode'].value == '' ) {\n this.resetRemissionForm([true, false, false, false, false], 'remissionCode');\n }\n if(remissionctrls['remissionCode'].value != '' && remissionctrls['remissionCode'].invalid ) {\n this.resetRemissionForm([false, true, false, false, false], 'remissionCode');\n }\n if(remissionctrls['amount'].value == '' ) {\n this.resetRemissionForm([false, false, true, false, false], 'amount');\n }\n if(remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid ) {\n this.resetRemissionForm([false, true, false, true, false], 'amount');\n }\n if(remissionctrls['reason'].value == '') {\n this.resetRemissionForm([false, false, false, true, false, true], 'reason');\n }\n if(remissionctrls.amount.valid){\n this.resetRemissionForm([false, false, false, false, true], 'amount');\n }\n\n }\n }\n\n\n gotoAddRetroRemissionCodePage() {\n this.errorMessage = false;\n this.isFromCheckAnsPage = false;\n this.errorMsg = [];\n if(this.isRefundRemission) {\n this.refundListAmount.emit();\n this.paymentLibComponent.isFromRefundStatusPage = true;\n return;\n }\n if ( this.isFromRefundListPage ) {\n this.paymentLibComponent.iscancelClicked = true;\n this.refundListReason.emit({reason: this.selectedRefundReason, code: this.refundReason});\n this.paymentLibComponent.isFromRefundStatusPage = true;\n return;\n }\n this.viewStatus = '';\n this.selectedValue = 'yes';\n this.viewCompStatus = \"addremission\";\n this.isRefundRemission = true;\n this.errorMessage = '';\n this.errorMsg = [];\n if(this.isFromPaymentDetailPage) {\n this.paymentLibComponent.viewName = 'payment-view';\n }\n }\n\n gotoCheckRetroRemissionPage(payment: IPayment) {\n this.paymentLibComponent.iscancelClicked = false;\n this.errorMessage = '';\n this.resetRemissionForm([false, false, false, false, false], 'All');\n if( !this.isRefundRemission) {\n var remissionctrls=this.remissionForm.controls,\n isRemissionLessThanFee = this.fee.calculated_amount >= remissionctrls.amount.value;\n if (this.remissionForm.dirty ) {\n if(remissionctrls['amount'].value == '' || remissionctrls['amount'].value < 0) {\n this.resetRemissionForm([false, false, true, false, false], 'amount');\n } else if(remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid ) {\n this.resetRemissionForm([false, false, false, true, false], 'amount');\n } else if(remissionctrls.amount.valid && !isRemissionLessThanFee){\n this.resetRemissionForm([false, false, false, false, true], 'amount');\n } else {\n this.viewCompStatus = '';\n this.viewStatus = \"checkretroremissionpage\";\n }\n }\n } else {\n var remissionctrls=this.remissionForm.controls;\n //if (this.remissionForm.dirty ) {\n if(remissionctrls['amount'].value == '' || remissionctrls['amount'].value < 0 ) {\n this.resetRemissionForm([false, false, true, false, false], 'amount');\n } else {\n this.viewCompStatus = '';\n this.viewStatus = \"checkretroremissionpage\";\n this.refundListAmount.emit(remissionctrls['amount'].value);\n }\n //}\n\n }\n }\n gotoAmountRetroRemission() {\n this.isFromCheckAnsPage = false;\n this.viewStatus = 'processretroremissonpage';\n this.viewCompStatus = '';\n // this.isRefundRemission = true;\n this.errorMessage = '';\n }\n gotoProcessRetroRemissionPage() {\n this.isFromCheckAnsPage = true;\n this.viewStatus = '';\n this.viewCompStatus = 'addremission';\n this.isRefundRemission = true;\n this.errorMessage = '';\n this.errorMsg = [];\n }\n\n gotoProcessRetroRemission(note?: IRefundContactDetails) {\n if(note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.isFromCheckAnsPage = true;\n this.viewStatus = 'remissionAddressPage';\n this.viewCompStatus = '';\n this.isRefundRemission = true;\n this.errorMessage = '';\n }\n\n confirmRetroRemission() {\n if(!this.isConfirmationBtnDisabled) {\n this.retroRemission = true;\n this.remissionamt = this.remissionForm.controls.amount.value;\n const requestBody = new AddRetroRemissionRequest(this.remissionamt,this.remissionForm.controls.remissionCode.value )\n this.paymentViewService.postPaymentGroupWithRetroRemissions(decodeURIComponent(this.paymentGroupRef).trim(), this.fee.id, requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.isRemissionApplied = true;\n this.viewCompStatus = '';\n this.viewStatus = 'retroremissionconfirmationpage';\n this.remissionReference =JSON.parse(response).remission_reference;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n }\n );\n }\n }\n\n processRefund() {\n this.errorMessage = '';\n this.errorMsg = [];\n this.isConfirmationBtnDisabled = true;\n if( this.isRefundRemission) {\n this.retroRemission = true;\n }\n if (this.remissionReference === undefined || this.remissionReference === '') {\n this.remissionReference = this.remission.remission_reference;\n }\n const requestBody = new PostIssueRefundRetroRemission(this.remissionReference, this.contactDetailsObj);\n this.paymentViewService.postRefundRetroRemission(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n })\n }\n\n // Issue Refund changes\n\n gotoIssueRefundConfirmation(payment: IPayment) {\n \n this.paymentLibComponent.iscancelClicked = false;\n if(this.paymentLibComponent.REFUNDLIST === \"true\") {\n this.isFromRefundListPage = true;\n }\n\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n\n\n this.errorMessage = '';\n this.errorMsg = [];\n this.refundReason = this.remissionForm.controls['refundReason'].value === null ? this.remissionForm.controls['refundDDReason'].value : this.remissionForm.controls['refundReason'].value;\n if(!this.refundReason || this.refundReason === 'Select a different reason') {\n this.refundHasError = true;\n } else if(this.selectedRefundReason.includes('Other') && (this.remissionForm.controls['reason'].value == '' || this.remissionForm.controls['reason'].value == null)) {\n this.resetRemissionForm([false, false, false, true, false, true], 'reason');\n } else if (this.selectedRefundReason.includes('Other') && this.remissionForm.controls['reason'].value !== '') {\n this.refundHasError = false;\n this.refundReason += '-' + this.remissionForm.controls['reason'].value;\n this.displayRefundReason = this.selectedRefundReason + '-' + this.remissionForm.controls['reason'].value;\n if ( this.isFromRefundListPage ) {\n this.refundListReason.emit({reason: this.displayRefundReason, code: this.refundReason});\n } else {\n if(this.isFromCheckAnsPage) {\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.isFromCheckAnsPage = false;\n this.viewStatus = 'checkissuerefundpage';\n this.viewCompStatus = '';\n this.notificationPreview = false;\n return;\n }\n this.viewCompStatus = '';\n this.viewStatus = 'contactDetailsPage';\n }\n\n } else {\n this.displayRefundReason = this.selectedRefundReason;\n if(this.isFromCheckAnsPage) {\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.isFromCheckAnsPage = false;\n this.viewStatus = 'checkissuerefundpage';\n this.viewCompStatus = '';\n this.notificationPreview = false;\n return;\n }\n if ( this.isFromRefundListPage ) {\n this.paymentLibComponent.isFromRefundStatusPage = true;\n this.refundListReason.emit({reason: this.selectedRefundReason, code: this.refundReason});\n } else {\n this.viewCompStatus = '';\n this.viewStatus = 'contactDetailsPage';\n }\n\n }\n }\n\n gotoIssueRefundPage() {\n this.errorMessage = '';\n this.viewCompStatus = 'issuerefund';\n this.viewStatus = '';\n this.isRefundRemission = true;\n this.errorMessage = false;\n this.errorMsg = [];\n this.refundHasError = false;\n this.isReasonEmpty = false;\n }\n\n gotoIssuePage(isFullyRefund: any){\nif(isFullyRefund) {\n this.viewCompStatus = 'issuerefundpage1';\n this.getRefundReasons();\n} else {\n [].forEach.call(document.querySelectorAll('input'), function (el) {\n el.classList.remove('inline-error-class');\n });\n\n\t var checkboxs = document.getElementsByTagName('input');\n\t this.errorMessage = '';\n this.totalRefundAmount = 0;\n this.errorMsg = []; \n\t\t\tfor (var j=0;j<checkboxs.length;j++)\n\t\t\t{\n\t\t\t\tif(checkboxs[j].checked)\n\t\t\t\t{\n\t\t\t\t\tthis.fullRefund = false;\n\t\t\t\t\tlet quantity: number = +(<HTMLInputElement>document.getElementById('feeVolume_'+checkboxs[j].value)).value;\n let amountToRefund: number = +(<HTMLInputElement>document.getElementById('feeAmount_'+checkboxs[j].value)).value;\n\t\t\t\t\tlet apportionAmount: number = +(<HTMLInputElement>document.getElementById('feeApportionAmount_'+checkboxs[j].value)).value;\n\t\t\t\t\tlet calculatedAmount: number = +(<HTMLInputElement>document.getElementById('calculatedAmount_'+checkboxs[j].value)).value; \n \n if( amountToRefund === apportionAmount) {\n this.fullRefund = true;\n }\n\n if(amountToRefund === 0){\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('You need to enter a refund amount');\n this.getErrorClass(this.elementId);\n\t\t\t\t\t}\n\n \n\n if (quantity === 1)\n {\n if(amountToRefund > 0 && amountToRefund > apportionAmount){\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('The amount you want to refund is more than the amount paid');\n this.getErrorClass(this.elementId);\n }\n } \n\n\t\t\t\t\tif(quantity > 1) {\n\n\t\t\t\t\t\tthis.quantityUpdated = +(<HTMLInputElement>document.getElementById('feeVolumeUpdated_'+checkboxs[j].value)).value;\n\n if(this.quantityUpdated === 0){\n this.elementId = 'feeVolumeUpdated_'+checkboxs[j].value;\n this.errorMsg.push('You need to enter quantity')\n this.getErrorClass(this.elementId);\n }\n\n if (this.fullRefund && quantity !== this.quantityUpdated) {\n this.elementId = 'feeVolumeUpdated_'+checkboxs[j].value;\n this.errorMsg.push('The quantity you want to refund should be maximun available quantity');\n this.getErrorClass(this.elementId);\n }\n\n if (!this.fullRefund && this.quantityUpdated > 0 && amountToRefund > 0) {\n this.refundAmtForFeeVolumes = +(<HTMLInputElement>document.getElementById('feeVOl_'+checkboxs[j].value)).innerText;\n this.allowedRefundAmount = this.quantityUpdated * this.refundAmtForFeeVolumes;\n if( this.allowedRefundAmount !== amountToRefund) \n {\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('The Amount to Refund should be equal to the product of Fee Amount and quantity');\n this.getErrorClass(this.elementId);\n }\n }\n\n if(!this.fullRefund && amountToRefund > apportionAmount)\n {\n this.elementId = 'feeAmount_'+checkboxs[j].value;\n this.errorMsg.push('The amount you want to refund is more than the amount paid');\n this.getErrorClass(this.elementId);\n }\n\t\n if( !this.fullRefund && this.quantityUpdated >0 && this.quantityUpdated > quantity){\n this.elementId = 'feeVolumeUpdated_'+checkboxs[j].value;\n this.errorMsg.push('The quantity you want to refund is more than the available quantity');\n this.getErrorClass(this.elementId);\n }\n }\n //this.remissionForm.value.feesList.find(id=>id=checkboxs[j].value)['refund_amount'] = apportionAmount;\n\t\t\t\t}\n\t\t\t}\n\n if(this.errorMsg.length === 0) {\n if (this.isFromCheckAnsPage) {\n this.isFromCheckAnsPage = false;\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.fees = this.remissionForm.value.feesList.filter(value => value.selected===true);\n this.viewStatus = 'checkissuerefundpage'\n this.viewCompStatus = '';\n this.notificationPreview = false;\n return;\n } else if (this.isFromRefundStatusPage){\n var remissionctrls=this.remissionForm.controls;\n this.totalRefundAmount = this.remissionForm.value.feesList.reduce((a, c) => a + c.refund_amount * c.selected, 0);\n this.refundListAmount.emit(this.totalRefundAmount.toString());\n this.fees = this.remissionForm.value.feesList.filter(value => value.selected===true);\n this.refundFees.emit(this.fees);\n return;\n }\n this.viewCompStatus = 'issuerefundpage1';\n this.getRefundReasons();\n }\n }\n }\n\n calAmtToRefund(value,amount,volume, i: any) {\n const volumeFee = amount/volume;\n const amtToRefund = value * volumeFee;\n const formArray = this.remissionForm.controls.feesList as FormArray;\n formArray.at(i).get('refund_amount').setValue(amtToRefund);\n // formArray.at(i).get('volume').setValue(value);\n // (<HTMLInputElement>document.getElementById('feeAmount_'+i)).value = +amtToRefund;\n // const formControl = this.remissionForm.controls.feesList['volume'].at(i);\n // formControl.setValue(value);\n\n }\n gotoContactDetailsPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewCompStatus = '';\n this.viewStatus = 'contactDetailsPage';\n this.isRefundRemission = true;\n this.errorMessage = false;\n }\n \n getRefundReasons(){\n if(this.viewCompStatus === 'issuerefundpage1'){\n this.refundService.getRefundReasons().subscribe(\n refundReasons => { \n this.refundReasons = refundReasons.filter((data) => data.recently_used === false);\n this.refundReasons = this.refundReasons.filter((data) => data.name !== 'Retrospective remission');\n this.cd.detectChanges();\n this.commonRefundReasons = refundReasons.filter((data) => data.recently_used === true);\n this.commonRefundReasons.sort((a, b) => a.toString().localeCompare(b));\n this.cd.detectChanges();\n } );\n }\n}\n getErrorClass(elementId) {\n if(this.errorMsg.length > 0) {\n const ele = document.getElementById(elementId);\n ele.classList.add('inline-error-class');\n }\n \n }\n\n changeIssueRefundReason() {\n this.isFromCheckAnsPage = true;\n this.errorMessage = '';\n this.errorMsg = [];\n this.refundHasError = false;\n this.isReasonEmpty = false;\n this.viewCompStatus = 'issuerefundpage1';\n this.viewStatus = '';\n this.isRefundRemission = true;\n }\n\n confirmIssueRefund(isFullyRefund: any) {\n this.isConfirmationBtnDisabled = true;\n this.errorMessage = '';\n this.errorMsg = [];\n if( this.isRefundRemission) {\n this.retroRemission = true;\n }\n if(isFullyRefund) {\n this.totalRefundAmount = this.payment.amount;\n }\n if(!isFullyRefund) {\n this.fees = this.remissionForm.value.feesList.filter(value => value.selected===true);\n }\n this.fees = this.fees.map(obj => ({ id: obj.id, \n code: obj.code,\n version:obj.version, \n apportion_amount: obj.apportion_amount,\n calculated_amount: obj.calculated_amount,\n updated_volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n refund_amount:obj.refund_amount ? obj.refund_amount : this.totalRefundAmount }));\n \n \n const requestBody = new PostRefundRetroRemission(this.contactDetailsObj, this.fees,this.payment.reference, this.refundReason, \n this.totalRefundAmount, 'op');\n this.paymentViewService.postRefundsReason(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference =JSON.parse(response).refund_reference;\n if(JSON.parse(response).refund_amount) {\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n })\n }\n\n gotoRefundReasonPage () {\n this.viewStatus = '';\n this.viewCompStatus = 'issuerefundpage1';\n \n }\n\n// Retro Refund\n\n // confirmRetroRefund() {\n // this.isConfirmationBtnDisabled = true;\n // this.errorMessage = '';\n // this.errorMsg = [];\n // if( this.isRefundRemission) {\n // this.retroRemission = true;\n // }\n\n // const requestBody = new PostRefundRetroRemission(this.payment.reference,'RR004-Retrospective remission', this.contactDetailsObj);\n // this.paymentViewService.postRefundsReason(requestBody).subscribe(\n // response => {\n // if (JSON.parse(response)) {\n // this.viewCompStatus = '';\n // this.viewStatus = 'retrorefundconfirmationpage';\n // this.refundReference =JSON.parse(response).refund_reference;\n // if(JSON.parse(response).refund_amount) {\n // this.refundAmount = JSON.parse(response).refund_amount;\n // }\n // }\n // },\n // (error: any) => {\n // this.errorMessage = error;\n // this.isConfirmationBtnDisabled = false;\n // });\n // }\n\n selectRadioButton(key, value) {\n localStorage.setItem(\"myradio\", value);\n const remissionctrls=this.remissionForm.controls;\n remissionctrls['refundDDReason'].setValue('Select a different reason', {onlySelf: true});\n remissionctrls['reason'].reset();\n this.isRefundReasonsSelected = true;\n this.errorMessage = false;\n this.errorMsg = [];\n this.isReasonEmpty = false;\n this.showReasonText = false;\n this.refundHasError = false;\n this.selectedRefundReason = value;\n this.selectedRefundReasonCode = key;\n if(this.selectedRefundReason.includes('Other')) {\n this.showReasonText = true;\n this.refundHasError = false;\n this.refundReason = value;\n }\n }\n\n selectchange(args) {\n const remissionctrls=this.remissionForm.controls;\n remissionctrls['refundReason'].reset();\n remissionctrls['reason'].reset();\n this.isRefundReasonsSelected = false;\n this.showReasonText = false;\n this.refundHasError = false;\n this.selectedRefundReason = args.target.options[args.target.options.selectedIndex].id;\n this.selectedRefundReasonCode = args.target.options[args.target.options.selectedIndex].value;\n this.reasonLength = (29-this.selectedRefundReason.split('- ')[1].length);\n\n if(this.selectedRefundReason.includes('Other')) {\n this.showReasonText = true;\n this.refundHasError = false;\n this.refundReason = args.target.options[args.target.options.selectedIndex].id;\n }\n\n\n }\n getContactDetails(obj:IRefundContactDetails, type) {\n this.contactDetailsObj = obj;\n this.viewCompStatus = '';\n this.notificationPreview = false;\n if(type == 'checkaddRefundpage'){\n this.getTemplateInstructionType(this.remessionPayment.reference,this.remessionPayment);\n }else if (type == 'checkissuerefundpage'){\n this.getTemplateInstructionType(this.payment.reference, this.payment);\n }else if(type == 'addrefundcheckandanswer'){\n this.getTemplateInstructionType(this.paymentReference, this.paymentObj);\n }\n this.viewStatus = type;\n }\n\n gotoPartialFeeRefundScreen() {\n\n if (this.isFromRefundStatusPage){\n var remissionctrls=this.remissionForm.controls;\n this.refundListReason.emit({reason: this.displayRefundReason, code: this.refundReason});\n return;\n }\n this.refundHasError = false;\n this.viewCompStatus = 'issuerefund';\n this.viewStatus = '';\n }\n\n \n\n gotoServiceRequestPage(event: any) {\n this.errorMessage ='';\n this.errorMsg = [];\n this.isFromCheckAnsPage = false;\n event.preventDefault();\n\n if (this.isFromRefundStatusPage){\n var remissionctrls=this.remissionForm.controls;\n this.totalRefundAmount = 0;\n this.refundListAmount.emit(this.totalRefundAmount.toString());\n return;\n }\n if (this.isFromServiceRequestPage && !this.isFromPaymentDetailPage) {\n this.viewStatus = 'order-full-view';\n this.viewCompStatus = '';\n } else if ( this.isFromRefundListPage ) {\n this.paymentLibComponent.iscancelClicked = true;\n this.refundListReason.emit({reason: this.selectedRefundReason, code: this.refundReason});\n this.paymentLibComponent.isFromRefundStatusPage = true;\n } else {\n this.paymentLibComponent.paymentMethod = this.payment.method;\n this.paymentLibComponent.paymentGroupReference = this.paymentLibComponent.paymentGroupReference\n this.paymentLibComponent.paymentReference = this.payment.reference;\n this.paymentLibComponent.viewName = 'payment-view';\n this.OrderslistService.setOrderRef(this.orderRef);\n this.OrderslistService.setorderCCDEvent(this.orderCCDEvent);\n this.OrderslistService.setorderCreated(this.orderCreated);\n this.OrderslistService.setorderDetail(this.orderDetail);\n this.OrderslistService.setorderParty(this.orderParty);\n this.OrderslistService.setorderTotalPayments(this.orderTotalPayments);\n this.OrderslistService.setorderRemissionTotal(this.orderRemissionTotal);\n this.OrderslistService.setorderFeesTotal(this.orderFeesTotal);\n this.viewStatus = 'payment-view';\n this.sendOrderDetail = this.orderDetail;\n this.sendOrderRef = this.orderRef;\n if(this.LOGGEDINUSERROLES === undefined) {\n this.OrderslistService.getUserRolesList().subscribe((data) => this.LOGGEDINUSERROLES = data);\n }\n this.viewCompStatus = '';\n }\n\n }\n gotoAddressPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewCompStatus = 'addrefundforremission';\n this.viewStatus = '';\n this.isRefundRemission = true;\n this.errorMessage = false;\n }\n gotoRemissionSuccess(event: Event) {\n event.preventDefault();\n this.errorMessage = '';\n this.viewCompStatus = '';\n this.viewStatus = 'retroremissionconfirmationpage';\n this.isRefundRemission = true;\n this.errorMessage = false;\n }\n\n gotoCasetransationPage() {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.errorMessage = '';\n this.errorMsg = [];\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.VIEW = 'case-transactions';\n this.paymentLibComponent.ISTURNOFF = this.isTurnOff;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.resetOrderData();\n let partUrl = this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl += this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl += this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl += `&caseType=${this.caseType}`;\n const url = `/payment-history/${this.ccdCaseNumber}?view=case-transactions&takePayment=${this.paymentLibComponent.TAKEPAYMENT}&selectedOption=${this.option}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n }\n\n gotoCasetransationPageCancelBtnClicked(event: Event) {\n event.preventDefault();\n this.errorMsg = [];\n if( this.paymentLibComponent.isFromServiceRequestPage !== undefined && !this.paymentLibComponent.isFromServiceRequestPage) {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.VIEW ='case-transactions';\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n } else { \n\n if (this.paymentLibComponent.REFUNDLIST) {\n this.paymentLibComponent.viewName = 'refund-list';\n return;\n }\n if (this.paymentLibComponent.TAKEPAYMENT === undefined && this.paymentLibComponent.SERVICEREQUEST === undefined) {\n this.paymentLibComponent.SERVICEREQUEST = 'false';\n }\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.OrderslistService.setpaymentPageView({method: '',payment_group_reference: '', reference:''});\n this.OrderslistService.setnavigationPage('casetransactions');\n this.errorMessage = '';\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISTURNOFF = this.isTurnOff;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.paymentLibComponent.ISBSENABLE = true;\n let partUrl = this.bsPaymentDcnNumber ? `&dcn=${this.bsPaymentDcnNumber}` : '';\n partUrl += this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl += this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n partUrl += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl += `&caseType=${this.caseType}`;\n if(this.isFromPaymentDetailPage) {\n partUrl += this.paymentLibComponent.isFromPaymentDetailPage\n }\n\n if(!this.paymentLibComponent.SERVICEREQUEST) {\n const url = `/payment-history/${this.ccdCaseNumber}?view=case-transactions&takePayment=${this.paymentLibComponent.TAKEPAYMENT}&selectedOption=${this.option}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n } else {\n const url =`/payment-history/${this.ccdCaseNumber}?selectedOption=${this.option}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n }\n }\n\n }\n\n resetOrderData() {\n this.OrderslistService.setOrderRef(null);\n this.OrderslistService.setorderCCDEvent(null);\n this.OrderslistService.setorderCreated(null);\n this.OrderslistService.setorderDetail(null);\n this.OrderslistService.setorderParty(null);\n this.OrderslistService.setorderTotalPayments(null);\n this.OrderslistService.setorderRemissionTotal(null);\n this.OrderslistService.setorderFeesTotal(null);\n }\n\n changeRefundAmount() { \n this.isFromCheckAnsPage = true;\n this.viewCompStatus = 'issuerefund';\n this.viewStatus = '';\n }\n\n getFormattedCurrency(currency:number){\n if(currency.toString().includes(\".\")){\n return currency\n }\n return currency.toString().concat(\".00\");\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n\n getTemplateInstructionType(paymentReference: string, payment?: IPayment): void {\n\n if (payment == undefined || payment == null || payment.reference != paymentReference) {\n this.paymentViewService.getPaymentDetails(paymentReference).subscribe(\n payment => {\n this.paymentObj = payment;\n this.paymentObj.reference = paymentReference;\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(this.paymentObj.channel, this.paymentObj.method);\n },\n (error: any) => { \n this.templateInstructionType = 'Template';\n })\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n }\n\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n@Pipe({\n name: 'ccdHyphens'\n})\nexport class CcdHyphensPipe implements PipeTransform {\n constructor() {}\n transform(value: any, args?: any): any {\n const pattern = /^([0-9]{4})+([0-9]{4})+([0-9]{4})+([0-9]{4})$/;\n if ( value.match(pattern)) {\n return value.replace(pattern,'$1-$2-$3-$4') \n }\n return value;\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n@Pipe({\n name: 'capitalize'\n})\nexport class CapitalizePipe implements PipeTransform {\n constructor() { }\n transform(s: any, args?: any): any {\n return s && s[0].toUpperCase() + s.slice(1) || \"\";\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n@Pipe({\n name: 'keyValue'\n})\nexport class keyValuePipe implements PipeTransform {\n constructor() {}\n transform(input: any): any {\n let keys = [];\n for (let key in input) {\n if (input.hasOwnProperty(key)) {\n keys.push({ key: key, value: input[key]});\n }\n }\n return keys;\n }\n}\n","import { Pipe, PipeTransform } from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\n\n@Pipe({ name: 'sanitizeHtml' })\nexport class SanitizeHtmlPipe implements PipeTransform {\n constructor(private sanitizer: DomSanitizer) {}\n transform(value: any): SafeHtml {\n return this.sanitizer.bypassSecurityTrustHtml(value);\n }\n}\n","import { Injectable } from '@angular/core';\nimport * as FileSaver from 'file-saver';\nimport * as XLSX from 'xlsx';\nimport * as XLSXStyle from 'xlsx-style';\n\n\nconst EXCEL_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8';\nconst EXCEL_EXTENSION = '.xlsx';\n\n@Injectable()\nexport class XlFileService {\n\n constructor() { }\n\n public exportAsExcelFile(json: any[], excelFileName: string): void {\n let worksheet: XLSX.WorkSheet; \n let workbook: XLSX.WorkBook; \n if(excelFileName.match('Data_Loss')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['loss_resp','payment_asset_dcn','env_ref','env_item','resp_service_id','resp_service_name','date_banked','bgc_batch','payment_method','amount']});\n worksheet = this.setDataLossReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else if(excelFileName.match('Unprocessed')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['resp_service_id','resp_service_name','exception_ref','ccd_ref','date_banked','bgc_batch','payment_asset_dcn','env_ref','env_item','payment_method','amount']});\n worksheet = this.setUnprocessedReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else if(excelFileName.match('Processed_Unallocated')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['resp_service_id','resp_service_name','allocation_status','receiving_office','allocation_reason','ccd_exception_reference','ccd_case_reference','payment_asset_dcn','env_ref','env_item','date_banked','bgc_batch','payment_method','amount']});\n worksheet = this.setProcessedUnallocatedReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else if(excelFileName.match('Payment failure')!== null){\n worksheet = XLSX.utils.json_to_sheet(json,{header:['payment_reference','ccd_reference','document_control_number','org_id','service_name','failure_reference','failure_reason','disputed_amount','event_name','event_date','representment_status','representment_date','refund_reference','refund_amount','refund_date']});\n worksheet = this.setPaymentFailureReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n } else {\n worksheet = XLSX.utils.json_to_sheet(json,{header:['resp_service_id','resp_service_name','surplus_shortfall','balance','payment_amount','ccd_case_reference', 'ccd_exception_reference', 'processed_date', 'reason', 'explanation', 'user_name']});\n worksheet = this.setShortFallReportHeaders(worksheet);\n worksheet = this.autoFitColumns(worksheet,json);\n }\n workbook = { Sheets: { 'data': worksheet }, SheetNames: ['data'] };\n const excelBuffer: any = XLSX.write(workbook, { bookType: 'xlsx', type: 'array' });\n this.saveAsExcelFile(excelBuffer, excelFileName);\n }\n\n\nprivate autoFitColumns (worksheet: XLSX.WorkSheet,json:any) : XLSX.WorkSheet {\n let objectMaxLength = []; \n let ColWidth = [];\n let obj = <any>Object;\n for (let i = 0; i < json.length; i++) {\n let value = obj.values(json[i]);\n let key = obj.keys(json[i]);\n for (let j = 0; j < value.length; j++) {\n if(value[j] === null){\n value[j] = '';\n }\n objectMaxLength[j] =\n key[j].length >= value[j].length\n ? key[j].length+2\n : value[j].length+1;\n if( value[j].length === undefined){\n objectMaxLength[j] = key[j].length+2;\n }\n ColWidth.push({'width': +objectMaxLength[j]});\n }\n }\n worksheet['!cols'] = ColWidth;\n return worksheet;\n}\n\n\nprivate setDataLossReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Loss_Resp\";\n worksheet.B1.v = \"Payment_Asset_DCN\";\n worksheet.C1.v = \"Envelope_Ref\";\n worksheet.D1.v = \"Envelope_Item\";\n worksheet.E1.v = \"Resp_Service ID\";\n worksheet.F1.v = \"Resp_Service Name\";\n worksheet.G1.v = \"Date_Banked\";\n worksheet.H1.v = \"BGC_Batch\";\n worksheet.I1.v = \"Payment_Method\";\n worksheet.J1.v = \"Amount\";\n return worksheet;\n}\n\nprivate setUnprocessedReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Resp_Service ID\";\n worksheet.B1.v = \"Resp_Service Name\";\n worksheet.C1.v = \"Exception_Ref\";\n worksheet.D1.v = \"CCD_Ref\";\n worksheet.E1.v = \"Date_Banked\";\n worksheet.F1.v = \"BGC_Batch\";\n worksheet.G1.v = \"Payment_Asset_DCN\";\n worksheet.H1.v = \"Envelope_Ref\";\n worksheet.I1.v = \"Envelope_Item\";\n worksheet.J1.v = \"Payment_Method\";\n worksheet.K1.v = \"Amount\";\n return worksheet;\n}\n\nprivate setProcessedUnallocatedReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Resp_Service ID\";\n worksheet.B1.v = \"Resp_Service Name\";\n worksheet.C1.v = \"Allocation_Status\";\n worksheet.D1.v = \"Receiving_Office\";\n worksheet.E1.v = \"Allocation_Reason\";\n worksheet.F1.v = \"CCD_Exception_Ref\";\n worksheet.G1.v = \"CCD_Case_Ref\";\n worksheet.H1.v = \"Payment_Asset_DCN\";\n worksheet.I1.v = \"Envelope_Ref\";\n worksheet.J1.v = \"Envelope_Item\";\n worksheet.K1.v = \"Date_Banked\";\n worksheet.L1.v = \"BGC_Batch\";\n worksheet.M1.v = \"Payment_Method\";\n worksheet.N1.v = \"Amount\";\n return worksheet;\n}\n\nprivate setPaymentFailureReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Payment reference\";\n worksheet.B1.v = \"CCD reference\";\n worksheet.C1.v = \"Document Control Number\";\n worksheet.D1.v = \"OrgID\";\n worksheet.E1.v = \"Service name\";\n worksheet.F1.v = \"Failure reference\";\n worksheet.G1.v = \"Failure reason\";\n worksheet.H1.v = \"Disputed amount\";\n worksheet.I1.v = \"Event name\";\n worksheet.J1.v = \"Event date\";\n worksheet.K1.v = \"Representment status\";\n worksheet.L1.v = \"Representment date\";\n worksheet.M1.v = \"Refund reference\";\n worksheet.N1.v = \"Refund amount\";\n worksheet.O1.v = \"Refund date\";\n return worksheet;\n}\nprivate setShortFallReportHeaders (worksheet: XLSX.WorkSheet): XLSX.WorkSheet {\n worksheet.A1.v = \"Resp_Service ID\";\n worksheet.B1.v = \"Resp_Service Name\";\n worksheet.C1.v = \"Over Payment_Under Payment\";\n worksheet.D1.v = \"Balance\";\n worksheet.E1.v = \"Payment_Amount\";\n worksheet.F1.v = \"CCD_Case_Ref\";\n worksheet.G1.v = \"Exception_Ref\";\n worksheet.H1.v = \"Processed_Date\";\n worksheet.I1.v = \"Reason\";\n worksheet.J1.v = \"Explanation\";\n worksheet.K1.v = \"Updated Name\";\n return worksheet;\n}\n\nprivate saveAsExcelFile(buffer: any, fileName: string): void {\n const data: Blob = new Blob([buffer], {\n type: EXCEL_TYPE\n });\n FileSaver.saveAs(data, fileName + EXCEL_EXTENSION);\n }\n}\n","import { Component, Input, OnInit } from '@angular/core';\nimport { FormBuilder, FormGroup, FormControl } from '@angular/forms';\nimport { formatDate } from \"@angular/common\";\nimport {IPaymentGroup} from '../../interfaces/IPaymentGroup';\nimport { BulkScaningPaymentService } from '../../services/bulk-scaning-payment/bulk-scaning-payment.service';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport {XlFileService} from '../../services/xl-file/xl-file.service';\nimport { FindValueSubscriber } from 'rxjs/internal/operators/find';\n\n@Component({\n selector: 'ccpay-reports',\n templateUrl: './reports.component.html',\n styleUrls: ['./reports.component.scss']\n})\nexport class ReportsComponent implements OnInit {\n @Input() ISPAYMENTSTATUSENABLED: string;\n fmt = 'dd/MM/yyyy';\n loc = 'en-US';\n reportsForm: FormGroup;\n startDate: string;\n endDate: string;\n errorMeaagse: string;\n ccdCaseNumber: string;\n isDownLoadButtondisabled:Boolean = false;\n isStartDateLesthanEndDate: Boolean = false;\n isDateBetwnMonth: Boolean = false;\n isDateRangeBetnWeek: Boolean = false;\n errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n paymentGroups: IPaymentGroup[] = [];\n\n constructor(\n private xlFileService: XlFileService,\n private errorHandlerService: ErrorHandlerService,\n private formBuilder: FormBuilder,\n private bulkScaningPaymentService: BulkScaningPaymentService,\n private paymentViewService: PaymentViewService) { }\n \n\n ngOnInit() {\n this.fromValidation();\n\n }\n\n getToday(): string {\n return new Date().toISOString().split('T')[0];\n }\n\n getSelectedFromDate(): void {\n this.validateDates(this.reportsForm.get('selectedreport').value);\n }\n\n validateDates(reportName){\n const selectedStartDate = this.tranformDate(this.reportsForm.get('startDate').value),\n selectedEndDate = this.tranformDate(this.reportsForm.get('endDate').value);\n const isDateRangeMoreThanWeek = (<any>new Date(selectedStartDate) - <any>new Date(selectedEndDate))/(1000 * 3600 * -24) > 7;\n const isDateRangeMoreThanMonth = (<any>new Date(selectedStartDate) - <any>new Date(selectedEndDate))/(1000 * 3600 * -24) > 30;\n if(new Date(selectedStartDate) > new Date(selectedEndDate) && selectedEndDate !== ''){\n this.reportsForm.get('startDate').setValue('');\n this.isDateRangeBetnWeek = false;\n this.isDateBetwnMonth = false;\n this.isStartDateLesthanEndDate = true;\n } else if(reportName && reportName ==='SURPLUS_AND_SHORTFALL' && isDateRangeMoreThanWeek ) {\n this.isDateRangeBetnWeek = true;\n this.isDateBetwnMonth = false;\n this.isStartDateLesthanEndDate = false;\n } else if(reportName && reportName ==='PAYMENT_FAILURE_EVENT' && isDateRangeMoreThanMonth ) {\n this.isDateRangeBetnWeek = false;\n this.isDateBetwnMonth = true;\n this.isStartDateLesthanEndDate = false;\n } else {\n this.isDateBetwnMonth = false;\n this.isDateRangeBetnWeek = false;\n this.isStartDateLesthanEndDate = false;\n }\n\n }\n\n fromValidation() {\n this.reportsForm = this.formBuilder.group({\n selectedreport: new FormControl('') ,\n startDate: new FormControl(''),\n endDate: new FormControl('') \n });\n}\n\ndownloadReport(){\n this.isDownLoadButtondisabled = true;\n const dataLossRptDefault = [{loss_resp:'',payment_asset_dcn:'',env_ref:'',env_item:'',resp_service_id:'',resp_service_name:'',date_banked:'',bgc_batch:'',payment_method:'',amount:''}],\n unProcessedRptDefault = [{resp_service_id:'',resp_service_name:'',exception_ref:'',ccd_ref:'',date_banked:'',bgc_batch:'',payment_asset_dcn:'',env_ref:'',env_item:'',payment_method:'',amount:''}],\n processedUnallocated =[{resp_service_id:'',resp_service_name:'',allocation_status:'',receiving_office:'',allocation_reason:'',ccd_exception_ref:'',ccd_case_ref:'',payment_asset_dcn:'',env_ref:'',env_item:'',date_banked:'',bgc_batch:'',payment_method:'',amount:'',updated_by:''}],\n shortFallsRptDefault = [{resp_service_id:'',resp_service_name:'',surplus_shortfall:'',balance:'',payment_amount:'',ccd_case_reference:'',ccd_exception_reference:'',processed_date:'', reason:'', explanation:'', user_name:''}],\n selectedReportName = this.reportsForm.get('selectedreport').value,\n selectedStartDate = this.tranformDate(this.reportsForm.get('startDate').value),\n selectedEndDate = this.tranformDate(this.reportsForm.get('endDate').value);\n\n if(selectedReportName === 'PROCESSED_UNALLOCATED' || selectedReportName === 'SURPLUS_AND_SHORTFALL' ){\n this.paymentViewService.downloadSelectedReport(selectedReportName,selectedStartDate,selectedEndDate).subscribe(\n response => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n const result = JSON.parse(response);\n let res= {data: this.applyDateFormat(result)};\n if(res['data'].length === 0 && selectedReportName === 'PROCESSED_UNALLOCATED' ){\n res.data= processedUnallocated;\n } else if(res['data'].length === 0 && selectedReportName === 'SURPLUS_AND_SHORTFALL' ) {\n res.data= shortFallsRptDefault;\n } \n if(result['data'].length > 0) {\n for( var i=0; i< res['data'].length; i++) {\n if(res['data'][i][\"payment_asset_dcn\"] !== undefined) {\n res['data'][i]['env_ref'] = res['data'][i][\"payment_asset_dcn\"].substr(0,13);\n res['data'][i]['env_item'] = res['data'][i][\"payment_asset_dcn\"].substr(13,21);\n }\n if(res['data'][i][\"amount\"] !== undefined) {\n res['data'][i]['amount'] = this.convertToFloatValue(res['data'][i]['amount']);\n }\n if(res['data'][i][\"balance\"] !== undefined) {\n res['data'][i]['balance'] = this.convertToFloatValue(res['data'][i][\"balance\"]);\n }\n let Op = res['data'][i][\"surplus_shortfall\"];\n if(Op !== undefined) {\n res['data'][i]['surplus_shortfall'] = Op ==\"Surplus\" ? \"Over payment\":\"Under payment\";\n }\n if(res['data'][i][\"payment_amount\"] !== undefined) {\n res['data'][i]['payment_amount'] = this.convertToFloatValue(res['data'][i]['payment_amount']);\n }\n }\n } \n this.isDownLoadButtondisabled = false;\n this.xlFileService.exportAsExcelFile(res['data'], this.getFileName(this.reportsForm.get('selectedreport').value, selectedStartDate, selectedEndDate));\n },\n (error: any) => {\n this.isDownLoadButtondisabled = false;\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n })\n\n } else if(selectedReportName === 'PAYMENT_FAILURE_EVENT') {\n\n this.paymentViewService.downloadFailureReport(selectedStartDate,selectedEndDate).subscribe(\n response => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n const result = {data: JSON.parse(response)['payment_failure_report_list']};\n let res = {data: this.applyDateFormat(result)};\n if (result['data'].length > 0) {\n for ( var i=0; i< res['data'].length; i++) {\n if (res['data'][i][\"disputed_amount\"] !== undefined) {\n res['data'][i]['disputed_amount'] = this.convertToFloatValue(res['data'][i][\"disputed_amount\"]);\n }\n if (res['data'][i][\"representment_status\"] !== undefined) {\n res['data'][i]['representment_status'] = res['data'][i][\"representment_status\"].toLowerCase() === 'yes' ? 'Success' : 'Failure';\n }\n if (res['data'][i]['representment_status'] === undefined) {\n res['data'][i]['representment_status'] = 'No representment received';\n }\n if (res['data'][i]['representment_date'] === undefined) {\n res['data'][i]['representment_date'] = 'N/A';\n }\n if (res['data'][i]['refund_reference'] === undefined) {\n res['data'][i]['refund_reference'] = 'No refund available';\n }\n if (res['data'][i]['refund_amount'] === undefined) {\n res['data'][i]['refund_amount'] = 'N/A';\n }\n if (res['data'][i]['refund_date'] === undefined) {\n res['data'][i]['refund_date'] = 'N/A';\n }\n if (res['data'][i]['document_control_number'] === undefined) {\n res['data'][i]['document_control_number'] = 'N/A';\n }\n }\n }\n this.isDownLoadButtondisabled = false;\n this.xlFileService.exportAsExcelFile(res['data'], this.getFileName(this.reportsForm.get('selectedreport').value, selectedStartDate, selectedEndDate ));\n\n },\n (error: any) => {\n this.isDownLoadButtondisabled = false;\n const errorContent = error.replace(/[^a-zA-Z ]/g, '').trim();\n const statusCode = error.replace(/[^a-zA-Z0-9 ]/g, '').trim().split(' ')[0];\n if(statusCode === '404') {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, true, errorContent);\n }else {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n }\n })\n\n } else {\n this.bulkScaningPaymentService.downloadSelectedReport(selectedReportName,selectedStartDate,selectedEndDate).subscribe(\n response => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n const result = JSON.parse(response);\n let res = {data: this.applyDateFormat(result)};\n if(res['data'].length === 0 && selectedReportName === 'DATA_LOSS' ){\n res.data= dataLossRptDefault;\n } else if(res['data'].length === 0 && selectedReportName === 'UNPROCESSED'){\n res.data = unProcessedRptDefault;\n }\n if(result['data'].length > 0) {\n for( var i=0; i< res['data'].length; i++) {\n if(res['data'][i][\"amount\"] !== undefined) {\n res['data'][i]['amount'] = this.convertToFloatValue(res['data'][i]['amount']);\n }\n if(res['data'][i][\"payment_asset_dcn\"] !== undefined) {\n res['data'][i]['env_ref'] = res['data'][i][\"payment_asset_dcn\"].substr(0,13);\n res['data'][i]['env_item'] = res['data'][i][\"payment_asset_dcn\"].substr(13,21);\n }\n }\n }\n this.isDownLoadButtondisabled = false;\n this.xlFileService.exportAsExcelFile(res['data'], this.getFileName(this.reportsForm.get('selectedreport').value, selectedStartDate, selectedEndDate ));\n },\n (error: any) => {\n this.isDownLoadButtondisabled = false;\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n })\n }\n }\n\n getFileName(selectedOption: string, startDate: string, endDate: string ) {\n const loc = 'en-US',\n stDt = formatDate(startDate, 'ddMMyy', loc),\n enDt = formatDate(endDate, 'ddMMyy', loc),\n now = new Date(),\n currentDate = formatDate(now, 'ddMMyy', loc),\n timestamp = `${currentDate}_${this.getTwodigit(now.getHours())}${this.getTwodigit(now.getMinutes())}${this.getTwodigit(now.getSeconds())}`,\n selectedOptionTxt = this.getCamelCaseString(selectedOption);\n \n return selectedOptionTxt+'_'+stDt+'_To_'+enDt+'_Run_'+ timestamp;\n } \n tranformDate(strDate: string) {\n let result = '';\n if (strDate) {\n let parts = strDate.split('-');\n result = `${parts[1]}/${parts[2]}/${parts[0]}`;\n }\n return result;\n }\n getTwodigit(input: number){\n return (\"0\" + input).slice(-2);\n }\n getCamelCaseString(selectedOption) {\n let result;\n switch(selectedOption) { \n case 'UNPROCESSED': { \n result = 'Unprocessed';\n break; \n } \n case 'DATA_LOSS': { \n result = 'Data_Loss';\n break; \n } \n case 'PROCESSED_UNALLOCATED': { \n result = 'Processed_Unallocated';\n break; \n } \n case 'SURPLUS_AND_SHORTFALL': { \n result = 'Over Payment_Under Payment';\n break; \n } \n case 'PAYMENT_FAILURE_EVENT': { \n result = 'Payment failure event';\n break; \n }\n default: { \n result = selectedOption;\n break; \n } \n } \n return result;\n }\n applyDateFormat(res) {\n return res['data'].map(value => {\n if (value['date_banked']) {\n value['date_banked'] = formatDate(value['date_banked'], this.fmt, this.loc);\n }\n if (value['event_date'] && value['event_date'].indexOf(',') === -1) {\n value['event_date'] = formatDate(value['event_date'], this.fmt, this.loc);\n } else if (value['event_date'] && value['event_date'].indexOf(',') !== -1) {\n value['event_date'] = this.multiDateFormater(value['event_date'])\n }\n\n if (value['representment_date'] && value['representment_date'].indexOf(',') === -1) {\n value['representment_date'] = formatDate(value['representment_date'], this.fmt, this.loc);\n } else if (value['representment_date'] && value['representment_date'].indexOf(',') !== -1) {\n value['representment_date'] = this.multiDateFormater(value['representment_date'])\n }\n\n if (value['refund_date'] && value['refund_date'].indexOf(',') === -1) {\n value['refund_date'] = formatDate(value['refund_date'], this.fmt, this.loc);\n } else if (value['refund_date'] && value['refund_date'].indexOf(',') !== -1) {\n value['refund_date'] = this.multiDateFormater(value['refund_date'])\n }\n return value;\n });\n }\n multiDateFormater(dateStr) {\n return dateStr.split(',').map((date) => formatDate(date, this.fmt, this.loc)).join(',');\n }\n \n convertToFloatValue(amt) {\n return amt ? Number.parseFloat(amt).toFixed(2): '0.00';\n }\n}\n","import {Component, ViewChild, Input, ChangeDetectorRef} from '@angular/core';\nimport {PaymentLibComponent} from '../../payment-lib.component';\nimport { MatTableDataSource} from '@angular/material/table';\nimport {MatSort } from '@angular/material/sort';\nimport {Sort } from '@angular/material/sort';\nimport {MatPaginator } from '@angular/material/paginator';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { THIS_EXPR } from '@angular/compiler/src/output/output_ast';\nimport { ActivatedRoute,Router } from '@angular/router';\n@Component({\n selector: 'ccpay-table',\n templateUrl: './table.component.html',\n styleUrls: ['./table.component.css']\n})\nexport class TableComponent {\n @Input('DATASOURCE') DATASOURCE: any[];\n @Input('STATUS') STATUS: string;\n @Input('errorMessage') errorMessage: string;\n isApprovalFlow: boolean;\n // displayedColumns = ['ccdCaseNumber', 'refundReference', 'reason', 'createBy', 'updateDate', 'Action'];\n displayedColumns = ['ccd_case_number', 'refund_reference', 'user_full_name','date_created', 'date_updated', 'Action'];\n \n dataSource: MatTableDataSource<any>;\n userLst;\n serviceLst;\n actualcount: number;\n count: number;\n refundList: IRefundList[];\n @ViewChild(MatPaginator) paginator: MatPaginator;\n @ViewChild(MatSort) sort: MatSort;\n constructor(\n private paymentLibComponent: PaymentLibComponent,\n private cdRef: ChangeDetectorRef,\n private OrderslistService: OrderslistService,\n private router: Router,\n private activeRoute: ActivatedRoute\n ) {}\n ngOnInit() {\n this.errorMessage = this.errorMessage;\n if(this.STATUS.toLowerCase() === 'sent for approval') {\n this.isApprovalFlow = true;\n } else {\n this.isApprovalFlow = false;\n }\n this.refundList = this.DATASOURCE;\n this.dataSource = new MatTableDataSource(this.refundList);\n this.actualcount = this.dataSource.data.length;\n if( this.refundList !== undefined) {\n this.userLst = this.refundList.reduce((r,{user_full_name}) => (r[user_full_name]='', r) , {});\n this.userLst = Object.keys(this.userLst);\n this.userLst.sort((a, b) => a.toString().localeCompare(b));\n this.serviceLst = this.refundList.reduce((r,{service_type}) => (r[service_type]='', r) , {});\n this.serviceLst = Object.keys(this.serviceLst);\n this.serviceLst.sort((a, b) => a.toString().localeCompare(b));\n }\n \n }\n \n /**\n * Set the paginator and sort after the view init since this component will\n * be able to query its view for the initialized paginator and sort.\n */\n ngAfterViewInit() {\n \n this.dataSource.sort = this.sort;\n\n //const sortState: Sort = {active: 'date_updated', direction: 'desc'};\n // this.sort.active = sortState.active;\n // this.sort.direction = sortState.direction;\n // this.sort.sortChange.emit(sortState);\n this.dataSource.paginator = this.paginator;\n this.dataSource.sort = this.sort;\n this.cdRef.detectChanges();\n }\n applyFilter(filterValue: string) {\n filterValue = filterValue.trim(); // Remove whitespace\n filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches\n this.dataSource.filter = filterValue;\n }\n selectchange(args){\n this.dataSource.filter = args.target.value;\n this.actualcount = this.dataSource.data.length;\n this.dataSource.paginator = this.paginator;\n }\n goToRefundProcessComponent(refundReference: string, refundData: IRefundList ) {\n this.paymentLibComponent.refundlistsource = refundData;\n this.paymentLibComponent.refundReference = refundReference;\n this.paymentLibComponent.viewName = 'process-refund';\n }\n goToRefundViewComponent(refundReference: string, refundData: IRefundList ) {\n this.OrderslistService.setRefundView(refundData);\n this.paymentLibComponent.viewName='refundstatuslist';\n this.paymentLibComponent.CCD_CASE_NUMBER = refundData.ccd_case_number;\n this.paymentLibComponent.isRefundStatusView = true;\n this.paymentLibComponent.isCallFromRefundList = true;\n }\n goToCaseReview(ccdCaseNumber: string, refundData: IRefundList ) {\n this.router.navigate([`/cases/case-details/${ccdCaseNumber}`], {relativeTo: this.activeRoute});\n }\n}","import { IRefundContactDetails } from './IRefundContactDetails';\n\nexport class IPutNotificationRequest {\n recipient_email_address?: string;\n recipient_postal_address?: IRefundContactDetails\n \n constructor(contactDetails: any, notificationType: string) {\n if(notificationType === 'EMAIL') {\n this.recipient_email_address = contactDetails;\n } else if(notificationType === 'LETTER') {\n this.recipient_postal_address = contactDetails;\n }\n } \n}","import { IFee } from \"./IFee\";\nimport { IRefundContactDetails } from \"./IRefundContactDetails\";\nexport class IResubmitRefundRequest {\n refund_reason: string;\n amount: number;\n contact_details: IRefundContactDetails;\n refund_fees: IFee[];\n \n constructor(refund_reason : string, amount: number,contact_details:any,refund_fees: any[]) {\n this.refund_reason= refund_reason;\n this.amount = amount;\n this.contact_details = contact_details;\n this.refund_fees = refund_fees;\n } \n }\n ","import { Component, OnInit, Input } from '@angular/core';\nimport { RefundsService } from '../../services/refunds/refunds.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';\nimport { IRefundList } from '../../interfaces/IRefundList';\nimport { IRefundsNotifications } from '../../interfaces/IRefundsNotifications';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IPutNotificationRequest } from '../../interfaces/IPutNotificationRequest';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { IRefundStatus } from '../../interfaces/IRefundStatus';\nimport { IResubmitRefundRequest } from '../../interfaces/IResubmitRefundRequest';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IFee } from '../../interfaces/IFee';\nimport { IRefundFee } from '../../interfaces/IRefundFee';\n\n@Component({\n selector: 'ccpay-refund-status',\n templateUrl: './refund-status.component.html',\n styleUrls: ['./refund-status.component.css']\n})\nexport class RefundStatusComponent implements OnInit {\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[] = [];\n @Input('API_ROOT') API_ROOT: string;\n @Input() ccdCaseNumber: string;\n @Input() isTurnOff: boolean;\n @Input() orderParty: string;\n refundStatusForm: FormGroup;\n selectedRefundReason: string;\n rejectedRefundList: IRefundList[] = [];\n notificationList: any;\n notification:any;\n approvalStatus = 'Sent for approval';\n rejectStatus = 'Update required';\n errorMessage = null;\n viewName: string;\n refundReason: string;\n refundlist: IRefundList;\n bsPaymentDcnNumber: string;\n isCallFromRefundList: boolean;\n refundButtonState: string = '';\n isAmountEmpty: boolean = false;\n isReasonEmpty: boolean = false;\n amountHasError: boolean = false;\n isRemissionLessThanFeeError: boolean = false;\n refundHasError: boolean = false;\n refundReasons: any[] = [];\n refundStatusHistories: IRefundStatus[];\n refundNotifications: IRefundStatus[];\n isResendOperationSuccess: boolean = false;\n isEditDetailsClicked: boolean = false;\n isEditAddressDeatilsClicked: boolean = false;\n addressDetails: IRefundContactDetails;\n refundReference: string;\n refundAmount: string;\n refundCode: string;\n isRefundBtnDisabled: boolean = true;\n isFromPayBubble: boolean = false;\n oldRefundReason: string;\n refundreason: string;\n navigationpage: string;\n isLastUpdatedByCurrentUser: boolean = true;\n isProcessRefund: boolean = false;\n changedAmount: number;\n isRemissionsMatch: boolean;\n payment: IPayment;\n changeRefundReason: string;\n fees: IFee [];\n refundFees: IRefundFee[];\n paymentObj: IPayment;\n templateInstructionType: string;\n notificationSentViewIndex: number = -1;\n notificationPreview: boolean = false;\n notificationSentView: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund', 'payments'];\n\n constructor(private formBuilder: FormBuilder,\n private refundService: RefundsService,\n private notificationService: NotificationService,\n private paymentLibComponent: PaymentLibComponent,\n private OrderslistService: OrderslistService,\n private paymentViewService: PaymentViewService) { }\n\n ngOnInit() {\n\n this.resetRemissionForm([false, false, false, false], 'All');\n this.bsPaymentDcnNumber = this.paymentLibComponent.bspaymentdcn;\n this.isCallFromRefundList = this.paymentLibComponent.isCallFromRefundList;\n if(this.API_ROOT == 'api/payment-history') {\n this.isFromPayBubble = true;\n }\n if (this.paymentLibComponent.isRefundStatusView) {\n this.viewName = 'refundview';\n this.OrderslistService.getRefundView().subscribe((data) => this.refundlist = data);\n this.OrderslistService.getCCDCaseNumberforRefund.subscribe((data) => this.ccdCaseNumber = data);\n } else {\n this.viewName = 'refundstatuslist';\n this.refundService.getRefundStatusList(this.ccdCaseNumber).subscribe(\n refundList => {\n this.rejectedRefundList = refundList['refund_list'];\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g, \"\");\n };\n }\n\n\n this.refundStatusForm = this.formBuilder.group({\n amount: new FormControl('', Validators.compose([\n Validators.required,\n Validators.pattern('^[0-9]+(\\.[0-9]{1,2})?$')\n ])),\n refundReason: new FormControl('', Validators.compose([Validators.required])),\n reason: new FormControl()\n });\n\n if(this.refundlist !== undefined) {\n this.getRefundsNotification();\n this.getRefundsStatusHistoryList();\n\n if (this.LOGGEDINUSERROLES.some(i => i.includes('payments-refund-approver'))) {\n this.isProcessRefund = true;\n this.refundButtonState = this.refundlist.refund_status.name;\n return;\n }\n\n if (this.LOGGEDINUSERROLES.some(i => i.includes('payments-refund'))) {\n this.isProcessRefund = false;\n this.refundButtonState = this.refundlist.refund_status.name;\n }\n }\n \n }\n\n getRefundsStatusHistoryList() {\n if(this.refundlist !== undefined) {\n this.refundService.getRefundStatusHistory(this.refundlist.refund_reference).subscribe(\n statusHistoryList => {\n this.refundStatusHistories = statusHistoryList.status_history_dto_list;\n this.isLastUpdatedByCurrentUser = statusHistoryList.last_updated_by_current_user;\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n };\n }\n }\n\n getRefundsNotification() {\n this.notificationService.getRefundNotification(this.refundlist.refund_reference).subscribe(\n refundsNotification => {\n this.notificationList = refundsNotification['notifications'];\n }\n ),\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n }; \n }\n\n goToRefundView(refundlist: IRefundList, navigationpage: string) {\n this.OrderslistService.setRefundView(refundlist);\n this.OrderslistService.setCCDCaseNumber(this.ccdCaseNumber);\n this.paymentLibComponent.viewName = 'refundstatuslist';\n this.paymentLibComponent.isRefundStatusView = true;\n this.refundlist = refundlist;\n this.OrderslistService.setnavigationPage(navigationpage);\n }\n\n loadCaseTransactionPage() {\n this.OrderslistService.setnavigationPage('casetransactions');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isRefundStatusView = false;\n }\n\n loadRefundListPage() {\n this.OrderslistService.getnavigationPageValue().subscribe((data) => this.navigationpage = data);\n if (this.navigationpage === 'casetransactions') {\n this.loadCaseTransactionPage();\n } else {\n this.paymentLibComponent.viewName = 'refund-list';\n }\n }\n\n gotoReviewDetailsPage(event:any) {\n // event.preventDefault();\n this.errorMessage = false;\n this.paymentLibComponent.isRefundStatusView = true;\n this.ngOnInit();\n }\n\n gotoReviewAndReSubmitPage() {\n this.viewName = 'reviewandsubmitview';\n this.getTemplateInstructionType(this.paymentObj, this.refundlist.payment_reference);\n this.oldRefundReason = this.refundlist.reason;\n this.changedAmount = this.refundlist.amount;\n this.refundreason = this.refundStatusHistories.filter(data => data.status.toLowerCase() === 'update required')[0].notes;\n this.refundService.getRefundReasons().subscribe(\n refundReasons => {\n this.refundReasons = refundReasons;\n });\n }\n gotoRefundReasonPage(refundReason:string) {\n this.isRefundBtnDisabled = false;\n this.paymentLibComponent.REFUNDLIST = \"true\";\n this.paymentLibComponent.isFromRefundStatusPage = true;\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.errorMessage = false;\n this.changeRefundReason = refundReason;\n this.viewName = 'issuerefundpage1';\n }\n\n gotoAmountPage() {\n this.errorMessage = false;\n this.paymentLibComponent.REFUNDLIST = \"true\";\n this.isRefundBtnDisabled = false;\n this.ccdCaseNumber = this.paymentLibComponent.CCD_CASE_NUMBER;\n this.paymentLibComponent.isFromRefundStatusPage = true;\n if(this.refundlist.reason == 'Retrospective remission') {\n this.viewName = 'processretroremissonpage';\n } else {\n this.viewName = 'issuerefund';\n }\n }\n\n goToReviewAndSubmitView() {\n const remissionctrls = this.refundStatusForm.controls\n if (this.refundStatusForm.dirty) {\n if (remissionctrls['amount'].value == '') {\n this.resetRemissionForm([true, false, false, false], 'amount');\n }\n else if (remissionctrls['amount'].value != '' && remissionctrls['amount'].invalid) {\n this.resetRemissionForm([false, true, false, false], 'amount');\n }\n else if (remissionctrls['reason'].value == '') {\n this.resetRemissionForm([false, false, false, true], 'reason');\n } else {\n this.refundlist.reason = remissionctrls['reason'].value;\n this.viewName = 'reviewandsubmitview';\n }\n }\n\n }\n\n resetRemissionForm(val, field) {\n if (field === 'All') {\n this.isAmountEmpty = val[0];\n this.amountHasError = val[1];\n this.isRemissionLessThanFeeError = val[2];\n this.isReasonEmpty = val[3];\n } else if (field === 'amount' || field === 'All') {\n this.isAmountEmpty = val[0];\n this.amountHasError = val[1];\n this.isRemissionLessThanFeeError = val[2];\n } else if (field === 'reason' || field === 'All') {\n this.isReasonEmpty = val[3];\n }\n }\n\n selectRadioButton(key, value) {\n this.refundHasError = false;\n this.selectedRefundReason = key;\n if (key === 'Other') {\n this.refundHasError = false;\n this.refundReason = key;\n }\n }\n\n getRefundListReason(refundListReason: any) {\n if (this.paymentLibComponent.isFromRefundStatusPage && !this.paymentLibComponent.iscancelClicked) {\n if(refundListReason.reason != undefined && refundListReason.reason != null && refundListReason.reason != this.refundlist.reason){\n this.refundlist.reason = refundListReason.reason;\n this.refundlist.reason_code = refundListReason.code.split('-')[0].trim();\n this.refundlist.code = refundListReason.code;\n this.refundCode = refundListReason.code;\n }\n } else {\n this.isRefundBtnDisabled = true;\n }\n this.notificationPreview = false;\n this.viewName = 'reviewandsubmitview';\n this.paymentLibComponent.CCD_CASE_NUMBER = this.ccdCaseNumber;\n }\n\n getRefundAmount(amount: number) {\n if (this.paymentLibComponent.isFromRefundStatusPage && !this.paymentLibComponent.iscancelClicked) {\n if (amount > 0) {\n this.changedAmount = amount;\n // this.refundlist.amount = amount;\n }\n } else {\n this.isRefundBtnDisabled = true;\n }\n this.notificationPreview = false;\n this.viewName = 'reviewandsubmitview';\n this.paymentLibComponent.CCD_CASE_NUMBER = this.ccdCaseNumber;\n }\n\n getRefundFees(fees: IFee[])\n {\n this.fees = fees;\n this.refundFees = this.fees.map(obj => ({\n fee_id: obj.id,\n code: obj.code,\n version: obj.version,\n volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n refund_amount: obj.refund_amount\n }));\n }\n\n gotoReviewRefundConfirmationPage() {\n // if (this.oldRefundReason === this.refundlist.reason) {\n // this.refundCode = '';\n // }\n if (this.refundFees === undefined) {\n this.refundFees = this.refundlist['refund_fees'];\n }\n if(this.refundlist.reason == 'Retrospective remission') {\n this.refundFees[0].refund_amount = this.changedAmount;\n }\n this.refundCode = this.refundlist.code;\n const resubmitRequest = new IResubmitRefundRequest(this.refundCode, this.changedAmount, this.refundlist.contact_details, this.refundFees);\n this.refundService.patchResubmitRefund(resubmitRequest, this.refundlist.refund_reference).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n this.viewName = 'reviewrefundconfirmationpage';\n }\n },\n (error: any) => {\n this.errorMessage = error.replace(/\"/g,\"\");\n }\n );\n }\n\n gotoEditAddressDetails(note: IRefundsNotifications) {\n this.notification = note;\n this.isEditDetailsClicked = true;\n this.viewName = 'refundEditView'\n }\n getContactDetails(obj:IRefundContactDetails) {\n this.addressDetails = obj;\n this.getTemplateInstructionType(this.paymentObj,this.refundlist.payment_reference);\n this.notificationPreview = false;\n this.viewName = 'revieweditdetailsconfirmationpage';\n }\n getContactDetailsForRefundList(obj:IRefundContactDetails) {\n this.refundlist.contact_details = obj;\n this.getTemplateInstructionType(this.paymentObj,this.refundlist.payment_reference);\n this.notificationPreview = false;\n this.isEditDetailsClicked = false;\n this.isRefundBtnDisabled = false;\n this.viewName = 'reviewandsubmitview';\n }\n gotoEditDetailsPage(note?: any, view?: string) {\n if(note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.isEditDetailsClicked = true;\n this.viewName = view;\n }\n submitEditDetail() {\n this.isResendOperationSuccess = false;\n const contactDetails = this.addressDetails.notification_type === 'EMAIL' ? this.addressDetails.email :\n {\n address_line: this.addressDetails.address_line,\n city: this.addressDetails.city,\n county: this.addressDetails.county,\n country: this.addressDetails.country,\n postal_code: this.addressDetails.postal_code,\n };\n const resendRequest = new IPutNotificationRequest(contactDetails, this.addressDetails.notification_type);\n\n this.refundService.putResendOrEdit(resendRequest, this.refundlist.refund_reference, this.addressDetails.notification_type).subscribe(\n (response) => {\n this.isResendOperationSuccess = response;\n },\n (error: any) => {\n this.isResendOperationSuccess = false;\n this.errorMessage = error.replace(/\"/g,\"\");\n }\n );\n }\n putResend(notification: IRefundsNotifications) {\n this.isResendOperationSuccess = false;\n const contactDetails = notification.notification_type === 'EMAIL' ? notification.contact_details.email :\n {\n address_line :notification.contact_details.address_line,\n city: notification.contact_details.city,\n county: notification.contact_details.county,\n country: notification.contact_details.country,\n postal_code: notification.contact_details.postal_code,\n };\n const resendRequest = new IPutNotificationRequest(contactDetails, notification.notification_type);\n\n this.refundService.putResendOrEdit(resendRequest, this.refundlist.refund_reference, notification.notification_type).subscribe(\n (response) => {\n this.isResendOperationSuccess = response;\n },\n (error: any) => {\n this.isResendOperationSuccess = false;\n this.errorMessage = error.replace(/\"/g,\"\");\n }\n );\n\n }\n\n gotoRefundViewPageCancelBtnClicked(event: Event) {\n event.preventDefault();\n this.isEditDetailsClicked = false;\n this.viewName = 'refundview';\n }\n\n gotoRefundReviewAndSubmitViewPageCancelBtnClicked(event: Event) {\n event.preventDefault();\n this.isEditDetailsClicked = false;\n this.viewName = 'reviewandsubmitview';\n }\n\n goToRefundProcessComponent(refundReference: string, refundList: IRefundList) {\n this.paymentLibComponent.refundlistsource = refundList;\n this.paymentLibComponent.refundReference = refundReference;\n this.paymentLibComponent.isFromPayBubble = true;\n this.paymentLibComponent.viewName = 'process-refund';\n }\n\n getTemplateInstructionType(payment: IPayment, paymentReference: string): void {\n\n if (payment == undefined || payment == null || payment.reference != paymentReference) {\n\n this.paymentViewService.getPaymentDetails(paymentReference).subscribe(\n payment => {\n this.paymentObj = payment;\n this.paymentObj.reference = paymentReference;\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(this.paymentObj.channel, this.paymentObj.method);\n },\n (error: any) => {\n this.templateInstructionType = 'Template';\n })\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n\n showNotificationSentView(index: number): void {\n this.notificationSentViewIndex = index;\n this.notificationSentView = true;\n }\n\n hideNotificationSentView(): void {\n this.notificationSentViewIndex = -1;\n this.notificationSentView = false;\n }\n\n}\n","import { THIS_EXPR } from '@angular/compiler/src/output/output_ast';\nimport { Component, Input, OnInit, Output, EventEmitter, ChangeDetectorRef } from '@angular/core';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { IRemission } from '../../interfaces/IRemission';\nimport { IPaymentView } from '../../interfaces/IPaymentView';\nimport { IOrderReferenceFee } from '../../interfaces/IOrderReferenceFee';\nimport { IFee } from '../../interfaces/IFee';\nimport { IPaymentGroup } from '../../interfaces/IPaymentGroup';\nimport { Router } from '@angular/router';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { OrderslistService } from '../../services/orderslist.service';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { PostRefundRetroRemission } from '../../interfaces/PostRefundRetroRemission';\n\n@Component({\n selector: 'ccpay-service-request',\n templateUrl: './service-request.component.html',\n styleUrls: ['./service-request.component.scss']\n})\nexport class ServiceRequestComponent implements OnInit {\n @Input('LOGGEDINUSERROLES') LOGGEDINUSERROLES: string[];\n @Input('viewStatus') viewStatus: string;\n @Input('orderDetail') orderDetail: any[];\n @Input('orderRef') orderRef: string;\n @Input('orderStatus') orderStatus: string;\n @Input('orderParty') orderParty: string;\n @Input('orderCreated') orderCreated: Date;\n @Input('orderCCDEvent') orderCCDEvent: string;\n @Input('orderFeesTotal') orderFeesTotal: number;\n @Input('orderTotalPayments') orderTotalPayments: number;\n @Input('orderRemissionTotal') orderRemissionTotal: number;\n @Input('paymentGroupList') paymentGroupList: IPaymentGroup;\n @Input('takePayment') takePayment: boolean;\n @Input('ccdCaseNumber') ccdCaseNumber: boolean;\n @Input(\"isServiceRequest\") isServiceRequest: string;\n @Output() goToServiceRquestComponent: EventEmitter<any> = new EventEmitter();\n\n viewCompStatus;\n servicerequest: string;\n paymentType: string;\n excReference: string;\n paymentGroups: any[] = [];\n payments: IPayment[] = [];\n nonPayments: IPayment[] = [];\n allPayments: IPayment[] = [];\n remissions: IRemission[] = [];\n paymentFees: IFee[];\n fees: any;\n errorMessage: string;\n totalFees: number;\n totalPayments: number;\n totalNonOffPayments: number;\n totalRemissions: number;\n selectedOption: string;\n dcnNumber: string;\n paymentRef: string;\n isTurnOff: boolean;\n isRefundRemission: boolean = true;\n isStrategicFixEnable: boolean;\n isAddFeeBtnEnabled: boolean = true;\n isExceptionRecord: boolean = false;\n isUnprocessedRecordSelected: boolean = false;\n exceptionRecordReference: string;\n isAnyFeeGroupAvilable: boolean = true;\n isHistoricGroupAvailable: boolean = false;\n isBulkScanEnable;\n isRemissionsMatch: boolean;\n isRemoveBtnDisabled: boolean = false;\n feeId: IFee;\n clAmountDue: number = 0;\n unprocessedRecordCount: number;\n isFeeRecordsExist: boolean = false;\n isGrpOutstandingAmtPositive: boolean = false;\n totalRefundAmount: Number;\n caseType: String;\n isConfirmationBtnDisabled: boolean;\n refundReference: string;\n refundAmount: string;\n payment: IPayment;\n paymentGroup: IPaymentGroup;\n paymentView: IPaymentView;\n\n isAddRemissionEnable: boolean = false;\n orderRemissionDetails: any[] = [];\n orderLevelFees: IOrderReferenceFee[] = [];\n cpoDetails: any []= [];\n serviceRequestValue: string;\n orderAddBtnEnable: boolean;\n isFromPaymentDetailPage: boolean;\n contactDetailsObj: IRefundContactDetails\n notification: any;\n isCPODown: boolean;\n test: boolean;\n isPBA: boolean = false;\n isIssueRefunfBtnEnable: boolean = false;\n isAddRemissionBtnEnabled: boolean = false;\n isRefundRemissionBtnEnable: boolean = false;\n allowedRolesToAccessRefund = ['payments-refund-approver', 'payments-refund'];\n isFromServiceRequestPage: boolean;\n navigationpage: string;\n remissionFeeAmt: number;\n isContinueBtnDisabled: boolean = true;\n isFullyRefund: boolean;\n templateInstructionType: string;\n notificationPreview: boolean;\n\n constructor(\n private paymentLibComponent: PaymentLibComponent,\n private paymentViewService: PaymentViewService,\n private OrderslistService: OrderslistService,\n private notificationService: NotificationService,\n private cd: ChangeDetectorRef,\n private router: Router) { }\n\n ngOnInit() {\n this.isTurnOff = this.paymentLibComponent.ISTURNOFF;\n this.isServiceRequest = 'false';\n if (this.viewStatus === undefined) {\n this.viewStatus = this.paymentLibComponent.viewName;\n }\n if(this.paymentLibComponent.isFromServiceRequestPage && this.paymentLibComponent.isFromPaymentDetailPage) {\n this.OrderslistService.getorderRefs().subscribe((data) => this.orderRef = data);\n this.OrderslistService.getorderCCDEvents().subscribe((data) => this.orderCCDEvent = data);\n this.OrderslistService.getorderCreateds().subscribe((data) => this.orderCreated = data);\n this.OrderslistService.getorderDetail().subscribe((data) => this.orderDetail = data);\n this.OrderslistService.getorderPartys().subscribe((data) => this.orderParty = data);\n this.OrderslistService.getorderRemissionTotals().subscribe((data) => this.orderRemissionTotal = data);\n this.OrderslistService.getorderFeesTotals().subscribe((data) => this.orderFeesTotal = data);\n this.OrderslistService.getoorderTotalPaymentss().subscribe((data) => this.orderTotalPayments = data);\n }\n if(this.paymentLibComponent.isFromServiceRequestPage && this.paymentLibComponent.TAKEPAYMENT) {\n this.isServiceRequest = 'false';\n }\n\n }\n goToServiceRequestPage() {\n this.goToServiceRquestComponent.emit();\n }\n\n goToCaseTransationPage(event: any) {\n event.preventDefault();\n this.OrderslistService.setnavigationPage('servicerequestpage');\n this.OrderslistService.setisFromServiceRequestPage(false);\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isTakePayment = this.paymentLibComponent.TAKEPAYMENT;\n if (this.takePayment) {\n this.paymentLibComponent.isTakePayment = this.takePayment;\n }\n //this.paymentLibComponent.SERVICEREQUEST = \"true\";\n this.paymentLibComponent.isFromServiceRequestPage = false;\n if(this.isServiceRequest !== 'false') {\n this.paymentLibComponent.isFromServiceRequestPage = true;\n }\n this.paymentLibComponent.isFromRefundStatusPage = false;\n this.paymentLibComponent.viewName = 'case-transactions';\n this.resetOrderData();\n\n // Check we on XUI\n if(this.router.url.startsWith('/cases/case-details/')) {\n // Use ccpay-case-transactions component\n this.viewStatus = 'case-transactions';\n } else {\n // Reload Paybubble case-transactions page.\n let partUrl = this.paymentLibComponent.ISBSENABLE ? '&isBulkScanning=Enable' : '&isBulkScanning=Disable';\n partUrl += this.paymentLibComponent.ISTURNOFF ? '&isTurnOff=Enable' : '&isTurnOff=Disable';\n if(this.isServiceRequest === 'false') {\n partUrl += this.paymentLibComponent.TAKEPAYMENT ? '&takePayment=true' : '&takePayment=false';\n }\n partUrl += this.isStrategicFixEnable ? '&isStFixEnable=Enable' : '&isStFixEnable=Disable';\n partUrl += this.isServiceRequest !== 'false' ? '&servicerequest=true' : '&servicerequest=false';\n partUrl += `&caseType=${this.paymentLibComponent.CASETYPE}`;\n const url = `/payment-history/${this.paymentLibComponent.CCD_CASE_NUMBER}?view=case-transactions&selectedOption=${this.paymentLibComponent.SELECTED_OPTION}${partUrl}`;\n this.router.routeReuseStrategy.shouldReuseRoute = () => false;\n this.router.onSameUrlNavigation = 'reload';\n this.router.navigateByUrl(url);\n }\n }\n\n addRemission(fee: IFee) {\n if(this.chkIsAddRemissionBtnEnable(fee)) {\n this.feeId = fee;\n this.viewStatus = 'addremission';\n this.payment = this.orderDetail[0].payments[0];\n this.paymentViewService.getApportionPaymentDetails(this.orderDetail[0].payments[0].reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(this.paymentLibComponent.paymentReference));\n this.payment = this.paymentGroup.payments[0];\n\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n\n },\n (error: any) => this.errorMessage = error.replace(/\"/g,\"\")\n );\n }\n }\n\n addRefundForRemission(payment: IPayment, remission: IRemission[],fees:any) {\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n this.paymentGroup = paymentGroup;\n this.paymentGroup.payments = this.paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj.reference === payment.reference);\n this.payment = this.paymentGroup.payments[0];\n this.remissions = remission;\n this.remissionFeeAmt = fees.filter(data=>data.code === this.remissions['fee_code'])[0].net_amount;\n this.viewStatus = 'addrefundforremission';\n // const paymentAllocation = this.paymentGroup.payments[0].payment_allocation;\n // this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;\n },\n (error: any) => this.errorMessage = error\n );\n }\n cancelRemoval() {\n this.viewStatus = 'main';\n }\n\n removeFee(fee: any) {\n this.isRemoveBtnDisabled = true;\n this.paymentViewService.deleteFeeFromPaymentGroup(fee).subscribe(\n (success: any) => {\n window.location.reload();\n },\n (error: any) => {\n this.errorMessage = error;\n this.isRemoveBtnDisabled = false;\n }\n );\n }\n\n issueRefund(payment: IPayment) {\n if (payment !== null && payment !== undefined) {\n if( this.chkIsIssueRefundBtnEnable(payment)) {\n this.paymentViewService.getApportionPaymentDetails(payment.reference).subscribe(\n paymentGroup => {\n paymentGroup.payments = paymentGroup.payments.filter\n (paymentGroupObj => paymentGroupObj['reference'].includes(payment.reference));\n if(payment.over_payment > 0) {\n this.viewStatus = '';\n this.payment = payment;\n this.paymentGroupList = paymentGroup;\n this.viewCompStatus = 'overpayment';\n } else {\n this.viewStatus = 'issuerefund';\n this.viewCompStatus = '';\n this.paymentFees = paymentGroup.fees;\n this.payment = payment;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.isRefundRemission = true;\n }\n },\n (error: any) => this.errorMessage = error\n );\n }\n }\n }\n\n goToPayementView(paymentGroupReference: string, paymentReference: string, paymentMethod: string) {\n this.goToPaymentViewComponent({ paymentGroupReference, paymentReference, paymentMethod });\n }\n\n goToPaymentViewComponent(paymentGroup: any) {\n this.paymentLibComponent.paymentMethod = paymentGroup.paymentMethod;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n this.paymentLibComponent.paymentGroupReference = paymentGroup.paymentGroupReference;\n this.paymentLibComponent.paymentReference = paymentGroup.paymentReference;\n this.OrderslistService.setOrderRef(this.orderRef);\n this.OrderslistService.setorderCCDEvent(this.orderCCDEvent);\n this.OrderslistService.setorderCreated(this.orderCreated);\n this.OrderslistService.setorderDetail(this.orderDetail);\n this.OrderslistService.setorderParty(this.orderParty);\n this.OrderslistService.setorderTotalPayments(this.orderTotalPayments);\n this.OrderslistService.setorderRemissionTotal(this.orderRemissionTotal);\n this.OrderslistService.setorderFeesTotal(this.orderFeesTotal);\n this.viewStatus = 'payment-view';\n }\n\n chkIsIssueRefundBtnEnable(payment: IPayment): boolean {\n if (payment !== null && payment !== undefined) {\n return payment.issue_refund && payment.refund_enable\n } else {\n return false;\n }\n }\n\n chkIsAddRefundBtnEnable(remission: IRemission): boolean {\n if (remission !== null && remission !== undefined) {\n return remission.add_refund;\n } else {\n return false;\n }\n }\n\n chkIsAddRemissionBtnEnable(fee: IFee): boolean {\n if (fee !== null && fee !== undefined) {\n return fee.add_remission && fee.remission_enable;\n } else {\n return false\n }\n }\n resetOrderData() {\n this.OrderslistService.setOrderRef(null);\n this.OrderslistService.setorderCCDEvent(null);\n this.OrderslistService.setorderCreated(null);\n this.OrderslistService.setorderDetail(null);\n this.OrderslistService.setorderParty(null);\n this.OrderslistService.setorderTotalPayments(null);\n this.OrderslistService.setorderRemissionTotal(null);\n this.OrderslistService.setorderFeesTotal(null);\n }\n\n selectPymentOption(paymentType: string) {\n this.paymentType = paymentType;\n this.isContinueBtnDisabled = false;\n }\n goToPaymentViewComp() {\n this.viewCompStatus = '';\n this.viewStatus = 'paymentview';\n }\n continuePayment(paymentgrp: IPaymentGroup) {\n\n if (this.paymentType === 'op') {\n this.isFullyRefund = false\n this.viewStatus = '';\n this.viewCompStatus = 'overPaymentAddressCapture';\n } else if(this.paymentType === 'fp') {\n this.isFullyRefund = true\n this.paymentGroupList = paymentgrp;\n this.viewStatus = 'issuerefund';\n this.viewCompStatus = \"\";\n this.isRefundRemission = true;\n this.paymentLibComponent.isFromPaymentDetailPage = true;\n this.isFromPaymentDetailPage = true;\n this.isFromServiceRequestPage = this.paymentLibComponent.isFromServiceRequestPage;\n }\n }\n getContactDetails(obj:IRefundContactDetails) {\n this.contactDetailsObj = obj;\n this.viewStatus = '';\n this.viewCompStatus = 'overpaymentcheckandanswer';\n this.getTemplateInstructionType(this.paymentGroupList.payments[0]);\n this.notificationPreview = false;\n }\n gotoPaymentSelectPage(event: Event) {\n event.preventDefault();\n this.viewStatus = '';\n this.viewCompStatus = 'overpayment';\n }\n gotoAddressPage(note?: IRefundContactDetails) {\n if (note) {\n this.notification = { contact_details: note, notification_type: note.notification_type };\n }\n this.errorMessage = '';\n this.viewStatus = '';\n this.viewCompStatus = 'overPaymentAddressCapture';\n }\n processRefund() {\n this.isConfirmationBtnDisabled = true;\n this.errorMessage = '';\n const obj = this.paymentGroupList.fees[0];\n this.fees = [{ id: obj.id,\n code: obj.code,\n version:obj.version,\n apportion_amount: obj.apportion_amount,\n calculated_amount: obj.calculated_amount,\n updated_volume: obj.updated_volume ? obj.updated_volume : obj.volume,\n volume: obj.volume,\n refund_amount: this.getOverPaymentValue() }];\n const requestBody = new PostRefundRetroRemission(this.contactDetailsObj,this.fees, this.paymentGroupList.payments[0].reference, 'RR037',\n this.getOverPaymentValue(), 'op');\n this.paymentViewService.postRefundsReason(requestBody).subscribe(\n response => {\n if (JSON.parse(response)) {\n this.viewCompStatus = '';\n this.viewStatus = 'refundconfirmationpage';\n this.refundReference = JSON.parse(response).refund_reference;\n this.refundAmount = JSON.parse(response).refund_amount;\n }\n },\n (error: any) => {\n this.errorMessage = error;\n this.isConfirmationBtnDisabled = false;\n this.cd.detectChanges();\n })\n }\n\n getOverPaymentValue() {\n let feesOverPayment = 0;\n this.paymentGroupList.fees.forEach(fee => {\n feesOverPayment += fee.over_payment;\n });\n return feesOverPayment > 0 ? feesOverPayment : this.paymentGroupList.payments[0].over_payment;\n\n }\n\n getTemplateInstructionType(payment: IPayment): void {\n\n if (payment == undefined || payment == null) {\n this.templateInstructionType = 'Template';\n } else {\n this.templateInstructionType = this.notificationService.getNotificationInstructionType(payment.channel, payment.method);\n }\n\n }\n\n showNotificationPreview(): void {\n this.notificationPreview = true;\n }\n\n hideNotificationPreview(): void {\n this.notificationPreview = false;\n }\n}\n","export class IserviceRequestCardPayment {\n amount: string\n currency: string\n language: string\n \n constructor(amount : string) {\n this.amount = amount;\n this.currency = 'GBP';\n this.language = 'string';\n } \n}\n ","export class IserviceRequestPbaPayment {\n account_number: string;\n amount: string\n currency: string\n customer_reference: string\n organisation_name: string\n \n constructor(account_number : string, amount : string, customer_reference: string, orgName: string) {\n this.account_number = account_number;\n this.amount = amount;\n this.currency = 'GBP';\n this.customer_reference = customer_reference;\n this.organisation_name = orgName;\n } \n}\n ","import { Component, OnInit, Input} from '@angular/core';\nimport { PaymentViewService } from '../../services/payment-view/payment-view.service';\nimport { PaymentLibComponent } from '../../payment-lib.component';\nimport { IserviceRequestCardPayment } from '../../interfaces/IserviceRequestCardPayment';\nimport { IserviceRequestPbaPayment } from '../../interfaces/IserviceRequestPbaPayment';\n\nconst BS_ENABLE_FLAG = 'bulk-scan-enabling-fe';\n\n@Component({\n selector: 'ccpay-pba-payment',\n templateUrl: './pba-payment.component.html',\n styleUrls: ['./pba-payment.component.scss']\n})\nexport class PbaPaymentComponent implements OnInit {\n @Input() pbaPayOrderRef: any;\n viewStatus: string;\n pbaAccountList: string[];\n isPBAAccountHold: boolean = false;\n errorMsg: any;\n isCardPaymentSuccess: boolean = true;\n isInSufficiantFund: boolean = false;\n isPBAAccountNotExist: boolean = false;\n isPBAServerError: boolean = false;\n isGetPBAAccountSucceed: boolean = false;\n selectedPbaAccount: string = '';\n pbaAccountRef: string = '';\n isPbaAccountSelected: boolean = false;\n isCardPaymentSelected: boolean = false;\n isPBADropdownSelected: boolean = false;\n isContinueButtondisabled: boolean = true;\n isPBAAccountPaymentSuccess: boolean = false;\n pbaAccountrPaymentResult: any;\n orgName: string = '';\n\n constructor(private paymentLibComponent: PaymentLibComponent,\n private paymentViewService: PaymentViewService) {}\n\n ngOnInit() {\n this.pbaPayOrderRef = this.paymentLibComponent.pbaPayOrderRef;\n this.viewStatus = 'pba-payment';\n this.errorMsg = null;\n this.paymentViewService.getPBAaccountDetails()\n .subscribe(\n result => {\n this.isGetPBAAccountSucceed = true;\n this.orgName = result.organisationEntityResponse.name;\n this.pbaAccountList = result.organisationEntityResponse.paymentAccount;\n },\n error => {\n this.errorMsg = error;\n }\n );\n\n }\n selectpbaaccount(args) {\n if(args.currentTarget.id === 'pbaAccountNumber') {\n this.isPBADropdownSelected = true;\n this.selectedPbaAccount = args.target.value; \n }\n if(args.currentTarget.id === 'pbaAccountRef') {\n this.pbaAccountRef = args.target.value; \n }\n if(this.selectedPbaAccount !== '' && this.pbaAccountRef !== \"\") {\n this.isContinueButtondisabled = false;\n } else {\n this.isContinueButtondisabled = true;\n }\n }\n\n saveAndContinue() {\n\n if(this.isPbaAccountSelected) {\n this.isInSufficiantFund = false;\n this.isPBAAccountNotExist = false;\n this.isPBAServerError = false;\n this.isPBAAccountPaymentSuccess = false;\n this.isContinueButtondisabled = true;\n if ( this.pbaAccountList.indexOf(this.selectedPbaAccount) !== -1 ) {\n const requestBody = new IserviceRequestPbaPayment(\n this.selectedPbaAccount, this.pbaPayOrderRef.orderTotalFees, this.pbaAccountRef, this.orgName);\n\n setTimeout(() => {\n this.paymentViewService.postPBAaccountPayment(this.pbaPayOrderRef.orderRefId, requestBody)\n .subscribe(\n r => {\n try {\n this.pbaAccountrPaymentResult = JSON.parse(r);\n } catch(e) {\n this.pbaAccountrPaymentResult = r;\n }\n this.isPBAAccountPaymentSuccess = true;\n },\n e => {\n if(e.status == '402') {\n this.isInSufficiantFund = true;\n } else if(e.status == '410') {\n this.isPBAAccountNotExist = true;\n } else if(e.status == '412') {\n this.isPBAAccountHold = true;\n } else {\n this.isPBAServerError = true;\n }\n }\n );\n\n }, 5000);\n } else {\n this.isPBAServerError = true;\n }\n } else if (this.isCardPaymentSelected) {\n this.cardPayment();\n }\n\n }\n cardPayment() {\n this.isCardPaymentSuccess = true;\n const requestBody = new IserviceRequestCardPayment (\n this.pbaPayOrderRef.orderTotalFees);\n this.paymentViewService.postWays2PayCardPayment(this.pbaPayOrderRef.orderRefId, requestBody)\n .subscribe(\n result => {\n const paymentUrl = JSON.parse(result).next_url;\n window.location.href = paymentUrl;\n },\n error => {\n this.isCardPaymentSuccess = false;\n }\n );\n\n }\n selectPaymentMethod(type: string) {\n if(type === 'PBA') {\n this.isPbaAccountSelected = true;\n this.isCardPaymentSelected = false;\n this.isPBADropdownSelected = false\n this.isContinueButtondisabled = true;\n this.selectedPbaAccount = null;\n } else if (type === 'CARD') {\n this.isPbaAccountSelected = false;\n this.isCardPaymentSelected = true;\n this.isPBADropdownSelected = false\n this.isContinueButtondisabled = false;\n }\n }\n gotoCasetransationPage() {\n this.paymentLibComponent.viewName = 'case-transactions';\n this.paymentLibComponent.TAKEPAYMENT = false;\n this.paymentLibComponent.ISBSENABLE = true;\n this.paymentLibComponent.isFromServiceRequestPage = true;\n }\n}\n","import { IPayment } from './IPayment';\nimport { IRefundContactDetails } from './IRefundContactDetails';\n\nexport class NotificationPreviewRequest {\n notification_type?: string;\n payment_channel?: string;\n payment_method?: string;\n payment_reference?: string;\n personalisation?: {\n ccd_case_number?: string;\n refund_amount?: number;\n refund_reason?: string;\n refund_reference?: string;\n }\n recipient_email_address?: string;\n recipient_postal_address?: {\n address_line?: string;\n city?: string;\n county?: string;\n country?: string;\n postal_code?: string;\n }\n service_name?: string;\n\n constructor(payment: IPayment, contactDetails: IRefundContactDetails, refund_reason: string, refund_amount: number, refund_reference: string, payment_reference: string) {\n \n if (contactDetails !== undefined && contactDetails !== null) {\n this.notification_type = contactDetails.notification_type.toUpperCase();\n }\n\n if (payment !== undefined && payment !== null) {\n this.payment_reference = payment.reference;\n this.payment_method = payment.method;\n this.payment_channel = payment.channel;\n this.service_name = payment.service_name;\n } else {\n this.payment_reference = payment_reference;\n }\n\n this.personalisation = {\n ccd_case_number: (payment !== undefined && payment !== null) ? payment.ccd_case_number : '',\n refund_reason: refund_reason,\n refund_amount: refund_amount,\n refund_reference: refund_reference\n };\n\n if (this.notification_type === \"EMAIL\") {\n this.recipient_email_address = contactDetails.email;\n this.recipient_postal_address = null;\n } else if (this.notification_type === \"LETTER\") {\n this.recipient_postal_address = {\n address_line: contactDetails.address_line,\n city: contactDetails.city,\n county: contactDetails.county,\n country: contactDetails.country,\n postal_code: contactDetails.postal_code\n };\n this.recipient_email_address = null;\n }\n\n }\n}","import { Component, Input, OnInit } from '@angular/core';\nimport { IPayment } from '../../interfaces/IPayment';\nimport { INotificationPreview } from '../../interfaces/INotificationPreview';\nimport { IRefundContactDetails } from '../../interfaces/IRefundContactDetails';\nimport { NotificationPreviewRequest } from '../../interfaces/NotificationPreviewRequest';\nimport { NotificationService } from '../../services/notification/notification.service';\nimport { ErrorHandlerService } from '../../services/shared/error-handler.service';\nimport { Output, EventEmitter } from '@angular/core';\n\n@Component({\n selector: 'app-notification-preview',\n templateUrl: './notification-preview.component.html',\n styleUrls: ['./notification-preview.component.scss']\n})\nexport class NotificationPreviewComponent implements OnInit {\n @Input() payment: IPayment;\n @Input() contactDetails: IRefundContactDetails;\n @Input() refundReason: string;\n @Input() refundAmount: number;\n @Input() paymentReference: string;\n @Input() refundReference: string;\n @Input() previewJourney: string;\n @Input() notificationSent: INotificationPreview;\n\n @Output() notificationPreviewEvent = new EventEmitter<INotificationPreview>();\n\n notification: INotificationPreview;\n notificationPreviewRequest: NotificationPreviewRequest;\n today: number = Date.now();\n errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n\n constructor(private errorHandlerService: ErrorHandlerService,\n private notificationService: NotificationService) { }\n\n ngOnInit() {\n\n if (this.previewJourney != undefined && this.previewJourney != null && this.previewJourney === 'Notifications sent') {\n\n this.notification = this.notificationSent;\n\n if (this.notification != undefined && this.notification != null && this.notification.template_type === 'letter') {\n this.notification.body = this.notification.body.replace(/\\r\\n/g, '<br/>');\n }\n } else {\n\n const notficationPreviewRequestBody = new NotificationPreviewRequest(this.payment, this.contactDetails,\n this.refundReason, this.refundAmount, this.refundReference, this.paymentReference);\n\n this.notificationService.getNotificationPreview(notficationPreviewRequestBody).subscribe(\n res => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(false, false, '');\n this.notification = JSON.parse(res);\n\n if (this.notification != undefined && this.notification != null && this.notification.template_type === 'letter') {\n this.notification.body = this.notification.body.replace(/\\r\\n/g, '<br/>');\n }\n },\n (error: any) => {\n this.errorMessage = this.errorHandlerService.getServerErrorMessage(true, false, '');\n console.log(this.errorMessage);\n }\n );\n\n this.notificationPreviewEvent.emit(this.notification);\n\n }\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { HttpClientModule } from '@angular/common/http';\nimport { CommonModule } from '@angular/common';\n\nimport { PaymentListComponent } from './components/payment-list/payment-list.component';\nimport { PaymentViewComponent } from './components/payment-view/payment-view.component';\nimport { ProcessRefundComponent } from './components/process-refund/process-refund.component';\nimport { RefundListComponent } from './components/refund-list/refund-list.component';\n\nimport { CardDetailsComponent } from './components/card-details/card-details.component';\nimport { PageNotFoundComponent } from './components/page-not-found.component';\nimport { PaymentLibComponent } from './payment-lib.component';\nimport { StatusHistoryComponent } from './components/status-history/status-history.component';\nimport { ContactDetailsComponent } from './components/contact-details/contact-details.component';\nimport { PbaDetailsComponent } from './components/pba-details/pba-details.component';\nimport { LoggerService } from './services/shared/logger/logger.service';\nimport { ConsoleLoggerService } from './services/shared/logger/console-logger.service';\nimport { WebComponentHttpClient } from './services/shared/httpclient/webcomponent.http.client';\nimport { CaseTransactionsComponent } from './components/case-transactions/case-transactions.component';\nimport { FeeSummaryComponent } from './components/fee-summary/fee-summary.component';\nimport { ErrorBannerComponent } from './components/error-banner/error-banner.component';\nimport { MarkUnidentifiedPaymentComponent } from './components/mark-unidentified-payment/mark-unidentified-payment.component';\nimport { MarkUnsolicitedPaymentComponent } from './components/mark-unsolicited-payment/mark-unsolicited-payment.component';\nimport { UnprocessedPaymentsComponent } from './components/unprocessed-payments/unprocessed-payments.component';\nimport { ProcessedPaymentsComponent } from './components/processed-payments/processed-payments.component';\nimport { AllocatePaymentsComponent } from './components/allocate-payments/allocate-payments.component';\nimport { AddRemissionComponent } from './components/add-remission/add-remission.component';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { CcdHyphensPipe } from './pipes/ccd-hyphens.pipe';\nimport { CapitalizePipe } from './pipes/capitalize.pipe';\nimport { keyValuePipe } from './pipes/key-value.pipe';\nimport { SanitizeHtmlPipe } from './pipes/sanitize-html.pipe';\nimport { ReportsComponent } from './components/reports/reports.component';\nimport { XlFileService } from './services/xl-file/xl-file.service';\nimport { TableComponent } from './components/table/table.component';\nimport { MatTableModule } from '@angular/material/table';\nimport { MatPaginatorModule } from '@angular/material/paginator';\nimport { MatSortModule } from '@angular/material/sort';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\n// import { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n// import { NoopAnimationsModule } from '@angular/platform-browser/animations';\nimport { RefundStatusComponent } from './components/refund-status/refund-status.component';\nimport { ServiceRequestComponent } from './components/service-request/service-request.component';\nimport { PbaPaymentComponent } from './components/pba-payment/pba-payment.component';\nimport { NotificationPreviewComponent } from './components/notification-preview/notification-preview.component';\n\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n FormsModule,\n ReactiveFormsModule,\n MatTableModule,\n MatPaginatorModule,\n MatSortModule,\n MatFormFieldModule,\n MatInputModule,\n // BrowserAnimationsModule,\n // NoopAnimationsModule\n ],\n declarations: [\n PaymentLibComponent,\n PaymentListComponent,\n PaymentViewComponent,\n PbaPaymentComponent,\n ContactDetailsComponent,\n ProcessRefundComponent,\n RefundListComponent,\n CardDetailsComponent,\n PageNotFoundComponent,\n StatusHistoryComponent,\n MarkUnidentifiedPaymentComponent,\n MarkUnsolicitedPaymentComponent,\n UnprocessedPaymentsComponent,\n ProcessedPaymentsComponent,\n AllocatePaymentsComponent,\n PbaDetailsComponent,\n CaseTransactionsComponent,\n FeeSummaryComponent,\n AddRemissionComponent,\n CcdHyphensPipe,\n CapitalizePipe,\n keyValuePipe,\n SanitizeHtmlPipe,\n ReportsComponent,\n ErrorBannerComponent,\n TableComponent,\n RefundStatusComponent,\n ServiceRequestComponent,\n NotificationPreviewComponent\n ],\n exports: [PaymentLibComponent],\n providers: [\n { provide: LoggerService, useClass: ConsoleLoggerService },\n XlFileService,\n WebComponentHttpClient\n ]\n})\n\nexport class PaymentLibModule { }\n"],"mappings":"umDAMAA,EAAA,WAOE,SAAAA,I,QAEAA,EAAaC,UAAAC,cAAb,SAAcC,GACZC,KAAKC,SAAWF,C,EAGlBH,EAAAC,UAAAK,cAAA,WACE,OAAOF,KAAKC,Q,EAGdL,EAAqBC,UAAAM,sBAArB,SAAsBC,GACpBJ,KAAKK,kBAAoBD,C,EAG3BR,EAAAC,UAAAS,sBAAA,WACE,OAAON,KAAKK,iB,EAGdT,EAAsBC,UAAAU,uBAAtB,SAAuBC,GACrBR,KAAKS,iBAAmBD,C,EAG1BZ,EAAAC,UAAAa,qBAAA,WACE,OAAOV,KAAKS,gB,EAEdb,EAAuBC,UAAAc,wBAAvB,SAAwBC,GACtBZ,KAAKa,sBAAwBD,C,EAG/BhB,EAAAC,UAAAiB,wBAAA,WACE,OAAOd,KAAKa,qB,EAEdjB,EAAuBC,UAAAkB,wBAAvB,SAAwBC,GACtBhB,KAAKiB,qBAAuBD,C,EAE9BpB,EAAAC,UAAAqB,wBAAA,WACE,OAAOlB,KAAKiB,oB,IA3ChB,G,y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