Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
140
No data display using row edit template
posted

Hi,  

There is not data display in the dialog.

View :

            @(Html.Infragistics().Grid<MvcApplication3.Models.Sales.SalesQuotation>()

                  .ID("grid1")
                  .PrimaryKey("QuotationID")
                  .AutoGenerateColumns(false)
      .AutoGenerateLayouts(false)
        .Virtualization(false)
        .LocalSchemaTransform(true)                  
                  .RenderCheckboxes(true)
                  .Columns(column =>
                      {
                          column.For(x => x.QuotationID).HeaderText("ID").DataType("string");
                          column.For(x => x.QuotationDate).HeaderText("Quotation Date").DataType("date").Format("MMM-d-yyyy");
                      })
                    .Features(features =>
                        {
                            features.Sorting().Type(OpType.Local);
                            features.Paging().PageSize(10).Type(OpType.Local);
                            features.Selection().Mode(SelectionMode.Row);
                            features.Updating().EnableAddRow(false).EnableDeleteRow(true)
                                    .EditMode(GridEditMode.RowEditTemplate)
                                    //.RowEditDialogContainment("owner")
            .RowEditDialogWidth("300px")
            .RowEditDialogHeight("270px")
            .RowEditDialogOkCancelButtonWidth("100px")
            .RowEditDialogFieldWidth("150px")                                    
                                    .RowEditDialogRowTemplateID("rowEditDioalogRowTemplate1")
                                    .ColumnSettings( settings =>
                                        {
                                            settings.ColumnSetting().ColumnKey("QuotationID").ReadOnly(true);
                                            settings.ColumnSetting().ColumnKey("QuotationDate");
                                        })
;                        })
                  .DataSourceUrl(Url.Action("GetGridData""SalesQuotation"))
                  .DataBind()
                  .Height("500px")
                  .Width("100%")
                  .Render()
                  )
        </div>
        
 
 
        @(Html.Infragistics().Loader()
       .ScriptPath(Url.Content("~/Scripts/Infragistics/js/"))
        .CssPath(Url.Content("~/Content/Infragistics/css/"))
        .Resources("igGrid.*")
        .Render()
        )
 
        <style type="text/css">
            .tableBackGround {
                background-color#FF7283;
            }
            .labelBackGround {
                background-color#ffe96d;
            }
        </style>
 
        <script id="rowEditDioalogRowTemplate1" type="text/x-jquery-tmpl">
            <tr class="tableBackGround">
                <td class="labelBackGround"> 
                    ${headerText}
                </td>
                <td data-key= "${dataKey}">
                    <input/>
                </td>
            </tr>
        </script>
 
        <script type="text/javascript">
            $("#grid1").live("iggridupdatingdatadirty"function (event, ui) {
                $("#grid1").igGrid("saveChanges");
                return false;
            });
        </script>

Parents
No Data
Reply
  • 23953
    Offline posted

    Hello Wilson,

    First, sorry for the late answer.

    From the code you provide is hard to say what the problem can be. One possible problem is that "QuotationID" column is with wrong data type. You can try to set it to "number" (since I don't know what type are the fields of your model: MvcApplication3.Models.Sales.SalesQuotation this is a blind guess).

    If this doesn't help you can try to remove the row edit template template by commenting out this line:

    .RowEditDialogRowTemplateID("rowEditDioalogRowTemplate1")
    
    
    If you still cannot resolve your issue please post your model's definition: MvcApplication3.Models.Sales.SalesQuotation so I can create a sample.
    
    
    Best regards,
    Martin Pavlov
    Infragistics, Inc.
Children
No Data