diff --git a/datamodels/2.x/itop-core-update/en.dict.itop-core-update.php b/datamodels/2.x/itop-core-update/en.dict.itop-core-update.php index 72288f7cf..8d3143cba 100644 --- a/datamodels/2.x/itop-core-update/en.dict.itop-core-update.php +++ b/datamodels/2.x/itop-core-update/en.dict.itop-core-update.php @@ -75,6 +75,7 @@ Dict::Add('EN US', 'English', 'English', array( 'iTopUpdate:UI:CanCoreUpdate:Yes' => 'Application can be updated', 'iTopUpdate:UI:CanCoreUpdate:No' => 'Application cannot be updated: %1$s', 'iTopUpdate:UI:CanCoreUpdate:Warning' => 'Warning: application update can fail: %1$s', + 'iTopUpdate:UI:CannotUpdateUseSetup' => 'You must use the setup to update the application.
Some modified files were detected, a partial update cannot be executed.', // Setup Messages 'iTopUpdate:UI:SetupMessage:Ready' => 'Ready to start', diff --git a/datamodels/2.x/itop-core-update/fr.dict.itop-core-update.php b/datamodels/2.x/itop-core-update/fr.dict.itop-core-update.php index 8dae6b928..a0aa2f8fa 100644 --- a/datamodels/2.x/itop-core-update/fr.dict.itop-core-update.php +++ b/datamodels/2.x/itop-core-update/fr.dict.itop-core-update.php @@ -75,6 +75,7 @@ Dict::Add('FR FR', 'French', 'Français', array( 'iTopUpdate:UI:CanCoreUpdate:Yes' => 'L\'application peut être mise à jour', 'iTopUpdate:UI:CanCoreUpdate:No' => 'L\'application ne peut pas être mise à jour : %1$s', 'iTopUpdate:UI:CanCoreUpdate:Warning' => 'Attention : la mise à jour de l\'application peut échouer : %1$s', + 'iTopUpdate:UI:CannotUpdateUseSetup' => 'Vous devez utiliser la page d\'installation pour mettre à jour l\'application.
Des fichiers modifiés ont été détectés, une mise à jour partielle ne peut pas être effectuée.', // Setup Messages 'iTopUpdate:UI:SetupMessage:Ready' => 'Prêt pour l\\installation', diff --git a/datamodels/2.x/itop-core-update/src/Controller/AjaxController.php b/datamodels/2.x/itop-core-update/src/Controller/AjaxController.php index dc33efa7f..8064ea2b0 100644 --- a/datamodels/2.x/itop-core-update/src/Controller/AjaxController.php +++ b/datamodels/2.x/itop-core-update/src/Controller/AjaxController.php @@ -37,7 +37,8 @@ class AjaxController extends Controller } else { - $aParams['sMessage'] = Dict::Format("iTopUpdate:UI:CanCoreUpdate:{$sCanUpdateCore}", $sMessage); + $sLink = utils::GetAbsoluteUrlAppRoot().'setup/'; + $aParams['sMessage'] = Dict::Format('iTopUpdate:UI:CannotUpdateUseSetup', $sLink); } } catch (FileNotExistException $e) { diff --git a/datamodels/2.x/itop-core-update/view/SelectUpdateFile.html.twig b/datamodels/2.x/itop-core-update/view/SelectUpdateFile.html.twig index 09bd5b4ed..eb6f9fbe7 100644 --- a/datamodels/2.x/itop-core-update/view/SelectUpdateFile.html.twig +++ b/datamodels/2.x/itop-core-update/view/SelectUpdateFile.html.twig @@ -54,7 +54,7 @@ -
+
{{ 'iTopUpdate:UI:SelectUpdateFile'|dict_s }}
diff --git a/datamodels/2.x/itop-core-update/view/SelectUpdateFile.ready.js.twig b/datamodels/2.x/itop-core-update/view/SelectUpdateFile.ready.js.twig index f52ac52cb..8b41ce446 100644 --- a/datamodels/2.x/itop-core-update/view/SelectUpdateFile.ready.js.twig +++ b/datamodels/2.x/itop-core-update/view/SelectUpdateFile.ready.js.twig @@ -22,6 +22,9 @@ $.ajax({ } else { + $("#check-update").prop("disabled", true); + $("#file").prop("disabled", true); + $('#form-update-outer').slideUp(600); oRequirements.addClass("message_error"); } }