PDA

View Full Version : Create grid.GroupingView in UI View



R.J
12 Jan 2010, 1:40 AM
I have a requirement where we need to create a Grouping View. Can any one help me to create the groupingview using extnd. My code of Head content is as under :


thisWebDbName := @WebDbName;
extndDbWebPath := "/extnd_b3.nsf/";
extUrl := extndDbWebPath + "ext/3x/";
extndUrl := extndDbWebPath + "extnd/3x/";
sViewName := "vwDiscussionBoard";
sOutlineName := "mainoutline";
bShowSearch := "true";
mode := @If(@UrlQueryString("debug") = "true"; "-debug"; "");
unid := @If(@IsNewDoc;"";@Text(@DocumentUniqueID));
editMode := @If(@IsDocBeingEdited;"true";"false");

"<!-- Ext JS library -->" + @NewLine +
"<script type='text/javascript' src='" + extUrl + "adapter/ext/ext-base.js'></script>" + @NewLine +
"<script type='text/javascript' src='" + extUrl + "ext-all" + mode + ".js'></script>" + @NewLine +
"<!-- Ext.nd JS library -->" + @NewLine +
"<script type='text/javascript' src='" + extndUrl + "extnd-all" + mode + ".js'></script>" + @NewLine +
"<script type='text/javascript' src='" + extndUrl + "Session.js?OpenAgent&db=" + thisWebDbName + "'></script>" + @NewLine +
"<script type='text/javascript' src='" + extndUrl + "UIDocument.js?OpenAgent&db=" + thisWebDbName + "&unid=" + unid + "&editmode=" + editMode + "'></script>" + @NewLine +
"<script type='text/javascript'>" + @NewLine +
" var ExtndApp = function() {
return {
init : function(){
this.ui = new Ext.nd.DominoUI({
uiOutline : {outlineName: '" + sOutlineName + "'},
uiView : {viewName: '" + sViewName + "', viewTitle: '" + sViewTitle + "', showSearch: " + bShowSearch + "}
});
//remove the outline panel and refresh the viewport
this.ui.outlinePanel.hide();
this.ui.viewport.doLayout();
} // init
} // return
}();" + @NewLine +
" Ext.onReady(ExtndApp.init, ExtndApp, true); " + @NewLine +
"</script>" + @NewLine +
"<link rel='stylesheet' type='text/css' href='" + extUrl + "resources/css/ext-all.css' />" + @NewLine +
"<link rel='stylesheet' type='text/css' href='" + extUrl + "resources/css/xtheme-gray.css' />" + @NewLine +
"<link rel='stylesheet' type='text/css' href='" + extndUrl + "resources/css/domino.css' />"


Please help..!!

Thanks...

RWaters
15 Jan 2010, 1:44 PM
the UIView class Ext.nd uses is really not set up for using the Ext grouping view. Ext's Grouping view requires a specific GroupingStore and GroupingView and since Ext.nd has custom versions of both of those it's not an easy replacement.

Now if you just wanted a straight Ext grouping view you could grab the code from the Grouping example and write an agent to get you a nice json data format for the display you want, but the auto xml mapping from Ext.nd obviously wont be there.

We do have a categorized view that is much like the grouping view and will continue to be polished and made more configurable in future releases.

aokokoka
9 Dec 2010, 2:43 AM
I want to own the definition of a panel to "uiOutline" in how to add?
I am very confused .Help me!

This My Code before:

Ext.onReady(function(){
new Ext.Viewport({
layout: 'border',
items: [
{
region:'center',
id:'west-panel',
title:'West',
split:true,
width: 200,
minSize: 175,
maxSize: 400,
collapsible: true,
margins:'35 0 5 5',
cmargins:'35 5 5 5'
},
{
xtype: 'treepanel',
id: 'tree-panel',
region: 'west',
split:true,
width: 200,
minSize: 175,
maxSize: 400,
collapsible: true,
margins:'35 0 5 5',
cmargins:'35 5 5 5',
autoScroll: true,
rootVisible: false,
root: new Ext.tree.AsyncTreeNode(),
// Our custom TreeLoader:
loader: new Ext.app.BookLoader({
dataUrl:"createTree.xml",
requestMethod: 'GET'
}),
listeners: {
'render': function(tp){tp.getSelectionModel().on('selectionchange', function(tree, node){})}
}
}]
});
});