@posx/core 5.3.77 → 5.3.79

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 CHANGED
@@ -583,6 +583,21 @@ declare module '@posx/core/services/app.service' {
583
583
  * @param stock the quantity to change the stock by, can be negative
584
584
  */
585
585
  changeStock(uid: string, stock: number): Promise<IItem>;
586
+ /**
587
+ * Clone an item
588
+ * @param item item to clone
589
+ * @returns cloned item
590
+ */
591
+ cloneItem(item: IItem): Promise<IItem>;
592
+ /**
593
+ * Clone modifiers of an item
594
+ * @param item item to clone modifiers
595
+ * @returns cloned modifiers
596
+ */
597
+ cloneModifiers(modifierCategory: ICoreCategory, modifiers: ICoreItem[]): Promise<{
598
+ modifierCategory: ICoreCategory;
599
+ modifiers: ICoreItem[];
600
+ }>;
586
601
  }
587
602
  export class ItemService extends AppRemoteService<IItem> implements IItemService {
588
603
  readonly http: AxiosInstance;
@@ -604,6 +619,11 @@ declare module '@posx/core/services/app.service' {
604
619
  changeStock(uid: string, stock: number): Promise<IItem>;
605
620
  private convertFileToBase64;
606
621
  private getFileExtension;
622
+ cloneItem(item: IItem): Promise<IItem>;
623
+ cloneModifiers(modifierCategory: ICoreCategory, modifiers: ICoreItem[]): Promise<{
624
+ modifierCategory: ICoreCategory;
625
+ modifiers: ICoreItem[];
626
+ }>;
607
627
  }
608
628
  /**
609
629
  * Represents a service for managing categories.
@@ -689,23 +709,7 @@ declare module '@posx/core/services/app.service' {
689
709
  constructor(http: AxiosInstance, db: Dexie, options: IServiceOptions, moduleName?: string, methodName?: string);
690
710
  changeToTakeOut(uid: string): Promise<ISectionItem>;
691
711
  }
692
- export interface IProductService extends IAppRemoteService<IItem> {
693
- /**
694
- * Clone an item
695
- * @param item item to clone
696
- * @returns cloned item
697
- */
698
- cloneItem(item: IItem): Promise<IItem>;
699
- /**
700
- * Clone modifiers of an item
701
- * @param item item to clone modifiers
702
- * @returns cloned modifiers
703
- */
704
- cloneModifiers(modifierCategory: ICoreCategory, modifiers: ICoreItem[]): Promise<{
705
- modifierCategory: ICoreCategory;
706
- modifiers: ICoreItem[];
707
- }>;
708
- }
712
+ export type IProductService = IAppRemoteService<IItem>;
709
713
  export class ProductService extends AppRemoteService<IItem> implements IProductService {
710
714
  readonly http: AxiosInstance;
711
715
  readonly db: Dexie;
@@ -713,11 +717,6 @@ declare module '@posx/core/services/app.service' {
713
717
  readonly moduleName: string;
714
718
  readonly methodName: string;
715
719
  constructor(http: AxiosInstance, db: Dexie, options: IServiceOptions, moduleName?: string, methodName?: string);
716
- cloneItem(item: IItem): Promise<IItem>;
717
- cloneModifiers(modifierCategory: ICoreCategory, modifiers: ICoreItem[]): Promise<{
718
- modifierCategory: ICoreCategory;
719
- modifiers: ICoreItem[];
720
- }>;
721
720
  }
722
721
  export interface IShiftService extends IAppRemoteService<IShift> {
723
722
  closeShift(declareAmount: number, userUid: string): Promise<IShift>;