upconta.frontend-utils 2.3.2 → 2.4.0

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.
@@ -0,0 +1,78 @@
1
+ import { Attachment, Movement } from '../';
2
+ export type PorcentajesDeIVA = '0' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '10';
3
+ export type PorcentajesDeICE = '3023' | '3610' | '3620' | '3630' | '3640' | '3670' | '3770' | '3043';
4
+ export type PorcentajesDeIRBPNR = '5001';
5
+ export type InfoAdicional = {
6
+ nombre: string;
7
+ valor: string;
8
+ };
9
+ export type TipoProducto = 'insumo' | 'combo' | 'receta' | 'producto' | 'fabricado';
10
+ export type Bodega = {
11
+ bodega: string;
12
+ amount: number;
13
+ };
14
+ export type RelacionProducto = {
15
+ producto: string;
16
+ cantidad: number;
17
+ nota?: string;
18
+ precio?: number;
19
+ };
20
+ export type Precio = {
21
+ _id?: string;
22
+ cliente?: {
23
+ _id?: string;
24
+ nombre?: string;
25
+ };
26
+ descripcion: string;
27
+ precio: number;
28
+ descuento?: number;
29
+ };
30
+ export interface Producto {
31
+ _id: string;
32
+ code: string;
33
+ auxiliarCode?: string;
34
+ type?: 'product' | 'service';
35
+ price?: number;
36
+ precios: Precio[];
37
+ precioFinal?: number;
38
+ description: string;
39
+ descripciones: Array<string>;
40
+ iva: PorcentajesDeIVA;
41
+ ice?: PorcentajesDeICE;
42
+ icePercentage?: number;
43
+ irbpnr?: PorcentajesDeIRBPNR;
44
+ aditionalInformation?: InfoAdicional[];
45
+ accountingAccount?: string;
46
+ status: 'active' | 'inactive';
47
+ claveProdServ: string;
48
+ claveUnidad: string;
49
+ noDeIdentificacion?: string;
50
+ ieps?: number;
51
+ ivaRet?: number;
52
+ iepsRet?: number;
53
+ isrRet?: number;
54
+ ObjetoImp?: string;
55
+ paraRestaurantes?: boolean;
56
+ categorias: string[];
57
+ categoriasRestaurantes: string[];
58
+ descuento?: number;
59
+ impresora?: string;
60
+ total: number;
61
+ bodegas: Bodega[];
62
+ images: Attachment[];
63
+ relaciones: RelacionProducto[];
64
+ tipoProducto: TipoProducto;
65
+ NoAplicaServicio?: boolean;
66
+ _movements: Movement[];
67
+ precioConDescuento?: number;
68
+ costo?: number;
69
+ costoUltimaCompra?: number;
70
+ }
71
+ export interface Categoria {
72
+ _id: string;
73
+ business: string;
74
+ nombre: string;
75
+ descripcion?: string;
76
+ color: string;
77
+ estado?: string;
78
+ }
@@ -1,3 +1,4 @@
1
+ import type { VistaInsertar } from './libs/hooks/vista-insertar';
1
2
  export type { Modulo } from './types/Empresa';
2
3
  export interface ApiResponse<T> {
3
4
  data: T[];
@@ -29,3 +30,13 @@ export interface Movement {
29
30
  nota?: string;
30
31
  mostrarBadge?: boolean;
31
32
  }
33
+ export type Attachment = {
34
+ _id: string;
35
+ name: string;
36
+ mimetype: string;
37
+ fromFileLibrary?: boolean;
38
+ };
39
+ export interface SeekerModalRef {
40
+ form: VistaInsertar['form'];
41
+ onSubmit: VistaInsertar['onSubmit'];
42
+ }