-
FEATURED COMPONENTS
First time here? Check out the FAQ!
I am intenting do an interface like:
zkdemo/grid/inlinerowediting
But with Users from my database, the problem is that: i have my DAO and i have a method to find all Users, And when i do click in the edit Button i need 2 texboxes to password and retypePassword, and i need verify each texbox, to do the seim, and later save in my database.
I have:
<template name="editable">
<row>
<textbox
value="@load(each.languageContribution.Name)
@save(each.languageContribution.Name, before='confirm')" />
<textbox
value="@load(each.languageContribution.password)
@save(each.languageContribution.password, before='confirm')" />
value="@load(each.languageContribution.Repassword)
@save(each.languageContribution.Repassword, before='confirm')" />
<textbox
value="@load(each.languageContribution.role)
@save(each.languageContribution.role, before='confirm')" />
<checkbox
value="@load(each.languageContribution.enabled) @save(each.languageContribution.enabled, before='confirm')" />
But i have errors because in my class User i do not have RePassword and if i created a model with List<users> users and List<string> Repasswords.
I do not know how i can load the Users with the passwords and Repasswords, and how can i Verify if the password is equal to Repassword.
Thanks
May be the following links will help you ?
You can use form binding, and a form validator, to validate dependent attributes. If you don't want to add a Transient field to your Entity class, you can wrap the Entity by a Ui object (UiUser in the example below).
Please refer to this fiddle where I provide an example putting it all together.
Asked: 2013-09-22 03:30:13 +0800
Seen: 16 times
Last updated: Sep 23 '13