Telerik Forums
Kendo UI for jQuery Forum
4 answers
246 views
// line 822
if (options.content && !isLocalUrl(options.content)) {
            contentHtml.html(templates.iframe(options));
        }

I think it's worth to give the programmer to decide on the insertiframe. It may be helpful:)

Alex Gyoshev
Telerik team
 answered on 18 Jan 2012
1 answer
294 views
I have a selectable grid and I want to be able to drag the selected row into a drop target.

I tried attaching kendoDraggable on all the grid rows to make all the rows draggle something like this:

$("#grid tr").kendoDraggable({
hint: function() {
var g = $("#grid").data("kendoGrid")
return g.select().clone()
},
dragstart: function() { console.log("drag start");},
dragend: function() {console.log("drag end");}
});

Unfortunately, this doesn't work. What I am doing wrong?
Numan
Top achievements
Rank 1
 answered on 17 Jan 2012
2 answers
533 views
I have a shared DataSouce that I wish to bind to multiple UI elements (dropdown and chart).

The DataSource has a change event so I can intercept the data.

What I observe is that EACH UI element seems to cause the DataSource to execute rather than the first one only.

Here is some code to illustrate :-

var metaDataSource
    ;
 
function createPieChart() {
    $("#pie").kendoChart({
        dataSource: metaDataSource,
        title: {
            text: "Total XDC Hits"
        },
        legend: {
            position: "bottom"
        },
        seriesDefaults: {
            type: "pie",
            labels: {
                visible: "true",
                template: "#= kendo.format('{0:P}', percentage)#"           
            }
        },
        series:
        [{
            field: "TotalHits",
            categoryField: "Name"
        }],
        chartArea: {
            height: 300,
            margin: 1
        },
        plotArea: {
            margin: 1
        }
    });
}
 
function createList() {
     $("#list").kendoDropDownList({
        index: 0,
        dataSource : metaDataSource,
        dataTextField: "Name",
        dataValueField: "ID",
        change: onSelectXDC
    });
}
 
function onSelectXDC() {
    var dl=$("#list").data("kendoDropDownList");
    var txt = dl.text();
    var val = dl.value();
    log(kendo.format("Select XDC :: {0} {1}", txt, val ));
}
 
function OnListXDC(e) {
    var view = metaDataSource.view();
    log(kendo.format("ds listxdc, #rows={0}",view.length));
    $(view).each(function() {
        log(kendo.format("ID={0}, Name={1}, Hits={2}",this.ID,this.Name,this.TotalHits));
    });
}
 
$(document).ready(function(){
    metaDataSource = new kendo.data.DataSource({
        transport: {
            read: {
                url: "/metrics/listxdc",
                data: {
                    json: "true",
                    simu: "true"
                }
            }
        },
        schema: {
            model: {
                fields: {
                    ID: { type: "number" },
                    Name: { type: "string" },
                    Path: { type: "string" },
                    TotalHits: { type: "number" }
                }
            }
        },
        change: OnListXDC
    });
 
    createList();
    createPieChart();
});

I define the DataSource and then call createList to use this with a dropdown.  This works and I see the change event for the DataSource as expected.

Next, I call createPieChart to use the same DataSource BUT I get another change on the DataSource and another network call is made?

I wish for there to be a single network call and for the results to be bound to the two UI elements until I call .read() on the DataSource to trigger an update.

Can you please take a look and see if I am doing something wrong here?
John
Top achievements
Rank 1
 answered on 17 Jan 2012
3 answers
359 views
Hello,

When I have any kind of error my JSON response is like:

{ error: true, message: "Error caused ....", date: "date ... " },

When I make an AJAX conn by myself I can check whether there has been any error or not, but how can I check it when kendoGrid makes a connection to "Save data"?

Thanks. 
John DeVight
Top achievements
Rank 1
 answered on 17 Jan 2012
5 answers
157 views
This doesn't seem to return anything (Should show Jane), am I using Filters incorrectly?

var stuff = [
                  {
                      FirstName: "Joe",
                      LastName: "Smith"
                  },
                  {
                      FirstName: "Jane",
                      LastName: "Smith"
              }];
 
 var ds = new kendo.data.DataSource({data: stuff});   
 
$("#grid").kendoGrid({
          columns:[
              {
                  field: "FirstName",
                  title: "First Name"
              },
              {
                  field: "LastName",
                  title: "Last Name"
          }],
          dataSource: ds.filter([{ field: "FirstName", operator: "neq", value: "Joe" }])
 
});
John DeVight
Top achievements
Rank 1
 answered on 17 Jan 2012
2 answers
685 views
how to increase dropdownlist items font size
Tirso
Top achievements
Rank 1
 answered on 17 Jan 2012
3 answers
200 views
Hi

I'm using a datasource to populate a grid. When the page loads for the first time I set the URL variable to the datasource. How can I change the URL of the datasource after it was created? The url changes when the user clicks on several items in the page and I don't want to use data property to send parameters to the url (the url changes and the parameters also).

If I initialize the datasource in every click I have strange behaviour. I've read in the forum that it's not advisable to do that

Thanks for your attention
John DeVight
Top achievements
Rank 1
 answered on 17 Jan 2012
0 answers
169 views
Does anybody knows if there is any perfect example available where JSON is implemented in Kendo Grid along with PHP5?
Ilyas
Top achievements
Rank 1
 asked on 17 Jan 2012
1 answer
41 views
As said in title, if I use something like this to style div to look like window ...

<div class="k-widget k-window panel">

... and call some window, window cannot be closed.
Error: Cannot read property 'options' of undefined
Alex Gyoshev
Telerik team
 answered on 17 Jan 2012
1 answer
147 views
Hi,

I'm newbie with js and HTML5. I have no idea how to pass value from QueryStringParameter (set in URL) and filter KendoDataSource ?

http://www.myapp.aspx?orderID=1234

example:

 $("#grid").kendoGrid({
                        dataSource: {
                            type: "odata",
                            serverFiltering: true,
                            filter: [{ field: "Order_ID", operator: "equals", value: 1234}
                            ]



BR
Marko
Atanas Korchev
Telerik team
 answered on 17 Jan 2012
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
Drawer (Mobile)
Drawing API
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?