Telerik Forums
Kendo UI for jQuery Forum
1 answer
182 views
Can you change a column title once the grid has been created?  I have tried setting the title property on the column object but it doesn't seem to have an effect.  I have attached a modified example taken from the basic grid example.
Boyan Dimitrov
Telerik team
 answered on 20 Jun 2016
2 answers
135 views

Hi all,

 

I am new to Kendo UI Calendar and I am facing what could be a standard behavior.

When the user clicks on an item on the calendar and a pop up opens to allow the item to be edited, the item becomes invisible in the calendar, once the item is edited, saved and the pop up closes, the item reappears on the calendar.

I would like the item to remain visible while being edited.

Is there a way around it?

 

Thanks 

Alex Hajigeorgieva
Telerik team
 answered on 20 Jun 2016
1 answer
514 views
Kendo UI Editor refresh method doesn't update the toolbar layout. I needed to do a`$(window).trigger('resize');` to make the editor update its toolbar layout. (showing, hiding hamburger menu based on device width)
Konstantin Dikov
Telerik team
 answered on 20 Jun 2016
1 answer
121 views
When my grid has a vertical scroll bar the row cells and the headers are misaligned. I understand that they are rendered as two separate things but how do I tell the grid to compensate the headers as well as the rows for the scroll bars?
Dimiter Topalov
Telerik team
 answered on 20 Jun 2016
1 answer
560 views

We have a C# MVC application that allows employees to enter hours spent per day on various activities for a given week (see the attached screenshot). However, one of the requirements of the application is that it update our Enterprise Resource Planning (ERP) system that we currently use. These updates must go into an intermediate table between this application and the ERP system. A stored procedure then picks up the data from this intermediate table and updates the ERP system appropriately. The trouble we are running into is getting the data accurately into the intermediate table. It needs the data put in as daily totals...

Date             Hours

6/1/2016       9

6/2/2016       8

6/3/2016       8.5

Can I mark every row in the grid as changed, whether it has changed or not, so that all the rows get sent over to my controller? We'd like to do this to make the processing of the data that's going into the intermediate table easier. Or, is it possible to send over the "Daily Totals" row in the footer? These are fields that are set on the DataSource using the built in Aggregates method. Our DataSource is configured as follows...

.DataSource(dataSource => dataSource
            .Ajax()
            .Aggregates(aggregates =>
            {
                aggregates.Add(t => t.Sunday).Sum();
                aggregates.Add(t => t.Monday).Sum();
                aggregates.Add(t => t.Tuesday).Sum();
                aggregates.Add(t => t.Wednesday).Sum();
                aggregates.Add(t => t.Thursday).Sum();
                aggregates.Add(t => t.Friday).Sum();
                aggregates.Add(t => t.Saturday).Sum();
                aggregates.Add(t => t.TotalHours).Sum();
            }
            )
            .Batch(true)
            .ServerOperation(false)
            .Events(events => events.Error("timesheetGrid_error_handler"))
            .Events(events => events.Change("timesheetGrid_change"))
            .Events(events => events.RequestEnd("timesheetGrid_requestEnd"))
            .Model(model => model.Id(t => t.rowId))            
            .Create(create => create.Action("Index_Create", "Home").Data("getCreateParams"))
            .Destroy(destroy => destroy.Action("Index_Delete", "Home").Data("getUpdateParams"))
            .Read(read => read.Action("Index_Read", "Home").Data("getReadParams"))
            .Update(update => update.Action("Index_Update", "Home").Data("getUpdateParams"))
        )

 

Danail Vasilev
Telerik team
 answered on 20 Jun 2016
1 answer
282 views

Hello Telerik,

I want use event features in Kendo UI calendar.

Example-

First Requirement - For attendance showing I want show on every date 

P - Present

A - Absent

FH, SH - first half, second half

L - leave 

Second Requirement - suppose I am going to click on P (present date) after click on that i want show the other details on same page or open popup or dialog for show IN Time and OUT Time details.

Please let me know about these two requirement how can I achieve the same using Kendo UI.

 

Thanks

Dimiter Topalov
Telerik team
 answered on 20 Jun 2016
1 answer
141 views

Hello Telerik,

I was using in Date Range Selection, Single Selection and No Selection (Read Only) Telerik Calendar in native android app. But Now I am moving to Cordova based hybrid application so that I am using Kendo UI for Calendar in that. Please let me know How I will achieve this things with Kendo UI for Hybrid App(Android & iOS)

Please let me know asap

Thanks

Georgi Krustev
Telerik team
 answered on 20 Jun 2016
5 answers
1.5K+ views
Hi Telerik,

are you planning to implement charts with 3D look, like FusionCharts?
If yes, in which release?

Regards,
Ingo
Iliana Dyankova
Telerik team
 answered on 20 Jun 2016
1 answer
1.0K+ views

Hello Telerik,

I want to apply date cell background colour according to working shift.

like -

General Shift - Green Background for all General shift date.

Holiday - Blue Background for all Holiday shift date.

Week Off - Red Background for all Week Off shift date.

Please guide me how can I achieve the same using Kendo UI calendar.

 

Thanks

 

Dimiter Topalov
Telerik team
 answered on 20 Jun 2016
1 answer
311 views

I'm having an issue with CRUD calls being repeated. It only happens if I make two CRUD calls in a row, the second one pulls in the first one's data. For example, if I have a grid that has three records on it:

1. I hit delete on the first record which successfully deletes that record, no issues (note that I AM returning the ID of that record back to the grid)

2. I hit delete on the second record and it uses that model's data of the first record. Entity framework of course throws an error because it can no longer find that entity since it was deleted in the first call.

controller:

public ActionResult CostsDestroy(string models)
{
    JavaScriptSerializer serializer = new JavaScriptSerializer();
    CapitalLeaseCostModel model = new CapitalLeaseCostModel();
    var CapitalLeaseCostModelArray = serializer.Deserialize<CapitalLeaseCostModel>(models);
    model = AccountingService.DeleteCapitalLeaseCost(CapitalLeaseCostModelArray);
 
    return PartialView(Json(model));
}

 

View:

@model DataNet.Common.Models.CapitalLease.CapitalLeaseCostModel
 
 
@*grid script*@
<script>
 
    $(document).ready(function () {
 
        dataSource = new kendo.data.DataSource({
            transport: {
                read: {
                    url: "/CapitalLease/CostsRead",
                    dataType: "json"
                },
                update: {
                    url: "/CapitalLease/CostsUpdate",
                    dataType: "json",
                    type: "POST",
                    complete: function (e) {
                        var grid = $('#capitalizedCostGrid').data("kendoGrid");
                        grid.dataSource.read();
                    }
                },
                destroy: {
                    url: "/CapitalLease/CostsDestroy",
                    dataType: "json",
                    type: "POST",
                    complete: function (e) {
                        e.success(data);
                        var grid = $('#capitalizedCostGrid').data("kendoGrid");
                        grid.dataSource.read();
                    }
                },
                create: {
                    url: "/CapitalLease/CostsCreate",
                    dataType: "json",
                    type: "POST",
                    complete: function (e) {
                        e.success(data);
                        var grid = $('#capitalizedCostGrid').data("kendoGrid");
                        grid.dataSource.read();
                    }
                },
                parameterMap: function (options, operation) {
                    if (operation !== "read" && options.models) {
                        options.models[0].StartDate = kendo.toString(kendo.parseDate(options.models[0].StartDate, 'yyyy-MM-dd'), 'MM/dd/yyyy');
                        options.models[0].EndDate = kendo.toString(kendo.parseDate(options.models[0].EndDate, 'yyyy-MM-dd'), 'MM/dd/yyyy');
                    }
                    if(operation === "create" && options.models){
                        options.models[0].EscalationTypeID = options.models[0].EscalationTypeID.ID;
                        options.models[0].EscalationFrequencyID = options.models[0].EscalationFrequencyID.ID;
                    }
                    if (operation === "destroy" && options.models) {
                        return { models: kendo.stringify(options.models[0]) };
                    } else {
                        return { models: kendo.stringify(options.models), keyID: 106715 };
                    }
                }
 
 
            },
            batch: true,
            pageSize: 20,
            schema: {
                model: {
                    id: "ID",
                    fields: {
                        ID: { editable: true, nullable: false, defaultValue: -1 },
                        Reason: { validation: { required: true } },
                        CapitalLeaseEscalationType: {
                            defaultValue: {
                                ID: 1,
                                EscalationType: "No Escalation"
                            }
                        },
                        CapitalLeaseEscalationFrequency: {
                            defaultValue: {
                                ID: 1,
                                EscalationFrequency: "Monthly"
                            }
                        },
                        EscalationTypeID: {
                            defaultValue: {
                                ID: 1,
                                EscalationType: "No Escalation"
                            }
                        },
                        EscalationFrequencyID: {
                            defaultValue: {
                                ID: 1,
                                EscalationFrequency: "Monthly"
                            }
                        }
                    }
                }
            }
        });
 
        $("#capitalizedCostGrid").kendoGrid({
            dataSource: dataSource,
            toolbar: ["create"],
            columns: [
            {
                field: "ID",
                title: "ID",
                hidden: true
 
            },
            {
                field: "Reason",
                title: "Reason"
            },
            {
                field: "Amount",
                title: "Amount",
                format: "{0:c}"
            },
            {
                field: "StartDate",
                title: "Start Date",
                type: "date",
                format: "{0:yyyy-MM-dd}",
                template: "#= kendo.toString(kendo.parseDate(data.StartDate, 'yyyy-MM-dd'), 'MM/dd/yyyy') #",
                editor: dateTimeEditor
                 
            },
            {
                field: "EndDate",
                title: "End Date",
                type: "date",
                format: "{0:yyyy-MM-dd}",
                template: "#= kendo.toString(kendo.parseDate(data.EndDate, 'yyyy-MM-dd'), 'MM/dd/yyyy') #",
                editor: dateTimeEditor
            },
            {
                field: "EscalationTypeID",
                title: "Escalation Type",
                editor: escalationTypeDropDownEditor,
                template: "#=CapitalLeaseEscalationType.EscalationType#"
            },
            {
                field: "EscalationFrequencyID",
                title: "Escalation Frequency",
                editor: frequencyTypeDropDownEditor,
                template: "#=CapitalLeaseEscalationFrequency.EscalationFrequency#"
            },
            {
                field: "EscalationPercentage",
                title: "Escalation Percent",
                template: "<div> #= kendo.toString(data.EscalationPercentage / 100, 'p0') #</div>"
            },
            {
                field: "EscalationMonetary",
                title: "Monetary Escalation",
                format: "{0:c}"
            },
            {
                command: ["edit", "destroy"], title: "Edit", width: "200px"
            }
            ],
            editable: "popup",
            edit: function (e) {
                e.container.find(".k-edit-label:first").hide();
                e.container.find(".k-edit-field:first").hide();
            },
            height: 200,
            autoSync: true
 
        })
 
        @*Attaches to Escalation type drop down list*@
        function escalationTypeDropDownEditor(container, options) {
        $('<input required data-text-field="EscalationType" data-value-field="ID" data-bind="value:' + options.field + '"/>')
            .appendTo(container)
            .kendoDropDownList({
                autoBind: true,
                dataSource: {
                    type: "json",
                    transport: {
                        read: "/CapitalLease/CostsEscalationTypeRead"
                    }
                }
            });
        }
 
        @*Attaches to Escalation Frequency drop down list*@
        function frequencyTypeDropDownEditor(container, options) {
        $('<input required data-text-field="EscalationFrequency" data-value-field="ID" data-bind="value:' + options.field + '"/>')
            .appendTo(container)
            .kendoDropDownList({
                autoBind: true,
                dataSource: {
                    type: "json",
                    transport: {
                        read: "/CapitalLease/CostsEscalationFrequencyRead"
                    }
                }
            });
        }
 
        @*Formats the date-picker in-grid*@
        function dateTimeEditor(container, options) {
        $('<input data-text-field="' + options.field + '" data-value-field="' + options.field + '" data-bind="value:' + options.field + '" data-format="' + options.format + '"/>')
                .appendTo(container)
                .kendoDatePicker({});
        }
 
    });
 
 
</script>
 
<style>
    .k-grid  .k-grid-header  .k-header  .k-link {
        height: auto;
    }
   
    .k-grid  .k-grid-header  .k-header {
        white-space: normal;
    }
</style>
 
 
@*Rent Information*@
<p class="title">Section Two - Lease Costs to Capitalize</p>
<div style="padding:15px;">
    <div id="costsRowOne">
        <div id="capitalizedCostGrid" class="inline-control"></div>
    </div>
</div>

 

What am i missing here. 

 

Vi Le
Top achievements
Rank 1
 answered on 18 Jun 2016
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?