Changeset 12780
- Timestamp:
- 17 Mar 2015, 18:42:35 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.ikoba/trunk/src/waeup/ikoba/payments/container.py
r12775 r12780 20 20 """ 21 21 import grok 22 from zope.schema import getFields 22 23 from waeup.ikoba.interfaces import IIkobaPluggable 23 from waeup.ikoba.payments.interfaces import IPaymentsContainer 24 from waeup.ikoba.payments.interfaces import IPaymentsContainer, IPayment 24 25 from waeup.ikoba.utils.helpers import attrs_to_fields 25 26 from waeup.ikoba.utils.logger import Logger … … 50 51 51 52 class PaymentsPlugin(grok.GlobalUtility): 52 """A plugin that creates container for payments inside a company. 53 """A plugin that creates container for payments inside a company 54 and updates payment objects. 53 55 """ 54 56 grok.implements(IIkobaPluggable) … … 66 68 if not 'payments' in site.keys(): 67 69 self.setup(site, name, logger) 70 for payment in site['payments'].values(): 71 # Add payment_items 72 if not hasattr(payment,'payment_items'): 73 payment.payment_items = () 74 logger.info( 75 'PaymentsPlugin: %s attribute %s added.' % ( 76 payment.payment_id,'payment_items')) 77 return
Note: See TracChangeset for help on using the changeset viewer.