diff --git a/product/ERP5/Document/AcceptSolver.py b/product/ERP5/Document/AcceptSolver.py index 52d602a3376c3d992209741f7d27e9514274733b..923f5925f5ac1ade24d985650d344c448df81332 100644 --- a/product/ERP5/Document/AcceptSolver.py +++ b/product/ERP5/Document/AcceptSolver.py @@ -66,8 +66,7 @@ class AcceptSolver(SolverMixin, XMLObject): solved_property = self._getPortalTypeValue().getTestedProperty() for movement in self.getDeliveryValueList(): new_value = movement.getProperty(solved_property) - for simulation_movement in movement.getDeliveryRelatedValueList( - portal_type='Simulation Movement'): + for simulation_movement in movement.getDeliveryRelatedValueList(): if not simulation_movement.isPropertyRecorded(solved_property): simulation_movement.recordProperty(solved_property) # XXX hard coded diff --git a/product/ERP5/Document/Delivery.py b/product/ERP5/Document/Delivery.py index 67e34325a8965fcd3c3273cde1cc285d8e9b33fa..c3be99e9001755a3399483b9c39bbe2b4511c9a0 100644 --- a/product/ERP5/Document/Delivery.py +++ b/product/ERP5/Document/Delivery.py @@ -792,8 +792,7 @@ class Delivery(XMLObject, ImmobilisationDelivery): # we might use a zsql method, because it can be very slow for m in self.getMovementList(): if m.isSimulated(): - sim_movement_list = m.getDeliveryRelatedValueList( - portal_type='Simulation Movement') # XXX hardcoded + sim_movement_list = m.getDeliveryRelatedValueList() for sim_movement in sim_movement_list: if sim_movement.getRootAppliedRule().getPath() \ not in excluded_rule_path_list: diff --git a/product/ERP5/Document/Movement.py b/product/ERP5/Document/Movement.py index 9db2b9fb36f6da2dabf2b67db0f09edc44b1ccef..38365762ccaf880d5f15014e2048324279de1999 100644 --- a/product/ERP5/Document/Movement.py +++ b/product/ERP5/Document/Movement.py @@ -493,8 +493,7 @@ class Movement(XMLObject, Amount): Return a list of messages that contains the divergences """ divergence_list = [] - for simulation_movement in self.getDeliveryRelatedValueList( - portal_type='Simulation Movement'): # XXX hardcoded + for simulation_movement in self.getDeliveryRelatedValueList(): divergence_list.extend(simulation_movement.getDivergenceList()) return divergence_list diff --git a/product/ERP5/Document/QuantitySplitSolver.py b/product/ERP5/Document/QuantitySplitSolver.py index 72a43253f334ae65f2660e54390f34fc0f8ccaeb..5bdef176af29d5edb7a5b043fbdd40239b20a25f 100644 --- a/product/ERP5/Document/QuantitySplitSolver.py +++ b/product/ERP5/Document/QuantitySplitSolver.py @@ -65,8 +65,7 @@ class QuantitySplitSolver(XMLObject): """ for delivery_line in self.getDeliveryValueList(): decision_quantity = delivery_line.getQuantity() - simulation_movement_list = self.getDeliveryRelatedValueList( - portal_type='Simulation Movement') + simulation_movement_list = self.getDeliveryRelatedValueList() delivery_solver = self.portal_solvers.newDeliverySolver(self.getDeliverySolver(), simulation_movement_list) # Update the quantity using delivery solver algorithm split_list = delivery_solver.setTotalQuantity(decision_quantity) diff --git a/product/ERP5/Document/SolverDecision.py b/product/ERP5/Document/SolverDecision.py index 92a8847503d5d9582aca553bbe375e9e40d4901a..88a22e13d9f086747be7425baaa57a421d60cdc4 100644 --- a/product/ERP5/Document/SolverDecision.py +++ b/product/ERP5/Document/SolverDecision.py @@ -64,9 +64,7 @@ class SolverDecision(XMLObject): meta_type = 'ERP5 Solver Decision' portal_type = 'Solver Decision' add_permission = Permissions.AddPortalContent - # XXX we need to index Solver Decision so as to find the related Solver - # Decision document from a Target Solver document. - # isIndexable = 0 # We do not want to fill the catalog with objects on which we need no reporting + isIndexable = 0 # We do not want to fill the catalog with objects on which we need no reporting # Declarative security security = ClassSecurityInfo()