Commit 403a1285 authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_crm: If monitor is disabled, don't generate tickets for the hosting subscription.

parent bf9a98ab
......@@ -4,6 +4,10 @@ from Products.ERP5Type.DateUtils import addToDate
hosting_subscription = context
portal = context.getPortalObject()
if hosting_subscription.getMonitorScope() == "disable":
# Don't generate ticket if Monitor Scope is marked to disable
return
if portal.ERP5Site_isSupportRequestCreationClosed():
# Stop ticket creation
return
......@@ -14,9 +18,6 @@ if (date_check_limit - hosting_subscription.Base_getCachedCreationDate()) < 0:
# Too early to check
return
#if not source_instance:
# return
software_instance_list = hosting_subscription.getSpecialiseRelatedValueList(
portal_type=["Software Instance", "Slave Instance"])
......
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