@pax2pay/client 0.5.3 → 0.5.5
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/dist/model/PaymentOperationType.d.ts +4 -3
- package/dist/model/PaymentOperationType.js +15 -0
- package/dist/model/PaymentOperationType.js.map +1 -1
- package/dist/model/StatementReportRowActionType.d.ts +1 -0
- package/dist/model/StatementReportRowActionType.js +10 -0
- package/dist/model/StatementReportRowActionType.js.map +1 -1
- package/model/PaymentOperationType.ts +14 -0
- package/model/StatementReportRowActionType.ts +9 -0
- package/package.json +1 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { isly } from "isly";
|
|
2
2
|
export type PaymentOperationType = typeof PaymentOperationType.types[number];
|
|
3
3
|
export declare namespace PaymentOperationType {
|
|
4
|
-
const types: readonly ["approved authorisation", "declined authorisation", "reversal", "settlement", "refund", "faster payments", "BACS", "CHAPS", "direct debit", "SEPA instant", "SEPA", "provider internal", "SWIFT", "chargeback", "created", "limit change", "purchase", "closed", "frozen", "thawed", "approval pending", "expired", "approved", "declined", "transfer"];
|
|
5
|
-
const type: isly.Type<"frozen" | "closed" | "expired" | "approved authorisation" | "declined authorisation" | "reversal" | "settlement" | "refund" | "faster payments" | "BACS" | "CHAPS" | "direct debit" | "SEPA instant" | "SEPA" | "provider internal" | "SWIFT" | "chargeback" | "created" | "limit change" | "purchase" | "thawed" | "approval pending" | "approved" | "declined" | "transfer">;
|
|
6
|
-
const is: (value: any | ("frozen" | "closed" | "expired" | "approved authorisation" | "declined authorisation" | "reversal" | "settlement" | "refund" | "faster payments" | "BACS" | "CHAPS" | "direct debit" | "SEPA instant" | "SEPA" | "provider internal" | "SWIFT" | "chargeback" | "created" | "limit change" | "purchase" | "thawed" | "approval pending" | "approved" | "declined" | "transfer")) => value is "frozen" | "closed" | "expired" | "approved authorisation" | "declined authorisation" | "reversal" | "settlement" | "refund" | "faster payments" | "BACS" | "CHAPS" | "direct debit" | "SEPA instant" | "SEPA" | "provider internal" | "SWIFT" | "chargeback" | "created" | "limit change" | "purchase" | "thawed" | "approval pending" | "approved" | "declined" | "transfer";
|
|
4
|
+
const types: readonly ["approved authorisation", "declined authorisation", "reversal", "reversal declined", "settlement", "refund", "authorisation fee", "settlement fee", "reversal fee", "refund fee", "faster payments", "BACS", "CHAPS", "direct debit", "SEPA instant", "SEPA", "provider internal", "SWIFT", "chargeback", "created", "limit change", "purchase", "closed", "frozen", "thawed", "approval pending", "expired", "approved", "declined", "transfer"];
|
|
5
|
+
const type: isly.Type<"frozen" | "closed" | "expired" | "approved authorisation" | "declined authorisation" | "reversal" | "reversal declined" | "settlement" | "refund" | "authorisation fee" | "settlement fee" | "reversal fee" | "refund fee" | "faster payments" | "BACS" | "CHAPS" | "direct debit" | "SEPA instant" | "SEPA" | "provider internal" | "SWIFT" | "chargeback" | "created" | "limit change" | "purchase" | "thawed" | "approval pending" | "approved" | "declined" | "transfer">;
|
|
6
|
+
const is: (value: any | ("frozen" | "closed" | "expired" | "approved authorisation" | "declined authorisation" | "reversal" | "reversal declined" | "settlement" | "refund" | "authorisation fee" | "settlement fee" | "reversal fee" | "refund fee" | "faster payments" | "BACS" | "CHAPS" | "direct debit" | "SEPA instant" | "SEPA" | "provider internal" | "SWIFT" | "chargeback" | "created" | "limit change" | "purchase" | "thawed" | "approval pending" | "approved" | "declined" | "transfer")) => value is "frozen" | "closed" | "expired" | "approved authorisation" | "declined authorisation" | "reversal" | "reversal declined" | "settlement" | "refund" | "authorisation fee" | "settlement fee" | "reversal fee" | "refund fee" | "faster payments" | "BACS" | "CHAPS" | "direct debit" | "SEPA instant" | "SEPA" | "provider internal" | "SWIFT" | "chargeback" | "created" | "limit change" | "purchase" | "thawed" | "approval pending" | "approved" | "declined" | "transfer";
|
|
7
|
+
function toDisplay(value: PaymentOperationType): string;
|
|
7
8
|
}
|
|
@@ -5,8 +5,13 @@ export var PaymentOperationType;
|
|
|
5
5
|
"approved authorisation",
|
|
6
6
|
"declined authorisation",
|
|
7
7
|
"reversal",
|
|
8
|
+
"reversal declined",
|
|
8
9
|
"settlement",
|
|
9
10
|
"refund",
|
|
11
|
+
"authorisation fee",
|
|
12
|
+
"settlement fee",
|
|
13
|
+
"reversal fee",
|
|
14
|
+
"refund fee",
|
|
10
15
|
"faster payments",
|
|
11
16
|
"BACS",
|
|
12
17
|
"CHAPS",
|
|
@@ -30,5 +35,15 @@ export var PaymentOperationType;
|
|
|
30
35
|
];
|
|
31
36
|
PaymentOperationType.type = isly.string(PaymentOperationType.types);
|
|
32
37
|
PaymentOperationType.is = PaymentOperationType.type.is;
|
|
38
|
+
function toDisplay(value) {
|
|
39
|
+
if (value == "reversal fee")
|
|
40
|
+
return "fee reversal";
|
|
41
|
+
if (value == "refund fee")
|
|
42
|
+
return "fee refund";
|
|
43
|
+
if (value == "thawed")
|
|
44
|
+
return "unfrozen";
|
|
45
|
+
return value;
|
|
46
|
+
}
|
|
47
|
+
PaymentOperationType.toDisplay = toDisplay;
|
|
33
48
|
})(PaymentOperationType || (PaymentOperationType = {}));
|
|
34
49
|
//# sourceMappingURL=PaymentOperationType.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaymentOperationType.js","sourceRoot":"../","sources":["model/PaymentOperationType.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;AAI3B,MAAM,KAAW,oBAAoB,
|
|
1
|
+
{"version":3,"file":"PaymentOperationType.js","sourceRoot":"../","sources":["model/PaymentOperationType.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;AAI3B,MAAM,KAAW,oBAAoB,CA4CpC;AA5CD,WAAiB,oBAAoB;IACvB,0BAAK,GAAG;QACpB,wBAAwB;QACxB,wBAAwB;QACxB,UAAU;QACV,mBAAmB;QACnB,YAAY;QACZ,QAAQ;QACR,mBAAmB;QACnB,gBAAgB;QAChB,cAAc;QACd,YAAY;QACZ,iBAAiB;QACjB,MAAM;QACN,OAAO;QACP,cAAc;QACd,cAAc;QACd,MAAM;QACN,mBAAmB;QACnB,OAAO;QACP,YAAY;QACZ,SAAS;QACT,cAAc;QACd,UAAU;QACV,QAAQ;QACR,QAAQ;QACR,QAAQ;QACR,kBAAkB;QAClB,SAAS;QACT,UAAU;QACV,UAAU;QACV,UAAU;KACD,CAAA;IACG,yBAAI,GAAG,IAAI,CAAC,MAAM,CAAC,qBAAA,KAAK,CAAC,CAAA;IACzB,uBAAE,GAAG,qBAAA,IAAI,CAAC,EAAE,CAAA;IACzB,SAAgB,SAAS,CAAC,KAA2B;QACpD,IAAI,KAAK,IAAI,cAAc;YAC1B,OAAO,cAAc,CAAA;QACtB,IAAI,KAAK,IAAI,YAAY;YACxB,OAAO,YAAY,CAAA;QACpB,IAAI,KAAK,IAAI,QAAQ;YACpB,OAAO,UAAU,CAAA;QAClB,OAAO,KAAK,CAAA;IACb,CAAC;IARe,8BAAS,YAQxB,CAAA;AACF,CAAC,EA5CgB,oBAAoB,KAApB,oBAAoB,QA4CpC"}
|
|
@@ -2,5 +2,6 @@ declare const statementReportRowActionType: readonly ["AUTHORISATION", "SETTLEME
|
|
|
2
2
|
export type StatementReportRowActionType = typeof statementReportRowActionType[number];
|
|
3
3
|
export declare namespace StatementReportRowActionType {
|
|
4
4
|
function is(value: unknown): value is StatementReportRowActionType;
|
|
5
|
+
function toDisplay(value: StatementReportRowActionType): string;
|
|
5
6
|
}
|
|
6
7
|
export {};
|
|
@@ -19,5 +19,15 @@ export var StatementReportRowActionType;
|
|
|
19
19
|
return typeof value == "string" && statementReportRowActionType.includes(value);
|
|
20
20
|
}
|
|
21
21
|
StatementReportRowActionType.is = is;
|
|
22
|
+
function toDisplay(value) {
|
|
23
|
+
if (value == "REFUND_FEE")
|
|
24
|
+
return "FEE_REFUND";
|
|
25
|
+
if (value == "REVERSAL_FEE")
|
|
26
|
+
return "FEE_REVERSAL";
|
|
27
|
+
if (value == "SCHEDULED_CARD_AMENDMENT")
|
|
28
|
+
return "SCHEDULED_CARD";
|
|
29
|
+
return value;
|
|
30
|
+
}
|
|
31
|
+
StatementReportRowActionType.toDisplay = toDisplay;
|
|
22
32
|
})(StatementReportRowActionType || (StatementReportRowActionType = {}));
|
|
23
33
|
//# sourceMappingURL=StatementReportRowActionType.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatementReportRowActionType.js","sourceRoot":"../","sources":["model/StatementReportRowActionType.ts"],"names":[],"mappings":"AAAA,MAAM,4BAA4B,GAAG;IACpC,eAAe;IACf,YAAY;IACZ,UAAU;IACV,QAAQ;IACR,mBAAmB;IACnB,gBAAgB;IAChB,cAAc;IACd,YAAY;IACZ,aAAa;IACb,cAAc;IACd,aAAa;IACb,iBAAiB;IACjB,0BAA0B;CACjB,CAAA;AAGV,MAAM,KAAW,4BAA4B,
|
|
1
|
+
{"version":3,"file":"StatementReportRowActionType.js","sourceRoot":"../","sources":["model/StatementReportRowActionType.ts"],"names":[],"mappings":"AAAA,MAAM,4BAA4B,GAAG;IACpC,eAAe;IACf,YAAY;IACZ,UAAU;IACV,QAAQ;IACR,mBAAmB;IACnB,gBAAgB;IAChB,cAAc;IACd,YAAY;IACZ,aAAa;IACb,cAAc;IACd,aAAa;IACb,iBAAiB;IACjB,0BAA0B;CACjB,CAAA;AAGV,MAAM,KAAW,4BAA4B,CAa5C;AAbD,WAAiB,4BAA4B;IAC5C,SAAgB,EAAE,CAAC,KAAc;QAChC,OAAO,OAAO,KAAK,IAAI,QAAQ,IAAI,4BAA4B,CAAC,QAAQ,CAAC,KAAqC,CAAC,CAAA;IAChH,CAAC;IAFe,+BAAE,KAEjB,CAAA;IACD,SAAgB,SAAS,CAAC,KAAmC;QAC5D,IAAI,KAAK,IAAI,YAAY;YACxB,OAAO,YAAY,CAAA;QACpB,IAAI,KAAK,IAAI,cAAc;YAC1B,OAAO,cAAc,CAAA;QACtB,IAAI,KAAK,IAAI,0BAA0B;YACtC,OAAO,gBAAgB,CAAA;QACxB,OAAO,KAAK,CAAA;IACb,CAAC;IARe,sCAAS,YAQxB,CAAA;AACF,CAAC,EAbgB,4BAA4B,KAA5B,4BAA4B,QAa5C"}
|
|
@@ -7,8 +7,13 @@ export namespace PaymentOperationType {
|
|
|
7
7
|
"approved authorisation",
|
|
8
8
|
"declined authorisation",
|
|
9
9
|
"reversal",
|
|
10
|
+
"reversal declined",
|
|
10
11
|
"settlement",
|
|
11
12
|
"refund",
|
|
13
|
+
"authorisation fee",
|
|
14
|
+
"settlement fee",
|
|
15
|
+
"reversal fee",
|
|
16
|
+
"refund fee",
|
|
12
17
|
"faster payments",
|
|
13
18
|
"BACS",
|
|
14
19
|
"CHAPS",
|
|
@@ -32,4 +37,13 @@ export namespace PaymentOperationType {
|
|
|
32
37
|
] as const
|
|
33
38
|
export const type = isly.string(types)
|
|
34
39
|
export const is = type.is
|
|
40
|
+
export function toDisplay(value: PaymentOperationType): string {
|
|
41
|
+
if (value == "reversal fee")
|
|
42
|
+
return "fee reversal"
|
|
43
|
+
if (value == "refund fee")
|
|
44
|
+
return "fee refund"
|
|
45
|
+
if (value == "thawed")
|
|
46
|
+
return "unfrozen"
|
|
47
|
+
return value
|
|
48
|
+
}
|
|
35
49
|
}
|
|
@@ -19,4 +19,13 @@ export namespace StatementReportRowActionType {
|
|
|
19
19
|
export function is(value: unknown): value is StatementReportRowActionType {
|
|
20
20
|
return typeof value == "string" && statementReportRowActionType.includes(value as StatementReportRowActionType)
|
|
21
21
|
}
|
|
22
|
+
export function toDisplay(value: StatementReportRowActionType): string {
|
|
23
|
+
if (value == "REFUND_FEE")
|
|
24
|
+
return "FEE_REFUND"
|
|
25
|
+
if (value == "REVERSAL_FEE")
|
|
26
|
+
return "FEE_REVERSAL"
|
|
27
|
+
if (value == "SCHEDULED_CARD_AMENDMENT")
|
|
28
|
+
return "SCHEDULED_CARD"
|
|
29
|
+
return value
|
|
30
|
+
}
|
|
22
31
|
}
|