Telerik Forums
UI for ASP.NET MVC Forum
3 answers
575 views

I have an editable grid with a custom template:

1..Editable(editable => editable
2.    .Mode(GridEditMode.PopUp)
3.    .Window(w => w.Width(600))
4.    .TemplateName("Inspection")
5. )     
Patrick
Top achievements
Rank 1
 answered on 13 Feb 2018
1 answer
202 views

Hi all.

I tried to select multiple events with the current Firefox and current Safari on the demo site. Without success. CMD-LeftMouseButton doesn't work.

What is the right way to select multiple events?

Kind regards

Bernd

Dimitar
Telerik team
 answered on 12 Feb 2018
3 answers
851 views
How do I control the spacing in between drop-down list items? 
Magdalena
Telerik team
 answered on 12 Feb 2018
1 answer
205 views
When calling ToDatasourceResults it wraps both sides of the filter criteria in LOWER() so that it can do case insensitive queries.  We are using it on a DB2 iSeries database and would like to be able to add indexes to improve the performance of the queries.

 

1. the DB is case sensitive and cannot be changed

2. we can put an upper case index (which would get used) but not a lower case one

I'm looking for some method of changing the LOWER() to UPPER() when using ToDatasourceResults preferably without having to write my own version of it.  Is there anywhere in the code that I can override to modify this behaviour?

Ivan Danchev
Telerik team
 answered on 12 Feb 2018
7 answers
1.6K+ views

I am updating a grid cell with a date value on a button click from a custom command in the row (see code below).  I am able to successfully add the value to the cell but I would like to have the cell show the red triangle in the upper left corner (see attached pic) that shows the user the value in the cell has been edited.

function activate_deactivate(e) {
    e.preventDefault();
    var tr = $(e.target).closest("tr"); //get the row
    var dataItem = this.dataItem($(e.currentTarget).closest("tr"));
    var data = this.dataItem(tr); //get the row data so it can be referred later
 
    var ad = dataItem.ActivatedOn;
 
    if (isDateActive(dataItem.ActivatedOn, dataItem.DeactivatedOn) || !dataItem.DeactivatedOn)
    {
        //set the deactivated date
        var strTodaysDate = getShortDate();
        data.set("DeactivatedOn", strTodaysDate);
    }
    else
    {
        //clear the deactivated date (Now Active)
        data.set("DeactivatedOn", null);
    }
}
Stefan
Telerik team
 answered on 09 Feb 2018
10 answers
1.6K+ views
Hi Kendo community,

I don't really understand how the selected objects out of a multiselect can be sent to the controller. The databinding out of the db works fine and I'm also able to select and remove items in the multiselect. By the way the multiselect is displayed inside a kendo window and posts with an ajax.beginform.

My multiselect looks like this:

@model SoftwareAdminInterface.Models.Administration.Pattern
@
using (Ajax.BeginForm("SetCombi", "Pattern", new { }, new AjaxOptions() { HttpMethod = "post", UpdateTargetId = "myContentPopupEditRole_div" }))
  
@(Html.Kendo().MultiSelect()
                    .MaxSelectedItems(2)
                    .Name("RegExID")
                    .DataTextField("RegExName")
                    .DataValueField("RegExID")
                    .Placeholder("Select Patterns...")
                    .AutoBind(false)    
                    .DataSource(source => {
                        source.Read(read =>
                        {
                            read.Action("GetPatternsForCombi", "Pattern");
                        })
                    .ServerFiltering(true);
          })
    )

What I want to do now is to pass the two selected RegExID's over to the controller. Controller action looks like this:
[AcceptVerbs(HttpVerbs.Post)]
        public ActionResult SetCombi([DataSourceRequest] DataSourceRequest request, List<Pattern> selectedPatterns)
        {
            SoftwareHelper helper = new SoftwareHelper();
 
            return PartialView("Combination");
        }

basically I thought of getting the IDs from the List<Pattern>, but the list is null.
any advise?

thx in advance
kind regards
jay taylor
Top achievements
Rank 1
 answered on 08 Feb 2018
4 answers
385 views

I have a grid  with a create tool bar.

.ToolBar(toolbar => toolbar.Create().Text("Add new Inspection"))

 

My grid is set to editable with a template.

.Editable(editable => editable.Mode(GridEditMode.PopUp).Window(w => w.Width(600)).TemplateName("Inspection"))

 

My data source is pretty standard.

.DataSource(dataSource => dataSource
        .Ajax()
            .Model(model => model.Id(Inspection => Inspection.DEPInspectionsID))
            .Read(read => read.Action("InspectionItems_Read", "Inspections"))
            .Create(create => create.Action("InspectionItem_Create", "Inspections"))
            .Update(update => update.Action("InspectionItem_Update", "Inspections"))
            .Destroy(destroy => destroy.Action("Inspections_Destroy", "Inspections"))
        )

 

When I click on the standard Update button on the pop up it calls the InspectionItem_Create action once for the new record, but then it also calls it again for each of the other records on the list as well...

Why would a single click of the update button trigger the function for not only for the item created using the model... but for all of the additional items in the list?

 

Stefan
Telerik team
 answered on 08 Feb 2018
3 answers
627 views

Hi,

I have 3 grids each one in another tab (another view).

for each one of them I have different Kendo extend validation  for example:

function ($, kendo) {
    $.extend(true, kendo.ui.validator, {
        rules: { // custom rules
            dateValidation: function (input, params) {
                debugger;
                if (input.is("[name='ActualStartDate']") && input.val() != "") {
                    var startDate = kendo.parseDate(input.val());
                    var endDate = kendo.parseDate($('#ActualEndDate').val());
                    if (startDate != null && endDate != null) {
                        input.attr("data-dateValidation-msg", "Start date should be before End date");
                        return startDate.getTime() <= endDate.getTime();
                    }
                } else if (input.is("[name='ActualEndDate']") && input.val() != "") {
                    var endDate = kendo.parseDate(input.val());
                    var startDate = kendo.parseDate($('#ActualStartDate').val());
                    if (startDate != null && endDate != null) {
                        input.attr("data-dateValidation-msg", "End date should be after Start date ");
                        return startDate.getTime() <= endDate.getTime();

                    }
                }
                if (input.is("[name='Description']") && input.val() != "") {
                    debugger
                    input.attr("data-dateValidation-msg", "A Description Cannot Be Longer Than 250 Characters");
                    return (input.val().length <= 250)

                }
                      
                return true;
            }
        },
        messages: { //custom rules messages
            dateValidation: function (input) {
                // return the message text
                return input.attr("data-val-dateValidation");
            }
        }
    });
})(jQuery, kendo);

 

 

because of cache , sometimes the the wrong validator is called and then the validation  went wrong.

How can I force that the right validator will be called? is there some unique name for each one?

 

 

Thank you

 

Stefan
Telerik team
 answered on 07 Feb 2018
1 answer
187 views

Currently a tornado chart is not available in the Kendo Charts library. Is there a way to create tornado charts with telerik html charts?

Example is attached below for your reference.

Stefan
Telerik team
 answered on 07 Feb 2018
1 answer
222 views
Under the React Data Query library, there are examples of doing the filtering/sorting in memory with local data: https://www.telerik.com/kendo-react-ui/components/dataquery/

And there's a page about Integration with UI for ASP.NET Core that shows the standard backend configuration for a DataqSourceRequest/ToDataSourceResult MVC configuration: https://www.telerik.com/kendo-react-ui/components/dataquery/mvc-integration/

But there's no information about how you configure a Kendo React component, for example a grid, to use the MVC Operations. Is there an example anywhere I have missed?
Vasil
Telerik team
 answered on 07 Feb 2018
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
ComboBox
Upload
MultiSelect
ListView
Window
TabStrip
Menu
Installer and VS Extensions
Spreadsheet
AutoComplete
TreeList
Gantt
PanelBar
NumericTextBox
Filter
ToolTip
Map
Diagram
Button
PivotGrid
Form
ListBox
Splitter
Application
FileManager
Sortable
Calendar
View
MaskedTextBox
PDFViewer
TextBox
Toolbar
Dialog
MultiColumnComboBox
DropDownTree
Checkbox
Slider
Switch
Notification
Accessibility
ListView (Mobile)
Pager
Security
ColorPicker
DateRangePicker
Wizard
Styling
Chat
DateInput
MediaPlayer
TileLayout
Drawer
SplitView
Template
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Licensing
Rating
ScrollView
ButtonGroup
CheckBoxGroup
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
DropDownButton
AIPrompt
PropertyGrid
ActionSheet (Mobile)
BulletGraph
Button (Mobile)
Collapsible
Loader
CircularGauge
SkeletonContainer
Popover
HeatMap
Avatar
ColorGradient
CircularProgressBar
SplitButton
StackLayout
TimeDurationPicker
Chip
ChipList
DockManager
ToggleButton
Sankey
OTPInput
ChartWizard
SpeechToTextButton
InlineAIPrompt
TimePicker
StockChart
RadialGauge
ContextMenu
ArcGauge
AICodingAssistant
SmartPasteButton
PromptBox
SegmentedControl
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?