Telerik Forums
Kendo UI for jQuery Forum
1 answer
118 views

Hello, 

 

There are any methods in your API to get the status of "Business hours/Full day" button?

Thank you

Magdalena
Telerik team
 answered on 20 Nov 2015
3 answers
304 views
I have a custom tool bar command that inserts HTML Snippets....

How do I programmatically load these elements (I have 100)...   It is the insertHTML command that I want to load from my database Table.

$("#editor").kendoEditor({
        tools: [
            "insertHtml",
            "bold",
            "italic",
            "underline"
        ],
        insertHtml: [
            { text: "Client First Name(s)", value: " [FIRSTNAME] " },
            { text: "Client FullName", value: " [FULLNAME] " },
            { text: "Client Since", value: " [CLIENTSINCE] " }
        ],
        messages: {
            insertHtml: "Insert Tags"
        }
    });
Dimo
Telerik team
 answered on 20 Nov 2015
1 answer
388 views

Is there any way to get the Kendo editor to use "U" tags instead of <style='text-decoration:underline">..." for the underline function.   I'm fine with retaining styles for the other functions.

 

Thanks!

Alex Gyoshev
Telerik team
 answered on 20 Nov 2015
7 answers
3.8K+ views
When I set min value for a KendoNumericTextBox, it automatically changes to the minimum value, instead of showing error saying that need to have minimum value. How do I change the behavior.

var numericBox = $("#numeric_" + attrObj.AttributeId).data("kendoNumericTextBox");
numericBox.min(5);
numericBox.validationMessage = "Please enter value 5 and above";

So when I enter 3 for example in the above numberBox, it is supposed to give an error saying "Please enter value 5 and above". Instead the value of the box changes to 5 and no error is shown. This behavior is not acceptable. Is there anyway I can change this?

Thanks,
Suresh
Elliot
Top achievements
Rank 1
 answered on 19 Nov 2015
1 answer
256 views

I can't figure out why my Kendo Autocomplete widget is not sending the authorization headers in the request to the server:

var dataSource = new kendo.data.DataSource({
    type: 'odata',
    serverFiltering: true,
    transport: {
        read: {
            url: myApiUrl,
            type: 'GET',
            beforeSend: function (xhr) {
                xhr.setRequestHeader('Authorization', myAuthorizationValue);
            }
        }
    }
});
 
$('#myAutocompleteField').kendoAutoComplete({
    dataTextField: 'fieldName',
    filter: 'contains',
    minLength: 3,
    dataSource: dataSource
});

When I check the server response in dev tools, I am getting a 401 Unauthorized error from the server. Looking at the Request Headers, I don't see the Authorization property at all.

What do I need to do to get the Authorization header to be included with the request?

 If I just do a typical $.ajax request with the same object as transport.read in the Kendo DataSource parameter, it sends the headers and I get a successful response.

$.ajax({
    url: myApiUrl,
    type: 'GET',
    beforeSend: function (xhr) {
        xhr.setRequestHeader('Authorization', myAuthorizationValue);
    },
    success: function(res) {
        console.log('success!');
        console.log(res);
    }
});

Steven
Top achievements
Rank 1
 answered on 19 Nov 2015
1 answer
125 views

I have a View in my SQL database defined in BackEndServices for my project.

When the following view runs, I get an "Uncaught TypeError: undefined is not a function" with my datasource.

Any thoughts?

<div data-role="view" data-title="TheTest" data-layout="main" data-show="onShow">
 
    <!--Page Title-->
    <div data-bind="html: title" class="pagetitle">INSPECTIONS</div>
 
    <!--ListView Headings-->
    <div>
        <table>
            <tr>
                <td style="width: 50%">
                    NAME
                </td>
                <td style="width: 50%">
                    DATE UPLOADED
                </td>
            </tr>
        </table>
    </div>
 
    <!--List of Inspections for the company-->
    <div><ul id="attachmentList"></ul></div>
 
</div>
 
<script>
 
    // attachments DataSource
    var attachments = new kendo.data.dataSource({
        type: 'everlive',
        transport: {
            typeName: 'dbo_View_InspectionAttachments'
        },
        schema: {
            model: {
                fields: {
                    'Id': { type: 'number' },
                    'fileName': { type: 'string' },
                    'dateuploaded': { type: 'date' }
                }
            }
        },
        serverFiltering: true,
        filter: {
            logic: "and",
            filters: [
                { field: 'inspectionid', operator: 'eq', value: 8385 },
                { field: 'confidential', operator: 'eq', value: false }
            ]
        },
        serverSorting: true,
        sort: { field: 'fileName', dir: 'asc' }
    });
 
</script>
 
<script>
    function onShow(e) {
 
        //Find the attachment listview
        var attachList = e.view.content.find("#attachmentList");
 
        // Passing template, datasource, and style to Attachment listview
        attachList.kendoListView({
            template: "<div><table><tr><td style='width: 50%'><label>#: fileName #</label></td>" +
                "<td style='width: 50%'><label>#: dateuploaded #</label></td></tr></table></div>",
            style: "inset",
            dataSource: attachments
        });
    }
</script>

Cecil
Top achievements
Rank 1
 answered on 19 Nov 2015
3 answers
152 views

Hi, I've recently started working with Kendo UI. I have been reading this forum to find answers usually very good. However I am struggling to replicate inline json data in to remote one. Please see below. This works fine creating me the Title for the radio group just as expected however the minute I try using the remote JSON.

http://jsbin.com/sanixi/edit?html,js,output

This is the code should be replacing " var tileDataSource " array with it's remote counterpart below:

 var tileBaseUrl = "//localhost:8000/data/repTiles.json";
    var tileDataSource = new kendo.data.DataSource({
        transport: {
              read: {
                  url: tileBaseUrl,
                  contentType: "application/json; charset=utf-8",
                  dataType: "json"
              },
              update: {
                  url: tileBaseUrl,
                  dataType: "json"
              },
               create: {
                  url: tileBaseUrl,
                  dataType: "json"
              },
              destroy: {
                  url: tileBaseUrl,
                  dataType: "json"
              },
              parameterMap: function(obj, operation) {
                  if (operation !== "read" && obj.models) {
                      return {
                          models: kendo.stringify(obj.models)
                      }
                  }
                  return obj;
              }
          }
   });

What am I missing here? what am I doing wrong? trying to achieve an all remote JSON code here. I have used this code for to remote load JSON for kendoComboBox and kendoDropDownList etc. All worked fine.

Please have a look any ideas how I can achieve this.

Thanks.

 

James
Top achievements
Rank 1
 answered on 19 Nov 2015
1 answer
293 views

How can one set xhrFields {withcredentials: true} when using an OData-V4 data source in an MVC Server Wrapper?

I've gotten this far in the data source using the Fluent API:

 

.DataSource(dataSource => dataSource
                    .Custom()
                    .Type("odata-v4")
                    .Transport(transport =>
                    {
                        transport.Read(read => read.Url("https://xxx/OData/Employee/FindEmployees"));
                    })
                    .ServerFiltering(true)
                )

 

 But I need to be able to include credentials like am doing here:

$("#EmpID").kendoComboBox({
                    placeholder: "Select employee",
                    dataTextField: "FullName",
                    dataValueField: "EmpID",
                    filter: "startswith",
                    autoBind: false,
                    minLength: 3,
                    dataSource: {
                        type: "odata-v4",
                        serverFiltering: true,
                        transport: {
                            read: {
                                url: "https://xxx.com/OData/Employee/FindEmployees",
                                xhrFields: {
                                    withCredentials: true}
                            }
                        }
                    }
                });

 

 

 

Rosen
Telerik team
 answered on 19 Nov 2015
1 answer
512 views

Hello,

I have a grid with about 15 columns.  When my page displays, I have a horizontal scroll bar at the bottom.  I drag the scroll bar all the way to the right so I can see my right most columns.  So far no issues. 

If I then pick any visible column and resize it by dragging its right border to the left a bit, instead of the columns to the right moving closer, the columns to the right stay stationary and the columns to the left of the one I am resizing scroll in from the left side.

I am looking to simply resize a column by moving its right border closer to its left border and having the columns to the right move in closer.  I don't want the fields to the left to start moving in from the left side.

I have looked through the documentation and have not seen a way to do this.  Is the behavior described here the way the grid was designed to work, or is there a way I can achieve my desired functionality.  The issue seems to be related to the horizontal scrollbar and how it comes into play with column resizing.

Please provide a link to a code snippet if possible, or an explanation if this is not possible.

Thank you very much!

Dave

Dimo
Telerik team
 answered on 19 Nov 2015
2 answers
245 views

Greetings,

I'm using the kendo grid as an ImageViewer to show thousand of images; these images are being shown one by one (paging size = 1) with only Next and Previous buttons as paging navigation; every time i click next, the image is downloaded from azure; don't know if it's relevant but I'm using the ClientRowTemplate property to construct a normal <img src='#: data.filename :#' /> which is why the image is downloaded by the browser when the row has been loaded. 

I would appreciate any ideas to download in chunks of 20 or even 100 images in the background so they appear instantaneously on every new page?

Thanks a lot,

hope it makes sense,

Geo

 

Quickstoker
Top achievements
Rank 2
 answered on 19 Nov 2015
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?