How do I customize the Ext.grid.RowBodyFeature of ExtJS 4.0? - extjs4

I have implemented the getAdditionalData in ExtJS's grid.panel.
I have it showing the extra information but I want to style the extra row. Basically make the font smaller, etc.
Other than wrapping my data in span tags, is there another way to alter the style for those rows?
Thanks.

I found the answer. It was just easier to use a custom renderer.

Related

Margin on all content pages in Template10 XAML

I am using Template10 with the Hamburger starting project template. I'd like to have a margin between the hamburger area on the left and all content. I tried changing the shared Shell.xaml page (by adding a margin, etc.) but couldn't figure out the best way to sort it out. Conceptually, that makes sense, but it's the specific detail of how to make it work that I'm missing.
Is there an easy way to do it without changing each content page?
Regarding the questions in the comments: I want it in the closed case of a wide view; the question doesn't make any sense in any other case.  As far as what I tried, it doesn't really ultimately matter, since none of what I tried worked - I'm asking what the right way is to do it, which I never figured out.
Here's what the default looks like, without a margin:
Here's what it looks like with a margin added to the content area, which is also how the sample template contents handle this:
I don't want to have to mark up every content page with left margins to get the offset in the second picture.
  1: https://i.stack.imgur.com/jUIuO.png
Okay, now I have enough information. You have a few options here. The first is just bite the bullet like the rest of the developer community and format your pages like normal. But if you simply must, you can create an implicit Page style with a setter setting Margin="16,16,16,16" but, listen, and I am not kidding, you will ultimately regret it unless your app is super-simple. The biggest problem will be the spacing will be OUTSIDE the containing ScrollViewer.
Thanks for using Template 10.

change cell styling in KendoGrid

Just discovered the KendoGrid and was trying to change the style of an individual column(cell) after changing another cellvalue. For example I have a grid with a shipname and shipcity column. Suppose I have a business rule that says :
'Make shipcity cell value disabled when the shipname on the same row has the same value'
I found this sample which uses the blur event which I probably use, what would be a good way of implementing this rule?
Also nice to know your opinion in relation to asp.net mvc integration.
jsfiddle link:http://jsfiddle.net/dingen2010/begjT/1/
Updated the link:
You can try the updated fiddle example here
Basically conditional editor templates are not supported out of the box. You have two options.
Either use the edit event of the Grid find the editor inside e.containder and disable it the way it needs to be (if using Kendo widget use the enable(false) method, or add the readonly attribute if regular input).
The other options is to define custom editor like demonstrated in this JsBin example.

show tree inside the grid columns in extjs 4

I have to create a cube structure and for this I want to load a different tree panels under each of the columns of extjs grid panel.Is it possible to have the grid panel to show the tree panel under each of its columns.
You can refer TreeGrid component for this. I hope you are looking for this implementation. You can refer sencha kitchen sink link with example. Please refer below URL which may help you.
http://docs.sencha.com/extjs/4.2.0/extjs-build/examples/build/KitchenSink/ext-theme-neptune/#tree-grid
Thanks.
So you need to use this TreeGrid for your project.
TreeGrid
No. Grid panel does not support this.
What's more, it does not make much sense from a functionality point of view - trees have nodes that can be expanded and collapsed. The only way this can work with a grid is if there is only one tree column; only then you can collapse or expand specific rows. But how would this work if there are different trees in different columns.
I'd take on rixo's recommendation and use a column layout in which there are trees. Although I still can't really see how users would benefit from such a screen.

How to make a custom ListVIewItem on Secha2?

I am trying to make a custom listview with his items bigger, with an image in the background and a text over it.
I'm trying to use the Kiva example on the docs, but I cannot understand nothing about how is doing that.
Someone could help me understand how to make that? or ar approach to do?
If you want to use sencha-touch 2.0, I think Sencha-touch2.0 guide helps you.
Of course if you want to edit style, you must change via css or template of listview (via listview's tpl attribute).

Dojo Grid Template

In asp.net the DataGrid supports templates. You can provide your own template and have the grid fill the data in your template.
With Dojo Grid, it seems like I can't make my own template outside of the the rigid simplistic cell style grid that Dojo provides.
Does anyone know a way to use a custom template with Dojo Grid? Specifically, with Dojo you're forced to use a cell that corresponds to a data item. I'm looking to use a table as a template with any styling that I choose (rows,columns,rowspans,colspans, more than one data items in a single cell, etc).
Any clues please?
Thanks
Firstly, it sounds like everything you want is available by customizing the grid. You can do nesting of cells and even have things like Filtering Selects in rows. Unfortunately the docs on this are not awesome so it takes Googling and trial and error if you want very customized features.
Secondly, because of the OO nature of Dojo you can always use inheritance to create mixes of various widgets. Specifically the _templated class allows you to specify an HTML template for your widget, which themselves can included templated widgets.
If that sounds non-trivial, you're right, which is why I would suggest digging deeper into the Enhanced grid and probably open up the code before trying to write something yourself.
I can tell you that I struggled getting it working correctly, but I have hence been pleasantly surprised by features that I needed that I thought I would need to build myself but were built into the grid.