@longvansoftware/service-js-client 1.2.1 → 1.2.3
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.
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.CANCEL_PAYMENT = void 0;
|
3
|
+
exports.CONFIRM_PAID_MANUAL = exports.CANCEL_PAYMENT = void 0;
|
4
4
|
const graphql_tag_1 = require("graphql-tag");
|
5
5
|
exports.CANCEL_PAYMENT = (0, graphql_tag_1.gql) `
|
6
6
|
mutation CancelPayment(
|
@@ -11,3 +11,15 @@ exports.CANCEL_PAYMENT = (0, graphql_tag_1.gql) `
|
|
11
11
|
cancelPayment(paymentId: $paymentId, reason: $reason, createBy: $createBy)
|
12
12
|
}
|
13
13
|
`;
|
14
|
+
exports.CONFIRM_PAID_MANUAL = (0, graphql_tag_1.gql) `
|
15
|
+
mutation ConfirmPaidManual($paymentId: String!, $confirmBy: String) {
|
16
|
+
confirmPaidManual(paymentId: $paymentId, confirmBy: $confirmBy) {
|
17
|
+
code
|
18
|
+
message
|
19
|
+
data
|
20
|
+
qrCodeUrl
|
21
|
+
deeplink
|
22
|
+
deeplinkMiniApp
|
23
|
+
}
|
24
|
+
}
|
25
|
+
`;
|
@@ -5,4 +5,5 @@ export declare class PaymentLVService extends Service {
|
|
5
5
|
paymentsByOrders(orderIds: [string]): Promise<any>;
|
6
6
|
getTransferInfo(): Promise<any>;
|
7
7
|
cancelPayment(paymentId: string, reason: string, createBy: string): Promise<any>;
|
8
|
+
confirmPaidManual(paymentId: string, confirmBy: string): Promise<any>;
|
8
9
|
}
|
@@ -74,5 +74,22 @@ class PaymentLVService extends serviceSDK_1.Service {
|
|
74
74
|
}
|
75
75
|
});
|
76
76
|
}
|
77
|
+
confirmPaidManual(paymentId, confirmBy) {
|
78
|
+
return __awaiter(this, void 0, void 0, function* () {
|
79
|
+
const mutation = mutations_1.CONFIRM_PAID_MANUAL;
|
80
|
+
const variables = {
|
81
|
+
paymentId,
|
82
|
+
confirmBy,
|
83
|
+
};
|
84
|
+
try {
|
85
|
+
const response = yield this.graphqlMutationCustomHeader(mutation, variables);
|
86
|
+
return response.confirmPaidManual;
|
87
|
+
}
|
88
|
+
catch (error) {
|
89
|
+
console.log(`Error fetching get confirmPaidManual method: ${error}`);
|
90
|
+
throw error;
|
91
|
+
}
|
92
|
+
});
|
93
|
+
}
|
77
94
|
}
|
78
95
|
exports.PaymentLVService = PaymentLVService;
|