diff --git a/openstack_dashboard/dashboards/admin/volumes/snapshots/views.py b/openstack_dashboard/dashboards/admin/volumes/snapshots/views.py index 057f7577ec..65ed50b067 100644 --- a/openstack_dashboard/dashboards/admin/volumes/snapshots/views.py +++ b/openstack_dashboard/dashboards/admin/volumes/snapshots/views.py @@ -30,7 +30,11 @@ from openstack_dashboard.dashboards.project.volumes.snapshots \ class UpdateStatusView(forms.ModalFormView): form_class = vol_snapshot_forms.UpdateStatus + modal_header = _("Update Volume Snapshot Status") + modal_id = "update_volume_snapshot_status" template_name = 'admin/volumes/snapshots/update_status.html' + submit_label = _("Update Status") + submit_url = "horizon:admin:volumes:snapshots:update_status" success_url = reverse_lazy("horizon:admin:volumes:snapshots_tab") page_title = _("Update Volume Snapshot Status") @@ -49,6 +53,8 @@ class UpdateStatusView(forms.ModalFormView): def get_context_data(self, **kwargs): context = super(UpdateStatusView, self).get_context_data(**kwargs) context['snapshot_id'] = self.kwargs["snapshot_id"] + args = (self.kwargs['snapshot_id'],) + context['submit_url'] = reverse(self.submit_url, args=args) return context def get_initial(self): diff --git a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/snapshots/_update_status.html b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/snapshots/_update_status.html index c1554fcc10..d9bc7c684b 100644 --- a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/snapshots/_update_status.html +++ b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/snapshots/_update_status.html @@ -1,30 +1,11 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}{% endblock %} -{% block form_action %}{% url 'horizon:admin:volumes:snapshots:update_status' snapshot_id %}{% endblock %} - -{% block modal_id %}update_volume_snapshot_status_modal{% endblock %} -{% block modal-header %}{% trans "Update Volume Snapshot Status" %}{% endblock %} - -{% block modal-body %} -
{% blocktrans %} The status of a volume snapshot is normally managed automatically. In some circumstances an administrator may need to explicitly update the status value. This is equivalent to the cinder snapshot-reset-state command. {% endblocktrans %}
-{% blocktrans %}
- Add, modify or remove the QoS Spec associated with this volume type.
-
-
- "None" indicates that no QoS Spec is currently associated. Conversely, setting
- the QoS Spec to "None" will remove the current association.
-
-
- This is equivalent to the cinder qos-associate and cinder qos-disassociate
- commands.
- {% endblocktrans %}
{% trans "Add, modify or remove the QoS Spec associated with this volume type." %}
+{% blocktrans %}"None" indicates that no QoS Spec is currently associated. Conversely, setting the QoS Spec to "None" will remove the current association.{% endblocktrans %}
+{% blocktrans %}This is equivalent to the cinder qos-associate and cinder qos-disassociate commands.{% endblocktrans %}
{% endblock %} - -{% block modal-footer %} - - {% trans "Cancel" %} -{% endblock %} \ No newline at end of file diff --git a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/_create_qos_spec.html b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/_create_qos_spec.html index c3e8f363e3..1fb95b566c 100644 --- a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/_create_qos_spec.html +++ b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/_create_qos_spec.html @@ -1,20 +1,7 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}{% endblock %} -{% block form_action %}{% url 'horizon:admin:volumes:volume_types:create_qos_spec' %}{% endblock %} - -{% block modal_id %}create_volume_type_modal{% endblock %} -{% block modal-header %}{% trans "Create QoS Spec" %}{% endblock %} - -{% block modal-body %} -{% blocktrans %} QoS Specs can be associated with volume types. @@ -27,12 +14,5 @@ Each QoS Specs entity will have a "Consumer" value which indicates where the administrator would like the QoS policy to be enforced. This value can be "front-end" (Nova Compute), "back-end" (Cinder back-end), or "both". - {% endblocktrans %} -
-{% blocktrans %} Volume type is a type or label that can be selected at volume creation @@ -26,10 +13,4 @@ pair(s) for that volume type. {% endblocktrans %}
-{% trans "Creating encryption for a volume type causes all volumes with that volume type to be encrypted. Encryption information cannot be added to a volume type if volumes are currently in use with that volume type." %} @@ -31,10 +18,4 @@
{% blocktrans %}The Key Size is the size of the encryption key, in bits (e.g., 128, 256). If the field is left empty, the provider default will be used.{% endblocktrans %}
-{% blocktrans %} Each QoS Specs entity will have a "Consumer" value which indicates where the administrator would like the QoS policy to be enforced. This value can be "front-end" (Nova Compute), "back-end" (Cinder back-end), or "both". {% endblocktrans %}
-{% trans 'Create a new "extra spec" key-value pair for a volume type.' %}
-{% trans 'Create a new "extra spec" key-value pair for a volume type.' %}
{% endblock %} - -{% block modal-footer %} - - {% trans "Cancel" %} -{% endblock %} - diff --git a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/extras/_edit.html b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/extras/_edit.html index 40ee98921d..ac27d86cb0 100644 --- a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/extras/_edit.html +++ b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/extras/_edit.html @@ -1,28 +1,7 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}extra_spec_edit_form{% endblock %} -{% block form_action %}{% url 'horizon:admin:volumes:volume_types:extras:edit' vol_type.id key %}{% endblock %} - - -{% block modal_id %}extra_spec_edit_modal{% endblock %} -{% block modal-header %}{% blocktrans %}Edit Extra Spec Value: {{ key }}{% endblocktrans %}{% endblock %} - -{% block modal-body %} -{% blocktrans with key=key %}Update the "extra spec" value for "{{ key }}"{% endblocktrans %}
-{% blocktrans with key=key %}Update the "extra spec" value for "{{ key }}"{% endblocktrans %}
{% endblock %} - -{% block modal-footer %} - - {% trans "Cancel" %} -{% endblock %} - diff --git a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_create.html b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_create.html index 47ae74718a..d372d115ab 100644 --- a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_create.html +++ b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_create.html @@ -1,28 +1,7 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}extra_spec_create_form{% endblock %} -{% block form_action %}{% url 'horizon:admin:volumes:volume_types:qos_specs:create' qos_spec_id %}{% endblock %} - - -{% block modal_id %}qos_spec_create_modal{% endblock %} -{% block modal-header %}{% trans "Create Spec" %}{% endblock %} - -{% block modal-body %} -{% blocktrans with key=qos_spec_name %}Create a new "spec" key-value pair for QoS Spec "{{ qos_spec_name }}"{% endblocktrans %}
-{% blocktrans with key=qos_spec_name %}Create a new "spec" key-value pair for QoS Spec "{{ qos_spec_name }}"{% endblocktrans %}
{% endblock %} - -{% block modal-footer %} - - {% trans "Cancel" %} -{% endblock %} - diff --git a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_edit.html b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_edit.html index 55bfeb831a..52f21f7599 100644 --- a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_edit.html +++ b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volume_types/qos_specs/_edit.html @@ -1,27 +1,7 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}qos_spec_edit_form{% endblock %} -{% block form_action %}{% url 'horizon:admin:volumes:volume_types:qos_specs:edit' qos_spec_id key %}{% endblock %} - - -{% block modal_id %}qos_spec_edit_modal{% endblock %} -{% block modal-header %}{% trans "Edit Spec Value: " %} {{ key }}{% endblock %} - -{% block modal-body %} -{% blocktrans with key=key %}Update the spec value for "{{ key }}"{% endblocktrans %}
-{% blocktrans with key=key %}Update the spec value for "{{ key }}"{% endblocktrans %}
{% endblock %} diff --git a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volumes/_update_status.html b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volumes/_update_status.html index c83bd5fa0f..717b0a0be2 100644 --- a/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volumes/_update_status.html +++ b/openstack_dashboard/dashboards/admin/volumes/templates/volumes/volumes/_update_status.html @@ -1,30 +1,11 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}{% endblock %} -{% block form_action %} {% url 'horizon:admin:volumes:volumes:update_status' volume_id %}{% endblock %} - -{% block modal_id %}update_volume_status_modal{% endblock %} -{% block modal-header %}{% trans "Update Volume Status" %}{% endblock %} - -{% block modal-body %} -{% blocktrans %} The status of a volume is normally managed automatically. In some circumstances an administrator may need to explicitly update the status value. This is equivalent to the cinder reset-state command. {% endblocktrans %}
-{% trans "Volume Backup:" %} {% trans "Volume Backups are stored using the Object Storage service. You must have this service activated in order to create a backup." %}
-{% trans "If no container name is provided, a default container named volumebackups will be provisioned for you. Backups will be the same size as the volume they originate from." %}
-{% trans "Volume Backup:" %} {% trans "Volume Backups are stored using the Object Storage service. You must have this service activated in order to create a backup." %}
+{% trans "If no container name is provided, a default container named volumebackups will be provisioned for you. Backups will be the same size as the volume they originate from." %}
{% endblock %} diff --git a/openstack_dashboard/dashboards/project/volumes/templates/volumes/backups/_restore_backup.html b/openstack_dashboard/dashboards/project/volumes/templates/volumes/backups/_restore_backup.html index 5704d24329..21c3498e06 100644 --- a/openstack_dashboard/dashboards/project/volumes/templates/volumes/backups/_restore_backup.html +++ b/openstack_dashboard/dashboards/project/volumes/templates/volumes/backups/_restore_backup.html @@ -1,26 +1,7 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}{% endblock %} -{% block form_action %}{% url 'horizon:project:volumes:backups:restore' backup_id %}{% endblock %} - -{% block modal_id %}restore_volume_backup_modal{% endblock %} -{% block modal-header %}{% trans "Restore Volume Backup" %}{% endblock %} - -{% block modal-body %} -{% trans "Restore Backup:" %} {% trans "Select a volume to restore to." %}
-{% trans "Optionally, you may choose to create a new volume." %}
-{% trans "Restore Backup:" %} {% trans "Select a volume to restore to." %}
+{% trans "Optionally, you may choose to create a new volume." %}
{% endblock %} diff --git a/openstack_dashboard/dashboards/project/volumes/templates/volumes/snapshots/_update.html b/openstack_dashboard/dashboards/project/volumes/templates/volumes/snapshots/_update.html index b8af2bdc33..8e45646980 100644 --- a/openstack_dashboard/dashboards/project/volumes/templates/volumes/snapshots/_update.html +++ b/openstack_dashboard/dashboards/project/volumes/templates/volumes/snapshots/_update.html @@ -1,26 +1,7 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}update_snapshot_form{% endblock %} -{% block form_action %}{% url 'horizon:project:volumes:snapshots:update' snapshot.id %}{% endblock %} - -{% block modal_id %}update_snapshot_modal{% endblock %} -{% block modal-header %}{% trans "Edit Snapshot" %}{% endblock %} - -{% block modal-body %} -{% trans "Modify the name and description of a snapshot." %}
-{% trans "Modify the name and description of a snapshot." %}
{% endblock %} diff --git a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_attach.html b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_attach.html index d2638f4a95..972ac3cb77 100644 --- a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_attach.html +++ b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_attach.html @@ -2,20 +2,15 @@ {% load i18n %} {% load url from future %} -{% block form_id %}attach_volume_form{% endblock %} -{% block form_action %}{% url 'horizon:project:volumes:volumes:attach' volume.id %}{% endblock %} {% block form_class %}{{ block.super }} horizontal {% if show_attach %}split_half{% else %} no_split{% endif %}{% endblock %} -{% block modal_id %}attach_volume_modal{% endblock %} -{% block modal-header %}{% trans "Manage Volume Attachments" %}{% endblock %} - {% block modal-body %} - {% if show_attach %} + {% if show_attach %}{% blocktrans %} - Change the volume type of a volume after its creation. - This is equivalent to the cinder retype command. - {% endblocktrans %} -
-{% blocktrans %} - The "Volume Type" selected must be different from the current volume type. - {% endblocktrans %} -
-{% blocktrans %} - The "Migration Policy" is only used if the volume retype cannot be - completed. If the "Migration Policy" is "On Demand", the back end will - perform volume migration. Note that migration may take a significant - amount of time to complete, in some cases hours. - {% endblocktrans %} -
-{% blocktrans %} + Change the volume type of a volume after its creation. + This is equivalent to the cinder retype command. + {% endblocktrans %} +
+{% blocktrans %} + The "Volume Type" selected must be different from the current volume type. + {% endblocktrans %} +
+{% blocktrans %} + The "Migration Policy" is only used if the volume retype cannot be + completed. If the "Migration Policy" is "On Demand", the back end will + perform volume migration. Note that migration may take a significant + amount of time to complete, in some cases hours. + {% endblocktrans %} +
{% endblock %} diff --git a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_show_transfer.html b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_show_transfer.html index 55f46a6f44..c776c560ec 100644 --- a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_show_transfer.html +++ b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_show_transfer.html @@ -6,7 +6,3 @@{% trans "The Transfer ID and the Authorization Key are needed by the recipient in order to accept the transfer. Please capture both the Transfer ID and the Authorization Key and provide them to your transfer recipient." %}
{% trans "The Authorization Key will not be available after closing this page, so you must capture it now, or else you will be unable to use the transfer." %}
{% endblock %} - -{% block modal-footer %} - {% trans "Close" %} -{% endblock %} diff --git a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_update.html b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_update.html index 42230444c1..2c5bc87f8d 100644 --- a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_update.html +++ b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_update.html @@ -1,29 +1,8 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}{% endblock %} -{% block form_action %}{% url 'horizon:project:volumes:volumes:update' volume.id %}{% endblock %} - -{% block modal_id %}update_volume_modal{% endblock %} -{% block modal-header %}{% trans "Edit Volume" %}{% endblock %} - -{% block modal-body %} -{% trans "Modify name and description of a volume." %} -
-{% trans 'The "Bootable" flag specifies that this volume can be used to launch an instance.' %} -
-{% trans "Modify name and description of a volume." %}
+{% trans 'The "Bootable" flag specifies that this volume can be used to launch an instance.' %}
{% endblock %} diff --git a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_upload_to_image.html b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_upload_to_image.html index ba56327b64..4480b117d0 100644 --- a/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_upload_to_image.html +++ b/openstack_dashboard/dashboards/project/volumes/templates/volumes/volumes/_upload_to_image.html @@ -1,42 +1,23 @@ {% extends "horizon/common/_modal_form.html" %} {% load i18n %} -{% load url from future %} -{% block form_id %}{% endblock %} -{% block form_action %}{% url 'horizon:project:volumes:volumes:upload_to_image' volume.id %}{% endblock %} - -{% block modal_id %}update_volume_modal{% endblock %} -{% block modal-header %}{% trans "Upload Volume to Image" %}{% endblock %} - -{% block modal-body %} -{% blocktrans %} + Upload the volume to the Image Service as an image. + This is equivalent to the cinder upload-to-image command. + {% endblocktrans %} +
+{% blocktrans %} + Choose "Disk Format" for the image. The volume images are created with + the QEMU disk image utility. + {% endblocktrans %} +
+ {% if volume.status == 'in-use' %}{% blocktrans %} - Upload the volume to the Image Service as an image. - This is equivalent to the cinder upload-to-image command. + When the volume status is "in-use", you can use "Force" to upload the + volume to an image. {% endblocktrans %}
-{% blocktrans %} - Choose "Disk Format" for the image. The volume images are created with - the QEMU disk image utility. - {% endblocktrans %} -
- {% if volume.status == 'in-use' %} -{% blocktrans %} - When the volume status is "in-use", you can use "Force" to upload the - volume to an image. - {% endblocktrans %} -
- {% endif %} -