/*
     $Revision$
     $Id$

     File:        cnt_list.js
*/
function cntEdit(row)
{
  $(row).addClass('dirty');
  var cnt_key = row.getAttribute("ROWKEY");

  url = "appl/cnt/cnt_contract.asp?cnt_key=" + cnt_key + "&urole=" + urole;
  FcltMgr.openDetail(url);
}

function reloadList(json, textStatus)
{
  // liefst doe ik FcltMgr.reload maar dit is een POST form. Dat komt niet over.
  parent.document.forms.u2.submit();
}

function cntForApproval(rowArray, isMulti)
{
  var cntData = eval("(" + rowArray[0].getAttribute("ROWDATA") + ")");
  FcltMgr.confirm(L("lcl_cnt_forward_forapproval").format(cntData.cntNummerIntern), { autoconfirm: isMulti }, function() {
      var cntKeyString = getKeyString(rowArray);
      var data = { cnt_key: cntKeyString };
      protectRequest.dataToken(data);
      $.post("../cnt/cnt_forapproval.asp",
          data,
          FcltCallbackAndThen(reloadList),
          "json");
  });
}
