Limit RSS feedback to year or so. Allow accessing RSS feeds of past years.
Changed to_html to emit only the feeds for this and last year. Added a unit-test. Running sudo -u apache /usr/local/bin/ruby jobs/update_rss_feeds
to regenerate the feeds. But this only regenerate price_cut and sl_introduction.
Must call jobs/update_textinfo_swissmedicinfo --target=fi
. Now I am starting to create files like fachinfo-2006.rss. The problem is, that it looks like update_textinfo_swissmedicinfo changes all active fachinfos and sets therefore the fachinfo.revision field (by odba_storage) to the actual date. Found a counter example
ch.oddb> registration('58778').fachinfo.revision -> 2015-10-28 07:09:27 +0100 ch.oddb> registration('58778').fachinfo.de.date -> Stand der Information August 2015
Trying to make http://oddb-ci2.dyndns.org/de/gcc/rss/channel/fachinfo-2006.rss work. Okay. I think it is better to try to use http://oddb-ci2.dyndns.org/de/gcc/rss/channel/fachinfo.rss/2006. No. Made it pass with fachinfo-2006.rss. But the problem is, that the RSS feeds are still very big as shown by this list
-rw-r--r-- 1 apache apache 66K 14. Dez 13:50 data/rss/de/fachinfo-2006.rss -rw-r--r-- 1 apache apache 44K 14. Dez 13:50 data/rss/de/fachinfo-2007.rss -rw-r--r-- 1 apache apache 52K 14. Dez 13:50 data/rss/de/fachinfo-2008.rss -rw-r--r-- 1 apache apache 22K 14. Dez 13:50 data/rss/de/fachinfo-2009.rss -rw-r--r-- 1 apache apache 1.3M 14. Dez 13:50 data/rss/de/fachinfo-2010.rss -rw-r--r-- 1 apache apache 861K 14. Dez 13:50 data/rss/de/fachinfo-2011.rss -rw-r--r-- 1 apache apache 597K 14. Dez 13:50 data/rss/de/fachinfo-2012.rss -rw-r--r-- 1 apache apache 8.9M 14. Dez 13:51 data/rss/de/fachinfo-2013.rss -rw-r--r-- 1 apache apache 4.0M 14. Dez 13:52 data/rss/de/fachinfo-2014.rss -rw-r--r-- 1 apache apache 9.3M 14. Dez 13:52 data/rss/de/fachinfo-2015.rss -rw-r--r-- 1 apache apache 14M 14. Dez 13:49 data/rss/de/fachinfo.rss
fachinfo.rss contains the years 2014 and 2015. For comparision on thinpower we have 25M for data/rss/de/fachinfo.rss.
Activated the changes on thinpower and started update_textinfo_swissmedicinfo
in screen 4390.update_fi_pi
.
Looks like if the search_results uses the names of the atc_class to sort and not the code see bin/admin
ch.oddb> search_combined('Sevikar', 'de').atc_classes.first.code -> C09DB02 ch.oddb> search_combined('Sevikar', 'de').atc_classes.last.code -> C09DX03 ch.oddb> search_combined('Sevikar', 'de').atc_classes.first.name -> Olmesartan Medoxomil und Amlodipin ch.oddb> search_combined('Sevikar', 'de').atc_classes.last.name -> Olmesartan Medoxomil, Amlodipine and Hydrochlorothiazide
Debugging I found that src/state/drugs/result.rb has the atc_classes correctly ordered. Therefore I probably must inject sorting by atc-code into the src/util/result_sort.rb. No. The problem lies that in src/view/drugs/resultlist.rb we did not sort the result by atc-code.
Now my watir test passes. Running all watir & unit tests before pushing commits Sort results by ATC-Code and Better logging for tests