KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Accessing logined user information from Dashboard or widget. #2359

Open Javier Gallardo opened this topic on on Sep 28 - 4 comments

Javier Gallardo commented on Sep 28

how to display user data in any report eg reportone.view.php

KoolReport commented on Sep 29

If you are using the CustomBoard of dashboard framework. In the view of CustomBoard, such as ReportBoard.view.php, you can access the logged user with

    $user = $this->board()->app()->user();
    echo $user->name();
Javier Gallardo commented on Sep 30

I need the column of the database

Javier Gallardo commented on Sep 30

KoolReport commented on Oct 1

Inside ReportBoard.view.php, you can query data

    $user = $this->board()->app()->user();
    $userInfo = AutoMaker::table("users")->where("id",$user->id())->run()->get(0);
    echo $userInfo["displayname"];
    echo $userInfo["email"];

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
None yet