Telerik Forums
Kendo UI for jQuery Forum
5 answers
294 views
How can I get the line chart to accept JSON with this format?

{
    "apps": [
        { "Name": "One", "Data": [8, 4, 10, 15, 6, 2, 7, 12, 10, 11, 5, 9] },
        { "Name": "Two", "Data": [7, 17, 9, 10, 7, 5, 15, 16, 7, 16, 5, 1] },
        { "Name": "Three", "Data": [18, 9, 8, 17, 13, 3, 11, 3, 8, 1, 5, 2] },
        { "Name": "Four", "Data": [5, 19, 7, 13, 8, 5, 19, 11, 2, 3, 16, 1] },
        { "Name": "Five", "Data": [5, 5, 9, 4, 14, 11, 5, 17, 6, 15, 14, 7] }, 
        { "Name": "Six", "Data": [13, 17, 18, 4, 19, 0, 8, 11, 2, 4, 9, 13] }
    ],
    "labels": [ "0:00", "1:00", "2:00", "3:00", "4:00", "5:00", "6:00", "7:00", "8:00", "9:00", "10:00", "11:00" ]
}

I'm not seeing how to transform the data from what I've got to what the Kendo line chart accepts. In fact, I don't really see any documentation on what the Kendo charts accept for data other than a demo that doesn't actually show the format of the data (I had to figure out the url to the JSON datasource).

I do have something working in jsfiddle (http://jsfiddle.net/472Xr/2/), but that doesn't seem like a workable solution for a remote data source that can be updated on the client.
Mike
Top achievements
Rank 1
 answered on 24 Jul 2012
0 answers
130 views
Hi, 
I want find and select a Node in TreeView with HierarchicalDataSource.
I have create a webService for to find the Item and the path in tree.
I want expand the treeview for show the Find Node.
How ?
The FindByText and expand not fuction ?

Help me.
Vitantonio
Top achievements
Rank 1
 asked on 24 Jul 2012
5 answers
369 views
i don't want to display grid if no record found here is my code i use the change function to check if data length exist  then grid display but it's no working and browser give me an error with the two options "Continue","Stop Script"..here is my code

var DataSource, UserName;

$(function () {

    UserName = $('#NameText').val();

    GetDataSource();
   
});


function GetDataSource() {

    DataSource = new kendo.data.DataSource({
        pageSize: 10,
        change: function () {
            if (this.data().length) {
              CreateGrid();
            }
        },
        transport: {
            read: {
                type: "POST",
                url: "/WebBasedBookExchangeSystem/books.svc/GetUserBooks",
                contentType: "application/json; charset=utf-8",
                dataType: "json"
            },
            update: {
                type: "POST",
                url: "/WebBasedBookExchangeSystem/books.svc/UpdateUserBook",
                contentType: "application/json; charset=utf-8",
                dataType: "json"
            },
            destroy: {
                type: "POST",
                url: "/WebBasedBookExchangeSystem/books.svc/DeleteUserBook",
                contentType: "application/json; charset=utf-8",
                dataType: "json"
            },
            parameterMap: function (data, operation) {

                if (operation == "update")
                    return kendo.stringify({ updateBook: data });
                else if (operation == "destroy")
                    return kendo.stringify({ deleteBook: data });
                else if (operation == "read")
                    return kendo.stringify({ user: UserName });

            }
        },

        schema: {

            parse: function (data) {
                return JSON.parse(data.d);

            },
            model: {
                id: "Book_Id",
                fields: {
                    "Book_Id": { type: "number" },
                    "Title": { type: "string" },
                    "ISBN": { type: "string" },
                    "Author": { type: "string" },
                    "Price": { type: "number" }
                }
            }
        }
    });

    DataSource.read();
}

function CreateGrid() {

    $('#grid').kendoGrid({

        filterable: true,
        sortable: true,
        pageable: true,
        scrollable: false,
        editable: "popup",
        columns: [
                    { field: "ISBN", filterable: false, width: 50, title: "ISBN NO" },
                    { field: "Title", title: "Book Title", width: 180 },
                    { field: "Author", filterable: false, width: 180, title: "Book Author" },
                    { field: "Price", filterable: false, width: 50, title: "Price (Rs)" },
                    { command: ["edit", "destroy"], title: "Action", width: 5 }
                 ],

        dataSource: DataSource

    });
}
Michael
Top achievements
Rank 2
 answered on 24 Jul 2012
0 answers
132 views
I have an XML RPC server which has a method to return data from a database when it is called. I want to bind a datasource to this method so that I can use this data in a grid. However, I haven't been able to find an example which shows this sort of thing. Is this possible, and if so could someone point me in the direction of an example? The POST request which I can send to the server to access the method looks like this:

<?xml version="1.0"?>
<methodCall>
<methodName>breq.getBreqs</methodName>
<params>></params>
</methodCall>
Paul
Top achievements
Rank 1
 asked on 24 Jul 2012
1 answer
166 views
why there are no :
1. "kendo-radioButtonList" 
2. "kendo-checkBoxList" 
3. "kendo-radioButton"
4. "kendo-checkBox"

if there are, the form elements will have universal theme(look and feel) !!!
Vesselin Obreshkov
Top achievements
Rank 2
 answered on 24 Jul 2012
3 answers
369 views
I want to use the visible and editable bindings in a complex, nested form. it consists of tabs, with <fieldsets> as child elements. the fieldsets itself host the individual form fields (e.g. <input>,<select>). what i want to is to apply visible or enable bindings to entire fieldsets or tabs. If the enable property is set on a tab, it should still be possible to open it, but all form fields on it should be disabled.

any idea how i could accomplish this with kendoui mvvm? i'm aware that i might have to write my own custom mvvm binders for that, since the enable binding is limited to form fields.

kind regards,

Franz
Atanas Korchev
Telerik team
 answered on 24 Jul 2012
0 answers
191 views

Hi

I have grid with template for column A

template: '<input type="checkbox" class="Acolumn" #= A ? checked="checked" : "" # />'
and delegate 

$(divGrid).delegate(".AColumn", "click", function (e) {
                var dataItem = grid.dataItem($(this).closest("tr"));
                dataItem.A = $(this).is(':checked');
            });

Data Source configured with following options: autosync, transport update url, batch

Grid configuration : editable. Save changes button at the grid header.

It works ok when checkbox is selected data in data source changed successfully but Save changes button of the grid doesn't call update method of data source. 

What could be a reason of this issue?

Yuriy
Top achievements
Rank 1
 asked on 24 Jul 2012
2 answers
76 views
I'm using a TabStrip  together with some list / detail views like in the sushi demo.
Whenever you're opening a details page, clicking back and afterwards opening a details page of another tab the following back-transition is executed twice. 
Confirmed that on the sushi demo as well.
Tested in android, iOS and Google Chrome.
Any Workarounds?

Thx
d2uX
Top achievements
Rank 1
 answered on 24 Jul 2012
1 answer
113 views
I have several html selects on a form. Once I package my application and deploy it via phonegap, it is VERY hard to select the drop down lists. I have to push about 3/4 of an inch to the top and left of each list to get it to work and even then it doesn't seem to work all of the time. Is there something that I am doing wrong. They are just regular select lists:

<select id="SelectText">
    <option selected="selected" value="1">Test 1</option>
    <option value="2">Test 2</option>
    <option value="3">Test 3</option>
</select>
Kamen Bundev
Telerik team
 answered on 24 Jul 2012
0 answers
110 views

I have used Kendo grid, I need to select a row without command columns. 

Here is my code..

 
var grid = $("#grid").kendoGrid({
        dataSource: grid,
        height: 450,
        sortable: true,
        selectable: "row",
        columns: [
            field: "user" },
            { field: "subject" },
            field: "status" },
           command: ["Update"],  title: "Subscribe" },
            command: ["destroy "], title: "Delete"}
           ]
    });

 In UI i want to select user, subject, status only. 



Ramesh
Top achievements
Rank 1
 asked on 24 Jul 2012
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
DatePicker
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)
Filter
SPA
Drawing API
Drawer (Mobile)
Globalization
LinearGauge
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
TextBox
OrgChart
Effects
Accessibility
PivotGridV2
ScrollView
BulletChart
Licensing
QRCode
ResponsivePanel
Switch
Wizard
CheckBoxGroup
TextArea
Barcode
Breadcrumb
Collapsible
Localization
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
TimePicker
BottomNavigation
Ripple
SkeletonContainer
Avatar
Circular ProgressBar
FlatColorPicker
SplitButton
Signature
Chip
ChipList
VS Code Extension
AIPrompt
PropertyGrid
Sankey
Chart Wizard
OTP Input
SpeechToTextButton
InlineAIPrompt
StockChart
ContextMenu
DateTimePicker
RadialGauge
ArcGauge
AICodingAssistant
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?