method getId documentation in bbn\Appui\Dashboard
Returns the dashboard id by its code
function(string $code)
{
if (empty($code)) {
throw new \Exception(_('A wrong argument value is passed'));
}
if (!Str::isUid($code)) {
return $this->db->selectOne(
[
'table' => $this->cfgPref['tables']['user_options'],
'fields' => [$this->archPref['id']],
'where' => [
'conditions' => [[
'field' => $this->archPref['id_option'],
'value' => $this->idList
], [
'field' => 'JSON_UNQUOTE(JSON_EXTRACT(cfg, \'$.code\'))',
'value' => $code
], [
'logic' => 'OR',
'conditions' => [[
'field' => $this->archPref['id_user'],
'value' => $this->user->getId()
], [
'field' => $this->archPref['id_group'],
'value' => $this->user->getGroup()
], [
'field' => $this->archPref['public'],
'value' => 1
]]
]]
]
]
);
}
return $code;
}
Returns the dashboard id by its code BBN is a suite of PHP and JS libraries and VueJS components - all open-source! bbn.io, build applications, the quick way
This website uses cookies to ensure you get the best experience on our website.
© 2011-2023
BBN Solutions