def loadRecord(self, cursor = None): #if self.formrecord_widget is None: if Project.debugLevel > 50: print("Loading record action %s . . . " % (self.name)) parent_or_cursor = cursor # Sin padre, ya que es ventana propia self.formrecord_widget = FLFormRecordDB(parent_or_cursor,self, load = True) self.formrecord_widget.setWindowModality(Qt.ApplicationModal) #self._record_loaded = True if self.mainform_widget: if Project.debugLevel > 50: print("End of record action load %s (iface:%s ; widget:%s)" % (self.name, repr(self.mainform_widget.iface), repr(self.mainform_widget.widget) ) ) return self.formrecord_widget
def loadRecord(self, cursor=None): # if self.formrecord_widget is None: if not getattr(self, "formrecord", None): self.logger.warn("Record action %s is not defined. Canceled !", self.name) return None self.logger.debug("Loading record action %s . . . ", self.name) self.formrecord_widget = FLFormRecordDB(cursor, self, load=True) self.formrecord_widget.setWindowModality(Qt.ApplicationModal) self._record_loaded = True if self.mainform_widget: self.logger.debug( "End of record action load %s (iface:%s ; widget:%s)", self.name, self.mainform_widget.iface, self.mainform_widget.widget) self.initModule(self.name) return self.formrecord_widget