rem: } 
add: } 
context: function setStartEndDates(id, name, currentdate){  /* current date attribute inputs */  input = Array();  input["d"] = document.getElementById(id+"[day]").value;  input["m"] = document.getElementById(id+"[month]").value;  input["y"] = document.getElementById(id+"[year]").value;    switch (eval('document.entryform.'+name+'.value'))  {    case "0":      break;    case "1":      if (id == "enddate")      {        start = calculateDate(input["y"], input["m"], input["d"], 7, 0, 0);        date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);      }      else      {        start = calculateDate(input["y"], input["m"], input["d"], 7, 0, 1);        date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);      }        break;    case "2":      if (id == "enddate")      {        start = calculateDate(input["y"], input["m"], input["d"], 14, 0, 0);        date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);      }      else      {        start = calculateDate(input["y"], input["m"], input["d"], 14, 0, 1);        date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);      }        break;    case "3":      if (id == "enddate")      {        start = calculateDate(input["y"], input["m"], input["d"], 21, 0, 0);        date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);      }      else      {        start = calculateDate(input["y"], input["m"], input["d"], 21, 0, 1);        date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);      }        break;          case "4":      if (id == "enddate")      {        start = calculateDate(input["y"], input["m"], input["d"], 28, 0, 0);        date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);      }      else      {        start = calculateDate(input["y"], input["m"], input["d"], 28, 0, 1);        date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);      }        break;    case "5":      if (id == "enddate")      {        start = calculateDate(input["y"], input["m"], input["d"], 0, 1, 0);        date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);      }      else      {        start = calculateDate(input["y"], input["m"], input["d"], 0, 1, 1);        date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);      }        break;    case "6":      if (id == "enddate")      {        start = calculateDate(input["y"], input["m"], input["d"], 0, 2, 0);        date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);      }      else      {        start = calculateDate(input["y"], input["m"], input["d"], 0, 2, 1);        date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);      }        break;    case "7":    if (id == "enddate")    {      start = calculateDate(input["y"], input["m"], input["d"], 0, 3, 0);      date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);    }    else    {      start = calculateDate(input["y"], input["m"], input["d"], 0, 3, 1);      date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);    }    break;    case "8":    if (id == "enddate")    {      start = calculateDate(input["y"], input["m"], input["d"], 0, 6, 0);      date_setValue("startdate", start["y"], start["m"], start["d"], currentdate);    }    else    {      start = calculateDate(input["y"], input["m"], input["d"], 0, 6, 1);      date_setValue("enddate", start["y"], start["m"], start["d"], currentdate);    }    break;  }}
meta: 7363	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/7363/c4ee580b3d8cd828a8f504963605f216831a9b33/timereg.js/clean/javascript/timereg.js