@nomalism-com/types 1.3.49 → 1.3.50

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/dist/index.cjs CHANGED
@@ -761,10 +761,12 @@ var checkLineInPrisonOptions = [
761
761
  // src/modules/stock/productGoogleSheets/interface.ts
762
762
  var interface_exports19 = {};
763
763
  __export(interface_exports19, {
764
+ InventoryCategoryEnum: () => InventoryCategoryEnum,
764
765
  ProductStateEnum: () => ProductStateEnum,
765
766
  ProductStateLabels: () => ProductStateLabels,
766
767
  ProductTypeEnum: () => ProductTypeEnum,
767
768
  Route: () => Route62,
769
+ SaftProductTypeEnum: () => SaftProductTypeEnum,
768
770
  productState: () => productState,
769
771
  productTypes: () => productTypes
770
772
  });
@@ -789,9 +791,23 @@ var ProductTypeEnum = {
789
791
  Producao: "Producao",
790
792
  Portes: "Portes",
791
793
  RM: "RM",
792
- Montagem: "Montagem"
794
+ Montagem: "Montagem",
795
+ Adiantamento: "Adiantamento"
793
796
  };
794
797
  var productTypes = Object.keys(ProductTypeEnum);
798
+ var SaftProductTypeEnum = {
799
+ P: "P",
800
+ S: "S",
801
+ O: "O"
802
+ };
803
+ var InventoryCategoryEnum = {
804
+ M: "M",
805
+ P: "P",
806
+ A: "A",
807
+ S: "S",
808
+ T: "T",
809
+ B: "B"
810
+ };
795
811
 
796
812
  // src/modules/stock/productImage/interface.ts
797
813
  var interface_exports20 = {};
package/dist/index.js CHANGED
@@ -757,10 +757,12 @@ var checkLineInPrisonOptions = [
757
757
  // src/modules/stock/productGoogleSheets/interface.ts
758
758
  var interface_exports19 = {};
759
759
  __export(interface_exports19, {
760
+ InventoryCategoryEnum: () => InventoryCategoryEnum,
760
761
  ProductStateEnum: () => ProductStateEnum,
761
762
  ProductStateLabels: () => ProductStateLabels,
762
763
  ProductTypeEnum: () => ProductTypeEnum,
763
764
  Route: () => Route62,
765
+ SaftProductTypeEnum: () => SaftProductTypeEnum,
764
766
  productState: () => productState,
765
767
  productTypes: () => productTypes
766
768
  });
@@ -785,9 +787,23 @@ var ProductTypeEnum = {
785
787
  Producao: "Producao",
786
788
  Portes: "Portes",
787
789
  RM: "RM",
788
- Montagem: "Montagem"
790
+ Montagem: "Montagem",
791
+ Adiantamento: "Adiantamento"
789
792
  };
790
793
  var productTypes = Object.keys(ProductTypeEnum);
794
+ var SaftProductTypeEnum = {
795
+ P: "P",
796
+ S: "S",
797
+ O: "O"
798
+ };
799
+ var InventoryCategoryEnum = {
800
+ M: "M",
801
+ P: "P",
802
+ A: "A",
803
+ S: "S",
804
+ T: "T",
805
+ B: "B"
806
+ };
791
807
 
792
808
  // src/modules/stock/productImage/interface.ts
793
809
  var interface_exports20 = {};
@@ -26,9 +26,40 @@ export declare const ProductTypeEnum: {
26
26
  Portes: "Portes";
27
27
  RM: "RM";
28
28
  Montagem: "Montagem";
29
+ Adiantamento: "Adiantamento";
29
30
  };
30
31
  export type IProductType = (typeof ProductTypeEnum)[keyof typeof ProductTypeEnum];
31
32
  export declare const productTypes: string[];
33
+ /**
34
+ * Indicador de produto ou serviço do SAF-T (PT) — ponto 2.4.1 (ProductType):
35
+ * P - Produtos, S - Serviços, O - Outros (ex.: portes debitados, adiantamentos
36
+ * recebidos ou alienação de ativos).
37
+ *
38
+ * É o valor de `product_sheet.saft_product_type`, coluna gerada a partir de
39
+ * `product_sheet.type` (o mapeamento vive na migração, não em código).
40
+ */
41
+ export declare const SaftProductTypeEnum: {
42
+ P: "P";
43
+ S: "S";
44
+ O: "O";
45
+ };
46
+ export type ISaftProductType = (typeof SaftProductTypeEnum)[keyof typeof SaftProductTypeEnum];
47
+ /**
48
+ * Categoria do produto na comunicação de inventários à AT
49
+ * (`product_sheet.type_of_inventory`): M - Mercadorias, P - Matérias-primas,
50
+ * A - Produtos acabados, S - Subprodutos, T - Produtos em curso, B - Ativos
51
+ * biológicos. As letras P/S NÃO têm o mesmo significado que no SAF-T de
52
+ * faturação (`ISaftProductType`).
53
+ */
54
+ export declare const InventoryCategoryEnum: {
55
+ M: "M";
56
+ P: "P";
57
+ A: "A";
58
+ S: "S";
59
+ T: "T";
60
+ B: "B";
61
+ };
62
+ export type IInventoryCategory = (typeof InventoryCategoryEnum)[keyof typeof InventoryCategoryEnum];
32
63
  export interface ICreateRequest {
33
64
  id?: string;
34
65
  reference?: string;
@@ -40,7 +71,6 @@ export interface ICreateRequest {
40
71
  short_description?: string | null;
41
72
  state?: IProductSheetState;
42
73
  type?: IProductType;
43
- type_of_inventory?: string;
44
74
  vat_tax_id?: string;
45
75
  reason_for_exemption?: string | null;
46
76
  weight?: number | null;
@@ -1,7 +1,7 @@
1
1
  import { IMotivosDeEsperaData } from "../../modules/document/order/interfaces";
2
2
  import { IConflict } from "../../modules/document/propostaSheets/interface";
3
3
  import { IEstadoEncomenda } from "../../modules/stock/conferirEncomenda/interface";
4
- import { IExpectDeliveryDates, IProductType } from "../../modules/stock/productGoogleSheets/interface";
4
+ import { IExpectDeliveryDates, IInventoryCategory, IProductType, ISaftProductType } from "../../modules/stock/productGoogleSheets/interface";
5
5
  import { IProductSheetState } from "../../modules/stock/productGoogleSheets/interface";
6
6
  import { IImageType } from "../../modules/stock/productImage/interface";
7
7
  import { IQueryParameterDatatype } from "../../modules/stock/queryParameter/interfaces";
@@ -690,7 +690,8 @@ export type ProductSheet = {
690
690
  name: string | null;
691
691
  designation: string;
692
692
  origin_id: string | null;
693
- type_of_inventory: string;
693
+ saft_product_type: ISaftProductType;
694
+ type_of_inventory: IInventoryCategory | null;
694
695
  max_discount: number;
695
696
  maintenances: string;
696
697
  compositions: string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nomalism-com/types",
3
3
  "description": "A nomalism package with all necessary types and validations for developing APIs",
4
- "version": "1.3.49",
4
+ "version": "1.3.50",
5
5
  "author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
6
6
  "license": "UNLICENSED",
7
7
  "type": "module",