Commit 09e0e3c8 authored by Łukasz Nowak's avatar Łukasz Nowak

Avoid flooding intergration site.

parent f50cd4b9
...@@ -69,14 +69,15 @@ transaction_id = str(portal.portal_ids.generateNewId(\n ...@@ -69,14 +69,15 @@ transaction_id = str(portal.portal_ids.generateNewId(\n
id_generator=\'uid\')).zfill(6)\n id_generator=\'uid\')).zfill(6)\n
\n \n
mapping_id = \'%s_%s\' % (today, transaction_id)\n mapping_id = \'%s_%s\' % (today, transaction_id)\n
try:\n if integration_site.getMappingFromCategory(\'causality/%s\' % context.getRelativeUrl()) == \'Causality/%s\' % context.getRelativeUrl():\n
integration_site.getCategoryFromMapping(\'Causality/%s\' % mapping_id, create_mapping_line=True, create_mapping=True)\n try:\n
except ValueError:\n integration_site.getCategoryFromMapping(\'Causality/%s\' % mapping_id, create_mapping_line=True, create_mapping=True)\n
mapping = integration_site.Causality[mapping_id]\n except ValueError:\n
mapping.setDestinationReference(\'causality/%s\' % context.getRelativeUrl())\n mapping = integration_site.Causality[mapping_id]\n
else:\n mapping.setDestinationReference(\'causality/%s\' % context.getRelativeUrl())\n
system_event.confirm(comment=\'Key %s already found!\' % mapping_id)\n else:\n
return \'There was system issue\'\n system_event.confirm(comment=\'Key %s already found!\' % mapping_id)\n
return \'There was system issue\'\n
\n \n
if context.getStartDate() is None:\n if context.getStartDate() is None:\n
context.setStartDate(now)\n context.setStartDate(now)\n
......
56 57
\ No newline at end of file \ No newline at end of file
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