You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
portainer/app/react/components/UsersSelector/UsersSelector.mocks.ts

32 lines
854 B

import { UserViewModel } from '@/portainer/models/user';
export function createMockUser(id: number, username: string): UserViewModel {
return {
Id: id,
Username: username,
Role: 2,
EndpointAuthorizations: {},
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: '',
ThemeSettings: {
color: 'auto',
},
};
}