jQWidgets Forums

Forum Replies Created

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts

  • Eaton
    Participant

    Any feedback on this issue yet?

    in reply to: CheckBox Column on change event CheckBox Column on change event #89439

    Eaton
    Participant

    The event handle you are looking for is ‘checked’ on the Grid, the Docs you want can be found at the Checkbox API


    Eaton
    Participant

    Thank you very much!!
    This helps me quite a lot.

    Just as a little bit of feedback: I see my source was changed, so what i really wanted was something more like:

    $(document).ready(function () {
        var productList = [{ "id": 11, "family": 1, "name": "Product_A" }, { "id": 14, "family": 1, "name": "Product_B" }];
        var familyList = [{ "id": 1, "name": "Family_A" }, { "id": 2, "name": "Family_B" }];
        var testCycle = { "startDate": "2016-03-08", "product": 11, "endDate": "2016-09-30", "name": "testCycleName", "note": "a Release Cycle.", "version": "xxx", "id": "394d5ca9-e16e-4eb5-9a68-10ccfa8a9845" };
        
        var familySource =
        {
            datatype: "json",
            datafields: [
                { name: 'id' },
                { name: 'name' },
            ],
            localdata: familyList
        };
        var familyAdapter = new $.jqx.dataAdapter(familySource, { autoBind: true });
        
        var productSource =
        {
            dataType: "json",
            dataFields: [
                { name: 'id' },
                { name: 'name' },
                // name - determines the field's name.
                // value - the field's value in the data source.
                // values - specifies the field's values.
                // values.source - specifies the foreign source. The expected value is an array.
                // values.value - specifies the field's name in the foreign source. 
                // values.name - specifies the field's value in the foreign source. 
                { name: 'fieldNameFamily', value: 'family', values: { source: familyAdapter.records, value: 'id', name: 'name' } },
                { name: 'family' }
            ],
            localData: productList
        };
        var productAdapter = new $.jqx.dataAdapter(productSource, { autoBind: true });
        
        var source =
        {
            dataType: "json",
            dataFields: [
                { name: 'id' },
                { name: 'name' },
                { name: 'productName', value: 'product', values: { source: productAdapter.records, value: 'id', name: 'name' } },
                { name: 'familyName', value: 'product', values: { source: productAdapter.records, value: 'id', name: 'fieldNameFamily' } },
                { name: 'product' },
                { name: 'version' },
                { name: 'startDate' },
                { name: 'endDate' },
                { name: 'note' },
            ],
            localData: testCycle
        };
        var dataAdapter = new $.jqx.dataAdapter(source, { autoBind: true });
        var record = dataAdapter.records[0];
        alert('endDate: ' + record.endDate + '\nfamily: ' + record.familyName + '\nproduct: ' + record.productName+ '\nnote: ' + record.note);
    });
Viewing 3 posts - 1 through 3 (of 3 total)