diff --git a/application/controllers/Adif.php b/application/controllers/Adif.php index 7dd8af5f7..005dff640 100644 --- a/application/controllers/Adif.php +++ b/application/controllers/Adif.php @@ -233,7 +233,16 @@ class adif extends CI_Controller { array_push($alladif,$record); }; $record=''; // free memory - $custom_errors = $this->logbook_model->import_bulk($alladif, $this->input->post('station_profile'), $this->input->post('skipDuplicate'), $this->input->post('markClublog'),$this->input->post('markLotw'), $this->input->post('dxccAdif'), $this->input->post('markQrz'), $this->input->post('markHrd'), true, $this->input->post('operatorName'), false, $this->input->post('skipStationCheck')); + try { + $custom_errors = $this->logbook_model->import_bulk($alladif, $this->input->post('station_profile'), $this->input->post('skipDuplicate'), $this->input->post('markClublog'),$this->input->post('markLotw'), $this->input->post('dxccAdif'), $this->input->post('markQrz'), $this->input->post('markHrd'), true, $this->input->post('operatorName'), false, $this->input->post('skipStationCheck')); + } catch (Exception $e) { + log_message('error', 'Import error: '.$e->getMessage()); + $data['page_title'] = __("ADIF Import failed!"); + $this->load->view('interface_assets/header', $data); + $this->load->view('adif/import_failed'); + $this->load->view('interface_assets/footer'); + return; + } } else { // Failure, if no ADIF inside ZIP $data['max_upload'] = ini_get('upload_max_filesize'); $this->load->view('interface_assets/header', $data); diff --git a/application/locale/bg_BG/LC_MESSAGES/messages.po b/application/locale/bg_BG/LC_MESSAGES/messages.po index 4449e31f2..ac8d1f5c8 100644 --- a/application/locale/bg_BG/LC_MESSAGES/messages.po +++ b/application/locale/bg_BG/LC_MESSAGES/messages.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: translations@wavelog.org\n" -"POT-Creation-Date: 2024-08-28 06:24+0000\n" +"POT-Creation-Date: 2024-08-28 11:59+0000\n" "PO-Revision-Date: 2024-08-17 10:46+0000\n" "Last-Translator: Anonymous \n" "Language-Team: Bulgarian \n" "Language-Team: Bosnian \n" "Language-Team: Montenegrin \n" "Language-Team: Czech \n" "Language-Team: German \n" "Language-Team: Greek \n" "Language-Team: Spanish \n" "Language-Team: Finnish \n" "Language-Team: French \n" "Language-Team: Croatian \n" "Language-Team: Italian \n" "Language-Team: Dutch \n" "Language-Team: Polish \n" "Language-Team: Portuguese (Portugal) \n" "Language-Team: Russian \n" "Language-Team: Albanian \n" -"Language-Team: Serbian \n" +"Language-Team: Serbian \n" "Language: sr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -172,20 +172,21 @@ msgstr "Uvoz ADIF" msgid "Unsupported Filetype" msgstr "Nepodržana vrsta datoteke" -#: application/controllers/Adif.php:245 +#: application/controllers/Adif.php:245 application/controllers/Adif.php:254 msgid "Station Profile not valid for User" msgstr "Profil stanice nije validan za ovog korisnika" #: application/controllers/Adif.php:252 #: application/views/adif/import_success.php:12 +#: application/controllers/Adif.php:261 msgid "ADIF Imported" msgstr "ADIF uvezen" -#: application/controllers/Adif.php:263 +#: application/controllers/Adif.php:263 application/controllers/Adif.php:272 msgid "DCL Import" msgstr "Uvoz DCL" -#: application/controllers/Adif.php:319 +#: application/controllers/Adif.php:319 application/controllers/Adif.php:328 msgid "DCL Data Imported" msgstr "DCL podaci uvezeni" @@ -11648,6 +11649,22 @@ msgstr "" msgid "Submit Request" msgstr "" +#: application/controllers/Adif.php:240 +#: application/views/adif/import_failed.php:12 +msgid "ADIF Import failed!" +msgstr "" + +#: application/views/adif/import_failed.php:15 +msgid "The ADIF file could not be parsed correctly." +msgstr "" + +#: application/views/adif/import_failed.php:16 +msgid "" +"At least one of the ADIF fields could not be parsed and/or inserted into the " +"database. Please check the imported ADIF file. You can use an online ADIF " +"file checker. For example:" +msgstr "" + #, php-format #~ msgctxt "Dashboard Warning" #~ msgid "You need to update country files! Click %s to do it." diff --git a/application/locale/sv_SE/LC_MESSAGES/messages.po b/application/locale/sv_SE/LC_MESSAGES/messages.po index 9db26886c..9ec4d720e 100644 --- a/application/locale/sv_SE/LC_MESSAGES/messages.po +++ b/application/locale/sv_SE/LC_MESSAGES/messages.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: translations@wavelog.org\n" -"POT-Creation-Date: 2024-08-28 06:24+0000\n" +"POT-Creation-Date: 2024-08-28 11:59+0000\n" "PO-Revision-Date: 2024-08-17 10:48+0000\n" "Last-Translator: Anonymous \n" "Language-Team: Swedish \n" "Language-Team: Turkish \n" "Language-Team: Chinese (Simplified) +
+ session->flashdata('message')) { ?> + +
+

session->flashdata('message'); ?>

+
+ + + + + + diff --git a/assets/lang_src/messages.pot b/assets/lang_src/messages.pot index 8df1c2e67..d35abb30b 100644 --- a/assets/lang_src/messages.pot +++ b/assets/lang_src/messages.pot @@ -6,7 +6,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: translations@wavelog.org\n" -"POT-Creation-Date: 2024-08-28 06:24+0000\n" +"POT-Creation-Date: 2024-08-28 11:59+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -167,20 +167,25 @@ msgstr "" msgid "Unsupported Filetype" msgstr "" -#: application/controllers/Adif.php:245 +#: application/controllers/Adif.php:240 +#: application/views/adif/import_failed.php:12 +msgid "ADIF Import failed!" +msgstr "" + +#: application/controllers/Adif.php:254 msgid "Station Profile not valid for User" msgstr "" -#: application/controllers/Adif.php:252 +#: application/controllers/Adif.php:261 #: application/views/adif/import_success.php:12 msgid "ADIF Imported" msgstr "" -#: application/controllers/Adif.php:263 +#: application/controllers/Adif.php:272 msgid "DCL Import" msgstr "" -#: application/controllers/Adif.php:319 +#: application/controllers/Adif.php:328 msgid "DCL Data Imported" msgstr "" @@ -3344,6 +3349,17 @@ msgid "" "will be displayed." msgstr "" +#: application/views/adif/import_failed.php:15 +msgid "The ADIF file could not be parsed correctly." +msgstr "" + +#: application/views/adif/import_failed.php:16 +msgid "" +"At least one of the ADIF fields could not be parsed and/or inserted into the " +"database. Please check the imported ADIF file. You can use an online ADIF " +"file checker. For example:" +msgstr "" + #: application/views/adif/import_success.php:15 msgid "Yay, its imported!" msgstr ""