Dialog Template Editing Validation
Good morning,
I have an issue when I have applied the validation to the Dialog Template Form of the grid.
There is validation on the Contact Name, Contact Telephone and Contact Type as these are the required fields. The error messages appears, however, when text is entered in the input box the error message is not disappearing and it is blocking the other input boxes. I have attached a screenshot of this to show exactly what I mean.
I notice that there is a code segment to insert, however, I have placed this a couple of different places and it doesn't seem to work. I have attached my code for the Dialog Form Template for my grid and would fully appreciate if you could have a look and see where the issue lies.
Thanks,
Frankie
Attachment: CodeSegment_cff65e9a.zip
- Share the stack trace details, if you face any script errors in console.
- Share the Essential Studio version details.
- Share your referred JQuery version details.
- If possible reproduce the issue in the attached sample.
Hi Thavasianand S.
When I first load up the dialog template box there is no data in any of the fields. If I clicked submit the validation messages appear, if I then go and populate the fields with data the validation messages do not disappear once they are populated.
Its like the validation messages are stuck when they are visible and won't disappear which is subsequently blocking the view of other input boxes. We need the validation messages to disappear once the input box has been populated or filled in.
Thanks,
Frankie
- Share the stack trace details, if you face any script errors in console.
- Share the Essential Studio version details.
- Share your referred JQuery version details.
- If possible reproduce the issue in the previously attached sample.
1. Stack trace:
2. Upgraded to the latest Syncfusion MVC (15.3.0.33)
3. Upgraded to the latest jQuery (3.2.1)
|
<script id="CreateNewContact" type="text/template">
<form id="ContactForm">
----
</form>
</script>
|
|
<script id="CreateNewContact" type="text/template">
<div class="container">
<div class="row">
<div class="e-rowcell">
---
</div>
</div>
<div class="row">
<div class="e-rowcell">
---
</div>
</div>
<div class="row">
<div class="e-rowcell">
---
</div>
</div>
<div class="row">
<div class="e-rowcell">
---
</div>
</div>
</div>
</script>
|
|
@(Html.EJ().Grid<object>("FlatGrid")
.Datasource((IEnumerable<object>)ViewBag.datasource)
---
.AllowPaging()
.Columns(col =>
{
---
})
.ClientSideEvents(eve => { eve.ActionComplete("complete"); })
)
</div>
<script type="text/javascript">
function complete(args) {
if ((args.requestType == "beginedit" || args.requestType == "add") && args.model.editSettings.editMode == "dialogtemplate") {
if (args.requestType == "add" || args.requestType == "beginedit") {
//Set Syncfusion Inputs
$("#OrderID").ejMaskEdit({
width: "100%", height: "42px", htmlAttributes: { name: "OrderID" },
change: function validatemsgRemove(e) {
this.wrapper.next().css('display', 'none'); // remove the validation message
}
});
----
}
</script>
|
Hi Thavasianand S.
Thanks for that! The validation messages are disappearing now when I input text into the input boxes.
One last question, you seem to have solved all but 1 of the console errors. I am still getting this one:
Any ideas how to solve this one?
Much appreciated
Thanks,
Frankie
|
@(Html.EJ().Grid<object>("FlatGrid")
// .Datasource((IEnumerable<object>)ViewBag.datasource) // if we comment the dataSource property then we able to reproduce your reported issue
---
.Columns(col =>
{
--
})
)
|
- Do you face above issue in initial rendering or while saving the data in Grid?
- Share exact scenario or proper replication procedure to reproduce the issue.
- If possible share the sample or reproduce the issue in the attached sample.
- 7 Replies
- 2 Participants
-
FM Frankie Moran
- Oct 2, 2017 10:35 AM UTC
- Oct 12, 2017 02:50 PM UTC