@hmcts/ccpay-web-component 5.0.1-beta94 → 5.0.1-beta98
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 +80 -35
- 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/add-remission/add-remission.component.js +87 -25
- package/esm5/lib/components/add-remission/add-remission.component.js +91 -33
- package/fesm2015/hmcts-ccpay-web-component.js +78 -24
- package/fesm2015/hmcts-ccpay-web-component.js.map +1 -1
- package/fesm5/hmcts-ccpay-web-component.js +82 -32
- package/fesm5/hmcts-ccpay-web-component.js.map +1 -1
- package/hmcts-ccpay-web-component.metadata.json +1 -1
- package/lib/components/add-remission/add-remission.component.d.ts +6 -0
- package/package.json +1 -1
|
@@ -6665,25 +6665,51 @@
|
|
|
6665
6665
|
/** @type {?} */
|
|
6666
6666
|
var remissionctrls = this.remissionForm.controls;
|
|
6667
6667
|
remissionctrls['refundDDReason'].setValue('Select a different reason', { onlySelf: true });
|
|
6668
|
-
if (this.
|
|
6669
|
-
/**
|
|
6670
|
-
|
|
6671
|
-
|
|
6672
|
-
|
|
6673
|
-
|
|
6674
|
-
|
|
6675
|
-
|
|
6676
|
-
|
|
6677
|
-
|
|
6678
|
-
|
|
6679
|
-
|
|
6680
|
-
|
|
6681
|
-
|
|
6682
|
-
|
|
6683
|
-
|
|
6668
|
+
if (this.isFromServiceRequestPage) {
|
|
6669
|
+
this.paymentViewService.getApportionPaymentDetails(this.paymentLibComponent.paymentReference).subscribe(( /**
|
|
6670
|
+
* @param {?} paymentGroup
|
|
6671
|
+
* @return {?}
|
|
6672
|
+
*/function (paymentGroup) {
|
|
6673
|
+
/** @type {?} */
|
|
6674
|
+
var fees = [];
|
|
6675
|
+
paymentGroup.fees.forEach(( /**
|
|
6676
|
+
* @param {?} fee
|
|
6677
|
+
* @return {?}
|
|
6678
|
+
*/function (fee) {
|
|
6679
|
+
_this.isRemissionsMatch = false;
|
|
6680
|
+
paymentGroup.remissions.forEach(( /**
|
|
6681
|
+
* @param {?} rem
|
|
6682
|
+
* @return {?}
|
|
6683
|
+
*/function (rem) {
|
|
6684
|
+
if (rem.fee_code === fee.code) {
|
|
6685
|
+
_this.isRemissionsMatch = true;
|
|
6686
|
+
fee['remissions'] = rem;
|
|
6687
|
+
fees.push(fee);
|
|
6688
|
+
}
|
|
6689
|
+
}));
|
|
6690
|
+
if (!_this.isRemissionsMatch) {
|
|
6691
|
+
fees.push(fee);
|
|
6692
|
+
}
|
|
6684
6693
|
}));
|
|
6685
|
-
|
|
6686
|
-
|
|
6694
|
+
paymentGroup.fees = fees;
|
|
6695
|
+
_this.paymentFees = fees;
|
|
6696
|
+
_this.fees = fees;
|
|
6697
|
+
_this.paymentGroup = paymentGroup;
|
|
6698
|
+
_this.paymentGroup.payments = _this.paymentGroup.payments.filter(( /**
|
|
6699
|
+
* @param {?} paymentGroupObj
|
|
6700
|
+
* @return {?}
|
|
6701
|
+
*/function (paymentGroupObj) { return paymentGroupObj['reference'].includes(_this.paymentLibComponent.paymentReference); }));
|
|
6702
|
+
/** @type {?} */
|
|
6703
|
+
var paymentAllocation = _this.paymentGroup.payments[0].payment_allocation;
|
|
6704
|
+
_this.isStatusAllocated = paymentAllocation.length > 0 && paymentAllocation[0].allocation_status === 'Allocated' || paymentAllocation.length === 0;
|
|
6705
|
+
_this.refundFeesList();
|
|
6706
|
+
}), ( /**
|
|
6707
|
+
* @param {?} error
|
|
6708
|
+
* @return {?}
|
|
6709
|
+
*/function (error) { return _this.errorMessage = error; }));
|
|
6710
|
+
}
|
|
6711
|
+
if (this.fees && this.viewCompStatus === 'issuerefund') {
|
|
6712
|
+
this.refundFeesList();
|
|
6687
6713
|
}
|
|
6688
6714
|
if (this.viewCompStatus === '') {
|
|
6689
6715
|
this.viewStatus = 'main';
|
|
@@ -6722,13 +6748,38 @@
|
|
|
6722
6748
|
this.paymentReference = this.orderDetail[0].payments[0].reference;
|
|
6723
6749
|
}
|
|
6724
6750
|
};
|
|
6751
|
+
/**
|
|
6752
|
+
* @return {?}
|
|
6753
|
+
*/
|
|
6754
|
+
AddRemissionComponent.prototype.refundFeesList = /**
|
|
6755
|
+
* @return {?}
|
|
6756
|
+
*/
|
|
6757
|
+
function () {
|
|
6758
|
+
/** @type {?} */
|
|
6759
|
+
var creds = ( /** @type {?} */(this.remissionForm.controls.feesList));
|
|
6760
|
+
for (var i = 0; i < this.fees.length; i++) {
|
|
6761
|
+
creds.push(this.formBuilder.group({
|
|
6762
|
+
id: this.fees[i].id,
|
|
6763
|
+
code: this.fees[i].code,
|
|
6764
|
+
volume: this.fees[i].volume,
|
|
6765
|
+
calculated_amount: this.fees[i].calculated_amount,
|
|
6766
|
+
apportion_amount: this.fees[i].apportion_amount,
|
|
6767
|
+
ccd_case_number: this.fees[i].ccd_case_number,
|
|
6768
|
+
description: this.fees[i].description,
|
|
6769
|
+
net_amount: this.fees[i].net_amount,
|
|
6770
|
+
version: this.fees[i].version,
|
|
6771
|
+
amounttorefund: [''],
|
|
6772
|
+
selected: ['']
|
|
6773
|
+
}));
|
|
6774
|
+
}
|
|
6775
|
+
this.cd.detectChanges();
|
|
6776
|
+
};
|
|
6725
6777
|
Object.defineProperty(AddRemissionComponent.prototype, "feesList", {
|
|
6726
6778
|
get: /**
|
|
6727
6779
|
* @return {?}
|
|
6728
6780
|
*/ function () {
|
|
6729
6781
|
/** @type {?} */
|
|
6730
6782
|
var dd = ( /** @type {?} */(this.remissionForm.get('feesList')));
|
|
6731
|
-
console.log(this.remissionForm.get('feesList'));
|
|
6732
6783
|
return ( /** @type {?} */(this.remissionForm.get('feesList')));
|
|
6733
6784
|
},
|
|
6734
6785
|
enumerable: true,
|
|
@@ -6758,34 +6809,28 @@
|
|
|
6758
6809
|
* @return {?}
|
|
6759
6810
|
*/function (item) { return item.get('selected').value === true; }));
|
|
6760
6811
|
};
|
|
6761
|
-
// validateRow(i){
|
|
6762
|
-
// return this.remissionForm.get('feesList').parent.controls['feesList'].controls[1].value['selected']
|
|
6763
|
-
// }
|
|
6764
|
-
// validateRow(i){
|
|
6765
|
-
// return this.remissionForm.get('feesList').parent.controls['feesList'].controls[1].value['selected']
|
|
6766
|
-
// }
|
|
6767
6812
|
/**
|
|
6768
6813
|
* @param {?} v1
|
|
6769
6814
|
* @return {?}
|
|
6770
6815
|
*/
|
|
6771
|
-
AddRemissionComponent.prototype.check_en =
|
|
6772
|
-
|
|
6773
|
-
|
|
6774
|
-
|
|
6775
|
-
/**
|
|
6776
|
-
* @param {?} v1
|
|
6777
|
-
* @return {?}
|
|
6778
|
-
*/
|
|
6816
|
+
AddRemissionComponent.prototype.check_en = /**
|
|
6817
|
+
* @param {?} v1
|
|
6818
|
+
* @return {?}
|
|
6819
|
+
*/
|
|
6779
6820
|
function (v1) {
|
|
6780
6821
|
/** @type {?} */
|
|
6781
6822
|
var ele = ( /** @type {?} */(document.getElementById(v1)));
|
|
6782
6823
|
if (ele.checked) {
|
|
6783
6824
|
document.getElementById('feeAmount_' + v1).removeAttribute("disabled");
|
|
6784
|
-
document.getElementById('feeVolumeUpdated_' + v1)
|
|
6825
|
+
if (document.getElementById('feeVolumeUpdated_' + v1) !== null) {
|
|
6826
|
+
document.getElementById('feeVolumeUpdated_' + v1).removeAttribute("disabled");
|
|
6827
|
+
}
|
|
6785
6828
|
}
|
|
6786
6829
|
else {
|
|
6787
6830
|
document.getElementById('feeAmount_' + v1).setAttribute("disabled", "true");
|
|
6788
|
-
document.getElementById('feeVolumeUpdated_' + v1)
|
|
6831
|
+
if (document.getElementById('feeVolumeUpdated_' + v1) !== null) {
|
|
6832
|
+
document.getElementById('feeVolumeUpdated_' + v1).removeAttribute("disabled");
|
|
6833
|
+
}
|
|
6789
6834
|
}
|
|
6790
6835
|
};
|
|
6791
6836
|
/**
|