Commit ef9f8cda34ad64119462e819830b9d298f58b942
1 parent
9e3ab6a5
Exists in
master
and in
7 other branches
--no commit message
Showing
4 changed files
with
30 additions
and
12 deletions
Show diff stats
admin/html/editormapfile.html
... | ... | @@ -46,8 +46,8 @@ |
46 | 46 | </div> |
47 | 47 | <div class="ft"></div> |
48 | 48 | </div> |
49 | - <input onclick="adicionaLinha()" type=button id=adiciona value="Criar um novo mapfile" /> | |
50 | - <input onclick="adicionaLinha()" type=button id=semmapfiles value="Verificar temas sem mapfiles" /> | |
49 | + <input onclick="" type=button id=adiciona value="Criar um novo mapfile" /> | |
50 | + <input onclick="" type=button id=semmapfiles value="Verificar temas sem mapfiles" /> | |
51 | 51 | <br><br> |
52 | 52 | Além de criar os mapfiles, é necessário definir as características de cada LAYER nas opções abaixo. |
53 | 53 | <br> | ... | ... |
admin/js/editormapfile.js
... | ... | @@ -165,7 +165,9 @@ function ativaBotaoAdicionaMapfile(idBotao) |
165 | 165 | var adiciona = function() |
166 | 166 | { |
167 | 167 | core_montaEditor("adicionaNovoMapfile()","450px","660px"); |
168 | - ins = "<p><b>Título do novo tema</b></p>"; | |
168 | + ins = "<p><b>Nome do novo arquivo mapfile (sem .map) </b>não utilize caracteres acentuados ou espaços em branco</p>"; | |
169 | + ins += "<input size=50 type=text id='Ecodigo' value='' /></p>"; | |
170 | + ins += "<p><b>Título do novo tema</b></p>"; | |
169 | 171 | ins += "<p>Em português: </p>"; |
170 | 172 | ins += "<input size=50 type=text id='Etitulo' value='' /></p>"; |
171 | 173 | ins += "<p>Espanhol (opcional): </p>"; |
... | ... | @@ -174,8 +176,6 @@ function ativaBotaoAdicionaMapfile(idBotao) |
174 | 176 | ins += "<input size=50 type=text id='EtituloEN' value='' /></p>"; |
175 | 177 | ins += "<p>Italiano: (opcional)</p>"; |
176 | 178 | ins += "<input size=50 type=text id='EtituloIT' value='' /></p>"; |
177 | - ins += "<p>Nome do arquivo mapfile (sem .map): </p>"; | |
178 | - ins += "<input size=50 type=text id='Ecodigo' value='' /></p>"; | |
179 | 179 | $i("editor_bd").innerHTML = ins; |
180 | 180 | }; |
181 | 181 | //cria o botão de adição de um novo menu | ... | ... |
admin/js/listatemas.js
... | ... | @@ -94,7 +94,7 @@ function montaDivTemas(i) |
94 | 94 | ins += "<select id='ogc_tema' >"; |
95 | 95 | ins += core_combosimnao(i.ogc_tema); |
96 | 96 | ins += "</select></p>"; |
97 | - ins += "<p>Permite o download na aplicação datadownload.htm?<br>"; | |
97 | + ins += "<p>Permite o download na aplicação datadownload.htm? (não afeta a permissão de download definida no item 'disponibilidade' existente em cada layer)<br>"; | |
98 | 98 | ins += "<select id='download_tema' >"; |
99 | 99 | ins += core_combosimnao(i.download_tema); |
100 | 100 | ins += "</select></p>"; | ... | ... |
admin/php/editortexto.php
... | ... | @@ -12,8 +12,8 @@ |
12 | 12 | </style> |
13 | 13 | <link rel="stylesheet" type="text/css" href="../html/admin.css"> |
14 | 14 | </head> |
15 | -<body class=" yui-skin-sam fundoPonto" style="margin:auto"> | |
16 | - | |
15 | +<body class=" yui-skin-sam fundoPonto"> | |
16 | +<center> | |
17 | 17 | <div class="bordaSuperior" > </div> |
18 | 18 | <div class="mascaraPrincipal" id="divGeral" style="width:80%"> |
19 | 19 | <div id=cabecalhoPrincipal ></div> |
... | ... | @@ -22,7 +22,8 @@ |
22 | 22 | <a href="../html/editormapfile.html" target="_self" >Voltar</a><br><br> |
23 | 23 | <form action="editortexto.php?mapfile=<?php echo $_GET["mapfile"];?>" method=post > |
24 | 24 | <input type=submit value="Salvar"/><input type=button value="Testar" onclick="testar()" /><input type=button value="Testar no i3Geo" onclick="abrirI3geo()" /> (Salve antes de testar)<br><br> |
25 | - | |
25 | + <div id="comboMapfiles" >Aguarde...</div> | |
26 | + <br> | |
26 | 27 | <?php |
27 | 28 | //evita erros removendo caracteres PHP |
28 | 29 | if(isset($_POST["texto"])){ |
... | ... | @@ -34,9 +35,6 @@ |
34 | 35 | if(verificaEditores($editores) == "nao") |
35 | 36 | {echo "Vc nao e um editor cadastrado. Apenas os editores definidos em i3geo/ms_configura.php podem acessar o sistema de administracao.";exit;} |
36 | 37 | $mapfile = $locaplic."/temas/".$_GET["mapfile"].".map"; |
37 | - | |
38 | - | |
39 | - | |
40 | 38 | if(!file_exists($mapfile)) |
41 | 39 | {echo "Arquivo $mapfile não existe.";exit;} |
42 | 40 | if($_POST["tipo"] == "gravar"){ |
... | ... | @@ -59,7 +57,27 @@ |
59 | 57 | ?> |
60 | 58 | </form> |
61 | 59 | </div> |
60 | +<script type="text/javascript" src="../js/core.js"></script> | |
61 | +<script src="../../classesjs/classe_util.js" type="text/javascript"></script> | |
62 | 62 | <script> |
63 | +function comboMapfiles(){ | |
64 | + var n = $mapfiles.length, | |
65 | + i,ins; | |
66 | + ins = "<select onchange='mudaMapfile(this)'><option value=''>Edite outro mapfile</option>"; | |
67 | + for(i=0;i<n;i++){ | |
68 | + if($mapfiles[i].extensao === "map"){ | |
69 | + ins += "<option value='"+$mapfiles[i].codigo+"'>"+$mapfiles[i].codigo+" - "+$mapfiles[i].nome+"</optiona>"; | |
70 | + } | |
71 | + } | |
72 | + ins += "</select>"; | |
73 | + $i("comboMapfiles").innerHTML = ins; | |
74 | +}; | |
75 | +core_pegaMapfiles("comboMapfiles()","",""); | |
76 | +function mudaMapfile(obj){ | |
77 | + if(obj.value != ""){ | |
78 | + window.location.href = "editortexto.php?mapfile="+obj.value; | |
79 | + } | |
80 | +} | |
63 | 81 | function testar(){ |
64 | 82 | window.open("../../testamapfile.php?map=<?php echo $_GET["mapfile"]; ?>"); |
65 | 83 | } | ... | ... |