Seph Soliman avatar Seph Soliman committed c78f60f

* round time and change debugging button. rounding still doesnt work correctly

Comments (0)

Files changed (2)

 function stopTimer() {
 	if(globalTimer.started) {
 		var e = globalTimer.getElapsed();
+		console.log(e);
 		var hours = roundNumber(e.hours + (e.minutes / 60) + (e.seconds / 60 / 60), 2);
+		//hours = roundHour(hours, HOUR_PRECISION); // rounding doesn't work correctly. 0.15 -> 0.91666
 		// * User may be trying to select something, so only change the value if needed.
 		if($("#reporthours").val() != hours.toString())
-// * Rounds an hour to the given precious, specified in minutes
+// * Rounds an hour to the given precision, specified in minutes
 function roundHour(hour, precision) {
 	var minutes = parseFloat(hour) * 60;
 	var rest = minutes % precision;
 				<span class="debug" onclick="$('#debug').slideToggle(250)" id="debugbtn"></span><br/>
 				<div class="debug" id="debug" style="display: none; width: 200px;">
 					<input type="button" value="Reload Projects" onclick="pullProjects()" />
-					<input type="button" value="Show report" onclick="$('#reportcontainer').show();" /><br/>
+					<input type="button" value="Add 1m" onclick="globalTimer.startTime -= 60*1000" /><br/>
 					<input type="button" value="Get User Id" onclick="pullUserId()" />
 					<input type="button" value="Show front" onclick="showFront()" /><br/>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.