Telerik Forums
Kendo UI for jQuery Forum
1 answer
167 views
Is it possible to have tabs not show in tab strip so it can behave wizard like?
Alexander Valchev
Telerik team
 answered on 04 Feb 2013
3 answers
333 views
Hi!

Is it possible to force the orientation to be portrait, not switching to landscape when user flips the phone? We target iPhone 4-5.
Jordan
Telerik team
 answered on 04 Feb 2013
1 answer
721 views
Hello,

I am currently using "kendo.mobile.min.js" for a client's mobile website.

On one of template pages for the page detail, I have included some JQuery code to show and hide a <div> when an image is clicked.

<script>
    $(document).ready(function(){
 
        var imgHelp = $('#imgHelp');
        var helpContent = $('#helpContent');
 
        imgHelp.click(function(event) {
 
            console.log('Image was clicked.');
 
            if (helpContent.is(":hidden")) {
                helpContent.show();
            }
            else {
                helpContent.hide();
            }
        });
    });
</script>

When the image is clicked, the code within the imgHelp.click is run twice.  The console log fires the message twice and the div never appears because it shows the div and then the code runs again, and hides it.  The only JavaScript file that I have on the page is the one reference above.  What I found interesting, is when I removed the "kendo.mobile.min.js" from the page, when I clicked on the image, the JQuery ran ONCE.

Can someone explain why this is happening and what I can do to fix this issue.


EDIT:  I found that when NOT using the document.ready, it works just fine!
<script>
function KendoUI() {
    alert('Test');
}
</script>
 
<img src="/design/images/info.png" onclick="KendoUI();">

Thank you in advance for your help.
Alexander Valchev
Telerik team
 answered on 04 Feb 2013
2 answers
81 views
Hi,
I have a problem on my mobile site with kendoui. I have pages for login, register etc.. with two or more inputs. I can tap the first one to write in it, but when i try to tap the second input the view scrolls to top, and the pointer remains in the first input, and the page becomes unscrollable. I can go to the next input only with the help of the "Next" button or after closing the keyboard. I have checked this on iPhone 4s and iPhone5, in Safari as well as Chrome the same issue.
Can you please help me to fix this problem?

Thanks in Advance
Amelia
Amelia
Top achievements
Rank 1
 answered on 04 Feb 2013
3 answers
200 views
I'm testing out using the menu datasource attribute for creating my initial menu "scaffolding".  I have one separator with a specific id, which I will insert items before or after (depending on the item type).

When I test this, both items are inserted *after* my separator:

$("#menu").kendoMenu({
    orientation: "vertical",
    dataSource:
    [{
        // Separator with unique id
        text: "<li id='main_separator'/>",
        encoded: false,
        enabled: false,
        cssClass:"menuItemSeparator MultipanelMenuSeparatorStyle",
     },
     {
         enabled: false,
         cssClass: "menuItemSeparator MultipanelMenuSeparatorStyle",
     },
     {
         text: "<input type='text' id='textbox' maxlength='256'/>",
         encoded: false,
         cssClass: "text k-textbox",
     }]
});
 
var viewMenu = $("#menu").data("kendoMenu");
 
viewMenu.insertBefore({text:"Layout1",cssClass:"menuItemLayout MultipanelMenuItemStyle"}, $("#main_separator"));
viewMenu.insertAfter({text:"Preference1",cssClass:"menuItemPref MultipanelMenuItemStyle"}, $("#main_separator"));
I've also included a link to a jsfiddle demonstrating this:  http://jsfiddle.net/raltman/qYtPC/4/
Please take a look and let me know what is wrong here.

Thanks.
Kamen Bundev
Telerik team
 answered on 04 Feb 2013
2 answers
64 views
I'm going mad trying to set the nav title of a page. I have a page of buttons that loads a view and displays a generated selection of other buttons depending on the first button selected. e.g.
 <li><a href="#tabstrip-knowledge-general" class="arrow" data-role="button" data-title="Title1" data-click="do_buttons" data-var="controls">Title1</a></li>
<li><a href="#tabstrip-knowledge-general" class="arrow" data-role="button" data-title="Title2" data-click="do_buttons" data-var="controls">Title2</a></li>
<li><a href="#tabstrip-knowledge-general" class="arrow" data-role="button" data-title="Title3" data-click="do_buttons" data-var="controls">Title3</a></li>
So my #tabstrip-knowledge-general page is generated based on the option selected but I just can't seem to set the pag title. I've tried storing the title to a var and use view.init  view.show etc. to set the title, but after it' set once I can't seem to get it to change ever again.

Also if I change the data-value of a keno button again it never refreshs when I try to use it. Kendo seems to init button and store all this data locally so when you update it, it never updates the kendo stored one.
Mat-Moo
Top achievements
Rank 1
 answered on 04 Feb 2013
4 answers
300 views

I have a cshtml page that contains a panelbar with 6 items.  Each item uses Ajax to load content based
on a partial view that contains a grid e.g.:

   @(Html.Kendo().PanelBar()
        .Name("panelbar")
        .ExpandMode(PanelBarExpandMode.Single)
        .Animation(animation =>
            {
                animation.Enable(true);
                animation.Expand(config =>
                    {
                        config.Expand();
                        config.Fade(FadeDirection.In);
                        config.Duration(AnimationDuration.Fast);
                    });
            })
        .Items(panelbar =>
        {
            panelbar.Add()
                .Text(String.Format("{0} [{1} Items]", "One",@Model.MyOpenObligations ))
                .ImageUrl(Url.Content("~/Contents/Images/White_Triangle.png"))                   
                .Encoded(false)
                .Selected(true)
                .Expanded(true)
                .LoadContentFrom("ListFilteredObligations", "MyController");
etc etc................           

The partial view that is loaded by each panel item contains a grid that uses ClientTemplates for specfic columns
e.g. :

@(Html.Kendo().Grid(Model)
    .Name("obligationGrid")
    .Columns(columns =>
        {
            columns.Bound(p => p.ReferenceNumber);
            columns.Bound(p => p.Extract);
            columns.Bound(p => p.Clause);
            columns.Bound(p => p.Party).ClientTemplate("#= Party ? Party.DisplayName : ''# ").Title("Party");
        })
....etc etc

The ClientTemplate columns are rendered OK when the first panel item is expanded (see attached screen shot).
However, when subsequent panel items are expended the grid client template columns display the entire child object (see attached screen shot).We only see this issue when using the grids within the PanelBar control.

Daniel
Telerik team
 answered on 04 Feb 2013
3 answers
257 views
Hi,

In your ASP.NET grid you have a grid select column (GridClientSelectColumn) which is a checkbox to select rows in a grid. This works together with the functionality to select multiple rows using click/ctrl-click. 

For an example see: http://demos.telerik.com/aspnet-ajax/grid/examples/programming/webmailgrid/defaultcs.aspx 

Is this something you are planning to implement in KendoUI? 


Regards,
Jan Erik
Iliana Dyankova
Telerik team
 answered on 04 Feb 2013
5 answers
456 views
When I change a value in the popup editor the dirty flag is not set, hence the data is not posted back.

Run the attached project:
Click Edit on the grid item
Within the popup dialog
Click into the Customer field and Add '5' to the 'Sage 1234' data(Notice the grid dirty(changed) indicator not present)
Click save.(Notice the grid not updated)

Another issue I'm having is the checkboxes in the Subscriptions grid (also on the Edit popup) do not set the dirty flag either. Hence, if I check or uncheck them and then enter subscription text the checkboxes revert back to their original state.

Any help is appreciated.
Petur Subev
Telerik team
 answered on 04 Feb 2013
3 answers
863 views
The datasource for my treeview is defined as follows:

 legends = new kendo.data.HierarchicalDataSource({                   
                 schema: {
                     model: { id : "id", hasChildren: true,  children: "layers"    }
                 }
             });      

and my treeview is initialized like this:

  $("#treeview").kendoTreeView({ 
                 checkboxes : { checkChildren : true },
                 dataSource: legends }); 

This is supposed to be a dynamic data source allowing me to add and remove items during runtime.  When I add and remove items from legends, I expect the treeview to add and remove nodes accordingly.  So when I later create a model like this:

var category = {id : 0, text : "some text", expanded : true, spriteCssClass : "folder", layers : [] }

and add it to the datasource using the add method

                legends.add(category); 

I should expect to see a tree node automatically created.  This works.

If I later grab the category created above from legends.data() and add a child layer like this:

category.layers.push({ id : 1, text : " child",  someOtherData : {} });

I do not see the child appear on the treeview and my application starts behaving abnormally.   Then it occurred to me that the layers collection was not an observable and tried creating my categories like this:

var category = {id : 0, text : "some text", expanded : true, spriteCssClass : "folder", layers : new kendo.data.ObservableArray([]) }

With this change, I still get no children displayed and applpication appears to hang on call to category.layers.push().

What am I missing?

Volodymyr Oliinyk
Top achievements
Rank 1
 answered on 04 Feb 2013
Narrow your results
Selected tags
Tags
+? 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?