Telerik Forums
Kendo UI for jQuery Forum
2 answers
135 views
I have the following grid set up on my view

@(Html.Kendo().Grid(Model)    
    .Name("Grid")
    .Columns(columns =>
    {
        columns.Bound(p => p.FirstName).Groupable(false);
        columns.Bound(p => p.City);
        columns.Bound(p => p.EprescribePatientMRN);
        columns.Bound(p => p.DateOfBirth);
    })
      .ToolBar(toolbar =>
    {
        toolbar.Template(@<text>
           <div class="toolbar">
                    <label class="category-label" for="category">Show products by category:</label>
                        @(Html.Kendo().DropDownList()
                            .Name("categories")
                            .OptionLabel("All")
                            .DataTextField("CategoryName")
                            .DataValueField("CategoryID")
                            .AutoBind(false)
                            .Events(e => e.Change("categoriesChange"))
                            .DataSource(ds =>
                            {
                                ds.Read("ToolbarTemplate_Categories", "Grid");
                            })
                        ) 
                        </div>
        </text>);
    })
    .ClientDetailTemplateId("tmplPatientDrugs")
    .Groupable()
    .Pageable()
    .Sortable()
    .Scrollable()
    .Filterable()
    .DataSource(dataSource => dataSource
        .Ajax()
        .Read(read => read.Action("Patients", ""))
        .PageSize(30)
    )
      )


and when I hit the page number, I end up getting paging information in the page url, is there a way to work around this. As I would really like a clean url, rather than filling it with querystring params and so on.

Vladimir Iliev
Telerik team
 answered on 26 Mar 2013
3 answers
958 views
Hi support,

I'm using the Kendo Framework Validator together with Siteifnity.
I'm getting this error when running my page:

Timestamp: 21-3-2013 14:18:05
Error: TypeError: $(...).kendoValidator is not a function
Line: 909
This is the code I use in my page:
$(document).ready(function () {
 
       $('#addReview').hide();
 
       var validator = $("#addReview").kendoValidator().data("kendoValidator");
       //status = $(".status");
 
       $("<%=submit.ClientID %>").click(function () {
           if (validator.validate()) {
               status.text("Hooray! Your tickets has been booked!")
                   .removeClass("invalid")
                   .addClass("valid");
           } else {
               status.text("Oops! There is invalid data in the form.")
                   .removeClass("valid")
                   .addClass("invalid");
           }
       });
 
   });
Any thoughts?

Kind regards,
Daniel
Alexander Valchev
Telerik team
 answered on 26 Mar 2013
7 answers
2.1K+ views
Hello Kendo team:
If you have a kendoWindow inside an iframe, it doesn´t center the window vertically as far as appending the window to document.body exceeds 100% of the height of the viewport.
I've checked this issue in version 2012.3.1406 with IE10.
I'm attaching an example to reproduce this. You can paste these two HTML files to your window's examples and open api1.html from IE10.

toFront() function in line 41200 of kendo.web.js makes a winElement.focus() that changes the $(window).scrollTop()
kendoWindow uses $(window).scrollTop() to determine the center of the viewport.

This worked fine with version 2012.2.710.

Hope it helps you to find a faster solution.

Kind regards.
Dimo
Telerik team
 answered on 26 Mar 2013
8 answers
171 views
Hi,
I am using Kendo UI Web for upload files.
Here is an issue when uploading large on IE9, the file is 49.6M. It is always in uploading file and no error message is shown. The upload is in a iframe.
On firefox, the file is uploaded successfully.

Is there any adive on this issue?

Thanks,
Peter
Vladimir Iliev
Telerik team
 answered on 26 Mar 2013
1 answer
108 views
I'm new to Kendo UI and Kendo Data Viz so bear with me :D

I have a datasource in my javascript file:

    var _detailDataSource = new kendo.data.DataSource({
        transport: {
            read: {
                type: "POST",
                url: "/Admin/GetDetailUsage",
                dataType: "json",
                data: {
                    beginDate: function () {
                        return $('#beginDate').val();
                    },
                    endDate: function () {
                        return $('#endDate').val();
                    }
                }
            }
        },
        schema: {
            model: {
                fields: {
                    RequestId: { type: "number" },
                    RequestDate: { type: "date" },
                    Interface: { type: "string" },
                    ProviderName: { type: "string" },
                    EmployeeId: { type: "string" },
                    EmployeeName: { type: "string" },
                    EmployeeType: { type: "string" },
                    Department: { type: "string" }
                }
            }
        },
        pageSize: 20
    });

I am currently using that datasource for a grid but I also wanted to use it for an area chart on the same page (different tab in the tab control)

So I have setup the chart like this:

function dashboardChart() {
    $("#chart").kendoChart({
        dataSource: _detailDataSource,
        title: {
            text: "Units sold"
        },
        series: [{
            type: "area",
            field: "RequestId",
            aggregate: "count"
        }],
        categoryAxis: {
            baseUnit: "weeks",
            field: "RequestDate"
        }
    });
}

and then I call the chart like so: dashboardChart();

So, can someone tell me what I'm doing wrong? I want to aggregate the data from the datasource by week and display the number of Requests in an area chart.

Thanks,

Chad.

Iliana Dyankova
Telerik team
 answered on 26 Mar 2013
1 answer
119 views
Are there style guides to write codes the "KendoUI way"? I'm new to KendoUI and I'm trying to find out how to write mobile apps the correct way KendoUI designed it for.

For example:
- What is the KendoUI way to populate a list view? Is the correct way to use JQuery and append html?
- What is the "KendoUI" way to pass data from a list view to another view.
- When using buttons, are you supposed to extend the button class to change the way it behaves, or manage that in the HTML?
- If not, what is the main reason you will use inheritance when using KendoUI?
- What is recommended, multiple views in one file? Or views in separate files.
- Which file is the layout supposed to reside in?

I'm having difficulty finding the answers to these questions since I can't find much documentation on it, and KendoUI being so new there is no tutorials for any of it. 
Alexander Valchev
Telerik team
 answered on 26 Mar 2013
1 answer
63 views
Hello

Is is possible to create a window on page example1.aspx and use it's dynamic contents on other page for example example2.aspx?

Example1.aspx would be open before example2.aspx is opened and would remain open for the time the contents is needed.

BR,
Joonas
Dimo
Telerik team
 answered on 26 Mar 2013
2 answers
265 views
I have a Kendo application construction with an initialization which contains a call bindevents() that in it's turn adds the event listener for deviceReady.

Before deviceready is finished the code for my homeView_onInit is already being executed causing incorrect behaviour of my app

How can I prevent that any code is executed before the deviceready event has finished or is fired?
Jan-Dirk
Top achievements
Rank 1
 answered on 26 Mar 2013
1 answer
57 views
Everytime I try to access this thread to reply, I get redirected to the forums homepage

http://www.kendoui.com/forums/ui/grid/selectable-elements---don't-trigger-when-you-drag-the-mouse-a-little.aspx

Anyways, it seems like it's a bug that doing a minor mouse drag causes the row to not be selected.
Alexander Valchev
Telerik team
 answered on 26 Mar 2013
1 answer
118 views
Why this code dosn't  work properly.
My grid show the IDArticolo property and not the text "HELLO WORLD"!!!!!  See the attached picture.

<%: Html.Kendo().Grid(Model) _
.Name("Grid") _
.Columns(Sub(column) column.Bound(Function(art) art.idarticolo).ClientTemplate("<span>HELLO WORLD</span>")) _
.Columns(Sub(o) o.Command(Sub(cmd) cmd.Custom("Dettaglio").Action("articolodettaglio", "articolo").DataRouteValues(Sub(va) va.Add(Function(da) da.idarticolo).RouteKey("idarticolo")))) _
 .Pageable(Sub(o) o.PageSizes(True)) _
.Sortable() _
.Filterable() _
.DataSource(Sub(ds) ds.Server().PageSize(10))
%>

Dimiter Madjarov
Telerik team
 answered on 26 Mar 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?