We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

BeforeBatchSave not work to the update syncfusion version

Thread ID:

Created:

Updated:

Platform:

Replies:

121940 Feb 10,2016 03:35 PM UTC Feb 11,2016 11:09 AM UTC ASP.NET Web Forms 1
loading
Tags: Grid
Roimer Machacón Otero
Asked On February 10, 2016 03:35 PM UTC

Hi, we're using syncfusion grid. In this day we update the version of the 12.2.0.36 to 12.4.0.34. Now testing the features we found that BeforeBatchSave in the grid not working in this new version.

Here is the code used for us:

"Aspx"

<script type="text/javascript">

function actualizarRecursos(args) {
        console.log("Entra actualizar recursos");
        return ActualizarRecursoDetalleControl(document.getElementById('<%= txtNumeroControlLabores.ClientID%>').value, document.getElementById('<%= txtCodigoPlanAccion.ClientID%>').value, document.getElementById('<%= txtCodigoDetallePlanAccion.ClientID%>').value, JSON.stringify(args.batchChanges));
        }

</script>

<ej:Grid ID="gvsRecurso" runat="server" AllowGrouping="false" AllowSelection="true" TabIndex="-1" Locale="es-ES"
                                    Selectiontype="Single" AllowSorting="True" AllowPaging="True" AllowFiltering="false"
                                    RowSelected="filaRecursoSeleccionada" BeforeBatchSave="actualizarRecursos" BatchDelete="limpiarCabeceraRecurso">
                                    <PageSettings PageSize="10" />
                                    <EditSettings AllowAdding="false" AllowEditing="True" AllowDeleting="True" EditMode="Batch"></EditSettings>

                                    <FilterSettings FilterType="FilterBar" FilterBarMode="OnEnter" />
                                    <GroupSettings EnableDropAreaAutoSizing="False"></GroupSettings>
                                    <Columns>
                                        <ej:Column Field="linearec_recursorep" IsPrimaryKey="true" HeaderText="<%$ Resources:ControlLabores, idRecurso %>" Width="10%" />
                                        <ej:Column Field="tiporec_recursorep" IsPrimaryKey="true" HeaderText="<%$ Resources:ControlLabores, codTipo %>" Width="10%" />
                                        <ej:Column Field="nombretiporec_recursorep" IsPrimaryKey="true" HeaderText="<%$ Resources:ControlLabores, nomTipoRecurso %>" Width="16%" />
                                        <ej:Column Field="idrec_recursorep" IsPrimaryKey="true" HeaderText="<%$ Resources:ControlLabores, codRecurso %>" Width="12%" />
                                        <ej:Column Field="nombrerec_recursorep" IsPrimaryKey="true" HeaderText="<%$ Resources:ControlLabores, nombreRecurso %>" />
                                        <ej:Column Field="cantidadrec_recursorep" HeaderText="<%$ Resources:Generales, cantidad %>" Width="9%" EditType="Numeric" />
                                    </Columns>
                                    <ToolbarSettings ShowToolbar="true" ToolbarItems="edit,delete,update,cancel,search"></ToolbarSettings>
                                </ej:Grid>

Jayaprakash Kamaraj [Syncfusion]
Replied On February 11, 2016 11:09 AM UTC

Hi Roimer,
From 12.4.0.34 version onwards, we need to give client side events  in ClientSideEvents, which is an inner Property of Grid .So, we suggest to use BeforeBatchSave event in ClientSideEvent property. Please refer to the following code example, online demo sample and sample.
Code Example:

<ej:Grid ID="Grid1"    AllowPaging="True"

  Locale="en-US"

               runat="server">

            <ClientSideEvents BeforeBatchSave="actualizarRecursos"  />

            <Columns>

                <ej:Column Field="OrderID" IsPrimaryKey="true" HeaderText="Order ID"    TextAlign="Right" Width="90" />

                <ej:Column Field="CustomerID" HeaderText="Customer ID"   Width="100"  />

                <ej:Column Field="EmployeeID" HeaderText="Employee ID" HeaderTemplateID="#employeeTemplate" TextAlign="Right" Width="110"  />

                <ej:Column Field="Freight" HeaderText="Freight"  TextAlign="Right" Width="90" Format="{0:C}" />

                <ej:Column Field="OrderDate" HeaderText="Order Date" Width="100" HeaderTemplateID="#dateTemplate" TextAlign="Right" Format="{0:MM/dd/yyyy}" />

                <ej:Column Field="ShipCity" HeaderText="Ship City" Width="100" />

            </Columns>

                <EditSettings AllowEditing="True" AllowAdding="True" AllowDeleting="True" EditMode="Batch"></EditSettings>

            <ToolbarSettings ShowToolbar="True" ToolbarItems="add,edit,delete,update,cancel"></ToolbarSettings>

        </ej:Grid>

    </div>

        </div>

</asp:Content>

<asp:Content ID="ScriptContent1" ContentPlaceHolderID="ScriptContent" runat="server">

<script type="text/javascript">


    function actualizarRecursos(args) {

        console.log("Entra actualizar recursos");


        }


</script>


</asp:Content>


Online Demo sample: http://asp.syncfusion.com/demos/web/grid/events.aspx

Sample: http://www.syncfusion.com/downloads/support/forum/121940/ze/121940-2138099320

Regards,
Jayaprakash K.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;