[Erp5-report] r15896 - in /erp5/trunk/bt5/erp5_banking_cash: PortalTypePropertySheetTemplat...

nobody at svn.erp5.org nobody at svn.erp5.org
Wed Aug 29 11:53:37 CEST 2007


Author: aurel
Date: Wed Aug 29 11:53:37 2007
New Revision: 15896

URL: http://svn.erp5.org?rev=15896&view=rev
Log:
add missing property sheet for mutilated banknote
fix check in wf transition for mutilated banknote

Added:
    erp5/trunk/bt5/erp5_banking_cash/PropertySheetTemplateItem/MutilatedBanknote.py
Modified:
    erp5/trunk/bt5/erp5_banking_cash/PortalTypePropertySheetTemplateItem/property_sheet_list.xml
    erp5/trunk/bt5/erp5_banking_cash/WorkflowTemplateItem/portal_workflow/mutilated_banknote_workflow/scripts/CheckTransitionStop.xml
    erp5/trunk/bt5/erp5_banking_cash/bt/revision
    erp5/trunk/bt5/erp5_banking_cash/bt/template_portal_type_property_sheet_list
    erp5/trunk/bt5/erp5_banking_cash/bt/template_property_sheet_id_list

Modified: erp5/trunk/bt5/erp5_banking_cash/PortalTypePropertySheetTemplateItem/property_sheet_list.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_banking_cash/PortalTypePropertySheetTemplateItem/property_sheet_list.xml?rev=15896&r1=15895&r2=15896&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_banking_cash/PortalTypePropertySheetTemplateItem/property_sheet_list.xml (original)
+++ erp5/trunk/bt5/erp5_banking_cash/PortalTypePropertySheetTemplateItem/property_sheet_list.xml Wed Aug 29 11:53:37 2007
@@ -126,6 +126,7 @@
   <item>Amount</item>
  </portal_type>
  <portal_type id="Mutilated Banknote">
+  <item>Mutilated Banknote</item>
   <item>Amount</item>
   <item>Price</item>
  </portal_type>

Added: erp5/trunk/bt5/erp5_banking_cash/PropertySheetTemplateItem/MutilatedBanknote.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_banking_cash/PropertySheetTemplateItem/MutilatedBanknote.py?rev=15896&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_banking_cash/PropertySheetTemplateItem/MutilatedBanknote.py (added)
+++ erp5/trunk/bt5/erp5_banking_cash/PropertySheetTemplateItem/MutilatedBanknote.py Wed Aug 29 11:53:37 2007
@@ -1,0 +1,40 @@
+##############################################################################
+#
+# Copyright (c) 2002-2007 Nexedi SARL and Contributors. All Rights Reserved.
+#
+# WARNING: This program as such is intended to be used by professional
+# programmers who take the whole responsability of assessing all potential
+# consequences resulting from its eventual inadequacies and bugs
+# End users who are looking for a ready-to-use solution with commercial
+# garantees and support are strongly adviced to contract a Free Software
+# Service Company
+#
+# This program is Free Software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+#
+##############################################################################
+
+class MutilatedBanknote:
+    """
+        PropertySheetTemplate properties for all ERP5 objects
+    """
+
+    _properties = (
+        {   'id'          : 'deponent',
+            'description' : 'The person who said that there is a mutilated banknote',
+            'type'        : 'string',
+            'mode'        : 'w' },
+    )
+  
+

Modified: erp5/trunk/bt5/erp5_banking_cash/WorkflowTemplateItem/portal_workflow/mutilated_banknote_workflow/scripts/CheckTransitionStop.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_banking_cash/WorkflowTemplateItem/portal_workflow/mutilated_banknote_workflow/scripts/CheckTransitionStop.xml?rev=15896&r1=15895&r2=15896&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_banking_cash/WorkflowTemplateItem/portal_workflow/mutilated_banknote_workflow/scripts/CheckTransitionStop.xml (original)
+++ erp5/trunk/bt5/erp5_banking_cash/WorkflowTemplateItem/portal_workflow/mutilated_banknote_workflow/scripts/CheckTransitionStop.xml Wed Aug 29 11:53:37 2007
@@ -85,8 +85,13 @@
   raise ValidationFailed, (msg,)\n
 \n
 # check reporter defined\n
-if ob.getSourceDecision() == 0:\n
+if ob.getDeponent() in (None, ""):\n
   msg = Message(domain = "ui", message="You must define a reporter.")\n
+  raise ValidationFailed, (msg,)\n
+\n
+# check original site defined is hq\n
+if "siege" in ob.getSource() and ob.getSourceTrade() is None:\n
+  msg = Message(domain = "ui", message="You must define the original site.")\n
   raise ValidationFailed, (msg,)\n
 </string> </value>
         </item>
@@ -140,6 +145,7 @@
                             <string>_getattr_</string>
                             <string>len</string>
                             <string>msg</string>
+                            <string>None</string>
                           </tuple>
                         </value>
                     </item>

Modified: erp5/trunk/bt5/erp5_banking_cash/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_banking_cash/bt/revision?rev=15896&r1=15895&r2=15896&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_banking_cash/bt/revision (original)
+++ erp5/trunk/bt5/erp5_banking_cash/bt/revision Wed Aug 29 11:53:37 2007
@@ -1,1 +1,1 @@
-487
+490

Modified: erp5/trunk/bt5/erp5_banking_cash/bt/template_portal_type_property_sheet_list
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_banking_cash/bt/template_portal_type_property_sheet_list?rev=15896&r1=15895&r2=15896&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_banking_cash/bt/template_portal_type_property_sheet_list (original)
+++ erp5/trunk/bt5/erp5_banking_cash/bt/template_portal_type_property_sheet_list Wed Aug 29 11:53:37 2007
@@ -63,6 +63,7 @@
 Money Deposit | Price
 Money Deposit | Task
 Mutilated Banknote | Amount
+Mutilated Banknote | Mutilated Banknote
 Mutilated Banknote | Price
 Outgoing Cash Balance Regulation Line | CashDeliveryLine
 Outgoing Cash Exchange Line | CashDeliveryLine

Modified: erp5/trunk/bt5/erp5_banking_cash/bt/template_property_sheet_id_list
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_banking_cash/bt/template_property_sheet_id_list?rev=15896&r1=15895&r2=15896&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_banking_cash/bt/template_property_sheet_id_list (original)
+++ erp5/trunk/bt5/erp5_banking_cash/bt/template_property_sheet_id_list Wed Aug 29 11:53:37 2007
@@ -1,2 +1,3 @@
 MonetaryDestruction
-CashMovement
+CashMovement
+MutilatedBanknote




More information about the Erp5-report mailing list