Telerik Forums
Kendo UI for jQuery Forum
3 answers
240 views

How do you data bind items. 
We can bind value like so:

data-bind="value: value"

but cannot bind to an array of items in the same manner. 

data-items="items" also doesn't seem to work.

Ivan Danchev
Telerik team
 answered on 21 Dec 2020
1 answer
554 views

I am developing video streaming using Kendo UI Media Player in HTML 5.

 

For back-end I am using Java, Spring framework, JPA, and Hibernate. Firstly, the service in the backend will send a list (array) of the web service URL to get each video. After that, the screen (web page) will show the video playlist, the video will be played based on the video clicked by user.
When user click the video in the playlist, the screen will assign a Service URL to get video as a source for Kendo UI Media Player. The content type for Service Output is application/octet-stream. The code below is JavaScript code to switch between videos in the playlist.

 

Example for Service URL: http://10.25.88.36:800/ns/listen/D03042020LNB0000901_EKYC01_20200304100308_cust.webm

 

function toggleActiveVideo(dataItem) {
    var mediaPlayer = $("#mediaplayer").data("kendoMediaPlayer");
 
    // Data item is Web Service URL to get the video data as application/octet-stream
    // Data item have structure like { title: "[File Name]" , poster: "/images/video.jpg" , source: "[Web Service to get Video Data]"  }
    mediaPlayer.media(dataItem);
 
    $("li.k-state-selected").removeClass("k-state-selected");
    $("li.k-state-default").eq(currentIndex).addClass("k-state-selected");
}

For the Response Headers of the service look like the image below.

 

Response Headers Image

For the Java code in the service look like this:

 

@RequestMapping(value="/ns/listen/{fileNm:.+}")
public StreamingResponseBody listenVoice( @PathVariable(value="fileNm") String fileNm, HttpServletRequest req, HttpServletResponse response   ) throws Exception {
    logger.debug("#### /ns/listenVoice [{}] start ####", fileNm);
 
    if (StringUtil.isBlank( fileNm ))
    {
        throw new InoanException("999999999", "Not Input File Name");
    }
 
    File rtnFile = null;
 
    if(StringUtil.endsWith(fileNm, ".mp4") || StringUtil.endsWith(fileNm, ".webm"))
    {
        rtnFile  = cnccUtil.getVideoFile(fileNm);
 
        if( rtnFile == null )
        {
            rtnFile = cnccUtil.getEkycVideoFile(fileNm);
        }
 
        //response.setContentType( "video/mp4" );
        response.setContentType( MediaType.APPLICATION_OCTET_STREAM_VALUE );
        response.setHeader("Content-Disposition", "attachment; filename="+fileNm);
    }
    else if( StringUtil.endsWith(fileNm, ".mp3") || StringUtil.endsWith(fileNm, ".wav") )
    {
        rtnFile  = cnccUtil.getVoiceFile(fileNm);
        //response.setContentType( "audio/mpeg3" );
    }
 
    //InputStream in = FileUtils.openInputStream(rtnFile);
    final InputStream is = new FileInputStream(rtnFile);
 
    return os -> {
        readAndWrite(is, os);
    };
}
 
private void readAndWrite(final InputStream is, OutputStream os) throws IOException {
    byte[] data = new byte[2048];
    int read = 0;
 
    while ((read = is.read(data)) > 0) {
        os.write(data, 0, read);
    }
 
    os.flush();
}

The video streaming can be played, but can't move video time forward or backward.

Should I change Content Disposition or Content Type in the response headers? Or there's another way to do video streaming using Kendo UI?

Note: the video mime is video/webm; codecs="vp8, opus"

Viktor Tachev
Telerik team
 answered on 18 Dec 2020
1 answer
277 views

Hi,

I'm using TreeList kendo component and there's a case when I need to force refresh of the whole tree node (sometimes it might have quite deep nesting level) and that's causing UI freeze for up to a few seconds.

I'm using the KendoTreeList API like:

```

treeList.kendoTreeList({

            expand: function (e) {

                    this.dataItem(e.model).loaded(false);
              }

})

```

I tried profiling this code and found out that lots of rendering calls (like removeChildData(), removeItems()) is happening during the freeze. As I understand, kendo is cleaning up the subnodes and it takes a while. Is there a way to force refresh of a single node more efficiently? Any help would be appreciated.

Tsvetomir
Telerik team
 answered on 17 Dec 2020
1 answer
143 views

In development we have a user definable dependency map; the shapes position is recorded using the value gained from the shape._bounds.x and y co-ordinates and these are stored in the database. The scope of the dependency map can have anywhere from a few shapes to thousands of shapes for example.

The problem i have come across is that when I am creating one of these maps; I us a combination of zoom and pan to navigate the positions of the shapes. I then may close the browser or go somehwere else on our website BUT when I come back to the web page with the diagram on and the dependency map is loaded I have a completely blank view port. As the diagram is actually on the canvas but out of view of the view port; so, I need to be able to move the view port to show the dependency map.

I have tried a couple of methods to do this, but it has not worked; I need help with this tricky situation. But what I do not want to do is re-position all the shapes as if there are thousands of these then I would need to change each shape x,y coordinates in the database; heavy workload. I would like the view port to move also, because I could then give functionality to the user to remember the last view and restore the view on each visit.

 

Alex Hajigeorgieva
Telerik team
 answered on 17 Dec 2020
1 answer
213 views

Hi,

We have more than 5000 records in calendar.

Currently if we bind all data together then scheduler takes almost 2 mins.

so avoiding load and bind time, we need to bind data on every view change. 

For e.g. By default month will be current month and when user navigate to next or previous month, we need to bind data and that way it will reduce the bind and load time.

We have used our custom api for read operation but found that when we change the view, it is not working as expected.

When we navigate and rebind the data, then it is not calling our read api with startdate and enddate.

How we can proceed further?

 

Misho
Telerik team
 answered on 17 Dec 2020
9 answers
100 views
 

Hi,

    i've encountered some issue while displaying in stockchart. If the last date is exactly the same time as the last element's date, it will not display.

    Here's my stockchart config:

$("#chart").kendoStockChart({
          dataSource:chart_data,
          dateField: "date",
          chartArea: {
            width: 1000,
          },
          seriesDefaults:{
            type: "column",
          },
          series: [{
            field: aField,
            name: aName
          },{
            field: bField,
            name: bName
          }],
          tooltip: {
            visible: true,
            shared: true,
            sharedTemplate:
              "#= $.format.date(new Date(category), 'yyyy-MM-dd') # </br>" +
              "# for (var i = 0; i < points.length; i++) { #" +
                  "#= points[i].series.name #: #= points[i].value.toLocaleString('en-US') # </br>" +
              "# } #" +
              "GAP: #= points[1].value-points[0].value # </br>"+
              compareName+": #= (points[0].value/points[1].value*100).toFixed(2) #%"
          },
          valueAxis: {
            labels:{
              template: "#= value #"
            },
 
          },
          categoryAxis: {
            justified: true,
            baseUnit: "days",
            baseUnitStep: "auto",
            labels:{
              step: 0,
            },
            autoBaseUnitSteps: {
                days: [0]
            }
          },
          legend:{
            visible: true,
            position: "top",
            labels: {
              font: "20px sans-serif",
              color: "grey"
            }
          },
          navigator: {
            series: [{
              type: "line",
              field: aField
            },{
              type: "line",
              field: bField
            }],
            categoryAxis: {
              labels: {
                  rotation: "auto"
              },
              justified: true
            }
          }
        });

Any advice would be helpful!

Bob

 
Georgi Denchev
Telerik team
 answered on 16 Dec 2020
3 answers
973 views

Hello,

When making a column selectable the table header fails WCAG AA 2.1 compliance as the select all header is flagged as a empty table header

Alex Hajigeorgieva
Telerik team
 answered on 16 Dec 2020
3 answers
193 views

I'm not sure where else to post this. dojo.telerik.com won't accept any of the passwords I've used with Telerik. I tried resetting my password, but the reset-password page does not work. It appears to work in that I get taken to a page that says the password change was successful, but when I try to use the password to login, I am told Invalid Credentials and to please retry with valid credentials. I have followed the instructions here,

https://www.telerik.com/forums/locked-out-of-my-dojo-account-can't-change-password

opening up the password reset link in a new incognito window, changing the password there, getting the success page. Opening up a new incognito window to try to login and it fails. I have done this multiple times. I can forward someone the password request and the confirmation emails if you like.

Any advice?

Misho
Telerik team
 answered on 16 Dec 2020
4 answers
1.2K+ views

Hello!

I have a Kendo Grid on my page and I have a few columns that are 'filterable' and 'multiselect' checkbox lists.

 

The top select option is "Select All" which selects all options, however this "Select All" option goes away once you search for anything.

 

What I need:

I need the "Select All" checkbox to remain after searching

I need the "Select All" checkbox to only select items that are shown. IE: I search for "W" and click 'select all' and only those items with "W" get selected.

 

 

Thanks!

Alex Hajigeorgieva
Telerik team
 answered on 16 Dec 2020
1 answer
114 views

Are there any plans to support branching in the stepper in the future?  We're using the control to track progress on a set of long-running tasks, but we've run into a scenario where two tasks can be run in parallel with each other.  

Thanks,
Will

Veselin Tsvetanov
Telerik team
 answered on 15 Dec 2020
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
Date/Time Pickers
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)
SPA
Filter
Drawing API
Drawer (Mobile)
Globalization
Gauges
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
Chat
DateRangePicker
Dialog
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
OrgChart
TextBox
Effects
Accessibility
ScrollView
PivotGridV2
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
Popover
DockManager
FloatingActionButton
TaskBoard
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
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
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?