Commit a1a88a6a authored by Sven Franck's avatar Sven Franck

erp5_corporate_identity: remove absolute urls from anchors

parent 2a768bac
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15175966.44</string> </value>
<value> <string>ts15420563.89</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>c0ae3d4ec4b196b8ecd5acae40b31981</string> </value>
<value> <string>b8de3de0a22d90c9272e10cfa05e92d7</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176051.49</string> </value>
<value> <string>ts15420644.41</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>bc12584785a3d311dc3719a0345c91a3</string> </value>
<value> <string>97cc44e4aeece5984c3f7c5586ba9231</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15175990.02</string> </value>
<value> <string>ts15420581.07</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>b575e14ac324da64c11c3c2817e45db1</string> </value>
<value> <string>99cc5646f1d8330bbceb4db690e96354</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15175982.31</string> </value>
<value> <string>ts15420576.27</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>57383fd25a551ea95ae9242149ccc088</string> </value>
<value> <string>ec3d6ed48ec29b2fd031978f59c7b0f2</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15175976.93</string> </value>
<value> <string>ts15420572.39</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>f9c2d8dd0e9e42a6edf7ab6ef6b37f87</string> </value>
<value> <string>f773f69605e66f3dcbd5a1a6cda2c119</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176005.51</string> </value>
<value> <string>ts15420596.24</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>23f314a0018a7e77f29ebe0d420d8395</string> </value>
<value> <string>551fee3dcee22951bfa0ca5d0ae6347e</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15175996.0</string> </value>
<value> <string>ts15420586.85</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>9cd04fd36df6f9c143bc1d189e8fe51a</string> </value>
<value> <string>01ab18bd48d3a6c8e9809fba306382dc</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176002.4</string> </value>
<value> <string>ts15420593.06</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>330ed00f11858f996449bdd1f6aba9ad</string> </value>
<value> <string>46e2d9d6bd04b044c41a4087cf447175</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15175999.2</string> </value>
<value> <string>ts15420589.94</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>11993b1e98c3f0e7c0ca065ecd1be1ff</string> </value>
<value> <string>7cc17b537278a19d5af114c7b10490de</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176011.22</string> </value>
<value> <string>ts15420599.96</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>2a6817742211295cfc7a3ae5f6594af0</string> </value>
<value> <string>15e43889d60a0f023978918005002f65</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176015.36</string> </value>
<value> <string>ts15420605.92</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>223d61d7f8b52175f939d8ce91bc4e41</string> </value>
<value> <string>08fce15da5ed4ef5a12f2bb3dd588ab6</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176033.62</string> </value>
<value> <string>ts15420628.94</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>6e715b910ac9073a5b07019d8a70c0da</string> </value>
<value> <string>5c9180eb4ea80f1ded48042cdfdada45</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176019.84</string> </value>
<value> <string>ts15420613.25</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>12d7aed66fce66f765fcd7df07130730</string> </value>
<value> <string>31f552fb1f475a0e9ed81f51bf0a472f</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -39,7 +39,7 @@
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts15176024.36</string> </value>
<value> <string>ts15420619.84</string> </value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
......@@ -83,7 +83,7 @@
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>9df2ae1e3495ee7781d2cb4934f38e8d</string> </value>
<value> <string>36381934960d9b85278fff59ef31245d</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
......
......@@ -82,9 +82,9 @@
<section class="ci-book-table-of-content"><p class="ci-book-toc-faux-h1">Inhaltsverzeichnis</p><ol><li><div><a href="#synthese">Synthese</div></a><ol><li><div><a href="#risks-and-measures">Risks and measures</div></a><ol><li><div><a href="#risk-of-casualties-if-device-does-not-stop-and-destroys-itself">Risk of casualties if device does not stop and destroys itself</div></a></li><li><div><a href="#risk-of-killing-birds-and-polluting-the-environment">Risk of killing birds and polluting the environment</div></a></li><li><div><a href="#noise-and-vibration-levels">Noise and vibration levels</div></a></li></ol></li></ol><li><div><a href="#reports">Reports</div></a><ol><li><div><a href="#project-reports">Project Reports</div></a></li><li><div><a href="#sale-order-reports">Sale Order Reports</div></a></ol></ol></section>
<section class="ci-book-table-of-content"><p class="ci-book-toc-faux-h1">Inhaltsverzeichnis</p><ol><li><div><a href="#synthese_anchor">Synthese</div></a><ol><li><div><a href="#risks-and-measures_anchor">Risks and measures</div></a><ol><li><div><a href="#risk-of-casualties-if-device-does-not-stop-and-destroys-itself_anchor">Risk of casualties if device does not stop and destroys itself</div></a></li><li><div><a href="#risk-of-killing-birds-and-polluting-the-environment_anchor">Risk of killing birds and polluting the environment</div></a></li><li><div><a href="#noise-and-vibration-levels_anchor">Noise and vibration levels</div></a></li></ol></li></ol><li><div><a href="#reports_anchor">Reports</div></a><ol><li><div><a href="#project-reports_anchor">Project Reports</div></a></li><li><div><a href="#sale-order-reports_anchor">Sale Order Reports</div></a></ol></ol></section>
<h1><a name="synthese"></a>Synthese<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#synthese"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1>
<h1><a name="synthese_anchor"></a>Synthese<a class="custom-para" href=Template.Test.Book#synthese><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1>
<p>This document is a high level overview measures taken by Foo for Bar project. </p>
<p>
The purpose of this document is to show possible dangers and measures being
......@@ -94,8 +94,8 @@ taken to prevent them from legal and ethics point of view.
<h2><a name="risks-and-measures"></a>Risks and measures<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#risks-and-measures"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
<h3><a name="risk-of-casualties-if-device-does-not-stop-and-destroys-itself"></a>Risk of casualties if device does not stop and destroys itself<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#risk-of-casualties-if-device-does-not-stop-and-destroys-itself"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h3>
<h2><a name="risks-and-measures_anchor"></a>Risks and measures<a class="custom-para" href=Template.Test.Book#risks-and-measures><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
<h3><a name="risk-of-casualties-if-device-does-not-stop-and-destroys-itself_anchor"></a>Risk of casualties if device does not stop and destroys itself<a class="custom-para" href=Template.Test.Book#risk-of-casualties-if-device-does-not-stop-and-destroys-itself><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h3>
<p>
When is it safe to turn off if we turn if off too early or are to risk-aversise,
economic losses of the device not working can be incurred. If on the other hand
......@@ -110,14 +110,14 @@ learning. Based on these findings another model / formula can be derived in
which we can calculate risk and evaluate costs of insurance which can cover
risk of casualties, et al.
</p>
<h3><a name="risk-of-killing-birds-and-polluting-the-environment"></a>Risk of killing birds and polluting the environment<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#risk-of-killing-birds-and-polluting-the-environment"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h3>
<h3><a name="risk-of-killing-birds-and-polluting-the-environment_anchor"></a>Risk of killing birds and polluting the environment<a class="custom-para" href=Template.Test.Book#risk-of-killing-birds-and-polluting-the-environment><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h3>
<p>The software is set up on pre-existing devices which should have already
passed regulatory checks and certification concerning these risks. The use of
smart sensors technology in no way compromises security as the software
is solely responsible for shutting down and starting a device without
affects its normal operation nor its structure.
</p>
<h3><a name="noise-and-vibration-levels"></a>Noise and vibration levels<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#noise-and-vibration-levels"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h3>
<h3><a name="noise-and-vibration-levels_anchor"></a>Noise and vibration levels<a class="custom-para" href=Template.Test.Book#noise-and-vibration-levels><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h3>
<p>
During operation, sound and vibration continue to be emitted into the
water body, potentially disturbing the communication and foraging behaviour
......@@ -193,15 +193,15 @@ which should not be touched.
web page, this time Google [<a href="https://www.google.com/" title="Google Website;Search;0;1">AD</a>], to
test whether the counter increments correctly.
</p>
<h1><a name="reports"></a>Reports<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#reports"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1>
<h1><a name="reports_anchor"></a>Reports<a class="custom-para" href=Template.Test.Book#reports><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1>
<p>
Embedding reports should work via links with a report name and subsequent parameters
specified. Reports are all custom, so if they don't exist, they will not be loaded.
</p>
<h2><a name="project-reports"></a>Project Reports<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#project-reports"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
<h2><a name="project-reports_anchor"></a>Project Reports<a class="custom-para" href=Template.Test.Book#project-reports><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
<a href="project_module/template_test_project?report=Base_generateLineBreakdownReport&amp;display_header=2">Line Breakdown Report</a>
<br/>
<h2><a name="sale-order-reports"></a>Sale Order Reports<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#sale-order-reports"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
<h2><a name="sale-order-reports_anchor"></a>Sale Order Reports<a class="custom-para" href=Template.Test.Book#sale-order-reports><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
<a href="sale_order_module/template_test_sale_order?report=Base_generateCostEffortReport&amp;display_detail=detailed">Cost Effort Report</a>
<br/>
<a href="sale_order_module/template_test_sale_order?report=Base_generateDeliverableReport">Deliverable Report</a>
......
......@@ -62,7 +62,6 @@ doc_relative_url = doc.getRelativeUrl()
doc_rendering_fix = doc.Base_getCustomTemplateParameter('wkhtmltopdf_rendering_fix') or blank
doc_report = getattr(doc, doc_report_name)
doc_aggregate_list = []
doc_absolute_url = doc.getAbsoluteUrl()
doc_revision = "1"
doc_modification_date = DateTime()
doc_short_date = doc_modification_date.strftime('%Y-%m-%d')
......
......@@ -6,7 +6,6 @@ Create HTML table of content (to be used on web pages instead of xsl for pdf)
# parameters
# ------------------------------------------------------------------------------
# doc_content text content of document being rendered
# doc_url absolute url of document
# doc_toc_title translated title for table of content
import re
......@@ -42,17 +41,17 @@ for header in re.findall("<h[1-6].*?</h[1-6]>", doc_content or blank):
snippet = ''.join(['>', header_reference])
named_snippet = ''.join([
'>',
'<a name="', html_quote(header_reference_prefix), '"></a>',
'<a name="', html_quote(header_reference_prefix), '_anchor"></a>',
header_reference,
'<a class="custom-para" href="', doc_url, '#', header_reference_prefix, '"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a>'
'<a class="custom-para" href=', doc_reference, '#', header_reference_prefix, '><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a>'
])
doc_content = doc_content.replace(snippet, named_snippet)
# create table of content entry
table_of_content += ''.join([
'<li><div><a href="#',
html_quote(header_reference_prefix),
'">',
'_anchor">',
html_quote(header_reference),
'</div></a>']
)
......@@ -61,7 +60,7 @@ closer = int(header_current) * '</ol>'
insert = ''.join([
'<section class="ci-book-table-of-content">',
'<p class="ci-book-toc-faux-h1">%s</p>' % (doc_toc_title or "Table of Contents"),
table_of_content,
table_of_content,
closer,
'</section>'
])
......
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>doc_content=None, doc_url=None, doc_toc_title=None</string> </value>
<value> <string>doc_content=None, doc_reference=None, doc_toc_title=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
......
......@@ -81,7 +81,6 @@ book_rendering_fix = book.Base_getCustomTemplateParameter('wkhtmltopdf_rendering
book_dialog_id = book_form.get('dialog_id', None)
book_content = book.getTextContent()
book_aggregate_list = []
book_absolute_url = book.getAbsoluteUrl()
book_revision = book.getRevision()
book_modification_date = book.getModificationDate()
book_language = book.Base_setToNone(param=book.getLanguage())
......@@ -198,7 +197,7 @@ if book_include_content_table is not None:
elif book_format == "html":
book_content, book_table_of_content = book.WebPage_createTableOfContent(
doc_content=book_content,
doc_url=book_absolute_url,
doc_reference=book_reference,
doc_toc_title=book_translated_toc_title
)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment