"; $agentData = gis_get_data_last_position_agent($id_agente); $updateGisData = db_get_value('update_gis_data', 'tagente', 'id_agente', $id_agente); $agent_name = agents_get_name($id_agente); // Avoid the agents with characters that fails the div. $agent_name = md5($agent_name); // Map with the current position echo '
'; if (!gis_get_agent_map($id_agente, '500px', '100%', false)) { ui_print_error_message(__('There is no default map. Please go to the setup for to set a default map.')); echo ""; } if ($agentData === false) { ui_print_info_message( [ 'no_close' => true, 'message' => __("There is no GIS data for this agent, so it's positioned in default position of map."), ] ); } ui_print_warning_message( [ 'no_close' => true, 'message' => __("When you change the Agent position, the agent automatically activates the 'Ignore new GIS data' option"), ] ); $table = new stdClass(); $table->width = '100%'; $table->class = 'databox filter-table-adv mrgn_top_15px pdd_t_0px_important'; $table->data = []; $table->cellpadding = 0; $table->cellspacing = 0; $table->head[0] = __('Agent position'); $table->head_colspan[0] = 4; $table->headstyle[0] = 'text-align:center'; $table->size[0] = '50%'; $table->size[2] = '50%'; $table->data[1][0] = html_print_label_input_block( __('Latitude: '), html_print_input_text_extended( 'latitude', $agentData['stored_latitude'], 'text-latitude', '', 20, 20, false, '', [ 'onchange' => 'setIgnoreGISDataEnabled()', 'onkeyup' => 'setIgnoreGISDataEnabled()', ], true ) ); $table->data[1][1] = html_print_label_input_block( __('Longitude: '), html_print_input_text_extended( 'longitude', $agentData['stored_longitude'], 'text-longitude', '', 20, 20, false, '', [ 'onchange' => 'setIgnoreGISDataEnabled()', 'onkeyup' => 'setIgnoreGISDataEnabled()', ], true ) ); $table->data[2][0] = html_print_label_input_block( __('Altitude: '), html_print_input_text_extended( 'altitude', $agentData['stored_altitude'], 'text-altitude', '', 10, 10, false, '', [ 'onchange' => 'setIgnoreGISDataEnabled()', 'onkeyup' => 'setIgnoreGISDataEnabled()', ], true ) ); $table->data[2][1] = html_print_label_input_block( __('Ignore new GIS data: '), '