dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #17923
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 7333: Filter properties of patients in tabular report.
------------------------------------------------------------
revno: 7333
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2012-06-20 15:18:00 +0700
message:
Filter properties of patients in tabular report.
modified:
dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java
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/i18n.vm
--
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-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java 2012-06-14 13:07:22 +0000
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/hibernate/HibernateProgramStageInstanceStore.java 2012-06-20 08:18:00 +0000
@@ -320,6 +320,14 @@
if ( objectType.equals( PREFIX_FIXED_ATTRIBUTE ) )
{
sql += "p." + infor[1] + ",";
+
+ if ( infor.length == 4 )
+ {
+ String value = lower( infor[3] );
+ where += operator + "lower(" + infor[1] + ") " + value + " ";
+
+ operator = "and ";
+ }
}
else
{
=== 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-06-20 06:32:51 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/app/app.js 2012-06-20 08:18:00 +0000
@@ -837,7 +837,7 @@
var value = compare + "'"+ filter.data.value + "'";
var record = grid.getView().getRecord( grid.getView().getNode(0) );
- record.set(filter.field, value);
+ record.set(filter.field, value.toLowerCase());
}
},
getParams: function() {
@@ -956,7 +956,7 @@
var col = cols[i];
if( col.name && col.name == colname )
{
- var value = editor.data[col.dataIndex];
+ var value = editor.data[col.dataIndex].toLowerCase();
var hidden = (col.hidden==undefined)? false : col.hidden;
if( value!=null && value!= '')
{
@@ -1231,16 +1231,8 @@
sortable: false,
draggable: false,
hidden: eval(TR.value.columns[index].hidden ),
- editor: {
- xtype: TR.value.columns[index].xtype,
- queryMode: 'local',
- editable: true,
- valueField: 'name',
- displayField: 'name',
- store: new Ext.data.ArrayStore({
- fields: ['name'],
- data: TR.value.columns[index].suggested
- })
+ filter:{
+ type: "string"
}
}
});
@@ -1253,7 +1245,8 @@
cols[++index]={
xtype:'actioncolumn',
- width:25,
+ header: TR.i18n.operations,
+ width:80,
sortable: false,
draggable: false,
hideable: false,
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/i18n.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/i18n.vm 2012-06-12 03:38:24 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/i18n.vm 2012-06-20 08:18:00 +0000
@@ -82,5 +82,6 @@
on:'$encoder.jsEscape($i18n.getString( 'on' ) , "'")',
orgunit_groups:'$encoder.jsEscape($i18n.getString( 'orgunit_groups' ) , "'")',
none:'[' + '$encoder.jsEscape($i18n.getString( 'none' ) , "'")' + ']',
-not_empty:'$encoder.jsEscape($i18n.getString( 'not_empty' ) , "'")'
+not_empty:'$encoder.jsEscape($i18n.getString( 'not_empty' ) , "'")',
+operations:'$encoder.jsEscape($i18n.getString( 'operations' ) , "'")',
};
\ No newline at end of file