Telerik Forums
Kendo UI for jQuery Forum
1 answer
994 views
Calling the jsonp response but receiving Error : jQuery18207158344800118357_1359997121430 was not called. can some one let me know how to fix this ? Appreciate your help. Below is the client code :

<script>
        function mobileListViewPullToRefresh() {
        var dataSource = new kendo.data.DataSource({
serverPaging: true,
    pageSize: 2,
type: "odata",
error: function(e) {
console.log("Error " + e);
alert(e.errorThrown);
   },
    transport: {
    read: {
                   url: "http://localhost:50675/movie/GetAll", 
                       dataType: "jsonp"
                       },
                       parameterMap: function(options) {
            alert("Inside parameterMap")
            alert(JSON.stringify(options, null, 4));
                       return {
                           q: "javascript",
                           page: options.page,
                           rpp: options.pageSize,
                       };
                      }
                 },
                 schema: {
        errors: function(response) {
       return response.errors;
   },
data: function(data) {
                    if (data.movieList.length == 0) {
    return [];
    }
return data.movieList;
       },
       total: function(data) {
        alert(data.movieList.length);
                           return data.movieList.length;
                       }
              }
});

$("#localListView").kendoMobileListView({
           dataSource: dataSource,
           pullToRefresh: true,
           appendOnRefresh: true,
           template: $("#categories-template").html(),
           pullParameters: function(item) {
            alert("Inside pullParameters")
            alert(item.length);
            alert(JSON.stringify(item, null, 4));
               return {
                   page: 1
                };
            }
       });
       };
       
       window.kendoMobileApplication = new kendo.mobile.Application(document.body);
    </script>

When checked in Chrome developer tools the response is successfully received from server. Below is the jsonp response from the server :

({"movieList":[{"ID":1,"Title":"Movie","ReleaseDate":"/Date(487189800000)/","Genre":"Comedy","Price":30},{"ID":1,"Title":"Movie","ReleaseDate":"/Date(487189800000)/","Genre":"Comedy","Price":30}],"count":4})

Petyo
Telerik team
 answered on 05 Feb 2013
2 answers
465 views

I want to sum my orders as GrandTotal, But my grid cannot do it.
Grand Total row is always 0
Please help Urgent

Big Thanks

my grid

@(Html.Kendo().Grid((IEnumerable<Apex.Models.bmfsummary>)ViewData["BMFsummary"])
    .Name("Grid")
    
    .Columns(cols =>
    {
 
        cols.Bound(ss => ss.eventdate).Title("Date").ClientFooterTemplate("Grand Total");
        cols.Bound(ss => ss.totalPrice).Title("Total").Format("{0:n2}").ClientFooterTemplate("#=sum#");
 
         
 
    })
 
 .DataSource(dataSource =>
               dataSource.Ajax()
                          
                         .Aggregates(aggregates => { aggregates.Add(ss => ss.totalPrice).Sum(); } )
                          
                         .Read(read => read.Action("Summary", "BMF"))
)
Rosen
Telerik team
 answered on 05 Feb 2013
3 answers
97 views
Hi,
I am using KendoUI version: 2012.3.1315.commercial.
I need help to understand the below code:
i use TabStrip and in my second Tab, i uses ListView to load my data. In the listView, i wanted to call the record as pagination.

I have encounter a very funny behaviour with my code. The LoadMore button when press\click, it just disappear, no event fired to fetch my next record.  

Thanks for the advise.

Following are my code:

HTML:
<div data-role="view" data-title="Views" id="overview-list" data-init="ProjectList" data-layout="overview-layout" >
 
 
  <ul data-role="listview" data-style="inset" data-type="group"  >
        <li>
            <ul id="endless-scrolling" >
       
            </ul>
           
           
        </li>
    </ul>
 
   
 <script id="endless-scrolling-template" type="text/x-kendo-template">
   <a href="/_layouts/projectDetail.aspx?id=#=ID #" data-transition="slide"">
                     <div class="Lists">
                            <img class="pullImage" src="#=Picture1 #" />#= Title #
                             <div class="metadata">
                              #= Description #
                             </div>
                        </div>
                        </a>
    
</script>
</div>

and my Javascript:
$(function () {
       window.kendoMobileApplication = new kendo.mobile.Application(document.body);
 
   });
   var Skip = 0; //Number of skipped row
   var Take = 1; //
   
   function ProjectList() {
       var dataSource = new kendo.data.DataSource({
           transport: {
               read: function (options) {
                   // make AJAX request to the remote service
                   $.ajax({
                       type: "POST",
                       url: "mobile.aspx/AllProject",
                       data: "{ Skip:" + Skip + ", Take:" + Take + " }",
                       contentType: "application/json; charset=utf-8",
                       dataType: "json",
                       headers: { "cache-control": "no-cache" },
                       success: function (data) {
                           Skip = Skip + Take;
                           options.success(data.d);
                       }
                   });
               },
               cache: false
 
           },
           schema: {
               total: function () { return 0; }
 
           }
       });
 
      var listMore  =$("#endless-scrolling").kendoMobileListView({
           dataSource: dataSource,
           template: $("#endless-scrolling-template").text(),
            loadMore: true
     
       });
 
       
    }


CH
Top achievements
Rank 1
 answered on 05 Feb 2013
2 answers
229 views
One of the ListViews displays no content when applying a template. For example, this section:

<script type="text/x-kendo-template" id="tmpl_jailcard_comment">
    begin list
    <ul data-role="listview" data-style="inset" data-type="group" >
        <li id="Item-A">AAA</li>
        <li id="Item-B">BBB</li>
        <li id="Item-C">CCC</li>
    </ul>
    end list
</script>

Produces no LI elements, only the enclosing UL element

When the UL attribute "data-role" is removed, the list displays the three items.
This might have to do with data binding, even though the above UL list does not work with dynamic data.

- bind data when calling the template from the view that uses the template: 
<span data-bind="source:this" data-template="tmpl_jailcard_comment"></span>
- bind data when navigating to the view:

kendo.bind("#scr_jailcard_comment", viewModel);
Any ideas what can cause this issue?

Attached is a stand-alone HTML file to reproduce the issue

EDIT:
On the following jsffiddle, the listview only displays when not binding any data to the view:

http://jsfiddle.net/elgato/CMCzC/7/

It does not matter binding an object or null.
mg1970
Top achievements
Rank 1
 answered on 04 Feb 2013
3 answers
98 views
Hello,

I have a scrollable editable grid (incell) and I started seeing a problem, so I went in and tried it at http://demos.kendoui.com/web/grid/editing.html and the problem happens there too, so I'm pretty sure it's an issue. The problem is that when you try to click on a cell and your scroll position is not on top, let's say middle or end of the page, the scroll goes all the way up and the cell doesn't go into edit mode, takes a few tries to get it to actually go into edit mode. I tested this on Chrome and there is no problem there so I'm guessing it is browser specific. I would like to have a workaround for this if possible since IE 9 is the standard browser being used for my application.

Thank you
OmarOrnelas
Top achievements
Rank 1
 answered on 04 Feb 2013
4 answers
340 views
I have run into an issue with the DataSource object of my Grid. In short, I bind the current record in the Grid DataSource to a popup window, make some changes to the model in the view (which makes the record "dirty"), and click a save button which calls the myGrid.dataSource.sync() method.

All is well and good up to the point when my Controller receives the POST on the server-side. My model contains a collection property. The problem is that the model being posted by the DataSource is sending the collection property names in the wrong format and ASP.NET does not know how to bind the data to my model.

Here is an example of my model:
public class Member {
  public Member() {
    this.Relatives = new List<Relative>();
  }
  public string Id { get; set; }
  public string Name { get; set; }
  public ICollection<Relative> Relatives { get; set; }
}
  
public class Relative {
  public string Name { get; set; }
  public int Age { get; set; }
}
Like I mentioned before, everything works as expected, up until the model changes are posted to the server. This is the format the model property names are sent in when received by the server:
Member.Id
Member.Name
Member.Relatives[0][Name]
Member.Relatives[0][Age]
Member.Relatives[1][Name]
Member.Relatives[1][Age]
Member[Id]
Member[Name]
Member[Relatives][0][Name]
Member[Relatives][0][Age]
Member[Relatives][1][Name]
Member[Relatives][1][Age]
This is confusing to me. Why are there brackets around the collection property names? There should be a dot after the index (i.e. Member.Relatives[0].Name). Also, why is the model posted twice and in a more incorrect format?
Daniel
Telerik team
 answered on 04 Feb 2013
3 answers
235 views
Heyas,

I'm using the latest version of kendoui and whenever I use the "is not equal to" or "does not contain" filter I get the following error:

Uncaught TypeError: Cannot read property 'length' of undefined
I'm using a server side datasource, all the other filters seem to work without issue.

Also, how do I specify a datetimepicker for a date column?

I've looked at the documentation and tried using:

filterable: {
                ui: "datetimepicker"
             }

But it never shows the datetimepicker.

Any ideas?
Petur Subev
Telerik team
 answered on 04 Feb 2013
2 answers
160 views
Hi, i have encounter a weird scenario where my list view suppose to shows a detail information of my project.

Here is my scenario:
I have a list view to shows all my product, when i touch\click on the first list view, it will show my remote view(passing in querystring) on the product details.

I then go back to the first view where it shows all my product, i then select the second product, when i am at my remote view, it is empty. 

Weird thing is that the second time i tried, it did call my server script to grab the second product information, but it didnt show the data.

I think it could be some caching issue where remote view is cache. can i uncache it?

regards,
CH



Alexander Valchev
Telerik team
 answered on 04 Feb 2013
1 answer
106 views
Hi,
I have scenario where I pre-popuate the editor with html content.
For e.g.
<P>The <ins>black</ins> spotted fox <del>leaped</del>
over the rolling<br>new</P>

If the user now wants to add an extra content next to word leaped then formatting from <del> element would be retained so any additional text would have strikethrough applied to it by default. Is there a way to avoid this without the user having to manually then reset the strikethrough option in the tools ?
Dimiter Madjarov
Telerik team
 answered on 04 Feb 2013
1 answer
85 views
I have been trying to make a treeview control look like a grid but I have been unsuccessful.  So I started from the grid and using the aggregate example which looks close, I have been trying to add treeview functionality to the grid but that is becoming just as difficult.  Has anybody figured out a way to make a treeview grid control using what is available?  If so I would love to hear how you went about it.  I so wish Kendo had a grid, treeview, and treeview grid like I have seen in other control suites.

Thanks!
Petur Subev
Telerik team
 answered on 04 Feb 2013
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
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
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?