@nomalism-com/types 0.40.100 → 0.40.102
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.
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import type * as IShared from '../../../shared/interface';
|
|
2
2
|
import type * as ChatSubscriber from '../../user/chatSubscribers/interfaces';
|
|
3
3
|
import { Chat, File } from '../../../shared/entities/stock';
|
|
4
|
-
import { Persona } from '../../../main';
|
|
5
4
|
export type Entity = Chat;
|
|
6
5
|
export declare const Route = "chat";
|
|
7
6
|
export declare const UpperName = "Chat";
|
|
@@ -30,25 +29,25 @@ export interface IChatBalloon {
|
|
|
30
29
|
export type IReport = Pick<Entity, 'email_processed' | 'email_delivered' | 'email_opened' | 'email_clicked'>;
|
|
31
30
|
export interface IPublicFindActiveByOwnerIdResponse {
|
|
32
31
|
last_group_report?: IReport;
|
|
33
|
-
owner_id
|
|
34
|
-
document_header_id
|
|
32
|
+
owner_id: string;
|
|
33
|
+
document_header_id: string;
|
|
35
34
|
chat: IChatBalloon[];
|
|
36
35
|
}
|
|
37
|
-
export interface
|
|
38
|
-
persona
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
36
|
+
export interface IPublicFindBySubscriberId {
|
|
37
|
+
persona: ChatSubscriber.IFindChatSubscriberPersona;
|
|
38
|
+
owner_id: string;
|
|
39
|
+
document_header_id: string;
|
|
40
|
+
store_operator_name: string;
|
|
41
|
+
document_total?: number;
|
|
42
42
|
chat: IChatBalloon[];
|
|
43
43
|
}
|
|
44
44
|
export interface IPublicClientWebAppFindActiveByOwnerIdResponse {
|
|
45
45
|
personas: ChatSubscriber.IFindChatSubscriberPersona[];
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
store_operator_name
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
chat_type?: IChatType;
|
|
46
|
+
owner_id: string;
|
|
47
|
+
document_header_id: string;
|
|
48
|
+
store_operator_name: string;
|
|
49
|
+
document_total: number;
|
|
50
|
+
chat_type: IChatType;
|
|
52
51
|
chat: IChatBalloon[];
|
|
53
52
|
}
|
|
54
53
|
export interface ICreateRequest {
|
|
@@ -76,7 +75,7 @@ export interface IMarkAllClientReadUnreadRequest {
|
|
|
76
75
|
export interface IRepository {
|
|
77
76
|
findActiveByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IPublicFindActiveByOwnerIdResponse>;
|
|
78
77
|
clientWebAppFindActiveByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IPublicClientWebAppFindActiveByOwnerIdResponse>;
|
|
79
|
-
findActiveBySubscriberId(params: IShared.IFindByOwnerIdRequest): Promise<
|
|
78
|
+
findActiveBySubscriberId(params: IShared.IFindByOwnerIdRequest): Promise<IPublicFindBySubscriberId>;
|
|
80
79
|
resendLast(params: IShared.IFindByOwnerIdRequest): Promise<void>;
|
|
81
80
|
create(data: ICreateRequest): Promise<Chat>;
|
|
82
81
|
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<void>;
|
|
@@ -75,9 +75,6 @@ export interface IDeletePersonaRequest {
|
|
|
75
75
|
id: string;
|
|
76
76
|
new_main_persona_id?: string;
|
|
77
77
|
}
|
|
78
|
-
export interface IFindContactPersonaByOwnerId extends Pick<Persona, 'id' | 'name' | 'email' | 'telephone'> {
|
|
79
|
-
chat_type: IChatType;
|
|
80
|
-
}
|
|
81
78
|
export interface IFindByEmailRequest {
|
|
82
79
|
email: string;
|
|
83
80
|
}
|
|
@@ -126,7 +123,6 @@ export interface IFindForGmailResponse {
|
|
|
126
123
|
export interface IRepository {
|
|
127
124
|
findById(selector: IShared.IFindByIdRequest): Promise<IEntityExtended | null>;
|
|
128
125
|
findByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IFindByOwnerIdResponse[]>;
|
|
129
|
-
findContactPersonaByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IFindContactPersonaByOwnerId>;
|
|
130
126
|
create(data: ICreateRequest): Promise<IEntityExtended>;
|
|
131
127
|
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<IEntityExtended | null>;
|
|
132
128
|
deleteOne(params: IDeletePersonaRequest): Promise<IEntityExtended | null>;
|
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.102",
|
|
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.8",
|
|
33
|
-
"@types/node": "^24.10.
|
|
34
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
35
|
-
"@typescript-eslint/parser": "^8.
|
|
33
|
+
"@types/node": "^24.10.7",
|
|
34
|
+
"@typescript-eslint/eslint-plugin": "^8.53.0",
|
|
35
|
+
"@typescript-eslint/parser": "^8.53.0",
|
|
36
36
|
"eslint": "^9.39.2",
|
|
37
37
|
"eslint-config-prettier": "^10.1.8",
|
|
38
38
|
"eslint-import-resolver-typescript": "^4.4.4",
|