variables.php 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  1. <?php
  2. /*
  3. * Copyright (C) 2021 Ángel Benítez Hernández, Echedey López Romero
  4. *
  5. * This program is free software: you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License as published by
  7. * the Free Software Foundation, either version 3 of the License, or
  8. * (at your option) any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU General Public License
  16. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. $Resultado = '';
  19. $Errores = [];
  20. $Respuestas = [
  21. // Datos de representación
  22. 'representacion' => '',
  23. // Datos personales
  24. 'documento' => '',
  25. 'identificacion' => '',
  26. 'nombre' => '',
  27. 'primer_apellido' => '',
  28. 'segundo_apellido' => '',
  29. 'calidad_de' => '',
  30. 'telefono_fijo' => '',
  31. 'telefono_movil' => '',
  32. 'email' => '',
  33. // Domicilio de contacto
  34. 'tipo_via' => '',
  35. 'nombre_via' => '',
  36. 'numero' => '',
  37. 'bloque' => '',
  38. 'escalera' => '',
  39. 'piso' => '',
  40. 'portal' => '',
  41. 'letra' => '',
  42. 'puerta' => '',
  43. 'complemento' => '',
  44. 'fecha' => '',
  45. 'pais' => '',
  46. 'provincia' => '',
  47. 'isla' => '',
  48. 'municipio' => '',
  49. 'localidad' => '',
  50. 'cp' => '',
  51. // Datos extra
  52. 'horfandad' => 'no',
  53. 'tutela_guarda' => 'no',
  54. // Datos alergias
  55. 'observaciones' => '',
  56. // Datos académicos
  57. 'itinerario' => '',
  58. 'lengua_literatura_1' => 'no',
  59. 'filosofia' => 'no',
  60. 'ed_fisica' => 'no',
  61. 'matematicas_1' => 'no',
  62. 'fisica_quimica' => 'no',
  63. 'tutoria' => 'no',
  64. 'optativa_1' => '',
  65. 'optativa_2' => '',
  66. 'optativa_3' => '',
  67. 'optativa_4' => '',
  68. // Medios de difusión
  69. 'tratamiento' => '',
  70. 'difusion_web' => '',
  71. 'difusion_app' => '',
  72. 'difusion_facebook' => '',
  73. 'fichero_identificacion' => '',
  74. 'fichero_certificacion' => ''
  75. ];
  76. $Documentos = [
  77. [
  78. 'id' => 'nif',
  79. 'nombre' => 'NIF'
  80. ],
  81. [
  82. 'id' => 'nie',
  83. 'nombre' => 'NIE'
  84. ]
  85. ];
  86. $Calidades = [
  87. [
  88. 'id' => 'estudiante',
  89. 'nombre' => 'Estudiante'
  90. ],
  91. [
  92. 'id' => 'guarda_hecho',
  93. 'nombre' => 'Guarda de hecho'
  94. ],
  95. [
  96. 'id' => 'patria_potestad',
  97. 'nombre' => 'Patria potestad'
  98. ],
  99. [
  100. 'id' => 'representante_voluntario',
  101. 'nombre' => 'Representante voluntario'
  102. ],
  103. [
  104. 'id' => 'representante_legal',
  105. 'nombre' => 'Representante legal'
  106. ]
  107. ];
  108. $TiposVia = [
  109. [
  110. 'id' => 'avenida',
  111. 'nombre' => 'Avenida'
  112. ],
  113. [
  114. 'id' => 'calle',
  115. 'nombre' => 'Calle'
  116. ],
  117. [
  118. 'id' => 'carretera',
  119. 'nombre' => 'Carretera'
  120. ],
  121. [
  122. 'id' => 'otros',
  123. 'nombre' => 'Otros'
  124. ],
  125. [
  126. 'id' => 'paseo',
  127. 'nombre' => 'Paseo'
  128. ],
  129. [
  130. 'id' => 'plaza',
  131. 'nombre' => 'Plaza'
  132. ],
  133. [
  134. 'id' => 'ronda',
  135. 'nombre' => 'Ronda'
  136. ],
  137. [
  138. 'id' => 'travesia',
  139. 'nombre' => 'Travesía'
  140. ],
  141. [
  142. 'id' => 'urbanizacion',
  143. 'nombre' => 'Urbanización'
  144. ]
  145. ];
  146. $Paises = [
  147. [
  148. 'id' => 'espania',
  149. 'nombre' => 'España'
  150. ]
  151. ];
  152. $FiltroProvincias = [
  153. [
  154. 'provincia_id' => '35'
  155. ],
  156. [
  157. 'provincia_id' => '38'
  158. ]
  159. ];
  160. $Provincias = DatosCanarias('./datos/provincias.json', $FiltroProvincias, 'provincia_id');
  161. $Islas = DatosCanarias('./datos/islas.json', $Provincias, 'provincia_id');
  162. $Municipios = DatosCanarias('./datos/municipios_islas.json', $Provincias, 'provincia_id');
  163. $Localidades = DatosCanarias('./datos/localidades_islas.json', $Provincias, 'provincia_id', true, 'localidad_id');
  164. $CPs = DatosCanarias('./datos/codigos_postales_municipios.json', $Municipios, 'municipio_id', true, 'cp_id');