app/helpers/week_plan_helper.rb
def table_header_for_week( curr_date = Date.today )
    sOut = "\r\n"                                   # (Add CR+LF for each table row to improve generated source readibility)
    dt_start = Schedule.get_week_start( curr_date )

    dt_start.step(dt_start+5, 1) { |d|
      header_text = "" << d.day.to_s << "/" << d.month.to_s << "<br/>" << h(Schedule.long_day_name( d.cwday ))
      sOut << "    #{content_tag( :th, header_text, :class => get_schedule_cell_style( d ) )}\r\n"
    }
    sOut << "    #{content_tag( :th, h(Schedule.long_day_name(7)), :class => 'schedule-notes' )}\r\n"

    return content_tag( :tr, sOut, :class => 'schedule-header' )
  end
# Builds up HTML table headers for displaying a week's schedule based on a
# specified date (defaults to today), starting from the beginning of the
# week.
# curr_date : Date instance for extracting the current day
Builds up HTML table headers for displaying a week's schedule based on a
specified date (defaults to today), starting from the beginning of the
week.
curr_date : Date instance for extracting the current day
Builds up HTML table headers for displaying a week ' s schedule based on a specified date ( defaults to today ) starting from the beginning of the week . curr_date : Date instance for extracting the current day
def table_header_for_week( curr_date = Date.today )
    sOut = "\r\n"                                   
    dt_start = Schedule.get_week_start( curr_date )
    dt_start.step(dt_start+5, 1) { |d|
      header_text = "" << d.day.to_s << "/" << d.month.to_s << "<br/>" << h(Schedule.long_day_name( d.cwday ))
      sOut << "    #{content_tag( :th, header_text, :class => get_schedule_cell_style( d ) )}\r\n"
    }
    sOut << "    #{content_tag( :th, h(Schedule.long_day_name(7)), :class => 'schedule-notes' )}\r\n"
    return content_tag( :tr, sOut, :class => 'schedule-header' )
  end
def table_header_for_week ( curr_date = Date . today ) sOut = "\r\n" dt_start = Schedule . get_week_start ( curr_date ) dt_start . step ( dt_start + 5 , 1 ) { | d | header_text = "" << d . day . to_s << "/" << d . month . to_s << "<br/>" << h ( Schedule . long_day_name ( d . cwday ) ) sOut << "    #{content_tag( :th, header_text, :class => get_schedule_cell_style( d ) )}\r\n" } sOut << "    #{content_tag( :th, h(Schedule.long_day_name(7)), :class => 'schedule-notes' )}\r\n" return content_tag ( :tr , sOut , :class => 'schedule-header' ) end
Builds up HTML table headers for displaying a week's schedule based on a
specified date (defaults to today), starting from the beginning of the
week.
Builds up HTML table headers for displaying a week ' s schedule based on a specified date ( defaults to today ) starting from the beginning of the week .
# (Add CR+LF for each table row to improve generated source readibility)
curr_date
today