Merge branch 'ent-2543-6208-version-movil-metaconsola-no-muestra-graficas-ni-algunas-imagenes-metaconsola-no-redirige-a-vista-de-movil' into 'develop'

Ent 2543 6208 version movil metaconsola no muestra graficas ni algunas imagenes metaconsola no redirige a vista de movil

See merge request artica/pandorafms!1886
This commit is contained in:
vgilc 2018-10-25 10:40:56 +02:00
commit aff94d0761
3 changed files with 12 additions and 8 deletions

View File

@ -2194,19 +2194,26 @@ function graph_agent_status ($id_agent = false, $width = 300, $height = 200, $re
if ($data_agents == false) {
$groups = implode(',', array_keys(users_get_groups(false, 'AR', false)));
$p_table = "tagente";
$s_table = "tagent_secondary_group";
if (is_metaconsole()) {
$p_table = "tmetaconsole_agent";
$s_table = "tmetaconsole_agent_secondary_group";
}
$data = db_get_row_sql(sprintf('SELECT
SUM(critical_count) AS Critical,
SUM(warning_count) AS Warning,
SUM(normal_count) AS Normal,
SUM(unknown_count) AS Unknown
%s
FROM tagente ta LEFT JOIN tagent_secondary_group tasg
FROM %s ta LEFT JOIN %s tasg
ON ta.id_agente = tasg.id_agent
WHERE
ta.disabled = 0 AND
%s
(ta.id_grupo IN (%s) OR tasg.id_group IN (%s))',
$show_not_init ? ', SUM(notinit_count) "Not init"' : '',
$p_table, $s_table,
empty($id_agent) ? '' : "ta.id_agente = $id_agent AND",
$groups,
$groups

View File

@ -228,12 +228,8 @@ class User {
$ui->showFooter(false);
$ui->beginContent();
if ($system->getConfig('metaconsole'))
$logo_image = html_print_image (ui_get_mobile_login_icon(),
true, array ("alt" => "logo", "border" => 0));
else
$logo_image = html_print_image (ui_get_mobile_login_icon(),
true, array ("alt" => "logo", "border" => 0),false, false, false, true);
$logo_image = html_print_image (ui_get_mobile_login_icon(),
true, array ("alt" => "logo", "border" => 0), false, false, false, true);
$ui->contentAddHtml('<div style="text-align: center;" class="login_logo">' .
$logo_image . '</div>');
@ -292,7 +288,7 @@ class User {
$ui->beginContent();
$ui->contentAddHtml('<div style="text-align: center;" class="login_logo">' .
html_print_image (ui_get_mobile_login_icon(),
true, array ("alt" => "logo", "border" => 0)) .
true, array ("alt" => "logo", "border" => 0), false, false, false, true) .
'</div>');
$ui->contentAddHtml('<div id="login_container">');
$ui->beginForm();

View File

@ -28,6 +28,7 @@ class Tactical {
else {
$this->correct_acl = false;
}
include_javascript_dependencies_flot_graph();
}
public function show() {