Telerik Forums
Kendo UI for jQuery Forum
1 answer
197 views
Hi,

We have a grid with many columns with editor templates defined. We also have many custom validations based on the values of these columns.

eg. One column is a drop down with Status and another column is a datepicker with Date.

When we change the Date we want to check the value of the Status dropdown in the custom validation. How can we do this?

Currently when we change the status from StatusOne to StatusTwo, and then change the date field we need to be able to access the current value of StatusID for that row. But it shows the old value of StatusID (StatusOne) when we try to access it via the grid instead of StatusTwo.

                        var gd = $('#gds').data("kendoGrid");
                        var inputName = input.attr("id");
                        var rowIndex = input.context.rowIndex;
                        var StatusID = gd._data[rowIndex].StatusID;

Please let us know how to access the current value.

Thanks,

Sherly
Greg
Top achievements
Rank 1
 answered on 01 Aug 2013
0 answers
144 views
When I give the scheduler event the startTime of "Thu Aug 01 2013 11:00:00 GMT-0700 (Pacific Daylight Time)" the scheduler shows the time as 6PM.

When I give it "Thu Aug 01 2013 18:00:00 GMT-0700 (Pacific Daylight Time)" it shows as 1AM.

I don't know what I am doing wrong, how do I tell the scheduler to show it in the time I want (which is 11AM PST).


UGH - I figured it out, the example had the timezone set:
timezone: "Etc/UTC",
Aaron
Top achievements
Rank 1
 asked on 01 Aug 2013
1 answer
134 views
Hi,
Web page is  freezes when data
is binding to chart. We are using kendoui version “Kendo UI Complete
v2012.2.710”.
Please advise.

Iliana Dyankova
Telerik team
 answered on 01 Aug 2013
5 answers
185 views
When using Firefox, if I set the Font and/or Size, then type a line, the font/size is honored.  As soon as I hit enter the new line being created goes back to the inherited font and size.
Alex Gyoshev
Telerik team
 answered on 01 Aug 2013
1 answer
93 views
We are using Kendo v2013.2.716. I have a simple Treeview on a page, and I have it linked to an onDrop function. In the function, I am checking to make sure the drop is allowed. If it is not allowed, I use e.setValid(false) like you guys have described elsewhere to do. I have confirmed that the e.setValid(false) statement is actually hit. But after I do this, I run console.log(e.valid) , and it seems to still be showing e.valid as true, even though I set it to false. Is this me misunderstanding how it works? Do I need to track an additional isValid variable myself? Just would have figured e.valid would keep the updated validity status. Thanks.
Alex Gyoshev
Telerik team
 answered on 01 Aug 2013
1 answer
99 views
Hello all,

I am working with the very latest kendo release 2013.2.716 and MVC 4 with VS 2012.

 I have a kendo grid and it was decided to remove the buttons for displaying details and achieve this via row click. Easy enough right?

If I have an edit and delete button however, for each row in addition to the row click to show details, how do I exclude the edit and delete buttons from calling the row click instead of the edit or delete functionality? 

Any help is appreciated.
$("#grid tbody").on("click", "tr", showError);
showError.call($("grid tbody tr:first"));
 
   function showError() {
 
          if (documentReady) {
               
              var $this = $(this),
              dataItem = $this.data();
              var id = GetId(dataItem);
              if (id != 0) {                 
                  window.location.href = "/Error/ShowError/" + id;
              }
          }          
   }
   function GetId(item) {
       var items = grid.dataSource.data();
       for (var i = 0; i < items.length; i++) {
           var e = items[i];
           if (e.uid == item.uid) {
               return e.ExceptionLogId;
           }           
       }
       return 0;
   }


Paul

Paul
Top achievements
Rank 1
 answered on 01 Aug 2013
1 answer
110 views
In Kendo StockChart(http://demos.kendoui.com/dataviz/financial/index.html), have observed that dragging the navigator in bottom chart doesn't work always as expected. When I want to narrow down the navigator range,by pulling in either right handle/left handle, instead of narrowing down it moves the navigator range.

Looking at mousemove event handler in this case,shows that it decides whether to drag/narrow down the range,based on target element.
So, in some cases though i start dragging the mouse with pointer on left handle, but mousemove event listener gets the target as selection between leftHandle and rightHandle.

Looks in this case, the cursor width (cursor type e-reisze) is more than handle width and that's causing the issue.

Is there any other better way to handle this scenario that works always?

Also, have seen in some toolkits (nvd3), SVG is used for right/left handle that works very smooth instead of HTML controls. Is there any reason for not using SVG for right/left handle in KendoUI?
T. Tsonev
Telerik team
 answered on 01 Aug 2013
3 answers
202 views
Hi

I'm trying to reproduce the custom editing sample with dropdownlist inside the gridcell.
For some reason, the combo is not created...

I'm attaching the project to this message.

Do I miss any script for the project?

Thank you in advance,
Shabtai
Vladimir Iliev
Telerik team
 answered on 01 Aug 2013
1 answer
170 views
Hello,
I'm going further in my KendoUI discovery... I wish to have a DropDownList while editing a cell on a certain column

my grid is :

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <%: Html.Kendo().Grid(Model)
    .Name("Grid")
    .Columns(columns =>
    {
        columns.Bound(x => x.IDUtente);
        columns.Bound(x => x.Nominativo);
        columns.Bound(x => x.Societa);
        columns.Bound(x => x.Filiale);
        columns.Bound(x => x.Ruolo);
        columns.Bound(x => x.IDStato).Hidden();
        columns.Bound(x => x.Stato).ClientTemplate("StatoID");
    })
    .Editable(editable => editable.Mode(GridEditMode.InCell))
    .Groupable()
   // .Pageable()
    .Sortable()
    .Scrollable()
    .Filterable()
    .DataSource(dataSource => dataSource
        .Ajax().Model(model => model.Id(p => p.IDUtente))
        .ServerOperation(false)
        .Read(read => read.Action("GetListaUtenti", "Administration")
        )
    )
%>
</asp:Content>

and I've created an ascx called StatoID with

<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<int>" %>

<%:@(Html.Kendo().DropDownListFor(m => m).BindTo(new List<SelectListItem>() {
              new SelectListItem() {
                  Text = "Enabled",
                  Value = "1"
              },
              new SelectListItem() {
                  Text = "Disabled",
                  Value = "0"
              }
       
          }).Value(1)
%>

I don't understand where I say to the Grid when in edit use that template...I've downloaded http://www.kendoui.com/code-library/mvc/grid/grid-inline-and-popup-editing-using-cascading-dropdownlists.aspx but it's razor and I'm using ASPX ... anyone can help me?

I wish those data to be loaded from the Controller

I've just got a method (first it would just be enougth to load statically),later my method will be

  [HttpPost]
        public ActionResult GetStati([DataSourceRequest] DataSourceRequest request, int idUser)
        {
            DataAccessAdministration da = new DataAccessAdministration(Global.IDApplication, IDIstituto);

            var res = da.GetStati(idUser);
            return Json(res.ToDataSourceResult(request));
        }

Please help me thanks!
Vladimir Iliev
Telerik team
 answered on 01 Aug 2013
3 answers
85 views
Hello,
Im getting a problem that i can't resolve.

So i have a grid, and in one of the field i have a dropdownlist (filled with an other Datasource)

When i select a data in the dropdownlist it works except when i create a new line, when i select  a data in the dropdownlist, i got in the grid [object Object] 

I'm asking how to put in the grid the data i selected in the dropdownlist (SellToName).

here is my code
DataSource:
var customers = [
          {NUMBER:"P001",SellToName:"test1"},
                {NUMBER:"U001",SellToName:"test2"}
]
 var businessList = [
         { NUMBER: "A5678", SellToCustomerNumber: "NOV" }
]
Grid and DropdownList
$(document).ready(function () {
                
                
                   //chargement customer list format json
                   var customerDataSource = new kendo.data.DataSource({
                        data: customers
                   });
                        
                   //chargement business list format json
                   var businessListDataSource = new kendo.data.DataSource({
                        data: businessList
                   });
                        
                   //on initialise la grid
                   $("#grid").kendoGrid({
                       dataSource: businessListDataSource,
                       pageable: true,
                       navigatable: true,
                       groupable: true,
                       sortable: true,
                       height: 700,
                       toolbar: ["create"],
                       columns: [
                           { field:"NUMBER",title:"Numero"},
                           { field: "SellToName", title: "Nom", editor: numberDropDownEditor },
                           { command: "destroy", title: " ", width: "90px"}],
                       editable: true
                   });
                    
            
                   function numberDropDownEditor(container, options) {
                       $('<input  required="required" data-text-field="SellToName" data-value-field="SellToName" data-bind="value:' + options.field + '"/>')
                       .appendTo(container)
                       .kendoDropDownList({
                           autoBind: false,
                           dataSource: customerDataSource
                       }
                       );
                   }
                    
               });
Thank you.


Kiril Nikolov
Telerik team
 answered on 01 Aug 2013
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
Date/Time Pickers
Spreadsheet
Upload
ListView (Mobile)
ComboBox
TabStrip
MultiSelect
AutoComplete
ListView
Menu
Templates
Gantt
Validation
TreeList
Diagram
NumericTextBox
Splitter
PanelBar
Application
Map
Drag and Drop
ToolTip
Calendar
PivotGrid
ScrollView (Mobile)
Toolbar
TabStrip (Mobile)
Slider
Button (Mobile)
SPA
Filter
Drawing API
Drawer (Mobile)
Globalization
Gauges
Sortable
ModalView
Hierarchical Data Source
Button
FileManager
MaskedTextBox
View
Form
NavBar
Notification
Switch (Mobile)
SplitView
ListBox
DropDownTree
PDFViewer
Sparkline
ActionSheet
TileLayout
PopOver (Mobile)
TreeMap
ButtonGroup
ColorPicker
Pager
Styling
MultiColumnComboBox
Chat
DateRangePicker
Dialog
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
OrgChart
TextBox
Effects
Accessibility
ScrollView
PivotGridV2
BulletChart
Licensing
QRCode
ResponsivePanel
Switch
Wizard
CheckBoxGroup
TextArea
Barcode
Collapsible
Localization
MultiViewCalendar
Touch
Breadcrumb
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
Popover
DockManager
FloatingActionButton
TaskBoard
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
BottomNavigation
Ripple
SkeletonContainer
Avatar
Circular ProgressBar
FlatColorPicker
SplitButton
Signature
Chip
ChipList
VS Code Extension
AIPrompt
PropertyGrid
Sankey
Chart Wizard
OTP Input
SpeechToTextButton
InlineAIPrompt
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?