@spytecgps/nova-orm 0.0.70 → 0.0.72
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,4 @@
|
|
|
1
|
+
import { NovaDataSource } from '../../novaDataSource';
|
|
2
|
+
import { Logger } from '../../types/logger';
|
|
3
|
+
import { GetUsersDataParams, UserData } from '../../types/user';
|
|
4
|
+
export declare const getUsersData: (novaDataSource: NovaDataSource, params: GetUsersDataParams, logger: Logger) => Promise<UserData[]>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { User } from '../../entities/user';
|
|
2
|
-
import { CreateUserParams, DeleteUserParams, GetUserByIdParams, GetUsersConfigurationByImeiParams, GetUsersIdsByPhoneAndCountryCodeParams, GetUsersParams, GetUsersWithRolesParams, UpdateUserParams, UserWithRole } from '../../types/user';
|
|
2
|
+
import { CreateUserParams, DeleteUserParams, GetUserByIdParams, GetUsersConfigurationByImeiParams, GetUsersDataParams, GetUsersIdsByPhoneAndCountryCodeParams, GetUsersParams, GetUsersWithRolesParams, UpdateUserParams, UserData, UserWithRole } from '../../types/user';
|
|
3
3
|
import { BaseRepository } from '../baseRepository';
|
|
4
4
|
export declare class UsersRepository extends BaseRepository {
|
|
5
5
|
/**
|
|
@@ -108,4 +108,11 @@ export declare class UsersRepository extends BaseRepository {
|
|
|
108
108
|
* @returns Whether the user was updated or not
|
|
109
109
|
*/
|
|
110
110
|
updateUser(params: UpdateUserParams): Promise<boolean>;
|
|
111
|
+
/**
|
|
112
|
+
* Get users data
|
|
113
|
+
* @param {GetUsersDataParams} params containing information to get users data
|
|
114
|
+
* - filters.imei: The imei of the device to obtain users configurations
|
|
115
|
+
* @returns The array of users data
|
|
116
|
+
*/
|
|
117
|
+
getUsersData(params: GetUsersDataParams): Promise<UserData[]>;
|
|
111
118
|
}
|
package/dist/types/user.d.ts
CHANGED
|
@@ -91,3 +91,31 @@ export interface UpdateUserParams {
|
|
|
91
91
|
lastLoginAt?: Date;
|
|
92
92
|
};
|
|
93
93
|
}
|
|
94
|
+
export interface GetUsersDataParams {
|
|
95
|
+
filters: {
|
|
96
|
+
imei: string;
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
export interface UserData {
|
|
100
|
+
userId: string;
|
|
101
|
+
telephone: string;
|
|
102
|
+
email: string;
|
|
103
|
+
isMetric: boolean;
|
|
104
|
+
timezone: string;
|
|
105
|
+
alertsNotificationOn: boolean;
|
|
106
|
+
speedUnits: string;
|
|
107
|
+
distanceUnits: string;
|
|
108
|
+
alertTypeId: number;
|
|
109
|
+
smsNotification: boolean;
|
|
110
|
+
emailNotification: boolean;
|
|
111
|
+
alertValue: string;
|
|
112
|
+
pushNotification: boolean;
|
|
113
|
+
appNotification: boolean;
|
|
114
|
+
alertMetadata: string;
|
|
115
|
+
deviceName: string;
|
|
116
|
+
deviceTypeId: number;
|
|
117
|
+
clientId: number;
|
|
118
|
+
internationalDirectDialing: string;
|
|
119
|
+
phoneNumbers: string[];
|
|
120
|
+
emailAddresses: string[];
|
|
121
|
+
}
|