KnockoutJS bindings not working

Ok getting frustrated on this one.... Using knockoutJS to do some visual interaction stuff.

What I have is a button that is going to make an AJAX call to validate some data. That call sends back a CanProceed property as well as an object that represents other view settings. The code works when I set CanProceed(true) this turns on a DIV that has more DIVs inside it, each of those visibility properties are bound to a Permissions.AllowXXX that is set from the server.

See the fiddle for an example

http://jsfiddle.net/RcCAx/

What I want to have happen is when I get the Permissions from the server I should be able to tell knockout about the object and have the page UI update but its not working. If I declare the observable first (like with the CanProceed property) it works, but if I try and use the ko.mapping.fromJS(serverdataobject) here its not updating stuff that was bound to it earlier.

Help......

Answers


See updated fiddle for a solution. The key here is to have Permissions be an observable


Need Your Help

using scipy.optimize.fmin_bfgs for logistic regression classifier leads divide by zero error

python numpy data-mining logistic-regression

I'm trying to implement my binary logistic regression classifier and I decided to use scipy.optimize.fmin_bfgs to minimize the objective function (loglikelihood) as stated in the following formula:...

Message Oriented Middleware for Mobile Device Development

android blackberry jms xmpp mom

I would like to write a application for mobile devices (blackberry and android). Is there a (free) client to connect to a MOM? The MOM should guarantee message delivery even if the connection is cl...