Telerik Forums
Kendo UI for jQuery Forum
1 answer
301 views
Hello, I'm having the following problem to implement the kendo  grid:

This is my code in client side:

   $(document).ready(function () { 
      var dataSource = kendo.data.DataSource({             
        transport: {                 
            read: {                     
                url: '@Url.Action("GetAll""Company")',                     
                dataType:"json"                
            },             
            schema: {                 
                data: "Companies",                 
                total: "TotalCount",                
                model: {                                      
                    id: 'CompanyID',                     
                    fields: {                         
                        CompanyID:{                             
                            type: 'number',                             
                            nullable: true,                             
                            editable:false                         
                        },                         
                        Name:{                                              
                            type: 'string'                         
                        },                         
                        Rif:{                                              
                            type: 'string'                           
                        },                         
                        Telephone:{                             
                            type: 'string'                         
                        },                         
                        FisicalAddress:{                                             
                            type: 'string'                         
                      }                     
                    }               
                }             
            },             
            pageSize: 1         
        });         

        $("#grid").kendoGrid({             
            dataSource: dataSource,             
            height: 250,             
            scrollable: true,             
            sortable: true,             
            filterable: true,             
            pageable: {                 
            input: false,                 
            numeric: true             
          },             
            columns: [ { field: "CompanyID",  title: "#",  width: 150 },
                       { field: "Name", title: "Name", width: 150   },                            
                       { field: "Rif", width: 150 },
 { field: "Telephone", title: "Telephone"},
                       {  field: "FisicalAddress", width: 300 }]
    });
});

and this is my code in server side:

public JsonResult GetAll(
{            
    var companies = _companyService.GetAll().Select(c => new { c.CompanyID, c.Name, c.Rif, c.Telephone, c.FiscalAddress});
     return Json(new { Companies = companies, TotalCount = companies.Count()},JsonRequestBehavior.AllowGet);
}

Error description in file kendo.web.min.js or kendo.data.min.js
Microsoft JScript runtime error: Object doesn't support property or method '_observe'

Any idea what may be happening? Thank you for help
Rosen
Telerik team
 answered on 10 Oct 2012
3 answers
150 views
i want to make popup editor with additional field, look it :
script grid kendo :
....
editable: { mode: "popup", template: kendo.template($("#popup_editor").html()) },
height: 450, filterable: true, sortable: true, pageable: true,
        toolbar: [{text: "Add data", name: "create"}],
        columns: [
            { field: "name",title: "Name", filterable: true },
            { field: "dtcreate",title: "Date create", filterable: true },
            { command: [{text:"Edit", name:"edit"}, {text:"Delete",name:"destroy"}], title: " ", width: "160px" }
        ]
script form popup :
<script id="popup_editor" type="text/x-kendo-template">
        <div class="k-edit-label"><label for="name">Name</label></div>
    <input type="text" class="k-input k-textbox" name="name" data-bind="value:name">
                 
    <div class="k-edit-label"><label for="publish">Publish</label></div>
    <input type="text" class="k-input k-textbox" name="publish" data-bind="value:publish">
             
    <div class="k-edit-label"><label for="dtcreate">Date Create</label></div>
    <input type="text" name="dtcreate" data-type="date" data-bind="value:dtcreate" data-role="datepicker" />
</script>  

So the problem is popup editor can't showed, why?

Thank,
Ä m o l
Top achievements
Rank 2
 answered on 10 Oct 2012
6 answers
633 views
We are running into an issue with Google Maps and Kendo UI where the pinch to zoom stops working correctly and as you move the map the tiles stop loading. Leaving my same code if I remove Kendo UI everything works correctly. Has anyone ran into this issue? If so do you have any work arounds?
Davide
Top achievements
Rank 1
 answered on 10 Oct 2012
1 answer
290 views
Does anyone know of an example where you can move rows between two grids (left/right)?  In the attached image I've got two select boxes but I want to turn them into grids with a row event that moves them left or right.  Any pointers would be greatly appreciated.
Ä m o l
Top achievements
Rank 2
 answered on 10 Oct 2012
1 answer
189 views
Hi,

I have downloaded kendoui.trial.2012.2.710. I went to the examples of Bubble Chart. 

Can we have the below features if we buy it?
  1. Selection Tool
  2. Zoom In/Out in the selected area from the chart
  3. Drag the area (like in Google Map).

Thanks and regards,
A M Shrestha | ShresthaBros. | Kathmandu | Nepal
info@shresthabros.com | www.shresthabros.com | 
+9779841493286  
Nohinn
Top achievements
Rank 1
 answered on 10 Oct 2012
4 answers
149 views
In the navigate event how do you tell what month the user naviagted to?
Georgi Krustev
Telerik team
 answered on 10 Oct 2012
1 answer
120 views
Hi,

Is there a way I could make the date part from the date time picker bold?

I have attached an image with what I would like to do.
  
Thank you,
Jayesh Goyani
Top achievements
Rank 2
 answered on 10 Oct 2012
0 answers
121 views
Hi,

I have a column in the grid that contains icons.These icons are updated properly on a button click , the latter is outside the grid.
However if I now sort the grid, the icons are not updated. I used  the below code  to update an Icon in a button click event.

$("#Img_" + ModId).attr("src", $.url("Content/images/Active.png")) 


Is this a problem with my code or sort function ? Please let me know.
Hari
Top achievements
Rank 1
 asked on 10 Oct 2012
2 answers
205 views
Hii,

Look at this :
$(document).ready(function () {
     var crudServiceBaseUrl = "http://demos.kendoui.com/service",
     dataSource = new kendo.data.DataSource({
     transport: {
            read:  {
                     url: crudServiceBaseUrl + "/Products",
                     dataType: "jsonp"
            },                  
            create: {
                     url: crudServiceBaseUrl + "/Products/Create",
                     dataType: "jsonp"
            },
.....

i'am using PHP, so how to retrieve data jsonp in page /Products/Create?
i want to insert that data to database

Thank,
rooney
Top achievements
Rank 1
 answered on 10 Oct 2012
1 answer
420 views
TL;DR - I want to provide a custom field name but use the built-in validation messages.  

I am trying to customize the validation messages displayed by the Kendo validator in a mobile application.

I've created a JsFiddle (http://jsfiddle.net/jeremy_wiebe/6nw8s/) to help show what's going on and the options for specifying validation options.  

  1. Don't provide anything, just let Kendo build the message using the input element's 'name' attribute.  This is sub-optimal because the 'name' attribute doesn't allow spaces in it and 'customerNumber1 is required' doesn't look good.
  2. Specify a 'title' on the input.  This is a start but kendo uses _only_ the 'title' attribute value for all validation messages.  This is again sub-optimal when the input may become invalid for multiple reasons (required, min/max values, incorrect format, etc).  Try putting '-100' the second field to see what I mean.
  3. Put a 'validationMessage' attribute on the input.  As far as I can tell this is identical to doing #2.  So it has the same shortcomings.
  4. Add custom data-{rule}-msg attributes for each type of validation you  might have on the attribute.  This solves the problem at the cost of making more verbose HTML.  Now I have to put a custom validation message on each HTML input form for each validation rule I have.
Looking at the Kendo source I see that there's an object that stores the built-in validation rule messages.  These messages use the kendo formatting (see the _extractMessage function) to display a message and  have placeholders for the field name as well as any other dynamic validation bits that may be applicable for the message.

So, what I'd like to be able to do is specify the 'title' attribute on the input (referring to my JSFiddle I'd use 'Customer #' from the second <input>) and have the kendo validator use that as the field name when it formats the built-in validation messages.  In this way the second input would show 'Customer # is required' if the field is empty and 'Customer # should be greater than or equal to 1' if the value is -11.  

Is there any way to accomplish this as the code is now?
Veronica
Top achievements
Rank 1
 answered on 09 Oct 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
Chat
MultiColumnComboBox
Dialog
DateRangePicker
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Accessibility
Effects
PivotGridV2
Licensing
ScrollView
Switch
TextArea
BulletChart
QRCode
ResponsivePanel
Wizard
CheckBoxGroup
Localization
Barcode
Breadcrumb
Collapsible
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
TimePicker
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
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
SmartPasteButton
PromptBox
SegmentedControl
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?