From 2b3d576ba29f9c937799e8243510ae25baf7edf8 Mon Sep 17 00:00:00 2001 From: Andreas Eberhart Date: Mon, 21 Oct 2024 17:05:37 +0200 Subject: [PATCH] remove reference to EJS --- dashjoin-docs/docs/faq.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/dashjoin-docs/docs/faq.md b/dashjoin-docs/docs/faq.md index fc24d92b1..8c40ecd9d 100644 --- a/dashjoin-docs/docs/faq.md +++ b/dashjoin-docs/docs/faq.md @@ -6,8 +6,6 @@ * **I have an object with special characters in the field names (e.g. a SQL query result). How can I access this field in JSONata?** In [JSONata](https://docs.jsonata.org/simple#navigating-json-objects), field names can be escaped using back-ticks (`). Click [here](https://demo.my.dashjoin.com/#/page/html) for a live example. -* **I have an object with special characters in the field names (e.g. a SQL query result). How can I access this field in the HTML widget?** The HTML widget uses [EJS](https://ejs.co/), which allows embedding JavaScript templates in HTML. In Javascript, you can access non-alphanummeric field names as follows: `object["field.name"]`. Click [here](https://demo.my.dashjoin.com/#/page/html) for a live example. - * **How can I customize the forms in the edit, button and variable widgets?** The layout editor allows you to graphically edit the "input" widgets' settings. Note that not all features of the component are exposed in the WYSIWYG editor. You can leverage the advanced features by editing the underlying JSON directly in Dashjoin Studio. This [online playground](https://dashjoin.github.io/) lets you experiment with the various features. The demo application shows two examples. The "createSchema" of the [customer page](https://github.com/dashjoin/dashjoin-demo/blob/main/model/dj-database/dj%252Fnorthwind.json) section shows the form of the email button, which displays the email body input field with a larger text box. The city instance page shows a similar layout for the edit widget. The [variable example](https://github.com/dashjoin/dashjoin-demo/blob/main/model/page/variable.json) shows how a select widget with display names and values can be rendered. * **How can I use values from the database in the edit, button and variable widgets?** This can be achieved by combining the JSON Schema Form extension mechanism described in the section above with the [API](api.md). In the example below, all values from the table test in the DB sql are retrieved. The jsonata expression projects the column id to be used as the auto-complete choices in the input field.