@pastelarai/pastelarai-shared-types 1.0.115 → 1.0.116

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.
@@ -1,4 +1,4 @@
1
- import { CONTENTTYPE, STORAGEUNIT, TASKACTIONTYPE, TASKUNIT, UNIT } from "src/data/types";
1
+ import { CONTENTTYPE, STATUS, STORAGEUNIT, TASKACTIONTYPE, TASKUNIT, UNIT } from "src/data/types";
2
2
  import { PRODUCTCATEGORY } from "src/data/categories";
3
3
  import { IdName } from "./bill";
4
4
  import { Avatar, Customer, ProductInRange } from "./ranges";
@@ -108,3 +108,41 @@ export interface TaskProduct {
108
108
  unit: UNIT;
109
109
  };
110
110
  }
111
+ export interface WorkingFormat extends Format {
112
+ category?: PRODUCTCATEGORY;
113
+ creationMode?: "CUS" | "GLO";
114
+ status?: STATUS;
115
+ isValid?: boolean;
116
+ errors?: {
117
+ type: boolean;
118
+ nb_pers: boolean;
119
+ size: boolean;
120
+ type_sale: boolean;
121
+ duplicate: boolean;
122
+ };
123
+ }
124
+ export interface WorkingCompositionBase extends Omit<CompositionBase, 'format' | 'content_list'> {
125
+ format: WorkingFormat;
126
+ selected?: boolean;
127
+ content_list: WorkingRecipeContent[];
128
+ }
129
+ export type WorkingComposition = WorkingCompositionBase & {
130
+ [key in PricingType]?: Pricing;
131
+ };
132
+ export interface WorkingProduct {
133
+ name: string;
134
+ category: PRODUCTCATEGORY;
135
+ holidays: string;
136
+ storage: {
137
+ unit: STORAGEUNIT;
138
+ value: number;
139
+ };
140
+ stock: number;
141
+ description: string;
142
+ base_format: string;
143
+ composition: WorkingComposition[];
144
+ _id?: string;
145
+ using?: {
146
+ ranges_list: IdNameAvatar[];
147
+ };
148
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pastelarai/pastelarai-shared-types",
3
- "version": "1.0.115",
3
+ "version": "1.0.116",
4
4
  "description": "Shared types for PastelarAI",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",