I posted this in the JavaScript forum three days ago and have yet to get a response. Maybe someone from Telerik will pay attention if I post it here instead.
I recently created a new project with the latest Kendo code. The project has numerous grids and most of them use filter rows. I do all my grid filtering, sorting, paging, and grouping on the server side using the DataSourceRequest object that the grid passes through the grid's data source read action. I noticed that in the latest version of Kendo, there are four new filter operations: Is Null, Is Not Null, Is Empty, and Is Not Empty. Those seem like good options to have for filtering. The problem is that, in their current form, they're unusable for server side filtering. The filters in the DataSourceRequest object are not providing the critical Member property when using any of the new operations so I have no way of knowing which columns in my database the new filters should be applied to. Can you tell me if you are aware of this issue and, if so, when you will fix it? Also, is there a way to keep those operations (or any of the others for that matter) from showing up in the list of filter operators? Thanks.
I've been using the demo to set up an Image and File browser for my editor.
The image browser seems to be working fine but the file browser doesn't open, I just get the standard window pop up.
I am have added the custom controller code in the same way, inherited and maintained the naming, and using the default routing for my application.
Any ideas of what could be wrong?
VIEW:
@(Html.Kendo().Editor()
.Name("Description")
.ImageBrowser(imageBrowser => imageBrowser
.Image("~/Content/ProjectFiles/" + (Model.RelatedProjectId > 0 ? Model.RelatedProjectId.ToString() + "/" : "") + "{0}")
.Read("Read", "ImageBrowser")
.Create("Create", "ImageBrowser")
.Destroy("Destroy", "ImageBrowser")
.Upload("Upload", "ImageBrowser")
.Thumbnail("Thumbnail", "ImageBrowser"))
.FileBrowser(fileBrowser => fileBrowser
.File("~/Content/ProjectFiles/" + (Model.RelatedProjectId > 0 ? Model.RelatedProjectId.ToString() + "/" : "") + "{0}")
.Read("Read", "FileBrowser")
.Create("Create", "FileBrowser")
.Destroy("Destroy", "FileBrowser")
.Upload("Upload", "FileBrowser"))
)
CONTROLLER
public class FileBrowserController : EditorFileBrowserController
{
private const string ContentFolderRoot = "~/Content/";
private static readonly string[] FoldersToCopy = new[] { "~/Content/shared/" };
etc....
Is there a way to set the background color of all cells in a column across multiple pages of a grid? I have a javascript function that sets the background color, however, as soon as I change pages, my highlighting goes away.
Thanks,
Matt
I have a grid in which one of the columns is a dropdown. I'd like to enable the Multi Filter checkboxes for this column.
How can I do this? If I set Multi to true it just displays the usual dropdown filter menu.
I have a MultiSelectFor using ajax read where I return a list of SelectList Items. Some of the SelectList items have their selected property set to true. The MultiSelect does not display those items as being pre-selected.
I have attached a file showing the View and the Controller code. (in VB)
There has to be a setup issue somewhere. I copied and pasted the Kendo dropdown example.
However the dropdown never calls my method in my controller. It renders on my page(empty).
What am I missing?
@(Html.Kendo().DropDownList()
.Name("myMainName")
.DataTextField("CustomerName")
.DataValueField("CustomerID")
.DataSource(s => {
s.Read(read =>
{
read.Action("GetCustomerList", "MyController");
})
})
.SelectedIndex(0)
)
_Layout
@Scripts.Render("~/bundles/jquery")
@Scripts.Render("~/bundles/kendo")
@Styles.Render("~/bundles/css")
@Styles.Render("~/Content/kendo/css")
BundleConfig
{
public static void RegisterBundles(BundleCollection bundles)
{
bundles.Add(new ScriptBundle("~/bundles/jquery").Include("~/Scripts/jquery-{version}.js"));
bundles.Add(new StyleBundle("~/bundles/css").Include("~/Content/*.css"));
bundles.Add(new ScriptBundle("~/bundles/kendo").Include(
"~/Scripts/kendo/kendo.all.min.js",
// "~/Scripts/kendo/kendo.timezones.min.js", // uncomment if using the Scheduler
"~/Scripts/kendo/kendo.aspnetmvc.min.js"));
bundles.Add(new StyleBundle("~/Content/kendo/css").Include(
"~/Content/kendo/kendo.common-bootstrap.min.css",
"~/Content/kendo/kendo.bootstrap.min.css"));
bundles.IgnoreList.Clear();
}
Here is the code I am using to create the TreeView...
01.
@(Html.Kendo().TreeView()
02.
.Name(
"CategoryTree"
)
03.
.TemplateId(
"TreeViewTemplate"
)
04.
.HtmlAttributes(
new
{ })
05.
.DataTextField(
"Description"
)
06.
.AutoScroll(
false
)
07.
.LoadOnDemand(
true
)
08.
.Events(e => e.Select(
"_CategoryChooserView_OnCategorySelected"
))
09.
.Events(e => e.Expand(
"_CategoryChooserView_OnCategoryExpand"
))
10.
.Events(e => e.Collapse(
"_CategoryChooserView_OnCategoryCollapsed"
))
11.
.Animation(
true
)
12.
//.DataSpriteCssClassField("DataSpriteCSSClass")
13.
.DataSource(d => d
14.
.Model(m => m
15.
.Id(
"CategoryCode"
)
16.
.HasChildren(
"HasChildren"
)
17.
)
18.
.Read(read => read.Action(
"ListSubCategories"
,
"Services"
))
19.
.Events(e => e.RequestEnd(
"_CategoryChooserView_OnCategoryRequestEnd"
))
20.
.Events(e => e.RequestStart(
"_CategoryChooserView_OnCategoryRequestStart"
))
21.
))
After the Treeview is instantiated, I want to call a JavaScript function like this one to expand and select a particular node. The node is not necessarily a top level node - it could be quite a ways down in the hierarchy.
01.
function
_CategoryChooserView_SelectNode(CategoryCode)
02.
{
03.
04.
if
(CategoryCode.length > 0)
05.
{
06.
var
TreeView = $(
"#CategoryTree"
).data(
"kendoTreeView"
);
07.
var
DataItem = TreeView.dataSource.get(CategoryCode);
08.
09.
if
(DataItem)
10.
{
11.
var
Node = treeview.findByUid(DataItem.uid);
12.
treeview.select(Node);
13.
14.
ScrollElementToScrollableParent(Node);
15.
}
16.
}
17.
}
The problem is that DataItem (line 7) comes back undefined every time, no matter what I feed "get()" method. It seems to me that with a client side Treeview that fetches its data from a remote source upon expansion of a node, this can never be possible.
How can I programmatically expand and work my way down to the node I want selected? I somehow need to expand each node down to the target node. Is it even possible?
Hello,
I'm having trouble getting the scheduler to display correctly when using JQuery 2.2.0. The times table is showing beside the days of the week instead of under it.
I've created a simple example here:
http://jsbin.com/lemadiqaju/1/edit?html,output
Any suggestions on how to get the scheduler working correctly?
Thank you.