我想显示数据库中的表并显示它,但也想根据函数修改特定列
QSqlTableModel *model = new QSqlTableModel(parentObject, database);
model->setTable("employee");
model->setEditStrategy(QSqlTableModel::OnManualSubmit);
model->select();
model->setHeaderData(0, Qt::Horizontal, tr("Name"));
model->setHeaderData(1, Qt::Horizontal, tr("Salary"));
model->setHeaderData(2, Qt::Horizontal, tr("encrypted_item"));
QTableView *view = new QTableView;
view->setModel(model);
view->hideColumn(0); // don't show the ID
view->show();
但是现在我不想打印加密的项目,而是想解密并显示它,我该怎么做?