@@ -172,7 +172,7 @@ discard block |
||
172 | 172 | } elseif (strpos($info['start_date'], '0000') === false) { |
173 | 173 | $yearStart = date("Y", strtotime($info['start_date'])); |
174 | 174 | } else { |
175 | - $yearStart = date("Y"); |
|
175 | + $yearStart = date("Y"); |
|
176 | 176 | } |
177 | 177 | if ($info['end_date'] != "0000-00-00" && $info['end_date'] != NULL) { |
178 | 178 | $tpl->assign('day_end', date("j", strtotime($info['end_date']))); |
@@ -182,7 +182,7 @@ discard block |
||
182 | 182 | } elseif (strpos($info['end_date'], '0000') === false) { |
183 | 183 | $yearEnd = date("Y", strtotime($info['end_date'])); |
184 | 184 | } else { |
185 | - $yearEnd = date("Y"); |
|
185 | + $yearEnd = date("Y"); |
|
186 | 186 | } |
187 | 187 | $tpl->assign('new_action', '0'); |
188 | 188 | } |
@@ -195,7 +195,7 @@ discard block |
||
195 | 195 | } |
196 | 196 | $yearStart -= 5; |
197 | 197 | $yearEnd += 5; |
198 | - $fin_rango_anio = (($yearStart + 15) < $yearEnd) ? ($yearEnd+1):($yearStart +15); |
|
198 | + $fin_rango_anio = (($yearStart + 15) < $yearEnd) ? ($yearEnd + 1) : ($yearStart + 15); |
|
199 | 199 | while ($yearStart <= $fin_rango_anio) { |
200 | 200 | $yearList[] = $yearStart; |
201 | 201 | $yearStart++; |
@@ -216,5 +216,5 @@ discard block |
||
216 | 216 | $tpl->assign('content', $content); |
217 | 217 | $tpl->display_one_col_template(); |
218 | 218 | } else { |
219 | - header('Location:' . api_get_path(WEB_PATH)); |
|
219 | + header('Location:'.api_get_path(WEB_PATH)); |
|
220 | 220 | } |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | $plugin = SepePlugin::create(); |
13 | 13 | $_cid = 0; |
14 | 14 | |
15 | -if ( !empty($_POST)) { |
|
15 | +if (!empty($_POST)) { |
|
16 | 16 | $check = Security::check_token('post'); |
17 | 17 | if ($check) { |
18 | 18 | $centerOrigin = Database::escape_string(trim($_POST['center_origin'])); |
@@ -132,7 +132,7 @@ discard block |
||
132 | 132 | } |
133 | 133 | $startYear -= 5; |
134 | 134 | $endYear += 5; |
135 | - $endRangeYear = (($startYear + 15) < $endYear) ? ($endYear+1):($startYear +15); |
|
135 | + $endRangeYear = (($startYear + 15) < $endYear) ? ($endYear + 1) : ($startYear + 15); |
|
136 | 136 | while ($startYear <= $endRangeYear) { |
137 | 137 | $listYears[] = $startYear; |
138 | 138 | $startYear++; |
@@ -154,5 +154,5 @@ discard block |
||
154 | 154 | $tpl->assign('content', $content); |
155 | 155 | $tpl->display_one_col_template(); |
156 | 156 | } else { |
157 | - header('Location:' . api_get_path(WEB_PATH)); |
|
157 | + header('Location:'.api_get_path(WEB_PATH)); |
|
158 | 158 | } |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | require_once '../config.php'; |
10 | 10 | $plugin = SepePlugin::create(); |
11 | 11 | |
12 | -if ( !empty($_POST)) { |
|
12 | +if (!empty($_POST)) { |
|
13 | 13 | $check = Security::check_token('post'); |
14 | 14 | if ($check) { |
15 | 15 | $centerOrigin = Database::escape_string(trim($_POST['center_origin'])); |
@@ -89,5 +89,5 @@ discard block |
||
89 | 89 | $tpl->assign('content', $content); |
90 | 90 | $tpl->display_one_col_template(); |
91 | 91 | } else { |
92 | - header('Location:' . api_get_path(WEB_PATH)); |
|
92 | + header('Location:'.api_get_path(WEB_PATH)); |
|
93 | 93 | } |
@@ -4,7 +4,7 @@ |
||
4 | 4 | * Config the plugin |
5 | 5 | * @package chamilo.plugin.sepe |
6 | 6 | */ |
7 | -require_once __DIR__ . '/config.php'; |
|
7 | +require_once __DIR__.'/config.php'; |
|
8 | 8 | |
9 | 9 | if (!api_is_platform_admin()) { |
10 | 10 | die ('You must have admin permissions to install plugins'); |
@@ -7,7 +7,7 @@ |
||
7 | 7 | * @package chamilo.plugin.sepe |
8 | 8 | */ |
9 | 9 | |
10 | -require_once __DIR__ . '/../../main/inc/global.inc.php'; |
|
10 | +require_once __DIR__.'/../../main/inc/global.inc.php'; |
|
11 | 11 | require_once api_get_path(LIBRARY_PATH).'plugin.class.php'; |
12 | 12 | |
13 | 13 | require_once 'src/sepe.lib.php'; |
@@ -84,7 +84,7 @@ discard block |
||
84 | 84 | } |
85 | 85 | } |
86 | 86 | |
87 | -function authenticate($WSUser,$WSKey) |
|
87 | +function authenticate($WSUser, $WSKey) |
|
88 | 88 | { |
89 | 89 | $tUser = Database::get_main_table(TABLE_MAIN_USER); |
90 | 90 | $tApi = Database::get_main_table(TABLE_MAIN_USER_API_KEY); |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | $s = new WSSESoapServer($doc); |
116 | 116 | |
117 | 117 | if (!empty($WSUser) && !empty($WSKey)) { |
118 | - if (authenticate($WSUser,$WSKey)) { |
|
118 | + if (authenticate($WSUser, $WSKey)) { |
|
119 | 119 | // pointing to the current file here |
120 | 120 | $options = array( |
121 | 121 | 'soap_version' => SOAP_1_1 |
@@ -6,5 +6,5 @@ |
||
6 | 6 | * @author Julio Montoya <[email protected]> |
7 | 7 | * @package chamilo.plugin.sepe |
8 | 8 | */ |
9 | -require_once __DIR__ . '/config.php'; |
|
10 | -require_once __DIR__ . '/src/index.sepe.php'; |
|
9 | +require_once __DIR__.'/config.php'; |
|
10 | +require_once __DIR__.'/src/index.sepe.php'; |
@@ -9,5 +9,5 @@ |
||
9 | 9 | /** |
10 | 10 | * Queries |
11 | 11 | */ |
12 | -require_once __DIR__ . '/config.php'; |
|
12 | +require_once __DIR__.'/config.php'; |
|
13 | 13 | SepePlugin::create()->uninstall(); |
@@ -752,7 +752,7 @@ discard block |
||
752 | 752 | $fieldtype = '3'; |
753 | 753 | $fieldtitle = 'Género'; |
754 | 754 | $fielddefault = ''; |
755 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
755 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
756 | 756 | $sql = "INSERT INTO extra_field_options (field_id, option_value, display_text, option_order) VALUES ('".$field_id."', 'Hombre', 'Hombre',1);"; |
757 | 757 | Database::query($sql); |
758 | 758 | $sql = "INSERT INTO extra_field_options (field_id, option_value, display_text, option_order) VALUES ('".$field_id."', 'Mujer', 'Mujer',2);"; |
@@ -764,28 +764,28 @@ discard block |
||
764 | 764 | $fieldtype = '6'; |
765 | 765 | $fieldtitle = 'Fecha de nacimiento'; |
766 | 766 | $fielddefault = ''; |
767 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
767 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
768 | 768 | |
769 | 769 | $fieldlabel = 'nivel_formativo'; |
770 | 770 | $fieldtype = '1'; |
771 | 771 | $fieldtitle = 'Nivel formativo'; |
772 | 772 | $fielddefault = ''; |
773 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
773 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
774 | 774 | |
775 | 775 | $fieldlabel = 'situacion_laboral'; |
776 | 776 | $fieldtype = '1'; |
777 | 777 | $fieldtitle = 'Situación Laboral'; |
778 | 778 | $fielddefault = ''; |
779 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
779 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
780 | 780 | |
781 | 781 | $fieldlabel = 'provincia_residencia'; |
782 | 782 | $fieldtype = '4'; |
783 | 783 | $fieldtitle = 'Provincia Residencia'; |
784 | 784 | $fielddefault = ''; |
785 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
785 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
786 | 786 | |
787 | 787 | $provinces = 'Albacete;Alicante/Alacant;Almería;Araba/Álava;Asturias;Ávila;Badajoz;Balears, Illes;Barcelona;Bizkaia;Burgos;Cáceres;Cádiz;Cantabria;Castellón/Castelló;Ciudad Real;Córdoba;Coruña, A;Cuenca;Gipuzkoa;Girona;Granada;Guadalajara;Huelva;Huesca;Jaén;León;Lleida;Lugo;Madrid;Málaga;Murcia;Navarra;Ourense;Palencia;Palmas, Las;Pontevedr;Rioja, La;Salamanca;Santa Cruz de Tenerife;Segovia;Sevilla;Soria;Tarragona;Teruel;Toledo;Valencia/Valéncia;Valladolid;Zamora;Zaragoza;Ceuta;Melilla'; |
788 | -$list_provinces = explode(';',$provinces); |
|
788 | +$list_provinces = explode(';', $provinces); |
|
789 | 789 | $i = 1; |
790 | 790 | foreach ($list_provinces as $value) { |
791 | 791 | $sql = "INSERT INTO extra_field_options (field_id, option_value, display_text, option_order) VALUES ('".$field_id."', '".$i."', '".$value."','".$i."');"; |
@@ -797,9 +797,9 @@ discard block |
||
797 | 797 | $fieldtype = '4'; |
798 | 798 | $fieldtitle = 'Comunidad autonoma de residencia'; |
799 | 799 | $fielddefault = ''; |
800 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
800 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
801 | 801 | $ccaa = ';Andalucía;Aragón;Asturias, Principado de;Balears, Illes;Canarias;Cantabria;Castilla y León;Castilla - La Mancha;Cataluña;Comunitat Valenciana;Extremadura;Galicia;Madrid, Comunidad de;Murcia, Región de;Navarra, Comunidad Foral de;País Vasco;Rioja, La;Ceuta;Melilla'; |
802 | -$list_ccaa = explode(';',$ccaa); |
|
802 | +$list_ccaa = explode(';', $ccaa); |
|
803 | 803 | $i = 1; |
804 | 804 | foreach ($list_ccaa as $value) { |
805 | 805 | $sql = "INSERT INTO extra_field_options (field_id, option_value, display_text, option_order) VALUES ('".$field_id."', '".$i."', '".$value."','".$i."');"; |
@@ -812,7 +812,7 @@ discard block |
||
812 | 812 | $fieldtitle = 'Provincia Trabajo'; |
813 | 813 | $fielddefault = ''; |
814 | 814 | //$fieldoptions = ';Albacete;Alicante/Alacant;Almería;Araba/Álava;Asturias;Ávila;Badajoz;Balears, Illes;Barcelona;Bizkaia;Burgos;Cáceres;Cádiz;Cantabria;Castellón/Castelló;Ciudad Real;Córdoba;Coruña, A;Cuenca;Gipuzkoa;Girona;Granada;Guadalajara;Huelva;Huesca;Jaén;León;Lleida;Lugo;Madrid;Málaga;Murcia;Navarra;Ourense;Palencia;Palmas, Las;Pontevedr;Rioja, La;Salamanca;Santa Cruz de Tenerife;Segovia;Sevilla;Soria;Tarragona;Teruel;Toledo;Valencia/Valéncia;Valladolid;Zamora;Zaragoza;Ceuta;Melilla'; |
815 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
815 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
816 | 816 | $i = 1; |
817 | 817 | foreach ($list_provincias as $value) { |
818 | 818 | $sql = "INSERT INTO extra_field_options (field_id, option_value, display_text, option_order) VALUES ('".$field_id."', '".$i."', '".$value."','".$i."');"; |
@@ -825,7 +825,7 @@ discard block |
||
825 | 825 | $fieldtitle = 'Comunidad autonoma Trabajo'; |
826 | 826 | $fielddefault = ''; |
827 | 827 | //$fieldoptions = ';Andalucía;Aragón;Asturias, Principado de;Balears, Illes;Canarias;Cantabria;Castilla y León;Castilla - La Mancha;Cataluña;Comunitat Valenciana;Extremadura;Galicia;Madrid, Comunidad de;Murcia, Región de;Navarra, Comunidad Foral de;País Vasco;Rioja, La;Ceuta;Melilla'; |
828 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
828 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
829 | 829 | $i = 1; |
830 | 830 | foreach ($list_ccaa as $value) { |
831 | 831 | $sql = "INSERT INTO extra_field_options (field_id, option_value, display_text, option_order) VALUES ('".$field_id."', '".$i."', '".$value."','".$i."');"; |
@@ -837,40 +837,40 @@ discard block |
||
837 | 837 | $fieldtype = '2'; |
838 | 838 | $fieldtitle = 'Medio de conocimiento Acción formativa'; |
839 | 839 | $fielddefault = ''; |
840 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
840 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
841 | 841 | |
842 | 842 | $fieldlabel = 'experiencia_anterior'; |
843 | 843 | $fieldtype = '2'; |
844 | 844 | $fieldtitle = 'Experiencia anterior en la realización de cursos on-line'; |
845 | 845 | $fielddefault = ''; |
846 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
846 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
847 | 847 | |
848 | 848 | $fieldlabel = 'razones_teleformacion'; |
849 | 849 | $fieldtype = '2'; |
850 | 850 | $fieldtitle = 'Razones por la modalidad teleformación'; |
851 | 851 | $fielddefault = ''; |
852 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
852 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
853 | 853 | |
854 | 854 | $fieldlabel = 'valoracion_modalidad'; |
855 | 855 | $fieldtype = '2'; |
856 | 856 | $fieldtitle = 'Valoración general sobre la modalidad'; |
857 | 857 | $fielddefault = ''; |
858 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
858 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
859 | 859 | |
860 | 860 | $fieldlabel = 'categoria_profesional'; |
861 | 861 | $fieldtype = '1'; |
862 | 862 | $fieldtitle = 'Categoría profesional'; |
863 | 863 | $fielddefault = ''; |
864 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
864 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
865 | 865 | |
866 | 866 | $fieldlabel = 'tamano_empresa'; |
867 | 867 | $fieldtype = '1'; |
868 | 868 | $fieldtitle = 'Tamaño de la empresa'; |
869 | 869 | $fielddefault = ''; |
870 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
870 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |
|
871 | 871 | |
872 | 872 | $fieldlabel = 'horario_accion_formativa'; |
873 | 873 | $fieldtype = '1'; |
874 | 874 | $fieldtitle = 'Horario de la acción formativa'; |
875 | 875 | $fielddefault = ''; |
876 | -$field_id = UserManager::create_extra_field($fieldlabel,$fieldtype,$fieldtitle,$fielddefault); |
|
876 | +$field_id = UserManager::create_extra_field($fieldlabel, $fieldtype, $fieldtitle, $fielddefault); |