-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
51 changed files
with
5,745 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
<?php | ||
class Aluno{ | ||
private $matricula,$id,$Cod_cur,$Num_mat,$Nome_civil,$Fin; | ||
private $Fev,$Ain,$Aev,$sistema,$Nome_cur,$Nome_social,$cont; | ||
function getNome_social(){ | ||
return $this->Nome_social; | ||
} | ||
function getNome_cur(){ | ||
return $this->Nome_cur; | ||
} | ||
function getMatricula(){ | ||
return $this->matricula; | ||
} | ||
function setMatricula($ma){ | ||
$this->matricula = $ma; | ||
} | ||
function getId(){ | ||
return $this->id; | ||
} | ||
function setId($id){ | ||
$this->id = $id; | ||
} | ||
function getCod(){ | ||
return $this->Cod_cur; | ||
} | ||
function getNum_mat(){ | ||
return $this->Num_mat; | ||
} | ||
function getNome_civil(){ | ||
return $this->Nome_civil; | ||
} | ||
function getFin(){ | ||
return $this->Fin; | ||
} | ||
function getFev(){ | ||
return $this->Fev; | ||
} | ||
function getAin(){ | ||
return $this->Ain; | ||
} | ||
function getAev(){ | ||
return $this->Aev; | ||
} | ||
function getSistema(){ | ||
return $this->sistema; | ||
} | ||
function pesquisa_banco(){ | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
$stmt = $pdo->prepare("SELECT *,COUNT(*) FROM Alunos WHERE Num_mat LIKE '$this->matricula%'"); | ||
$stmt->execute(array('id','Cod_cur','Num_mat','Nome_civil','Nome_cur','Fin','Fev','Ain','Aev','sistema','Nome_social','COUNT(*)')); | ||
$resultado = $stmt->fetchAll(PDO::FETCH_ASSOC); | ||
foreach($resultado as $item){ | ||
$this->cont = $item['COUNT(*)']; | ||
$this->id = $item['id']; | ||
$this->Cod_cur = $item['Cod_cur']; | ||
$this->Num_mat = $item['Num_mat']; | ||
$this->Nome_civil = $item['Nome_civil']; | ||
$this->Nome_cur = $item['Nome_cur']; | ||
$this->Fin = $item['Fin']; | ||
$this->Fev = $item['Fev']; | ||
$this->Ain = $item['Ain']; | ||
$this->Aev = $item['Aev']; | ||
$this->sistema = $item['sistema']; | ||
$this->Nome_social = $item['Nome_social']; | ||
|
||
} | ||
} | ||
function pesquisa_banco2($id){ | ||
$this->id = $id; | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
$stmt = $pdo->prepare("SELECT * FROM Alunos WHERE id LIKE $this->id"); | ||
$this->cont = 1; | ||
$stmt->execute(array('id','Cod_cur','Num_mat','Nome_civil','Nome_cur','Fin','Fev','Ain','Aev','sistema','Nome_social')); | ||
$resultado = $stmt->fetchAll(PDO::FETCH_ASSOC); | ||
foreach($resultado as $item){ | ||
$this->id = $item['id']; | ||
$this->Cod_cur = $item['Cod_cur']; | ||
$this->Num_mat = $item['Num_mat']; | ||
$this->Nome_civil = $item['Nome_civil']; | ||
$this->Nome_cur = $item['Nome_cur']; | ||
$this->Fin = $item['Fin']; | ||
$this->Fev = $item['Fev']; | ||
$this->Ain = $item['Ain']; | ||
$this->Aev = $item['Aev']; | ||
$this->sistema = $item['sistema']; | ||
$this->Nome_social = $item['Nome_social']; | ||
|
||
} | ||
} | ||
function exibir(){ | ||
if($this->cont == 1){ | ||
echo "<div id='dadosal'> | ||
<label style='color:#FE642E;' >Nome civil:  </label> | ||
<label> $this->Nome_civil </label><br> | ||
<label style='color:#FE642E;'>Nome social:  </label> | ||
<label>$this->Nome_social</label><br> | ||
<label style='color:#FE642E;' >Matrícula:  </label> | ||
<label> $this->Num_mat      </label> | ||
<label style='color:#FE642E;'>Curso:  </label> | ||
<label>$this->Cod_cur--   </label> | ||
<label>$this->Nome_cur</label><br> | ||
<label style='color:#FE642E;'>Forma de ingresso:  </label> | ||
<label >$this->Fin    |  </label> | ||
<label style='color:#FE642E;'>Ano de ingresso:  </label> | ||
<label >$this->Ain</label><br> | ||
<label style='color:#FE642E;'>Forma de evasão:  </label> | ||
<label>$this->Fev   |  </label> | ||
<label style='color:#FE642E; '>Ano de evsão:  </label> | ||
<label>$this->Aev   |  </label> | ||
<label style='color:#FE642E';>Dados retirados do:  </label> | ||
<label>$this->sistema</label><br> | ||
</div>"; | ||
}else{ | ||
echo "<script>window.location.href='psq_nome.php?nun=$this->matricula'</script>"; | ||
} | ||
|
||
} | ||
} | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
<?php | ||
class Alunos_nome{ | ||
private $nome,$matricula,$tb; | ||
function getTb(){ | ||
return $this->tb; | ||
} | ||
function getNome(){ | ||
return $this->nome; | ||
} | ||
function getMatricula(){ | ||
return $this->matricula; | ||
} | ||
function pesquisa_nome($nome){ | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
$stmt = $pdo->prepare("SELECT * FROM Alunos WHERE Nome_civil LIKE '%$nome%' OR Nome_social LIKE '%$nome%' ORDER BY Num_mat ASC"); | ||
$stmt->execute(array('id','Cod_cur','Num_mat','Nome_civil','Nome_cur','Nome_social')); | ||
$resultado = $stmt->fetchAll(PDO::FETCH_ASSOC); | ||
foreach($resultado as $item){ | ||
$this->tb .= "<tr> | ||
<td style='display:none;'>".$item['id']."</td> | ||
<td style='font-size:17px;'>".$item['Cod_cur']."-->".$item['Nome_cur']."</td> | ||
<td style='font-size:17px;'>".$item['Num_mat']."</td> | ||
<td style='font-size:17px;'>".$item['Nome_civil']."</td> | ||
<td style='font-size:15px;'>".$item['Nome_social']."</td> | ||
</tr>"; | ||
} | ||
|
||
} | ||
function pesquisa_matricula($matricula){ | ||
$this->matricula = $matricula; | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
$stmt = $pdo->prepare("SELECT * FROM Alunos WHERE Num_mat LIKE '$matricula%' ORDER BY Num_mat ASC"); | ||
$stmt->execute(array('id','Cod_cur','Num_mat','Nome_civil','Nome_cur','Nome_social')); | ||
$resultado = $stmt->fetchAll(PDO::FETCH_ASSOC); | ||
foreach($resultado as $item){ | ||
$this->tb .= "<tr> | ||
<td style='display:none;'>".$item['id']."</td> | ||
<td style='font-size:17px;'>".$item['Cod_cur']."-->".$item['Nome_cur']."</td> | ||
<td style='font-size:17px;'>".$item['Num_mat']."</td> | ||
<td style='font-size:17px;'>".$item['Nome_civil']."</td> | ||
<td style='font-size:15px;'>".$item['Nome_social']."</td> | ||
</tr>"; | ||
} | ||
|
||
} | ||
|
||
function exibir_tabela(){ | ||
echo " | ||
<table id='minhaTabela'> | ||
<thead class='cabecalj'> | ||
<tr> | ||
<th style='display:none;'>ID</th> | ||
<th>Curso</th> | ||
<th>Matricula</th> | ||
<th>Nome Civil</th> | ||
<th>Nome Social</th> | ||
<tr> | ||
</thead> | ||
<tbody> | ||
$this->tb | ||
</tbody> | ||
</table>"; | ||
} | ||
} | ||
|
||
|
||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?php | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
<?php | ||
class Tabela{ | ||
private $id,$im,$di,$td,$cd,$ad,$tb,$no; | ||
function setId($id){ | ||
$this->id = $id; | ||
} | ||
function getIm(){ | ||
return $this->im; | ||
} | ||
function setIm($im){ | ||
$this->im = $im; | ||
} | ||
function getId(){ | ||
return $this->id; | ||
} | ||
function pesquisa_doc(){ | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
$stmt = $pdo->prepare("SELECT * FROM Ko WHERE imagem LIKE '$this->im' ORDER BY ano_doc ASC"); | ||
$stmt->execute(array('id','data_inserido','tipo_doc','class_doc','nome','ano_doc')); | ||
$resultado = $stmt->fetchAll(PDO::FETCH_ASSOC); | ||
foreach($resultado as $item){ | ||
$this->tb .= "<tr> | ||
<td style='display:none;'>".$item['id']."</td> | ||
<td style='font-size:17px;'>".$item['tipo_doc']."</td> | ||
<td style='font-size:17px;'>".$item['class_doc']."</td> | ||
<td style='font-size:17px;'>".$item['nome']."</td> | ||
<td style='font-size:15px;'>".$item['ano_doc']."</td> | ||
<td>".$item['data_inserido']."</td> | ||
</tr>"; | ||
} | ||
} | ||
function pesquisa_doc2($id,$im){ | ||
$this->id = $id; | ||
$this->im = $im; | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
$stmt = $pdo->prepare("SELECT * FROM Ko WHERE id LIKE '$this->id' ORDER BY ano_doc ASC"); | ||
$stmt->execute(array('id','tipo_doc','class_doc','nome','ano_doc','data_inserido')); | ||
$resultado = $stmt->fetchAll(PDO::FETCH_ASSOC); | ||
foreach($resultado as $item){ | ||
|
||
$this->id = $item['id']; | ||
$this->td = $item['tipo_doc']; | ||
$this->cd=$item['class_doc']; | ||
$this->no=$item['nome']; | ||
$this->ad=$item['ano_doc']; | ||
$this->di=$item['data_inserido']; | ||
|
||
} | ||
} | ||
function exibir_dados(){ | ||
$data=date('Y-m-d'); | ||
$par = explode('-',$data); | ||
|
||
$en = "window.location.href='pg_res_pes_mat.php?alid=$this->im'"; | ||
echo "<div id='alter-doc'> | ||
<form method='POST' action='alterar_documento.php?id=$this->id&alid=$this->im'> | ||
<label>Classificação do documento: </label> | ||
<input type='text' name='classfi' id='assunto' placeholder='Pesquisar tipo de documento' value='$this->td' required><br><br> | ||
<label>Tipo de documento</label> | ||
<select name='sele'> | ||
<option>$this->cd</option> | ||
<option>Ficha Cadastral </option> | ||
<option >Processo</option> | ||
<option >Requerimento</option> | ||
<option >TCE</option> | ||
<option >Histórico Escolar</option> | ||
<option >Outro tipo de ficha</option> | ||
<option >Ofício</option> | ||
</select><br><br> | ||
<label>Descrição: </label> | ||
<input type='text' name='descricao' value='$this->no' placeholder='Descreva a modificação'><br><br> | ||
<label>Ano do documento: </label> | ||
<input id='ano' name='ano' value='$this->ad' type='number' min='1900' max='$par[0]' required> | ||
<br><input type='submit' value='Salvar'><br><br> | ||
</form> | ||
<button onclick='funcao1()'>Apagar documento</button><br><br> | ||
<button onclick=".$en.">voltar</button> | ||
</div>"; | ||
$eap = ""; | ||
echo "<script> | ||
function funcao1() | ||
{ | ||
var x; | ||
var r=confirm('Deseja realmente excluí esse documento?' ); | ||
if (r==true) | ||
{ | ||
var x='S'; | ||
} | ||
else | ||
{ | ||
var x='N'; | ||
} | ||
window.location.href='apagar_documento.php?alid=$this->im&iddoc=$this->id&nome='+x; | ||
} | ||
</script>"; | ||
} | ||
function exibir_tabela(){ | ||
echo " | ||
<table id='minhaTabela' class='tabfom'> | ||
<thead class='cabecalj'> | ||
<tr> | ||
<th style='display:none;'>ID</th> | ||
<th>Classificação do <br> documento</th> | ||
<th>Tipo de <br> documento</th> | ||
<th>Descrição</th> | ||
<th>Ano do documento</th> | ||
<th>Inserido em:</th> | ||
<tr> | ||
</thead> | ||
<tbody> | ||
$this->tb | ||
</tbody> | ||
</table>"; | ||
} | ||
|
||
} | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<?php | ||
ini_set('default_charset','UTF-8'); | ||
$db_hos = "localhost"; | ||
$use = "root"; | ||
$pss = ""; | ||
$ban = "Al"; | ||
$conn = new mysqli("$db_hos","$use","$pss","$ban"); | ||
//$conn = mysqli_connect("$db_hos","$use","$pss","$ban"); | ||
$conn -> query(" | ||
SET NAMES UTF8 | ||
"); | ||
|
||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?php | ||
$pdo = new PDO( 'mysql:host=localhost;dbname=Al', 'root', '' ); | ||
$pdo -> query("SET NAMES UTF8"); | ||
?> |
Oops, something went wrong.