dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #19989
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 8962: Don't run filtering functionality in tabular report.
------------------------------------------------------------
revno: 8962
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2012-11-09 19:46:35 +0700
message:
Don't run filtering functionality in tabular report.
modified:
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.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-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js 2012-11-08 13:09:31 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js 2012-11-09 12:46:35 +0000
@@ -662,10 +662,11 @@
currentPage: 1,
total: 1,
totalRecords: 0,
+ isFilter:false,
orderByOrgunitAsc: true,
orderByExecutionDateByAsc: true,
orgunitIds: [],
- generateReport: function( type, isFilter ) {
+ generateReport: function( type ) {
// Validation
if( !this.validation.objects() )
{
@@ -788,7 +789,7 @@
// Get searching values
p.searchingValues = [];
- if( !TR.state.paramChanged() )
+ if( !TR.state.paramChanged() || TR.state.isFilter )
{
var cols = TR.datatable.datatable.columns;
for( var k in cols )
@@ -828,7 +829,7 @@
p += '&orgunitIds=' + TR.state.orgunitIds[i];
}
- if( !TR.state.paramChanged() )
+ if( !TR.state.paramChanged() || TR.state.isFilter )
{
var cols = TR.datatable.datatable.columns;
for( var k in cols )
@@ -927,6 +928,7 @@
{
return true;
}
+ TR.state.isFilter = false;
return false;
}
return true;
@@ -1342,6 +1344,7 @@
TR.state.generateReport( type );
},
filter: function() {
+ TR.state.isFilter = true;
TR.state.filterReport();
},
paging: function( currentPage )
@@ -1992,7 +1995,7 @@
cls: 'tr-toolbar-btn-1',
text: TR.i18n.update,
handler: function() {
- if( !TR.state.paramChanged() )
+ if( !TR.state.paramChanged() || TR.state.isFilter )
{
TR.exe.filter();
}