Skip to content

Commit 6d29a5c

Browse files
committed
Updated readme.md file
1 parent f73d1d1 commit 6d29a5c

File tree

1 file changed

+16
-6
lines changed
  • samples/features/json/todo-app/nodejs-express4-rest-api

1 file changed

+16
-6
lines changed

samples/features/json/todo-app/nodejs-express4-rest-api/README.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,16 +46,26 @@ To run this sample, you need the following prerequisites.
4646
3. From Visual Studio, open the **TodoApp.xproj** file from the root directory,
4747

4848
4. Locate db.js file in the project, change database connection info in createConnection() method to reference your database. the following tokens should be replaced:
49-
4.1. SERVERNAME - name of the database server.
50-
4.2. DATABASE - Name of database where Todo table is stored.
51-
4.3. USERNAME - SQL Server login that can access table data and execute stored procedures.
52-
4.4. PASSWORD - Password associated to SQL Server login.
49+
1. SERVERNAME - name of the database server.
50+
2. DATABASE - Name of database where Todo table is stored.
51+
3. USERNAME - SQL Server login that can access table data and execute stored procedures.
52+
4. PASSWORD - Password associated to SQL Server login.
53+
54+
```
55+
var config = {
56+
server : "SERVER.database.windows.net",
57+
userName: "USER",
58+
password: "PASSWORD",
59+
// If you're on Azure, you will need this:
60+
options: { encrypt: true, database: 'DATABASE' }
61+
};
62+
```
5363

5464
5. Build project using Ctrl+Shift+B, right-click on project + Build, or Build/Build Solution from menu.
5565

5666
6. Run sample app using F5 or Ctrl+F5. /todo Url will be opened with a list of all Todo items as a JSON array,
57-
6.1. Open /api/Todo/1 Url to get details about a single Todo item with id 1,
58-
6.2. Send POST, PUT, or DELETE Http requests to update content of Todo table.
67+
1. Open /api/Todo/1 Url to get details about a single Todo item with id 1,
68+
2. Send POST, PUT, or DELETE Http requests to update content of Todo table.
5969

6070
<a name=sample-details></a>
6171

0 commit comments

Comments
 (0)