||ifequal||sid||0||
auth_error('||auth_fail_reason||');
||else||

setTodos([\
||begin_list_todo|| \
  ||if(not(blank(event_uid)))|| \
	||ifdef||done_some||,||endif|| 
\
	  { cal_id:'||event_cal||',	\
	  	uid:'||event_uid||', \
	  	desc:'||web_encode_js(event_desc)||', \
		location_alert:||json_validate_bool(location_alert)||, location_action:'||location_action||', location_name:'||location_name||',\
		event_hasdue:||json_validate_bool(event_hasdue)||, due_in:'||time_interval_text_approx(event_dt)||',\
		mtags: '||event_mtags||'\
	  }\
	||define||done_some||true||\
  ||endif||\
||end_list_todo||
], '||cal_id||');


||endif||