mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Allow user to select date format on manual CSV import
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3b3d8949f7
commit
1b74947bf5
5 changed files with 92 additions and 32 deletions
|
|
@ -107,6 +107,7 @@ void DiveLogImportDialog::on_buttonBox_accepted()
|
|||
parse_manual_file(fileNames[i].toUtf8().data(),
|
||||
ui->ManualSeparator->currentIndex(),
|
||||
ui->Units->currentIndex(),
|
||||
ui->DateFormat->currentIndex(),
|
||||
VALUE_IF_CHECKED(DiveNumber),
|
||||
VALUE_IF_CHECKED(Date), VALUE_IF_CHECKED(Time),
|
||||
VALUE_IF_CHECKED(Duration), VALUE_IF_CHECKED(Location),
|
||||
|
|
|
|||
|
|
@ -296,6 +296,53 @@
|
|||
<string>Manual dives</string>
|
||||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout_4">
|
||||
<item row="0" column="1">
|
||||
<widget class="QGroupBox" name="groupBox_5">
|
||||
<property name="title">
|
||||
<string>Field separator</string>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QComboBox" name="ManualSeparator"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QGroupBox" name="groupBox_8">
|
||||
<property name="toolTip">
|
||||
<string>Choose day, month and year order for date format. The field separator can be any of the characters .-/.</string>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Date format</string>
|
||||
</property>
|
||||
<widget class="QComboBox" name="DateFormat">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>40</y>
|
||||
<width>131</width>
|
||||
<height>27</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>dd.mm.yyyy</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>mm/dd/yyyy</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>yyyy-mm-dd</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QGroupBox" name="groupBox_6">
|
||||
<property name="title">
|
||||
|
|
@ -544,31 +591,6 @@
|
|||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QGroupBox" name="groupBox_5">
|
||||
<property name="title">
|
||||
<string>Field separator</string>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QComboBox" name="ManualSeparator"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<spacer name="verticalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue