Changes between Version 19 and Version 20 of S3/S3Model


Ignore:
Timestamp:
01/24/14 08:38:54 (11 years ago)
Author:
Dominic König
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • S3/S3Model

    v19 v20  
    221221- {{{configure}}} to define table configuration settings
    222222
    223 These functions should not be overwritten in the subclass.
    224 
     223These functions should not be overwritten in the subclass. To avoid collisions, names of additional functions (besides model() and defaults()) in S3Model subclasses should always start with the module prefix:
     224
     225{{{#!python
     226class MyModel(S3Model):
     227
     228   def model(self):
     229       ...
     230
     231   def defaults(self):
     232
     233   # Use the module prefix in function names to avoid overriding of superclass functions:
     234   def my_additional_function(self, param1, param2):
     235       ...
     236}}}
    225237== current.s3db ==
    226238