kendo-ui

Kendo UI - Turning Text() enclosed text into <span> encoded HTML

不打扰是莪最后的温柔 提交于 2019-12-13 06:27:39
问题 I am trying to add style to title of a panel bar that comes with Kendo UI and I want to break this pure text of Blah-1 Blah-2 into 2 span blocks so it outputs html as <span>Blah-1</span> and <span>Blah -2</span> How do I achieve that with the following? @(Html.Kendo().PanelBar() .Name("panelBar") .Items(panelBar => { panelBar.Add().Text("Blah-1 Blah-2") }) ) I've tried to encode <span> within Text() but it doesn't escape html tags. 回答1: The Encode method allows you to stop HTML encoding (done

how to add a new row with pre defined data in kendo grid?

旧街凉风 提交于 2019-12-13 06:26:48
问题 I'm trying to add a new row to a kendo grid with selected data from another kendo grid. Its showing a blank row but no data. Here is my code: var PunishmentGridDataSource = new kendo.data.DataSource({ schema: { model: { id: "DICP_ACTN_TYPE_CODE", fields: { DICP_ACTN_TYPE_SLNO: { editable: false }, DICP_ACTN_TYPE_CODE: { editable: false }, DICP_ACTN_TYPE_NAME: { editable: false } } } }, pageSize: 5, data: [ { DICP_ACTN_TYPE_SLNO: "1", DICP_ACTN_TYPE_CODE: "1", DICP_ACTN_TYPE_NAME:"aa" }] });

Filter local Kendo datasource based on other attribute of selected value in dropdown list

这一生的挚爱 提交于 2019-12-13 06:25:36
问题 I have a LOCAL Kendo datasource which has the following values: var dataSourceSearchOperators = new kendo.data.DataSource({ data: [ { OPERAND: "=", DATATYPE: "num", INFO: "Equal", OPERATOR: "eq" }, { OPERAND: "<>", DATATYPE: "num", INFO: "Not Equal", OPERATOR: "nq" }, { OPERAND: ">", DATATYPE: "num", INFO: "Greater Than", OPERATOR: "gt" }, { OPERAND: "CW", DATATYPE: "text", INFO: "Contains Word", OPERATOR: "contains" }, { OPERAND: "CP", DATATYPE: "text", INFO: "Contains Partial", OPERATOR: ""

Kendo numeric textbox range validator message

笑着哭i 提交于 2019-12-13 06:18:05
问题 Kendo numberic textbox is not showing my Range validator message. It Always showing "Please enter a value less than or equal to 100." But i want to change it to my defined message. How can i change range validator message? How can i show my defined message "Length should be 1-100"? Code: [Required(ErrorMessage = "Enter length")] [Range(1, 100, ErrorMessage = "Length should be 1-100")] public double? Length { get; set; } Required errormessage ("Enter length") is showing properly but range

A button in a kendo ui grid doesn't work on mobile device

一笑奈何 提交于 2019-12-13 06:13:33
问题 I have an example, a kendo ui grid is added with Backbone.js. In the kendo ui grid I have a buttons to remove rows, but the buttons don't work on mobile devices. If I press a button repeteadly, it sometimes works. Why? I declare the button in kendoGrid.columns so: { command: [{ name: "destroy", text: "Remove", className: "ob-delete" } To remove a row and do something when button is clicked: $(document).on("click", ".grid tbody tr .ob-delete", function (e) { var item = grid.dataItem($(this)

Set title and additional properties to kendo ui grid

▼魔方 西西 提交于 2019-12-13 06:13:23
问题 I am using kendo ui grid to display data. I want to set title for the grid.Is there any way to set it. Also I want to set some additional/custom property for grid which will help to identify the grid uniquely. Any custom property I can set to grid so I can get its value when required. So in case if there are more instances on grid this will help. Please suggest on this. 回答1: Iterating through all your tables can be done using: $.each($(".k-grid"), function (idx, grid) { // Do whatever you

Binding DataViz chart (Bar chart) locally using Angular

你说的曾经没有我的故事 提交于 2019-12-13 06:05:11
问题 I want to implement a kendo DataViz chart i.e., Bar chart locally using Angular binding, also i want to show bars of different colours as shown in the image: Kindly advice me how to implement. A sample was created here http://plnkr.co/edit/?p=catalogue 回答1: Start with something like this: HTML: <body ng-app="app" ng-controller="myCtrl"> <div kendo-chart k-options="barOptions" /> </body> JavaScript: var app = angular.module('app', ['kendo.directives']); app.controller("myCtrl", function(

Bootstrap / KendoUI / LocalHost Works Fine, But Not Domain Name

耗尽温柔 提交于 2019-12-13 05:59:00
问题 I have a web application using bootstrap and Kendo UI togethor on the same page. THe page looks perfect most of the time, but I noticed a problem after deploying to a Test Web Server. Can anyone please help me figure out why the formatting is off for IE 9 when using a domain name, and not localhost? For (http://localhost) (Running from VS 2012) Chrome: Works; FireFox: Works; IE 9: Works For (http://webtrgws01:1200/) Chrome: Works; FireFox: Works; IE 9: Not Working For (http://localhost:1200/)

Filter for “UnitPrice” and “ProductID” column

99封情书 提交于 2019-12-13 05:58:14
问题 I wanted to filter UnitPrice and ProductID . This is the sample, you want more using the jsfiddle link. Check this jsfiddle for more detail & work my program in that //change event $("#category").keyup(function () { var selecteditem = $('#category').val(); var kgrid = $("#grid").data("kendoGrid"); selecteditem = selecteditem.toUpperCase(); var selectedArray = selecteditem.split(" "); if (selecteditem) { }); var orfilter = { logic: "or", filters: [] }; var andfilter = { logic: "and", filters:

Kendo Grid: getting an instance in a Angular directive

落爺英雄遲暮 提交于 2019-12-13 05:43:10
问题 this follows directly on from this question (with an additional question hence I thought should be a new post?) The link above shows how to get a grid instance in Angular (thanks to Lars) So, following on from this last example, I now have added the following directive.. <body> <div data-ng-app="app"> <div data-ng-controller="Grid as vm"> <div id='aa'> <div pckendo id='bb' kendo-grid='grid' k-options="vm.options"></div> </div> </div> </div> </body> and in the .js added angular .module("app",