incubator-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cross...@apache.org
Subject svn commit: r722370 - in /incubator/public/trunk: clutch.py site-author/clutch.js site-author/clutch.xml site-publish/clutch.html site-publish/clutch.js
Date Tue, 02 Dec 2008 04:17:11 GMT
Author: crossley
Date: Mon Dec  1 20:17:11 2008
New Revision: 722370

URL: http://svn.apache.org/viewvc?rev=722370&view=rev
Log:
Move Clutch javascript to a file.

Added:
    incubator/public/trunk/site-author/clutch.js   (with props)
    incubator/public/trunk/site-publish/clutch.js   (with props)
Modified:
    incubator/public/trunk/clutch.py
    incubator/public/trunk/site-author/clutch.xml
    incubator/public/trunk/site-publish/clutch.html

Modified: incubator/public/trunk/clutch.py
URL: http://svn.apache.org/viewvc/incubator/public/trunk/clutch.py?rev=722370&r1=722369&r2=722370&view=diff
==============================================================================
--- incubator/public/trunk/clutch.py (original)
+++ incubator/public/trunk/clutch.py Mon Dec  1 20:17:11 2008
@@ -728,74 +728,11 @@
 <document>
   <properties>
     <title>Status of the clutch</title>
+    <script type="text/javascript" src="clutch.js"> </script>
   </properties>
   <body>
     <section id="current">
       <title>Status of the clutch currently in incubation</title>
-      <script type="text/javascript">
-<!--
-window.onload = function() {
-  theTable = document.getElementById("clutch");
-  today = new Date();
-  secondsToday = today.getTime() / 1000;
-  for (var x = 1; x < theTable.tBodies[0].rows.length; x++) {
-    name = theTable.tBodies[0].rows[x].cells[0].firstChild.nodeValue;
-    // Days since projects started
-    dateString = theTable.tBodies[0].rows[x].cells[2].firstChild.nodeValue;
-    arrayTemp = dateString.split("-");
-    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
-      dateStart = new Date(Number(arrayTemp[0]),
-          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
-          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
-      secondsStart = dateStart.getTime() / 1000;
-      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
-      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = elapsed;
-    }
-    else {
-      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = "?";
-      elapsed = -10;
-    }
-    if (elapsed == -10) { // error
-      theTable.tBodies[0].rows[x].cells[3].className = "issue";
-    } else if (elapsed < 273) { // 9 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool1";
-    } else if (elapsed < 547) { // 18 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool2";
-    } else if (elapsed < 820) { // 27 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool3";
-    } else {
-      theTable.tBodies[0].rows[x].cells[3].className = "cool4";
-    }
-    // Days since edited Status file
-    dateString = theTable.tBodies[0].rows[x].cells[8].firstChild.nodeValue;
-    arrayTemp = dateString.split("-");
-    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
-      dateStart = new Date(Number(arrayTemp[0]),
-          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
-          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
-      secondsStart = dateStart.getTime() / 1000;
-      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
-      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = elapsed;
-    }
-    else {
-      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = "?";
-      elapsed = -10;
-    }
-    if (elapsed == -10) { // error
-      theTable.tBodies[0].rows[x].cells[9].className = "issue";
-    } else if (elapsed < 61) { // 2 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool1";
-    } else if (elapsed < 122) { // 4 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool2";
-    } else if (elapsed < 273) { // 9 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool3";
-    } else {
-      theTable.tBodies[0].rows[x].cells[9].className = "cool4";
-    }
-  }
-}
-//-->
-      </script>
       <p>
         Clutch is a tool which gathers details about the projects currently in
         incubation. It aims to encourage and nurture, to provide an overview of

Added: incubator/public/trunk/site-author/clutch.js
URL: http://svn.apache.org/viewvc/incubator/public/trunk/site-author/clutch.js?rev=722370&view=auto
==============================================================================
--- incubator/public/trunk/site-author/clutch.js (added)
+++ incubator/public/trunk/site-author/clutch.js Mon Dec  1 20:17:11 2008
@@ -0,0 +1,60 @@
+window.onload = function() {
+  theTable = document.getElementById("clutch");
+  today = new Date();
+  secondsToday = today.getTime() / 1000;
+  for (var x = 1; x < theTable.tBodies[0].rows.length; x++) {
+    name = theTable.tBodies[0].rows[x].cells[0].firstChild.nodeValue;
+    // Days since projects started
+    dateString = theTable.tBodies[0].rows[x].cells[2].firstChild.nodeValue;
+    arrayTemp = dateString.split("-");
+    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
+      dateStart = new Date(Number(arrayTemp[0]),
+          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
+          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
+      secondsStart = dateStart.getTime() / 1000;
+      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
+      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = elapsed;
+    }
+    else {
+      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = "?";
+      elapsed = -10;
+    }
+    if (elapsed == -10) { // error
+      theTable.tBodies[0].rows[x].cells[3].className = "issue";
+    } else if (elapsed < 273) { // 9 months
+      theTable.tBodies[0].rows[x].cells[3].className = "cool1";
+    } else if (elapsed < 547) { // 18 months
+      theTable.tBodies[0].rows[x].cells[3].className = "cool2";
+    } else if (elapsed < 820) { // 27 months
+      theTable.tBodies[0].rows[x].cells[3].className = "cool3";
+    } else {
+      theTable.tBodies[0].rows[x].cells[3].className = "cool4";
+    }
+    // Days since edited Status file
+    dateString = theTable.tBodies[0].rows[x].cells[8].firstChild.nodeValue;
+    arrayTemp = dateString.split("-");
+    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
+      dateStart = new Date(Number(arrayTemp[0]),
+          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
+          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
+      secondsStart = dateStart.getTime() / 1000;
+      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
+      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = elapsed;
+    }
+    else {
+      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = "?";
+      elapsed = -10;
+    }
+    if (elapsed == -10) { // error
+      theTable.tBodies[0].rows[x].cells[9].className = "issue";
+    } else if (elapsed < 61) { // 2 months
+      theTable.tBodies[0].rows[x].cells[9].className = "cool1";
+    } else if (elapsed < 122) { // 4 months
+      theTable.tBodies[0].rows[x].cells[9].className = "cool2";
+    } else if (elapsed < 273) { // 9 months
+      theTable.tBodies[0].rows[x].cells[9].className = "cool3";
+    } else {
+      theTable.tBodies[0].rows[x].cells[9].className = "cool4";
+    }
+  }
+}

Propchange: incubator/public/trunk/site-author/clutch.js
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/public/trunk/site-author/clutch.xml
URL: http://svn.apache.org/viewvc/incubator/public/trunk/site-author/clutch.xml?rev=722370&r1=722369&r2=722370&view=diff
==============================================================================
--- incubator/public/trunk/site-author/clutch.xml (original)
+++ incubator/public/trunk/site-author/clutch.xml Mon Dec  1 20:17:11 2008
@@ -18,74 +18,11 @@
 <document>
   <properties>
     <title>Status of the clutch</title>
+    <script type="text/javascript" src="clutch.js"> </script>
   </properties>
   <body>
     <section id="current">
       <title>Status of the clutch currently in incubation</title>
-      <script type="text/javascript">
-<!--
-window.onload = function() {
-  theTable = document.getElementById("clutch");
-  today = new Date();
-  secondsToday = today.getTime() / 1000;
-  for (var x = 1; x < theTable.tBodies[0].rows.length; x++) {
-    name = theTable.tBodies[0].rows[x].cells[0].firstChild.nodeValue;
-    // Days since projects started
-    dateString = theTable.tBodies[0].rows[x].cells[2].firstChild.nodeValue;
-    arrayTemp = dateString.split("-");
-    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
-      dateStart = new Date(Number(arrayTemp[0]),
-          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
-          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
-      secondsStart = dateStart.getTime() / 1000;
-      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
-      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = elapsed;
-    }
-    else {
-      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = "?";
-      elapsed = -10;
-    }
-    if (elapsed == -10) { // error
-      theTable.tBodies[0].rows[x].cells[3].className = "issue";
-    } else if (elapsed < 273) { // 9 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool1";
-    } else if (elapsed < 547) { // 18 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool2";
-    } else if (elapsed < 820) { // 27 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool3";
-    } else {
-      theTable.tBodies[0].rows[x].cells[3].className = "cool4";
-    }
-    // Days since edited Status file
-    dateString = theTable.tBodies[0].rows[x].cells[8].firstChild.nodeValue;
-    arrayTemp = dateString.split("-");
-    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
-      dateStart = new Date(Number(arrayTemp[0]),
-          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
-          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
-      secondsStart = dateStart.getTime() / 1000;
-      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
-      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = elapsed;
-    }
-    else {
-      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = "?";
-      elapsed = -10;
-    }
-    if (elapsed == -10) { // error
-      theTable.tBodies[0].rows[x].cells[9].className = "issue";
-    } else if (elapsed < 61) { // 2 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool1";
-    } else if (elapsed < 122) { // 4 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool2";
-    } else if (elapsed < 273) { // 9 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool3";
-    } else {
-      theTable.tBodies[0].rows[x].cells[9].className = "cool4";
-    }
-  }
-}
-//-->
-      </script>
       <p>
         Clutch is a tool which gathers details about the projects currently in
         incubation. It aims to encourage and nurture, to provide an overview of
@@ -172,7 +109,7 @@
         </li>
       </ul>
       <p>
-        Clutch last gathered: Mon Dec  1 23:46:00 2008 UTC.<br />
+        Clutch last gathered: Tue Dec  2 04:11:29 2008 UTC.<br />
         Number of podlings in incubation: 35
       </p>
       <table id="clutch">
@@ -581,9 +518,9 @@
           <td>group-1</td>
           <td class="cool1">True</td>
           <td class="cool1"><a href="projects/olio.html">True</a></td>
-          <td>2008-11-24</td>
+          <td>2008-12-02</td>
           <td></td>
-          <td>1,3,-</td>
+          <td>2,4,-</td>
           <td class="cool1"><a href="http://people.apache.org/~jim/projects.html#olio">11</a></td>
           <td>0</td>
           <td class="cool1"><a href="http://svn.apache.org/repos/asf/incubator/olio">True</a></td>

Modified: incubator/public/trunk/site-publish/clutch.html
URL: http://svn.apache.org/viewvc/incubator/public/trunk/site-publish/clutch.html?rev=722370&r1=722369&r2=722370&view=diff
==============================================================================
--- incubator/public/trunk/site-publish/clutch.html (original)
+++ incubator/public/trunk/site-publish/clutch.html Mon Dec  1 20:17:11 2008
@@ -21,6 +21,7 @@
   <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
   <link rel="stylesheet" href="./style/style.css" type="text/css" />
         <title>Status of the clutch - Apache Incubator</title>
+  <script type="text/javascript" src="clutch.js"> </script>
  </head>
  <body>        
   <table border="0" width="100%" cellspacing="0">
@@ -111,70 +112,6 @@
    <a name="current">Status of the clutch currently in incubation</a>
 </h2>
 <div class="section-content">
-<script type="text/javascript">
-<!--
-window.onload = function() {
-  theTable = document.getElementById("clutch");
-  today = new Date();
-  secondsToday = today.getTime() / 1000;
-  for (var x = 1; x < theTable.tBodies[0].rows.length; x++) {
-    name = theTable.tBodies[0].rows[x].cells[0].firstChild.nodeValue;
-    // Days since projects started
-    dateString = theTable.tBodies[0].rows[x].cells[2].firstChild.nodeValue;
-    arrayTemp = dateString.split("-");
-    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
-      dateStart = new Date(Number(arrayTemp[0]),
-          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
-          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
-      secondsStart = dateStart.getTime() / 1000;
-      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
-      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = elapsed;
-    }
-    else {
-      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = "?";
-      elapsed = -10;
-    }
-    if (elapsed == -10) { // error
-      theTable.tBodies[0].rows[x].cells[3].className = "issue";
-    } else if (elapsed < 273) { // 9 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool1";
-    } else if (elapsed < 547) { // 18 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool2";
-    } else if (elapsed < 820) { // 27 months
-      theTable.tBodies[0].rows[x].cells[3].className = "cool3";
-    } else {
-      theTable.tBodies[0].rows[x].cells[3].className = "cool4";
-    }
-    // Days since edited Status file
-    dateString = theTable.tBodies[0].rows[x].cells[8].firstChild.nodeValue;
-    arrayTemp = dateString.split("-");
-    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
-      dateStart = new Date(Number(arrayTemp[0]),
-          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
-          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
-      secondsStart = dateStart.getTime() / 1000;
-      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
-      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = elapsed;
-    }
-    else {
-      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = "?";
-      elapsed = -10;
-    }
-    if (elapsed == -10) { // error
-      theTable.tBodies[0].rows[x].cells[9].className = "issue";
-    } else if (elapsed < 61) { // 2 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool1";
-    } else if (elapsed < 122) { // 4 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool2";
-    } else if (elapsed < 273) { // 9 months
-      theTable.tBodies[0].rows[x].cells[9].className = "cool3";
-    } else {
-      theTable.tBodies[0].rows[x].cells[9].className = "cool4";
-    }
-  }
-}
-//-->
-      </script>
 <p>
         Clutch is a tool which gathers details about the projects currently in
         incubation. It aims to encourage and nurture, to provide an overview of
@@ -261,7 +198,7 @@
         </li>
       </ul>
 <p>
-        Clutch last gathered: Mon Dec  1 23:46:00 2008 UTC.<br />
+        Clutch last gathered: Tue Dec  2 04:11:29 2008 UTC.<br />
         Number of podlings in incubation: 35
       </p>
 <table id="clutch" class="colortable" width="100%">
@@ -670,9 +607,9 @@
           <td>group-1</td>
           <td class="cool1">True</td>
           <td class="cool1"><a href="projects/olio.html">True</a></td>
-          <td>2008-11-24</td>
+          <td>2008-12-02</td>
           <td />
-          <td>1,3,-</td>
+          <td>2,4,-</td>
           <td class="cool1"><a href="http://people.apache.org/~jim/projects.html#olio">11</a></td>
           <td>0</td>
           <td class="cool1"><a href="http://svn.apache.org/repos/asf/incubator/olio">True</a></td>

Added: incubator/public/trunk/site-publish/clutch.js
URL: http://svn.apache.org/viewvc/incubator/public/trunk/site-publish/clutch.js?rev=722370&view=auto
==============================================================================
--- incubator/public/trunk/site-publish/clutch.js (added)
+++ incubator/public/trunk/site-publish/clutch.js Mon Dec  1 20:17:11 2008
@@ -0,0 +1,60 @@
+window.onload = function() {
+  theTable = document.getElementById("clutch");
+  today = new Date();
+  secondsToday = today.getTime() / 1000;
+  for (var x = 1; x < theTable.tBodies[0].rows.length; x++) {
+    name = theTable.tBodies[0].rows[x].cells[0].firstChild.nodeValue;
+    // Days since projects started
+    dateString = theTable.tBodies[0].rows[x].cells[2].firstChild.nodeValue;
+    arrayTemp = dateString.split("-");
+    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
+      dateStart = new Date(Number(arrayTemp[0]),
+          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
+          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
+      secondsStart = dateStart.getTime() / 1000;
+      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
+      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = elapsed;
+    }
+    else {
+      theTable.tBodies[0].rows[x].cells[3].firstChild.nodeValue = "?";
+      elapsed = -10;
+    }
+    if (elapsed == -10) { // error
+      theTable.tBodies[0].rows[x].cells[3].className = "issue";
+    } else if (elapsed < 273) { // 9 months
+      theTable.tBodies[0].rows[x].cells[3].className = "cool1";
+    } else if (elapsed < 547) { // 18 months
+      theTable.tBodies[0].rows[x].cells[3].className = "cool2";
+    } else if (elapsed < 820) { // 27 months
+      theTable.tBodies[0].rows[x].cells[3].className = "cool3";
+    } else {
+      theTable.tBodies[0].rows[x].cells[3].className = "cool4";
+    }
+    // Days since edited Status file
+    dateString = theTable.tBodies[0].rows[x].cells[8].firstChild.nodeValue;
+    arrayTemp = dateString.split("-");
+    if (arrayTemp.length > 0 && arrayTemp[0] > 2000) {
+      dateStart = new Date(Number(arrayTemp[0]),
+          (arrayTemp.length > 1 ? Number(arrayTemp[1])-1 : 1),
+          (arrayTemp.length > 2 ? Number(arrayTemp[2]) : 1));
+      secondsStart = dateStart.getTime() / 1000;
+      elapsed = Math.floor((secondsToday - secondsStart) / (60 * 60 * 24));
+      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = elapsed;
+    }
+    else {
+      theTable.tBodies[0].rows[x].cells[9].firstChild.nodeValue = "?";
+      elapsed = -10;
+    }
+    if (elapsed == -10) { // error
+      theTable.tBodies[0].rows[x].cells[9].className = "issue";
+    } else if (elapsed < 61) { // 2 months
+      theTable.tBodies[0].rows[x].cells[9].className = "cool1";
+    } else if (elapsed < 122) { // 4 months
+      theTable.tBodies[0].rows[x].cells[9].className = "cool2";
+    } else if (elapsed < 273) { // 9 months
+      theTable.tBodies[0].rows[x].cells[9].className = "cool3";
+    } else {
+      theTable.tBodies[0].rows[x].cells[9].className = "cool4";
+    }
+  }
+}

Propchange: incubator/public/trunk/site-publish/clutch.js
------------------------------------------------------------------------------
    svn:eol-style = native



---------------------------------------------------------------------
To unsubscribe, e-mail: cvs-unsubscribe@incubator.apache.org
For additional commands, e-mail: cvs-help@incubator.apache.org


Mime
View raw message