Browse Source

Merge "Update API version to 2.33"

changes/93/707793/1
Zuul 1 week ago
parent
commit
ae3408fc96
5 changed files with 39 additions and 19 deletions
  1. +1
    -1
      manila_ui/api/manila.py
  2. +13
    -9
      manila_ui/dashboards/admin/shares/templates/shares/_detail.html
  3. +5
    -0
      manila_ui/dashboards/project/shares/tables.py
  4. +13
    -9
      manila_ui/dashboards/project/shares/templates/shares/_detail.html
  5. +7
    -0
      releasenotes/notes/bug-1823078-upgrade-api-to-v2.33-82871432659a8285.yaml

+ 1
- 1
manila_ui/api/manila.py View File

@@ -31,7 +31,7 @@ LOG = logging.getLogger(__name__)
MANILA_UI_USER_AGENT_REPR = "manila_ui_plugin_for_horizon"
# NOTE(vponomaryov): update version to 2.34 when manilaclient is released with
# its support. It will allow to show 'availability zones' for share groups.
MANILA_VERSION = "2.32" # requires manilaclient 1.13.0 or newer
MANILA_VERSION = "2.33" # requires manilaclient 1.16.0 or newer
MANILA_SERVICE_TYPE = "sharev2"

# API static values

+ 13
- 9
manila_ui/dashboards/admin/shares/templates/shares/_detail.html View File

@@ -81,15 +81,19 @@
<h4>{% trans "Access Rules" %}</h4>
<hr class="header_rule">
<dl class="dl-horizontal">
{% for rule in share.rules %}
{% for rule in share.rules %}
<dt>{{ rule.access_type }}</dt>
<dd><p>
<div><b>Access to: </b>{{ rule.access_to }}</div>
<div><b>Access Level: </b>{{ rule.access_level }}</div>
<div><b>Status: </b>{{ rule.state }}</div>
<div><b>Access Key: </b>{{ rule.access_key }}</div>
</p></dd>
{% endfor %}
<dd>
<p>
<div><b>Access to: </b>{{ rule.access_to }}</div>
<div><b>Access Level: </b>{{ rule.access_level }}</div>
<div><b>Status: </b>{{ rule.state }}</div>
<div><b>Access Key: </b>{{ rule.access_key }}</div>
<div><b>Created At: </b>{{ rule.created_at|parse_date }}</div>
<div><b>Updated At: </b>{{ rule.updated_at|parse_date }}</div>
</p>
</dd>
{% endfor %}
</dl>
</div>

@@ -102,4 +106,4 @@
<dd>{{ value }}</dd>
{% endfor %}
</dl>
</div>
</div>

+ 5
- 0
manila_ui/dashboards/project/shares/tables.py View File

@@ -21,6 +21,7 @@ from django.utils.translation import ungettext_lazy
from horizon import exceptions
from horizon import messages
from horizon import tables
from horizon.utils import filters

from manila_ui.api import manila
from manila_ui.dashboards.project.share_snapshots import tables as ss_tables
@@ -359,6 +360,10 @@ class RulesTable(tables.DataTable):
"access_level", verbose_name=_("Access Level"))
status = tables.Column("state", verbose_name=_("Status"))
access_key = tables.Column("access_key", verbose_name=_("Access Key"))
created_at = tables.Column("created_at", verbose_name=_("Created At"),
filters=(filters.parse_isotime,))
updated_at = tables.Column("updated_at", verbose_name=_("Updated At"),
filters=(filters.parse_isotime,))

def get_object_display(self, obj):
return obj.id

+ 13
- 9
manila_ui/dashboards/project/shares/templates/shares/_detail.html View File

@@ -83,15 +83,19 @@
<h4>{% trans "Access Rules" %}</h4>
<hr class="header_rule">
<dl class="dl-horizontal">
{% for rule in share.rules %}
{% for rule in share.rules %}
<dt>{{ rule.access_type }}</dt>
<dd><p>
<div><b>Access to: </b>{{ rule.access_to }}</div>
<div><b>Access Level: </b>{{ rule.access_level }}</div>
<div><b>Status: </b>{{ rule.state }}</div>
<div><b>Access Key: </b>{{ rule.access_key }}</div>
</p></dd>
{% endfor %}
<dd>
<p>
<div><b>Access to: </b>{{ rule.access_to }}</div>
<div><b>Access Level: </b>{{ rule.access_level }}</div>
<div><b>Status: </b>{{ rule.state }}</div>
<div><b>Access Key: </b>{{ rule.access_key }}</div>
<div><b>Created At: </b>{{ rule.created_at|parse_date }}</div>
<div><b>Updated At: </b>{{ rule.updated_at|parse_date }}</div>
</p>
</dd>
{% endfor %}
</dl>
</div>

@@ -104,4 +108,4 @@
<dd>{{ value }}</dd>
{% endfor %}
</dl>
</div>
</div>

+ 7
- 0
releasenotes/notes/bug-1823078-upgrade-api-to-v2.33-82871432659a8285.yaml View File

@@ -0,0 +1,7 @@
---
fixes:
- |
This change updates the Manila API version to 2.33.
This means that users can have access to timestamp details in access rules,
available since API v2.33


Loading…
Cancel
Save