Bug in Display of Checkbox Value When Server Connect Data is Reloaded

Wappler 3.0.0 beta 3

This is where you have a checkbox whose value is set by the result of a database query, when that database boolean field contains a value of 1.

Expected Behaviour
If you reload the database query via a server connect, the checkbox is still checked.

Actual Behaviour
The first time the server connect is run, the checkbox is checked.
Subsequent times the server connect is run, the value returned by server connect is still 1 but the checkbox is now shown unchecked.

How to Create

  1. Create a mysql database table with a field boolean_field of type boolean.
  2. Create a server action and server connect test_checkbox to access that field.
  3. Create a checkbox to display the value of boolean_field
  4. Add a button to load the server connect.
  5. Set the value of the boolean_field to 1 in the database
  6. View the page.
  7. Click on the button to load server connect test_checkbox
    The check box is checked.
  8. Click on the button to load server connect test_checkbox again.
    The check box is no longer checked.

Here is the code my example used for displaying the checkbox:

<input id="i_test_checkbox" name="boolean_field" 
   class="custom-control-input input_text" type="checkbox" 
   dmx-bind:checked="test_checkbox.data.test_checkbox.boolean_field" value="1">
Community Page
Last updated: