JQueryField is one of the most powerful components in CloudIO Platform. This can be used to integrate any JavaScript/JQuery form component with a page.

Java Script

This property takes a javascript that should implement the below methods. Check JQueryField Plugin for some sample implementations.

{
    /* the following methods are called by the platform */
    onRender: function (target, index) {
        // called only once when the field is rendered
        this.parent = target; // the parent DOM Element
        this.index = index; // the index of this JQueryField within the parent.. in this case it will always be 0
    },
    onLoad: function () {
        // fired when this JQueryField is loaded into the DOM (on page active, tab click etc.)
    },
    onUnload: function () {
        // fired when this JQueryField is removed from the DOM (on page inactive, tab hide etc.) ...
        // remove any listeners here and add them back in onLoad
    },
    onResize: function (width, height) {
        // fired when this JQueryField is resized by the parent container
    },
    setValue: function (value) {
        // may get called multiple times
    },
    getValue: function () {
        // will be called by the platform during onblur even to update the value back into the model
    },
    setReadOnly: function (readonly) {
        // may get called multiple times
    },
    setTabIndex: function (readonly) {
        // called only once when the field is rendered
    },
    /* the following methods are available for this javascript code to invoke */
    updateValue: function (value) {
        // updates the value back into the model
    },
    doblur = function (e) {
        // performs an update to the model & removes the x-form-focus css class from this field
    },
    dofocus = function (e) {
        // set's the x-form-focus css class on this field
    }
}

 

Location

101 California Street, Suite 2710
San Francisco, CA 94111


440 N. Wolfe Rd.
Sunnyvale, CA 94085


Office 11, 5th Floor, Building 9,
Mindspace IT Park
Hyderabad 500081

p: +1 (844) AT CloudIO (844-282-5683)
f: +1 (650) 300-5247 | e: sales@cloudio.io
© 2009, 2017 CloudIO Inc. | Terms of Use | Privacy Policy