@longvansoftware/storefront-js-client 2.2.7-beta.2 → 2.2.8
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/README.md +93 -93
- package/dist/src/graphql/auth/mutations.d.ts +0 -3
- package/dist/src/graphql/auth/mutations.js +89 -134
- package/dist/src/graphql/auth/queries.d.ts +0 -3
- package/dist/src/graphql/auth/queries.js +21 -56
- package/dist/src/graphql/campaign/queries.js +248 -248
- package/dist/src/graphql/cloud/mutations.js +103 -103
- package/dist/src/graphql/cloud/queries.js +112 -112
- package/dist/src/graphql/computing/mutations.js +96 -96
- package/dist/src/graphql/computing/queries.js +41 -41
- package/dist/src/graphql/crm/mutations.js +799 -799
- package/dist/src/graphql/crm/queries.js +615 -615
- package/dist/src/graphql/payment/mutations.js +39 -39
- package/dist/src/graphql/payment/queries.js +57 -57
- package/dist/src/graphql/paymentV2/mutations.d.ts +1 -0
- package/dist/src/graphql/paymentV2/mutations.js +18 -5
- package/dist/src/graphql/paymentV2/queries.d.ts +2 -0
- package/dist/src/graphql/paymentV2/queries.js +160 -60
- package/dist/src/graphql/product/queries.js +431 -431
- package/dist/src/graphql/service/mutations.js +304 -304
- package/dist/src/graphql/service/queries.js +131 -131
- package/dist/src/graphql/user/mutations.js +110 -110
- package/dist/src/graphql/user/queries.js +279 -281
- package/dist/src/lib/auth/index.d.ts +0 -16
- package/dist/src/lib/auth/index.js +0 -181
- package/dist/src/lib/paymentV2/index.d.ts +3 -0
- package/dist/src/lib/paymentV2/index.js +46 -0
- package/dist/src/lib/serviceSDK.js +12 -12
- package/dist/src/lib/shareZalo/index.d.ts +5 -0
- package/dist/src/lib/shareZalo/index.js +32 -0
- package/dist/src/lib/user/index.js +0 -1
- package/package.json +43 -43
|
@@ -2,43 +2,43 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CREATE_PAYMENT_ORDER_MUTATION = void 0;
|
|
4
4
|
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
-
exports.CREATE_PAYMENT_ORDER_MUTATION = (0, graphql_tag_1.gql) `
|
|
6
|
-
mutation CreatePaymentOrder(
|
|
7
|
-
$orgId: String!
|
|
8
|
-
$orderId: String!
|
|
9
|
-
$paymentMethod: String!
|
|
10
|
-
$storeId: String!
|
|
11
|
-
$source: String!
|
|
12
|
-
$appliedAmount: BigDecimal
|
|
13
|
-
$payDate: String!
|
|
14
|
-
$returnUrl: String
|
|
15
|
-
$paymentType: String!
|
|
16
|
-
$createBy: String!
|
|
17
|
-
$paymentInfo: String
|
|
18
|
-
$attributes: JSON
|
|
19
|
-
) {
|
|
20
|
-
createPaymentOrder(
|
|
21
|
-
orgId: $orgId
|
|
22
|
-
orderId: $orderId
|
|
23
|
-
paymentMethod: $paymentMethod
|
|
24
|
-
storeId: $storeId
|
|
25
|
-
source: $source
|
|
26
|
-
appliedAmount: $appliedAmount
|
|
27
|
-
payDate: $payDate
|
|
28
|
-
returnUrl: $returnUrl
|
|
29
|
-
paymentType: $paymentType
|
|
30
|
-
createBy: $createBy
|
|
31
|
-
paymentInfo: $paymentInfo
|
|
32
|
-
attributes: $attributes
|
|
33
|
-
) {
|
|
34
|
-
code
|
|
35
|
-
message
|
|
36
|
-
data
|
|
37
|
-
qrCodeUrl
|
|
38
|
-
deeplink
|
|
39
|
-
deeplinkMiniApp
|
|
40
|
-
invoiceId
|
|
41
|
-
orderId
|
|
42
|
-
}
|
|
43
|
-
}
|
|
5
|
+
exports.CREATE_PAYMENT_ORDER_MUTATION = (0, graphql_tag_1.gql) `
|
|
6
|
+
mutation CreatePaymentOrder(
|
|
7
|
+
$orgId: String!
|
|
8
|
+
$orderId: String!
|
|
9
|
+
$paymentMethod: String!
|
|
10
|
+
$storeId: String!
|
|
11
|
+
$source: String!
|
|
12
|
+
$appliedAmount: BigDecimal
|
|
13
|
+
$payDate: String!
|
|
14
|
+
$returnUrl: String
|
|
15
|
+
$paymentType: String!
|
|
16
|
+
$createBy: String!
|
|
17
|
+
$paymentInfo: String
|
|
18
|
+
$attributes: JSON
|
|
19
|
+
) {
|
|
20
|
+
createPaymentOrder(
|
|
21
|
+
orgId: $orgId
|
|
22
|
+
orderId: $orderId
|
|
23
|
+
paymentMethod: $paymentMethod
|
|
24
|
+
storeId: $storeId
|
|
25
|
+
source: $source
|
|
26
|
+
appliedAmount: $appliedAmount
|
|
27
|
+
payDate: $payDate
|
|
28
|
+
returnUrl: $returnUrl
|
|
29
|
+
paymentType: $paymentType
|
|
30
|
+
createBy: $createBy
|
|
31
|
+
paymentInfo: $paymentInfo
|
|
32
|
+
attributes: $attributes
|
|
33
|
+
) {
|
|
34
|
+
code
|
|
35
|
+
message
|
|
36
|
+
data
|
|
37
|
+
qrCodeUrl
|
|
38
|
+
deeplink
|
|
39
|
+
deeplinkMiniApp
|
|
40
|
+
invoiceId
|
|
41
|
+
orderId
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
44
|
`;
|
|
@@ -2,64 +2,64 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.GET_INVOICE_DETAIL = exports.GET_PAYMENT_METHOD_OF_STORE_CHANNEL = exports.GEN_QR_PAYMENT = exports.GET_PAYMENT_METHOD = void 0;
|
|
4
4
|
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
-
exports.GET_PAYMENT_METHOD = (0, graphql_tag_1.gql) `
|
|
6
|
-
query GetPaymentMethod($orgId: String!, $storeChannelId: String) {
|
|
7
|
-
getPaymentMethod(orgId: $orgId, storeChannelId: $storeChannelId) {
|
|
8
|
-
id
|
|
9
|
-
code
|
|
10
|
-
name
|
|
11
|
-
}
|
|
12
|
-
}
|
|
5
|
+
exports.GET_PAYMENT_METHOD = (0, graphql_tag_1.gql) `
|
|
6
|
+
query GetPaymentMethod($orgId: String!, $storeChannelId: String) {
|
|
7
|
+
getPaymentMethod(orgId: $orgId, storeChannelId: $storeChannelId) {
|
|
8
|
+
id
|
|
9
|
+
code
|
|
10
|
+
name
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
13
|
`;
|
|
14
|
-
exports.GEN_QR_PAYMENT = (0, graphql_tag_1.gql) `
|
|
15
|
-
query GenQRPayment(
|
|
16
|
-
$orgId: String!
|
|
17
|
-
$orderId: String!
|
|
18
|
-
$storeId: String!
|
|
19
|
-
$totalAmount: BigDecimal
|
|
20
|
-
) {
|
|
21
|
-
genQRPayment(
|
|
22
|
-
orgId: $orgId
|
|
23
|
-
orderId: $orderId
|
|
24
|
-
storeId: $storeId
|
|
25
|
-
totalAmount: $totalAmount
|
|
26
|
-
)
|
|
27
|
-
}
|
|
14
|
+
exports.GEN_QR_PAYMENT = (0, graphql_tag_1.gql) `
|
|
15
|
+
query GenQRPayment(
|
|
16
|
+
$orgId: String!
|
|
17
|
+
$orderId: String!
|
|
18
|
+
$storeId: String!
|
|
19
|
+
$totalAmount: BigDecimal
|
|
20
|
+
) {
|
|
21
|
+
genQRPayment(
|
|
22
|
+
orgId: $orgId
|
|
23
|
+
orderId: $orderId
|
|
24
|
+
storeId: $storeId
|
|
25
|
+
totalAmount: $totalAmount
|
|
26
|
+
)
|
|
27
|
+
}
|
|
28
28
|
`;
|
|
29
|
-
exports.GET_PAYMENT_METHOD_OF_STORE_CHANNEL = (0, graphql_tag_1.gql) `
|
|
30
|
-
query GetPaymentMethodOfStoreChannel(
|
|
31
|
-
$orgId: String!
|
|
32
|
-
$storeChannelId: String!
|
|
33
|
-
) {
|
|
34
|
-
getPaymentMethodOfStoreChannel(
|
|
35
|
-
orgId: $orgId
|
|
36
|
-
storeChannelId: $storeChannelId
|
|
37
|
-
) {
|
|
38
|
-
id
|
|
39
|
-
code
|
|
40
|
-
name
|
|
41
|
-
image
|
|
42
|
-
description
|
|
43
|
-
}
|
|
44
|
-
}
|
|
29
|
+
exports.GET_PAYMENT_METHOD_OF_STORE_CHANNEL = (0, graphql_tag_1.gql) `
|
|
30
|
+
query GetPaymentMethodOfStoreChannel(
|
|
31
|
+
$orgId: String!
|
|
32
|
+
$storeChannelId: String!
|
|
33
|
+
) {
|
|
34
|
+
getPaymentMethodOfStoreChannel(
|
|
35
|
+
orgId: $orgId
|
|
36
|
+
storeChannelId: $storeChannelId
|
|
37
|
+
) {
|
|
38
|
+
id
|
|
39
|
+
code
|
|
40
|
+
name
|
|
41
|
+
image
|
|
42
|
+
description
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
45
|
`;
|
|
46
|
-
exports.GET_INVOICE_DETAIL = (0, graphql_tag_1.gql) `
|
|
47
|
-
query GetInvoiceDetail($invoiceId: String!) {
|
|
48
|
-
getInvoiceDetail(invoiceId: $invoiceId) {
|
|
49
|
-
id
|
|
50
|
-
orderId
|
|
51
|
-
type
|
|
52
|
-
partyIdFrom
|
|
53
|
-
partyIdTo
|
|
54
|
-
status
|
|
55
|
-
invoiceDate
|
|
56
|
-
invoiceDueDate
|
|
57
|
-
createdBy
|
|
58
|
-
createdStamp
|
|
59
|
-
paymentId
|
|
60
|
-
originalTotalPrice
|
|
61
|
-
totalVAT
|
|
62
|
-
appliedAmount
|
|
63
|
-
}
|
|
64
|
-
}
|
|
46
|
+
exports.GET_INVOICE_DETAIL = (0, graphql_tag_1.gql) `
|
|
47
|
+
query GetInvoiceDetail($invoiceId: String!) {
|
|
48
|
+
getInvoiceDetail(invoiceId: $invoiceId) {
|
|
49
|
+
id
|
|
50
|
+
orderId
|
|
51
|
+
type
|
|
52
|
+
partyIdFrom
|
|
53
|
+
partyIdTo
|
|
54
|
+
status
|
|
55
|
+
invoiceDate
|
|
56
|
+
invoiceDueDate
|
|
57
|
+
createdBy
|
|
58
|
+
createdStamp
|
|
59
|
+
paymentId
|
|
60
|
+
originalTotalPrice
|
|
61
|
+
totalVAT
|
|
62
|
+
appliedAmount
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
65
|
`;
|
|
@@ -1,9 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.CANCEL_PAYMENT = void 0;
|
|
3
|
+
exports.CONFIRM_TO_GATEWAY = exports.CANCEL_PAYMENT = void 0;
|
|
4
4
|
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
-
exports.CANCEL_PAYMENT = (0, graphql_tag_1.gql) `
|
|
6
|
-
mutation CancelPayment($paymentId: String!, $reason: String!) {
|
|
7
|
-
cancelPayment(paymentId: $paymentId, reason: $reason)
|
|
8
|
-
}
|
|
5
|
+
exports.CANCEL_PAYMENT = (0, graphql_tag_1.gql) `
|
|
6
|
+
mutation CancelPayment($paymentId: String!, $reason: String!) {
|
|
7
|
+
cancelPayment(paymentId: $paymentId, reason: $reason)
|
|
8
|
+
}
|
|
9
|
+
`;
|
|
10
|
+
exports.CONFIRM_TO_GATEWAY = (0, graphql_tag_1.gql) `
|
|
11
|
+
mutation ConfirmToGateWay($paymentId: String!, $methodCode: String) {
|
|
12
|
+
confirmToGateway(paymentId: $paymentId, methodCode: $methodCode) {
|
|
13
|
+
code
|
|
14
|
+
message
|
|
15
|
+
data
|
|
16
|
+
qrCodeUrl
|
|
17
|
+
deeplink
|
|
18
|
+
deeplinkMiniApp
|
|
19
|
+
paymentId
|
|
20
|
+
}
|
|
21
|
+
}
|
|
9
22
|
`;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
export declare const PAYMENTS_BY_ORDERS: import("graphql").DocumentNode;
|
|
2
2
|
export declare const PAYMENT_METHODS: import("graphql").DocumentNode;
|
|
3
3
|
export declare const GET_PAYMENT_METHOD_TYPES: import("graphql").DocumentNode;
|
|
4
|
+
export declare const PAYMENT_INFO: import("graphql").DocumentNode;
|
|
5
|
+
export declare const PAYMENT_STATUS: import("graphql").DocumentNode;
|
|
@@ -1,66 +1,166 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.GET_PAYMENT_METHOD_TYPES = exports.PAYMENT_METHODS = exports.PAYMENTS_BY_ORDERS = void 0;
|
|
3
|
+
exports.PAYMENT_STATUS = exports.PAYMENT_INFO = exports.GET_PAYMENT_METHOD_TYPES = exports.PAYMENT_METHODS = exports.PAYMENTS_BY_ORDERS = void 0;
|
|
4
4
|
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
-
exports.PAYMENTS_BY_ORDERS = (0, graphql_tag_1.gql) `
|
|
6
|
-
query PaymentsByOrders($orderIds: [String!]!) {
|
|
7
|
-
paymentsByOrders(orderIds: $orderIds) {
|
|
8
|
-
methodCode
|
|
9
|
-
methodTypeCode
|
|
10
|
-
gatewayConfigId
|
|
11
|
-
partnerCode
|
|
12
|
-
totalAmount
|
|
13
|
-
fee
|
|
14
|
-
discountAmount
|
|
15
|
-
payDate
|
|
16
|
-
payType
|
|
17
|
-
transactionDate
|
|
18
|
-
orderId
|
|
19
|
-
paymentId
|
|
20
|
-
invoiceId
|
|
21
|
-
orderInfo
|
|
22
|
-
orderType
|
|
23
|
-
locale
|
|
24
|
-
merchantIp
|
|
25
|
-
extraData
|
|
26
|
-
storeID
|
|
27
|
-
bankCode
|
|
28
|
-
appUser
|
|
29
|
-
phone
|
|
30
|
-
email
|
|
31
|
-
address
|
|
32
|
-
statusCode
|
|
33
|
-
statusDescription
|
|
34
|
-
transactionId
|
|
35
|
-
createBy
|
|
36
|
-
methodDescription
|
|
37
|
-
methodMapping
|
|
38
|
-
baseMethodCode
|
|
39
|
-
confirmPaidBy
|
|
40
|
-
confirmPaidDate
|
|
41
|
-
qrCode
|
|
42
|
-
payUrl
|
|
43
|
-
}
|
|
44
|
-
}
|
|
5
|
+
exports.PAYMENTS_BY_ORDERS = (0, graphql_tag_1.gql) `
|
|
6
|
+
query PaymentsByOrders($orderIds: [String!]!) {
|
|
7
|
+
paymentsByOrders(orderIds: $orderIds) {
|
|
8
|
+
methodCode
|
|
9
|
+
methodTypeCode
|
|
10
|
+
gatewayConfigId
|
|
11
|
+
partnerCode
|
|
12
|
+
totalAmount
|
|
13
|
+
fee
|
|
14
|
+
discountAmount
|
|
15
|
+
payDate
|
|
16
|
+
payType
|
|
17
|
+
transactionDate
|
|
18
|
+
orderId
|
|
19
|
+
paymentId
|
|
20
|
+
invoiceId
|
|
21
|
+
orderInfo
|
|
22
|
+
orderType
|
|
23
|
+
locale
|
|
24
|
+
merchantIp
|
|
25
|
+
extraData
|
|
26
|
+
storeID
|
|
27
|
+
bankCode
|
|
28
|
+
appUser
|
|
29
|
+
phone
|
|
30
|
+
email
|
|
31
|
+
address
|
|
32
|
+
statusCode
|
|
33
|
+
statusDescription
|
|
34
|
+
transactionId
|
|
35
|
+
createBy
|
|
36
|
+
methodDescription
|
|
37
|
+
methodMapping
|
|
38
|
+
baseMethodCode
|
|
39
|
+
confirmPaidBy
|
|
40
|
+
confirmPaidDate
|
|
41
|
+
qrCode
|
|
42
|
+
payUrl
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
45
|
`;
|
|
46
|
-
exports.PAYMENT_METHODS = (0, graphql_tag_1.gql) `
|
|
47
|
-
query PaymentMethods($partnerCode: String) {
|
|
48
|
-
paymentMethods(partnerCode: $partnerCode) {
|
|
49
|
-
id
|
|
50
|
-
code
|
|
51
|
-
name
|
|
52
|
-
description
|
|
53
|
-
image
|
|
54
|
-
}
|
|
55
|
-
}
|
|
46
|
+
exports.PAYMENT_METHODS = (0, graphql_tag_1.gql) `
|
|
47
|
+
query PaymentMethods($partnerCode: String) {
|
|
48
|
+
paymentMethods(partnerCode: $partnerCode) {
|
|
49
|
+
id
|
|
50
|
+
code
|
|
51
|
+
name
|
|
52
|
+
description
|
|
53
|
+
image
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
56
|
`;
|
|
57
|
-
exports.GET_PAYMENT_METHOD_TYPES = (0, graphql_tag_1.gql) `
|
|
58
|
-
query GetPaymentMethodTypes($partnerId: String!, $storeId: String!) {
|
|
59
|
-
getPaymentMethodTypes(partnerId: $partnerId, storeId: $storeId) {
|
|
60
|
-
code
|
|
61
|
-
name
|
|
62
|
-
description
|
|
63
|
-
image
|
|
64
|
-
}
|
|
65
|
-
}
|
|
57
|
+
exports.GET_PAYMENT_METHOD_TYPES = (0, graphql_tag_1.gql) `
|
|
58
|
+
query GetPaymentMethodTypes($partnerId: String!, $storeId: String!) {
|
|
59
|
+
getPaymentMethodTypes(partnerId: $partnerId, storeId: $storeId) {
|
|
60
|
+
code
|
|
61
|
+
name
|
|
62
|
+
description
|
|
63
|
+
image
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
`;
|
|
67
|
+
exports.PAYMENT_INFO = (0, graphql_tag_1.gql) `
|
|
68
|
+
query PaymentInfo($paymentId: String!) {
|
|
69
|
+
paymentInfo(paymentId: $paymentId) {
|
|
70
|
+
id
|
|
71
|
+
payType
|
|
72
|
+
payDate
|
|
73
|
+
dueDate
|
|
74
|
+
completePayment
|
|
75
|
+
paymentTerm
|
|
76
|
+
methodCode
|
|
77
|
+
methodTypeCode
|
|
78
|
+
gatewayConfigId
|
|
79
|
+
partnerCode
|
|
80
|
+
totalAmount
|
|
81
|
+
remain
|
|
82
|
+
currCode
|
|
83
|
+
invoiceId
|
|
84
|
+
orderId
|
|
85
|
+
orderInfo
|
|
86
|
+
orderGroup
|
|
87
|
+
orderType
|
|
88
|
+
returnUrl
|
|
89
|
+
ipnUrl
|
|
90
|
+
merchantIp
|
|
91
|
+
extraData
|
|
92
|
+
storeID
|
|
93
|
+
bankCode
|
|
94
|
+
appUser
|
|
95
|
+
phone
|
|
96
|
+
email
|
|
97
|
+
address
|
|
98
|
+
signature
|
|
99
|
+
createBy
|
|
100
|
+
transactionId
|
|
101
|
+
baseMethodCode
|
|
102
|
+
retry
|
|
103
|
+
postToOrder
|
|
104
|
+
editAble
|
|
105
|
+
approved
|
|
106
|
+
statusCode
|
|
107
|
+
paymentGroup
|
|
108
|
+
userId
|
|
109
|
+
type
|
|
110
|
+
attributes
|
|
111
|
+
items {
|
|
112
|
+
id
|
|
113
|
+
partnerCode
|
|
114
|
+
paymentId
|
|
115
|
+
type
|
|
116
|
+
orderId
|
|
117
|
+
invoiceId
|
|
118
|
+
orderGroup
|
|
119
|
+
orderType
|
|
120
|
+
orderInfo
|
|
121
|
+
totalAmount
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
`;
|
|
126
|
+
exports.PAYMENT_STATUS = (0, graphql_tag_1.gql) `
|
|
127
|
+
query PaymentStatus($paymentId: String!) {
|
|
128
|
+
paymentStatus(paymentId: $paymentId) {
|
|
129
|
+
methodCode
|
|
130
|
+
methodTypeCode
|
|
131
|
+
gatewayConfigId
|
|
132
|
+
partnerCode
|
|
133
|
+
totalAmount
|
|
134
|
+
fee
|
|
135
|
+
discountAmount
|
|
136
|
+
payDate
|
|
137
|
+
payType
|
|
138
|
+
transactionDate
|
|
139
|
+
paymentId
|
|
140
|
+
invoiceId
|
|
141
|
+
orderInfo
|
|
142
|
+
orderType
|
|
143
|
+
locale
|
|
144
|
+
merchantIp
|
|
145
|
+
extraData
|
|
146
|
+
storeID
|
|
147
|
+
bankCode
|
|
148
|
+
appUser
|
|
149
|
+
phone
|
|
150
|
+
email
|
|
151
|
+
address
|
|
152
|
+
statusCode
|
|
153
|
+
statusDescription
|
|
154
|
+
transactionId
|
|
155
|
+
createBy
|
|
156
|
+
methodDescription
|
|
157
|
+
methodMapping
|
|
158
|
+
baseMethodCode
|
|
159
|
+
confirmPaidBy
|
|
160
|
+
confirmPaidDate
|
|
161
|
+
qrCode
|
|
162
|
+
payUrl
|
|
163
|
+
attributes
|
|
164
|
+
}
|
|
165
|
+
}
|
|
66
166
|
`;
|