parameters: (self)
docstring: first check whether everything's fine
docstring_summary: first check whether everything's fine
docstring_tokens: first check whether everything s fine
function: def onOK(self):
          """ first check whether everything's fine """
          fld = self.getField(True)  # don't change the original copy
          if fld.name == "":
              QMessageBox.critical(self, self.tr("DB Manager"), self.tr("Field name must not be empty."))
              return
          if fld.dataType == "":
              QMessageBox.critical(self, self.tr("DB Manager"), self.tr("Field type must not be empty."))
              return
  
          self.accept()
function_tokens: def onOK ( self ) : fld = self . getField ( True ) # don't change the original copy if fld . name == "" : QMessageBox . critical ( self , self . tr ( "DB Manager" ) , self . tr ( "Field name must not be empty." ) ) return if fld . dataType == "" : QMessageBox . critical ( self , self . tr ( "DB Manager" ) , self . tr ( "Field type must not be empty." ) ) return self . accept ( )