Closed (fixed)
Project:
Webform Report
Version:
6.x-2.0-rc1
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
24 Aug 2008 at 18:56 UTC
Updated:
25 Feb 2011 at 14:41 UTC
Jump to comment: Most recent file
Comments
Comment #1
sunComment #2
brooke_heaton commentedAny progress on this?
Comment #3
drupaledmonk commentedany progress?? or any other way for searching through entries of submitted forms please help!!
Comment #4
vako commentedI am interested in this as well.
Although we can always do a Ctrl-F and search, but it's not the same, specially if there are multiple pages.
Comment #5
MBroberg commentedWith 6.x-2.0-beta4 you can set up a filter, but it is not yet exposed to users.
You can also sort by any column, and users can change that by clicking the column header.
So it's closer!
Comment #6
vako commentedThank you, will try it soon.
Comment #7
joeybernal commentedThis would be fantastic!
Comment #8
jimbullington commentedThe attached patch does the following:
The patch was created in Beta5.
Please leave feedback!
Comment #9
luthien commentedpatch is working great!
Comment #10
vako commentedI'm unable to apply this patch.
I'm new to Cygwin and after issuing the command
patch -p0 < 299414.patchit's telling me:
bash: patch: command not foundany easier way to apply this patch? it's too long to do it manually.
Comment #11
jimbullington commentedI don't use cygwin - you probably need to specify the complete path to the patch program, however.
I applied the patch to beta5 and attached the affected files. Hope this helps.
Comment #12
vako commentedThanks Jim.
I applied the patch, but unfortunately the search only works under FireFox but not in IE 8, Chrome and Opera.
Comment #13
vako commentedThe hidden fields are showing up in the Columns to search drop down (date and time that I used in the sort option).
Another suggestion is to keep the search section expanded once a search has been performed, because it is keeping the last search in memory and might confuse people.
Comment #14
jimbullington commentedThank you for the feeback.
The fix to exclude hidden columns is simple enough...
However, I don't understand why it only works in FF. When I tried to display your page in FF, I could not get the search column to drop down...
I have noted another issue - the search form does not work in a cached page. This may be the problem you are running into. Unless someone can think of a better idea, I think I will only display the search form to authenticated users - maybe I could check $GLOBALS['conf']['cache'] and display if caching is disabled (0).
Comment #15
vako commentedIs it working under IE for anyone else?
I use Boost cache and have excluded this page from caching, maybe that's why it's working under FF.
I know there is an unknown issue with my site and drop-down list, but a workaround is to use the up/down arrow keys for now.
Comment #16
vako commentedI replaced the files with the original beta5 files, so no traces of any patch.
Now even if we click on any of the column-headers, it's not sorting in that order. I'm not sure if this functionality worked before or not. Did anyone test this sorting?
Comment #17
jimbullington commentedComment #18
landry commentedReopening, as the search field doesnt work at all here with 6.x-2.0-rc1, using postgresql database.
I'm viewing the report as admin (with firefox, fwiw), and regardless of what i put in the search field (and in the dropdown column selection) all submissions are shown. This is with default drupal install, i didn't specifically enable caching, and it's the same whether i configure filters or not.
There's also a 'Display Report Filter Form' checkbox option on the report criteria tab which does nothing (i looked at the code). Maybe it should be hidden/removed until it's implemented.
Sorting works fine. The filters themselves work fine.
Comment #19
jimbullington commentedThank you for the feedback!
There's also a 'Display Report Filter Form' checkbox option on the report criteria tab which does nothing (i looked at the code). Maybe it should be hidden/removed until it's implemented
This was inadvertently left from an earlier patch revision - I will take it out.
I'm viewing the report as admin (with firefox, fwiw), and regardless of what i put in the search field (and in the dropdown column selection) all submissions are shown. This is with default drupal install, i didn't specifically enable caching, and it's the same whether i configure filters or not.
The search appears to be working for me - can you insert some debug prints and post the output? I'm interested in the value of the $_SESSION variable around line 120 in webform_report.inc.
Comment #20
landry commentedOh, i just found where it comes from. In fact it will only work on english websites :)
Fix is easy: in webform_report_search_form_submit(), replace 'Search' by t('Search') in the check for $form_state['values']['op']. Bam, it works. There could probably be a cleaner solution..
Comment #21
jimbullington commentedThank you posting the fix. I've created a patch, can you try it?
I refactored the search form and changed the submit to:
Comment #22
landry commentedYour patch works for me, thanks.
Comment #23
jimbullington commentedCommitted to CVS
Comment #24
vako commentedUsing FireFox browser with the February 4th version of 6.x-2.x-dev and a special PHP code that was provided. When I do a search, it comes with the following error:
if (function_exists('ip2cc_get_country') && function_exists('theme_countryicons_icon')) { $headers[5] = 'Country Name'; $headers[6] = 'Country Code'; $headers[7] = 'Country Icon'; foreach($rows as $i => $row) { $ip = $row[4]['data']; $c = ip2cc_get_country($ip); $rows[$i][5]['data'] = $c->country_name; $rows[$i][6]['data'] = $c->country_code2; $rows[$i][7]['data'] = theme_countryicons_icon($c->country_code2); } }
If you go back and hit refresh the search works and displays the correct rows. However the error above stays above the header of the site.
The search doesn't work at all for IE 8 but displays the same error.
Tried it on two different sites with the same issue.
Comment #25
jimbullington commentedThe PHP code needs to start with
and end with.Comment #26
vako commentedYes, that was it, I changed the PHP code and it is working now under FireFox, however IE 8 still doesn't provide any results, just gives the full list.
Comment #27
jimbullington commentedI think is a problem with caching. If I'm logged into the site, the search works - both in both FF and IE8. But it does not work for anonymous users.
I think I either need to disable this feature for anonymous users or disable caching when this feature is turned on.
What does the community think?
Comment #28
jimbullington commentedComment #29
vako commentedCaching is important, however search is a powerful option and most of the sites might need it.
My suggestion is to disable caching when this feature is on.
If it's not too hard, you might provide an option for the admin to choose between the two.
Comment #30
jimbullington commentedThe code will be change to disable the search form for anonymous users if site caching is enabled. If you want to change this behaviour, site caching will need to be disabled or the module can be altered to turn off site caching under certain conditions.