jQWidgets Forums

jQuery UI Widgets Forums Angular ever present row "add" event

This topic contains 5 replies, has 2 voices, and was last updated by  Hristo 4 years, 10 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
  • ever present row "add" event #112476

    ilywanzi
    Participant

    Hi, I am try to use ever present row in my jqxgrid, and I have some questions.
    1. Can I know what event is triggered when I click the “Add” button in every column’s ever present row?
    2. How to disable some columns’ ever present row input filed? I have a grid with 10 columns, but 3 of them are action buttons, so I don’t want to have ever present row input on top of these columns.
    3. About the validation in ever present row, user can see the error message only if they hover on the red text. Is it possible to show the error message similar to the jqxGrid’s validation?
    Thanks!

    ever present row "add" event #112477

    ilywanzi
    Participant

    For the first point I asked, because in ever present row, user can make multiple inputs in different columns first, then click “Add” button from any one of the columns, then a new row with multiple columns’ value will be added. So what I want to know is how to get the whole row’s data after click the “Add” button.
    I search in the document, and tried “getEverPresentRowWidgetValue” inside column’s config, but this one can only get one column’s value.
    Please let me know how to implement this, thanks.

    ever present row "add" event #112480

    Hristo
    Participant

    Hello ilywanzi,

    You could implement to each one column the getEverPresentRowWidgetValue callback and get the needed information.
    Another option is to implement the addrow callback to the jqxDataAdapter’s source:

    var source = {
    	localdata: data,
    	datafields:
    	[
    		{ name: "name", type: "string" },
    		{ name: "productname", type: "string" },
    		{ name: "available", type: "bool" },
    		{ name: "date", type: "date"},
    		{ name: "quantity", type: "number" }
    	],
    	datatype: "array",
    	addrow: function (rowid, rowdata, position, commit) {
    		console.log("addrow", rowdata);
    		// synchronize with the server - send insert command
    		// call commit with parameter true if the synchronization with the server is successful 
    		// and with parameter false if the synchronization failed.
    		commit(true);
    	}
    };

    About the second question I would like to suggest you look at this demo:
    https://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/everpresentcustomization.htm?light

    On the last question, I would like to suggest the option to use a custom jqxTooltip.
    In the validateEverPresentRowWidgetValue you could invoke that tooltip and show it to the user.

    Best Regards,
    Hristo Hristov

    jQWidgets team
    https://www.jqwidgets.com

    ever present row "add" event #112485

    ilywanzi
    Participant

    Hi, Hristo, thanks for your response. It’s help!

    ever present row "add" event #112497

    ilywanzi
    Participant

    Hi, Hristo, could you please provide an example about using tooltip in validateEverPresentRowWidgetValue? Thanks

    ever present row "add" event #112508

    Hristo
    Participant

    Hello ilywanzi,

    We have a similar forum topic:
    https://www.jqwidgets.com/community/topic/geteverpresentrowwidgetvalue-is-not-working/

    Best Regards,
    Hristo Hristov

    jQWidgets team
    https://www.jqwidgets.com

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

You must be logged in to reply to this topic.