connected date-edits to updates
This commit is contained in:
parent
00a4d37ec3
commit
b69a748f94
3 changed files with 15 additions and 2 deletions
|
@ -17,7 +17,7 @@ DataModel::DataModel(QObject *parent)
|
||||||
{
|
{
|
||||||
connect(&m_plural, &PluralModel::dataChanged, this,
|
connect(&m_plural, &PluralModel::dataChanged, this,
|
||||||
&DataModel::pluralModelChanged);
|
&DataModel::pluralModelChanged);
|
||||||
connect(&m_metaData, &PluralModel::dataChanged, this,
|
connect(&m_metaData, &MetaDataModel::dataChanged, this,
|
||||||
&DataModel::metaDataChanged);
|
&DataModel::metaDataChanged);
|
||||||
connect(&m_genus, &GenusModel::dataChanged, this,
|
connect(&m_genus, &GenusModel::dataChanged, this,
|
||||||
&DataModel::genusModelChanged);
|
&DataModel::genusModelChanged);
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
#include "MetaDataModel.h"
|
#include "MetaDataModel.h"
|
||||||
|
|
||||||
#include <QDataWidgetMapper>
|
#include <QDataWidgetMapper>
|
||||||
|
#include <QDebug>
|
||||||
|
|
||||||
MetaDataWidget::MetaDataWidget(QWidget *parent)
|
MetaDataWidget::MetaDataWidget(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
@ -11,6 +12,11 @@ MetaDataWidget::MetaDataWidget(QWidget *parent)
|
||||||
, m_widgetMapper(new QDataWidgetMapper(this))
|
, m_widgetMapper(new QDataWidgetMapper(this))
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
|
||||||
|
connect(ui->dateOfTestDateEdit, &QDateEdit::dateChanged, m_widgetMapper,
|
||||||
|
&QDataWidgetMapper::submit);
|
||||||
|
connect(ui->dateOfBirthDateEdit, &QDateEdit::dateChanged, m_widgetMapper,
|
||||||
|
&QDataWidgetMapper::submit);
|
||||||
}
|
}
|
||||||
|
|
||||||
MetaDataWidget::~MetaDataWidget()
|
MetaDataWidget::~MetaDataWidget()
|
||||||
|
|
|
@ -61,7 +61,14 @@
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QDateEdit" name="dateOfTestDateEdit"/>
|
<widget class="QDateEdit" name="dateOfTestDateEdit">
|
||||||
|
<property name="displayFormat">
|
||||||
|
<string>M/d/yyyy</string>
|
||||||
|
</property>
|
||||||
|
<property name="calendarPopup">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer">
|
<spacer name="horizontalSpacer">
|
||||||
|
|
Loading…
Reference in a new issue