rbrindley: branch rbrindley/astman_revamp r4609 - /team/rbrindley/astman_reva...

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Wed Mar 11 12:36:36 CDT 2009


Author: rbrindley
Date: Wed Mar 11 12:36:33 2009
New Revision: 4609

URL: http://svn.digium.com/svn-view/asterisk-gui?view=rev&rev=4609
Log:

- oops, time comes before weekday


Modified:
    team/rbrindley/astman_revamp/config/js/pbx2.js

Modified: team/rbrindley/astman_revamp/config/js/pbx2.js
URL: http://svn.digium.com/svn-view/asterisk-gui/team/rbrindley/astman_revamp/config/js/pbx2.js?view=diff&rev=4609&r1=4608&r2=4609
==============================================================================
--- team/rbrindley/astman_revamp/config/js/pbx2.js (original)
+++ team/rbrindley/astman_revamp/config/js/pbx2.js Wed Mar 11 12:36:33 2009
@@ -329,6 +329,7 @@
  */
 pbx.ring_groups = {};
 
+/*---------------------------------------------------------------------------*/
 /**
  * Time Interval object.
  */
@@ -343,37 +344,6 @@
 	days: ['sun', 'mon', 'tue', 'wed', 'thu', 'fri', 'sat'],
 	months: ['jan', 'feb', 'mar', 'apr', 'may', 'jun', 'jul', 'aug', 'sep', 'oct', 'nov', 'dec']
 
-};
-
-/**
- * Validates Weekday format.
- * @param week The weekday range to be checked.
- * @return boolean on valid format.
- */
-pbx.time_intervals.validate.weekday = function(week) {
-	if (week === '*') {
-		/* this condition was separated from the switch
-		 * because its its own condition */
-		return true;
-	}
-
-	if (week.contains('-') && week[3] !== '-') {
-		return false;
-	} else if (week[3] === '-') {
-		var first = week.split('-')[0];
-		var second = week.split('-')[1];
-
-		if (!this.days.contains(first) || !this.days.contains(second)) {
-			return false;
-		}
-	} else {
-		if (!this.days.contains(week)) {
-			return false;
-		}
-
-	}
-
-	return true;
 };
 
 /**
@@ -427,6 +397,38 @@
 	}
 };
 
+/**
+ * Validates Weekday format.
+ * @param week The weekday range to be checked.
+ * @return boolean on valid format.
+ */
+pbx.time_intervals.validate.weekday = function(week) {
+	if (week === '*') {
+		/* this condition was separated from the switch
+		 * because its its own condition */
+		return true;
+	}
+
+	if (week.contains('-') && week[3] !== '-') {
+		return false;
+	} else if (week[3] === '-') {
+		var first = week.split('-')[0];
+		var second = week.split('-')[1];
+
+		if (!this.days.contains(first) || !this.days.contains(second)) {
+			return false;
+		}
+	} else {
+		if (!this.days.contains(week)) {
+			return false;
+		}
+
+	}
+
+	return true;
+};
+/*---------------------------------------------------------------------------*/
+
 /*---------------------------------------------------------------------------*/
 /**
  * Trunks object.




More information about the asterisk-gui-commits mailing list