Changes between Version 5 and Version 6 of RemovingTheMagic


Ignore:
Timestamp:
12/06/2005 11:30:30 PM (9 years ago)
Author:
adrian
Comment:

Fixed spacing issues.

Legend:

Unmodified
Added
Removed
Modified
  • RemovingTheMagic

    v5 v6  
    2626    last_name = models.CharField(maxlength=30)
    2727
    28 def _get_full_name(self):
    29     return "%s %s" % (self.first_name, self.last_name)
    30 full_name = property(_get_full_name)
     28    def _get_full_name(self):
     29        return "%s %s" % (self.first_name, self.last_name)
     30    full_name = property(_get_full_name)
    3131}}}
    3232
     
    103103    last_name = models.CharField(maxlength=30)
    104104
    105 def save(self):
    106     self.do_something()
    107     super(Person, self).save(self) # Call the "real" save() method.
    108     self.do_something_else()
     105    def save(self):
     106        self.do_something()
     107        super(Person, self).save(self) # Call the "real" save() method.
     108        self.do_something_else()
    109109}}}
    110110
     
    117117    last_name = models.CharField(maxlength=30)
    118118
    119 def save(self):
    120     if datetime.date.today() > datetime.date(2005, 1, 1):
    121         super(Person, self).save(self) # Call the "real" save() method.
    122     else:
    123         # Don't save.
    124         pass
     119    def save(self):
     120        if datetime.date.today() > datetime.date(2005, 1, 1):
     121            super(Person, self).save(self) # Call the "real" save() method.
     122        else:
     123            # Don't save.
     124            pass
    125125}}}
    126126
Back to Top