Guide 01 · Web apps
Build your first app.
You will build a small orders page for Fernleaf Supply: a table that lists orders and a form that adds a new one. Then you save a version and publish it.
On this page
What you will build
One page, two parts, two queries. The table reads the Orders table. The form adds a row, and an alert tells you it worked.
| order | customer | total | status |
|---|---|---|---|
| #10483 | Rohit | $189.00 | Paid |
| #10482 | Harshal | $612.50 | Paid |
| #10481 | Charudatt | $148.00 | Shipped |
| #10480 | Dipak | $42.00 | Shipped |
Create an app
From your workspace home, choose New application and name it Fernleaf orders. Leave Web & BI and Database ticked. A new app starts with one stage, called dev, so nothing you do here is public yet.
Add an Orders table in the Schema builder
Open the Data console, then Data, then the Schema builder. Choose New table, call it Orders and use Add column four times: an order number, the customer, the total and a status.
Drag a Table onto the page and bind it
Back in the app, add a query named getOrders: a connection query on the NoCodeBI Database, with Action type Read on the Orders table. Then drag a Table from the component rail onto the page. In its Build settings, set Source to Query and pick getOrders as the Data source. The same rows are also available to any other part as an expression:
{{ queries.getOrders.data }}Add a form that saves an order
Drag a Form next to the table, drop two Input parts inside it, Customer and Total, and set its submit label to Save order. Add a second query, addOrder, on the same database with Action type Insert on Orders. Then give the form an event: when it is submitted, run the query, then show an alert.
- 1Run queryaddOrder
- 2Show alertOrder saved
- 3Run querygetOrdersoptional
Preview
Open the preview and try it as a visitor would. Fill in the form, press Save order, and check that the alert shows and the new row lands in the table. This is the page in Fig. 1.
Publish your page
Save a version in the builder, then publish it to the dev stage and give it one more look. On Team and Enterprise, add a second stage with Create stage, such as Prod, and publish the same version there. If something goes wrong later, press Go back to on the version you want back.
Next steps
Your orders page works. Make it do more: