Browse Source

ckdb/ckp - add the idname to the web events list

master
kanoi 9 years ago
parent
commit
68fe4fd301
  1. 10
      pool/page_events.php
  2. 2
      src/ckdb.h
  3. 5
      src/ckdb_cmd.c

10
pool/page_events.php

@ -108,7 +108,8 @@ What: <input type=text name=what size=10 value='$wh'>
$pg .= '<td class=dr>#</td>'; $pg .= '<td class=dr>#</td>';
$pg .= '<td class=dl>List</td>'; $pg .= '<td class=dl>List</td>';
$pg .= '<td class=dr>ID</td>'; $pg .= '<td class=dr>ID</td>';
$pg .= '<td class=dr>User</td>'; $pg .= '<td class=dl>IDName</td>';
$pg .= '<td class=dl>User</td>';
$pg .= '<td class=dr>IP</td>'; $pg .= '<td class=dr>IP</td>';
$pg .= '<td class=dr>IPc</td>'; $pg .= '<td class=dr>IPc</td>';
$pg .= '<td class=dr>Hash</td>'; $pg .= '<td class=dr>Hash</td>';
@ -131,7 +132,8 @@ What: <input type=text name=what size=10 value='$wh'>
$pg .= "<td class=dr>$j</td>"; $pg .= "<td class=dr>$j</td>";
$pg .= '<td class=dl>'.$ans['list:'.$i].'</td>'; $pg .= '<td class=dl>'.$ans['list:'.$i].'</td>';
$pg .= '<td class=dr>'.$ans['id:'.$i].'</td>'; $pg .= '<td class=dr>'.$ans['id:'.$i].'</td>';
$pg .= '<td class=dr>'.$ans['user:'.$i].'</td>'; $pg .= '<td class=dl>'.$ans['idname:'.$i].'</td>';
$pg .= '<td class=dl>'.$ans['user:'.$i].'</td>';
$pg .= '<td class=dr>'.isans($ans, 'ip:'.$i).'</td>'; $pg .= '<td class=dr>'.isans($ans, 'ip:'.$i).'</td>';
$pg .= '<td class=dr>'.isans($ans, 'ipc:'.$i).'</td>'; $pg .= '<td class=dr>'.isans($ans, 'ipc:'.$i).'</td>';
$pg .= '<td class=dr>'.isans($ans, 'hash:'.$i).'</td>'; $pg .= '<td class=dr>'.isans($ans, 'hash:'.$i).'</td>';
@ -151,7 +153,7 @@ What: <input type=text name=what size=10 value='$wh'>
$pg .= '<td class=dr>#</td>'; $pg .= '<td class=dr>#</td>';
$pg .= '<td class=dl>Key</td>'; $pg .= '<td class=dl>Key</td>';
$pg .= '<td class=dr>ID</td>'; $pg .= '<td class=dr>ID</td>';
$pg .= '<td class=dr>IDName</td>'; $pg .= '<td class=dl>IDName</td>';
$pg .= '<td class=dr>Hour UTC</td>'; $pg .= '<td class=dr>Hour UTC</td>';
$pg .= '<td class=dl>Count</td>'; $pg .= '<td class=dl>Count</td>';
$pg .= "</tr></thead>\n"; $pg .= "</tr></thead>\n";
@ -172,7 +174,7 @@ What: <input type=text name=what size=10 value='$wh'>
$pg .= "<td class=dr>$j</td>"; $pg .= "<td class=dr>$j</td>";
$pg .= '<td class=dl>'.$ans['key:'.$i].'</td>'; $pg .= '<td class=dl>'.$ans['key:'.$i].'</td>';
$pg .= '<td class=dr>'.$ans['id:'.$i].'</td>'; $pg .= '<td class=dr>'.$ans['id:'.$i].'</td>';
$pg .= '<td class=dr>'.$ans['idname:'.$i].'</td>'; $pg .= '<td class=dl>'.$ans['idname:'.$i].'</td>';
$pg .= '<td class=dr>'.gmdate('j/M H:i:s',$ans['hour:'.$i]*3600).'</td>'; $pg .= '<td class=dr>'.gmdate('j/M H:i:s',$ans['hour:'.$i]*3600).'</td>';
$co = ''; $co = '';
for ($k = 0; $k < 60; $k++) for ($k = 0; $k < 60; $k++)

2
src/ckdb.h

@ -51,7 +51,7 @@
#define DB_VLOCK "1" #define DB_VLOCK "1"
#define DB_VERSION "1.0.5" #define DB_VERSION "1.0.5"
#define CKDB_VERSION DB_VERSION"-1.989" #define CKDB_VERSION DB_VERSION"-1.990"
#define WHERE_FFL " - from %s %s() line %d" #define WHERE_FFL " - from %s %s() line %d"
#define WHERE_FFL_HERE __FILE__, __func__, __LINE__ #define WHERE_FFL_HERE __FILE__, __func__, __LINE__

5
src/ckdb_cmd.c

@ -7570,11 +7570,12 @@ static void event_tree(K_TREE *the_tree, char *list, char *reply, size_t siz,
snprintf(reply, siz, "list:%d=%s%c", snprintf(reply, siz, "list:%d=%s%c",
*rows, list, FLDSEP); *rows, list, FLDSEP);
APPEND_REALLOC(*buf, *off, *len, reply); APPEND_REALLOC(*buf, *off, *len, reply);
snprintf(reply, siz, "id:%d=%d%c", snprintf(reply, siz, "id:%d=%d%c",
*rows, e->id, FLDSEP); *rows, e->id, FLDSEP);
APPEND_REALLOC(*buf, *off, *len, reply); APPEND_REALLOC(*buf, *off, *len, reply);
snprintf(reply, siz, "idname:%d=%s%c",
*rows, e_limits[e->id].name, FLDSEP);
APPEND_REALLOC(*buf, *off, *len, reply);
snprintf(reply, siz, "user:%d=%s%c", snprintf(reply, siz, "user:%d=%s%c",
*rows, e->createby, FLDSEP); *rows, e->createby, FLDSEP);
APPEND_REALLOC(*buf, *off, *len, reply); APPEND_REALLOC(*buf, *off, *len, reply);

Loading…
Cancel
Save