mirror of
https://gitea.psi.ch/ELOG/elog.git
synced 2026-09-08 17:13:56 +00:00
Fixed wrong date display in threaded mode
SVN revision: 1734
This commit is contained in:
parent
b70059cda2
commit
75bbb64d9b
42
src/elogd.c
42
src/elogd.c
@ -15155,6 +15155,48 @@ void display_line(LOGBOOK * lbs, int message_id, int number, char *mode,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
else if (attr_flags[i] & AF_DATE) {
|
||||||
|
if (skip_comma) {
|
||||||
|
rsprintf(" ");
|
||||||
|
skip_comma = FALSE;
|
||||||
|
} else
|
||||||
|
rsprintf(", ");
|
||||||
|
|
||||||
|
if (!getcfg(lbs->name, "Date format", format, sizeof(format)))
|
||||||
|
strcpy(format, DEFAULT_DATE_FORMAT);
|
||||||
|
|
||||||
|
ltime = atoi(attrib[i]);
|
||||||
|
pts = localtime(<ime);
|
||||||
|
assert(pts);
|
||||||
|
if (ltime == 0)
|
||||||
|
strcpy(str, "-");
|
||||||
|
else
|
||||||
|
my_strftime(str, sizeof(str), format, pts);
|
||||||
|
|
||||||
|
rsputs(str);
|
||||||
|
}
|
||||||
|
|
||||||
|
else if (attr_flags[i] & AF_DATETIME) {
|
||||||
|
if (skip_comma) {
|
||||||
|
rsprintf(" ");
|
||||||
|
skip_comma = FALSE;
|
||||||
|
} else
|
||||||
|
rsprintf(", ");
|
||||||
|
|
||||||
|
if (!getcfg(lbs->name, "Time format", format, sizeof(format)))
|
||||||
|
strcpy(format, DEFAULT_TIME_FORMAT);
|
||||||
|
|
||||||
|
ltime = atoi(attrib[i]);
|
||||||
|
pts = localtime(<ime);
|
||||||
|
assert(pts);
|
||||||
|
if (ltime == 0)
|
||||||
|
strcpy(str, "-");
|
||||||
|
else
|
||||||
|
my_strftime(str, sizeof(str), format, pts);
|
||||||
|
|
||||||
|
rsputs(str);
|
||||||
|
}
|
||||||
|
|
||||||
else if (attr_flags[i] & AF_ICON) {
|
else if (attr_flags[i] & AF_ICON) {
|
||||||
if (attrib[i][0])
|
if (attrib[i][0])
|
||||||
rsprintf(" \n<img border=0 src=\"icons/%s\" alt=\"%s\" title=\"%s\"> ",
|
rsprintf(" \n<img border=0 src=\"icons/%s\" alt=\"%s\" title=\"%s\"> ",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user