insert rows in kendogrid dynamically

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
Post Reply
swiftinitpvtltd
Posts: 370
Joined: Sat Apr 28, 2018 3:33 am
Location: India
Contact:

insert rows in kendogrid dynamically

Post by swiftinitpvtltd »

I am trying to use
https://www.telerik.com/forums/add-row-in-kendo-grid

I want to Dynamically insert rows in aware im kendo grid via javascript with data like
{ id: 1, name: "Jane Doe", age: 30 } and it partially works.
Its giving me kendo
Object name not specified in sync_kendo_data_action when row focus is changed.
Row gets inserted and I can see it but when row loses focus it gives above error.
swiftinitpvtltd
Posts: 370
Joined: Sat Apr 28, 2018 3:33 am
Location: India
Contact:

Re: insert rows in kendogrid dynamically

Post by swiftinitpvtltd »

Need it like this add click-
http://dojo.telerik.com/@korchev/eRoSA
customaware
Posts: 2401
Joined: Mon Jul 02, 2012 12:24 am
Location: Ulaanbaatar, Mongolia

Re: insert rows in kendogrid dynamically

Post by customaware »

Why can't you just call a process that creates records with dummy data and Auto Refresh the grid every time the process is called?
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Image
swiftinitpvtltd
Posts: 370
Joined: Sat Apr 28, 2018 3:33 am
Location: India
Contact:

Re: insert rows in kendogrid dynamically

Post by swiftinitpvtltd »

Thanks mark. Thats a good idea.
Actually I want to achieve bulk copy paste like the one below-
So I got the data in json and it inserts row but causes grid sync issues.
This bulk copy paste is great for excel import. So you have inline edit grid, you copy paste, save inline edits and done.

Now id I can send this data to process thats fine too.
and then I read grid again.
I tried
AwareApp.createOrUpdateObject('mybo',null,newRecord,function (objectId, objectVersion){alert('test')});
this works with simple plain text attributes
But it does not work for me when I have referenced attributes to insert.

https://dojo.telerik.com/ItAsEfAN
I am almost close but not working.
customaware
Posts: 2401
Joined: Mon Jul 02, 2012 12:24 am
Location: Ulaanbaatar, Mongolia

Re: insert rows in kendogrid dynamically

Post by customaware »

Assume you want to create a dynamic number of MyBO Records....


When you click the Add Button, ENTER NEW a NP BO called CreateCounter_NP with an Attribute called HowMany. User enters say, 20.

BO Rule ......WHile Loop On

Condition
CreateCounter_NP.HowMany>0

Action:
CREATE MyBO WITH MyBO.DataA='Some Text',MyBO.NumbericData=10
INCREASE CreateCounter_NP.HowMany BY -1
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Image
Post Reply