diff options
author | Sawyer Bergeron <sbergeron@iol.unh.edu> | 2022-09-07 18:07:18 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2022-09-07 18:07:18 +0000 |
commit | 1773e2b7fc4564e693dfbf29074374379ed86ebb (patch) | |
tree | 51f18dc1beb17957ceba2c30c7fbe586c8a982f7 /src | |
parent | 2f00cec033d0b20f5d4fda78281988da4ad18e9f (diff) | |
parent | 03e71787d6c556078624e3044d722b5781876396 (diff) |
Merge "Posix compliant username is shown in booking details"
Diffstat (limited to 'src')
-rw-r--r-- | src/booking/views.py | 5 | ||||
-rw-r--r-- | src/templates/base/booking/booking_detail.html | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/src/booking/views.py b/src/booking/views.py index 940428b..367a18d 100644 --- a/src/booking/views.py +++ b/src/booking/views.py @@ -24,7 +24,7 @@ from booking.models import Booking from booking.stats import StatisticsManager from booking.forms import HostReImageForm from workflow.forms import FormUtils -from api.models import JobFactory +from api.models import JobFactory, GeneratedCloudConfig from workflow.views import login from booking.forms import QuickBookingForm from booking.quick_deployer import create_from_form, drop_filter @@ -167,7 +167,8 @@ def booking_detail_view(request, booking_id): 'booking': booking, 'pdf': booking.pdf, 'user_id': user.id, - 'image_mapping': build_image_mapping(booking.lab, user) + 'image_mapping': build_image_mapping(booking.lab, user), + 'posix_username': GeneratedCloudConfig._normalize_username(None, user.username) } return render( diff --git a/src/templates/base/booking/booking_detail.html b/src/templates/base/booking/booking_detail.html index 4a8f35a..70958f6 100644 --- a/src/templates/base/booking/booking_detail.html +++ b/src/templates/base/booking/booking_detail.html @@ -24,6 +24,10 @@ code { <div class="collapse show" id="panel_overview"> <table class="table m-0"> <tr> + <td>Username</td> + <td>{{ posix_username }}</td> + </tr> + <tr> <td>Purpose</td> <td>{{ booking.purpose }}</td> </tr> |