This project was generated with Angular CLI version 16.0.2.
Run npm install
to install dependencies for a Node.js
Run ng serve
for a dev server. Navigate to http://localhost:4200/
. The application 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.
Run ng test
to execute the unit tests via Karma.
Run ng e2e
to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.
To get more help on the Angular CLI use ng help
or go check out the Angular CLI Overview and Command Reference page.
-
building the docker file from the root folder docker build -t us-east1-docker.pkg.dev/shoppertrak-repo/java-competency-demo-ui:latest .
-
Run from local docker run --env API_URL="https://webapi-dev.appname.com" -dp 8080:80 us-east1-docker.pkg.dev/shoppertrak-repo/java-competency-demo-ui:latest
This Angular application primarily deals with car-related operations. It loads car brands and models from the following URLs: These are available on GCP and Azure both.
- Private brands URL (GCP): "http://35.193.88.251/v1/data/brands"
- Private brands URL (Azure): "http://40.88.227.104/v1/data/brands"
- Car models URL (Azure): "http://40.88.227.104/v1/data/cars/"
- Car models URL (GCP): "http://35.193.88.251/v1/data/cars/"
When a user adds an item to the cart, a backend application named "CartApplication," written in Spring Boot, handles the process. The /add
endpoint is called, and in the backend,
it checks whether the product is available in the inventory database. If the product is found, it is added to the SQL database, which is maintained by the CartApplication.
To remove an item from the cart, the /remove
endpoint of the CartApplication is called. Item will be removed from the database as well.
User can increase and decrease the quantity of the particular item while placing the order.
To place an order, the /order
endpoint of the OrderApplication is called. When an order is successfully placed, a message is received, and the corresponding item is removed from the cart database.
- Get Cart Items:
http://localhost:9094/cart/get
- Place Order:
http://localhost:9090/orders
- Remove from Cart:
http://localhost:9094/cart/remove
- Add to Cart:
http://localhost:9094/cart/add
We have integrated sonar in our project for inspection of code quality to perform automatic reviews with static analysis of code to detect bugs, code smells, and security.
Execute the following Maven command to run Sonar analysis:
mvn clean verify sonar:sonar