jQWidgets Forums

Forum Replies Created

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • in reply to: Edition data on nested grids Edition data on nested grids #94270

    damianp
    Participant

    Hello Hristo,

    Base on http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/nestedgrids.htm
    I’ve created simple demo.

    See on Plunker

    scenario:
    1. Expand two rows.
    2. Edition of ShippedDate depends on ShipCountry – iseditable attached to column ShippedDate.

    var iseditable = function (row, datafield, columntype, value) {
      var country = $('#whichNestedGrid').jqxGrid('getrowdata', row).ShipCountry;
      if (country === 'USA') {
    	return true;
      }
      return false;
    }

    Which Nested Grid is currently edited? From which “id” (#whichNestedGrid) I should get row data?

    Regards

    in reply to: Edition data on nested grids Edition data on nested grids #94188

    damianp
    Participant

    Hello Hristo,

    Thank you for response. I see that demo earlier, but my problem is different.
    I have opened two nested grids see that demo. And I have expanded two rows, next I want to make changes on one of nested grid.
    Nested grids was created with the same columns collection.
    When I have cellbeginedit = function (row, datafield, columntype, value) I see that there is row number, which column name, type and value.
    But I need to know from which nested jqxGrid event was fired up.

    Regards
    damianp


    damianp
    Participant

    Hello ppatel,

    My Angular 4 CLI setup.
    package.json
    dependencies on "jqwidgets-framework": "^4.6.2",

    .angular-cli.json

    "styles": [
            "assets/css/bootstrap.min.css",
            "assets/css/bootstrap-theme.min.css",
            "../node_modules/jqwidgets-framework/jqwidgets/styles/jqx.base.css",
            "../node_modules/jqwidgets-framework/jqwidgets/styles/jqx.metro.css",
            "styles.css"
          ],
    "scripts": [
            "assets/js/jquery-3.2.1.min.js",
            "assets/js/bootstrap.min.js",
            "../node_modules/jqwidgets-framework/jqwidgets/jqxangular.js",
            "../node_modules/jqwidgets-framework/jqwidgets/jqxcore.js",
            "../node_modules/jqwidgets-framework/jqwidgets/jqxdata.js",
            ...
    

    Additionaly index.ts:

    /// <reference path="../../node_modules/jqwidgets-framework/jqwidgets-ts/jqwidgets.d.ts" />
    export * from './app.component';
    export * from './app.module';

    Then import in app.module.ts looks that:
    import {jqxGridComponent} from '../../node_modules/jqwidgets-framework/jqwidgets-ts/angular_jqxgrid';

    @NgModule({
      declarations: [
        AppComponent,
        jqxGridComponent,

    Regards

Viewing 3 posts - 1 through 3 (of 3 total)