Skip to content
Permalink
Browse files

disabled logging maintenance states for DNF logs

  • Loading branch information...
following5 committed Mar 18, 2016
1 parent 0783240 commit 0b048897cfbb152a326d7bb49612922c5dc1c2df
Showing with 20 additions and 4 deletions.
  1. +2 −0 htdocs/doc/sql/static-data/data.sql
  2. +18 −4 htdocs/templates2/ocstyle/log_cache.tpl
@@ -2862,6 +2862,7 @@ INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2601', 'The pro
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2602', 'All information (coordinates, container size, difficulty, terrain, description text, encoded hints, additional waypoints) is at least up-to-date with', '2015-06-17 10:09:14');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2603', 'More than 2 years ago', '2015-06-17 10:09:14');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2604', 'Admin<br />comment:', '2015-06-17 10:09:14');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2605', 'If you are sure that the geocache is gone, and the owner does not<br />react to your log entry, you may report it to the Opencaching team.<br />Use the \'Report this cache\' button above the cache description.', '2015-06-17 10:09:14');

-- Table sys_trans_ref
SET NAMES 'utf8';
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2602', 'DE', 'Alle Angaben (Koordinaten, Behältergröße, Schwierigkeit, Geländewertung, Beschreibungstext, verschlüsselte Hinweise, zusätzliche Wegpunkte) sind mindestens auf dem Stand von', '2015-06-17 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2603', 'DE', 'vor mehr als 2 Jahren', '2015-06-17 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2604', 'DE', 'Admin-<br />Kommentar:', '2015-06-17 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2605', 'DE', 'Wenn du sicher bist, dass der Cache nicht mehr da ist, und der Besitzer <br />nicht auf dein Log reagiert, kannst du eine Meldung an das Opencaching-<br />Team senden. Verwende dazu den Knopf \'Cache melden\' oberhalb der <br />Cachebeschreibung.', '2015-06-17 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1', 'EN', 'Reorder IDs', '2010-09-02 00:15:30');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2', 'EN', 'The database could not be reconnected.', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('3', 'EN', 'Testing – please do not login', '2010-08-28 11:48:07');
@@ -17,7 +17,8 @@ var tip_general_lo = "{if $gcwp}{t}Select <i>is outdated</i> if the geocache sea
var tip_activate_nm = '{t}By logging "Available", you also confirm that the geocache is in good condition.{/t}';
var tip_activate_lo = '{t}By logging "Available", you also confirm that the geocache description is up-to-date.{/t}';
var tip_disable_nm = "{t}You may indicate here what is the current maintenance state of the geocache.{/t}";
var tip_disable_lo = "{t}You may indicate here if the cache description is up-to-date.{/t}";
var tip_disable_lo = "{t}You may indicate here if the cache description is up-to-date.{/t}";
var tip_dnf_nm = "{t}If you are sure that the geocache is gone, and the owner does not<br />react to your log entry, you may report it to the Opencaching team.<br />Use the 'Report this cache' button above the cache description.{/t}";
var cache_listing_is_outdated = {$cache_listing_is_outdated} + 0;
var ownerlog = {$ownerlog} + 0;
@@ -97,6 +98,17 @@ function logtype_changed()
var nm = document.getElementById('needs_maintenance');
var lo = document.getElementById('listing_outdated');
if ((new_logtype == 2) != (old_logtype == 2))
{
nm.value = "0";
nm.disabled = (new_logtype == 2);
nm.className = (new_logtype == 2 ? 'disabled' : '');
lo.value = "0";
lo.disabled = (new_logtype == 2);
lo.className = (new_logtype == 2 ? 'disabled' : '');
}
if ((new_logtype == 10) != (old_logtype == 10))
{
nm.value = (old_logtype == 10 ? "0" : "1");
@@ -106,10 +118,10 @@ function logtype_changed()
lo.value = (old_logtype == 10 ? "0" : "1");
lo.disabled = (new_logtype == 10);
lo.className = (new_logtype == 10 ? 'disabled' : '');
old_logtype = new_logtype;
}
old_logtype = new_logtype;
// This allows us to post also disabled fields' values:
document.getElementById('needs_maintenance2').value = nm.value;
document.getElementById('listing_outdated2').value = lo.value;
@@ -137,6 +149,8 @@ function show_nm_tip()
show_tip(tip_activate_nm);
else if (document.editform.logtype.value == "11")
show_tip(tip_disable_nm);
else if (document.editform.logtype.value == "2")
show_tip(tip_dnf_nm);
else
show_tip(tip_general_nm);
}
@@ -147,7 +161,7 @@ function show_lo_tip()
show_tip(tip_activate_lo);
else if (document.editform.logtype.value == "11")
show_tip(tip_disable_lo);
else
else if (document.editform.logtype.value != "2")
show_tip(tip_general_lo);
}

0 comments on commit 0b04889

Please sign in to comment.
You can’t perform that action at this time.