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

[Solved] Route Value from DropDownList in Delete Command

3 Answers 119 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
JULIA
Top achievements
Rank 1
JULIA asked on 04 Aug 2010, 04:13 PM
Hello,

is there a way to achive the following goal.

.DataBinding( dataBinding => dataBinding

.Ajax()

 

 

.Delete(

 

"Action", "Controller", new { routeValue = "SelectedValueFromDropDownList" } )

Regards,
Timo

 

3 Answers, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 04 Aug 2010, 05:46 PM
Hi Timo,

To achieve your goal you need yo modify deleteUrl serialized from the server. For instance you can wire the delete button click, get Grid client object and modify deleteUrl placed in its ajax object:
$('.t-grid-delete').click(function(){
var grid = $('#Grid').data('tGrid');
grid.ajax.deleteUrl += '?routeValue=1';
})

Best wishes,
Georgi Krustev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
JULIA
Top achievements
Rank 1
answered on 06 Aug 2010, 01:51 PM
Hello,

the delete button can not found. with the following code the add button will be found but not the delete button.

<script type="text/javascript">
        $(function () {
            $('.t-grid-add').click(function () {
                alert("Click");
            })
  
            $('.t-grid-delete').click(function () {
                alert("Click");
            })
        });
</script>

Regards,
Timo
0
Georgi Krustev
Telerik team
answered on 06 Aug 2010, 02:11 PM
Hello Timo,

It is very strange. I am not sure where could be the problem in this implementation. I will suggest you open a support thread on the matter and attach a simple test project, which we could review.

Sincerely yours,
Georgi Krustev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
JULIA
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
JULIA
Top achievements
Rank 1
Share this question
or