Hi Tibor,
could you please apply this tiny patch? I've refreshed it to apply
cleanly to current git tree.
Thanks,
Ferran
Websearch: add a newline before printing Marc tags
The output of Marc format in search_engine.py is useful for offline
processing. Adding a newline before <pre> simplifies it.
---
Index: cds-invenio/modules/websearch/lib/search_engine.py
===================================================================
--- cds-invenio.orig/modules/websearch/lib/search_engine.py 2009-10-15 10:22:58.000000000 +0200
+++ cds-invenio/modules/websearch/lib/search_engine.py 2009-10-15 10:29:38.000000000 +0200
@@ -3371,16 +3371,16 @@
elif format == "hm":
if record_exist_p == -1:
- out += "<pre>" + cgi.escape(get_fieldvalues_alephseq_like(recID, ["001", CFG_OAI_ID_FIELD, "980"])) + "</pre>"
+ out += "\n<pre>" + cgi.escape(get_fieldvalues_alephseq_like(recID, ["001", CFG_OAI_ID_FIELD, "980"])) + "</pre>"
else:
- out += "<pre>" + cgi.escape(get_fieldvalues_alephseq_like(recID, ot)) + "</pre>"
+ out += "\n<pre>" + cgi.escape(get_fieldvalues_alephseq_like(recID, ot)) + "</pre>"
elif format.startswith("h") and ot:
## user directly asked for some tags to be displayed only
if record_exist_p == -1:
- out += "<pre>" + get_fieldvalues_alephseq_like(recID, ["001", CFG_OAI_ID_FIELD, "980"]) + "</pre>"
+ out += "\n<pre>" + get_fieldvalues_alephseq_like(recID, ["001", CFG_OAI_ID_FIELD, "980"]) + "</pre>"
else:
- out += "<pre>" + get_fieldvalues_alephseq_like(recID, ot) + "</pre>"
+ out += "\n<pre>" + get_fieldvalues_alephseq_like(recID, ot) + "</pre>"
elif format == "hd":
# HTML detailed format