Author: reinhard Date: 2008-04-29 05:22:10 -0500 (Tue, 29 Apr 2008) New Revision: 9872
Modified: trunk/gnue-forms/src/GFObjects/GFBlock.py Log: Fixed get_record_status() while in init mode (ON-NEWRECORD and ON-RECORDLOADED triggers). Modified: trunk/gnue-forms/src/GFObjects/GFBlock.py =================================================================== --- trunk/gnue-forms/src/GFObjects/GFBlock.py 2008-04-28 11:20:12 UTC (rev 9871) +++ trunk/gnue-forms/src/GFObjects/GFBlock.py 2008-04-29 10:22:10 UTC (rev 9872) @@ -856,16 +856,20 @@ if self.mode == 'query': return None - if self.__resultset is None: - return None + elif self.mode == 'init': + rec = self.__initializing_record - record_number = self.__resultset.getRecordNumber() + offset - if record_number < 0 or \ - record_number >= self.__resultset.getRecordCount(): - return None else: - rec = self.__resultset[record_number] + if self.__resultset is None: + return None + record_number = self.__resultset.getRecordNumber() + offset + if record_number < 0 or \ + record_number >= self.__resultset.getRecordCount(): + return None + else: + rec = self.__resultset[record_number] + # try functions that do not depend on detail records first, because # they are faster if rec.isVoid(): _______________________________________________ commit-gnue mailing list commit-gnue@gnu.org http://lists.gnu.org/mailman/listinfo/commit-gnue