This is a migrated thread and some comments may be shown as answers.

Binding Checkbox

0 Answers 88 Views
MVVM
This is a migrated thread and some comments may be shown as answers.
Mohammad
Top achievements
Rank 1
Mohammad asked on 06 Oct 2012, 07:27 AM
I have one dropdwonlist in my view i want to when change dropdownlist list many checkbox and id change again save the state
Roles:<select id="roles" data-bind="source: roles, value: role" data-text-field="roleName" data-value-field="roleId" ></select>
</div>
 $(document).ready(function({
            var viewModel kendo.observable({
                roles[  {
                    roleName:"Admin",
                    roleId:1
                },
          {
              roleName:"user",
              roleId:2
          }],
                Accesses:[{
                    accssesName:"read",accessMode:true},
                    {accssesName:"Write",accessMode:false},
                       {accssesName:"Delete",accessMode:false}
                ]
                
            });

            kendo.bind($("#example")viewModel);
            var roles=[
                {
                    roleName:"Admin",
                    roleId:1
                },
                 {
                     roleName:"user",
                     roleId:2
                 }
            ];
            var roledataSource=  new kendo.data.DataSource({
                roles:roles
            });
        });

No answers yet. Maybe you can help?

Tags
MVVM
Asked by
Mohammad
Top achievements
Rank 1
Share this question
or