kendo-ui

kendo ui select a specifix index/text during first load

大兔子大兔子 提交于 2019-12-04 10:16:43
The problem i am running into is that during the first load of the page i want to read the value from cookies if found, i want to change the theme that was stored in the cookie. not only want to change the them but i also want to select that item in the combo box so that it is in sync with the them that was applied. How can i select a specific item during initial page load, when i am constructing the combobox ? $(document).ready(function () { var initialized = false; // theme chooser drop-down var cmb=$(".themeChooser").kendoDropDownList({ dataSource: [ { text: "Default" }, { text: "BlueOpal"

Send Additional Parameter in Kendo Grid Read Action

妖精的绣舞 提交于 2019-12-04 10:08:34
问题 I have a kendo Grid as follows. @(Html.Kendo().Grid<RevenueModel>() .Name("WeeklyRevenue") .Resizable(resizing => resizing.Columns(true)) .Columns(columns => { columns.Bound(p => p.Number).Width(100); columns.Bound(p => p.Type).Width(100); columns.Bound(p => p.Week1).Format("{0:c}"); columns.Bound(p => p.Week2).Format("{0:c}"); columns.Bound(p => p.Week3).Format("{0:c}"); columns.Bound(p => p.Week4).Format("{0:c}"); columns.Bound(p => p.Week5).Format("{0:c}"); columns.Bound(p => p

Kendo UI and angular - no widget in $scope

旧城冷巷雨未停 提交于 2019-12-04 10:04:53
I'm using Kendo UI version 2014.2.716 with AngularJS version 1.2.27, and I made a grid using a directive <div ng-controller="MyController as ctrl"> <div id="myGrid" kendo-grid k-options="{some options}"></div> <button ng-click="ctrl.doSomething()"></div> </div> I read that if you give a name to the grid (like this: kendo-grid="myGridOnScope"), you can access the widget in the controller scope in this way: myModule.controller('MyController', function($scope) { this.doSomething = function() { console.log($scope.myGridOnScope); } } The console.log should log a widget object, but in my case it's

Change the width of the events in a Kendo UI Scheduler

五迷三道 提交于 2019-12-04 10:03:03
I am creating a website in HTML5 and javascript. One of the site contains the Kendo UI Scheduler . I understand the scheduler and how it works, and I've managed to set up a simple scheduler with some events. Now, my problem is that I want to alter the way the events is drawn in to the scheduler; I want to alter the size of the events to be half the size of the column they are displayed in. Is there any simple way to do this, or do I have to alter the Kendo code that is calculating the position of these events? Since nobody could answer this for me, I'm posting my own solution: I tried doing

Telerik Kendo UI grid: grouping and sorting survive grid.refresh() but collapsed groups get expanded; how to preserve state

北战南征 提交于 2019-12-04 09:43:02
问题 As is typical for grids in a "dashboard" application that monitors dynamically changing data, my (Telerik) Kendo UI grid is refreshed with fresh data periodically, every 60 seconds: grid.dataSource.data(freshData); grid.refresh(); // have been informed this refresh may not be necessary The schema does not change, but some new rows might show up in the dataset and some might have been removed. Although the grid.refresh() leaves the groupings intact, and the sort state is also preserved, any

Kendo UI Grid with Cascading DropDownList

≡放荡痞女 提交于 2019-12-04 09:32:16
问题 I have a Kendo UI Grid on my Razor Layout which fetches data from the controller. In this grid I wish to have a set of 3 DropDownLists which are: ProductGroups , Products , Services The behaviour I wish to implement is, when I Add a row to the Grid, I choose ProductGroups first, and the Products DropDown is updated with products list filtered by GroupId (value). Then select Product and like the first one, update the Services DropDown with services filtered by productId (value). I don't quite

How to show Kendo Grid's columnMenu using script

元气小坏坏 提交于 2019-12-04 09:26:51
The Kendo Grid has a really nice column context menu (aka: columnMenu) which you can access by right clicking on each column header. The menu is enabled by setting the field in the Kendo Grid to: columnMenu: true When the columnMenu is enabled, it displays the columns in the grid and allows you to show/hide columns, sort, and filter on them. However, we have a requirement to move this column menu outside of the grid and tie it to a button. So when the user clicks on a button, the column menu will appear. Is there a way to invoke this via javascript? This request is similar to one made by

Kendo Grid Edit InLine Custom Validation message e.g. for duplicate Names etc

你说的曾经没有我的故事 提交于 2019-12-04 08:16:28
问题 I have an entity Location and I am using the Kendu UI Grid with InLine edit mode. The entity owns a property DisplayName , which is required and must not exist twice in the database. At the moment, it works to display the Required Validation message: And it also works to build up a method CustomValidateModel called in the LocationController Ajax InLine Create method, that checks if the Name is already existing in the database and adds then a ModelError . I catch this error then in the .Events

The Kendo UI directives require jQuery to be available before AngularJS with Kendo grid in routing template with Html5mode

僤鯓⒐⒋嵵緔 提交于 2019-12-04 07:40:40
Why kendo load before Jquery in angular routing template with Kendo grid. I have ordered the scripts, while clicking any event through angular routing templates getting this error in console. Note: In page refresh, scripts loaded properly, the application works fine, not getting any error. Only occurred in event routing. kendo load before jquery why. order scripts : <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.9.1/jquery.js"></script> <script src="https://code.angularjs.org/1.3.8/angular.js"></script> <script src="//kendo.cdn.telerik.com/2016.2.714/js/kendo.all.min.js"></script

kendo ui on-demand RTL support with script

穿精又带淫゛_ 提交于 2019-12-04 06:54:26
问题 I created an Autocomplete form. I followed this simple documentation to create a button together with its click handler script. Clicking this button shall toggle RTL support for the form. I have a problem. When I click the button, it does not toggle RTL support for the form. demo <body> <input type="button" id="toggleRTL" value="Activate RTL Support" class="k-button" /> <script> $('#toggleRTL').on('click', function(event) { var form = $('#speakerForm'); if (form.hasClass('k-rtl')) { form