thegooglecodearchive / allforgood

Automatically exported from code.google.com/p/allforgood
0 stars 0 forks source link

Opp dates shown in SERP as "Ongoing" when they are not. #609

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The echoditto code is flagging opps in the SERP UI as “Ongoing” when they 
are clearly not.  I’m not sure if the same error is occurring on production.  
It looks as if the logic used to determine whether to display an opp’s date 
as “ongoing” is not correct.  In the below example, the opp clearly has 
start and stop date values for April and is not openended:true in Solr, but the 
opp is being shown in the SERP UI as “Ongoing”.  I’m guessing the issue 
is in this logic. 
http://code.google.com/p/allforgood/source/browse/branches/release_2_0.transitio
nal/frontend/templatetags/dateutils_tags.py

1. Sample URL and screen shot showing opp as “Ongoing”
http://echoditto.latest.footprint2009dev.appspot.com/search#q=Improve%20Our%20De
ntal%20Brochure%20For%20Children&num=10&start=1&vol_loc=10012&distance=25&type=m
icro&sort=Relevance&timeperiodstart=start%20date&timeperiodend=end%20date&cache=
1

2. Solr query for that opp that shows it near term start and stop dates and is 
not openended
http://li169-139.members.linode.com:8983/solr/select/?&wt=xml&sort=Relevance%20d
esc&fq=%28%28eventrangeend:[2011-04-07T00:00:00.000Z+TO+*]+AND+eventrangestart:[
*+TO+2011-04-07T23:59:59.999Z]%29+OR+%28eventrangeend:+%221971-01-01T00:00:000Z%
22+AND+eventrangestart:%221971-01-01T00:00:000Z%22%29%29&rows=100&start=0&q=*%3A
*+AND+improve+our+dental+brochure+for+children+AND+micro:true
<int name="endtime">0</int>
<str name="event_date_range">2011-04-06T13:16:23/2011-04-07T00:00:00</str>
<int name="eventduration">0</int>
<date name="eventrangeend">2011-04-07T00:00:00Z</date>
<date name="eventrangestart">2011-04-06T13:16:23Z</date>
<bool name="openended">false</bool>
<int name="starttime">1316</int>

Original issue reported on code.google.com by danstryk...@gmail.com on 7 Apr 2011 at 2:15

GoogleCodeExporter commented 9 years ago
Adding some padding to the logic that compares start and end dates when 
comparing them to today. The opps on the page below were marked as ongoing but 
now show their dates.

http://echoditto.latest.footprint2009dev.appspot.com/search#num=10&start=1&vol_l
oc=10012&distance=25&type=micro&sort=Relevance&timeperiodstart=start%20date&time
periodend=end%20date&cache=1

Original comment by jwdemp...@gmail.com on 7 Apr 2011 at 4:01

GoogleCodeExporter commented 9 years ago
verified

Original comment by danstryk...@gmail.com on 8 Apr 2011 at 1:41