Telerik Forums
Kendo UI for jQuery Forum
9 answers
847 views
Hello all!

I'm currently running into an issue with the latest version of Kendo UI (2013.3.1119).  In the previous version I used Kendo window as a form entry and used the bootstrap 3 form group as the layout.  My expected results are attached.  The code used inside the window is as follows.

<div class="form-horizontal" role="form">
        <div class="form-group">
            @Html.Label("Entry Type", htmlAttributes: new { @class = "col-lg-2 control-label" })
            <div class="col-lg-10">
                @(Html.Kendo().DropDownList()
                    .Name("ddlEntryType")
                    .HtmlAttributes(new { @required = "required", @style = "width: 100%" })
                    .OptionLabel("Select Course Type...")
                    .DataTextField("Text")
                    .DataValueField("Value")
                    .BindTo(new List<SelectListItem>() {
                        new SelectListItem() {
                            Text = "Manual",
                            Value = "Manual"   
                        },
                        new SelectListItem() {
                            Text = "Temporary Access",
                            Value = "Temporary"
                        }
                    })
                )
            </div>
        </div>
        <div class="form-group">
            @Html.Label("Select Course", htmlAttributes: new { @class = "col-lg-2 control-label" })
            <div class="col-lg-10">
                @(Html.Kendo().DropDownList()
                    .Name("ddlCourses")
                    .HtmlAttributes(new { @required = "required", @style = "width: 100%" })
                    .OptionLabel("Select Course...")
                    .DataTextField("Name")
                    .DataValueField("ID")
                    .DataSource(dataSource =>
                    {
                        dataSource.Read(read =>
                            {
                                read.Action("GetCourseList", "Home", new { @personID = ViewBag.PersonID })
                                    .Data("filterCourses");
                            })
                            .ServerFiltering(true);
                    })
                    .Enable(false)
                    .AutoBind(false)
                    .CascadeFrom("ddlEntryType")
                )
            </div>
        </div>
        <div class="form-group">
            @Html.Label("Completed Date", htmlAttributes: new { @id = "lblCompletedDate", @class = "col-lg-2 control-label" })
            <div class="col-lg-10">
                @(Html.Kendo().DatePicker().Name("dpCompletedDate").Value(DateTime.Now))
            </div>
        </div>
        <div class="form-group">
            @Html.Label("Course Site", htmlAttributes: new { @class = "col-lg-2 control-label" })
            <div class="col-lg-10">
                @Html.TextBox("txtCourseSite", "", htmlAttributes: new { @placeholder = "ex. Nationwide Children's Hospital, CITI, or OSU", @required = "required", @class = "form-control" })
            </div>
        </div>
        <div class="form-group">
            <div class="col-lg-offset-2 col-lg-10">
                <button type="button" class="btn btn-default" onclick="closeAddCompletedCourse(this);">Cancel</button>
                <button type="submit" class="btn btn-primary">Add</button>
            </div>
        </div>
    </div>

After updating to the latest version I got a different result which is also attached.  What you will see is the horizontal grouping is now breaking in the window.  I did find a temporary fix which was to decrease the col size that is holding the control from 10 to 8.  The bootstrap grid is 12 so the previous code should have worked.  I'm just curious if I'm missing something or if this is an issue in the latest version of Kendo UI.

Thanks in advance for your help!
Neil
Top achievements
Rank 1
 answered on 26 Mar 2014
7 answers
225 views
I have a stock chart where I'm showing values from two years for comparison.  In my json, I have a field that shows the delta between the two values, ((thisyear - lastyear) / lastyear)

The problem I have is when the user zooms out of the chart, the delta gets aggregated incorrectly.

I want to know if I can create a series and add the formula that I showed, and have the chart calculate the delta instead of adding it to the json object.
Jonathan Travis
Top achievements
Rank 1
 answered on 26 Mar 2014
11 answers
1.8K+ views

We have a datasource that has groups and aggregates specified.

dataSourcePipeline = new kendo.data.DataSource({             
    transport: {
        read: {
            url: "/Market/Pipeline",
            dataType: "json",
            type: "get",
            cache: true,
            data: {
                zip: zip
            }
        }
    },
    group: { field: "Stage", dir: "desc", aggregates: [
                { field: "PropertyName", aggregate: "count" },
                { field: "Area", aggregate: "sum"}]
    },
    aggregate: [ { field: "PropertyName", aggregate: "count" }, { field: "Area", aggregate: "sum" } ],
    sort: { field: "Area", dir: "desc" }
});

We have a grid bound to that datasource and is configured to allow grouping. Further, we have specified a groupFooterTemplate for one of the columns that displays the aggregate.

$("#marketPipeline").kendoGrid({
     dataSource: dataSourcePipeline,
     groupable: true,
     scrollable: false,
     sortable: { mode: "multiple" },
     filterable: true,
     columns: [
             { field: "PropertyName", title: "Property Name", template: '<div style="cursor: pointer;" class="pipelinePopupTrigger" rel="#=ID#"><img src="/Content/images/mapIcon.png" height="20" style="cursor: pointer; padding-right: 10px;" title="Show on map" onClick="CenterMap(#=Lat#,#=Lng#,\'PIPELINE\',\'#=ID#\')"/> #=PropertyName#</div>',
                 footerTemplate: "Total Count: #=count#", groupFooterTemplate: "Count: #=count#"
              },
             { field: "Address", title: "Address" },
             { field: "City", title: "City" },
             { field: "ZipCode", title: "Zip Code", width: 100,
                 footerTemplate: "<span style='float:right'>Total Area:</span>",
                 groupFooterTemplate: "<span style='float:right'>Area</span>"
              },
             { field: "Area", title: "Area", template: '<span style="float:right">#= kendo.toString(Area,"N0") #</span>', width: 100,
                 footerTemplate: "<span style='float:right'>#= kendo.toString(sum,'N0') #</span>",
                 groupFooterTemplate: "<span style='float:right'>#= kendo.toString(sum,'N0') #</span>"
             },
             { field: "Subclass", title: "Sub-Class" },
             { field: "Stage", title: "Stage", width: 200 }
         ]
 });

Everything works well until the user removes all groups for the grid. Once they drag a new column to the group area, the grid fails with this error:

count is not defined
/Scripts/kendo/kendo.web.min.js
Line 10

Thoughts?

Alexander Valchev
Telerik team
 answered on 26 Mar 2014
5 answers
342 views
For many reasons I am using a tab strip as action buttons on a form instead of buttons.

First question:

I want to be able to deselect a tab once I have called its action.  For example I have the following snippet.

      <div data-role="footer">
            <div data-role="tabstrip" id="tabstrip" data-select="onTabSelected">
                <a data-icon="home">Save</a>
                <a data-icon="info">Previous</a>
                <a data-icon="details">Next</a>
                <a data-icon="camera">Scan</a>
            </div>
        </div>

And here is the select event

        function onTabSelected(e)
        {
            var index = $(e.item).index();

            console.log("tab index="index);

            if(index == 1)
            {
                    // do something
            }
            else if(index == 2)
            {
                    // do something
            }

            // deselect the tab item so the user can select it again and fire the select event

            return;
        }

Second question:

Can I use standard jquery icons like data-icon="ui-icon-carat-1-e"

Thanks in advance 





Shawn
Top achievements
Rank 2
 answered on 26 Mar 2014
6 answers
240 views
Kendo docs is a nice looking site ... http://docs.kendoui.com/getting-started/changes-and-backward-compatibility

I thought now if I can just make my Kendo Web UI site work like this I'll get a pay rise for sure!

Seems though that each treenode selection triggers a postback and so the entire page is returned along with lots of ugly viewstate.

So now I'm thinking .... how can I use the Kendo UI treeview like this as a page navigator and have it's state persist across postbacks? Do I need to have my "content" page in a frame?
Daniel
Telerik team
 answered on 26 Mar 2014
6 answers
286 views
When a column filter is set to a dropdownlist but no option label is set hitting filter does not filter the grid until the dropdownlist value is changed.  http://trykendoui.telerik.com/ojUV
Ryan
Top achievements
Rank 1
 answered on 26 Mar 2014
1 answer
162 views
After scrolling the window datetimepicker trigger close event immediately after open http://demos.telerik.com/kendo-ui/web/datetimepicker/index.html
Georgi Krustev
Telerik team
 answered on 26 Mar 2014
3 answers
204 views
Greetings,

I just published one of our web apps to a testing server to test the upgrade from 2013.3.1316 --> 2014.1.318. It looks good for the most part. I have found one issue I can not explain. In 2013.3.1316, the application rendered great for ie8,ie9,ie10,ie11, chrome and Firefox. After the latest update it seems all of the browser versions except ie9 are rendering correctly. There seems to be something off with the styling for ie9 standard mode. I have attached a few screenshots.

Thanks
Ross B.
Top achievements
Rank 1
 answered on 26 Mar 2014
1 answer
96 views
I need to subscribe my external edit template to grid edit, in order my update and cancel buttons work, but I don't know how to do it. Any help?

In the attached code I rendered all the information I need and how I wanted it,  but when I click in the update or cancel button, nothing happens.



Daniel
Telerik team
 answered on 26 Mar 2014
2 answers
104 views
We are binding the kendo grid widget to a dataset where columns are identified only by an index (their definitions/content are dynamic and are known only at runtime).

We use the following approach to bind columns:
for (var i = 0; i < 5; i++) {
    var entryIndex = "entries[" + i + "]";
    columns.push({
        field: entryIndex,
        title: "Column " + i
    });
}

Which is a mechanism that is used by others as well.

We just noticed that this approach breaks when aggregates(footerTemplate) are defined on such columns.

Example of such behavior (please uncomment marked code)

Is this a bug that can be fixed in kendo code? 
Is there a workaround you can suggest?

Thanks.

Alexander Popov
Telerik team
 answered on 26 Mar 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?