dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #20975
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 9815: (PT) Scrollbars fixed.
Merge authors:
Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 9815 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-02-15 13:38:45 +0100
message:
(PT) Scrollbars fixed.
modified:
dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js'
--- dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js 2013-02-15 11:12:39 +0000
+++ dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/core.js 2013-02-15 12:37:39 +0000
@@ -1077,7 +1077,7 @@
};
getHtml = function() {
- var s = '<table class="pivot">';
+ var s = '<table id="pivottable" class="pivot">';
for (var i = 0; i < htmlArray.length; i++) {
s += '<tr>' + htmlArray[i].join('') + '</tr>';
@@ -1128,7 +1128,7 @@
},
success: function(response) {
var html,
- tablePanel;
+ el;
if (!validateResponse(response)) {
pt.util.mask.hideMask();
@@ -1152,12 +1152,15 @@
xRowAxis = extendRowAxis(xSettings.row, xResponse);
html = getTableHtml(xColAxis, xRowAxis, xResponse);
-
- tablePanel = getTablePanel(html);
- if (!pt.el) {
- container.removeAll(true);
- container.add(tablePanel);
+ if (!pt.el && container) {
+ el = Ext.get('pivottable');
+
+ if (el) {
+ el.destroy();
+ }
+
+ container.update(html);
}
pt.util.mask.hideMask();