Updated OID router to remove optional '::' from URL
authorThierry Florac <thierry.florac@onf.fr>
Tue, 08 Jan 2019 17:59:46 +0100
changeset 352 2cdb8562f7fd
parent 351 09b8d282db1a
child 353 1ed87336d991
Updated OID router to remove optional '::' from URL
src/pyams_default_theme/routes.py
--- a/src/pyams_default_theme/routes.py	Tue Jan 08 15:18:38 2019 +0100
+++ b/src/pyams_default_theme/routes.py	Tue Jan 08 17:59:46 2019 +0100
@@ -33,6 +33,7 @@
     """
     oid = request.matchdict.get('oid')
     if oid:
+        oid = oid.split('::')[0]
         view_name = request.matchdict.get('view')
         sequence = get_utility(ISequentialIntIds)
         reference = sequence.get_full_oid(oid)