spaces: add username suffix when installing apps

This commit is contained in:
Girish Ramakrishnan
2018-08-27 20:45:09 -07:00
parent 9c90a20b4d
commit 0e43ca31a3
2 changed files with 6 additions and 2 deletions

View File

@@ -23,7 +23,9 @@
<input type="text" class="form-control" ng-model="appInstall.location" id="appInstallLocationInput" name="location" placeholder="Leave empty to use bare domain" autofocus>
<div class="input-group-btn">
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
{{ (appInstall.location ? (appInstall.domain.config.hyphenatedSubdomains ? '-' : '.') : '') + appInstall.domain.domain }}
<!-- the admin check is to check for spaces user -->
<span ng-if="user.admin">{{ (appInstall.location ? (appInstall.domain.config.hyphenatedSubdomains ? '-' : '.') : '') + appInstall.domain.domain }}</span>
<span ng-if="!user.admin">{{ (appInstall.location ? '-' : '') + user.username + '.' + appInstall.domain.domain }}</span>
<span class="caret"></span>
</button>
<ul class="dropdown-menu dropdown-menu-right" role="menu">