Telerik Forums
Kendo UI for jQuery Forum
1 answer
110 views
Hi ,

I am having a problem in Kendo grid inline editor mode. When I click on Edit button the rendered html do not show three spans having classes "k-widget k-numerictextbox", "k-numeric-wrap k-state-default" and "k-select" respectively. Please share what can cause this problem and how to resolve it.

Thanks,
Akhtar
Akhtar
Top achievements
Rank 1
 answered on 22 Dec 2014
5 answers
89 views
Hello,

I am using a Kendo UI grid, however, the filter option does not work. 

I have attached the cshtml code and controller code to this forum.
Please can you take a look and let me know why the filter does not work. Infact, nothing other than the sorting option works for me.

Thank you!

Regards,
Reshma






CPM Australia
Top achievements
Rank 1
 answered on 22 Dec 2014
5 answers
291 views
Hi guys,

I have a complex scenario where a kendo grid is getting loaded inside of an iframe (the base of the application is in Silverlight, so we use telerik's HTML placeholder to load pages that were developed in html/javascript).

On the columns that are text, the integrated filters input text boxes stop responding to the user mouse click the second time the page is loaded inside the iframe. If I use the TAB key I can make the input gain focus normally.

If I click on one of the other filters (non-text) input boxes the text filters now respond to the click event.

If I reload the page it all works fine.

On other browsers it all works as expected. There are no errors on the console. Inspecting the html element everything seems correct (I cannot detect any differences before and after).

Any idea what the issue is and is there a workaround.

Kendo version: 2014.2.716
Guga
Top achievements
Rank 1
 answered on 22 Dec 2014
3 answers
503 views
Hi there,

We are trying out kendo to see if it meets our needs.

Using the Diagram control I have added a couple of shapes containing information that I don't want a user to remove or edit.

Can I 
a. Disable deleting of certain shapes
b. Disable moving of certain shapes.


Thanks
T. Tsonev
Telerik team
 answered on 19 Dec 2014
3 answers
1.1K+ views
I am using the upload in multiple places, but usually only passing one or two integers along with the uploaded document, and that works.

On this new page I am building, I need to upload the document, but with over 20 fields, and a couple collections of records.
Normally we will create an object, and JSON.stringify it to pass it to the Controller, like this...

Javascript
var obj = {};
obj.ID = 1;
obj.Name = "Joe";
var DTO = { 'DTO': obj };
 
$.ajax({
    type: "POST",
    contentType: 'application/json;charset=utf-8',
    url: "/Controller/Method",
    dataType: "json",
    data: JSON.stringify(DTO),
    success: function (data) {
        // do stuff
    },
    complete: function () {
        // do stuff
     }
});
Controller
public JsonResult Method(SomeClass DTO){
    // do stuff
}
This all works, but when I try to do the same thing when uploading a file, I get a null object...

Javascript
$("#contractUpload").kendoUpload({
    multiple: false,
    showFileList: false,
    localization: {
        select: GetUploadSelectText(),
        dropFilesHere: "Drop File Here"
    },
    async: {
        saveUrl: '/Contract/UploadFile',
        autoUpload: true
    },
    select: function (e) {
        // check file types
    },
    upload: function (e) {     
        // get values from page into a DTO
        var SaveContract = {};
        SaveContract.bdID = $("#hidBDID").val();
        SaveContract.DocumentType = $("#hidContractType").val();
 
        //billing terms
        var billingTermsViewModel = {};
        billingTermsViewModel.ContractID = window.billingTermsModel.ContractID;
 
        //save deleted rows
        var removedBillingTerms = [];
        $.each(window.removedBillingTerms.data(), function (index, value) {
            var removedBillingTermsItem = {};
            removedBillingTermsItem = value.ID;
            removedBillingTerms.push(removedBillingTermsItem);
        });
        billingTermsViewModel.RemovedBillingTerms = removedBillingTerms;
 
        //look through any rows that have been updated and send the updates to the view model
 
        var directBillingTerms = [];
        $.each(window.dataSourceDirectBillingTerms.data(), function (index, value) {
            if (value.dirty == true || value.ID == 0) {
                var directBillingTermsItem = {};
                var stipulatedTermItem = {};
                directBillingTermsItem.ID = value.ID;
                directBillingTerms.push(directBillingTermsItem);
                value.dirty = false;
            }
        });
 
        var indirectBillingTerms = [];
        $.each(window.dataSourceIndirectBillingTerms.data(), function (index, value) {
            if (value.dirty == true || value.ID == 0) {
                var indirectBillingTermsItem = {};
                var stipulatedTermItem = {};
                indirectBillingTermsItem.ID = value.ID;
                indirectBillingTerms.push(indirectBillingTermsItem);
                value.dirty = false;
            }
        });
 
        billingTermsViewModel.RemovedBillingTerms = removedBillingTerms;
        billingTermsViewModel.DirectBillingTerms = directBillingTerms;
        billingTermsViewModel.IndirectBillingTerms = indirectBillingTerms;
        SaveContract.BillingTermsViewModel = billingTermsViewModel;
 
        var DTO = { 'DTO': SaveContract };
         
        e.data = { doc: e.files[0].rawFile, DTO: JSON.stringify(DTO) };
    },
    success: function(data) {
        //do stuff
    },
    error: function (e) {
        //do stuff
    }
});
Controller
[HttpPost]
public ActionResult UploadFile(IEnumerable<HttpPostedFileBase> files, HttpPostedFileBase doc, SaveContract  DTO) {
    // when i get here, DTO is null
}

When I get to the controller, my object is null. 

Is there a way to pass an object like this through the upload?
Dimiter Madjarov
Telerik team
 answered on 19 Dec 2014
3 answers
1.6K+ views
I have the following object for configuration and code, but when the grid renders, the column headers look fine...but the rows show up as a single row of "undefined" repeated for each entry.  Please help.

configuration object:
{"dataSource":{"data":[{"s":"http://en.wikipedia.org/wiki/Une_Histoire_de_vent","o":"en","p":"http://purl.org/dc/elements/1.1/language","id":0},{"p":"http://www.w3.org/1999/02/22-rdf-syntax-ns#type","s":"http://en.wikipedia.org/wiki/Une_Histoire_de_vent","o":"http://xmlns.com/foaf/0.1/Document","id":1},{"o":"http://dbpedia.org/resource/Une_Histoire_de_vent","s":"http://en.wikipedia.org/wiki/Une_Histoire_de_vent","p":"http://xmlns.com/foaf/0.1/primaryTopic","id":2},{"p":"http://www.w3.org/2002/07/owl#someValuesFrom","s":"b0","o":"http://www.w3.org/2006/03/wn/wn20/schema/AdverbWordSense","id":3},{"s":"b0","o":"http://www.w3.org/2006/03/wn/wn20/schema/containsWordSense","p":"http://www.w3.org/2002/07/owl#onProperty","id":4},{"p":"http://www.w3.org/1999/02/22-rdf-syntax-ns#type","o":"http://www.w3.org/2002/07/owl#Restriction","s":"b0","id":5},{"o":"http://xmlns.com/foaf/0.1/Document","s":"http://en.wikipedia.org/wiki/2006_White_House_Correspondents'_Association_Dinner","p":"http://www.w3.org/1999/02/22-rdf-syntax-ns#type","id":6},{"p":"http://purl.org/dc/elements/1.1/language","s":"http://en.wikipedia.org/wiki/2006_White_House_Correspondents'_Association_Dinner","o":"en","id":7},{"p":"http://xmlns.com/foaf/0.1/primaryTopic","s":"http://en.wikipedia.org/wiki/2006_White_House_Correspondents'_Association_Dinner","o":"http://dbpedia.org/resource/2006_White_House_Correspondents'_Association_Dinner","id":8},{"o":"http://www.w3.org/2006/03/wn/wn20/schema/WordSense","s":"b1","p":"http://www.w3.org/2002/07/owl#someValuesFrom","id":9}],"pageSize":25,"schema":{"model":{"fields":[{"s":{"type":"string"}},{"p":{"type":"string"}},{"o":{"type":"string"}}]}}},"height":400,"scrollable":true,"sortable":true,"filterable":true,"pageable":{"input":true,"numeric":false},"columns":[{"field":"s","title":"s"},{"field":"p","title":"p"},{"field":"o","title":"o"}]}

And here is my code:
        var columns = [];
        var fields = [];
        
        $.each(data.results.head.vars, function(index, value) {
          columns.push({'field': value, 'title': value});
          var to = {};
          to[value] = {type: "string"};
          fields.push(to);
        });
        
        var dataBindings = [];
        $.each(data.results.results.bindings, function(index1, value) {
          var tempobj = {};
          $.each(value, function(k1,v1) {
            tempobj[k1] = v1.value;
          });
          tempobj.id=index1;
          dataBindings.push(tempobj);
        });
        
        console.log(JSON.stringify(dataBindings));
        var configuration = {
          dataSource: {
            data: dataBindings,
            pageSize: 25,
            schema: {
              model: {
                fields: fields
              }
            },
          },
          height: 400,
          scrollable: true,
          sortable: true,
          filterable: true,
          pageable: {
            input: true,
            numeric: false
          },
          'columns': columns
        };
        
        console.log(JSON.stringify(configuration));
        
        // Create the popup window
        var gridWindow = $("#resultsPopup").kendoWindow({
          width: "70%",
          title: "Graph Results",
          actions: [
              "Minimize",
              "Maximize",
              "Close"
          ]
        }).data('kendoWindow');
        
        gridWindow.center().open();
        
        // Create the grid
        var grid = $("#resultsGrid").kendoGrid(configuration).data('kendoGrid');

Rosen
Telerik team
 answered on 19 Dec 2014
1 answer
101 views
I'm not sure this is the correct channel for this, but I didn't find a dedicated issues reporting channel.
I believe there's an issue with Kendo-UI Grid and reordering columns when there are multi-headers.

I encountered it during my test project evaluating the package.
I can demonstrate this with-in the demos.  Follow these steps: 

1. Open http://dojo.telerik.com/@zagzag999/UcurU or use the attached html source.
2. Move the column "Contact Name" in between the "Location" and "Contact Details" (columns with Multi-Headers).
3. Move the "Contact Details" column to be after the "Location" again.
!!  Note that the headers don't match the data columns. 
The Phone column jumped into the "Location" group and City column is now under "Contact Details"
Rosen
Telerik team
 answered on 19 Dec 2014
11 answers
728 views
Hello Ninjas,

I'm new to Kendo UI and I am having a hard time digesting how DataSource, Model and ViewModel are intended to be used.

1. what's the point of Models in Kendo UI when all of the documented examples seem to store data everywhere!

For example:

var viewModel = kendo.observable({name: "John Doe"});

Shouldn't "John Doe" live inside a model?

2. Do you need to define a model when defining a DataSource or does the DataSource act as a model?
If the DataSource will return data, why do I need to define a model?

3. If ObservableObject is used to respond to events on the view and Model inherits ObservableObject, am I correct in saying that Models can do everything that ObservableObjects can do, and more? So why even use ObservableObject in the first place?

4. Is "ViewModel" referred to as "new kendo.data.ObservableObject({...})"?
Petyo
Telerik team
 answered on 19 Dec 2014
1 answer
425 views
is there any way to make each node a checkbox and then be able to determine which nodes are checked?
Nikolay Rusev
Telerik team
 answered on 19 Dec 2014
3 answers
808 views
I'm using Kendo Editor content to generate PDF. The PDF looks awkward because of line-height. 

How to handle line-height in Editor?
Dimo
Telerik team
 answered on 19 Dec 2014
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
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?