@nomalism-com/types 0.40.55 → 0.40.57
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 +85 -1
- package/dist/index.js +85 -1
- package/dist/main.d.ts +5 -1
- package/dist/modules/user/chatSubscribers/interfaces.d.ts +1 -1
- package/dist/modules/user/externalChatSubscribers/interfaces.d.ts +27 -0
- package/dist/modules/user/externalChatSubscribers/route.schema.d.ts +3 -0
- package/dist/modules/user/externalPersona/interface.d.ts +47 -0
- package/dist/modules/user/externalPersona/route.schema.d.ts +3 -0
- package/dist/shared/entities/user.d.ts +39 -0
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -65,9 +65,13 @@ __export(main_exports, {
|
|
|
65
65
|
EmailVerificationRoutes: () => route_schema_exports80,
|
|
66
66
|
ErrorLog: () => interfaces_exports55,
|
|
67
67
|
ErrorLogRoutes: () => route_schema_exports104,
|
|
68
|
+
ExternalChatSubscriber: () => interfaces_exports57,
|
|
69
|
+
ExternalChatSubscriberRoutes: () => route_schema_exports117,
|
|
68
70
|
ExternalDocumentHeader: () => interface_exports9,
|
|
69
71
|
ExternalDocumentHeaderRoutes: () => route_schema_exports21,
|
|
70
72
|
ExternalDocumentType: () => interface_exports8,
|
|
73
|
+
ExternalPersona: () => interface_exports68,
|
|
74
|
+
ExternalPersonaRoutes: () => route_schema_exports116,
|
|
71
75
|
Favorites: () => interfaces_exports16,
|
|
72
76
|
FavoritesRoutes: () => route_schema_exports22,
|
|
73
77
|
File: () => interface_exports10,
|
|
@@ -4368,7 +4372,7 @@ var createBodyKeys55 = {
|
|
|
4368
4372
|
main: joi79.boolean().default(false).optional(),
|
|
4369
4373
|
contact: joi79.boolean().default(false).optional()
|
|
4370
4374
|
};
|
|
4371
|
-
var createBody56 = joi79.object().keys(createBodyKeys55).xor("provider_id", "client_id", "commissioner_id").messages(messages);
|
|
4375
|
+
var createBody56 = joi79.object().keys(createBodyKeys55).xor("provider_id", "client_id", "commissioner_id", "store_operator_id").messages(messages);
|
|
4372
4376
|
var updateBodyKeys50 = {
|
|
4373
4377
|
name: joi79.string().allow(null, "").optional(),
|
|
4374
4378
|
nif: joi79.string().allow(null, "").optional(),
|
|
@@ -5975,6 +5979,86 @@ var findByCodeParams = {
|
|
|
5975
5979
|
};
|
|
5976
5980
|
var findByCode = joi116.object().keys(findByCodeParams).messages(messages);
|
|
5977
5981
|
|
|
5982
|
+
// src/modules/user/externalPersona/interface.ts
|
|
5983
|
+
var interface_exports68 = {};
|
|
5984
|
+
__export(interface_exports68, {
|
|
5985
|
+
LowerName: () => LowerName109,
|
|
5986
|
+
Route: () => Route111,
|
|
5987
|
+
UpperName: () => UpperName109
|
|
5988
|
+
});
|
|
5989
|
+
var Route111 = "external_persona";
|
|
5990
|
+
var UpperName109 = "ExternalPersona";
|
|
5991
|
+
var LowerName109 = UpperName109[0].toLowerCase() + UpperName109.substring(1);
|
|
5992
|
+
|
|
5993
|
+
// src/modules/user/externalPersona/route.schema.ts
|
|
5994
|
+
var route_schema_exports116 = {};
|
|
5995
|
+
__export(route_schema_exports116, {
|
|
5996
|
+
createBody: () => createBody68,
|
|
5997
|
+
updateBody: () => updateBody58
|
|
5998
|
+
});
|
|
5999
|
+
import joi117 from "joi";
|
|
6000
|
+
var emailSchema2 = joi117.string().trim(true).lowercase().email({ tlds: { allow: false } }).allow(null, "");
|
|
6001
|
+
var createBodyKeys67 = {
|
|
6002
|
+
name: joi117.string().allow(null, "").optional(),
|
|
6003
|
+
nif: joi117.string().allow(null, "").optional(),
|
|
6004
|
+
street: joi117.string().allow(null, "").optional(),
|
|
6005
|
+
locality: joi117.string().allow(null, "").optional(),
|
|
6006
|
+
postal_code: joi117.string().trim(true).lowercase().allow(null, "").optional(),
|
|
6007
|
+
country_id: joi117.string().uuid().allow(null, "").optional(),
|
|
6008
|
+
telephone: joi117.string().allow(null, "").optional(),
|
|
6009
|
+
email: emailSchema2.optional(),
|
|
6010
|
+
observations: joi117.string().allow(null, "").optional(),
|
|
6011
|
+
provider_id: joi117.string().uuid().allow(null, ""),
|
|
6012
|
+
client_id: joi117.string().uuid().allow(null, ""),
|
|
6013
|
+
commissioner_id: joi117.string().uuid().allow(null, ""),
|
|
6014
|
+
store_operator_id: joi117.string().uuid().allow(null, ""),
|
|
6015
|
+
reason_for_exemption_id: joi117.string().uuid().allow(null, "").optional()
|
|
6016
|
+
};
|
|
6017
|
+
var createBody68 = joi117.object().keys(createBodyKeys67).xor("provider_id", "client_id", "commissioner_id", "store_operator_id").messages(messages);
|
|
6018
|
+
var updateBodyKeys56 = {
|
|
6019
|
+
name: joi117.string().allow(null, "").optional(),
|
|
6020
|
+
nif: joi117.string().allow(null, "").optional(),
|
|
6021
|
+
street: joi117.string().allow(null, "").optional(),
|
|
6022
|
+
locality: joi117.string().allow(null, "").optional(),
|
|
6023
|
+
postal_code: joi117.string().trim(true).lowercase().allow(null, "").optional(),
|
|
6024
|
+
country_id: joi117.string().uuid().allow(null, "").optional(),
|
|
6025
|
+
telephone: joi117.string().allow(null, "").optional(),
|
|
6026
|
+
email: emailSchema2.optional(),
|
|
6027
|
+
observations: joi117.string().allow(null, "").optional(),
|
|
6028
|
+
reason_for_exemption_id: joi117.string().uuid().allow(null, "").optional()
|
|
6029
|
+
};
|
|
6030
|
+
var updateBody58 = joi117.object().keys(updateBodyKeys56).messages(messages);
|
|
6031
|
+
|
|
6032
|
+
// src/modules/user/externalChatSubscribers/interfaces.ts
|
|
6033
|
+
var interfaces_exports57 = {};
|
|
6034
|
+
__export(interfaces_exports57, {
|
|
6035
|
+
LowerName: () => LowerName110,
|
|
6036
|
+
Route: () => Route112,
|
|
6037
|
+
UpperName: () => UpperName110
|
|
6038
|
+
});
|
|
6039
|
+
var Route112 = "external_chat_subscriber";
|
|
6040
|
+
var UpperName110 = "ExternalChatSubscriber";
|
|
6041
|
+
var LowerName110 = UpperName110[0].toLowerCase() + UpperName110.substring(1);
|
|
6042
|
+
|
|
6043
|
+
// src/modules/user/externalChatSubscribers/route.schema.ts
|
|
6044
|
+
var route_schema_exports117 = {};
|
|
6045
|
+
__export(route_schema_exports117, {
|
|
6046
|
+
createOrUpdateBody: () => createOrUpdateBody3,
|
|
6047
|
+
findByParams: () => findByParams2
|
|
6048
|
+
});
|
|
6049
|
+
import joi118 from "joi";
|
|
6050
|
+
var createOrUpdateBodyKeys3 = {
|
|
6051
|
+
owner_id: joi118.string().uuid().required(),
|
|
6052
|
+
document_header_id: joi118.string().uuid().required(),
|
|
6053
|
+
external_persona_ids: joi118.array().items(joi118.string().optional()).required()
|
|
6054
|
+
};
|
|
6055
|
+
var createOrUpdateBody3 = joi118.object().keys(createOrUpdateBodyKeys3).messages(messages);
|
|
6056
|
+
var findByParamsKeys2 = {
|
|
6057
|
+
owner_id: joi118.string().uuid().required(),
|
|
6058
|
+
document_header_id: joi118.string().uuid().optional()
|
|
6059
|
+
};
|
|
6060
|
+
var findByParams2 = joi118.object().keys(findByParamsKeys2).messages(messages);
|
|
6061
|
+
|
|
5978
6062
|
// src/index.ts
|
|
5979
6063
|
var index_default = main_exports;
|
|
5980
6064
|
export {
|
package/dist/index.js
CHANGED
|
@@ -65,9 +65,13 @@ __export(main_exports, {
|
|
|
65
65
|
EmailVerificationRoutes: () => route_schema_exports80,
|
|
66
66
|
ErrorLog: () => interfaces_exports55,
|
|
67
67
|
ErrorLogRoutes: () => route_schema_exports104,
|
|
68
|
+
ExternalChatSubscriber: () => interfaces_exports57,
|
|
69
|
+
ExternalChatSubscriberRoutes: () => route_schema_exports117,
|
|
68
70
|
ExternalDocumentHeader: () => interface_exports9,
|
|
69
71
|
ExternalDocumentHeaderRoutes: () => route_schema_exports21,
|
|
70
72
|
ExternalDocumentType: () => interface_exports8,
|
|
73
|
+
ExternalPersona: () => interface_exports68,
|
|
74
|
+
ExternalPersonaRoutes: () => route_schema_exports116,
|
|
71
75
|
Favorites: () => interfaces_exports16,
|
|
72
76
|
FavoritesRoutes: () => route_schema_exports22,
|
|
73
77
|
File: () => interface_exports10,
|
|
@@ -4368,7 +4372,7 @@ var createBodyKeys55 = {
|
|
|
4368
4372
|
main: joi79.boolean().default(false).optional(),
|
|
4369
4373
|
contact: joi79.boolean().default(false).optional()
|
|
4370
4374
|
};
|
|
4371
|
-
var createBody56 = joi79.object().keys(createBodyKeys55).xor("provider_id", "client_id", "commissioner_id").messages(messages);
|
|
4375
|
+
var createBody56 = joi79.object().keys(createBodyKeys55).xor("provider_id", "client_id", "commissioner_id", "store_operator_id").messages(messages);
|
|
4372
4376
|
var updateBodyKeys50 = {
|
|
4373
4377
|
name: joi79.string().allow(null, "").optional(),
|
|
4374
4378
|
nif: joi79.string().allow(null, "").optional(),
|
|
@@ -5975,6 +5979,86 @@ var findByCodeParams = {
|
|
|
5975
5979
|
};
|
|
5976
5980
|
var findByCode = joi116.object().keys(findByCodeParams).messages(messages);
|
|
5977
5981
|
|
|
5982
|
+
// src/modules/user/externalPersona/interface.ts
|
|
5983
|
+
var interface_exports68 = {};
|
|
5984
|
+
__export(interface_exports68, {
|
|
5985
|
+
LowerName: () => LowerName109,
|
|
5986
|
+
Route: () => Route111,
|
|
5987
|
+
UpperName: () => UpperName109
|
|
5988
|
+
});
|
|
5989
|
+
var Route111 = "external_persona";
|
|
5990
|
+
var UpperName109 = "ExternalPersona";
|
|
5991
|
+
var LowerName109 = UpperName109[0].toLowerCase() + UpperName109.substring(1);
|
|
5992
|
+
|
|
5993
|
+
// src/modules/user/externalPersona/route.schema.ts
|
|
5994
|
+
var route_schema_exports116 = {};
|
|
5995
|
+
__export(route_schema_exports116, {
|
|
5996
|
+
createBody: () => createBody68,
|
|
5997
|
+
updateBody: () => updateBody58
|
|
5998
|
+
});
|
|
5999
|
+
import joi117 from "joi";
|
|
6000
|
+
var emailSchema2 = joi117.string().trim(true).lowercase().email({ tlds: { allow: false } }).allow(null, "");
|
|
6001
|
+
var createBodyKeys67 = {
|
|
6002
|
+
name: joi117.string().allow(null, "").optional(),
|
|
6003
|
+
nif: joi117.string().allow(null, "").optional(),
|
|
6004
|
+
street: joi117.string().allow(null, "").optional(),
|
|
6005
|
+
locality: joi117.string().allow(null, "").optional(),
|
|
6006
|
+
postal_code: joi117.string().trim(true).lowercase().allow(null, "").optional(),
|
|
6007
|
+
country_id: joi117.string().uuid().allow(null, "").optional(),
|
|
6008
|
+
telephone: joi117.string().allow(null, "").optional(),
|
|
6009
|
+
email: emailSchema2.optional(),
|
|
6010
|
+
observations: joi117.string().allow(null, "").optional(),
|
|
6011
|
+
provider_id: joi117.string().uuid().allow(null, ""),
|
|
6012
|
+
client_id: joi117.string().uuid().allow(null, ""),
|
|
6013
|
+
commissioner_id: joi117.string().uuid().allow(null, ""),
|
|
6014
|
+
store_operator_id: joi117.string().uuid().allow(null, ""),
|
|
6015
|
+
reason_for_exemption_id: joi117.string().uuid().allow(null, "").optional()
|
|
6016
|
+
};
|
|
6017
|
+
var createBody68 = joi117.object().keys(createBodyKeys67).xor("provider_id", "client_id", "commissioner_id", "store_operator_id").messages(messages);
|
|
6018
|
+
var updateBodyKeys56 = {
|
|
6019
|
+
name: joi117.string().allow(null, "").optional(),
|
|
6020
|
+
nif: joi117.string().allow(null, "").optional(),
|
|
6021
|
+
street: joi117.string().allow(null, "").optional(),
|
|
6022
|
+
locality: joi117.string().allow(null, "").optional(),
|
|
6023
|
+
postal_code: joi117.string().trim(true).lowercase().allow(null, "").optional(),
|
|
6024
|
+
country_id: joi117.string().uuid().allow(null, "").optional(),
|
|
6025
|
+
telephone: joi117.string().allow(null, "").optional(),
|
|
6026
|
+
email: emailSchema2.optional(),
|
|
6027
|
+
observations: joi117.string().allow(null, "").optional(),
|
|
6028
|
+
reason_for_exemption_id: joi117.string().uuid().allow(null, "").optional()
|
|
6029
|
+
};
|
|
6030
|
+
var updateBody58 = joi117.object().keys(updateBodyKeys56).messages(messages);
|
|
6031
|
+
|
|
6032
|
+
// src/modules/user/externalChatSubscribers/interfaces.ts
|
|
6033
|
+
var interfaces_exports57 = {};
|
|
6034
|
+
__export(interfaces_exports57, {
|
|
6035
|
+
LowerName: () => LowerName110,
|
|
6036
|
+
Route: () => Route112,
|
|
6037
|
+
UpperName: () => UpperName110
|
|
6038
|
+
});
|
|
6039
|
+
var Route112 = "external_chat_subscriber";
|
|
6040
|
+
var UpperName110 = "ExternalChatSubscriber";
|
|
6041
|
+
var LowerName110 = UpperName110[0].toLowerCase() + UpperName110.substring(1);
|
|
6042
|
+
|
|
6043
|
+
// src/modules/user/externalChatSubscribers/route.schema.ts
|
|
6044
|
+
var route_schema_exports117 = {};
|
|
6045
|
+
__export(route_schema_exports117, {
|
|
6046
|
+
createOrUpdateBody: () => createOrUpdateBody3,
|
|
6047
|
+
findByParams: () => findByParams2
|
|
6048
|
+
});
|
|
6049
|
+
import joi118 from "joi";
|
|
6050
|
+
var createOrUpdateBodyKeys3 = {
|
|
6051
|
+
owner_id: joi118.string().uuid().required(),
|
|
6052
|
+
document_header_id: joi118.string().uuid().required(),
|
|
6053
|
+
external_persona_ids: joi118.array().items(joi118.string().optional()).required()
|
|
6054
|
+
};
|
|
6055
|
+
var createOrUpdateBody3 = joi118.object().keys(createOrUpdateBodyKeys3).messages(messages);
|
|
6056
|
+
var findByParamsKeys2 = {
|
|
6057
|
+
owner_id: joi118.string().uuid().required(),
|
|
6058
|
+
document_header_id: joi118.string().uuid().optional()
|
|
6059
|
+
};
|
|
6060
|
+
var findByParams2 = joi118.object().keys(findByParamsKeys2).messages(messages);
|
|
6061
|
+
|
|
5978
6062
|
// src/index.ts
|
|
5979
6063
|
var index_default = main_exports;
|
|
5980
6064
|
export {
|
package/dist/main.d.ts
CHANGED
|
@@ -241,4 +241,8 @@ import * as PortalRoutes from './modules/ui/portal/route.schema';
|
|
|
241
241
|
import * as GoogleSheetPool from './modules/stock/googleSheetPool/interface';
|
|
242
242
|
import * as AccountCode from './modules/stock/accountCode/interface';
|
|
243
243
|
import * as AccountCodeRoutes from './modules/stock/accountCode/route.schema';
|
|
244
|
-
|
|
244
|
+
import * as ExternalPersona from './modules/user/externalPersona/interface';
|
|
245
|
+
import * as ExternalPersonaRoutes from './modules/user/externalPersona/route.schema';
|
|
246
|
+
import * as ExternalChatSubscriber from './modules/user/externalChatSubscribers/interfaces';
|
|
247
|
+
import * as ExternalChatSubscriberRoutes from './modules/user/externalChatSubscribers/route.schema';
|
|
248
|
+
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, DocumentLineAssocRoutes, DocumentSet, DocumentSetRoutes, DocumentType, DocumentTypeRoutes, ExternalDocumentType, ExternalDocumentHeader, ExternalDocumentHeaderRoutes, Favorites, FavoritesRoutes, File, FileRoutes, GroupPermissions, GroupPermissionsRoutes, GoogleSheets, GoogleSheetsRoutes, Language, LanguageRoutes, Location, LocationRoutes, MaturityDates, MaturityDatesRoutes, Multimedia, MultimediaRoutes, OrderManagement, Observation, ObservationRoutes, ObservationType, ObservationTypeRoutes, Password, PasswordRoutes, Payment, PaymentRoutes, PaymentMethods, PaymentMethodsRoutes, Permissions, PermissionsRoutes, ProductImage, ProductImageRoutes, Promotion, PromotionRoutes, PromotionAssoc, PromotionAssocRoutes, Providers, ProvidersRoutes, ProviderType, ProviderTypeRoutes, PurchaseConditions, PurchaseConditionsRoutes, ReasonForExemption, ReasonForExemptionRoutes, RefreshToken, RefreshTokenRoutes, SegmentsArea, SegmentsAreaRoutes, Sessions, SessionsRoutes, Shippings, ShippingsRoutes, StoreOperator, StoreOperatorRoutes, Swift, SwiftRoutes, TypeOfLocation, TypeOfLocationRoutes, UnitOfMeasure, UnitOfMeasureRoutes, UserPermissions, UserPermissionsRoutes, 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, AdminPanel, ErrorLog, ErrorLogRoutes, DocumentLineRm, DocumentLineRmRoutes, DocumentLineMt, DocumentLineMtRoutes, ChatSubscriber, ChatSubscriberRoutes, Tag, TagRoutes, Gmails, GmailsRoutes, NPF, NPFRoutes, NRCL, NRCLRoutes, CurrentAccount, CurrentAccountRoutes, PaymentBatch, PaymentBatchRoutes, Portal, PortalRoutes, GoogleSheetPool, AccountCode, AccountCodeRoutes, ExternalPersona, ExternalPersonaRoutes, ExternalChatSubscriber, ExternalChatSubscriberRoutes, };
|
|
@@ -20,7 +20,7 @@ export type IFindResponse = {
|
|
|
20
20
|
phone_number: string | null;
|
|
21
21
|
};
|
|
22
22
|
export interface IRepository {
|
|
23
|
-
createOrUpdate(data: ICreateOrUpdateRequest): Promise<
|
|
23
|
+
createOrUpdate(data: ICreateOrUpdateRequest): Promise<void>;
|
|
24
24
|
find(selector: IFindRequest): Promise<IFindResponse[]>;
|
|
25
25
|
deleteOne(selector: IShared.IFindByIdRequest): Promise<void>;
|
|
26
26
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ExternalChatSubscriber } from '../../../shared/entities/user';
|
|
2
|
+
import * as IShared from '../../../shared/interface';
|
|
3
|
+
export type Entity = ExternalChatSubscriber;
|
|
4
|
+
export declare const Route = "external_chat_subscriber";
|
|
5
|
+
export declare const UpperName = "ExternalChatSubscriber";
|
|
6
|
+
export declare const LowerName: string;
|
|
7
|
+
export interface ICreateOrUpdateRequest {
|
|
8
|
+
owner_id: string;
|
|
9
|
+
document_header_id: string;
|
|
10
|
+
external_persona_ids: string[];
|
|
11
|
+
}
|
|
12
|
+
export interface IFindRequest {
|
|
13
|
+
owner_id: string;
|
|
14
|
+
document_header_id: string;
|
|
15
|
+
}
|
|
16
|
+
export type IFindResponse = {
|
|
17
|
+
external_persona_id: string;
|
|
18
|
+
name: string;
|
|
19
|
+
email: string;
|
|
20
|
+
phone_number: string | null;
|
|
21
|
+
};
|
|
22
|
+
export interface IRepository {
|
|
23
|
+
createOrUpdate(data: ICreateOrUpdateRequest): Promise<void>;
|
|
24
|
+
find(selector: IFindRequest): Promise<IFindResponse[]>;
|
|
25
|
+
deleteOne(selector: IShared.IFindByIdRequest): Promise<void>;
|
|
26
|
+
}
|
|
27
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type * as IShared from '../../../shared/interface';
|
|
2
|
+
import type { ExternalPersona, Country, ReasonForExemption } from '../../../shared/entities/user';
|
|
3
|
+
export type Entity = ExternalPersona;
|
|
4
|
+
export declare const Route = "external_persona";
|
|
5
|
+
export declare const UpperName = "ExternalPersona";
|
|
6
|
+
export declare const LowerName: string;
|
|
7
|
+
interface IEntityExtended extends Entity {
|
|
8
|
+
formatted_address: string;
|
|
9
|
+
country: Country | null;
|
|
10
|
+
reason_for_exemption: ReasonForExemption | null;
|
|
11
|
+
}
|
|
12
|
+
export interface ICreateRequest {
|
|
13
|
+
name: string | null;
|
|
14
|
+
nif: string | null;
|
|
15
|
+
street: string | null;
|
|
16
|
+
postal_code: string | null;
|
|
17
|
+
locality: string | null;
|
|
18
|
+
country_id: string | null;
|
|
19
|
+
telephone: string | null;
|
|
20
|
+
email: string | null;
|
|
21
|
+
observations: string | null;
|
|
22
|
+
provider_id: string | null;
|
|
23
|
+
client_id: string | null;
|
|
24
|
+
commissioner_id: string | null;
|
|
25
|
+
store_operator_id: string | null;
|
|
26
|
+
reason_for_exemption_id: string | null;
|
|
27
|
+
}
|
|
28
|
+
export interface IUpdateRequest {
|
|
29
|
+
name?: string | null;
|
|
30
|
+
nif?: string | null;
|
|
31
|
+
street?: string | null;
|
|
32
|
+
postal_code?: string | null;
|
|
33
|
+
locality?: string | null;
|
|
34
|
+
country_id?: string | null;
|
|
35
|
+
telephone?: string | null;
|
|
36
|
+
email?: string | null;
|
|
37
|
+
observations?: string | null;
|
|
38
|
+
reason_for_exemption_id?: string | null;
|
|
39
|
+
}
|
|
40
|
+
export interface IRepository {
|
|
41
|
+
findByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IEntityExtended[]>;
|
|
42
|
+
create(data: ICreateRequest): Promise<Entity>;
|
|
43
|
+
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<void>;
|
|
44
|
+
deleteOne(params: IShared.IFindByIdRequest): Promise<void>;
|
|
45
|
+
}
|
|
46
|
+
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
47
|
+
export {};
|
|
@@ -511,3 +511,42 @@ export type ChatSubscriber = {
|
|
|
511
511
|
created_by: string;
|
|
512
512
|
updated_by: string;
|
|
513
513
|
};
|
|
514
|
+
/**
|
|
515
|
+
* Model ExternalPersona
|
|
516
|
+
*
|
|
517
|
+
*/
|
|
518
|
+
export type ExternalPersona = {
|
|
519
|
+
id: string;
|
|
520
|
+
name: string | null;
|
|
521
|
+
nif: string | null;
|
|
522
|
+
telephone: string | null;
|
|
523
|
+
email: string | null;
|
|
524
|
+
observations: string | null;
|
|
525
|
+
street: string | null;
|
|
526
|
+
postal_code: string | null;
|
|
527
|
+
locality: string | null;
|
|
528
|
+
country_id: string | null;
|
|
529
|
+
reason_for_exemption_id: string | null;
|
|
530
|
+
provider_id: string | null;
|
|
531
|
+
client_id: string | null;
|
|
532
|
+
commissioner_id: string | null;
|
|
533
|
+
store_operator_id: string | null;
|
|
534
|
+
created_at: Date;
|
|
535
|
+
updated_at: Date;
|
|
536
|
+
created_by: string;
|
|
537
|
+
updated_by: string;
|
|
538
|
+
};
|
|
539
|
+
/**
|
|
540
|
+
* Model ExternalChatSubscriber
|
|
541
|
+
*
|
|
542
|
+
*/
|
|
543
|
+
export type ExternalChatSubscriber = {
|
|
544
|
+
id: string;
|
|
545
|
+
external_persona_id: string;
|
|
546
|
+
owner_id: string;
|
|
547
|
+
document_header_id: string;
|
|
548
|
+
created_at: Date;
|
|
549
|
+
updated_at: Date;
|
|
550
|
+
created_by: string;
|
|
551
|
+
updated_by: string;
|
|
552
|
+
};
|
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.40.
|
|
4
|
+
"version": "0.40.57",
|
|
5
5
|
"author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
|
|
6
6
|
"license": "UNLICENSED",
|
|
7
7
|
"type": "module",
|