mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
Show trip date (with number of dives) in dive/trip list
That was easy :-) Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
6b7797140b
commit
e6ec626c97
1 changed files with 9 additions and 7 deletions
|
@ -404,13 +404,15 @@ QVariant TripItem::data(int column, int role) const
|
||||||
{
|
{
|
||||||
QVariant ret;
|
QVariant ret;
|
||||||
|
|
||||||
if (column != LOCATION) {
|
if (role == Qt::DisplayRole) {
|
||||||
return ret;
|
switch (column) {
|
||||||
}
|
case LOCATION:
|
||||||
|
ret = QString(trip->location);
|
||||||
switch (role) {
|
break;
|
||||||
case Qt::DisplayRole:
|
case DATE:
|
||||||
ret = QString(trip->location);
|
ret = QString(get_trip_date_string(trip->when, trip->nrdives));
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
Loading…
Reference in a new issue