-
Use built in pipes, Title case pipe, Date pipe to transform data (‘Manage’ page) Write a custom pure pipe to combine and give full name given user (‘Manage’ page) Write a custom pure pipe to show ‘Active’ or ‘Deleted’ based on ‘isDeleted’ property of user
-
Create http services for below and replace existing mock service data with http service Get all users
-
Make changes to application button clicks in ‘Active’, ‘Deleted’ to use delete and activate through API
-
Use Angular Reactive forms for Create/Update user forms implementation
Run ng serve
for a dev server. Navigate to http://localhost:4200/
. The app will automatically reload if you change any of the source files.
Run ng generate component component-name
to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module
.
Run ng build
to build the project. The build artifacts will be stored in the dist/
directory. Use the --prod
flag for a production build.
Run ng test
to execute the unit tests via Karma.
To get more help on the Angular CLI use ng help
or go check out the Angular CLI README.
Run npm install
Execute "npm run start loadUsersData" to run the app with initial data
OR
Execute "npm run start" to run the app with existing data in the database
Get All Users
(GET) http://localhost:8080/users
Get User By Id
(GET) http://localhost:8080/users/:id
Create User
(POST) http://localhost:8080/users/
body : {
firstName: string;
lastName: string;
login: string;
password: string;
age: number;
isDeleted?: boolean;
}
Update User
(PUT) http://localhost:8080/users/:id
body : {
password: string;
age: number;
isDeleted?: boolean;
}
Delete User
(DELETE) http://localhost:8080/users/:id
Search Users ( case insensitive )
(POST) http://localhost:8080/users/search
body : {
key: string;
limit: number;
}
Get All Groups
(GET) http://localhost:8080/groups
Get Group By Id
(GET) http://localhost:8080/groups/:id
Create Group
(POST) http://localhost:8080/groups/
body : {
name: string;
permissions: Array<string>;
}
Update Group
(PUT) http://localhost:8080/groups/:id
body : {
permissions: Array<string>;
}
Delete Group
(DELETE) http://localhost:8080/groups/:id
Get All Users Groups
(Get) http://localhost:8080/groups/users
Add Users To Groups
(POST) http://localhost:8080/groups/:id/users
body : Array<userId>
yarn test OR npm run test