Fixed bug on empty database.

This commit is contained in:
2017-05-21 16:43:12 +02:00
parent 6a042c46a1
commit d53fed72d8
2 changed files with 15 additions and 0 deletions
+13
View File
@@ -43,6 +43,11 @@ AddressbookDataPtr AddressHelper::newAddress()
AddressbookDataPtr AddressHelper::copyAddress()
{
if (m_copyAddress.isNull())
{
m_copyAddress = AddressbookDataPtr(new AddressbookData);
}
return m_copyAddress;
}
@@ -94,6 +99,9 @@ CampWizard::CampWizard(QWidget *parent) :
Service<CountryData> coutrySrv;
m_addressBinder->registerBinding(ui->country, ComboData::createComboData(coutrySrv.all()));
m_addressBinder->setData(m_addrHelper->copyAddress().data());
m_addressBinder->bindToUi();
m_bindAddrCombo = true;
}
@@ -181,3 +189,8 @@ void CampWizard::on_groupNew_clicked(bool checked)
ui->address->setEnabled(true);
}
}
void CampWizard::on_CampWizard_currentIdChanged(int id)
{
}
+2
View File
@@ -54,6 +54,8 @@ private slots:
void on_groupNew_clicked(bool checked);
void on_CampWizard_currentIdChanged(int id);
private:
Ui::CampWizard *ui;
CampDataPtr m_data;