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

When I set the dropdownlist width in relative terms say 45%, the drop down appears fine but I am not able to see the list of data and only the scroll bar is visible. dropdownlist is fine when the width is set in px. What could be causing this issue?

J
Anil
Top achievements
Rank 1
 answered on 13 Apr 2012
0 answers
85 views
Hi, exists some way for using a grid where the fields for edition some distinct to fields for adding?
I need a grid with editing popup with some fiels for update, and other fields are for adding.

Thanks
Juan
Top achievements
Rank 1
 asked on 13 Apr 2012
4 answers
1.8K+ views
I am using a simple template and rendering the html using $("#main").html(kendo.render(template, repairs));.  Since I am just dealing with local data, I felt there was no need for a datasource, but when I add an item to the repair array I would like to have it update the html via the template.  I am using $("#main").html(kendo.render(template, repairs));  again to do that right now, but is there a better way?  Thanks.

Wade      
<script id="template" type="text/x-kendo-template">
    <div id="content">
        <div id="RepairNum">
            Repair:#= RepairNum # 
            Customer:#= CustomerName #
        </div>
    </div
</script>

<script>
 
    function Repair(repairNum,customerName) {
        this.RepairNum = repairNum;
        this.CustomerName = customerName;
    }
 
    var repairs = new Array();
    repairs.push(new Repair("111111","Test1"));
    repairs.push(new Repair("222222","Test2"));
    repairs.push(new Repair("333333","Test3"));
     
    $(document).ready(function() {
     
        var template = kendo.template($("#template").html());
        $("#main").html(kendo.render(template, repairs));
         
        $("#addButton").click(function(){
            //Attempt to get the customer name
            var repairNum = $("#repairnum").val();
 
            $.get('/app/json.mx', {RepairNum : repairNum},
                function(data)
                {
                    repairs.push(new Repair(repairNum,data));
                    $("#main").html(kendo.render(template, repairs));  
                });
 
            $("#repairnum").val("");
            $("#repairnum").focus();
 
 
        });
 
    });
</script>

















Alexander Valchev
Telerik team
 answered on 13 Apr 2012
1 answer
612 views
Hi, I'm using the kendo UI grid without using the dataprovider(including the transport object) because we are using server sides pushed data.

All I want to do is when i click delete on the grid, or add, catch that event and do some stuff.

however I can't get the listener to kick off. Iv'e tried 2 methods outlined in the docs, but I think its because i'm not using the data provider?

$("#grid").kendoGrid({
               columns: [
               "Id",
               "HostName",
               "BaseUri",
               { field: null,command: "destroy"}
               ], 
               editable: true,
               remove: function(row) {alert("removed");}
           });
and 
$("#grid").kendoGrid({
     remove
: function(e) {
         
// handle event
 
});
have not been working for me

This is how i'm refreshing the data
$("#grid").data("kendoGrid").dataSource.data(message).read();

I also had the same issue using the toolbar[] to define the destroy button.

Looking at my console it looks like its trying to call destroy in the data provider but again i'm not using that 

  1. h.extend._modelForContainerkendo.all.min.js:11
  2. h.extend.removeRow <- there's the event i'm trying to catchkendo.all.min.js:11
  3. h.extend._editablekendo.all.min.js:11
  4. f.event.dispatchjquery.min.js:3
  5. f.event.add.h.handle.i
Alexander Valchev
Telerik team
 answered on 13 Apr 2012
0 answers
42 views
Hello,

I have a code like this:
<div id="wnd1">
    <div>Click me!</div>
    <script type="text/javascript">alert('executed 1');</script>
</div>
 
<script type="text/javascript">
    (function ($) {
        $("#wnd1").kendoWindow({
            height: "500px",
            width: "400px",
            modal: true,
            draggable: true,
            resizable: false,
            visible: false
        });
    })(jQuery);
</script>

And in this case alert is executed twice. First time because of initial script rendering and second when window is initialized.
Should it be such case and how to prevent it?

Also I can see this window during the second alert, is it ok that window shows and hides when "visible: false"?

Vladimir
Volodymyr Oliinyk
Top achievements
Rank 1
 asked on 13 Apr 2012
1 answer
267 views
I've had a request come in for a client for this feature and wondering on the best way to implement this with the Kendo Grid. I know the demos actually show this, but not actually within the filtering selectable options.

What I'd like is potentially a custom filter (say a customName instead of number/string etc) that I can create, then call on each column to pre-populate certain row data and somehow call this into the Grid API to filter on the selected value. Such as, say, a number will allow you to select a number, a customName attribute will allow you to select from a dropdown list of certain elements.

Is this possible if I delve into the nitty gritty of the Grid API?
Iliana Dyankova
Telerik team
 answered on 13 Apr 2012
0 answers
51 views
Unable to view grid data component in firefox 3.0.19 version.
i am using Kendo UI v2011.3.1129 version.

Please assist me.

Thanks in Advance.
Atit
Top achievements
Rank 1
 asked on 13 Apr 2012
0 answers
110 views
Hi,

I've been using the last version with the MVVM and new DataSource, and I have a problem when adding an entity to a remote DataSource.

After sending the ajax request for adding a new entity, the response is merged with the entity.
This is done in dataSource._accept : 
if (type !== "destroy") {
models[idx].accept(response[idx]);

But the Model.accept will extends the model and will override all observable fields by the response from the server.
I have to modify the Model.accept method like this : 
             if (that instanceof ObservableObject) {
            that.init(data);
            } else {
                extend(that, data);
                if (that.idField) {
                    that.id = that.get(that.idField);
                }
            }

After the modification, my code works but I strongly believe it's not the good way.

Thanks in advance,

Laurent.


Laurent
Top achievements
Rank 1
 asked on 13 Apr 2012
0 answers
61 views
Unable to display Grid data component in firefox 3.0.19 version.
i am using Kendo UI v2011.3.1129 version.

Please assist me.

Thanks in Advance.

Atit
Top achievements
Rank 1
 asked on 13 Apr 2012
0 answers
76 views
Hello-

I'm trying to use Kendo grid and so far it's pretty good.  The one thing I don't heart about it is that when you do
$("#mydiv").kendoGrid( { dataSource: myJsonObjects })
it takes the explicit property name.  For a good user experience, CamelCasing isn't awesome.  Instead, I'd like to have my columns in English, so I would not want
"AccountName" and "ThisIsAColumnThatIsHardToRead"
but rather
"Account Name"  and "This Is a Column That Is Easy To Read".

So I walk my JSON objects and insert spaces in the property names (this is unusual but 'legal' in Javascript).  But when I hand this revamped object list to Kendo, I get an error:
Invalid template: '<tr><td>#=Account
Name"</td><td>#=This Is A Column That Is Easy To
Read</td></tr>'enerated code:'var
o,e=kendo.htmlEncode;with(data){o='<tr><td>'+(Account Name)
+'</td><td>' + (This Is A Column That Is Easy To Read) +
'</td></tr>';>return o;'
Triple
Top achievements
Rank 1
 asked on 13 Apr 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)
SPA
Filter
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
OrgChart
TextBox
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
Popover
DockManager
FloatingActionButton
TaskBoard
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
TimePicker
DateTimePicker
RadialGauge
ArcGauge
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?