Sorry I have corrected my errors.
The problem now is that my field  ctx.user.data is not modified...



function FormController(){
    this.user = {
    name: "ALBATOR",
    valide: true,
    data : "TEST"
    }
}

FormController.prototype = {
    fetchdata: function () {
        this.user.data = "Loading...";
        var d = loadJSONDoc("http://search.twitter.com/search?
q=artyprog");
        var x = this;
        var gotMetadata = function (ctx, meta) {
            alert(ctx.user.name);
            ctx.user.data = meta.results[0].text;
        };
        var metadataFetchFailed = function (err) {
            alert("The metadata for MochiKit.Async could not be
fetched :(");
        };
        d.addCallback(gotMetadata, this);
        d.addErrback(metadataFetchFailed);

    },
    save: function () {
        alert(angular.toJson(this.user));
    }
}

-- 
You received this message because you are subscribed to the Google Groups 
"MochiKit" group.
To post to this group, send email to mochikit@googlegroups.com.
To unsubscribe from this group, send email to 
mochikit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/mochikit?hl=en.

Reply via email to