0
0
mirror of https://github.com/fralx/LimeReport.git synced 2025-11-20 06:30:03 +03:00

Using variables in the connection describer has been extended

This commit is contained in:
Arin Alexander
2020-05-08 14:19:02 +03:00
parent 36b60319ce
commit ccf8134012
10 changed files with 77 additions and 23 deletions

View File

@@ -336,13 +336,13 @@ void ModelToDataSource::slotModelDestroed()
ConnectionDesc::ConnectionDesc(QSqlDatabase db, QObject *parent)
: QObject(parent), m_connectionName(db.connectionName()), m_connectionHost(db.hostName()), m_connectionDriver(db.driverName()),
m_databaseName(db.databaseName()), m_user(db.userName()), m_password(db.password()), m_port(-1), m_autoconnect(false),
m_databaseName(db.databaseName()), m_user(db.userName()), m_password(db.password()), m_port(""), m_autoconnect(false),
m_internal(false), m_keepDBCredentials(true)
{}
ConnectionDesc::ConnectionDesc(QObject *parent)
:QObject(parent),m_connectionName(""),m_connectionHost(""), m_connectionDriver(""),
m_databaseName(""), m_user(""), m_password(""), m_port(-1), m_autoconnect(false),
m_databaseName(""), m_user(""), m_password(""), m_port(""), m_autoconnect(false),
m_internal(false), m_keepDBCredentials(true)
{}
@@ -377,12 +377,12 @@ QString ConnectionDesc::connectionNameForReport(const QString &connectionName)
return connectionName.compare(tr("defaultConnection")) == 0 ? QSqlDatabase::defaultConnection : connectionName;
}
int ConnectionDesc::port() const
QString ConnectionDesc::port() const
{
return m_port;
}
void ConnectionDesc::setPort(int port)
void ConnectionDesc::setPort(QString port)
{
m_port = port;
}