Commit e8587452a60a0e73eafd0a52c2395c3aca2a11bd
1 parent
f54fe0f7
Exists in
master
Alterado cadastro de histórico escolar
Corrigido para que seja carregado corretamente estado e país na edição; portabilis/ieducar#52
Showing
2 changed files
with
4 additions
and
2 deletions
Show diff stats
ieducar/intranet/educar_historico_escolar_cad.php
| @@ -181,6 +181,7 @@ class indice extends clsCadastro | @@ -181,6 +181,7 @@ class indice extends clsCadastro | ||
| 181 | $this->campoTexto( "escola", "Escola", $this->escola, 30, 255, true ); | 181 | $this->campoTexto( "escola", "Escola", $this->escola, 30, 255, true ); |
| 182 | $this->campoTexto( "escola_cidade", "Cidade da Escola", $this->escola_cidade, 30, 255, true ); | 182 | $this->campoTexto( "escola_cidade", "Cidade da Escola", $this->escola_cidade, 30, 255, true ); |
| 183 | 183 | ||
| 184 | + $det_uf[] = array(); | ||
| 184 | 185 | ||
| 185 | if($this->escola_uf) | 186 | if($this->escola_uf) |
| 186 | { | 187 | { |
| @@ -198,10 +199,10 @@ class indice extends clsCadastro | @@ -198,10 +199,10 @@ class indice extends clsCadastro | ||
| 198 | $lista_pais_origem[$pais["idpais"]] = $pais["nome"]; | 199 | $lista_pais_origem[$pais["idpais"]] = $pais["nome"]; |
| 199 | } | 200 | } |
| 200 | } | 201 | } |
| 201 | - $this->campoLista("idpais", "País da Escola", $lista_pais_origem, $det_uf['45'] ); | 202 | + $this->campoLista("idpais", "País da Escola", $lista_pais_origem, $det_uf['int_idpais'] ); |
| 202 | 203 | ||
| 203 | $obj_uf = new clsUf(); | 204 | $obj_uf = new clsUf(); |
| 204 | - $lista_uf = $obj_uf->lista( false,false,$det_uf['idpais'],false,false, "sigla_uf" ); | 205 | + $lista_uf = $obj_uf->lista( false,false,$det_uf['int_idpais'],false,false, "sigla_uf" ); |
| 205 | $lista_estado = array( "SC" => "Selecione um país" ); | 206 | $lista_estado = array( "SC" => "Selecione um país" ); |
| 206 | if( $lista_uf ) | 207 | if( $lista_uf ) |
| 207 | { | 208 | { |
ieducar/intranet/include/pessoa/clsUf.inc.php
| @@ -235,6 +235,7 @@ class clsUf | @@ -235,6 +235,7 @@ class clsUf | ||
| 235 | $this->geom = $tupla["geom"]; | 235 | $this->geom = $tupla["geom"]; |
| 236 | $this->idpais = $tupla["idpais"]; | 236 | $this->idpais = $tupla["idpais"]; |
| 237 | 237 | ||
| 238 | + $tupla["int_idpais"] = $tupla["idpais"]; | ||
| 238 | $tupla["idpais"] = new clsPais( $tupla["idpais"] ); | 239 | $tupla["idpais"] = new clsPais( $tupla["idpais"] ); |
| 239 | 240 | ||
| 240 | return $tupla; | 241 | return $tupla; |