Telerik Forums
Kendo UI for jQuery Forum
1 answer
88 views
Using the example i have a login / logout link on the drawer.
Now my question is how do i go about hiding the ">" that is placed after the link. in this case i am not calling another view but want to do an action.

<div data-role="drawer" id="my-drawer" style="width: 270px" data-views="['drawer-home', 'drawer-settings' ">
    <ul data-role="listview" data-type="group">
        <li>Application
            <ul>
                <li data-icon="inbox"><a href="#drawer-home" data-transition="none">Show</a></li>
            </ul>
        </li>
      
        <li>Account
            <ul>
                <li data-icon="settings"><a href="#drawer-settings" data-transition="none">Settings</a></li>
                <li data-icon="off" id="logintext" ><a href="#" onclick="app.LoginLogout()">Login</a></li>
            </ul>
        </li>
    </ul>
</div>
Kiril Nikolov
Telerik team
 answered on 10 Dec 2013
2 answers
66 views
Hi.
I was struggling those days with a listview.
Basically, I want to load data remotely.

Here-s the html code:

     <div data-role="view" data-init="initListView">
        <ul id="listView"></ul>
    </div>
        
      <script type="text/x-kendo-template" id="foo-template">
        #: data #
     </script>

And here's the javascript code:
 function initListView(e) {
            var dataSourcevar = new kendo.data.DataSource({
                transport: {
                    read: {
                    // the remote service url
                    url: "http://localhost/PCW/list.php",

                    // JSONP is required for cross-domain AJAX
                    dataType: "jsonp"                    
            }
        }
        });
            
            dataSourcevar.fetch(function() {
              var products = dataSourcevar.data();
              console.log(products[0].ProductName);
            });
            
            e.view.element.find("#listView").kendoMobileListView({
                template : $("#foo-template"),
                dataSource: dataSourcevar
            });
        }
I'm loading data from a localhost script made in php. The script displays:
callback([{"id":"1","name":"Chihuahua","picture":"Chihuahua.jpg"},{"id":"2","name":"chow-chow","picture":"chow-chow.jpg"}])

However, neither the data it's displayed, neither the javascript log displays something.
Please help
Iacob
Top achievements
Rank 1
 answered on 09 Dec 2013
4 answers
124 views
Hi
We have a problem with ComboBox, that can be reproduced with your online demos.
Our ComboBox should accept every numerical input and not only the items in the corresponding list.
If we enter a number and press Enter immediately, then the input will not be accepted. 
If we wait for a short time before pressing Enter, the new value is accepted correctly.
It seems to me, that the delay (the configuration property) is the time to wait for.
Steps to reproduce the error:
- Go to the basic usage demo of the ComboBox
- Clear the "T-shirt Size" combo
- enter a number and press Enter IMMEDIATELY.
- The message box will tell you, that you ordered the size "X-Small", no matter of  your input
- Repeat the steps but wait a second before pressing Enter. Now the size will be stated correctly, according to your input. 
Thank you for any help!
Dylan
Top achievements
Rank 1
 answered on 09 Dec 2013
2 answers
111 views
Hello,

Let's take the following example (3 views: one view with 2 buttons that when clicked redirects the app to the other views, each of them containing a grid):

<body>
    <div id="mainPage" class="k-content" data-role="view">
        <a data-role="button" href="#example1">Test 1</a>
        <a data-role="button" href="#example2">Test 2</a>
    </div>
 
     <div id="example1" class="k-content" data-role="view">
            <div id="grid1"></div>
            ....
    </div>
 
     <div id="example2" class="k-content" data-role="view">
            <div id="grid2"></div>
             .....
    </div>
 
    <script>
        var app = new kendo.mobile.Application(document.body);
    </script>
 
</body>
After pressing one of the 2 buttons in the top the app will navigate to one of those 2 views that have a grid inside (The scripts to create the grids and other data is omitted). When trying to filter a grid's column the app will navigate to a new view that contains the filter view ( or the column menu, depending on the settings of the grid). After pressing one of the buttons in the Filter view (Clear, Filter, Cancel)  the app is redirected to the initial view when the app started which is: "mainPage" view. Why is this happening? Why doesn't it redirect me to the previously view (the view with the grid that triggered this filtering) ?
My application is much more complex than that, but I've reduced the problem to this simple example.
Can I override this behavior of the grid's filtering on Mobile applications, and set the normal web one with dropdown ? 

Thanks,
Walid

Walid
Top achievements
Rank 1
 answered on 09 Dec 2013
3 answers
265 views
I have a  Grid read method that throws this error on the ToDataSourceResult line at the bottom.   
The context.Search_All method is a SQL Stored Procedure in the context object.    

Any suggestions?
             
  public ActionResult Search_Read([DataSourceRequest]DataSourceRequest request, SearchInputModel input)
        {
            var username = _identityService.UserID;
            using (var context = new eEntities.eWJB())
            {
                context.Configuration.ProxyCreationEnabled = false;

                
                IQueryable search = context.Search_All("a", "b", "c", "d", "1", true)
              .AsQueryable()    
              .Select( item => new SearchResultModel
                                      {
                                          ID1 = item.ID1,
                                          ID2 = item.ID2,
                                          1D3 = item.ID3,
                                          Name= item.Name,
                                          Name2= item.Name2});
                var result = search.ToDataSourceResult(request);        <--- Error Here
          
                return Json(result, JsonRequestBehavior.AllowGet);
            }

        }
          
Daniel
Telerik team
 answered on 09 Dec 2013
2 answers
133 views
The commented part of the code does work, but when I try to group my own stuff it fails.

http://mobile.zuol.ch/api/t_links/getLinks

Is my group: simply at the wrong place or what am I doing wrong?

Markus

var dataSource = new kendo.data.DataSource({
    type: "json",
    transport: {
        read: {
            url: "http://mobile.zuol.ch/api/T_links/GetLinks",
            data:{
                Accept: "application/json"
            },
            group:{
                field: "Kategorie"
            }
        }
    }
     
     
        
      /*     data: [
      { name: "Sashimi Salad", description: "Organic greens topped with market fresh sashimi, wasabi soy vinaigrette.",  letter: "S" },
      { name: "Seaweed Salad", description: "A nice seaweed salad.",  letter: "S" },
      { name: "Edamame", description: "Boiled soy beans with salt.",  letter: "E" },
      { name: "Maguro", description: "Tuna pieces.",  letter: "M" },
      { name: "Tekka Maki", description: "Tuna roll with wasabi.",  letter: "T" },
      { name: "California Rolls", description: "Crab sticks, avocado and cucumber.",  letter: "C" }
    ],
    group: { field: "letter" } */
});
 
function LinksListviewInit() {
    $("#filterable-links").kendoMobileListView({
        dataSource:  dataSource,
        template: $("#links-template").text(),
        headerTemplate: $("#links-header-template").text(),
        filterable: {
            field: "Kategorie",
            operator: "startswith",
            placeholder: "Tippen Sie hier um zu filtern ..."
        },
      
    });
}
Alexander Valchev
Telerik team
 answered on 09 Dec 2013
1 answer
974 views
It appears that when you call options.success within the success callback of the Data Source Update, it will reset the grid scollbar to the top.  For example, if I scroll down several records and edit a record, the scrollbar will jump back to the top rather than staying where it was.  Is there a way to keep the scrollbar from jumping back to the top?

success: function(result) {
    // notify the data source that the request succeeded
    options.success(result);
}

Thanks,
Blake
Rosen
Telerik team
 answered on 09 Dec 2013
4 answers
248 views
I  think the title says it all.  No HeaderTemplate shows up in the resulting web page. I also searched the browser debug window to make sure it wasn't just hidden but there. It's not rendered at all:

@(Html.Kendo().DropDownList()
   .Name("CompanyId")
   .DataValueField("Id")
   .DataTextField("Name")
   .BindTo(Model.CompanyList)
   .HtmlAttributes(new { style = "width: 200px; z-index: 10004;" })
   .Height(300)
   .OptionLabel("Select a company")
   .Events(e => e.DataBound("dataBound"))
   .HeaderTemplate("<div>FOO BAR</div>")
   .Template("<span class=\"k-state-default\">" +
                          "<h5 style=\"display: inline-block; width: 190px\">#: data.Name #</h5>&nbsp;&nbsp;" +
                          "<p style=\"display: inline-block; width: 100px\">#if(data.ContactName) {# #=data.ContactName# # } else {# #}#</p>&nbsp;&nbsp;" +
                          "<p style=\"display: inline-block; width: 100px\">#if(data.PhoneFormatted) {# #=data.PhoneFormatted# # } else {# #}#</p>" +
                       "</span>"
   )
)
Georgi Krustev
Telerik team
 answered on 09 Dec 2013
1 answer
83 views
Hi

I'm working in a large corporate and I'm interesting in new web frameworks for our web applications.
I really impressed from Kendo UI web components .
I couldn't find out if following capabilities embedded in Kendo UI components:
If you do, I would like to get references to articles and examples for those capabilities:

1. Out of the box Localization for all components.
2. Supporting roles (hide / show or disable / enable components based on users' roles.
3. Accessibility 

* I prefer to work with the HTML / JavaScript/ Client side package, but if the JSP tag library support those feature I also like to know about it.

Thanks in advance
Alexander Valchev
Telerik team
 answered on 09 Dec 2013
3 answers
250 views
can anyone give an example?  
Can user select a rectangle area with mouse, and then kendo chart zoom into the area?
Jianxun
Top achievements
Rank 1
 answered on 09 Dec 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?