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

Grid inside tabstrip visualizazion problem

0 Answers 22 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.
Banca del Ceresio
Top achievements
Rank 1
Banca del Ceresio asked on 12 Jun 2012, 03:39 PM
Hi everybody,

I have a problem with the visualization inside my grid, what happens is that the first line of the grid put the edit and delete command on to separate line, and I cannot understand what I'm doing wrong :/, I post you the code and attach the image of the strange behaviour.

here is my view
@model ZygosMVC.Areas.BaseData.CreditorModel
@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    Html.Telerik().TabStrip()
        .Name("TabStrip")
        .Items(tabstrip =>
        {
            tabstrip.Add()
                .Text("Creditor")
                .Content(@<text>
                    <fieldset>
                        @Html.HiddenFor(model => model.CreditorId)
                        <div class="editor-label">
                            @Html.LabelFor(model => model.LastName)
                        </div>
                        <div class="editor-field">
                            @Html.EditorFor(model => model.LastName)
                            @Html.ValidationMessageFor(model => model.LastName)
                        </div>
                        <div class="editor-label">
                            @Html.LabelFor(model => model.FirstName)
                        </div>
                        <div class="editor-field">
                            @Html.EditorFor(model => model.FirstName)
                            @Html.ValidationMessageFor(model => model.FirstName)
                        </div>
                    </fieldset>
                </text>);
            tabstrip.Add()
                        .Text("Pagamento")
                        .Content(@<text>
                            @(Html.Telerik().Grid(Model.BankPostLinks)
                                .Name("BankPost")
                                .DataKeys(k => k.Add(r => r.BankPostId).RouteKey("BankPostId"))
                                .ToolBar(commands => commands.Insert().ButtonType(GridButtonType.BareImage).ImageHtmlAttributes(new { style = "margin-left:0" }))
                                .Columns(columns =>
                                {
                                    columns.Bound(bp => bp.PaymentTypeId);
                                    columns.Bound(bp => bp.AccountNumber);
                                    columns.Bound(bp => bp.IBAN);
                                    columns.Command(commands =>
                                    {
                                        commands.Edit().ButtonType(GridButtonType.BareImage);
                                        commands.Delete().ButtonType(GridButtonType.BareImage);
                                    }
                                        );
                                })
                                .DataBinding(dataBinding => dataBinding.Ajax()
                                                .Insert("Insert", "Creditor")
                                                .Update("Update", "Creditor")
                                                .Delete("Delete", "Creditor"))
                                .Scrollable(s => s.Height(200))
                                .Editable(editing => editing.Mode(GridEditMode.PopUp))
                                    )
  
                        </text>);
        })
        .SelectedIndex(0)
        .Render();

can somebody tell me what i'm doing wrong?
thank you raphael
Tags
Grid
Asked by
Banca del Ceresio
Top achievements
Rank 1
Share this question
or