[Erp5-report] r41787 arnaud.fontaine - in /erp5/trunk: bt5/erp5_registry_ohada/PropertyShee...

nobody at svn.erp5.org nobody at svn.erp5.org
Mon Dec 27 10:09:13 CET 2010


Author: arnaud.fontaine
Date: Mon Dec 27 10:09:12 2010
New Revision: 41787

URL: http://svn.erp5.org?rev=41787&view=rev
Log:
Remove useless message_property_not_set because calling getProperty()
will never be called after hasProperty()

Modified:
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M0Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M2Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M4Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P0Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P2Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P4Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S1Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S5Constraint.py
    erp5/trunk/bt5/erp5_registry_ohada/bt/revision
    erp5/trunk/bt5/erp5_trade/PropertySheetTemplateItem/InventoryConstraint.py
    erp5/trunk/bt5/erp5_trade/bt/revision
    erp5/trunk/bt5/vifib_base/PropertySheetTemplateItem/SoftwareInstanceConstraint.py
    erp5/trunk/bt5/vifib_base/bt/revision
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/AccountingTransactionConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/BugConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/CalendarPeriodConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/ProductionOrder.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskLineConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeConditionConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeModelLineConstraint.py
    erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeOrder.py
    erp5/trunk/products/ERP5Type/Constraint/PropertyExistence.py

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M0Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M0Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M0Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M0Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,14 +36,12 @@ class M0Constraint:
       'type'          : 'PropertyExistence',
       'title'         : None, 
       'message_no_such_property': 'The naming must be defined',
-      'message_property_not_set': 'The naming must be defined',
     },
     { 'id'            : 'name_existence',
       'description'   : 'Property name must be definied',
       'type'          : 'PropertyExistence',
       'name'          : None, 
       'message_no_such_property': 'The commercial name must be defined',
-      'message_property_not_set': 'The commercial name must be defined',
     },
     { 'id'            : 'head_office_address_existence',
       'description'   : 'Property address must be definied',

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M2Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M2Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M2Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M2Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -41,7 +41,6 @@ class M2Constraint:
 #      'type'          : 'PropertyExistence',
 #      'corporate_registration_code'          : None, 
 #      'message_no_such_property': 'The corporate registration must be defined',
-#      'message_property_not_set': 'The corporate registration must be defined',
 #    },
 #    { 'id'            : 'old_headquarters_existence',
 #      'description'   : 'Property old_headquarters must be definied',

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M4Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M4Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M4Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/M4Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,7 +36,6 @@ class M4Constraint:
       'type'          : 'PropertyExistence',
       'title'         : None, 
       'message_no_such_property': 'The naming must be defined',
-      'message_property_not_set': 'The naming must be defined',
     },
     { 'id'            : 'corporate_registration_code_existence',
       'description'   : 'Property corporate registration code must be definied',

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P0Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P0Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P0Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P0Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,14 +36,12 @@ class P0Constraint:
       'type'          : 'PropertyExistence',
       'last_name'         : None, 
       'message_no_such_property': 'The last name must be defined',
-      'message_property_not_set': 'The last name must be defined',
     },
     { 'id'            : 'first_name_existence',
       'description'   : 'Property first name  code must be definied',
       'type'    : 'PropertyExistence',
       'first_name'          : None, 
       'message_no_such_property': 'The first name address must be defined',
-      'message_property_not_set': 'The first name address must be defined',
     },
     { 'id'            : 'date_exitence',
       'description'   : 'Property date must be definied',
@@ -166,6 +164,5 @@ class P0Constraint:
       'previous_activity_corporate_registration_code'     : None,
       'condition'     : 'python: object.getActivityRestartCheck() ==1',
       'message_no_such_property': 'for a restart activity you must define the previous registration code',
-      'message_property_not_set': 'for a restart activity you must define the previous registration code',
     },
   )

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P2Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P2Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P2Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P2Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,14 +36,12 @@ class P2Constraint:
       'type'          : 'PropertyExistence',
       'owner_last_name'         : None, 
       'message_no_such_property': 'The owner last name must be defined',
-      'message_property_not_set': 'The owner last name must be defined',
     },
     { 'id'            : 'owner_first_name_existence',
       'description'   : 'Property owner first name  code must be definied',
       'type'    : 'PropertyExistence',
       'owner_first_name'          : None, 
       'message_no_such_property': 'The owner first name address must be defined',
-      'message_property_not_set': 'The owner first name address must be defined',
     },
     { 'id'            : 'date_existence',
       'description'   : 'Property date must be definied',
@@ -80,7 +78,6 @@ class P2Constraint:
       'company_corporate_registration_code'     : None,
       'condition'     : 'python: object.getCompanyModifications() != None',
       'message_no_such_property': 'for an orgnisation modification you must define the company registration code',
-      'message_property_not_set': 'for an orgnisation modification you must define the company registration code',
     },
     { 'id'            : 'establishment_corporate_registration_code_existence',
       'description'   : 'Property must be definied',
@@ -88,6 +85,5 @@ class P2Constraint:
       'establishment_corporate_registration_code'     : None,
       'condition'     : 'python: object.getEstablishmentModification() != None',
       'message_no_such_property': 'for an establishment modification you must define the establishment registration code',
-      'message_property_not_set': 'for an establishment modification you must define the establishment registration code',
     },
   )

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P4Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P4Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P4Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/P4Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,14 +36,12 @@ class P4Constraint:
       'type'          : 'PropertyExistence',
       'owner_last_name'         : None, 
       'message_no_such_property': 'The owner last name must be defined',
-      'message_property_not_set': 'The owner last name must be defined',
     },
     { 'id'            : 'owner_first_name_existence',
       'description'   : 'Property owner first name  code must be definied',
       'type'    : 'PropertyExistence',
       'owner_first_name'          : None, 
       'message_no_such_property': 'The owner first name address must be defined',
-      'message_property_not_set': 'The owner first name address must be defined',
     },
     { 'id'            : 'corporate_registration_code_existence',
       'description'   : 'Property corporate registration code must be definied',

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S1Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S1Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S1Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S1Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,7 +36,6 @@ class S1Constraint:
       'type'          : 'PropertyExistence',
       'title'         : None, 
       'message_no_such_property': 'The denomination must be defined',
-      'message_property_not_set': 'The denomination must be defined',
     },
     { 'id'            : 'hypothecation_person_title_existence',
       'description'   : 'Property hypothecation person title must be definied',

Modified: erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S5Constraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S5Constraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S5Constraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/PropertySheetTemplateItem/S5Constraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -36,7 +36,6 @@ class S5Constraint:
       'type'          : 'PropertyExistence',
       'title'         : None, 
       'message_no_such_property': 'The denomination must be defined',
-      'message_property_not_set': 'The denomination must be defined',
     },
     { 'id'            : 'inscription_person_title_existence',
       'description'   : 'Property inscription person title must be definied',

Modified: erp5/trunk/bt5/erp5_registry_ohada/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_registry_ohada/bt/revision?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_registry_ohada/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/erp5_registry_ohada/bt/revision [utf8] Mon Dec 27 10:09:12 2010
@@ -1 +1 @@
-934
\ No newline at end of file
+935
\ No newline at end of file

Modified: erp5/trunk/bt5/erp5_trade/PropertySheetTemplateItem/InventoryConstraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_trade/PropertySheetTemplateItem/InventoryConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_trade/PropertySheetTemplateItem/InventoryConstraint.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_trade/PropertySheetTemplateItem/InventoryConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -54,7 +54,6 @@ class InventoryConstraint:
       'description'   : 'Start Date must be defined',
       'type'          : 'PropertyExistence',
       'start_date'    : 1,
-      'message_property_not_set': 'Inventory Date must be defined',
       'message_no_such_property': 'Inventory Date must be defined',
     },
     { 'id'            : 'resource_on_line',

Modified: erp5/trunk/bt5/erp5_trade/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_trade/bt/revision?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_trade/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/erp5_trade/bt/revision [utf8] Mon Dec 27 10:09:12 2010
@@ -1 +1 @@
-1096
\ No newline at end of file
+1097
\ No newline at end of file

Modified: erp5/trunk/bt5/vifib_base/PropertySheetTemplateItem/SoftwareInstanceConstraint.py
URL: http://svn.erp5.org/erp5/trunk/bt5/vifib_base/PropertySheetTemplateItem/SoftwareInstanceConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/vifib_base/PropertySheetTemplateItem/SoftwareInstanceConstraint.py [utf8] (original)
+++ erp5/trunk/bt5/vifib_base/PropertySheetTemplateItem/SoftwareInstanceConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -33,14 +33,12 @@ class SoftwareInstanceConstraint:
       'description'   : 'Property text content must be defined',
       'type'          : 'PropertyExistence',
       'text_content'  : None,
-      "message_property_not_set" : 'XML must be set',
       "message_no_such_property" : 'XML must be set'
     },
     { 'id'            : 'property_existence',
       'description'   : 'Property reference must be defined',
       'type'          : 'PropertyExistence',
       'reference'     : None,
-      "message_property_not_set" : 'Reference must be set',
       "message_no_such_property" : 'Reference must be set'
     },
     { 'id'            : 'text_content_validation',

Modified: erp5/trunk/bt5/vifib_base/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/vifib_base/bt/revision?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/bt5/vifib_base/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/vifib_base/bt/revision [utf8] Mon Dec 27 10:09:12 2010
@@ -1 +1 @@
-177
\ No newline at end of file
+178
\ No newline at end of file

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/AccountingTransactionConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/AccountingTransactionConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/AccountingTransactionConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/AccountingTransactionConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -45,7 +45,6 @@ class AccountingTransactionConstraint:
 
     { 'id': 'date_existence',
       'description': 'Date must be defined',
-      'message_property_not_set': 'Date must be defined',
       'message_no_such_property': 'Date must be defined',
       'condition' : 'python: object.getSimulationState() not'
                      ' in ("cancelled", "deleted")'
@@ -56,7 +55,6 @@ class AccountingTransactionConstraint:
 
     { 'id': 'date_existence_purchase',
       'description': 'Date must be defined',
-      'message_property_not_set': 'Date must be defined',
       'message_no_such_property': 'Date must be defined',
       'condition' : 'python: object.getSimulationState() not'
                      ' in ("cancelled", "deleted")'

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/BugConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/BugConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/BugConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/BugConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -37,7 +37,6 @@ class BugConstraint:
       'description'   : 'Title must be defined',
       'type'          : 'PropertyExistence',
       'title'         :  None,
-      'message_property_not_set': 'Title must be defined',
       'message_no_such_property' : 'Title must be defined',
     },
     { 'id'            : 'tested_existence',
@@ -45,7 +44,6 @@ class BugConstraint:
       'type'          : 'PropertyExistence',
       'tested'        :  0,
       'condition'     : "python: object.getSimulationState() in ['ready','stopped']" ,
-      'message_property_not_set': 'Tested is unchecked, Must have a Unit/Funcional test for this',
       'message_no_such_property' : 'Tested is unchecked, Must have a Unit/Funcional test for this',
     },
     { 'id'            : 'source_project_category_membership_arity',
@@ -61,7 +59,6 @@ class BugConstraint:
       'description'   : 'Property start_date must be defined',
       'type'          : 'PropertyExistence',
       'start_date'    : None,
-      'message_property_not_set': 'Begin Date must be defined',
       'message_no_such_property' : 'Begin Date must be defined' 
     },
     { 'id'            : 'date_coherency',

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/CalendarPeriodConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/CalendarPeriodConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/CalendarPeriodConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/CalendarPeriodConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -35,7 +35,6 @@ class CalendarPeriodConstraint:
 
     { 'id': 'start_date_existence',
       'description': 'Date must be defined',
-      'message_property_not_set': 'Start date must be defined',
       'message_no_such_property': 'Start date must be defined',
       'type': 'PropertyExistence',
       'start_date' : 1,
@@ -43,7 +42,6 @@ class CalendarPeriodConstraint:
 
     { 'id': 'stop_date_existence',
       'description': 'Date must be defined',
-      'message_property_not_set': 'Stop date must be defined',
       'message_no_such_property': 'Stop date must be defined',
       'type': 'PropertyExistence',
       'stop_date' : 1,

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/ProductionOrder.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/ProductionOrder.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/ProductionOrder.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/ProductionOrder.py [utf8] Mon Dec 27 10:09:12 2010
@@ -64,7 +64,6 @@ class ProductionOrder:
       'type'          : 'PropertyExistence',
       'start_date'    : 1,
       'message_no_such_property' : "Shipping Date must be defined",
-      'message_property_not_set' : "Shipping Date must be defined",
     },
     { 'id'            : 'date_coherency',
       'description'   : 'Stop Date must be after Start Date',

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -55,7 +55,6 @@ class TaskConstraint:
       'description'   : 'Property start_date must be defined',
       'type'          : 'PropertyExistence',
       'start_date'    : None,
-      'message_property_not_set': 'Begin Date must be defined',
       'message_no_such_property' : 'Begin Date must be defined' 
     },
     { 'id'            : 'date_coherency',

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskLineConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskLineConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskLineConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TaskLineConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -35,7 +35,6 @@ class TaskLineConstraint:
       'description'   : 'Property quantity must be defined',
       'type'          : 'PropertyExistence',
       'quantity'    : None,
-      "message_property_not_set" : 'Quantity must be defined in lines',
       "message_no_such_property" : 'Quantity must be defined in lines'
     },
     { 'id'            : 'resource',

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeConditionConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeConditionConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeConditionConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeConditionConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -35,7 +35,6 @@ class TradeConditionConstraint:
       'description'   : 'Property reference must be defined',
       'type'          : 'PropertyExistence',
       'reference'    : None,
-      "message_property_not_set" : 'Reference must be defined',
       "message_no_such_property" : 'Reference must be defined'
     },
     { 'id'            : 'date_coherency',
@@ -51,7 +50,6 @@ class TradeConditionConstraint:
       'description'   : 'Version must be defined',
       'type'          : 'PropertyExistence',
       'version'         :  None,
-      'message_property_not_set': 'Version must be defined',
       'message_no_such_property' : 'Version must be defined',
     },
   )

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeModelLineConstraint.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeModelLineConstraint.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeModelLineConstraint.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeModelLineConstraint.py [utf8] Mon Dec 27 10:09:12 2010
@@ -35,7 +35,6 @@ class TradeModelLineConstraint:
       'description'   : 'Property reference must be defined',
       'type'          : 'PropertyExistence',
       'reference'    : None,
-      "message_property_not_set" : 'Reference must be defined in lines',
       "message_no_such_property" : 'Reference must be defined in lines'
     },
     { 'id'            : 'resource',

Modified: erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeOrder.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeOrder.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeOrder.py [utf8] (original)
+++ erp5/trunk/products/ERP5PropertySheetLegacy/PropertySheet/TradeOrder.py [utf8] Mon Dec 27 10:09:12 2010
@@ -86,7 +86,6 @@ class TradeOrder:
       'type'          : 'PropertyExistence',
       'start_date'    : 1,
       'message_no_such_property' : "Shipping Date must be defined",
-      'message_property_not_set' : "Shipping Date must be defined",
     },
     { 'id'            : 'date_coherency',
       'description'   : 'Stop Date must be after Start Date',

Modified: erp5/trunk/products/ERP5Type/Constraint/PropertyExistence.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/Constraint/PropertyExistence.py?rev=41787&r1=41786&r2=41787&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/Constraint/PropertyExistence.py [utf8] (original)
+++ erp5/trunk/products/ERP5Type/Constraint/PropertyExistence.py [utf8] Mon Dec 27 10:09:12 2010
@@ -45,11 +45,13 @@ class PropertyExistence(Constraint):
   """
 
   _message_id_list = ['message_no_such_property',
+                      # Only keeping this message for backward-compatibility
+                      # as it was meaningless to call a getProperty() after
+                      # hasProperty() failed
                       'message_property_not_set']
   message_no_such_property =  "Property existence error for property "\
-            "${property_id}, this document has no such property"
-  message_property_not_set = "Property existence error for property "\
-            "${property_id}, this property is not defined"
+            "${property_id}, this document has no such property or the "\
+            "property has never been set"
 
   def _checkConsistency(self, obj, fixit=0):
     """Check the object's consistency.
@@ -61,10 +63,6 @@ class PropertyExistence(Constraint):
       mapping = dict(property_id=property_id)
       if not obj.hasProperty(property_id):
         error_message_id = "message_no_such_property"
-      elif obj.getProperty(property_id) is None:
-        # If value is '', attribute is considered a defined
-        # XXX is this the default API ?
-        error_message_id = "message_property_not_set"
       else:
         error_message_id = None
 



More information about the Erp5-report mailing list