@posx/core 5.5.250 → 5.5.252
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/build/index.d.ts +51 -5
- package/build/index.js +1 -1
- package/package.json +1 -1
- package/package.publish.json +1 -1
package/build/index.d.ts
CHANGED
|
@@ -2036,6 +2036,10 @@ declare module '@posx/core/test/services/discount/flat-discount-test/flat-discou
|
|
|
2036
2036
|
declare module '@posx/core/test/services/invoice/appendInvoice/append-invoice.test' {
|
|
2037
2037
|
export {};
|
|
2038
2038
|
|
|
2039
|
+
}
|
|
2040
|
+
declare module '@posx/core/test/services/invoice/flat-discount-exceeds-bill-test/flat-discount-exceeds-bill.test' {
|
|
2041
|
+
export {};
|
|
2042
|
+
|
|
2039
2043
|
}
|
|
2040
2044
|
declare module '@posx/core/test/services/invoice/invoice-discount-calculations-test/invoice-discount-calculations.test' {
|
|
2041
2045
|
export {};
|
|
@@ -2236,16 +2240,22 @@ declare module '@posx/core/types/auto.query.type' {
|
|
|
2236
2240
|
Asc = "asc",
|
|
2237
2241
|
Desc = "desc"
|
|
2238
2242
|
}
|
|
2239
|
-
export type Operator<T> = T extends number ? keyof typeof NumericOperators : T extends string ? keyof typeof StringOperators :
|
|
2240
|
-
export type OperatorValueMap = {
|
|
2241
|
-
[K in Operator<
|
|
2243
|
+
export type Operator<T> = T extends number ? keyof typeof NumericOperators | keyof typeof NullOperators : T extends Date ? keyof typeof DateOperators | keyof typeof NullOperators : T extends string ? keyof typeof StringOperators | keyof typeof NullOperators : keyof typeof NullOperators;
|
|
2244
|
+
export type OperatorValueMap<T = any> = {
|
|
2245
|
+
[K in Operator<T>]: T extends Date ? (K extends keyof typeof DateOperators ? DateOperatorValueMap[K] : K extends keyof typeof NullOperators ? boolean : never) : T extends number ? (K extends keyof typeof NumericOperators ? number : K extends keyof typeof NullOperators ? boolean : never) : K extends keyof typeof NumericOperators ? number : K extends keyof typeof DateOperators ? DateOperatorValueMap[K] : K extends keyof typeof StringOperators ? string : K extends keyof typeof MonthOperator ? MonthValues : K extends keyof typeof DayOperator ? string : K extends keyof typeof NullOperators ? boolean : never;
|
|
2242
2246
|
};
|
|
2243
2247
|
export enum NumericOperators {
|
|
2244
2248
|
'>' = 0,
|
|
2245
2249
|
'>=' = 1,
|
|
2246
2250
|
'<' = 2,
|
|
2247
2251
|
'<=' = 3,
|
|
2248
|
-
'=' = 4
|
|
2252
|
+
'=' = 4,
|
|
2253
|
+
'GreaterThan' = 5,
|
|
2254
|
+
'GreaterThanOrEqualTo' = 6,
|
|
2255
|
+
'LessThan' = 7,
|
|
2256
|
+
'LessThanOrEqualTo' = 8,
|
|
2257
|
+
'EqualTo' = 9,
|
|
2258
|
+
'NotEqualTo' = 10
|
|
2249
2259
|
}
|
|
2250
2260
|
export enum StringOperators {
|
|
2251
2261
|
'Contains' = 0,
|
|
@@ -2254,12 +2264,34 @@ declare module '@posx/core/types/auto.query.type' {
|
|
|
2254
2264
|
'EndsWith' = 3,
|
|
2255
2265
|
"Like" = 4
|
|
2256
2266
|
}
|
|
2267
|
+
export enum NullOperators {
|
|
2268
|
+
'IsNull' = 0,
|
|
2269
|
+
'IsNotNull' = 1
|
|
2270
|
+
}
|
|
2257
2271
|
export enum MonthOperator {
|
|
2258
2272
|
WithinAMonth = "Contains"
|
|
2259
2273
|
}
|
|
2260
2274
|
export enum DayOperator {
|
|
2261
2275
|
At = "StartsWith"
|
|
2262
2276
|
}
|
|
2277
|
+
export enum DateOperators {
|
|
2278
|
+
'GreaterThan' = 0,
|
|
2279
|
+
'GreaterThanOrEqualTo' = 1,
|
|
2280
|
+
'LessThan' = 2,
|
|
2281
|
+
'LessThanOrEqualTo' = 3,
|
|
2282
|
+
'Between' = 4,
|
|
2283
|
+
'StartsWith' = 5,
|
|
2284
|
+
'Contains' = 6
|
|
2285
|
+
}
|
|
2286
|
+
export type DateOperatorValueMap = {
|
|
2287
|
+
'GreaterThan': string;
|
|
2288
|
+
'GreaterThanOrEqualTo': string;
|
|
2289
|
+
'LessThan': string;
|
|
2290
|
+
'LessThanOrEqualTo': string;
|
|
2291
|
+
'Between': [string, string];
|
|
2292
|
+
'StartsWith': string;
|
|
2293
|
+
'Contains': MonthValues;
|
|
2294
|
+
};
|
|
2263
2295
|
export enum MonthValues {
|
|
2264
2296
|
Jan = "-01-",
|
|
2265
2297
|
Feb = "-02-",
|
|
@@ -4681,7 +4713,7 @@ declare module '@posx/core/types/product.type' {
|
|
|
4681
4713
|
declare module '@posx/core/types/report.type' {
|
|
4682
4714
|
import { IAppBase, IAppCoreModel, AppCoreModel } from '@posx/core/types/abstract.type';
|
|
4683
4715
|
import { IConfig } from '@posx/core/types/config.type';
|
|
4684
|
-
import { IItem } from '@posx/core/types/product.type';
|
|
4716
|
+
import { IItem, ICategory } from '@posx/core/types/product.type';
|
|
4685
4717
|
export type IReportCategory = IAppBase & {
|
|
4686
4718
|
reports: IReport[];
|
|
4687
4719
|
};
|
|
@@ -4761,6 +4793,7 @@ declare module '@posx/core/types/report.type' {
|
|
|
4761
4793
|
item_sales_summary: TItemSalesSummary[];
|
|
4762
4794
|
item_sales_summary_total: number;
|
|
4763
4795
|
item_sales_summary_total_count: number;
|
|
4796
|
+
item_sales_summary_by_category: TCategorySalesSummary[];
|
|
4764
4797
|
modifier_sales_summary: TModifierSalesSummary[];
|
|
4765
4798
|
modifier_sales_summary_total: number;
|
|
4766
4799
|
modifier_sales_summary_total_count: number;
|
|
@@ -4779,6 +4812,7 @@ declare module '@posx/core/types/report.type' {
|
|
|
4779
4812
|
item_sales_summary: ItemSalesSummary[];
|
|
4780
4813
|
item_sales_summary_total: number;
|
|
4781
4814
|
item_sales_summary_total_count: number;
|
|
4815
|
+
item_sales_summary_by_category: CategorySalesSummary[];
|
|
4782
4816
|
modifier_sales_summary: ModifierSalesSummary[];
|
|
4783
4817
|
modifier_sales_summary_total: number;
|
|
4784
4818
|
modifier_sales_summary_total_count: number;
|
|
@@ -4902,6 +4936,18 @@ declare module '@posx/core/types/report.type' {
|
|
|
4902
4936
|
quantity: number;
|
|
4903
4937
|
total_amount: number;
|
|
4904
4938
|
}
|
|
4939
|
+
export type TCategorySalesSummary = {
|
|
4940
|
+
category: ICategory | null;
|
|
4941
|
+
items: TItemSalesSummary[];
|
|
4942
|
+
total_quantity: number;
|
|
4943
|
+
total_amount: number;
|
|
4944
|
+
};
|
|
4945
|
+
export class CategorySalesSummary implements TCategorySalesSummary {
|
|
4946
|
+
category: ICategory;
|
|
4947
|
+
items: TItemSalesSummary[];
|
|
4948
|
+
total_quantity: number;
|
|
4949
|
+
total_amount: number;
|
|
4950
|
+
}
|
|
4905
4951
|
|
|
4906
4952
|
}
|
|
4907
4953
|
declare module '@posx/core/types/request.type' {
|