I am using kendo UI sortable without grid in my application. But it seems IE browser is not compatible for it. Our application is using AngularJS with select and ng-repeat. I was able to get it work for Chrome and Firefox but not with IE. Below is the code snippet for HTML
<select class="form-control" kendo-sortable k-on-end="endHandler(kendoEvent)"
k-placeholder="placeholder" k-hint="hint" id="favorite_reports" selectedClass= "selected"
multiple ng-model="favoriteReports.chosenReports">
<option ng-repeat="link in config.links">
{{link.NAME}}
</option>
</select>
JS:
$scope.endHandler = function (e) {
var sortable = e.sender;
// prevent the sortable from modifying the DOM
e.sender.draggable.dropped = true;
e.preventDefault();
// update the model and let Angular update the DOM
$timeout(function () {
$scope.$apply(function () {
$scope.config.links.splice(
e.newIndex, 0, $scope.config.links.splice(e.oldIndex, 1)[0]
);
});
});
};
$scope.placeholder = function (element) {
return element.clone().addClass("placeholder").text("drop here");
};
$scope.hint = function (element) {
return element.clone().addClass("hint");
};
And when I use ul and li instead of select, sortable function is not working as expected in chrome, IE and other browsers as well. When I try to drag one element, next element from the queue has the index change and couple of other issues.
Could you please give me a working example for kendo with sortable functionality (not grid) which uses select and ng-repeat and works for ALL THE BROWSERS as well as AND we can disable the sortable functionality onClick on list for other functionality.
Also onClick, I was trying to get the e.currentTarget.selectedOptions.length value which is having the issue with IE saying as selectedOptions is undefined and chrome is working as expected.
Also I am trying to achieve "multiple" for onClick functionality to remove from the list and add it to other list. (FYI)
Please let me know, if there is any example links or code snippet which works for all browser.
Thanks in advance,
Sujatha
Hello,
I'm trying the Kendo UI with lastest version and I'm facing to an issue using the TreeList component under Chrome (80.0.3987.122).
Please see the attached screenchot, coupling kendo ui 2020.1.219 with jQuery 3.4.1, the height of the first row is not initialized correctly.
You can run this demo here: https://dojo.telerik.com/EsobuqAH
Note it works under FireFox.
Any Idea ?
Thx.
Julien.
I want to create a dropdownlist named 'font size' that helps a user select font size out of the values lets say 12 pt, 14 pt, 16 pt....and so on.
These list items should not all appear with the same font size but should rather appear with a font size they represent. For example - 12 pt must show in 12 pt size, 14 pt in 14 pt size and so on.
Is it possible to show different list items in a dropdownlist in different font sizes? If yes, then how?
Thanks in anticipation.
Hi,
As my title says, Im trying to bind MVVM attributes to command buttons in a KendoGrid. At the moment im struggling with binding an 'enabled' attr.
Dojo: https://dojo.telerik.com/AXojaNuT
In the above, I've bound the enabled state to a command button but it only makes the button look disabled, its still clickable.
Please advise.
Thanks,
Grant
public
class
BasicInformation
{
[Display(Description =
"Patient's height"
, Name =
"Height (Inches):"
)]
[Required(AllowEmptyStrings =
false
, ErrorMessage =
"Height requires a value to be entered."
)]
[Range(12, 96)]
public
double
Height {
get
;
set
; }
}
BasicInformation bi =
new
BasicInformation();
return
View(
"Step2"
, bi);
@(Html.Kendo().NumericTextBoxFor<
double
>(model => model.Height)
.Name("txtHeight")
.Decimals(0)
.Format("##")
)@Html.EditorFor(model => model.Height)
I'm kind of new to JQuery, Json, MVC and all so my problem is probably simple to fix but for some reason, I can't seems to find the answer.
I'm trying to use the Kendo DropDownList to call an MVC action that takes a parameters and sends a query to an ElasticSearch server. So far I have this code :
$('#myInput').kendoDropDownList({
template: $("#inputTemplate").html(),
dataValueField: 'Id',
dataTextField: 'FullName',
filter: 'contains',
minLength: 3,
dataSource: {
serverFiltering: true,
transport: {
read: {
url: '@(Url.Action("ElasticSearch", "Participant"))',
dataType: 'json',
contentType:'application/json; charset=utf-8',
data: {
critere: 'bob'
}
}
}
}
});
This is actually working .... if I only want to search for "bob". But I can't figure out how to send the text from the seach field in the dropdownlist each time that I type something.
What am I missing here?
I've looked at the DevExpress HTML grid, and when switching pages when AJAX-bound, the vertical scroll is put to the top. I don't know anyone who would want to stay vertically scrolled to the bottom when switching to another grid page.
When using Kendo AJAX-bound grid and switching pages, the vertical scrollbar stays where it was on the previous page. Is this a bug or did you just let that be something we have to do ourselves?