Commit 9c3f71cc authored by Romain Courteaud's avatar Romain Courteaud 🐸

Computer may still have capacity for slave partition.

No being able to allocation Software Instance should not prevent allocating slave instance.
parent 8ef95d87
...@@ -119,15 +119,15 @@ if can_allocate:\n ...@@ -119,15 +119,15 @@ if can_allocate:\n
comment = \'Computer capacity limit exceded\'\n comment = \'Computer capacity limit exceded\'\n
break\n break\n
\n \n
if can_allocate:\n # if can_allocate:\n
result_list = portal.portal_catalog.portal_catalog(\n # result_list = portal.portal_catalog.portal_catalog(\n
parent_uid=computer.getUid(),\n # parent_uid=computer.getUid(),\n
portal_type=\'Computer Partition\',\n # portal_type=\'Computer Partition\',\n
free_for_request=1,\n # free_for_request=1,\n
limit=1)\n # limit=1)\n
if len(result_list) == 0:\n # if len(result_list) == 0:\n
can_allocate = False\n # can_allocate = False\n
comment = \'No free partition left\'\n # comment = \'No free partition left\'\n
\n \n
new_value = None\n new_value = None\n
if can_allocate:\n if can_allocate:\n
......
10 11
\ 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