blob: 64626c8e87bfad325d376b27ba54d1517ec656c4 [file] [log] [blame]
kumaran.m3b4814a2020-05-01 19:48:54 +05301/*
2 Copyright 2020 TATA ELXSI
3
4 Licensed under the Apache License, Version 2.0 (the 'License');
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15
16 Author: KUMARAN M (kumaran.m@tataelxsi.co.in), RAJESH S (rajesh.s@tataelxsi.co.in), BARATH KUMAR R (barath.r@tataelxsi.co.in)
17 */
18
19/**
20 * @file Model for user related information.
21 */
22
23/** Interface for UserDetails */
24export interface UserDetails {
25 userDetail: UserDetail[];
26}
27
28/** Interface for UserDetail */
29export interface UserDetail {
30 username: string;
31 password?: string;
32 _id?: string;
33 projects: string[];
34 _admin?: Admin;
35 modified: string;
36 created: string;
37 identifier: string;
38 projectListName?: string;
39 project_role_mappings?: ProjectRoleMappings[];
40}
41
42/** Interface for user role mappings */
43export interface UserRoleMap {
44 project_role_mappings?: ProjectRoleMappings[];
Barath Kumar R42fe05d2021-01-29 16:02:34 +053045 remove_project_role_mappings?: ProjectRoleMappings[];
kumaran.m3b4814a2020-05-01 19:48:54 +053046}
47
48/** Interface for Admin */
49interface Admin {
50 salt: string;
51 created: number;
52 modified: number;
53}
54/** Interface for UserDetail */
55export interface UserData {
56 username: string;
57 projects: string;
58 modified: string;
59 created: string;
60 identifier: string;
61}
62
63/** Interface for Project Roles Mappings */
64export interface ProjectRoleMappings {
65 project?: string;
66 project_name?: string;
67 role?: string;
68 role_name?: string;
69}