Hi,
I'm having trouble using a ReplaceOptions on a ajaxSelect-based
selectbox.
ReplaceOptions adds the new option correctly but then the functions
called on ajax-based on-change event aren't being fired. Do I need to
rebind the ajaxSelectbox?
I call 'ReplaceOptions' like this:
def selectPools = ("0", S.?("base_pool_msg_choose_pool")) ::
(user match {
case Full(u)=> Privilege.findViewablePools(
u.id).map(
p => (p.toString, AccessPool.find(p).get.getName)).toList
case _ => Nil
})
if(privilegeSaved && user.isDefined) {
Distributor !
Distributor.AllowUserInPool(
user.get.id.is,
p.id.is)
logger.info("ACCESS: " + S.?
("base_pool_msg_new_pool",name))
SetValById(theInput, "") &
ReplaceOptions("edit_pool", selectPools, Full("0")) &
DisplayMessage("messages", <b>{S.?
("base_pool_msg_new_pool",name)}</b>, 3 seconds, 2 seconds)
The Ajax selectbox is used in a bind.
bind("edit", in,
"pool" -%> ajaxSelect(adminPools, Empty, p => {pool = p;
poolId.set(p.toLong);
redisplay() //
redisplay pooluser and pool detail
},
"id" ->
editPoolName),
Thanks,
D.
Co-Project Lead / Apache ESME
http://cwiki.apache.org/confluence/display/ESME/Index
--
You received this message because you are subscribed to the Google Groups "Lift" group.
To post to this group, send email to
lif...@googlegroups.com.
To unsubscribe from this group, send email to
liftweb+u...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/liftweb?hl=en.