From e11125ef9e579895d38c5d377ddc87f7885b4a3c Mon Sep 17 00:00:00 2001 From: Javier Sánchez Parra Date: Thu, 20 Jan 2022 08:06:58 +0100 Subject: Rename MSDOS to MBR This commit rename partition table type MSDOS to MBR in the front-end. At the back-end ogCP still uses MSDOS string because ogClient scripts (aka cloning engine) expects it. --- ogcp/forms/action_forms.py | 2 +- ogcp/views.py | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'ogcp') diff --git a/ogcp/forms/action_forms.py b/ogcp/forms/action_forms.py index 44a898f..09197d5 100644 --- a/ogcp/forms/action_forms.py +++ b/ogcp/forms/action_forms.py @@ -61,7 +61,7 @@ class SetupForm(FlaskForm): ips = HiddenField() disk = HiddenField() disk_type = SelectField(label=_l('Type'), - choices=[('MSDOS', 'MSDOS'), + choices=[('MSDOS', 'MBR'), ('GPT', 'GPT')]) partitions = FieldList(FormField(PartitionForm), min_entries=1, diff --git a/ogcp/views.py b/ogcp/views.py index 61e146b..de92430 100644 --- a/ogcp/views.py +++ b/ogcp/views.py @@ -581,6 +581,8 @@ def action_client_info(): images = r.json()['images'] setup = get_client_setup(ips) + if setup and setup[0].get('code') == 'MSDOS': + setup[0]['code'] = 'MBR' for entry in setup: if images and entry['image'] != 0: -- cgit v1.2.3-18-g5258