/* Please write your code here. */

/* It's sample code.
function popup_close() {
  var odoc = window.opener.document;
  odoc.getElementById("flashmsg").innerHTML = "<div style='color: green'>申請が登録されました。更新してください</div>"
  window.close();
  return false;
}

function set_expense_application(expense_application_id, expense_app_type_name, plan_buy_date, book_no, account_item, content, approximate_amount, tag_prefix) {
    window.opener.document.getElementById(tag_prefix + "_expense_app_type_name").innerHTML = expense_app_type_name
    window.opener.document.getElementById(tag_prefix + "_expense_application_id").setAttribute("value", expense_application_id);
    window.opener.document.getElementById(tag_prefix + "[buy_date]").setAttribute("value", plan_buy_date);
    window.opener.document.getElementById(tag_prefix + "[book_no]").setAttribute("value", book_no);
    window.opener.document.getElementById(tag_prefix + "[account_item]").setAttribute("value", account_item);
    window.opener.document.getElementById(tag_prefix + "[content]").setAttribute("value", content);
    window.opener.document.getElementById(tag_prefix + "[amount]").setAttribute("value", approximate_amount);
//    window.opener.document.getElementById('site_category_code_' + site_id).setAttribute("value", site_category_code);
    window.close();
}
*/

function checkAttend(url) {
  var myAjax = new Ajax.Request(url, {method: 'get', asynchronous: true});
}

function checkAllAttend(url, flg)
{
//  document.searchResultForm.rowCheck.checked = flg;
  for (i=0; i < document.searchResultForm.rowCheck.length; i++)
  {   
    document.searchResultForm.rowCheck[i].checked = flg;
  }
  var myAjax = new Ajax.Request(url, {method: 'get', asynchronous: false});
}

