Hello,
I do not know if it is a feature or a bug in latest 4.1d. Since I am using this version the listGrid filter does not ignore the upper and lower case search. I need to enter the search term with correct upper and lower cases.
Thanks for your help.
best regards
Andy
I do not know if it is a feature or a bug in latest 4.1d. Since I am using this version the listGrid filter does not ignore the upper and lower case search. I need to enter the search term with correct upper and lower cases.
Thanks for your help.
best regards
Andy
Code:
listGrid = new ListGrid(); listGrid.setDataSource( getDataSource() ); listGrid.setShowFilterEditor( true ); listGrid.setAutoFetchData( true ); listGrid.setEmptyCellValue( "---" ); listGrid.setAutoFitFieldsFillViewport( true ); ListGridField displayField = new ListGridField( CItemSupplyEmails.display_name, constants.listGridEmailsSenderName() ); displayField.setWidth( "20%" ); ListGridField senderField = new ListGridField( CItemSupplyEmails.sender_adress, constants.listGridEmailsSenderAddress() ); senderField.setWidth( "20%" ); ListGridField headlineField = new ListGridField( CItemSupplyEmails.headline, constants.listGridEmailsSubject() ); headlineField.setWidth( "35%" ); ListGridField statusField = new ListGridField( CItemSupplyEmails.status, constants.listGridEmailsStatus() ); statusField.setWidth( "5%" ); statusField.setAlign( Alignment.CENTER ); statusField.setCellFormatter( new CellFormatter() { public String format( Object value, ListGridRecord record, int rowNum, int colNum ) { if ( value == null ) return null; try { String[] split = String.valueOf( value ).split( "/" ); if ( split[0].equals( split[1] ) ) { return "<font color = 'green'> " + value.toString() + "</font>"; } else if ( String.valueOf( value ).toLowerCase().trim().equals( "warten" ) || String.valueOf( value ).toLowerCase().trim().equals( "waiting" ) || Integer.valueOf( split[0] ) < Integer.valueOf( split[1] ) ) { return "<font color = 'orange'> " + value.toString() + "</font>"; } else { return "<font color = 'red'> " + value.toString() + "</font>"; } } catch ( Exception e ) { return "<font color = 'red'> " + value.toString() + "</font>"; } } } ); ListGridField attachmentsField = new ListGridField( CItemSupplyEmails.attachments, constants.listGridEmailsAttachments() ); attachmentsField.setWidth( "5%" ); attachmentsField.setAlign( Alignment.CENTER ); ListGridField creatorField = new ListGridField( CItemSupplyEmails.creator, constants.listGridEmailsSender() ); creatorField.setWidth( "10%" ); ListGridField createDateField = new ListGridField( CItemSupplyEmails.creation_date, constants.listGridEmailsSendedDate() ); createDateField.setWidth( "10%" ); createDateField.setAlign( Alignment.LEFT ); listGrid.setFields( displayField, senderField, headlineField, statusField, attachmentsField, creatorField, createDateField );
Comment