Commit Graph

5 Commits

Author SHA1 Message Date
Tatiana Ovchinnikova 1011d4237e Fix redirect after deleting from details page
On apache environments, when WEBROOT is "/dashboard/" and not "/",
redirection after deleting from Angular details page is broken. If
we go to image/key pair/server group/etc details page, and delete
it from this page, redirect url is "/dashboard/dashboard/project/..."
instead of "/dashboard/project/..."

This patch switches from using WEBROOT depentent panel navigation to
getting default index url directly from details view controller.
It also cleans up a work around that was implemented for some pages.

Change-Id: I6bd06ea479f473a319f8100cbf8d168424b62461
2022-09-14 16:37:58 +00:00
pengyuesheng 0d8fba2a3d After deleting the trunk, jump to the correct page
Change-Id: Ie1835e67d7c5e0879cd372cee996853c4d7a36bc
Closes-Bug: #1821835
2019-03-27 10:06:46 +08:00
Lajos Katona 7b207fbf89 Remove initScope from trunk delete.action.service
The initScope method is deprecated, the action service should be
stateless.

Also refactor to simplify delete action logic. Some code got carried
over from the images panel, what we originally used as an example. But
much of that code was doing checks useless for trunks. Trunks don't have
complicated 'public' and 'shared' attributes controlling who can operate
on them. A simple policy check will suffice.

Co-Authored-By: Bence Romsics <bence.romsics@ericsson.com>
Change-Id: I689a98697d997780af42eb31a4b5eeee2ddf9b0f
Partially-Implements: blueprint neutron-trunk-ui
Related-Bug: #1640049
2017-11-27 14:05:43 +01:00
Bence Romsics 1ab4b498f2 Trunks panel: create button
Trunk creation is a 3-step workflow:
  * Basic trunk attributes
  * Parent port selector transfertable:
      Selects a single port (mandatory)
  * Subports selector transfertable:
      Selects many ports with segmentation details (optional)

In the port selector steps reused and built on port allocator
transfertable from launch instance.

The easiest way to test is to take the whole change series by taking the
last change in it, then build devstack with neutron trunk support. Eg:

  local.conf:
  enable_plugin neutron https://git.openstack.org/openstack/neutron
  enable_service q-trunk

If you want to test this change in isolation you also need the following
Horizon config:

  openstack_dashboard/enabled/_1500_project_trunks_panel.py:
  DISABLED = False  # or just remove this line

As long as the 'trunk' API extension is available (openstack
extension show trunk) the panel should automatically appear under
Project/Network/Trunks.

To try the 'inherit' segmentation type the subports must be ports of
vlan type provider networks.

Co-Authored-By: Lajos Katona <lajos.katona@ericsson.com>
Co-Authored-By: Elod Illes <elod.illes@ericsson.com>
Change-Id: I663a7e0158335155fe11f0fc40d9fa86bf984ae0
Partially-Implements: blueprint neutron-trunk-ui
2017-11-27 14:05:43 +01:00
Bence Romsics 9120b40038 Trunks panel: item and batch delete
Add delete buttons to the Project/Network/Trunks panel. There is one
button per each trunk item deleting only that trunk. Plus a select and
delete many trunks at once by checkboxes and then delete all selected.
The usual extras (confirmations and toast notifications) are included.

Change-Id: Ie88e169072a563fa238bf870664b71aa7f2a883d
Partially-Implements: bp/neutron-trunk-ui
2017-06-16 09:11:40 +02:00