ClipperCMS/ClipperCMS — pull request #390 by AgelxNash (2013-10-28 06:05:41+00:00)
Title: usertype in LogEvent

Method getLoginUserID() can give a web user or manager. But if the user is a web user, the reports will show login manager. Look at [actions/eventlog.dynamic.php](https://github.com/ClipperCMS/ClipperCMS/blob/develop/manager/actions/eventlog.dynamic.php#L92-L97):
```php
$sql = "SELECT el.id, el.type, el.createdon, el.source, el.eventid,IFNULL(wu.username,mu.username) as 'username' " .
"FROM ".$tbl_event_log." el ".
"LEFT JOIN ".$tbl_manager_users." mu ON mu.id=el.user AND el.usertype=0 ".
"LEFT JOIN ".$tbl_web_users." wu ON wu.id=el.user AND el.usertype=1 ".
($sqlQuery ? " WHERE ".(is_numeric($sqlQuery)?"(eventid='$sqlQuery') OR ":'')."(source LIKE '%$sqlQuery%') OR (description LIKE '%$sqlQuery%')":"")." ".
"ORDER BY createdon DESC";
```