I need to set checkbox in a view. I created an Enum for this, the checkbox consist of 3 values. I need to bind this to the database. how can i do that.?

asked 19 Feb, 04:04

SajinL's gravatar image

SajinL
115
accept rate: 0%


Graphite does not automatically bind view elements directly to the database. This is because that type of "forms based" development promotes improper software development patterns. However, in order for you to get the list of of check boxes that you have selected to show up as input in the OnClick... behavior, you have to have the Checkbox Field as an Input in the Start shape.

FieldName of type Enumeration which is a list and is not required

This and the other fields will be automatically added to the inputs (of the Start shape) if the "Form to Submit" was set before clicking the "Add Behavior" link next to the OnClick property of the Button. If you missed doing that you still can create these inputs using the "Add Form" link in the Start shape of the OnClick behavior.

link

answered 20 Feb, 01:54

ChrisG's gravatar image

ChrisG
1001k314366
accept rate: 57%

The properties of the Checkbox Field you have added in the View has one property called "Choices". Choose the Enumeration in the property. Two more drop-down fields will appear below when you choose the Enumeration. In the first drop-down choose the property of Enumeration that you want to display has the checkboxes.

Also, the Enumeration you created becomes a table in the database that contains the enumerations as the data rows.

link

answered 20 Feb, 00:47

ChrisG's gravatar image

ChrisG
1001k314366
accept rate: 57%

edited 20 Feb, 00:48

That i have done already and the choices are displayed in the browser. when i run this, i checks 2 check boxes and 1 left unchecked among 3. How does graphite store the checked values in DB.

link

answered 20 Feb, 01:29

SajinL's gravatar image

SajinL
115
accept rate: 0%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×2
×1

Asked: 19 Feb, 04:04

Seen: 182 times

Last updated: 20 Feb, 01:54

Powered By:   Graphite