Adjust to Qt 6.7.2
This commit is contained in:
parent
16d485b1ed
commit
2d950fb026
|
|
@ -1 +1 @@
|
|||
set(QT_REPO_MODULE_VERSION "6.5.1")
|
||||
set(QT_REPO_MODULE_VERSION "6.7.2")
|
||||
|
|
|
|||
|
|
@ -615,7 +615,7 @@ int Database::saveChanges()
|
|||
}
|
||||
|
||||
int rowsAffected = 0;
|
||||
for (const auto &ts: qAsConst(d->tableSets))
|
||||
for (const auto &ts: std::as_const(d->tableSets))
|
||||
rowsAffected += ts->save(this);
|
||||
|
||||
return rowsAffected;
|
||||
|
|
@ -624,7 +624,7 @@ int Database::saveChanges()
|
|||
void Database::cleanUp()
|
||||
{
|
||||
Q_D(Database);
|
||||
for (const auto &ts: qAsConst(d->tableSets))
|
||||
for (const auto &ts: std::as_const(d->tableSets))
|
||||
ts->clearChildren();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -706,7 +706,7 @@ Q_OUTOFLINE_TEMPLATE void Query<T>::toModel(QSqlQueryModel *model)
|
|||
int fieldIndex = 0;
|
||||
|
||||
if (d->fieldPhrase.data.count()) {
|
||||
for (const auto &pd : qAsConst(d->fieldPhrase.data)) {
|
||||
for (const auto &pd : std::as_const(d->fieldPhrase.data)) {
|
||||
QString displayName = dbModel.tableByClassName(QString::fromUtf8(pd->className))
|
||||
->field(QString::fromUtf8(pd->fieldName))
|
||||
->displayName;
|
||||
|
|
|
|||
|
|
@ -170,7 +170,7 @@ void Table::setParentTableSet(AbstractTableSet *parent)
|
|||
AbstractTableSet *Table::childTableSet(const QString &name) const
|
||||
{
|
||||
//Q_D(const Table);
|
||||
for (auto &t: qAsConst(d->childTableSets))
|
||||
for (auto &t: std::as_const(d->childTableSets))
|
||||
if (t->childClassName() == name)
|
||||
return t;
|
||||
return Q_NULLPTR;
|
||||
|
|
@ -185,7 +185,7 @@ int Table::save(Database *db)
|
|||
if(status() == Added && model->isPrimaryKeyAutoIncrement())
|
||||
setProperty(model->primaryKey().toLatin1().data(), q.lastInsertId());
|
||||
|
||||
foreach(AbstractTableSet *ts, d->childTableSets)
|
||||
for (auto &ts: std::as_const(d->childTableSets))
|
||||
ts->save(db);
|
||||
setStatus(FetchedFromDB);
|
||||
|
||||
|
|
|
|||
|
|
@ -610,7 +610,7 @@ QString AbstractSqlGenerator::selectCommand(const QString &tableName,
|
|||
tables << rel->masterTable << rel->slaveTable;
|
||||
|
||||
selectText = QString();
|
||||
for (auto &t: qAsConst(tables)) {
|
||||
for (auto &t: std::as_const(tables)) {
|
||||
if (!selectText.isEmpty())
|
||||
selectText.append(QStringLiteral(", "));
|
||||
selectText.append(recordsPhrase(t));
|
||||
|
|
|
|||
Loading…
Reference in New Issue