Telerik Forums
Kendo UI for jQuery Forum
6 answers
121 views
Hello everyone, I'm trying to populate a grid with localized data.
My codefirst entity framework database look like this:

public class Prod
{
    public int ProdId { get; set; }
    public int Quantity { get; set; }
 
    //Other Properties & Navigation Properties
 
    public ICollection<ProdLang> ProdLangs { get; set; }
}
 
public class ProdLang
{
    public int ProdLangId { get; set; }
    public int LangId { get; set; }
    public string Name { get; set; }
    public string Description { get; set; }
 
    //Other Properties
 
    public int ProdId { get; set; }
    public Prod Prod { get; set; }
}

I want to show in my kendo grid Collection of Product with ProdLang properties for current user language (eg. Name, Description)
For doing that i buil a flattened class, like this:

public class ProdView
{
    public int ProdId { get; set; }
    public int Quantity { get; set; }
 
    public string Name
    {
        get
        {
            return ProdLangs.Single(pl => pl.LangId == langId).Name;
        }
    }
 
    public string Description
    {
        get
        {
            return ProdLangs.Single(pl => pl.LangId == langId).Description;
        }
    }
    //Other Properties & Navigation Properties
 
    public ICollection<ProdLang> ProdLangs { get; set; }
}

My problem is that I want to let user to order & paging data, but I don't want to load entire collection everytime I have to display grid and pass it to "ToDataSourceResult" method.

There is a way for loading from the DB only the desired data?

Thanks
Atanas Korchev
Telerik team
 answered on 14 Mar 2014
1 answer
102 views
I am trying to create a dynamic drawer widget on initialization of a view, since there is not programmatic way to create a drawer widget I  build the drawer HTML like so:
<div data-role="drawer" id="my-drawer" style="width: 270px">
    <ul id="nav" data-role="listview" data-type="group">
       <li>Navigation
          <ul>
             <li data-icon=home><a href=views/index.html data-transition="none">Menu A</a></li>                </ul>
          <ul>
             <li data-icon=search><a href=views/weather.html data-transition="none">Menu B</a></li>             </ul>
          <ul>
             <li data-icon=compose><a href=views/location.html data-transition="none">Menu C</a></li>           </ul>
      </li>
      <li>Account
         <ul>
            <li data-icon="settings">Settings</li>
            <li data-icon="off">Log Out</li>
        </ul>
      </li>
   </ul>
</div>


I then append this generated HTML to the DOM but it is not "kendorized" so it doesn't act as the drawer widget would. When I click to open the drawer I get the following error message: Uncaught TypeError: Cannot call method 'openFor' of undefined

I need help getting this to work properly. Thanks

Kiril Nikolov
Telerik team
 answered on 14 Mar 2014
1 answer
159 views
Is there a way to get (not set) the valueAxis' min/max/majorunit values? I only seem to be able to access those properties if I actually set them first.

I want to be able to know what the values have been automatically set to by Kendo and determine if I need to fine tune the scaling.

Thanks.
Hristo Germanov
Telerik team
 answered on 14 Mar 2014
1 answer
106 views
Hi,

I've added native scrolling to all mi views on my app and the performance is awesome, just like a native app.

But if we combine a ListView with "pull to refresh" or "endless-scrolling" and native-scrolling does not work. Any way to fix it? Why in Chrome for Windows Desktop this feature is supported and work? what about mobile browsers?

please
Kiril Nikolov
Telerik team
 answered on 14 Mar 2014
1 answer
142 views
Hi,

I have succesfully import the custom admob plugin to show ads in my app. The only problem I have is that the ads are below the tabstrip, I actually prefer it being above the tabstrip. Second The whole view is being pushed up. I have attached a screenshot. Can I do anything about these problems?

Kiril Nikolov
Telerik team
 answered on 14 Mar 2014
1 answer
69 views
i'am using sql server 2012 and want to use pageable option to paginate and not scroll.
Kiril Nikolov
Telerik team
 answered on 14 Mar 2014
2 answers
136 views
I have a chart that has two category axes defined so I can display the category labels at the bottom of the chart when there are negative values. I am also setting min and max values for the second axis to avoid labels that show up as 0.25, 0.5, etc. when the series has small values like 1.

I would like to know if there is a simple way to line up the category axes of different series. If you see the attached image, you can see how the first series has a negative value and the second series starts below it.

Thanks.
Hristo Germanov
Telerik team
 answered on 14 Mar 2014
4 answers
1.0K+ views
Hi,
I'm trying to filter data inside dataBound event function, but it creates recursive calls to itself.
Could you tell me if this is a bug or am I doing something wrong?

Example: http://trykendoui.telerik.com/onAj
This is Event example from grid demos with modification inside "function onDataBound(arg)".

function onDataBound(arg) {
                    kendoConsole.log("Grid data bound");
                      var l_Data = this.dataSource;
                    l_Data.filter( {
                        field: "UnitsInStock",
                        operator: "eq",
                        value: 39
                        } );
                }
Luke
Top achievements
Rank 1
 answered on 14 Mar 2014
8 answers
250 views
Hi, I have a problem with navigating between two remote views, where one view has the data-reload=true attribute.

I have a remote view which show details of a message, you can then post this message on twitter. If the user didn't authorize twitter before, they get a message with that they have to do that. The user then has two options: authorize twitter or go back to the message. If back to the message is selected, the tabstrip in the data-reload view dissappears and reappears immediatly. 

This problem wont happen when data-reload is set to false. But if i set it to false the data in the remote view wont update. when another message is selected.

How can I make sure the tabstrip doesn't flicker when navigating back to the remote view with the data-reload true attribute.


-EDIT:
When i go to the remote view with data-reload=true for the first time no flicker appears only for second time and the times after that.
Alexander Valchev
Telerik team
 answered on 14 Mar 2014
1 answer
173 views
Hi.

How can I distinguish operations in change event? I mean, how to recognize whether current operation is select (add new item) or delete (cross clicked)?
I know about select event, but I'm interested in change event only? Should I use external counter?

Thanks in advance.
Georgi Krustev
Telerik team
 answered on 14 Mar 2014
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
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
LLM Kit
+? 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?