/*==================== APRESENTAÇÃO ====================*/
var listaOportunidades = new Array();

function toggleOportunidades(v) {
  for(var i = 0; i < listaOportunidades.length; i++) {
    if(listaOportunidades[i][0] == v) {
      var d = top.getObj("c_" + v, top.mainFrame);
      if(d.style.display == "none") {
        d.style.display = "block";
      } else {
        d.style.display = "none";
      }
      return true;
    }
  }
  top.loadLista("actions/loadOportunidade.asp?c=" + v, listaOportunidades, v, mostraOportunidade, true);

}

function mostraOportunidade(v) {
  top.getObj("c_" + v, top.mainFrame).style.display = "block";
  top.setInnerHTML("c_" + v, listaOportunidades[listaOportunidades.length-1][1], top.mainFrame);
}
/*================== FIM APRESENTAÇÃO ==================*/

function pagina(p) {
  document.form1.pg.value = p;
  consultar(0);
}

function limpar() {
 document.form1.local.value = "";
 document.form1.nome.value = "";
 document.form1.estado.selectedIndex = 0;
 document.form1.pg.value = 1;
}

function consultar(x) {
  if (x == 1) {
    pagina(1);
  }
  document.form1.submit();
}

function start(){
  top.toggleForwardLink();
  if(top.central){
    top.central.zeraTudo();
  }
}
