Telerik Forums
Kendo UI for jQuery Forum
2 answers
281 views

Hi, 

I have a dataSource with a number of fields. Is there any way to get the list of these fields, in the order specified when the datasource was created.

I know I can get the list by using dataSource.options.schema.model.fields, however the order in alphabetical and not in the order I used when I created the datasource.

Thanks!

Marc
Top achievements
Rank 1
 answered on 26 Jul 2017
1 answer
180 views

Is it possible to paste data from Excel and have the create method fire to append each inserted row?

The example from the documentation (http://docs.telerik.com/kendo-ui/controls/data-management/grid/how-to/excel/copy-from-excel-to-grid) simply replaces the existing grid's datasource whereas I would like to append each row that is pasted in so that it maintains the existing data and adds the newly pasted data.

My example Grid currently looks like:

@(Html.Kendo().Grid<InvoiceDetailVM>()
.Name("MyGrid")
.Columns(columns =>
{
columns.Bound(p => p.ID).Hidden();
columns.Bound(p => p.Description);
columns.Command(command => { command.Edit(); command.Destroy(); }).Width(250);
})

.Editable(editable => editable.Mode(GridEditMode.InLine))
.Sortable()

.DataSource(dataSource => dataSource // Configure the grid data source
.Ajax()                                                    
.PageSize(25)
.Events(events => events.Error("window.KendoGrid_Error"))
.Model(model =>
{
model.Id(i => i.ID); // Specify the property which is the unique identifier of the model.
model.Field(i => i.ID).Editable(false);
})
.Create(update => update.Action("Create", "Test"))
.Read(read => read.Action("Read", "Test"))
.Update(update => update.Action("Edit"))
.Destroy(update => update.Action("Delete", "Test"))
)                                
)

Any help would be appreciated.

Thanks!

Stefan
Telerik team
 answered on 26 Jul 2017
7 answers
303 views
Do Kendo UI make full support for OData V4 in the new release ?
I ask because that we earlier this year tried to use odata v4 together with Kendo UI, and it gave us some problems with the grid and problems with the datetime.

We need to use some of the features now, that odata v4 gives us. But I can not find any information if you are going to support it now ?
If the answer is no - then my next question will be - when can we expect it to be supported ?

Thanks in advance


Peter Beyer
CRM Byggefakta
Angel Petrov
Telerik team
 answered on 25 Jul 2017
2 answers
415 views
I cannot found the source files for Kendo UI Professional in my account. Please help me download the sources.
Krzysztof
Top achievements
Rank 1
 answered on 25 Jul 2017
13 answers
2.3K+ views
Hi,

I have a command column like as follows.

 { command: ["edit", "destroy", { text: "Reset", className: "Reset-button" }, { text: "Re-Register", className: "Re-Register-button"}], title: "&nbsp;", width: "420px"}],

As you can see I have associated 4 buttons to the column.
In the grid Data Bound event I want to show 2 buttons for some rows and 3 buttons for some rows and 4 buttons for some.


Please let me know how can i achieve this in Data Bound event, I have already spent nights for this please help .

Thanks
Anil. 
Preslav
Telerik team
 answered on 25 Jul 2017
5 answers
245 views

Hello-

I have an ObservableObject bound to a remote datasource, and the ObservableObject is bound to form fields with MVVM.

I currently have a 1-1 relationship between the field and the form input.  However, I want to change that so there is a single field for multiple controls.  For example...

 

Current

isClient database field (boolean) --> isClient checkbox

isPrimeClient database field (boolean) --> isPrimeClient checkbox

 

Desired

clientType database field (integer) --> isClient checkbox, isPrimeClient checkbox

 

I think I can use binding to the observable's "get" and "set" events...

 

observable.bind("set", function (e) {
if ((e.field === "isClient") || (e.field === "isPrimeClient")) {

   let isClient = observalbe.get("isClient");

   let isPrimeClient = observalbe.get("isPrimeClient");

   //// Some logic to determine appropriate value for clientType /////

   observable.set("clientType",somevalue);

}

});

 

observable.bind("get", function (e) {
if (e.field === "isClient") {

   //Look at clientType integer value and set e.value (for isClient) appropriately.

   let clientType = observable.get("clientType");

   e.value = //// some logic to determine appropriate value ////
}

else if(e.field === "isPrimeClient"){

   //Look at clientType integer value and set e.value (for isPrimeClient) appropriately.
   let clientType = observable.get("clientType");
   e.value = //// some logic to determine appropriate value ////

}
});

However, observable.get(...) always returns null.  Why is that?

Basically what I'm trying to do is take a single field from the back-end and render two controls for it.

Georgi
Telerik team
 answered on 24 Jul 2017
5 answers
127 views

Hello,

Please help me resolve the bug In timelineWeek view when shown only business hours.

If there is an event that star and end in off hours, timelineWeek did not show event, and breaks - see attach.

Here is live example http://dojo.telerik.com/iVAFa/2

 

Event with this dates breaks "timelineWeek business hours" view

"Start": new Date("2017/2/16 17:00"),
"End": new Date("2017/2/17 17:00"),

Misho
Telerik team
 answered on 24 Jul 2017
4 answers
156 views

Are there demos for the following widgets:

Prompt, Dialog, Notification, Popup, PanelBar

Dimitar
Telerik team
 answered on 24 Jul 2017
4 answers
2.6K+ views

I have a custom button on scheduler's toolbar and on "onclick" event I'm calling function "openEditor()". Inside this function I want to call a `text/x-kendo-template` script type. How can I do this?

My code right now:

Custom button:

schedulerToolbar.append(
"<ul class='k-reset'>
   <li class='k-state-default'>
     <a role='button' href='#' class='k-link newMeetingButton' onclick='openEditor()'>
       Nova reserva
     </a>
   </li>
</ul>"
)

Function openEditor():

function openEditor() {
   *code to call customEditorTemplateBh script*
 }

Template script:

<script id="customEditorTemplateBh" type="text/x-kendo-template">
   *template code*
</script>

 

Allan
Top achievements
Rank 1
 answered on 24 Jul 2017
4 answers
701 views

Hello I have 2 problems:

1) When click a file upload button my  opens. If I open a  from inside that one, the new window opens behind the first one, even though it is modal. How do you force a  to open in front? See below:

this.m_oDlg.kendoWindow(
{
actions: [],
title: "Edit Document",
draggable: true,
width : 840,
height : 580, 
resizable : false,
scrolling : false,
modal : true,
open: function(e){
// OK Button
var divText = "<div style='float:right;'>";
divText += "<button title='OK' id='editorOK' class='k-button basicModalDialogButton' style='paddingTop: 5px;'>OK</button>";
divText += "</div>";
$("#docEditor").append(divText);

//Cancel Button
var divText1 = "<div style='float:right;'>";
divText1 += "<button title='Cancel' id='editorCancel' class='k-button basicModalDialogButton' style='paddingTop: 5px;'>Cancel</button>";
divText1 += "</div>";
$("#docEditor").append(divText1);

var win = this;
$("#editorCancel").click(function(){
win.close();
});
$("#editorOK").click(function(){
ProStarAPI.DocEditorDlg.onOK;
win.close();
});
}
});
//this.m_oDlg.data("kendoWindow").center().open();
var win = $("#docEditor");
win.data("kendoWindow").open();

2) The buttons declared in the open event disappear if i close the window and re-open it. 

Any help would be greatly appreciated. Thanks

Nencho
Telerik team
 answered on 24 Jul 2017
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
Drag and Drop
Application
Map
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
DropDownTree
ListBox
PDFViewer
Sparkline
ActionSheet
TileLayout
PopOver (Mobile)
TreeMap
ButtonGroup
Styling
ColorPicker
Pager
Chat
MultiColumnComboBox
Dialog
DateRangePicker
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Accessibility
Effects
Licensing
PivotGridV2
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
LLM Kit
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?