Skip to content

Latest commit

 

History

History
62 lines (41 loc) · 1.97 KB

02_node_introduction_to_incident_management_application.md

File metadata and controls

62 lines (41 loc) · 1.97 KB

Incident Management Application

In this exercise we assume we are a developer given the task to implement an application to create and manage incidents, that is customer support messages. The application will allow customers to create incidents, processed by support team members. Both add comments to a conversation. Eventually, a repair appointment is created with a service worker assigned.

Create a new project

To create a new CAP project, you can use the cds init command. This command creates the needed project configuration for you to start developing your application. Since this exercise is about creating a simple incident management application, the project name will be incidents-mgmt.

Use the following command in the terminal:

cds init incidents-mgmt

Load the project in the editor

Now, it's time to load our IDE and access the newly created directory. You can open the project folder incidents-mgmt in your choice of IDE

In BAS:

  1. Go to Explorer -> Open Folder

Open Folder

  1. Choose incidents-mgmt from the file explorer.

Open Application

Basic CAP structure containing folder app, db and srv has been created.

Open the terminal and use the command:

npm install

to install the dependencies.

Start the CAP server by using cds watch in the Integrated Terminal.

cds watch

The CAP server serves all the CAP sources from your project. It also "watches" all the files in your projects and conveniently restarts whenever you save a file. Changes you have made will immediately be served without you having to do anything.

Currently, it will show

No service definitions found in loaded models...

It tells you that there is no model and no service definitions yet that it can serve.

We will be adding the service definitions in the upcoming modules.


Proceed with the next step: Domain modeling