Merge pull request #2146 from ntoff/improve/shutdown-serial-reset-warn
Add possible print disruption warning to shutdown dialog
This commit is contained in:
commit
40eb3c1072
3 changed files with 11 additions and 11 deletions
|
|
@ -39,7 +39,7 @@ List all registered system commands
|
|||
"action": "shutdown",
|
||||
"name": "Shutdown",
|
||||
"command": "sudo shutdown -h now",
|
||||
"confirm": "You are about to shutdown the system.",
|
||||
"confirm": "<b>You are about to shutdown the system.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||
"async": true,
|
||||
"ignore": true,
|
||||
"source": "core",
|
||||
|
|
@ -49,7 +49,7 @@ List all registered system commands
|
|||
"action": "reboot",
|
||||
"name": "Reboot",
|
||||
"command": "sudo reboot",
|
||||
"confirm": "You are about to reboot the system.",
|
||||
"confirm": "<b>You are about to reboot the system.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||
"async": true,
|
||||
"ignore": true,
|
||||
"source": "core",
|
||||
|
|
@ -59,7 +59,7 @@ List all registered system commands
|
|||
"action": "restart",
|
||||
"name": "Restart OctoPrint",
|
||||
"command": "sudo service octoprint restart",
|
||||
"confirm": "You are about to restart the OctoPrint server.",
|
||||
"confirm": "<b>You are about to restart the OctoPrint server.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||
"async": true,
|
||||
"ignore": true,
|
||||
"source": "core",
|
||||
|
|
@ -100,7 +100,7 @@ List all registered system commands for a source
|
|||
"action": "shutdown",
|
||||
"name": "Shutdown",
|
||||
"command": "sudo shutdown -h now",
|
||||
"confirm": "You are about to shutdown the system.",
|
||||
"confirm": "<b>You are about to shutdown the system.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||
"async": true,
|
||||
"ignore": true,
|
||||
"source": "core",
|
||||
|
|
@ -110,7 +110,7 @@ List all registered system commands for a source
|
|||
"action": "reboot",
|
||||
"name": "Reboot",
|
||||
"command": "sudo reboot",
|
||||
"confirm": "You are about to reboot the system.",
|
||||
"confirm": "<b>You are about to reboot the system.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||
"async": true,
|
||||
"ignore": true,
|
||||
"source": "core",
|
||||
|
|
@ -120,7 +120,7 @@ List all registered system commands for a source
|
|||
"action": "restart",
|
||||
"name": "Restart OctoPrint",
|
||||
"command": "sudo service octoprint restart",
|
||||
"confirm": "You are about to restart the OctoPrint server.",
|
||||
"confirm": "<b>You are about to restart the OctoPrint server.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).",
|
||||
"async": true,
|
||||
"ignore": true,
|
||||
"source": "core",
|
||||
|
|
|
|||
|
|
@ -731,7 +731,7 @@ $(function() {
|
|||
if (restartClicked) return;
|
||||
restartClicked = true;
|
||||
showConfirmationDialog({
|
||||
message: gettext("This will restart your OctoPrint server."),
|
||||
message: gettext("<b>This will restart your OctoPrint server.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage)."),
|
||||
onproceed: function() {
|
||||
OctoPrint.system.executeCommand("core", "restart")
|
||||
.done(function() {
|
||||
|
|
|
|||
|
|
@ -167,19 +167,19 @@ def _get_core_command_specs():
|
|||
shutdown=dict(
|
||||
command=s().get(["server", "commands", "systemShutdownCommand"]),
|
||||
name=gettext("Shutdown system"),
|
||||
confirm=gettext("You are about to shutdown the system.")),
|
||||
confirm=gettext("<b>You are about to shutdown the system.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).")),
|
||||
reboot=dict(
|
||||
command=s().get(["server", "commands", "systemRestartCommand"]),
|
||||
name=gettext("Reboot system"),
|
||||
confirm=gettext("You are about to reboot the system.")),
|
||||
confirm=gettext("<b>You are about to reboot the system.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).")),
|
||||
restart=dict(
|
||||
command=s().get(["server", "commands", "serverRestartCommand"]),
|
||||
name=gettext("Restart OctoPrint"),
|
||||
confirm=gettext("You are about to restart the OctoPrint server.")),
|
||||
confirm=gettext("<b>You are about to restart the OctoPrint server.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage).")),
|
||||
restart_safe=dict(
|
||||
command=s().get(["server", "commands", "serverRestartCommand"]),
|
||||
name=gettext("Restart OctoPrint in safe mode"),
|
||||
confirm=gettext("You are about to restart the OctoPrint server in safe mode."),
|
||||
confirm=gettext("<b>You are about to restart the OctoPrint server in safe mode.</b></p><p> This action may disrupt any ongoing print jobs (depending on your printer's controller and general setup that might also apply to prints run directly from your printer's internal storage)."),
|
||||
before=enable_safe_mode)
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue