Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - sahil.b

Pages: [1]
1
Hi,

I am unable to change/update the value of rowHt.

//--- CODE ---//
    componentDidMount() {
        this.rowHeightManager();
    }

    changeDropDown(e) {
        const rowHt = parseInt(e.target.value, 10);
        jQ(`#${this.props.id}`).pqGrid('option', 'rowHt', rowHt);
        jQ(`#${this.props.id}`).pqGrid('refreshDataAndView');

        // This is updating the value but not reflecting on Grid UI
        console.log(jQ(`#${this.props.id}`).pqGrid('option', 'rowHt'), rowHt);


    }

    rowHeightManager() {
        const $option = [25,50,75].map(item => `<option value="${item}">${item}</option>`).join('');
        const $selectBox = `<select id="changeRowHeight" class="ui-corner-all">${$option}</select>`;
        const $footer = jQ(`#${this.props.id}`).find('.pq-grid-footer.pq-pager');
        $footer.append(`<span class="pq-separator"></span><span class="pq-page-rppoptions">${$selectBox}</span>`);

        $footer.find('#changeRowHeight').on('change', this.changeDropDown.bind(this));
        // console.log($footer);
    }
//--- END CODE---//

The above code will add a dropDown in footer next to pagination section. On changing the value from the dropDown i want the row height to be changed. Is this the correct implementation or could be other way.

Thanks,
Sahil




2
ParamQuery Pro Evaluation Support / Getting error while editing cell
« on: July 27, 2018, 05:55:29 pm »
Hi,

I am using the pq-grid v5.1. On triggering save button i need to get all the changed rows with the help of the $('.selector').pq('getChanges') method and trackModel : { on: true } and  recIndx: "id".

After that i am not able to update the grid. Error is coming when i color the row whole row by col[index].pq_cellattr

Please help and refer to the error below.

Uncaught TypeError: Cannot read property 'split' of undefined
    at e.(:3000/anonymous function).(anonymous function).l.addClass (http://localhost:3000/js/pqgrid.min.js:11:4061)
    at e.cUCData.update (pqgrid.min.js:13)
    at e.(:3000/anonymous function).(anonymous function).l._digestUpdate (http://localhost:3000/js/pqgrid.min.js:10:22060)
    at e.(:3000/anonymous function).(anonymous function).l._digestData (http://localhost:3000/js/pqgrid.min.js:10:21735)
    at e.(:3000/anonymous function).(anonymous function).n.updateRow (http://localhost:3000/js/pqgrid.min.js:13:19267)
    at e.(:3000/anonymous function).(anonymous function).l.saveEditCell (http://localhost:3000/js/pqgrid.min.js:10:19417)
    at HTMLDivElement.<anonymous> (pqgrid.min.js:10)
    at HTMLDivElement.dispatch (jquery.min.js:2)
    at HTMLDivElement.u (jquery.min.js:2)


Thanks,
Sahil

3
Hi,

After adding some coloring to some cells. When i export it to excel. I coloring disappears.

Is there any way to add custom styles for cells that can appear on excel after exporting it.


Thanks,
Sahil

Pages: [1]