Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Titouan Soulard
erp5
Commits
3a45c304
Commit
3a45c304
authored
Apr 09, 2015
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CRM: When ingesting email, lookup first validated senders
and in any case, do not accept deleted ones
parent
6faa1b16
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
6 deletions
+13
-6
bt5/erp5_crm/SkinTemplateItem/portal_skins/erp5_crm/Event_finishIngestion.xml
...plateItem/portal_skins/erp5_crm/Event_finishIngestion.xml
+13
-6
No files found.
bt5/erp5_crm/SkinTemplateItem/portal_skins/erp5_crm/Event_finishIngestion.xml
View file @
3a45c304
...
@@ -112,22 +112,29 @@ if context.getPortalType() == \'Web Message\' and\\\n
...
@@ -112,22 +112,29 @@ if context.getPortalType() == \'Web Message\' and\\\n
person = None\n
person = None\n
organisation = None\n
organisation = None\n
if context.getSourcePersonFirstName() or context.getSourcePersonLastName():\n
if context.getSourcePersonFirstName() or context.getSourcePersonLastName():\n
person_email = portal.portal_catalog.getResultValue(\n
for validation_state in (\'validated\', \'!= deleted\'):\n
person_email = portal.portal_catalog.getResultValue(\n
url_string={\'query\': email_text, \'key\':\'ExactMatch\'},\n
url_string={\'query\': email_text, \'key\':\'ExactMatch\'},\n
portal_type=\'Email\',\n
portal_type=\'Email\',\n
parent_portal_type=person_portal_type,\n
parent_portal_type=person_portal_type,\n
validation_state=validation_state,\n
parent_title=\'%s %s\' % (context.getSourcePersonFirstName(\'\'),\n
parent_title=\'%s %s\' % (context.getSourcePersonFirstName(\'\'),\n
context.getSourcePersonLastName(\'\')))\n
context.getSourcePersonLastName(\'\')))\n
if person_email is not None:\n
if person_email is not None:\n
person = person_email.getParentValue()\n
person = person_email.getParentValue()\n
break\n
if context.getSourceOrganisationTitle():\n
if context.getSourceOrganisationTitle():\n
organisation_email = portal.portal_catalog.getResultValue(\n
for validation_state in (\'validated\', \'!= deleted\'):\n
organisation_email = portal.portal_catalog.getResultValue(\n
url_string={\'query\': email_text, \'key\':\'ExactMatch\'},\n
url_string={\'query\': email_text, \'key\':\'ExactMatch\'},\n
portal_type=\'Email\',\n
portal_type=\'Email\',\n
parent_portal_type=organisation_portal_type,\n
parent_portal_type=organisation_portal_type,\n
validation_state=validation_state,\n
parent_title=context.getSourceOrganisationTitle(\'\'))\n
parent_title=context.getSourceOrganisationTitle(\'\'))\n
if organisation_email is not None:\n
if organisation_email is not None:\n
organisation = organisation_email.getParentValue()\n
organisation = organisation_email.getParentValue()\n
break\n
\n
if person is None and (context.getSourcePersonFirstName() or context.getSourcePersonLastName()):\n
if person is None and (context.getSourcePersonFirstName() or context.getSourcePersonLastName()):\n
person_module = portal.getDefaultModule(person_portal_type)\n
person_module = portal.getDefaultModule(person_portal_type)\n
person = person_module.newContent(portal_type=person_portal_type,\n
person = person_module.newContent(portal_type=person_portal_type,\n
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment