This is a migrated thread and some comments may be shown as answers.

No confirmation on Grid Row Delete when using MVVM

1 Answer 122 Views
MVVM
This is a migrated thread and some comments may be shown as answers.
Keith
Top achievements
Rank 1
Keith asked on 08 May 2013, 10:07 AM
Hi,

I have a Kendo grid and am using MVVM binding, I have CRUD operations defined. Everything works fine with out exception I never get a confirmation message when deleting a row.

I have the Grid editable property set to:
editable: { "mode": "popup" }

If I change this to:
editable: "popup"

Then I successfully get the delete confirmation message.

However I need to retain the first method as I want to use a template like below:
editable: { "mode": "popup", "template": $("#popup_editor").html() },

Any ideas why the confirmation message doesn't appear.  Also If I do the following
editable: { "mode": "popup", confirmation: "Are you sure" }

Then it functions correctly.  I'd prefer not to have to do this for localisation reasons.

Thanks,
Keith

1 Answer, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 10 May 2013, 08:58 AM
Hi Keith,

Thank you for getting in touch with us.

I am afraid that this is the default behaviour:
  1. If the editable is set to string, the confirmation will be enabled;
  2. If the editable is set to object, the confirmation will be disabled. To enable it you should set a confirmation message. 
    editable: { "mode": "popup", "confirmation": "Are you sure" }

The behaviour is not related to Kendo MVVM, it occurs no matter if the Grid is bound to a ViewModel or not.

Kind regards,
Alexander Valchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
MVVM
Asked by
Keith
Top achievements
Rank 1
Answers by
Alexander Valchev
Telerik team
Share this question
or