diff --git a/extras/chrome_extension/css/popup.css b/extras/chrome_extension/css/popup.css index 8f8d6f2c79..a736abea57 100644 --- a/extras/chrome_extension/css/popup.css +++ b/extras/chrome_extension/css/popup.css @@ -1,84 +1,170 @@ +* { + font-family: "Open Sans", "Noto Sans", sans-serif +} + body { - min-width:425px; - min-height:540px; - margin:5px; - font-family:Tahoma, Geneva, Arial; - font-size:10pt; + min-width: 425px; + min-height: 540px; + margin: 5px; + font-family: Tahoma, Geneva, Arial; + font-size: 10pt; } -h1 { font-weight: bold; font-size:16px; margin:2px 0px 2px 0px; color:#237948; font-family:arial } -h2{ - color : black; +h1 { + font-weight: bold; + font-size: 14px; + margin: 2px 0px 2px 0px; } -p -{ - font-family:"Times New Roman"; - font-size:20px; +h2 { + color : #333; +} +p { + font-size: 20px; +} +a { + color: #254533; + text-decoration: none; +} +a:hover { + text-decoration: underline; +} +a:visited { + color: #254533; text-decoration:none; +} +a:visited:hover { + text-decoration: underline; } -a { color: #254533; text-decoration:none; } -a:hover { text-decoration:underline; } -a:visited { color: #254533; text-decoration:none; } -a:visited:hover { text-decoration:underline; } +span.res { + font-size: 80%; + color: #555; +} -span.res { font-size:80%; color:#555; } - -img.pm { margin-right:3px;cursor:pointer; margin-top:0px; } -div.main{ - background-color : white; +img.pm { + margin-right: 3px; + cursor: pointer; + margin-top: 2px; + float: right; +} +div.main { + background-color: white; height: 500px; width: 400px; } -div.textarea{ - background-color : #D5DED5; - width :100% +div.textarea { + background-color: #D5DED5; + width: 100% +} +div.e { + text-align: right; + font-size:8pt; +} +div.b { + background-color:white; + display: none; +} +div.b p a { + font-size: 10pt; } -div.e{ text-align:right; font-size:8pt; } -div.b { background-color:white; border:1px solid #BABABA; margin:5px; padding:4px; display:none; } -div.b p a { font-size: 10pt; } -div.b p { margin:2px 0px 4px 0px; display:none; color:#333; font-size:9pt; } div.b div.items p { - margin:2px 0px 8px 0px; color:#333; width:355px;float:left;display:block; + margin: 2px 0px 8px 0px; + width: 355px; + float: left; + display: block; } div.b div.items p img { - float:left;margin:0px 3px 0px 0px; + float: left; + margin: 0px 3px 0px 0px; } -div.options_header{ - margin : 10px 10px; +div.options_header { + margin: 10px 10px; } -div.options_divider{ - width : 100%; - background-color : #C8C8C8; +div.options_divider { + width: 627px; + margin-top: 30px; } -div.optionsG_textarea{ - background-color : green; - width : 450px; - margin : 5px, 10px; +div.options_divider h2{ + margin: 20px 20px 0; + padding: 5px; + font-weight: 500; + border: 2px solid #82b92e; + border-top-left-radius: 2px; + border-top-right-radius: 2px; + color: white; + text-align: center; + background: #82b92e; + font-size: 14px; + font-weight: 600; } -div.options_textarea{ - background-color : #ebebeb; - width : 550px; - margin : 10px 10px; + +div.options_textarea { + background-color: #f6f6f6; + width: 550px; + margin: 0 20px; + padding: 10px 10px 25px 25px; + border-bottom-left-radius: 2px; + border-bottom-right-radius: 2px; + border: 1px solid #e4e4e4; + border-top: 0; +} + +div.options_footer { + width: 550px; + margin: 10px 10px; padding: 10px; - -webkit-border-radius:10px; - border: 2px solid #c8c8c8; } -div.options_footer{ - width : 550px; - margin : 10px 10px; - padding: 10px; +select { + background: white; + border: 1px solid #888; + font-size: smaller; + padding: 2px 1px; + width: 250px; +} + +.sound_selector td:first-child { + padding-left: 25px; + width: 39%; +} + +.options_textarea button { + background-color: #82b92e; + border: 1px solid #82b92e; + color: white; + padding: 6px 32px; + text-align: center; + text-decoration: none; + display: inline-block; + font-size: 12px; + border-radius: 2px; + margin: 25px 0px 0px 422px; +} + +.options_textarea button:hover { + background-color: transparent; + color: #82b92e; + cursor: pointer; +} + +.options_textarea h3 { + text-align: left; + font-size: 11.4pt; +} + +button h3 { + margin: 0; + font-size: 10pt !important; } .tooltip { - display:none; - font-size:12px; - height:70px; - width:160px; - padding:25px; - color:#eee; + display: none; + font-size: 12px; + height: 70px; + width: 160px; + padding: 25px; + color: #eee; } .spinner { @@ -87,11 +173,78 @@ div.options_footer{ left: 50%; margin-left: -50px; margin-top: -50px; - text-align:center; - z-index:1234; + text-align: center; + z-index: 1234; overflow: auto; width: 100px; height: 102px; } +.error { + display: flex; + border: solid #e4e4e4 1px; + border-radius: 2px; + background: #f6f6f6; + padding: 10px; + margin: 10px; + margin-top: 35px; +} +.error_text { + margin: 0 10px; +} + +.result { + margin: 10px; + height: 500; + overflow-y: auto; +} + +#events_title { + padding: 5px 0; + margin: 0; + padding-bottom: 10px; + border-bottom: 1px solid #e5e5e5; +} + +.event { + border: solid 1px #e5e5e5; + border-top: 0; + padding: 5px 6px; + color: white; +} + +.event a { + margin-left: 5px; + color: white; + font-size: 9pt; +} + +.sev-Warning a { + margin-left: 5px; + color: #333; +} + +.event p { + margin: 0 0 0 6px; + padding-top: 2px; + display: none; + font-size: 8pt; +} + +.sev-Warning { + background: #FDDD30; + color: #333; +} +.sev-Critical { + background: #F84348; +} +.sev-Informational { + background: #4CA8E0; +} +.sev-Normal { + background: #84B839; +} +.sev-Maintenance { + background: #A8A8A8; +} \ No newline at end of file diff --git a/extras/chrome_extension/images/error.png b/extras/chrome_extension/images/error.png new file mode 100644 index 0000000000..af676eb8f1 Binary files /dev/null and b/extras/chrome_extension/images/error.png differ diff --git a/extras/chrome_extension/images/gear.png b/extras/chrome_extension/images/gear.png index 77863fc470..bc064777f9 100644 Binary files a/extras/chrome_extension/images/gear.png and b/extras/chrome_extension/images/gear.png differ diff --git a/extras/chrome_extension/images/icon.png b/extras/chrome_extension/images/icon.png index a793b1ca3b..1fb89b2f3e 100644 Binary files a/extras/chrome_extension/images/icon.png and b/extras/chrome_extension/images/icon.png differ diff --git a/extras/chrome_extension/images/icon128.png b/extras/chrome_extension/images/icon128.png index 5fae8cedf8..1859358929 100644 Binary files a/extras/chrome_extension/images/icon128.png and b/extras/chrome_extension/images/icon128.png differ diff --git a/extras/chrome_extension/images/icon16.png b/extras/chrome_extension/images/icon16.png index 3bc0ff4040..59788e3458 100644 Binary files a/extras/chrome_extension/images/icon16.png and b/extras/chrome_extension/images/icon16.png differ diff --git a/extras/chrome_extension/images/icon19.png b/extras/chrome_extension/images/icon19.png index 79e819f62e..d3749f3f34 100644 Binary files a/extras/chrome_extension/images/icon19.png and b/extras/chrome_extension/images/icon19.png differ diff --git a/extras/chrome_extension/images/icon32.png b/extras/chrome_extension/images/icon32.png index a27ee9dc3f..33c63fbb56 100644 Binary files a/extras/chrome_extension/images/icon32.png and b/extras/chrome_extension/images/icon32.png differ diff --git a/extras/chrome_extension/images/icon48.png b/extras/chrome_extension/images/icon48.png index f6941faccf..1fb89b2f3e 100644 Binary files a/extras/chrome_extension/images/icon48.png and b/extras/chrome_extension/images/icon48.png differ diff --git a/extras/chrome_extension/images/icon64.png b/extras/chrome_extension/images/icon64.png index c9cb50c065..cdf016624c 100644 Binary files a/extras/chrome_extension/images/icon64.png and b/extras/chrome_extension/images/icon64.png differ diff --git a/extras/chrome_extension/images/logo.png b/extras/chrome_extension/images/logo.png index 16bf203322..3305749f7a 100644 Binary files a/extras/chrome_extension/images/logo.png and b/extras/chrome_extension/images/logo.png differ diff --git a/extras/chrome_extension/images/minus.gif b/extras/chrome_extension/images/minus.gif deleted file mode 100644 index 2e74ca7bb9..0000000000 Binary files a/extras/chrome_extension/images/minus.gif and /dev/null differ diff --git a/extras/chrome_extension/images/minus.png b/extras/chrome_extension/images/minus.png new file mode 100644 index 0000000000..380d9112b8 Binary files /dev/null and b/extras/chrome_extension/images/minus.png differ diff --git a/extras/chrome_extension/images/plus.gif b/extras/chrome_extension/images/plus.gif deleted file mode 100644 index 47db223eb0..0000000000 Binary files a/extras/chrome_extension/images/plus.gif and /dev/null differ diff --git a/extras/chrome_extension/images/plus.png b/extras/chrome_extension/images/plus.png new file mode 100644 index 0000000000..2666d189e3 Binary files /dev/null and b/extras/chrome_extension/images/plus.png differ diff --git a/extras/chrome_extension/images/refresh.png b/extras/chrome_extension/images/refresh.png index d4c16a67a0..3f81fdde0d 100644 Binary files a/extras/chrome_extension/images/refresh.png and b/extras/chrome_extension/images/refresh.png differ diff --git a/extras/chrome_extension/images/spinny.gif b/extras/chrome_extension/images/spinny.gif index bb6d8f7ca8..6bf2309a0b 100644 Binary files a/extras/chrome_extension/images/spinny.gif and b/extras/chrome_extension/images/spinny.gif differ diff --git a/extras/chrome_extension/js/background.js b/extras/chrome_extension/js/background.js index 3de478b61b..8f3b80e866 100644 --- a/extras/chrome_extension/js/background.js +++ b/extras/chrome_extension/js/background.js @@ -1,29 +1,35 @@ -var timer = null; -var allEvents=new Array(); -var newEvents=new Array(); -var oldEvents=new Array(); -var api_div_numbers=21; - +var refreshTimer = null; +var isFetching = null; +var storedEvents = new Array(); +var notVisited = {}; $(window).load(function() { initilise(); - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(main , 100 ); + // Wait some ms to throw main function + var delay = setTimeout(main, 100); + resetInterval(); }); - - -function fetchEvents(){ - return oldEvents; +function fetchEvents() { + return storedEvents; } +function fetchNotVisited() { + return notVisited; +} + +function removeNotVisited(eventId) { + if (notVisited[eventId] === true) delete notVisited[eventId]; +} function main() { - var url=localStorage["ip_address"]+'/include/api.php?op=get&op2=events&return_type=csv&apipass='+localStorage["api_pass"]+'&user='+localStorage["user_name"]+'&pass='+localStorage["pass"]; - var feedUrl = url; - localStorage["data_check"]="true"; + + chrome.runtime.sendMessage({text: "FETCH_EVENTS"}); + // Do not fetch if is fetching now + if (isFetching) return; + isFetching = true; + + var feedUrl = localStorage["ip_address"]+'/include/api.php?op=get&op2=events&return_type=csv&apipass='+localStorage["api_pass"]+'&user='+localStorage["user_name"]+'&pass='+localStorage["pass"]; req = new XMLHttpRequest(); req.onload = handleResponse; req.onerror = handleError; @@ -32,96 +38,85 @@ function main() { } function handleError() { - localStorage["data_check"]="false"; - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(main , 1000); + chrome.runtime.sendMessage({text: "FETCH_EVENTS_URL_ERROR"}); + isFetching = false; } function handleResponse() { var doc = req.responseText; if (doc=="auth error") { - localStorage["data_check"]="false"; - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(main , 1000); - } - else{ - var n=doc.search("404 Not Found"); - if(n>0){ - localStorage["data_check"]="false"; - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(main , 1000); - } - - else{ - localStorage["data_check"]="true" + chrome.runtime.sendMessage({text: "FETCH_EVENTS_URL_ERROR"}); + } else { + var n = doc.search("404 Not Found"); + if (n>0) { + chrome.runtime.sendMessage({text: "FETCH_EVENTS_DATA_ERROR"}); + } else { getEvents(doc); + chrome.runtime.sendMessage({text: "FETCH_EVENTS_SUCCESS"}); } } + isFetching = false; } function getEvents(reply){ - if(check()){ - all_event_array=reply.split("\n"); - allEvents=divideArray(all_event_array); - if(oldEvents.length==0){ - oldEvents=allEvents; + var fetchedEvents = parseReplyEvents(reply); + + // If there is no events requested, mark all as visited + if (storedEvents.length == 0) { + notVisited = {}; + storedEvents = fetchedEvents; + return; + } + + // Discriminate the new events + newEvents=fetchNewEvents(fetchedEvents,storedEvents); + var newNotVisited = {}; + var notVisitedCount = 0; + + // Check if popup is displayed to make some actions + var views = chrome.extension.getViews({ type: "popup" }); + for(var k=0;k' + title + '
' + event + ''; + // Otherwise, we need to ask the user for permission + // Note, Chrome does not implement the permission static property + // So we have to check for NOT 'denied' instead of 'default' + else if (Notification.permission !== 'denied') { + Notification.requestPermission(function (permission) { + // Whatever the user answers, we make sure we store the information + if(!('permission' in Notification)) { + Notification.permission = permission; + } + + // If the user is okay, let's create a notification + if (permission === "granted") getNotification(pEvent); + }); + } } -function check(){ - if (localStorage["data_check"]=="true" && localStorage["ip_address"] != null && localStorage["api_pass"] != null &&localStorage["user_name"]!=null &&localStorage["pass"]!=null && localStorage["ip_address"] != "" && localStorage["api_pass"] != "" &&localStorage["user_name"]!="" &&localStorage["pass"]!=""){ - return true; +function getNotification(pEvent){ + + // Build the event text + var even = pEvent['type']; + if (pEvent['source'] != '') even += " : " + pEvent['source']; + even += ". Event occured at " + pEvent['date']; + if(pEvent['module'] != 0) even += " in the module with Id "+ pEvent['module']; + even += "."; + + var url = (pEvent['agent']=="") + ? localStorage["ip_address"]+"/index.php?sec=eventos&sec2=operation/events/events" + : localStorage["ip_address"]+"/index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente=" + pEvent['agent']; + + var notification = new Notification( + pEvent['title'], + { + body: even, + icon: "images/icon.png" + } + ); + + // Add the link + notification.onclick = function (event) { + event.preventDefault(); + window.open(url, '_blank'); } - else - return false; + + // Close notification after 10 secs + setTimeout(function() {notification.close()}, 10000); +} + +function resetInterval () { + if (refreshTimer) clearInterval(refreshTimer); + refreshTimer = setInterval(main, localStorage["refresh"]*1000); } function initilise(){ - if(localStorage["ip_address"]==undefined){ - localStorage["ip_address"]="http://firefly.artica.es/pandora_demo"; - - } - - if(localStorage["api_pass"]==undefined){ - localStorage["api_pass"]="doreik0"; - } - - if(localStorage["user_name"]==undefined){ - localStorage["user_name"]="demo"; - } - - if(localStorage["pass"]==undefined){ - localStorage["pass"]="demo"; - } - if(localStorage["critical"]==null){ - localStorage["critical"]="11"; - } - if(localStorage["informational"]==null){ - localStorage["informational"]="1"; - } - if(localStorage["maintenance"]==null){ - localStorage["maintenance"]="10"; - } - if(localStorage["normal"]==null){ - localStorage["normal"]="6"; - } - if(localStorage["warning"]==null){ - localStorage["warning"]="2"; - } - if(localStorage["events"]==null){ - localStorage["events"]=20; - } - if(localStorage["refresh"]==null){ - localStorage["refresh"]="10"; - } - if(localStorage["ip_address"]==null){ - localStorage["ip_address"]="http://firefly.artica.es/pandora_demo"; - } - - if(localStorage["api_pass"]==null){ - localStorage["api_pass"]="doreik0"; - } - - if(localStorage["user_name"]==null){ - localStorage["user_name"]="demo"; - } - - if(localStorage["pass"]==null){ - localStorage["pass"]="demo"; - } - if(localStorage["sound_alert"]==null){ - localStorage["sound_alert"]="on"; - } - if(localStorage["changed"]==null){ - localStorage["changed"]="false"; - } - if(localStorage["new_events"]==null){ - localStorage["new_events"]=parseInt(localStorage["events"]); - } + if (isFetching == null) isFetching = false; + if(localStorage["ip_address"]==undefined){ + localStorage["ip_address"]="http://firefly.artica.es/pandora_demo"; + } + + if(localStorage["api_pass"]==undefined){ + localStorage["api_pass"]="doreik0"; + } + + if(localStorage["user_name"]==undefined){ + localStorage["user_name"]="demo"; + } + + if(localStorage["pass"]==undefined){ + localStorage["pass"]="demo"; + } + if(localStorage["critical"]==null){ + localStorage["critical"]="11"; + } + if(localStorage["informational"]==null){ + localStorage["informational"]="1"; + } + if(localStorage["maintenance"]==null){ + localStorage["maintenance"]="10"; + } + if(localStorage["normal"]==null){ + localStorage["normal"]="6"; + } + if(localStorage["warning"]==null){ + localStorage["warning"]="2"; + } + if(localStorage["events"]==null){ + localStorage["events"]=20; + } + if(localStorage["refresh"]==null){ + localStorage["refresh"]="10"; + } + if(localStorage["ip_address"]==null){ + localStorage["ip_address"]="http://firefly.artica.es/pandora_demo"; + } + + if(localStorage["api_pass"]==null){ + localStorage["api_pass"]="doreik0"; + } + + if(localStorage["user_name"]==null){ + localStorage["user_name"]="demo"; + } + + if(localStorage["pass"]==null){ + localStorage["pass"]="demo"; + } + if(localStorage["sound_alert"]==null){ + localStorage["sound_alert"]="on"; + } + if(localStorage["changed"]==null){ + localStorage["changed"]="false"; + } + if(localStorage["new_events"]==null){ + localStorage["new_events"]=parseInt(localStorage["events"]); + } + if(localStorage["error"]==null) { + localStorage["error"] = true; + } } diff --git a/extras/chrome_extension/js/options.js b/extras/chrome_extension/js/options.js index c8ff5cd6c1..cee8033dde 100644 --- a/extras/chrome_extension/js/options.js +++ b/extras/chrome_extension/js/options.js @@ -11,7 +11,7 @@ function initialise(){ document.getElementById('normal').value = localStorage["normal"]; document.getElementById('warning').value = localStorage["warning"]; document.getElementById('refresh').value = localStorage["refresh"]; - document.getElementById('events').value = localStorage["events"]; + document.getElementById('number_events').value = localStorage["events"]; if(localStorage["sound_alert"]=="on"){ disable(false); document.getElementById('sound_alert_o').checked=true; @@ -20,7 +20,6 @@ function initialise(){ disable(true); document.getElementById('sound_alert_f').checked=true; } - } function change(value, id){ @@ -46,16 +45,13 @@ function change_o(value, id){ if(id=="refresh"){ localStorage["refresh"]=value; } - if(id=="events"){ + if(id=="number_events"){ localStorage["events"]=value; } } function change_global(value,id){ - console.log("value => "+value); - console.log("id => "+id); bg=chrome.extension.getBackgroundPage(); - bg.location.reload(); if(id=="ip_address"){ localStorage["ip_address"]=value; } @@ -96,12 +92,6 @@ function disable(state){ } } -function windowClose() { - //window.close(); - console.log("close"); -} - - //Add callbacks to elements $(document).ready (function () { @@ -163,13 +153,12 @@ $(document).ready (function () { change_o($(this).val(), "refresh"); }); - $("#events").change(function () { - change_o($(this).val(), "events"); + $("#number_events").change(function () { + change_o($(this).val(), "number_events"); }); //Close button $("#close").click (function () { window.close(); }); - }); diff --git a/extras/chrome_extension/js/popup.js b/extras/chrome_extension/js/popup.js index c6213cbf4e..e9f41c328f 100644 --- a/extras/chrome_extension/js/popup.js +++ b/extras/chrome_extension/js/popup.js @@ -1,5 +1,3 @@ -var timer = null; -var event_array; var max_events; var bg; $(document).ready(function(){ @@ -8,198 +6,165 @@ $(document).ready(function(){ localStorage["events"]="20"; } bg=chrome.extension.getBackgroundPage(); - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(mainPoP , 2000 ); -}); -function mainPoP(){ - if(bg.check()){ + // Display the information + if (bg.fetchEvents().length == 0) { + showError("Error in fetching data!! Check your internet connection"); + } else { showEvents(); } - else - { - showUrlError(); - } -} -function showUrlError(){ - var res=document.createDocumentFragment(); - var r = document.getElementById('e'); - var eve=document.createElement('div'); - eve.id="event_temp"; - eve.setAttribute("class","b"); - - var p = document.createElement('a'); - p.href="options.html"; - p.target="_blank"; - p.innerText="Configure ip address,API password, user name and password with correct values"; - eve.appendChild(p); - res.appendChild(eve); - r.parentNode.insertBefore(res,r); - $('.loader').hide(); - $('div.b').show(); - - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(refresh , 1000 ); + + // Adding buttons listeners + document.getElementById("m_refresh").addEventListener("click", mrefresh); + + // Added listener to background messages + chrome.runtime.onMessage.addListener(function(message,sender,sendResponse){ + switch (message.text) { + case "FETCH_EVENTS": + setSpinner(); + //$('div.b').hide(); + break; + case "FETCH_EVENTS_SUCCESS": + unsetSpinner(); + showEvents(); + break; + case "FETCH_EVENTS_DATA_ERROR": + unsetSpinner(); + showError("Error in fetching data!! Check your internet connection"); + break; + case "FETCH_EVENTS_URL_ERROR": + unsetSpinner(); + showError("Configure ip address,API password, user name and password with correct values"); + break; + default: + console.log("Unrecognized message: ", message.text); + break; + } + }); +}); + +function setSpinner () { + $('#refr_img_id').attr("src", "images/spinny.gif"); } -function showDataError(){ - var res=document.createDocumentFragment(); - var r = document.getElementById('e'); - var eve=document.createElement('div'); - eve.id="event_temp"; - eve.setAttribute("class","b"); - - var p = document.createElement('a'); - p.innerText="Error in fetching data!! Check your internet connection"; - eve.appendChild(p); - res.appendChild(eve); - r.parentNode.insertBefore(res,r); - $('.loader').hide(); - $('div.b').show(); - - if(timer) { - clearTimeout(timer); - } - timer =setTimeout(refresh , 1000 ); +function unsetSpinner() { + $('#refr_img_id').attr("src", "images/refresh.png"); +} + +function clearError() { + $('.error').hide(); + $('.error a').text(""); + $('.result').css('height', null); +} + +function showError(text){ + $('.error a').text(text); + $('.error').show(); + $('.result').height(420); } function showEvents(){ - var allEvents=bg.fetchEvents(); - var r = document.getElementById('e'); - var res=document.createDocumentFragment(); + + clearError(); + $('#events').empty(); + var e_refr = document.getElementById('event_temp'); + if(e_refr){ + wrapper.removeChild(e_refr); + } + var allEvents = bg.fetchEvents(); + var notVisitedEvents = bg.fetchNotVisited(); var eve=document.createElement('div'); eve.id="event_temp"; eve.setAttribute("class","b"); var i=0; if(allEvents.length>0){ - while(i_ + var nums = id.split('_'); + var pid = "p_" + nums[1]; + + // Mark as visited if visited + if($(this).parent().css('font-weight') == '600') { + bg.removeNotVisited(nums[2]); + $(this).parent().css('font-weight', ''); + } + + // Toggle information if($('#' + pid).css('display') == 'none') { - $('#' + pid).slideDown("fast"); - $(this).attr({src: 'images/minus.gif'}); + $('#' + pid).slideDown(); + $(this).attr({src: 'images/minus.png'}); } else { - $('#' + pid).slideUp("fast"); - $(this).attr({src: 'images/plus.gif'}); + $('#' + pid).slideUp(); + $(this).attr({src: 'images/plus.png'}); } } -function refresh(){ - localStorage["new_events"]=0; - bg.hideBadge(); - var e = document.getElementById('event_temp'); - if(e){ - e.parentNode.removeChild(e); - } - mainPoP(); -} - - function mrefresh(){ localStorage["new_events"]=0; - bg.hideBadge(); - var bg=chrome.extension.getBackgroundPage(); - bg.location.reload(); - var e = document.getElementById('event_temp'); - if(e){ - e.parentNode.removeChild(e); - } - mainPoP(); + bg.updateBadge(); + clearError(); + bg.resetInterval(); + bg.main(); } diff --git a/extras/chrome_extension/manifest.json b/extras/chrome_extension/manifest.json index 025e680ffa..662eaf24ee 100644 --- a/extras/chrome_extension/manifest.json +++ b/extras/chrome_extension/manifest.json @@ -20,10 +20,10 @@ }, "options_page": "options.html", "permissions": [ - "tabs", - "notifications", - "http://*/*", - "background" + "tabs", + "notifications", + "http://*/*", + "background" ], "default_locale": "en" } diff --git a/extras/chrome_extension/options.html b/extras/chrome_extension/options.html index 7678782265..59410b8b05 100644 --- a/extras/chrome_extension/options.html +++ b/extras/chrome_extension/options.html @@ -3,6 +3,7 @@ Pandora FMS extension + @@ -35,23 +36,18 @@ - -
+
- - + - - - - - + - + - + - + - + - - +

Event Alert Sounds Configuration

Sound Alerts + Sound Alerts On Off
SeveritySound Type
Critical
Informational
Maintenance
Normal
Warning
Auto Refresh Time + Auto Refresh Time
Number of events - @@ -173,10 +169,11 @@
+ +
diff --git a/extras/chrome_extension/popup.html b/extras/chrome_extension/popup.html index e616020f50..951adfc0ca 100644 --- a/extras/chrome_extension/popup.html +++ b/extras/chrome_extension/popup.html @@ -1,5 +1,6 @@ + @@ -7,16 +8,28 @@
- -
Loading...
-
-
-

Events

-
+ + + + + + + +
+
+
+
+ +
+
+

ERROR

+ +
+
+
+
+
diff --git a/extras/pandora_update_version.sh b/extras/pandora_update_version.sh index 486dcbb79b..2b77dd8e02 100755 --- a/extras/pandora_update_version.sh +++ b/extras/pandora_update_version.sh @@ -64,7 +64,8 @@ $PANDHOME_ENT/pandora_plugins/Nutanix/pandora_nutanix.pl \ $PANDHOME_ENT/pandora_plugins/MTL/pandora_mtl.pl \ $PANDHOME_ENT/pandora_plugins/Informix/informix.pl \ $PANDHOME_ENT/pandora_plugins/Ruckus/ruckus.pl \ -$PANDHOME_ENT/pandora_server/util/plugins/vmware-plugin.pl" +$PANDHOME_ENT/pandora_plugins/UX/pandora_ux.pl \ +$PANDHOME_ENT/pandora_server/util/plugins/vmware-plugin.pl " PLUGIN_LIB_FILE="$CODEHOME/pandora_server/lib/PandoraFMS/PluginTools.pm" # Update version in spec files diff --git a/pandora_agents/pc/AIX/pandora_agent.conf b/pandora_agents/pc/AIX/pandora_agent.conf index 78e0821d91..d0e53ebecd 100644 --- a/pandora_agents/pc/AIX/pandora_agent.conf +++ b/pandora_agents/pc/AIX/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, AIX version +# Version 7.0NG.718, AIX version # Licensed under GPL license v2, # Copyright (c) 2003-2010 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/pc/FreeBSD/pandora_agent.conf b/pandora_agents/pc/FreeBSD/pandora_agent.conf index 8852a19369..0eb8f55178 100644 --- a/pandora_agents/pc/FreeBSD/pandora_agent.conf +++ b/pandora_agents/pc/FreeBSD/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, FreeBSD Version +# Version 7.0NG.718, FreeBSD Version # Licensed under GPL license v2, # Copyright (c) 2003-2010 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/pc/HP-UX/pandora_agent.conf b/pandora_agents/pc/HP-UX/pandora_agent.conf index 8c73870953..7108651c8b 100644 --- a/pandora_agents/pc/HP-UX/pandora_agent.conf +++ b/pandora_agents/pc/HP-UX/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, HP-UX Version +# Version 7.0NG.718, HP-UX Version # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/pc/Linux/pandora_agent.conf b/pandora_agents/pc/Linux/pandora_agent.conf index 290f5817ee..21b8b41c06 100644 --- a/pandora_agents/pc/Linux/pandora_agent.conf +++ b/pandora_agents/pc/Linux/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, GNU/Linux +# Version 7.0NG.718, GNU/Linux # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/pc/NT4/pandora_agent.conf b/pandora_agents/pc/NT4/pandora_agent.conf index 7a47ad64ca..d79070cbf8 100644 --- a/pandora_agents/pc/NT4/pandora_agent.conf +++ b/pandora_agents/pc/NT4/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, GNU/Linux +# Version 7.0NG.718, GNU/Linux # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/pc/SunOS/pandora_agent.conf b/pandora_agents/pc/SunOS/pandora_agent.conf index 2acdc4736b..38d1a68066 100644 --- a/pandora_agents/pc/SunOS/pandora_agent.conf +++ b/pandora_agents/pc/SunOS/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, Solaris Version +# Version 7.0NG.718, Solaris Version # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/pc/Win32/pandora_agent.conf b/pandora_agents/pc/Win32/pandora_agent.conf index b2110f2478..44a621e200 100644 --- a/pandora_agents/pc/Win32/pandora_agent.conf +++ b/pandora_agents/pc/Win32/pandora_agent.conf @@ -1,6 +1,6 @@ # Base config file for Pandora FMS Windows Agent # (c) 2006-2010 Artica Soluciones Tecnologicas -# Version 7.0NG.717 +# Version 7.0NG.718 # This program is Free Software, you can redistribute it and/or modify it # under the terms of the GNU General Public Licence as published by the Free Software diff --git a/pandora_agents/shellscript/aix/pandora_agent.conf b/pandora_agents/shellscript/aix/pandora_agent.conf index af7efdc29d..cc91d44bed 100644 --- a/pandora_agents/shellscript/aix/pandora_agent.conf +++ b/pandora_agents/shellscript/aix/pandora_agent.conf @@ -1,6 +1,6 @@ # Fichero de configuracion base de agentes de Pandora # Base config file for Pandora agents -# Version 7.0NG.717, AIX version +# Version 7.0NG.718, AIX version # General Parameters # ================== diff --git a/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf b/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf index 63b9c76b14..a3f71e626a 100644 --- a/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf +++ b/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf @@ -1,6 +1,6 @@ # Fichero de configuracion base de agentes de Pandora # Base config file for Pandora agents -# Version 7.0NG.717 +# Version 7.0NG.718 # FreeBSD/IPSO version # Licenced under GPL licence, 2003-2007 Sancho Lerena diff --git a/pandora_agents/shellscript/hp-ux/pandora_agent.conf b/pandora_agents/shellscript/hp-ux/pandora_agent.conf index cf8b955a94..e57d9b8e72 100644 --- a/pandora_agents/shellscript/hp-ux/pandora_agent.conf +++ b/pandora_agents/shellscript/hp-ux/pandora_agent.conf @@ -1,6 +1,6 @@ # Fichero de configuracion base de agentes de Pandora # Base config file for Pandora agents -# Version 7.0NG.717, HPUX Version +# Version 7.0NG.718, HPUX Version # General Parameters # ================== diff --git a/pandora_agents/shellscript/linux/pandora_agent.conf b/pandora_agents/shellscript/linux/pandora_agent.conf index 7946e94ad4..9544190a1c 100644 --- a/pandora_agents/shellscript/linux/pandora_agent.conf +++ b/pandora_agents/shellscript/linux/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717 +# Version 7.0NG.718 # Licensed under GPL license v2, # (c) 2003-2010 Artica Soluciones Tecnologicas # please visit http://pandora.sourceforge.net diff --git a/pandora_agents/shellscript/mac_osx/pandora_agent.conf b/pandora_agents/shellscript/mac_osx/pandora_agent.conf index 4bd85fea52..0a635fe968 100644 --- a/pandora_agents/shellscript/mac_osx/pandora_agent.conf +++ b/pandora_agents/shellscript/mac_osx/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717 +# Version 7.0NG.718 # Licensed under GPL license v2, # (c) 2003-2009 Artica Soluciones Tecnologicas # please visit http://pandora.sourceforge.net diff --git a/pandora_agents/shellscript/openWRT/pandora_agent.conf b/pandora_agents/shellscript/openWRT/pandora_agent.conf index bce34a02e5..0bedcbadf7 100644 --- a/pandora_agents/shellscript/openWRT/pandora_agent.conf +++ b/pandora_agents/shellscript/openWRT/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717 +# Version 7.0NG.718 # Licensed under GPL license v2, # please visit http://pandora.sourceforge.net diff --git a/pandora_agents/shellscript/solaris/pandora_agent.conf b/pandora_agents/shellscript/solaris/pandora_agent.conf index fe724e254a..5208129e75 100644 --- a/pandora_agents/shellscript/solaris/pandora_agent.conf +++ b/pandora_agents/shellscript/solaris/pandora_agent.conf @@ -1,6 +1,6 @@ # Fichero de configuracion base de agentes de Pandora # Base config file for Pandora agents -# Version 7.0NG.717, Solaris version +# Version 7.0NG.718, Solaris version # General Parameters # ================== diff --git a/pandora_agents/unix/AIX/pandora_agent.conf b/pandora_agents/unix/AIX/pandora_agent.conf index 79cd101c3e..5edd29b25a 100644 --- a/pandora_agents/unix/AIX/pandora_agent.conf +++ b/pandora_agents/unix/AIX/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, AIX version +# Version 7.0NG.718, AIX version # Licensed under GPL license v2, # Copyright (c) 2003-2010 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index 1c8fcede3d..ce05a736ac 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.717-180110 +Version: 7.0NG.718-180130 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index 0f3cd0f4db..20e99d306b 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.717-180110" +pandora_version="7.0NG.718-180130" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/Darwin/pandora_agent.conf b/pandora_agents/unix/Darwin/pandora_agent.conf index e18cc25981..9fcd0e0ec3 100644 --- a/pandora_agents/unix/Darwin/pandora_agent.conf +++ b/pandora_agents/unix/Darwin/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, GNU/Linux +# Version 7.0NG.718, GNU/Linux # Licensed under GPL license v2, # Copyright (c) 2003-2012 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/FreeBSD/pandora_agent.conf b/pandora_agents/unix/FreeBSD/pandora_agent.conf index 3a66ba3349..8c2a2e1519 100644 --- a/pandora_agents/unix/FreeBSD/pandora_agent.conf +++ b/pandora_agents/unix/FreeBSD/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, FreeBSD Version +# Version 7.0NG.718, FreeBSD Version # Licensed under GPL license v2, # Copyright (c) 2003-2016 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/HP-UX/pandora_agent.conf b/pandora_agents/unix/HP-UX/pandora_agent.conf index 962e9d760f..e3bf99a391 100644 --- a/pandora_agents/unix/HP-UX/pandora_agent.conf +++ b/pandora_agents/unix/HP-UX/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, HP-UX Version +# Version 7.0NG.718, HP-UX Version # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/Linux/pandora_agent.conf b/pandora_agents/unix/Linux/pandora_agent.conf index c4092a3c9a..0e1f7b4e00 100644 --- a/pandora_agents/unix/Linux/pandora_agent.conf +++ b/pandora_agents/unix/Linux/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, GNU/Linux +# Version 7.0NG.718, GNU/Linux # Licensed under GPL license v2, # Copyright (c) 2003-2014 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/NT4/pandora_agent.conf b/pandora_agents/unix/NT4/pandora_agent.conf index cb35dc3848..15a79c55ac 100644 --- a/pandora_agents/unix/NT4/pandora_agent.conf +++ b/pandora_agents/unix/NT4/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, GNU/Linux +# Version 7.0NG.718, GNU/Linux # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/NetBSD/pandora_agent.conf b/pandora_agents/unix/NetBSD/pandora_agent.conf index c746e395a4..ec2b14b196 100644 --- a/pandora_agents/unix/NetBSD/pandora_agent.conf +++ b/pandora_agents/unix/NetBSD/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, NetBSD Version +# Version 7.0NG.718, NetBSD Version # Licensed under GPL license v2, # Copyright (c) 2003-2010 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/SunOS/pandora_agent.conf b/pandora_agents/unix/SunOS/pandora_agent.conf index ffbe99b449..607da990a3 100644 --- a/pandora_agents/unix/SunOS/pandora_agent.conf +++ b/pandora_agents/unix/SunOS/pandora_agent.conf @@ -1,5 +1,5 @@ # Base config file for Pandora FMS agents -# Version 7.0NG.717, Solaris Version +# Version 7.0NG.718, Solaris Version # Licensed under GPL license v2, # Copyright (c) 2003-2009 Artica Soluciones Tecnologicas # http://www.pandorafms.com diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index a0e33757a4..bd3e995987 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -40,8 +40,8 @@ my $Sem = undef; # Semaphore used to control the number of threads my $ThreadSem = undef; -use constant AGENT_VERSION => '7.0NG.717'; -use constant AGENT_BUILD => '180110'; +use constant AGENT_VERSION => '7.0NG.718'; +use constant AGENT_BUILD => '180130'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; @@ -1298,13 +1298,14 @@ sub check_collections () { # Read local md5 my $local_collection_md5 = ''; - if (defined (open (MD5_FILE, "< $ConfDir/collections/$collection_md5_file"))) { - $local_collection_md5 = ; - close MD5_FILE; - } - else{ - log_message ('Collection', "Could not open dir $ConfDir/collections/$collection_md5_file"); - next; + if (-f "$ConfDir/collections/$collection_md5_file") { + if (open (MD5_FILE, "< $ConfDir/collections/$collection_md5_file")) { + $local_collection_md5 = ; + close MD5_FILE; + } else { + log_message ('Collection', "Could not open dir $ConfDir/collections/$collection_md5_file"); + next; + } } # Check for changes @@ -1312,7 +1313,7 @@ sub check_collections () { next if ($local_collection_md5 eq $remote_collection_md5); # Download and unzip - if(recv_file ($collection_md5_file, $Conf{'server_path_md5'}) != 0){ + if (recv_file ($collection_file, $Conf{'server_path_zip'}) != 0) { log_message ('Collection', "Could not write $collection_file on " . $Conf{'server_path_zip'}); next; } diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index 005da06156..056d65de26 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -2,8 +2,8 @@ #Pandora FMS Linux Agent # %define name pandorafms_agent_unix -%define version 7.0NG.717 -%define release 180110 +%define version 7.0NG.718 +%define release 180130 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index 236415dd97..46386f2b89 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -2,8 +2,8 @@ #Pandora FMS Linux Agent # %define name pandorafms_agent_unix -%define version 7.0NG.717 -%define release 180110 +%define version 7.0NG.718 +%define release 180130 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index d39ebf1007..898b6f3c38 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -9,8 +9,8 @@ # Please see http://www.pandorafms.org. This code is licensed under GPL 2.0 license. # ********************************************************************** -PI_VERSION="7.0NG.717" -PI_BUILD="180110" +PI_VERSION="7.0NG.718" +PI_BUILD="180130" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/bin/pandora_agent.conf b/pandora_agents/win32/bin/pandora_agent.conf index 2b28347152..3d921af535 100644 --- a/pandora_agents/win32/bin/pandora_agent.conf +++ b/pandora_agents/win32/bin/pandora_agent.conf @@ -1,6 +1,6 @@ # Base config file for Pandora FMS Windows Agent # (c) 2006-2017 Artica Soluciones Tecnologicas -# Version 7.0NG.717 +# Version 7.0NG.718 # This program is Free Software, you can redistribute it and/or modify it # under the terms of the GNU General Public Licence as published by the Free Software diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index 9e54cd3878..83467f86ff 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -3,7 +3,7 @@ AllowLanguageSelection {Yes} AppName -{Pandora FMS Windows Agent v7.0NG.717} +{Pandora FMS Windows Agent v7.0NG.718} ApplicationID {17E3D2CF-CA02-406B-8A80-9D31C17BD08F} @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{180110} +{180130} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index f87c67967c..a0d5789245 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.717(Build 180110)") +#define PANDORA_VERSION ("7.0NG.718(Build 180130)") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index 64403f9bfd..a9893c66b8 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.717(Build 180110))" + VALUE "ProductVersion", "(7.0NG.718(Build 180130))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index 3f1f80ea43..ec3015920a 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.717-180110 +Version: 7.0NG.718-180130 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 7fb92df1be..3289b58dcb 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.717-180110" +pandora_version="7.0NG.718-180130" package_pear=0 package_pandora=1 diff --git a/pandora_console/extras/mr/11.sql b/pandora_console/extras/mr/11.sql index a49120cf85..95ea1459fa 100644 --- a/pandora_console/extras/mr/11.sql +++ b/pandora_console/extras/mr/11.sql @@ -13,4 +13,6 @@ ALTER TABLE tcontainer_item ADD COLUMN `fullscale` tinyint(1) UNSIGNED NOT NULL ALTER TABLE treport_content ADD COLUMN hide_no_data tinyint(1) DEFAULT 0; -COMMIT; \ No newline at end of file +ALTER TABLE tagente_estado ADD COLUMN last_unknown_update bigint(20) NOT NULL default 0; + +COMMIT; diff --git a/pandora_console/extras/pandoradb_migrate_6.0_to_7.0.mysql.sql b/pandora_console/extras/pandoradb_migrate_6.0_to_7.0.mysql.sql index 7849faaa65..ec97615a55 100644 --- a/pandora_console/extras/pandoradb_migrate_6.0_to_7.0.mysql.sql +++ b/pandora_console/extras/pandoradb_migrate_6.0_to_7.0.mysql.sql @@ -1110,6 +1110,7 @@ ALTER TABLE tserver ADD COLUMN `server_keepalive` int(11) DEFAULT 0; ALTER TABLE tagente_estado MODIFY `status_changes` tinyint(4) unsigned default 0; ALTER TABLE tagente_estado CHANGE `last_known_status` `known_status` tinyint(4) default 0; ALTER TABLE tagente_estado ADD COLUMN `last_known_status` tinyint(4) default 0; +ALTER TABLE tagente_estado ADD COLUMN last_unknown_update bigint(20) NOT NULL default 0; -- --------------------------------------------------------------------- -- Table `talert_actions` @@ -1158,10 +1159,10 @@ ALTER TABLE titem MODIFY `source_data` int(10) unsigned; INSERT INTO `tconfig` (`token`, `value`) VALUES ('big_operation_step_datos_purge', '100'); INSERT INTO `tconfig` (`token`, `value`) VALUES ('small_operation_step_datos_purge', '1000'); INSERT INTO `tconfig` (`token`, `value`) VALUES ('days_autodisable_deletion', '30'); -INSERT INTO `tconfig` (`token`, `value`) VALUES ('MR', 9); +INSERT INTO `tconfig` (`token`, `value`) VALUES ('MR', 11); UPDATE tconfig SET value = 'https://licensing.artica.es/pandoraupdate7/server.php' WHERE token='url_update_manager'; DELETE FROM `tconfig` WHERE `token` = 'current_package_enterprise'; -INSERT INTO `tconfig` (`token`, `value`) VALUES ('current_package_enterprise', '716'); +INSERT INTO `tconfig` (`token`, `value`) VALUES ('current_package_enterprise', '718'); -- --------------------------------------------------------------------- -- Table `tplanned_downtime_agents` diff --git a/pandora_console/general/alert_enterprise.php b/pandora_console/general/alert_enterprise.php index d5be19eebd..66d6e36b09 100644 --- a/pandora_console/general/alert_enterprise.php +++ b/pandora_console/general/alert_enterprise.php @@ -94,7 +94,7 @@ switch ($tipo) { case "helpmodal": echo __("This is the online help for Pandora FMS console. This help is -in best cases- just a brief contextual help, not intented to teach you how to use Pandora FMS. Official documentation of Pandora FMS is about 900 pages, and you probably don't need to read it entirely, but sure, you should download it and take a look.

- Download the official documentation"); + Download the official documentation"); break; diff --git a/pandora_console/general/login_page.php b/pandora_console/general/login_page.php index 8d6712f65a..290e44f262 100755 --- a/pandora_console/general/login_page.php +++ b/pandora_console/general/login_page.php @@ -254,7 +254,7 @@ echo '