community-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hbout...@apache.org
Subject svn commit: r1769827 - /comdev/reporter.apache.org/trunk/site/js/addrelease.js
Date Tue, 15 Nov 2016 13:27:31 GMT
Author: hboutemy
Date: Tue Nov 15 13:27:31 2016
New Revision: 1769827

URL: http://svn.apache.org/viewvc?rev=1769827&view=rev
Log:
fill current date as default

Modified:
    comdev/reporter.apache.org/trunk/site/js/addrelease.js

Modified: comdev/reporter.apache.org/trunk/site/js/addrelease.js
URL: http://svn.apache.org/viewvc/comdev/reporter.apache.org/trunk/site/js/addrelease.js?rev=1769827&r1=1769826&r2=1769827&view=diff
==============================================================================
--- comdev/reporter.apache.org/trunk/site/js/addrelease.js (original)
+++ comdev/reporter.apache.org/trunk/site/js/addrelease.js Tue Nov 15 13:27:31 2016
@@ -9,10 +9,9 @@
      }
  }
  document.getElementById('committee').value = committee;
- var date = new Date();
  var xdate = document.getElementById('xdate');
  var done = false;
- xdate.value = date.getFullYear() + "-" + ((date.getMonth()+1) < 10? "0"+(date.getMonth()+1)
: (date.getMonth()+1)) + "-" + ((date.getDay()+1) < 10? "0"+(date.getDay()+1) : (date.getDay()+1))
+ xdate.value = new Date().toISOString().substring(0, 10)
  
  function validate(form) {
   var x = document.getElementById('xdate').value.split("-");
@@ -75,4 +74,4 @@
   }
   document.getElementById('committee').value = committee;
  }
- 
\ No newline at end of file
+ 



Mime
View raw message