2021-12-20 17:21:19 +00:00
|
|
|
import { UserViewModel } from '@/portainer/models/user';
|
|
|
|
|
|
|
|
export function createMockUser(id: number, username: string): UserViewModel {
|
|
|
|
return {
|
|
|
|
Id: id,
|
|
|
|
Username: username,
|
|
|
|
Role: 2,
|
|
|
|
EndpointAuthorizations: {},
|
2023-11-22 01:21:07 +00:00
|
|
|
UseCache: false,
|
2021-12-20 17:21:19 +00:00
|
|
|
PortainerAuthorizations: {
|
|
|
|
PortainerDockerHubInspect: true,
|
|
|
|
PortainerEndpointGroupInspect: true,
|
|
|
|
PortainerEndpointGroupList: true,
|
|
|
|
PortainerEndpointInspect: true,
|
|
|
|
PortainerEndpointList: true,
|
|
|
|
PortainerMOTD: true,
|
|
|
|
PortainerRoleList: true,
|
|
|
|
PortainerTeamList: true,
|
|
|
|
PortainerTemplateInspect: true,
|
|
|
|
PortainerTemplateList: true,
|
|
|
|
PortainerUserInspect: true,
|
|
|
|
PortainerUserList: true,
|
|
|
|
PortainerUserMemberships: true,
|
|
|
|
},
|
|
|
|
RoleName: 'user',
|
|
|
|
Checked: false,
|
|
|
|
AuthenticationMethod: '',
|
2023-02-19 04:17:50 +00:00
|
|
|
ThemeSettings: {
|
|
|
|
color: 'auto',
|
|
|
|
},
|
2021-12-20 17:21:19 +00:00
|
|
|
};
|
|
|
|
}
|