| |
46 |
46 |
display_template { <a href="@calendar_url@cal-item-view?cal_item_id=@session_list.cal_item_id@">@session_list.session_name@</a> } |
| |
47 |
47 |
} |
| |
48 |
48 |
date_time { |
| |
49 |
49 |
label "Date and Time" |
| |
50 |
50 |
} |
| |
51 |
51 |
action { |
| |
52 |
52 |
label "Actions" |
| |
53 |
53 |
html "nowrap" |
| |
54 |
54 |
display_template { <a href="@calendar_url@cal-item-new?cal_item_id=@session_list.cal_item_id@&return_url=@current_url@">Edit</a> | <a href="@attendance_url@admin/mark?item_id=@session_list.item_id@&return_url=@current_url@">Attendance</a> | <a href="@attendance_url@admin/print?item_id=@session_list.item_id@" target='_blank'>Print</a> <br> <a href="@attendance_url@admin/task-delete?task_id=@session_list.task_id@&grade_id=@session_list.grade_id@&return_url=@current_url@"> Delete</a> | <a href="@attendance_url@admin/spam?item_id=@session_list.cal_item_id@&return_url=@current_url@">Email Attendees</a> } |
| |
55 |
55 |
} |
| |
56 |
56 |
} |
| |
57 |
57 |
|
| |
58 |
58 |
db_multirow -extend {session_name cal_item_id date_time grade_id date_time_serial} session_list get_sessions { } { |
| |
59 |
59 |
set cal_item_id [db_string "getcalid" "select cal_item_id from evaluation_cal_task_map where task_item_id=:item_id" -default ""] |
| |
60 |
60 |
set session_name [db_string "geteventname" "select name from acs_events where event_id=:cal_item_id" -default ""] |
| |
61 |
61 |
set grade_id [db_string "getgradeid" "select grade_id from evaluation_grades where grade_item_id = :grade_item_id" -default ""] |
| |
62 |
62 |
|
| |
63 |
63 |
set date_time "" |
| |
64 |
64 |
set date_time_serial 0 |
| |
65 |
65 |
db_0or1row datetime { |
| |
66 |
|
select to_char(start_date, 'Mon dd, yyyy hh:miam-')||to_char(end_date, 'hh:miam') as date_time, to_char(start_date, 'yyyymmddhhmi') as date_time_serial |
| |
|
66 |
select to_char(start_date, 'Mon dd, yyyy hh:miam-')||to_char(end_date, 'hh:miam') as date_time, to_char(start_date, 'yyyymmddhh24mi') as date_time_serial |
| |
67 |
67 |
from cal_items ci, acs_events e, acs_activities a, timespans s, time_intervals t |
| |
68 |
68 |
where e.timespan_id = s.timespan_id |
| |
69 |
69 |
and s.interval_id = t.interval_id |
| |
70 |
70 |
and e.activity_id = a.activity_id |
| |
71 |
71 |
and e.event_id = ci.cal_item_id |
| |
72 |
72 |
and ci.cal_item_id = :cal_item_id |
| |
73 |
73 |
} |
| |
74 |
74 |
} |
| |
75 |
|
|
| |
76 |
75 |
template::multirow sort session_list date_time_serial |
| |
77 |
76 |
|
| |
78 |
77 |
} else { |
| |
79 |
78 |
set return_url [ad_return_url] |
| |
80 |
79 |
set create_session_type_url [export_vars -base "attendance/admin/create-cal-session-type" { return_url calendar_id }] |
| |
81 |
80 |
set attendance_msg "To use the Attendance Tracking feature you must create a \"Session\" designtation for calendar events. Click <a href=\"$create_session_type_url\">here</a> to let the system create the \"Session\" designation and enable attendance tracking." |
| |
82 |
81 |
} |
| |
83 |
82 |
|
| |
84 |
83 |
set attendance_by_user_url ${attendance_url}admin/summary |