Commit 8a1da07c authored by Renfred Harper's avatar Renfred Harper

Fix bug that incorrectly assigned special schedules

parent 3399856a
......@@ -67,8 +67,10 @@ function update_grid(restaurants) {
var schedule = undefined;
// If there exists a valid special schedule choose it.
$.each(restaurant.special_schedules, function (idx, special) {
if (day >= Date.parse(special.start)
&& day <= Date.parse(special.end)) {
console.log(Date.parse(special.start))
console.log(date)
if (date >= Date.parse(special.start)
&& date <= Date.parse(special.end)) {
schedule = special;
}
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment