We use Kendo for ASP MVC and use lots of reusable Kendo windows with inputs, grid etc. in them.
Everytime we use reusable window we have to manually clear validation messages, inputs and grid on window open/close.
Is there any other approach to this problem?
Related
I want to create editable Kendo MVC grid bound to local data(some IEnumerable<>).
I found this and this. But first is only for js and second is not ediatable.
Is it possible?
I have tried all modes of Editable. But Editable() requires to specify related actions and it's impossible to prevent its execution.
As far as I know, editing is not supported with server side binding. In the past, I have used a Template column with links to edit the items. An example:
cols.Template(#<text>Edit</text>)
I wanted to bind a checkboxlist using KendoUI when a modal pop is opened.
On modal popup load I wanted to get data from a webapi which will have json response and bind it to checkbox kendo Ui template.
I referred kendoUI forums all samples are using static data. Can someone please guide me to the right direction where I can consume dynamic data.
Thank you!
There's a lot of ways to approach this.
I think the easiest way would be to use a TreeView with checkboxes configured that only returns a single level of nodes, then just show it in a Window or Dialog as you would show any other view. This way you get decent, default item formatting of the TreeView with having to use a template, but you don't get paging if your datasource is large.
You can also use a ListView with a template that formats the data with a checkbox. This requires a template but you get paging capability. Once again, you just display the ListView in a Window or Dialog as normal.
Here's a simple demo of a ListView implementation: http://dojo.telerik.com/#Stephen/iwOhIV
It is a combination of Kendo demos: http://demos.telerik.com/kendo-ui/dialog/treeview-integration with the TreeView replaced with the ListView from this demo(http://demos.telerik.com/kendo-ui/listview/remote-data-binding) and then the styling tweak with a template that uses checkboxes.
The rest of it is up to you(persisting/loading checked state, etc).
I need to migrate an app to HTML 5 and I'm researching HTML 5 frameworks. So far I have Webix and Kendo ui as the 2 finalists.
Now, each one has something that I need to use and that is better than on the other, so, I was thinking about using both of them if possible.
So far the only related comment I have found is this Webix and KendoUI
There is one thing to consider with regard to styling - Kendo UI uses the content box model, while Webix uses the border box model.
https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Box_Model/Introduction_to_the_CSS_box_model
This can cause problems when nesting components from the two libraries - the ones inside may end up with broken layout due to inherited opposite box model styles.
I'm trying to create some CRUD grids using Kendo UI + Codeigniter and i would like to ask if
anyone knows how to handle the Kendo scripts in the views. Is it better to use a common view
for all grids and pass each time the Kendo script as a paramater to the view or is it better
to use a separate view for each grid and hardcode the Kendo script in the view.
Or is there any better way?
For a web application it would be better to keep its discreteness - so creating separate view for each grid and hardcoding kendo script in the views would be the best option.
The project is MVC 3 with Razor views and JQuery unobtrusive validation. Our web pages are set up with the label above the textbox and the validation message falls under the textbox. Usually the textbox is about 150px wide so the validation message tends to be rather narrow and tall. It doesn't look nice.
I would prefer to utilize the Html.ValidationMessageFor helper to position all of the messages together at the top of the page, preferably in a bulleted list. I haven't found a way to "turn off" the display of the messages that are next to the textboxes, although I can use a validation summary to catch the property errors on submit.
Many of the validations are occurring in popups and we are using Telerik for the popups.
I would prefer to avoid editing the open source js files, if possible.
Remove the Html.ValidationMessageFor() items in your view => this will disable the messages appearing beside your textboxes.
Next, add Html.ValidationSummary(false, "Your Message") at the point that you want the bulleted list to appear (must be within the using(html.BeginForm() call). The false in this Html Helper is an overload that instructs the summary to not exclude property errors. For styling, you will need to do some CSS work.
You might want to look into using the <%: Html.ValidationSummary(true) %> markup. This creates what you're looking for.