@nomalism-com/types 0.45.63 → 0.45.65
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
|
@@ -16,6 +16,8 @@ __export(main_exports, {
|
|
|
16
16
|
BillOfLadingRoutes: () => route_schema_exports10,
|
|
17
17
|
CLT: () => interfaces_exports39,
|
|
18
18
|
CLTRoutes: () => route_schema_exports74,
|
|
19
|
+
Catalogo: () => interfaces_exports62,
|
|
20
|
+
CatalogoRoutes: () => route_schema_exports119,
|
|
19
21
|
Channel: () => interfaces_exports37,
|
|
20
22
|
ChannelRoutes: () => route_schema_exports72,
|
|
21
23
|
Chat: () => interfaces_exports2,
|
|
@@ -5840,11 +5842,14 @@ __export(route_schema_exports118, {
|
|
|
5840
5842
|
import joi119 from "joi";
|
|
5841
5843
|
var clockSchema = joi119.object({
|
|
5842
5844
|
id: joi119.string().uuid(),
|
|
5843
|
-
// Opcional no create/update (indica se já existe ou é novo)
|
|
5844
5845
|
time: joi119.date().required(),
|
|
5845
5846
|
type: joi119.string().valid(...Object.values(IClockTypeEnum)).required(),
|
|
5846
5847
|
registry_type: joi119.string().valid(...Object.values(IRegistryTypeEnum)).required(),
|
|
5847
|
-
note: joi119.string().allow("", null).optional()
|
|
5848
|
+
note: joi119.string().allow("", null).optional(),
|
|
5849
|
+
created_by: joi119.string().uuid().required(),
|
|
5850
|
+
// 👈 Adicionado para auditoria nos updates
|
|
5851
|
+
updated_by: joi119.string().uuid().required()
|
|
5852
|
+
// 👈 Adicionado para auditoria nos updates
|
|
5848
5853
|
});
|
|
5849
5854
|
var createBodyKeys64 = {
|
|
5850
5855
|
date: joi119.date().required(),
|
|
@@ -5852,12 +5857,20 @@ var createBodyKeys64 = {
|
|
|
5852
5857
|
total_worked: joi119.number().integer().min(0),
|
|
5853
5858
|
balance: joi119.number().integer(),
|
|
5854
5859
|
state: joi119.string().valid(...Object.values(ITimesheetStateEnum)),
|
|
5855
|
-
|
|
5860
|
+
created_by: joi119.string().uuid().required(),
|
|
5861
|
+
// 👈 Adicionado na raiz do dia
|
|
5862
|
+
updated_by: joi119.string().uuid().required(),
|
|
5863
|
+
// 👈 Adicionado na raiz do dia
|
|
5864
|
+
// Objeto opcional para quando se cria o dia já com a primeira picagem
|
|
5856
5865
|
clock: joi119.object({
|
|
5857
5866
|
time: joi119.date(),
|
|
5858
5867
|
type: joi119.string().valid(...Object.values(IClockTypeEnum)).required(),
|
|
5859
5868
|
registry_type: joi119.string().valid(...Object.values(IRegistryTypeEnum)).required(),
|
|
5860
|
-
note: joi119.string().allow("", null).optional()
|
|
5869
|
+
note: joi119.string().allow("", null).optional(),
|
|
5870
|
+
created_by: joi119.string().uuid().required(),
|
|
5871
|
+
// 👈 Adicionado no clock interno
|
|
5872
|
+
updated_by: joi119.string().uuid().required()
|
|
5873
|
+
// 👈 Adicionado no clock interno
|
|
5861
5874
|
})
|
|
5862
5875
|
};
|
|
5863
5876
|
var createBody65 = joi119.object().keys(createBodyKeys64).messages(messages);
|
|
@@ -5865,11 +5878,35 @@ var updateBodyKeys54 = {
|
|
|
5865
5878
|
total_worked: joi119.number().integer().min(0),
|
|
5866
5879
|
balance: joi119.number().integer(),
|
|
5867
5880
|
state: joi119.string().valid(...Object.values(ITimesheetStateEnum)),
|
|
5868
|
-
|
|
5881
|
+
created_by: joi119.string().uuid().optional(),
|
|
5882
|
+
// 💡 Opcional no update para manter o original se quiseres
|
|
5883
|
+
updated_by: joi119.string().uuid().required(),
|
|
5884
|
+
// 👈 Obrigatório no update do dia
|
|
5885
|
+
// Array de picagens enviado pelo formulário de edição
|
|
5869
5886
|
clocks: joi119.array().items(clockSchema)
|
|
5870
5887
|
};
|
|
5871
5888
|
var updateBody56 = joi119.object().keys(updateBodyKeys54).messages(messages);
|
|
5872
5889
|
|
|
5890
|
+
// src/modules/document/CAT/interfaces.ts
|
|
5891
|
+
var interfaces_exports62 = {};
|
|
5892
|
+
__export(interfaces_exports62, {
|
|
5893
|
+
Route: () => Route131
|
|
5894
|
+
});
|
|
5895
|
+
var Route131 = "catalogo";
|
|
5896
|
+
|
|
5897
|
+
// src/modules/document/CAT/route.schema.ts
|
|
5898
|
+
var route_schema_exports119 = {};
|
|
5899
|
+
__export(route_schema_exports119, {
|
|
5900
|
+
createBody: () => createBody66
|
|
5901
|
+
});
|
|
5902
|
+
import joi120 from "joi";
|
|
5903
|
+
var createBody66 = joi120.object().keys({
|
|
5904
|
+
document_header_id: joi120.string().uuid().optional(),
|
|
5905
|
+
document_type_id: joi120.number().integer().positive().required(),
|
|
5906
|
+
from_document_header_id: joi120.string().uuid().required(),
|
|
5907
|
+
document_line_ids: joi120.array().items(joi120.string().uuid().required()).required()
|
|
5908
|
+
}).messages(messages);
|
|
5909
|
+
|
|
5873
5910
|
// src/index.ts
|
|
5874
5911
|
var index_default = main_exports;
|
|
5875
5912
|
export {
|
package/dist/index.js
CHANGED
|
@@ -16,6 +16,8 @@ __export(main_exports, {
|
|
|
16
16
|
BillOfLadingRoutes: () => route_schema_exports10,
|
|
17
17
|
CLT: () => interfaces_exports39,
|
|
18
18
|
CLTRoutes: () => route_schema_exports74,
|
|
19
|
+
Catalogo: () => interfaces_exports62,
|
|
20
|
+
CatalogoRoutes: () => route_schema_exports119,
|
|
19
21
|
Channel: () => interfaces_exports37,
|
|
20
22
|
ChannelRoutes: () => route_schema_exports72,
|
|
21
23
|
Chat: () => interfaces_exports2,
|
|
@@ -5840,11 +5842,14 @@ __export(route_schema_exports118, {
|
|
|
5840
5842
|
import joi119 from "joi";
|
|
5841
5843
|
var clockSchema = joi119.object({
|
|
5842
5844
|
id: joi119.string().uuid(),
|
|
5843
|
-
// Opcional no create/update (indica se já existe ou é novo)
|
|
5844
5845
|
time: joi119.date().required(),
|
|
5845
5846
|
type: joi119.string().valid(...Object.values(IClockTypeEnum)).required(),
|
|
5846
5847
|
registry_type: joi119.string().valid(...Object.values(IRegistryTypeEnum)).required(),
|
|
5847
|
-
note: joi119.string().allow("", null).optional()
|
|
5848
|
+
note: joi119.string().allow("", null).optional(),
|
|
5849
|
+
created_by: joi119.string().uuid().required(),
|
|
5850
|
+
// 👈 Adicionado para auditoria nos updates
|
|
5851
|
+
updated_by: joi119.string().uuid().required()
|
|
5852
|
+
// 👈 Adicionado para auditoria nos updates
|
|
5848
5853
|
});
|
|
5849
5854
|
var createBodyKeys64 = {
|
|
5850
5855
|
date: joi119.date().required(),
|
|
@@ -5852,12 +5857,20 @@ var createBodyKeys64 = {
|
|
|
5852
5857
|
total_worked: joi119.number().integer().min(0),
|
|
5853
5858
|
balance: joi119.number().integer(),
|
|
5854
5859
|
state: joi119.string().valid(...Object.values(ITimesheetStateEnum)),
|
|
5855
|
-
|
|
5860
|
+
created_by: joi119.string().uuid().required(),
|
|
5861
|
+
// 👈 Adicionado na raiz do dia
|
|
5862
|
+
updated_by: joi119.string().uuid().required(),
|
|
5863
|
+
// 👈 Adicionado na raiz do dia
|
|
5864
|
+
// Objeto opcional para quando se cria o dia já com a primeira picagem
|
|
5856
5865
|
clock: joi119.object({
|
|
5857
5866
|
time: joi119.date(),
|
|
5858
5867
|
type: joi119.string().valid(...Object.values(IClockTypeEnum)).required(),
|
|
5859
5868
|
registry_type: joi119.string().valid(...Object.values(IRegistryTypeEnum)).required(),
|
|
5860
|
-
note: joi119.string().allow("", null).optional()
|
|
5869
|
+
note: joi119.string().allow("", null).optional(),
|
|
5870
|
+
created_by: joi119.string().uuid().required(),
|
|
5871
|
+
// 👈 Adicionado no clock interno
|
|
5872
|
+
updated_by: joi119.string().uuid().required()
|
|
5873
|
+
// 👈 Adicionado no clock interno
|
|
5861
5874
|
})
|
|
5862
5875
|
};
|
|
5863
5876
|
var createBody65 = joi119.object().keys(createBodyKeys64).messages(messages);
|
|
@@ -5865,11 +5878,35 @@ var updateBodyKeys54 = {
|
|
|
5865
5878
|
total_worked: joi119.number().integer().min(0),
|
|
5866
5879
|
balance: joi119.number().integer(),
|
|
5867
5880
|
state: joi119.string().valid(...Object.values(ITimesheetStateEnum)),
|
|
5868
|
-
|
|
5881
|
+
created_by: joi119.string().uuid().optional(),
|
|
5882
|
+
// 💡 Opcional no update para manter o original se quiseres
|
|
5883
|
+
updated_by: joi119.string().uuid().required(),
|
|
5884
|
+
// 👈 Obrigatório no update do dia
|
|
5885
|
+
// Array de picagens enviado pelo formulário de edição
|
|
5869
5886
|
clocks: joi119.array().items(clockSchema)
|
|
5870
5887
|
};
|
|
5871
5888
|
var updateBody56 = joi119.object().keys(updateBodyKeys54).messages(messages);
|
|
5872
5889
|
|
|
5890
|
+
// src/modules/document/CAT/interfaces.ts
|
|
5891
|
+
var interfaces_exports62 = {};
|
|
5892
|
+
__export(interfaces_exports62, {
|
|
5893
|
+
Route: () => Route131
|
|
5894
|
+
});
|
|
5895
|
+
var Route131 = "catalogo";
|
|
5896
|
+
|
|
5897
|
+
// src/modules/document/CAT/route.schema.ts
|
|
5898
|
+
var route_schema_exports119 = {};
|
|
5899
|
+
__export(route_schema_exports119, {
|
|
5900
|
+
createBody: () => createBody66
|
|
5901
|
+
});
|
|
5902
|
+
import joi120 from "joi";
|
|
5903
|
+
var createBody66 = joi120.object().keys({
|
|
5904
|
+
document_header_id: joi120.string().uuid().optional(),
|
|
5905
|
+
document_type_id: joi120.number().integer().positive().required(),
|
|
5906
|
+
from_document_header_id: joi120.string().uuid().required(),
|
|
5907
|
+
document_line_ids: joi120.array().items(joi120.string().uuid().required()).required()
|
|
5908
|
+
}).messages(messages);
|
|
5909
|
+
|
|
5873
5910
|
// src/index.ts
|
|
5874
5911
|
var index_default = main_exports;
|
|
5875
5912
|
export {
|
package/dist/main.d.ts
CHANGED
|
@@ -253,4 +253,6 @@ import * as MobilePrint from './modules/stock/mobilePrint/interface';
|
|
|
253
253
|
import * as MobilePrintRoutes from './modules/stock/mobilePrint/route.schema';
|
|
254
254
|
import * as TimeSheet from './modules/user/timeSheet/interfaces';
|
|
255
255
|
import * as TimeSheetRoutes from './modules/user/timeSheet/route.schema';
|
|
256
|
-
|
|
256
|
+
import * as Catalogo from './modules/document/CAT/interfaces';
|
|
257
|
+
import * as CatalogoRoutes from './modules/document/CAT/route.schema';
|
|
258
|
+
export { shared, viewErrors, stockErrors, userErrors, documentManagementErrors, integrationErrors, ZipCode, ZipCodeRoutes, BankData, BankDataRoutes, Client, ClientRoutes, ClientType, ClientTypeRoutes, Chat, ChatRoutes, Commissioner, CommissionerRoutes, Country, CountryRoutes, DeliveryMethods, DeliveryMethodsRoutes, DocumentHeader, DocumentHeaderRoutes, DocumentHeaderHistory, BillOfLading, BillOfLadingRoutes, ProductionOrder, ProductionOrderRoutes, Proforma, ProformaRoutes, PropostaFornecedor, PropostaFornecedorRoutes, ProviderCreditNoteFromReturn, ProviderCreditNoteFromReturnRoutes, ProviderFinancialCreditNote, ProviderFinancialCreditNoteRoutes, ProviderServiceInvoice, ProviderServiceInvoiceRoutes, DocumentLine, DocumentLineRoutes, DocumentLineAssoc, DocumentSet, DocumentSetRoutes, DocumentType, DocumentTypeRoutes, ExternalDocumentType, ExternalDocumentHeader, ExternalDocumentHeaderRoutes, Favorites, FavoritesRoutes, File, FileRoutes, GoogleSheets, GoogleSheetsRoutes, Language, LanguageRoutes, Location, LocationRoutes, MaturityDates, MaturityDatesRoutes, Multimedia, MultimediaRoutes, OrderManagement, Observation, ObservationRoutes, ObservationType, ObservationTypeRoutes, Password, PasswordRoutes, Payment, PaymentRoutes, PaymentMethods, PaymentMethodsRoutes, ProductImage, ProductImageRoutes, Promotion, PromotionRoutes, PromotionAssoc, PromotionAssocRoutes, Providers, ProvidersRoutes, ProviderType, ProviderTypeRoutes, PurchaseConditions, PurchaseConditionsRoutes, ReasonForExemption, ReasonForExemptionRoutes, RefreshToken, RefreshTokenRoutes, SegmentsArea, SegmentsAreaRoutes, Sessions, SessionsRoutes, Shippings, ShippingsRoutes, StoreOperator, StoreOperatorRoutes, SystemModule, SystemModuleRoutes, Swift, SwiftRoutes, TypeOfLocation, TypeOfLocationRoutes, UnitOfMeasure, UnitOfMeasureRoutes, UserPositions, UserPositionsRoutes, Users, UsersRoutes, UserTokens, UserTokensRoutes, VatValidation, VatValidationRoutes, VatTax, VatTaxRoutes, VatTaxZone, VatTaxZoneRoutes, Vehicles, VehiclesRoutes, Workflow, WorkflowRoutes, StockMovement, StockMovementRoutes, Tenant, TenantRoutes, PreSale, PreSaleRoutes, PreSaleProduct, PreSaleProductRoutes, Npc, NpcRoutes, Printer, PrinterRoutes, SchedulePrintJob, SchedulePrintJobRoutes, QueryList, QueryListRoutes, QueryParameter, QueryParameterRoutes, ReturnReason, ReturnReasonRoutes, PropostaSheets, PropostaSheetsRoutes, Schedule, ScheduleRoutes, GoogleFilePermission, GoogleFilePermissionRoutes, Settings, SettingsRoutes, Tickets, TicketsRoutes, Channel, ChannelRoutes, TicketsLanguage, TicketsLanguageRoutes, CLT, CLTRoutes, StartDocumentHeaderLastUpdate, Persona, PersonaRoutes, ProjectInfo, ProjectInfoRoutes, EmailVerification, EmailVerificationRoutes, EmailLog, EmailLogRoutes, Purchase, PurchaseRoutes, Order, OrderRoutes, MaterialEntrance, MaterialEntranceRoutes, Transformado, TransformadoRoutes, Quebra, QuebraRoutes, UpfrontReturn, UpfrontReturnRoutes, SavedEmPicking, SavedEmPickingRoutes, EmailTemplate, EmailTemplateRoutes, EmailTemplateAttachment, EmailTemplateAttachmentRoutes, Inventario, InventarioRoutes, ReturnToProvider, ReturnToProviderRoutes, Prison, PrisonRoutes, DocumentLineNote, DocumentLineNoteRoutes, SavedProviderProposal, SavedProviderProposalRoutes, ProductGoogleSheets, ProductGoogleSheetsRoutes, Task, TaskRoutes, TaskMessage, TaskMessageRoutes, RecurrentTasks, TaskRead, TaskReadRoutes, Theme, ThemeRoutes, Dashboard, DashboardRoutes, ChatRapidMessage, ChatRapidMessageRoutes, SideMenu, SideMenuRoutes, SidemenuHighlight, SidemenuHighlightRoutes, AdminPanel, ErrorLog, ErrorLogRoutes, DocumentLineRm, DocumentLineRmRoutes, DocumentLineMt, DocumentLineMtRoutes, ChatSubscriber, ChatSubscriberRoutes, Tag, TagRoutes, Gmails, NPF, NPFRoutes, NRCL, NRCLRoutes, CurrentAccount, CurrentAccountRoutes, PaymentBatch, PaymentBatchRoutes, Portal, PortalRoutes, GoogleSheetPool, AccountCode, AccountCodeRoutes, LLM, LLMRoutes, PatchNotes, ConferirEncomenda, DocumentHeaderSurvey, DocumentHeaderSurveyRoutes, DocumentHeaderSubscriber, DocumentHeaderSubscriberRoutes, GoogleCalendar, GoogleCalendarRoutes, WebSocket, ProductLocation, MobilePrint, MobilePrintRoutes, TimeSheet, TimeSheetRoutes, Catalogo, CatalogoRoutes, };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as IShared from '../../../shared/interface';
|
|
2
|
+
export declare const Route = "catalogo";
|
|
3
|
+
export interface ICreateRequest {
|
|
4
|
+
document_header_id?: string;
|
|
5
|
+
from_document_header_id: string;
|
|
6
|
+
document_type_id: number;
|
|
7
|
+
document_line_ids: string[];
|
|
8
|
+
}
|
|
9
|
+
export interface IRepository {
|
|
10
|
+
create(params: ICreateRequest): Promise<void>;
|
|
11
|
+
}
|
|
12
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
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": "0.45.
|
|
4
|
+
"version": "0.45.65",
|
|
5
5
|
"author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
|
|
6
6
|
"license": "UNLICENSED",
|
|
7
7
|
"type": "module",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@swc/core": "^1.15.40",
|
|
33
|
-
"@types/node": "^24.
|
|
34
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
35
|
-
"@typescript-eslint/parser": "^8.
|
|
33
|
+
"@types/node": "^24.13.1",
|
|
34
|
+
"@typescript-eslint/eslint-plugin": "^8.61.0",
|
|
35
|
+
"@typescript-eslint/parser": "^8.61.0",
|
|
36
36
|
"eslint": "^9.39.4",
|
|
37
37
|
"eslint-config-prettier": "^10.1.8",
|
|
38
38
|
"eslint-import-resolver-typescript": "^4.4.5",
|