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. Image for the cookie policy date

InlineFormTemplate Grid Validation

Hi All.

There is an issue with the Inline Form Template and the Grid Validation, I manage to follow the validation that is setup in the grid but the only thing is that the validation is just field by field, the form doesn't alert or show all the validations at once.

Can you help to find out how to show all the warning messages of the form just in one go when I try to save or edit?

Thanks in advance, the example is attached.

Attachment: SampleInlineForm_7b5669d7.zip

1 Reply

VN Vignesh Natarajan Syncfusion Team February 15, 2019 12:04 PM UTC

Hi Nestor, 
 
Thanks for contacting Syncfusion support.  
 
Query: “Can you help to find out how to show all the warning messages of the form just in one go when I try to save or edit?” 
 
From your query, we understand that you are facing issue while showing the validation in inlineform template. We have analyzed the provided sample and we are able to reproduce the reported issue at our end. In your inline form template definition, we have found that you have defined the input elements as div’s. But we have processed the form elements as table and tr and td. Hence the reported issue occur. To overcome the reported issue, we suggest you to define the template definition of inline form template as table tr and td.  
 
Refer the below code example 
 
<script id="templateVehicle" type="text/template"> 
        <input type="hidden" id="VehicleCode" value="{{:VehicleCode}}" /> 
        <input type="hidden" id="EmployeeId" value="{{:EmployeeId}}" /> 
        <input type="hidden" id="VehicleId" value="{{:VehicleId}}" /> 
        <input type="hidden" id="Colour" value="{{:Colour}}" /> 
        <input type="hidden" id="DaysinYear" value="{{:DaysinYear}}" /> 
        <input type="hidden" id="Daysavail" value="{{:Daysavail}}" /> 
        <input type="hidden" id="ManufactureYear" value="{{:ManufactureYear}}" /> 
        <input type="hidden" id="EmployeePackageId" value="{{:EmployeePackageId}}" /> 
        <input type="hidden" id="EmployerId" value="{{:EmployerId}}" /> 
        <table cellspacing="10"> 
            <tr> 
                <td style="text-align: right;">Make & Model: 
                </td> 
                <td style="text-align: left"> 
                    <input type="text" class="textbox" id="VehicleMake" value="{{:VehicleMake}}" /> 
                </td> 
            </tr> 
            <tr> 
                <td style="text-align: right;">Vehicle FBT Type: 
                </td> 
                <td style="text-align: left"> 
                    <select id="Model" name="Model" data-selected="{{:Model}}"> 
                        <option value="">-- Select --</option> 
                    </select> 
                </td> 
            </tr> 
            <tr> 
                <td style="text-align: right;">Lease 1st Held Date 
                </td> 
                <td style="text-align: left"> 
                    <input type="text" class="textbox date" id="PurchaseDate" value="{{:PurchaseDate}}" /> 
                </td> 
            </tr> 
            <tr> 
                <td style="text-align: right;">FBT Base Value: 
                </td> 
                <td style="text-align: left"> 
                    <input type="text" class="textbox currency" id="PurchasePrice" value="{{:PurchasePrice}}" /> 
                </td> 
            </tr> 
            <tr> 
                <td style="text-align: right;">Fuel Card No: 
                </td> 
                <td style="text-align: left"> 
                    <input type="text" class="textbox number" id="ShellCardNo" value="{{:ShellCardNo}}" /> 
                </td> 
            </tr> 
            <tr> 
                <td style="text-align: right;">Rego: 
                </td> 
                <td style="text-align: left"> 
                    <input type="text" class="textbox" id="Rego" value="{{:Rego}}" /> 
                </td> 
            </tr> 
            <tr> 
                <td style="text-align: right;">State: 
                </td> 
                <td style="text-align: left"> 
                    <select id="StateReg" name="StateReg" data-selected="{{:StateReg}}"> 
                        <option value="">-- Select --</option> 
                        <option value="ACT">ACT</option> 
                        <option value="NSW">NSW</option> 
                        <option value="NT">NT</option> 
                        <option value="QLD">QLD</option> 
                        <option value="SA">SA</option> 
                        <option value="TAS">TAS</option> 
                        <option value="VIC">VIC</option> 
                        <option value="WA">WA</option> 
                    </select> 
                </td> 
            </tr> 
……………………………………………………………………………………………………. 
            <tr> 
                <td style="text-align: right;">FBT Year: 
                </td> 
                <td style="text-align: left"> 
                    <select id="EffectiveFBTYear" name="EffectiveFBTYear" data-selected="{{:EffectiveFBTYear}}"> 
                        <option value="">-- Select --</option> 
                    </select> 
                </td> 
            </tr> 
 
        </table> 
 
        
    </script> 
 
 
For your convenience we have modified  the sample which can be downloaded from below link 
 
 
Please get back to us if you have further queries. 
 
Regards, 
Vignesh Natarajan  


Loader.
Live Chat Icon For mobile
Up arrow icon