code: def setModelData(self, editor, model, index):
          
          model.setData(index, editor.itemText(editor.currentIndex()))
docs: Updates the model after changing data in the editor.
  
          Args:
              editor (QtGui.QComboBox): The current editor for the item. Should be
                  a `QtGui.QComboBox` as defined in `createEditor`.
              model (ColumnDtypeModel): The model which holds the displayed data.
              index (QtCore.QModelIndex): The index of the current item of the model.