@longvansoftware/service-js-client 1.0.2
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 -0
- package/dist/config/config.d.ts +26 -0
- package/dist/config/config.js +29 -0
- package/dist/src/graphql/auth/mutations.d.ts +7 -0
- package/dist/src/graphql/auth/mutations.js +99 -0
- package/dist/src/graphql/auth/queries.d.ts +1 -0
- package/dist/src/graphql/auth/queries.js +25 -0
- package/dist/src/graphql/cloud/mutations.d.ts +8 -0
- package/dist/src/graphql/cloud/mutations.js +115 -0
- package/dist/src/graphql/cloud/queries.d.ts +5 -0
- package/dist/src/graphql/cloud/queries.js +121 -0
- package/dist/src/graphql/computing/mutations.d.ts +10 -0
- package/dist/src/graphql/computing/mutations.js +110 -0
- package/dist/src/graphql/computing/queries.d.ts +3 -0
- package/dist/src/graphql/computing/queries.js +48 -0
- package/dist/src/graphql/crm/mutations.d.ts +8 -0
- package/dist/src/graphql/crm/mutations.js +316 -0
- package/dist/src/graphql/crm/queries.d.ts +7 -0
- package/dist/src/graphql/crm/queries.js +281 -0
- package/dist/src/graphql/payment/mutations.d.ts +1 -0
- package/dist/src/graphql/payment/mutations.js +35 -0
- package/dist/src/graphql/payment/queries.d.ts +2 -0
- package/dist/src/graphql/payment/queries.js +23 -0
- package/dist/src/graphql/product/mutations.d.ts +0 -0
- package/dist/src/graphql/product/mutations.js +1 -0
- package/dist/src/graphql/product/queries.d.ts +11 -0
- package/dist/src/graphql/product/queries.js +431 -0
- package/dist/src/graphql/service/mutations.d.ts +10 -0
- package/dist/src/graphql/service/mutations.js +284 -0
- package/dist/src/graphql/service/queries.d.ts +6 -0
- package/dist/src/graphql/service/queries.js +174 -0
- package/dist/src/graphql/user/mutations.d.ts +4 -0
- package/dist/src/graphql/user/mutations.js +118 -0
- package/dist/src/graphql/user/queries.d.ts +13 -0
- package/dist/src/graphql/user/queries.js +252 -0
- package/dist/src/index.d.ts +1 -0
- package/dist/src/index.js +5 -0
- package/dist/src/lib/SDK.d.ts +42 -0
- package/dist/src/lib/SDK.js +71 -0
- package/dist/src/lib/auth/index.d.ts +27 -0
- package/dist/src/lib/auth/index.js +72 -0
- package/dist/src/lib/cloud/index.d.ts +25 -0
- package/dist/src/lib/cloud/index.js +248 -0
- package/dist/src/lib/computing/index.d.ts +25 -0
- package/dist/src/lib/computing/index.js +254 -0
- package/dist/src/lib/crm/index.d.ts +21 -0
- package/dist/src/lib/crm/index.js +296 -0
- package/dist/src/lib/order/index.d.ts +452 -0
- package/dist/src/lib/order/index.js +1204 -0
- package/dist/src/lib/payment/index.d.ts +7 -0
- package/dist/src/lib/payment/index.js +69 -0
- package/dist/src/lib/product/index.d.ts +37 -0
- package/dist/src/lib/product/index.js +132 -0
- package/dist/src/lib/service/index.d.ts +94 -0
- package/dist/src/lib/service/index.js +348 -0
- package/dist/src/lib/service.d.ts +14 -0
- package/dist/src/lib/service.js +101 -0
- package/dist/src/lib/serviceSDK.d.ts +18 -0
- package/dist/src/lib/serviceSDK.js +187 -0
- package/dist/src/lib/user/index.d.ts +23 -0
- package/dist/src/lib/user/index.js +345 -0
- package/dist/src/lib/warehouse/index.d.ts +20 -0
- package/dist/src/lib/warehouse/index.js +48 -0
- package/dist/src/types/auth.d.ts +82 -0
- package/dist/src/types/auth.js +2 -0
- package/dist/src/types/cloud.d.ts +40 -0
- package/dist/src/types/cloud.js +2 -0
- package/dist/src/types/computing.d.ts +16 -0
- package/dist/src/types/computing.js +2 -0
- package/dist/src/types/crm.d.ts +291 -0
- package/dist/src/types/crm.js +2 -0
- package/dist/src/types/order.d.ts +54 -0
- package/dist/src/types/order.js +2 -0
- package/dist/src/types/product.d.ts +63 -0
- package/dist/src/types/product.js +2 -0
- package/dist/src/types/service.d.ts +29 -0
- package/dist/src/types/service.js +2 -0
- package/dist/src/types/user.d.ts +95 -0
- package/dist/src/types/user.js +2 -0
- package/dist/src/types/warehouse.d.ts +5 -0
- package/dist/src/types/warehouse.js +2 -0
- package/dist/src/utils/helpers.d.ts +4 -0
- package/dist/src/utils/helpers.js +41 -0
- package/package.json +43 -0
@@ -0,0 +1,452 @@
|
|
1
|
+
import { LineItem, DiscountCampaign, CancelOrder, MemberDiscount, CampaignPromotion, OrderQuery } from "../../types/order";
|
2
|
+
import { Service } from "../serviceSDK";
|
3
|
+
/**
|
4
|
+
* Represents a service for managing orders.
|
5
|
+
*/
|
6
|
+
export declare class OrderService extends Service {
|
7
|
+
/**
|
8
|
+
* Constructs a new OrderService instance.
|
9
|
+
* @param endpoint - The endpoint URL for the service.
|
10
|
+
* @param orgId - The organization ID.
|
11
|
+
* @param storeId - The store ID.
|
12
|
+
*/
|
13
|
+
constructor(endpoint: string, orgId: string, storeId: string);
|
14
|
+
setToken(token: string): void;
|
15
|
+
/**
|
16
|
+
* Creates a new order.
|
17
|
+
* @param orderData - The data for the order.
|
18
|
+
* @param platform - The platform for the order.
|
19
|
+
* @param createDraft - Indicates whether to create a draft order.
|
20
|
+
* @returns A promise that resolves with the created order.
|
21
|
+
* @throws If an error occurs while creating the order.
|
22
|
+
*/
|
23
|
+
createOrder(orderData: any, platform: string, createDraft: boolean): Promise<any>;
|
24
|
+
/**
|
25
|
+
* Creates a temporary order.
|
26
|
+
*
|
27
|
+
* @param orderData - The data for the order.
|
28
|
+
* @param platform - The platform for the order.
|
29
|
+
* @returns A promise that resolves to the response from the server.
|
30
|
+
* @throws If an error occurs during the API call.
|
31
|
+
*/
|
32
|
+
createOrderTemp(orderData: any, platform: string): Promise<any>;
|
33
|
+
/**
|
34
|
+
* Completes multiple orders.
|
35
|
+
* @param orderIds - The IDs of the orders to complete.
|
36
|
+
* @returns A promise that resolves when the orders are completed.
|
37
|
+
* @throws If an error occurs while completing the orders.
|
38
|
+
*/
|
39
|
+
completeOrder(orderIds: string[]): Promise<any>;
|
40
|
+
/**
|
41
|
+
* Adds a voucher to an order.
|
42
|
+
* @param orderId - The ID of the order.
|
43
|
+
* @param voucherCode - The voucher code.
|
44
|
+
* @returns A promise that resolves when the voucher is added.
|
45
|
+
* @throws If an error occurs while adding the voucher.
|
46
|
+
*/
|
47
|
+
addVoucher(orderId: string, voucherCode: string): Promise<any>;
|
48
|
+
/**
|
49
|
+
* Removes a voucher from an order.
|
50
|
+
* @param orderId - The ID of the order.
|
51
|
+
* @param voucherCode - The voucher code.
|
52
|
+
* @returns A promise that resolves when the voucher is removed.
|
53
|
+
* @throws If an error occurs while removing the voucher.
|
54
|
+
*/
|
55
|
+
removeVoucher(orderId: string, voucherCode: string): Promise<any>;
|
56
|
+
/**
|
57
|
+
* Updates the VAT (Value Added Tax) for an order.
|
58
|
+
* @param orderId - The ID of the order.
|
59
|
+
* @param vatFee - The VAT fee.
|
60
|
+
* @param vatType - The VAT type. (e.g., VALUE_GOODS, PRODUCT, etc. )
|
61
|
+
* @returns A promise that resolves when the VAT is updated.
|
62
|
+
* @throws If an error occurs while updating the VAT.
|
63
|
+
*/
|
64
|
+
updateVAT(orderId: string, vatFee: number, vatType: string): Promise<any>;
|
65
|
+
/**
|
66
|
+
* Updates the customer and shipping address for an order.
|
67
|
+
* @param orderId - The ID of the order.
|
68
|
+
* @param customerData - The data for the customer.
|
69
|
+
* @param shippingAddress - The shipping address.
|
70
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
71
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
72
|
+
*/
|
73
|
+
updateCustomerAndShippingAddress(orderId: string, customerData: string, shippingAddress: string): Promise<any>;
|
74
|
+
/**
|
75
|
+
* Retrieves the order line items for a specific order.
|
76
|
+
* @param partnerId - The partner ID.
|
77
|
+
* @returns A promise that resolves with the order line items.
|
78
|
+
* @throws If an error occurs while retrieving the order line items.
|
79
|
+
*/
|
80
|
+
/**
|
81
|
+
* Adds order line items to an order.
|
82
|
+
* @param orderId - The ID of the order.
|
83
|
+
* @param lineItems - The line items to add.
|
84
|
+
* @returns A promise that resolves when the line items are added.
|
85
|
+
* @throws If an error occurs while adding the line items.
|
86
|
+
*/
|
87
|
+
addOrderLineItems(orderId: string, lineItems: LineItem[]): Promise<any>;
|
88
|
+
/**
|
89
|
+
* Update Quantity in an order
|
90
|
+
* @param orderId - The id of the order .
|
91
|
+
* @param orderItemId - The id of order item.
|
92
|
+
* @param quantity - Quantity of profuct in order.
|
93
|
+
* @returns A promise that resolves with the created order.
|
94
|
+
* @throws If an error occurs while creating the order.
|
95
|
+
*/
|
96
|
+
updateQuantityProductInOrder(orderId: string, orderItemId: string, quantity: number): Promise<any>;
|
97
|
+
/**
|
98
|
+
*Updates sale Employee
|
99
|
+
* @param orderId - The ID of the order.
|
100
|
+
* @param saleId - The Id of saler.
|
101
|
+
* @param updatedBy - Who update.
|
102
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
103
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
104
|
+
*/
|
105
|
+
updateSaleEmployee(orderId: string, saleId: string, updatedBy: string): Promise<any>;
|
106
|
+
/**
|
107
|
+
*Update type of order
|
108
|
+
* @param orderId - The ID of the order.
|
109
|
+
* @param orderType - The type of order.
|
110
|
+
* @param updatedBy - Id of person update
|
111
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
112
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
113
|
+
*/
|
114
|
+
updateOrderType(orderId: string, orderType: string, updatedBy: string): Promise<any>;
|
115
|
+
/**
|
116
|
+
* Update new price in order
|
117
|
+
* @param orderId - The ID of the order.
|
118
|
+
* @param orderItemId - The id of order.
|
119
|
+
* @param priceNew - the new price after update
|
120
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
121
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
122
|
+
*/
|
123
|
+
updatePriceInOrder(orderId: string, orderItemId: string, priceNew: number): Promise<any>;
|
124
|
+
/**
|
125
|
+
* Update discount price in order
|
126
|
+
* @param orderId - The ID of the order.
|
127
|
+
* @param orderItemId - The id of order.
|
128
|
+
* @param requestData - The request data
|
129
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
130
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
131
|
+
*/
|
132
|
+
updateDiscountPriceInOrder(orderId: string, orderItemId: string, requestData: DiscountCampaign): Promise<any>;
|
133
|
+
/**
|
134
|
+
* Update cancel order
|
135
|
+
* @param orderId - The ID of the order.
|
136
|
+
* @param requestData
|
137
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
138
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
139
|
+
*/
|
140
|
+
updateCancelOrder(orderId: string, requestData: CancelOrder): Promise<any>;
|
141
|
+
/**
|
142
|
+
* Update status of return order
|
143
|
+
* @param orderId - The ID of the order.
|
144
|
+
* @param statusNew - the new status of order
|
145
|
+
* @param updatedBy - Id of person update
|
146
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
147
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
148
|
+
*/
|
149
|
+
updateStatusReturnOrder(orderId: string, statusNew: string, updatedBy: string): Promise<any>;
|
150
|
+
/**
|
151
|
+
* Update Shipping service
|
152
|
+
* @param orderId - The ID of the order.
|
153
|
+
* @param shippingServiceId - the id of shipping service
|
154
|
+
* @param updatedBy - Id of person update
|
155
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
156
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
157
|
+
*/
|
158
|
+
updateShippngService(orderId: string, shippingServiceId: string, updatedBy: string): Promise<any>;
|
159
|
+
/**
|
160
|
+
* Update shipping order
|
161
|
+
* @param orderId - The ID of the order.
|
162
|
+
* @param shippingId - the id of shipping
|
163
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
164
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
165
|
+
*/
|
166
|
+
updateShippingOrder(orderId: string, shippingId: string): Promise<any>;
|
167
|
+
/**
|
168
|
+
* Update shipping fee
|
169
|
+
* @param orderId - The ID of the order.
|
170
|
+
* @param shippingFee - the fee of shipping
|
171
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
172
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
173
|
+
*/
|
174
|
+
updateShippingFee(orderId: string, shipingFee: Number): Promise<any>;
|
175
|
+
/**
|
176
|
+
* Update Financial Status after payment success
|
177
|
+
* @param orderId - The ID of the order.
|
178
|
+
* @param financialStatus - the status of financial
|
179
|
+
* @param updatedBy - Id of person update
|
180
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
181
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
182
|
+
*/
|
183
|
+
updateFinancialStatus(orderId: string, financialStatus: string, updatedBy: string): Promise<any>;
|
184
|
+
/**
|
185
|
+
* Update warehouse of order
|
186
|
+
* @param orderId - The ID of the order.
|
187
|
+
* @param warehouseId - the status of warehouse
|
188
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
189
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
190
|
+
*/
|
191
|
+
updateWareHouseOrder(orderId: String, warehouseId: string): Promise<any>;
|
192
|
+
/**
|
193
|
+
* Update voucher
|
194
|
+
* @param orderId - The ID of the order.
|
195
|
+
* @param voucherCode - the code of voucher
|
196
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
197
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
198
|
+
*/
|
199
|
+
updateVoucher(orderId: string, voucherCode: string): Promise<any>;
|
200
|
+
/**
|
201
|
+
* Update Vat
|
202
|
+
* @param orderId - The ID of the order.
|
203
|
+
* @param vatFee - The fee of VAT
|
204
|
+
* @param vatType - The type of vat
|
205
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
206
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
207
|
+
*/
|
208
|
+
updateVat(orderId: string, vatFee: number, vatType: string): Promise<any>;
|
209
|
+
/**
|
210
|
+
* Update Status of l order
|
211
|
+
* @param orderId - The ID of the order.
|
212
|
+
* @param status - The status of sell order
|
213
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
214
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
215
|
+
*/
|
216
|
+
updateStatusSellOrder(orderId: string, status: string): Promise<any>;
|
217
|
+
/**
|
218
|
+
* Update date remain in total price
|
219
|
+
* @param orderId - The ID of the order.
|
220
|
+
* @param updatedBy - Id of person update
|
221
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
222
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
223
|
+
*/
|
224
|
+
updateRemainToTalPrice(orderId: string, updatedBy: string): Promise<any>;
|
225
|
+
/**
|
226
|
+
* Update date create order
|
227
|
+
* @param orderId - The ID of the order.
|
228
|
+
* @param orderDate - The date of order
|
229
|
+
* @param updatedBy - Id of person update
|
230
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
231
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
232
|
+
*/
|
233
|
+
updateDateCreateOrder(orderId: string, orderDate: number, updatedBy: string): Promise<any>;
|
234
|
+
/**
|
235
|
+
* Update membership discount
|
236
|
+
* @param orderId - The ID of the order.
|
237
|
+
* @param requestData
|
238
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
239
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
240
|
+
*/
|
241
|
+
updateMemberDiscount(orderId: string, requestData: MemberDiscount): Promise<any>;
|
242
|
+
/**
|
243
|
+
* Update status editable order
|
244
|
+
* @param orderId - The ID of the order.
|
245
|
+
* @param editable - The editable of
|
246
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
247
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
248
|
+
*/
|
249
|
+
updateEditableOrder(orderId: string, editable: boolean): Promise<any>;
|
250
|
+
/**
|
251
|
+
* Update discount
|
252
|
+
* @param orderId - The ID of the order.
|
253
|
+
* @param requestData
|
254
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
255
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
256
|
+
*/
|
257
|
+
updateDiscount(orderId: string, requestData: MemberDiscount): Promise<any>;
|
258
|
+
/**
|
259
|
+
* Update info campaign promotion
|
260
|
+
* @param orderId - The ID of the order.
|
261
|
+
* @param requestData
|
262
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
263
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
264
|
+
*/
|
265
|
+
updateInfoCampaignPromotion(orderId: string, requestData: CampaignPromotion): Promise<any>;
|
266
|
+
/**
|
267
|
+
* Get list shipping service
|
268
|
+
* @param shippingCarrierId - The ID of the campaign
|
269
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
270
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
271
|
+
*/
|
272
|
+
getListShippingService(shippingCarrierId: string): Promise<any>;
|
273
|
+
/**
|
274
|
+
* Get info sell order
|
275
|
+
* @param orderId - The ID of the order.
|
276
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
277
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
278
|
+
*/
|
279
|
+
getInfoSellOrder(orderId: string): Promise<any>;
|
280
|
+
/**
|
281
|
+
* Get info return order
|
282
|
+
* @param orderId - The ID of the order.
|
283
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
284
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
285
|
+
*/
|
286
|
+
getInfoReturnOrder(orderId: string): Promise<any>;
|
287
|
+
/**
|
288
|
+
* Get list type order
|
289
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
290
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
291
|
+
*/
|
292
|
+
getListTypeOrder(): Promise<any>;
|
293
|
+
/**
|
294
|
+
* GEt list shipping carrier
|
295
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
296
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
297
|
+
*/
|
298
|
+
getListShippingCarrier(): Promise<any>;
|
299
|
+
/**
|
300
|
+
* Get list sell order
|
301
|
+
* @param orderId
|
302
|
+
* @param requestData
|
303
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
304
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
305
|
+
*/
|
306
|
+
getListSellOrder(requestData: OrderQuery): Promise<any>;
|
307
|
+
getDiaries(requestData: OrderQuery): Promise<any>;
|
308
|
+
/**
|
309
|
+
* Get list sale order status
|
310
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
311
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
312
|
+
*/
|
313
|
+
getListSaleOrderStatus(): Promise<any>;
|
314
|
+
/**
|
315
|
+
* Get list return order
|
316
|
+
* @param orderId - The id of the order
|
317
|
+
* @param requestData
|
318
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
319
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
320
|
+
*/
|
321
|
+
getListReturnOrder(orderId: string, requestData: OrderQuery): Promise<any>;
|
322
|
+
/**
|
323
|
+
* Get list return order status
|
324
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
325
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
326
|
+
*/
|
327
|
+
getListReturnOrderStatus(): Promise<any>;
|
328
|
+
/**
|
329
|
+
* remove draft order
|
330
|
+
* @param orderId - The id of order
|
331
|
+
* @param updatedBy - Thi id of person update
|
332
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
333
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
334
|
+
*/
|
335
|
+
removeDraftOrder(orderId: string, updatedBy: string): Promise<any>;
|
336
|
+
/**
|
337
|
+
* Cancel product in order
|
338
|
+
* @param orderId - The id of order
|
339
|
+
* @param orderItemId - Thi id of item order
|
340
|
+
* @param reason - The reason of cancel product in order
|
341
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
342
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
343
|
+
*/
|
344
|
+
cancelProductInOrder(orderId: string, orderItemId: string, reason: string): Promise<any>;
|
345
|
+
/**
|
346
|
+
* Remove Product in order
|
347
|
+
* @param orderId - The id of order
|
348
|
+
* @param orderItemId - Thi id of item order
|
349
|
+
* @param reason - The reason of cancel product in order
|
350
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
351
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
352
|
+
*/
|
353
|
+
removeProductInOrder(orderId: string, orderItemId: string, reason: string): Promise<any>;
|
354
|
+
/**
|
355
|
+
* Print order pdf
|
356
|
+
* @param orderId - The id of order
|
357
|
+
* @param paymentMethod - Thi id of item order
|
358
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
359
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
360
|
+
*/
|
361
|
+
printOrderPdf(orderId: string, paymentMethod: string): Promise<any>;
|
362
|
+
/**
|
363
|
+
* Print order HTML
|
364
|
+
* @param orderId - The id of order
|
365
|
+
* @param paymentMethod - Thi id of item order
|
366
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
367
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
368
|
+
*/
|
369
|
+
printOrderHtml(orderId: string, paymentMethod: string): Promise<any>;
|
370
|
+
/**
|
371
|
+
* Create an orderReturn
|
372
|
+
* @param orderData - The id of order
|
373
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
374
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
375
|
+
*/
|
376
|
+
createOrderReturn(orderData: any): Promise<any>;
|
377
|
+
/**
|
378
|
+
* Caculate the order
|
379
|
+
* @param orderData - The data from the order
|
380
|
+
* @returns A promise that resolves when the customer and shipping address are updated.
|
381
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
382
|
+
*/
|
383
|
+
calculateOrder(orderData: any): Promise<any>;
|
384
|
+
/**
|
385
|
+
* get amount product able order
|
386
|
+
* @param productIds - The id of product
|
387
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
388
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
389
|
+
*/
|
390
|
+
getQuantityAbleOrder(productIds: string[]): Promise<any>;
|
391
|
+
/**
|
392
|
+
* updatee note without login
|
393
|
+
* @param orderId - The id of the order
|
394
|
+
* @param noteId - The id of the note
|
395
|
+
* @param note - The content of the note
|
396
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
397
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
398
|
+
*/
|
399
|
+
updateNoteWithoutLogin(orderId: string, noteId: string, note: string): Promise<any>;
|
400
|
+
/**
|
401
|
+
* add voucher without login
|
402
|
+
* @param orderId - The id of the order
|
403
|
+
* @param voucherCode - The code of voucher
|
404
|
+
* @param updatedBy
|
405
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
406
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
407
|
+
*/
|
408
|
+
addVoucherWithoutLogin(orderId: string, voucherCode: string, updatedBy: "SYSTEM"): Promise<any>;
|
409
|
+
/**
|
410
|
+
* delete voucher without login
|
411
|
+
* @param orderId - The id of the order
|
412
|
+
* @param voucherCode - The code of voucher
|
413
|
+
* @param updatedBy
|
414
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
415
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
416
|
+
*/
|
417
|
+
deleteVoucherLogin(orderId: string, voucherCode: string, updatedBy: "SYSTEM"): Promise<any>;
|
418
|
+
/**
|
419
|
+
* get list note without login
|
420
|
+
* @param orderId - The id of the order
|
421
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
422
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
423
|
+
*/
|
424
|
+
getListNoteWithoutLogin(orderId: string): Promise<any>;
|
425
|
+
/**
|
426
|
+
* create note without login
|
427
|
+
* @param orderId - The id of the order
|
428
|
+
* @param createdBy
|
429
|
+
* @param note
|
430
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
431
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
432
|
+
*/
|
433
|
+
createNoteWithoutLogin(orderId: string, createdBy: string, note: string): Promise<any>;
|
434
|
+
/**
|
435
|
+
* get list order realation
|
436
|
+
* @param orderIds
|
437
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
438
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
439
|
+
*/
|
440
|
+
getListOrderRelationsWithoutLogin(orderIds: string[]): Promise<any>;
|
441
|
+
/**
|
442
|
+
* get list order realation
|
443
|
+
* @param orderId - The id of order
|
444
|
+
* @param noteId - The id of note
|
445
|
+
* @param deletedBy - The id of person delete
|
446
|
+
* @returns A prom that resolves when the customer and shipping address are updated.
|
447
|
+
* @throws If an error occurs while updating the customer and shipping address.
|
448
|
+
*/
|
449
|
+
deleteNoteWithoutLogin(orderId: string, noteId: string, deletedBy: string): Promise<any>;
|
450
|
+
updateOrderDescription(orderId: string, description: string): Promise<any>;
|
451
|
+
getOrderDetail(orderId: string): Promise<any>;
|
452
|
+
}
|