Ignore:
Timestamp:
1 Dec 2014, 09:59:14 (10 years ago)
Author:
Henrik Bettermann
Message:

Add sample contract interfaces with additional document field. Use these interfaces in form pages.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.ikoba/trunk/src/waeup/ikoba/customers/browser.py

    r12099 r12103  
    5151    ICustomer, ICustomersContainer, ICustomerRequestPW, ICustomersUtils,
    5252    ICustomerDocument, ICustomerDocumentsContainer, ICustomerCreate,
    53     ICustomerPDFDocument, IContractsContainer, IContract, IContractEdit
     53    ICustomerPDFDocument, IContractsContainer, IContract, IContractEdit,
     54    ISampleContract,
    5455    )
    5556from waeup.ikoba.customers.catalog import search
     
    11501151    grok.require('waeup.viewCustomer')
    11511152    grok.template('contractpage')
    1152     form_fields = grok.AutoFields(IContract).omit('last_transition_date')
    1153     pnav = 4
     1153    pnav = 4
     1154
     1155    @property
     1156    def form_fields(self):
     1157        return grok.AutoFields(self.context.form_fields_interface).omit(
     1158            'last_transition_date')
    11541159
    11551160    @property
     
    11651170    grok.require('waeup.manageCustomer')
    11661171    grok.template('contracteditpage')
    1167     form_fields = grok.AutoFields(IContract).omit('last_transition_date')
    11681172    pnav = 4
    11691173    deletion_warning = _('Are you sure?')
     1174
     1175    @property
     1176    def form_fields(self):
     1177        return grok.AutoFields(self.context.form_fields_interface).omit(
     1178            'last_transition_date')
    11701179
    11711180    @property
     
    11841193    grok.name('edit')
    11851194    grok.require('waeup.handleCustomer')
    1186     form_fields = grok.AutoFields(IContractEdit).omit('last_transition_date')
     1195
     1196    @property
     1197    def form_fields(self):
     1198        return grok.AutoFields(self.context.edit_form_fields_interface).omit(
     1199            'last_transition_date')
    11871200
    11881201    def update(self):
Note: See TracChangeset for help on using the changeset viewer.