Javascript and jquery code added, static dates replaced with dynamic dates, table number field also updated onSelect()