@zeniai/client-epic-state 4.15.61 → 4.15.62

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.
@@ -9,7 +9,7 @@ const responsePayload_1 = require("../../../../../responsePayload");
9
9
  const billDetailViewReducer_1 = require("../billDetailViewReducer");
10
10
  const billDetailViewState_1 = require("../billDetailViewState");
11
11
  const retryOrRefundBillEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(billDetailViewReducer_1.retryOrRefundBill.match), (0, operators_1.mergeMap)((action) => {
12
- var _a, _b, _c, _d, _e, _f, _g;
12
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
13
13
  const { billId, actionType } = action.payload;
14
14
  const { editBillDetailViewState } = state$.value;
15
15
  const key = (0, billDetailViewState_1.getBillTransactionDetailKey)(billId);
@@ -17,24 +17,31 @@ const retryOrRefundBillEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, o
17
17
  let apiUrl = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions/${billId}`;
18
18
  let payload;
19
19
  if (actionType === 'retry') {
20
+ const paymentDetail = billDetail.billDetailLocalData.paymentDetailsSection;
20
21
  apiUrl = `${apiUrl}/payment/retry`;
21
22
  payload =
22
23
  Boolean(billDetail.billDetailLocalData
23
24
  .isCollectToAccountInfoFromVendorContact) === false
24
25
  ? {
26
+ bill_pay_provider: 'zeni',
25
27
  bill_pay_info: {
26
- to_account: ((_b = (_a = billDetail.billDetailLocalData.paymentDetailsSection) === null || _a === void 0 ? void 0 : _a.paymentType) === null || _b === void 0 ? void 0 : _b.method.includes('international')) === true
28
+ payment_date: (_a = paymentDetail === null || paymentDetail === void 0 ? void 0 : paymentDetail.paymentDate) !== null && _a !== void 0 ? _a : null,
29
+ to_account: ((_b = paymentDetail === null || paymentDetail === void 0 ? void 0 : paymentDetail.paymentType) === null || _b === void 0 ? void 0 : _b.method.includes('international')) === true
27
30
  ? {
28
- payment_instrument_id: (_d = (_c = billDetail.billDetailLocalData.paymentDetailsSection) === null || _c === void 0 ? void 0 : _c.paymentTo) !== null && _d !== void 0 ? _d : null,
31
+ payment_instrument_id: (_c = paymentDetail === null || paymentDetail === void 0 ? void 0 : paymentDetail.paymentTo) !== null && _c !== void 0 ? _c : null,
29
32
  }
30
33
  : {
31
- account_id: (_f = (_e = billDetail.billDetailLocalData.paymentDetailsSection) === null || _e === void 0 ? void 0 : _e.paymentTo) !== null && _f !== void 0 ? _f : null,
34
+ account_id: (_d = paymentDetail === null || paymentDetail === void 0 ? void 0 : paymentDetail.paymentTo) !== null && _d !== void 0 ? _d : null,
32
35
  },
36
+ from_account: {
37
+ account_id: (_f = (_e = paymentDetail === null || paymentDetail === void 0 ? void 0 : paymentDetail.withdrawFrom) === null || _e === void 0 ? void 0 : _e.id) !== null && _f !== void 0 ? _f : null,
38
+ account_type: (_h = (_g = paymentDetail === null || paymentDetail === void 0 ? void 0 : paymentDetail.withdrawFrom) === null || _g === void 0 ? void 0 : _g.accType) !== null && _h !== void 0 ? _h : null,
39
+ },
33
40
  },
34
41
  }
35
42
  : {
36
43
  bill_pay_info: {
37
- to_account_vendor_email: (_g = billDetail.billDetailLocalData.toAccountVendorEmail) !== null && _g !== void 0 ? _g : null,
44
+ to_account_vendor_email: (_j = billDetail.billDetailLocalData.toAccountVendorEmail) !== null && _j !== void 0 ? _j : null,
38
45
  is_collect_to_account_info_from_vendor_contact: billDetail.billDetailLocalData
39
46
  .isCollectToAccountInfoFromVendorContact,
40
47
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeniai/client-epic-state",
3
- "version": "4.15.61",
3
+ "version": "4.15.62",
4
4
  "description": "Shared module between Web & Mobile containing required abstractions for state management, async network communication. ",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",