...
This step generates controls that are bound to the createOrderDetail data source by . You can render the controls as you wish but will always generate an XML document conforming to the XML schema above. Here's what our form looks like:
Create/Update business rules
- Click the icon in the toolbar at the top of the Form Designer.
- Click the Edit icon for the Show Customers rule we created in Example 4. Change the name to Show Customers/Products.
- In the Rule text area: copy and paste the following:
...
Finally, we connect the createOrderDetails document to the database query defined above. See Doc URl Wizards for help on the steps below.
- Click on the Doc Action button Form Properties icon in the toolbar at the top of the form.
- In the dialog box that appears click on 'Select the Document Actions tab and the Send Data sub-tab.
- Select Manually set document URIs'.A new dialog box will appear. Navigate to the desired document (createOrderDetail) by clicking the Next button twice
- You should see the Document name 'createOrder', which is the data source we are interested in.
- Set the Write URL to: http://localhost:8082/database/BIRT/createOrderDetail
- Leave the Read method empty.
- Set the Write method to POST.
- Click the Finish Submit button.
When the form is submitted, will issue an HTTP POST request to the above URL sending the createOrderDetail XML document in the payload. The database connector will map this to the <create> operation of the createOrderDetail query that we defined above, will use the data in the XML document to resolve the query. Since there are multiple line items, the query will be executed once for each Order line item thereby inserting the multiple line items for an Order.
...