Telerik Forums
Kendo UI for jQuery Forum
1 answer
1.5K+ views
When I add a new row my date column is getting a default value assigned to it which is the date from when the grid initially loaded and not the current date.  Is this the expected behavior?
Iliana Dyankova
Telerik team
 answered on 31 May 2013
2 answers
263 views
Hi,
I have been trying to launch a window from a base page and the launch window content view will have to be from an action.
With the below code block, I'm getting a blank window, please help in this regard.
fyi... I have converted my existing application to KendoUI using the tool menu upgrade wizard.

<div id="divDocsUploadWindow">
    @(Html.Kendo().Window()
        .Name("DocsUploadWindow")
    .Title("Customer")    
     .Draggable()
    .Resizable()
    .Width(736)
    .Visible(false)
    .Modal(true)
    )
</div>     
the jquery portion:
 $("#btnOpenDocs ").click(function () {           
        var windowWidget = $("#DocsUploadWindow").data("kendoWindow");
        windowWidget.refresh({
             url: "@Url.Action("UploadViewAction", "UploadController")"
        });
        windowWidget.center();
        windowWidget.open();            
    });

view:
@model Models.UploadFile
@{
    ViewBag.Title = "Upload";
}
<h2>_Upload</h2>
<label>test</label>
@(Html.Kendo().Upload()
        .Name("attachments")       
        .Multiple((bool) ViewData["multiple"])
        .Async(async => async
            .Save("Save", "Upload")
            .Remove("Remove", "Upload")
            .AutoUpload((bool) ViewData["autoUpload"])
        )
    )

Thanks,
Subbu.
Subramanian
Top achievements
Rank 1
 answered on 31 May 2013
1 answer
172 views
Hey Guys,

I'm binding a grid to a table (using the kendo-knockout) library and my table has a caption.  Unfortunately when the binding takes place the caption is no longer in the right place.  It stays on the content table thus appearing between the headers and the main table content.

So..
    <table>
        <caption>Caption</caption>
        <thead>...</thead>
        <tbody>...</tbody>
    </table>

Get's rendered as 

Headings
Caption
Data

rather than 

Caption
Headings
Data

as you might expect.

Is there any way to have captions supported.  I can easily overcome this by having my caption above the table in a span or some such but I'd really like to keep my html as semantic as possible.

Chris
Dimiter Madjarov
Telerik team
 answered on 31 May 2013
1 answer
485 views
I have a grid set up with my datasource and working properly with popup editing. My popup has two drop down lists and a number field. What I would like to do is set the value of the number field to a specific value when the user makes their selection from the first drop down list, essentially pre-populating the number value to "highest entered value for the user selected item + 5". 

Is there a way to hook up to the "change" event for the  drop down list in the popup editor and as part of the function for the change event, query the current dataset bound the grid to retrieve a value, then set that value to the numeric field in the popup editor?

Robert 



Daniel
Telerik team
 answered on 31 May 2013
3 answers
138 views
Hi ,
 I'm trying to build a image gallery with options on swipe the image to the next image and prev image location of an array of images.

The best next thing i could find was the following http://www.webresourcesdepot.com/image-gallery-for-mobile-and-touch-devices-photoswipe/
which does the job perfectly on any browser and with custom toolbar where you can add options for close and etc.
The problem is when i compile the kendo application for ipad 2.0 using phonegab and the latest xcode version the gallery opens fine but i have no event custom listeners except the ones the gallery supports.
I mean if on the toolbar i attach a div with a ID and i try call that id onclick or on tap the event doesnt triggers.
The gallery appends classes on the body and adds some html as well.

So i cant find a relative solution to this problem , is there any other gallery someone could suggest to use that runs on kendo ui mobile?





Alexander Valchev
Telerik team
 answered on 31 May 2013
1 answer
6.2K+ views
Hi
I'm using Kendo window in my MVC application. I was wondering if there is any way to fill the content of the window from partialView ?
For example I have a partial view stored in file PartialViewSample.cshtml

@model Product
@using(Html.BeginForm("InsertProduct","Product"))
{
    Html.TextBoxFor(val => val.Name);
    Html.TextBoxFor(val => val.Id);
}

and in some other place I would like to load this content to kendo window.

<button id="addButton">Add</button>
 <script type="text/javascript">
     $(document).ready(function () {
         var window = $("#window").kendoWindow({
             height: "200px",
             modal: true,
             title: "Centered Window",
             visible: false,
             width: "200px"
             
         }).data("kendoWindow");
     });

If the user clicks the button I would like to load content of the window. I was trying to do this that way

    
$("#addButton ").click(function () {
        var window = $("#window").data("kendoWindow");
        window.content("@Html.Partial("PartialViewSample ",new Product()).ToHtmlString()");
        window.center();
        window.open();
    });
Unfortunatelly it doesnt work. Is there any way to load content of the window from using Html.Partial or sth like that ?
Daniel
Telerik team
 answered on 31 May 2013
1 answer
214 views
Hello Telerik,
I have a kendo datasource that will load the following json data

[{"pedidoId":1,"supervisorId":"manuel","vendedorId":"1","clienteId":"1","total":12345.0000,"hora":"12:00"},{"pedidoId":2,"supervisorId":"manuel","vendedorId":"1","clienteId":"1","total":54321.0000,"hora":"12:06"},{"pedidoId":3,"supervisorId":"luis","vendedorId":"2","clienteId":"2","total":4521.0000,"hora":"12:10"}]

Using Mobile ListView Template, I want to display only the grouped data, for example:
<li>supervisorId = manuel, Total = 66666 </li> (that is the result of 12345+ 54321
<li>supervisor Id = luis, Total = 4521 </li>

Please refer to my attach files for the complete code.

Thank you for your help.
Alexander Valchev
Telerik team
 answered on 31 May 2013
3 answers
206 views

i am populating multiple observables and binding them to grids without much problem.  for example i have code like this that i am using to populate a grid:
     var viewModel = kendo.observable({
            partsSource: new kendo.data.DataSource({
                transport: {
                    read: {
                        url: "/api/Parts",
                        dataType: "json"
                    }
                }
            })
        });

this is calling a service that returns IEnumerable<Part>.  if i only want to return a specific part i call my service like this /api/Parts/7 and i know from fiddler that it returns that single part but i can't get it populate my observable.

i guess the issue is that the service now returns only <Part> and not the enumerable.   in fiddler it looks identical to the data used in the examples that seem to work flawlessly but i can't seem to find the proper syntax with remote data.

any ideas?  thanks!


Alexander Valchev
Telerik team
 answered on 31 May 2013
2 answers
55 views
Good morning

I have 2 separate data sources with the same length and same values for the category field.
[{"category":"a","value":1},{"category":"b","value":2},{"category":"c","value":3}]
and
[{"category":"a","value":2},{"category":"b","value":3},{"category":"c","value":4}]

Is it possible to apply these data sources to series1 and series2 on the same line chart?

Thanks.
 Raido

Hristo Germanov
Telerik team
 answered on 31 May 2013
5 answers
487 views
Hi! We want to use treeview with strongly-typed model binding (not AJAX). 
     
This is our TreeView:   
@(Html.Kendo().TreeView().Name("treeviewDepartments")
         .BindTo(Model.Departments, (NavigationBindingFactory<TreeViewItem> mappings) =>
           {
               mappings.For<AddDepartmentTreeModel>(binding => binding.ItemDataBound((item, dapartment) =>
                   {
                       item.Text = dapartment.Name;
                   })
                   .Children(department => department.Departments));
           })
        )
We would like to add new node using this function. 
function addDepartment()
       {
           var treeView = $("#treeviewDepartments").data("kendoTreeView");
 
           var selectedNode = treeView.select();
 
           // passing a falsy value as the second append() parameter
           // will append the new node to the root group
           if (selectedNode.length == 0) {
               selectedNode = null;
           }
 
           treeView.append({
               text: "New department"
           }, selectedNode);
       }
Is it way to bind and submit to server dynamically added treeview nodes with model?
Thanks!
Atanas Korchev
Telerik team
 answered on 31 May 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
Dialog
Chat
DateRangePicker
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
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
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?