date.js 228行 改为把if收起来改为
if ($(this).text() == strDays) {
var r = index;
$(this).append('</br><p class="rz">入住
');
if ($(this).next().text() != "") {
$(this).next().append('</br><p class="rz">离店
');
}
else {
if ($(this).parent().next().length) {
$(this).parent().next().find("td").eq(0).append('</br><p class="rz">离店
');
}
else {
$(".dateTable").eq(1).find("td").each(function(index, el) {
if ($(this).text() != "") {
$(this).append('</br><p class="rz">离店
');
return false;
}
});
}
}
me._checkColor(me.comeColor, me.outColor);
}
if ($(this).next().text() != "") {
$(this).next().append('</br><p class="rz">结束
');
}
else if ($(this).parent("tr").next("tr").find("td").eq(0).text() != "") {
$(this).parent("tr").next("tr").find("td").eq(0).append('</br><p class="rz">结束
');
}
else {
$(".dateTable").eq(1).find("td").each(function(index, el) {
if ($(this).text() != "") {
$(this).append('</br><p class="rz">结束
');
return false;
}
});
}这里多加一个判断 ,作者只判断了最后一天选择下个月的第一天,选择下一个tr td 的第一天没判断到