Hide passwords fields data in treeview and events - #2030

This commit is contained in:
enriquecd 2018-03-22 13:10:25 +01:00
parent f809a013e1
commit 078b370cbd
2 changed files with 18 additions and 4 deletions

View File

@ -2042,9 +2042,17 @@ function events_page_custom_fields ($event) {
$data = array(); $data = array();
$data[0] = $field['name']; $data[0] = $field['name'];
$data[1] = empty($fields_data[$field['id_field']]) if(empty($fields_data[$field['id_field']])){
? '<i>'.__('N/A').'</i>' $data[1] = '<i>'.__('N/A').'</i>';
: ui_bbcode_to_html($fields_data[$field['id_field']]); }
else{
if($field['is_password_type']){
$data[1] = '&bull;&bull;&bull;&bull;&bull;&bull;&bull;&bull;';
}
else{
$data[1] = ui_bbcode_to_html($fields_data[$field['id_field']]);
}
}
$field['id_field']; $field['id_field'];

View File

@ -695,7 +695,13 @@ function treeview_printTable($id_agente, $server_data = array(), $no_head = fals
if (!empty($custom_value)) { if (!empty($custom_value)) {
$row = array(); $row = array();
$row['title'] = $field['name'] . ui_print_help_tip (__('Custom field'), true); $row['title'] = $field['name'] . ui_print_help_tip (__('Custom field'), true);
if($field['is_password_type']){
$row['data'] = '&bull;&bull;&bull;&bull;&bull;&bull;&bull;&bull;';
}
else{
$row['data'] = ui_bbcode_to_html($custom_value); $row['data'] = ui_bbcode_to_html($custom_value);
}
$table->data['custom_field_'.$field['id_field']] = $row; $table->data['custom_field_'.$field['id_field']] = $row;
} }
} }