@final-commerce/command-frame 0.0.1 → 0.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 +6 -0
- package/dist/actions/get-context/types.d.ts +4 -0
- package/dist/client.d.ts +1 -1
- package/dist/client.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -31,6 +31,7 @@ The library provides a `command` namespace object containing all available actio
|
|
|
31
31
|
- **[getProducts](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/get-products/README.md)** - Retrieve a list of products from the parent application
|
|
32
32
|
- **[getCategories](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/get-categories/README.md)** - Retrieve a list of categories from the parent application
|
|
33
33
|
- **[getProductVariants](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/get-product-variants/README.md)** - Retrieve all variants for a specific product
|
|
34
|
+
- **[getOrders](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/get-orders/README.md)** - Retrieve a list of orders from the system with optional filtering, sorting, and pagination
|
|
34
35
|
- **[getContext](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/get-context/README.md)** - Get current environment/context information (user, company, device, station, outlet, build)
|
|
35
36
|
|
|
36
37
|
#### Product Actions
|
|
@@ -163,6 +164,10 @@ Retrieves a list of categories from the parent application's local database. Sup
|
|
|
163
164
|
|
|
164
165
|
Retrieves all variants for a specific product from the parent application's local database. Useful for displaying variant options or selecting a specific variant.
|
|
165
166
|
|
|
167
|
+
### [getOrders](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/get-orders/README.md)
|
|
168
|
+
|
|
169
|
+
Retrieves a list of orders from the system with optional filtering, sorting, and pagination. Supports filtering by status, customer ID, session ID, and text search.
|
|
170
|
+
|
|
166
171
|
### [addCustomSale](https://github.com/Final-Commerce/command-frame/blob/main/src/actions/add-custom-sale/README.md)
|
|
167
172
|
|
|
168
173
|
Adds a custom sale item to the cart in the parent window. Useful for adding non-product items like service fees, discounts, or custom charges.
|
|
@@ -361,6 +366,7 @@ import type {
|
|
|
361
366
|
GetProductsParams, GetProductsResponse, GetProducts,
|
|
362
367
|
GetCategoriesParams, GetCategoriesResponse, GetCategories,
|
|
363
368
|
GetProductVariantsParams, GetProductVariantsResponse, GetProductVariants,
|
|
369
|
+
GetOrdersParams, GetOrdersResponse, GetOrders,
|
|
364
370
|
GetContext, GetContextResponse,
|
|
365
371
|
// Product Actions
|
|
366
372
|
SetProductActiveParams, SetProductActiveResponse, SetProductActive,
|
|
@@ -13,5 +13,9 @@ export interface GetContextResponse {
|
|
|
13
13
|
buildSourceId: string | null;
|
|
14
14
|
buildIsPremium: boolean;
|
|
15
15
|
timestamp: string;
|
|
16
|
+
user: Record<string, any> | null;
|
|
17
|
+
company: Omit<Record<string, any>, 'settings'> | null;
|
|
18
|
+
station: Record<string, any> | null;
|
|
19
|
+
outlet: Record<string, any> | null;
|
|
16
20
|
}
|
|
17
21
|
export type GetContext = () => Promise<GetContextResponse>;
|
package/dist/client.d.ts
CHANGED
package/dist/client.js
CHANGED