details: /erp/devel/pi/rev/f5271f780cb9
changeset: 9454:f5271f780cb9
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 15:42:32 2010 +0100
summary: [OBCQL] Added QueryListWidgetView first implementation.
details: /erp/devel/pi/rev/a165d07b7666
changeset: 9455:a165d07b7666
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 15:42:39 2010 +0100
summary: [OBCQL] Override maximize function of QueryList widget to open
QueryListView.
details: /erp/devel/pi/rev/21a20b994424
changeset: 9456:21a20b994424
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 17:21:05 2010 +0100
summary: [OBQMO] Fixed typo on javadoc.
details: /erp/devel/pi/rev/e594fd8a26ee
changeset: 9457:e594fd8a26ee
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 17:24:05 2010 +0100
summary: [OBCQL] Show widget and grid with filter row in QueryListView.
details: /erp/devel/pi/rev/195d0f5eb1f4
changeset: 9458:195d0f5eb1f4
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 17:44:48 2010 +0100
summary: [OBCQL] Set widget title.
details: /erp/devel/pi/rev/06f9d01f6c08
changeset: 9459:06f9d01f6c08
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 17:45:07 2010 +0100
summary: [OBCQL] Properly set the widgetInstanceId.
details: /erp/devel/pi/rev/8c9962fd95ed
changeset: 9460:8c9962fd95ed
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Tue Dec 28 18:09:03 2010 +0100
summary: [OBCQL] Only open once each widget instance.Disable drag and drop.
details: /erp/devel/pi/rev/53e07338668b
changeset: 9461:53e07338668b
user: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
date: Wed Dec 29 18:17:21 2010 +0100
summary: [OBCQL] Temporarily remove rows filter on maximized view.
diffstat:
modules/org.openbravo.client.myob/web/org.openbravo.client.myob/js/ob-widget.js
| 2 +-
modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListComponentProvider.java
| 2 +
modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListWidgetProvider.java
| 3 +
modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-view.js
| 56 ++++++++++
modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-widget.js
| 24 +++-
5 files changed, 84 insertions(+), 3 deletions(-)
diffs (152 lines):
diff -r 87c027fb8bd2 -r 53e07338668b
modules/org.openbravo.client.myob/web/org.openbravo.client.myob/js/ob-widget.js
---
a/modules/org.openbravo.client.myob/web/org.openbravo.client.myob/js/ob-widget.js
Wed Dec 29 18:08:55 2010 +0100
+++
b/modules/org.openbravo.client.myob/web/org.openbravo.client.myob/js/ob-widget.js
Wed Dec 29 18:17:21 2010 +0100
@@ -414,7 +414,7 @@
// Returns true if the object passed as parameter is the same instance.
//
// Parameters:
- // {{widget}} an object to which you want to campare
+ // {{widget}} an object to which you want to compare
// {{isNew}} If this flag is true, the comparison is based on the ID of the
// client side object, otherwise the dbInstanceId is used
isSameWidget: function(widget, isNew){
diff -r 87c027fb8bd2 -r 53e07338668b
modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListComponentProvider.java
---
a/modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListComponentProvider.java
Wed Dec 29 18:08:55 2010 +0100
+++
b/modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListComponentProvider.java
Wed Dec 29 18:17:21 2010 +0100
@@ -47,6 +47,8 @@
final List<ComponentResource> globalResources = new
ArrayList<ComponentResource>();
globalResources.add(createStaticResource(
"web/org.openbravo.client.querylist/js/ob-querylist-widget.js",
false));
+ globalResources.add(createStaticResource(
+ "web/org.openbravo.client.querylist/js/ob-querylist-view.js", false));
return globalResources;
}
diff -r 87c027fb8bd2 -r 53e07338668b
modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListWidgetProvider.java
---
a/modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListWidgetProvider.java
Wed Dec 29 18:08:55 2010 +0100
+++
b/modules/org.openbravo.client.querylist/src/org/openbravo/client/querylist/QueryListWidgetProvider.java
Wed Dec 29 18:17:21 2010 +0100
@@ -84,6 +84,9 @@
+ ", fields:"
+ QueryListUtils
.getWidgetClassFields(getWidgetClass(),
QueryListUtils.IncludeIn.WidgetView)
+ + ", maximizedFields:"
+ + QueryListUtils.getWidgetClassFields(getWidgetClass(),
+ QueryListUtils.IncludeIn.MaximizedView)
+ gridProperties + "});";
return result;
}
diff -r 87c027fb8bd2 -r 53e07338668b
modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-view.js
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++
b/modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-view.js
Wed Dec 29 18:17:21 2010 +0100
@@ -0,0 +1,56 @@
+/*
+ *************************************************************************
+ * The contents of this file are subject to the Openbravo Public License
+ * Version 1.1 (the "License"), being the Mozilla Public License
+ * Version 1.1 with a permitted attribution clause; you may not use this
+ * file except in compliance with the License. You may obtain a copy of
+ * the License at http://www.openbravo.com/legal/license.html
+ * Software distributed under the License is distributed on an "AS IS"
+ * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ * The Original Code is Openbravo ERP.
+ * The Initial Developer of the Original Code is Openbravo SLU
+ * All portions are Copyright (C) 2010 Openbravo SLU
+ * All Rights Reserved.
+ * Contributor(s): ______________________________________.
+ ************************************************************************
+ */
+// = OBQueryListView =
+//
+// Implements the Query / List widget maximized view.
+//
+isc.defineClass('OBQueryListView', isc.PortalLayout);
+
+isc.OBQueryListView.addProperties({
+ widgetInstanceId: null,
+ fields: null,
+ gridDataSource: null,
+
+ //Set PortalLayout common parameters
+ numColumns: 1,
+ showColumnMenus: false,
+ canDropComponents: false,
+
+ initWidget: function(args){
+ this.Super('initWidget', arguments);
+
+ this.widgetInstanceId = args.widgetInstanceId;
+ this.fields = args.fields;
+ this.gridDataSource = args.gridDataSource;
+
+ var widgetInstance = isc.OBQueryListWidget.create(isc.addProperties({
+ viewMode: 'maximized',
+ fields: this.fields,
+ widgetInstanceId: this.widgetInstanceId,
+ dbInstanceId: this.widgetInstanceId,
+ gridDataSource: this.gridDataSource,
+ title: args.tabTitle
+ }));
+ this.addPortlet(widgetInstance);
+ },
+
+ isSameTab: function(viewName, params){
+ return this.widgetInstanceId === params.widgetInstanceId;
+ }
+});
\ No newline at end of file
diff -r 87c027fb8bd2 -r 53e07338668b
modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-widget.js
---
a/modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-widget.js
Wed Dec 29 18:08:55 2010 +0100
+++
b/modules/org.openbravo.client.querylist/web/org.openbravo.client.querylist/js/ob-querylist-widget.js
Wed Dec 29 18:17:21 2010 +0100
@@ -26,14 +26,18 @@
widgetInstanceId: null,
rowsNumber: null,
fields: null,
+ maximizedFields: null,
+ gridDataSource: null,
grid: null,
gridProperties: {},
- actionHandler: 'org.openbravo.client.querylist.QueryListActionHandler',
viewMode: 'widget',
initWidget: function(){
this.Super('initWidget', arguments);
- // Calculate height
+ // Calculate height only on widget view mode
+ if (this.viewMode !== 'widget') {
+ return;
+ }
var currentHeight = this.getHeight(),
//currentBodyHeight = this.body.getHeight(),
headerHeight = this.headerDefaults.height,
@@ -56,6 +60,13 @@
styleName: ''
}), url, params = {};
+// FIXME: not shown filters row until optional filter parameters are possible
+// if (this.viewMode === 'maximized') {
+// isc.addProperties(this.gridProperties, {
+// showFilterEditor: true
+// });
+// }
+
this.grid = isc.OBQueryListGrid.create(isc.addProperties({
dataSource: this.gridDataSource,
widget: this,
@@ -86,6 +97,15 @@
};
grid.exportData(requestProperties, additionalProperties);
+ },
+
+ maximize: function() {
+ OB.Layout.ViewManager.openView('OBQueryListView', {
+ tabTitle: this.title,
+ widgetInstanceId: this.dbInstanceId,
+ fields: this.maximizedFields,
+ gridDataSource: this.gridDataSource
+ });
}
});
------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and,
should the need arise, upgrade to a full multi-node Oracle RAC database
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits