@kiminix/tp-client 2.11.2 → 2.11.4
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/menus/admin/api/create-bill-api.d.ts +12 -0
- package/dist/menus/admin/api/create-bill-api.js +10 -0
- package/dist/menus/admin/api/patch-order-api.d.ts +1 -0
- package/dist/menus/admin/api/patch-order-api.js +2 -1
- package/dist/menus/admin/api/update-order-api.d.ts +1 -1
- package/dist/menus/admin/api/update-order-api.js +1 -1
- package/dist/menus/shared/types.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,15 @@
|
|
|
1
|
+
import { CreateOrdersAdminAPI } from "./create-orders-api";
|
|
1
2
|
export declare class CreateBillAPI {
|
|
3
|
+
/**
|
|
4
|
+
*
|
|
5
|
+
* @param props
|
|
6
|
+
* @throws
|
|
7
|
+
* unauthorized_action, item_unavailable, item_not_found,
|
|
8
|
+
* variant_not_found, qrcode_not_found, internal_error,
|
|
9
|
+
* order_not_found, order_already_linked
|
|
10
|
+
*
|
|
11
|
+
* @returns
|
|
12
|
+
*/
|
|
2
13
|
static create(props: {
|
|
3
14
|
token?: string;
|
|
4
15
|
request: CreateBillAPI.Request;
|
|
@@ -9,5 +20,6 @@ export declare namespace CreateBillAPI {
|
|
|
9
20
|
orders: string[];
|
|
10
21
|
discount?: number;
|
|
11
22
|
name?: string;
|
|
23
|
+
createOrder?: CreateOrdersAdminAPI.Request | undefined;
|
|
12
24
|
}
|
|
13
25
|
}
|
|
@@ -40,6 +40,16 @@ import { RequestUtils } from "../../../utils/request-utils";
|
|
|
40
40
|
var CreateBillAPI = /** @class */ (function () {
|
|
41
41
|
function CreateBillAPI() {
|
|
42
42
|
}
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @param props
|
|
46
|
+
* @throws
|
|
47
|
+
* unauthorized_action, item_unavailable, item_not_found,
|
|
48
|
+
* variant_not_found, qrcode_not_found, internal_error,
|
|
49
|
+
* order_not_found, order_already_linked
|
|
50
|
+
*
|
|
51
|
+
* @returns
|
|
52
|
+
*/
|
|
43
53
|
CreateBillAPI.create = function (props) {
|
|
44
54
|
return __awaiter(this, void 0, void 0, function () {
|
|
45
55
|
return __generator(this, function (_a) {
|
|
@@ -53,7 +53,8 @@ var PatchOrderAdminAPI = /** @class */ (function () {
|
|
|
53
53
|
return [2 /*return*/, RequestUtils.send(function () {
|
|
54
54
|
return axios.patch(base + "/menus/admin/orders", {
|
|
55
55
|
id: props.id,
|
|
56
|
-
status: props.status
|
|
56
|
+
status: props.status,
|
|
57
|
+
unlink: props.unlink
|
|
57
58
|
}, {
|
|
58
59
|
headers: {
|
|
59
60
|
'Authorization': "".concat(props.token)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { OrderStatus } from "../../../enum";
|
|
2
2
|
/**
|
|
3
3
|
* update order
|
|
4
|
-
* @error order_not_found,
|
|
4
|
+
* @error order_not_found, item_not_found, variant_not_found, internal_error
|
|
5
5
|
* @param token
|
|
6
6
|
*/
|
|
7
7
|
export declare class UpdateOrderAdminAPI {
|
|
@@ -39,7 +39,7 @@ import { base } from "../../../constants";
|
|
|
39
39
|
import { RequestUtils } from "../../../utils/request-utils";
|
|
40
40
|
/**
|
|
41
41
|
* update order
|
|
42
|
-
* @error order_not_found,
|
|
42
|
+
* @error order_not_found, item_not_found, variant_not_found, internal_error
|
|
43
43
|
* @param token
|
|
44
44
|
*/
|
|
45
45
|
var UpdateOrderAdminAPI = /** @class */ (function () {
|