Revision: 2627
https://sourceforge.net/p/mrbs/code/2627/
Author: cimorrison
Date: 2012-12-30 17:27:20 +0000 (Sun, 30 Dec 2012)
Log Message:
-----------
Fixed some JSHint problems
Modified Paths:
--------------
mrbs/trunk/web/js/datatables.js.php
mrbs/trunk/web/js/edit_entry.js.php
mrbs/trunk/web/js/pending.js.php
mrbs/trunk/web/js/report.js.php
Modified: mrbs/trunk/web/js/datatables.js.php
===================================================================
--- mrbs/trunk/web/js/datatables.js.php 2012-12-29 21:06:22 UTC (rev 2626)
+++ mrbs/trunk/web/js/datatables.js.php 2012-12-30 17:27:20 UTC (rev 2627)
@@ -58,7 +58,7 @@
{
var tableWidth = table.outerWidth();
var leftWidth = table.find('th:first-child').outerWidth();
- var maxWidthPx = (col.sWidth == "relative") ? tableWidth*col.iWidth/100 :
col.iWidth;
+ var maxWidthPx = (col.sWidth === "relative") ? tableWidth*col.iWidth/100 :
col.iWidth;
return Math.min(leftWidth, maxWidthPx);
}
@@ -92,7 +92,7 @@
?>
var winNewWidth = $(window).width();
var winNewHeight = $(window).height();
- if ((winNewWidth == winWidth) && (winNewHeight == winHeight))
+ if ((winNewWidth === winWidth) && (winNewHeight === winHeight))
{
return;
}
Modified: mrbs/trunk/web/js/edit_entry.js.php
===================================================================
--- mrbs/trunk/web/js/edit_entry.js.php 2012-12-29 21:06:22 UTC (rev 2626)
+++ mrbs/trunk/web/js/edit_entry.js.php 2012-12-30 17:27:20 UTC (rev 2627)
@@ -48,7 +48,6 @@
if (properties.indexOf(property) < 0)
{
throw new Error("areaConfig(): invalid property '" + property + "'
passed to areaConfig");
- return;
}
if (areaId === undefined)
@@ -158,7 +157,7 @@
onAllDayClick.oldEndDatepicker = endDatepicker.datepicker('getDate');
endSelect.val(lastSlot);
if ((lastSlot < firstSlot) &&
- (onAllDayClick.oldStartDatepicker == onAllDayClick.oldEndDatepicker))
+ (onAllDayClick.oldStartDatepicker === onAllDayClick.oldEndDatepicker))
{
<?php
// If the booking day spans midnight then the first and last slots
@@ -394,7 +393,7 @@
?>
if (!("min" in testInput) || !(("step" in testInput)))
{
- if ((form.find('input:radio[name=rep_type]:checked').val() == <?php echo
REP_WEEKLY ?>) &&
+ if ((form.find('input:radio[name=rep_type]:checked').val() === '<?php echo
REP_WEEKLY ?>') &&
(form.find('#rep_num_weeks').val() < <?php echo REP_NUM_WEEKS_MIN ?>))
{
window.alert("<?php echo escape_js(get_vocab('you_have_not_entered')) .
'\n' . escape_js(get_vocab('useful_n-weekly_value')) ?>");
Modified: mrbs/trunk/web/js/pending.js.php
===================================================================
--- mrbs/trunk/web/js/pending.js.php 2012-12-29 21:06:22 UTC (rev 2626)
+++ mrbs/trunk/web/js/pending.js.php 2012-12-30 17:27:20 UTC (rev 2627)
@@ -42,7 +42,7 @@
?>
maintable.find('table.sub th.control')
.text('-')
- .live('click', function (event) {
+ .live('click', function () {
var nTr =
$(this).closest('.table_container').parent().prev();
var serial =
$(this).parent().parent().parent().attr('id').replace('subtable_', '');
$('#subtable_' + serial + '_wrapper').slideUp( function () {
@@ -74,7 +74,7 @@
?>
maintable.find('td.control')
.text('+')
- .live('click', function (event) {
+ .live('click', function () {
var nTr = $(this).parent();
var serial = nTr.attr('id').replace('row_', '');
var subtableId = 'subtable_' + serial;
Modified: mrbs/trunk/web/js/report.js.php
===================================================================
--- mrbs/trunk/web/js/report.js.php 2012-12-29 21:06:22 UTC (rev 2626)
+++ mrbs/trunk/web/js/report.js.php 2012-12-30 17:27:20 UTC (rev 2627)
@@ -50,7 +50,7 @@
var output = $(this).filter(':checked').val();
var formatButtons = $('input[name="output_format"]');
var icalButton = formatButtons.filter('[value="' + <?php echo
OUTPUT_ICAL ?> + '"]');
- if (output == <?php echo SUMMARY ?>)
+ if (output === '<?php echo SUMMARY ?>')
{
icalButton.attr('disabled', 'disabled');
if (icalButton.is(':checked'))
------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnmore_123012
_______________________________________________
Mrbs-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mrbs-commits