dewrich closed pull request #2135: TP - adds external links to drop down values in TP forms URL: https://github.com/apache/incubator-trafficcontrol/pull/2135
This is a PR merged from a forked repository. As GitHub hides the original diff on merge, it is displayed below for the sake of provenance: As this is a foreign pull request (from a fork), the diff is supplied below (as it won't show otherwise due to GitHub magic): diff --git a/traffic_portal/app/src/common/modules/form/asn/form.asn.tpl.html b/traffic_portal/app/src/common/modules/form/asn/form.asn.tpl.html index 6cdf9f8e6..c476e1720 100644 --- a/traffic_portal/app/src/common/modules/form/asn/form.asn.tpl.html +++ b/traffic_portal/app/src/common/modules/form/asn/form.asn.tpl.html @@ -44,6 +44,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(asnForm.cachegroup, 'required')">Required</small> + <small ng-show="asn.cachegroupId"><a href="/#!/cache-groups/{{asn.cachegroupId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="modal-footer"> diff --git a/traffic_portal/app/src/common/modules/form/cacheGroup/form.cacheGroup.tpl.html b/traffic_portal/app/src/common/modules/form/cacheGroup/form.cacheGroup.tpl.html index 91bd59c6c..292897091 100644 --- a/traffic_portal/app/src/common/modules/form/cacheGroup/form.cacheGroup.tpl.html +++ b/traffic_portal/app/src/common/modules/form/cacheGroup/form.cacheGroup.tpl.html @@ -79,6 +79,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(cacheGroupForm.type, 'required')">Required</small> + <small ng-show="cacheGroup.typeId"><a href="/#!/types/{{cacheGroup.typeId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(cacheGroupForm.latitude), 'has-feedback': hasError(cacheGroupForm.latitude)}"> @@ -105,6 +106,7 @@ <select name="parentCacheGroup" class="form-control" ng-model="cacheGroup.parentCachegroupId" ng-options="cacheGroup.id as cacheGroup.name for cacheGroup in cacheGroups"> <option value="">Select...</option> </select> + <small ng-show="cacheGroup.parentCachegroupId"><a href="/#!/cache-groups/{{cacheGroup.parentCachegroupId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group"> @@ -113,6 +115,7 @@ <select name="secondaryParentCacheGroup" class="form-control" ng-model="cacheGroup.secondaryParentCachegroupId" ng-options="cacheGroup.id as cacheGroup.name for cacheGroup in cacheGroups"> <option value="">Select...</option> </select> + <small ng-show="cacheGroup.secondaryParentCachegroupId"><a href="/#!/cache-groups/{{cacheGroup.secondaryParentCachegroupId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="modal-footer"> diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html index d92469238..38e8acfa2 100644 --- a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html +++ b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.DNS.tpl.html @@ -87,6 +87,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.type, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.typeId != dsCurrent.typeId">Current Value: [ {{dsCurrent.type}} ]</small> + <small ng-show="deliveryService.typeId"><a href="/#!/types/{{deliveryService.typeId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -127,6 +128,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.tenantId, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.tenantId != dsCurrent.tenantId">Current Value: [ {{dsCurrent.tenant}} ]</small> + <small ng-show="deliveryService.tenantId"><a href="/#!/tenants/{{deliveryService.tenantId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -140,6 +142,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.cdn, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.cdnId != dsCurrent.cdnId">Current Value: [ {{dsCurrent.cdnName}} ]</small> + <small ng-show="deliveryService.cdnId"><a href="/#!/cdns/{{deliveryService.cdnId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -451,6 +454,7 @@ <option value="">Select...</option> </select> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.profileId != dsCurrent.profileId">Current Value: [ {{dsCurrent.profileName}} ]</small> + <small ng-show="deliveryService.profileId"><a href="/#!/profiles/{{deliveryService.profileId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html index c7612b1f7..9f6a10efc 100644 --- a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html +++ b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.HTTP.tpl.html @@ -87,6 +87,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.type, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.typeId != dsCurrent.typeId">Current Value: [ {{dsCurrent.type}} ]</small> + <small ng-show="deliveryService.typeId"><a href="/#!/types/{{deliveryService.typeId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -127,6 +128,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.tenantId, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.tenantId != dsCurrent.tenantId">Current Value: [ {{dsCurrent.tenant}} ]</small> + <small ng-show="deliveryService.tenantId"><a href="/#!/tenants/{{deliveryService.tenantId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -140,6 +142,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.cdn, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.cdnId != dsCurrent.cdnId">Current Value: [ {{dsCurrent.cdnName}} ]</small> + <small ng-show="deliveryService.cdnId"><a href="/#!/cdns/{{deliveryService.cdnId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -454,6 +457,7 @@ <option value="">Select...</option> </select> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.profileId != dsCurrent.profileId">Current Value: [ {{dsCurrent.profileName}} ]</small> + <small ng-show="deliveryService.profileId"><a href="/#!/profiles/{{deliveryService.profileId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.Steering.tpl.html b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.Steering.tpl.html index bf4cde0a9..c800e06f8 100644 --- a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.Steering.tpl.html +++ b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.Steering.tpl.html @@ -85,6 +85,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.type, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.typeId != dsCurrent.typeId">Current Value: [ {{dsCurrent.type}} ]</small> + <small ng-show="deliveryService.typeId"><a href="/#!/types/{{deliveryService.typeId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -125,6 +126,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.tenantId, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.tenantId != dsCurrent.tenantId">Current Value: [ {{dsCurrent.tenant}} ]</small> + <small ng-show="deliveryService.tenantId"><a href="/#!/tenants/{{deliveryService.tenantId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -138,6 +140,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.cdn, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.cdnId != dsCurrent.cdnId">Current Value: [ {{dsCurrent.cdnName}} ]</small> + <small ng-show="deliveryService.cdnId"><a href="/#!/cdns/{{deliveryService.cdnId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -264,6 +267,7 @@ <option value="">Select...</option> </select> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.profileId != dsCurrent.profileId">Current Value: [ {{dsCurrent.profileName}} ]</small> + <small ng-show="deliveryService.profileId"><a href="/#!/profiles/{{deliveryService.profileId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> diff --git a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.anyMap.tpl.html b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.anyMap.tpl.html index 27dc56d2f..0573deec2 100644 --- a/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.anyMap.tpl.html +++ b/traffic_portal/app/src/common/modules/form/deliveryService/form.deliveryService.anyMap.tpl.html @@ -83,6 +83,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.type, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.typeId != dsCurrent.typeId">Current Value: [ {{dsCurrent.type}} ]</small> + <small ng-show="deliveryService.typeId"><a href="/#!/types/{{deliveryService.typeId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -123,6 +124,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.tenantId, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.tenantId != dsCurrent.tenantId">Current Value: [ {{dsCurrent.tenant}} ]</small> + <small ng-show="deliveryService.tenantId"><a href="/#!/tenants/{{deliveryService.tenantId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -136,6 +138,7 @@ </select> <small class="input-error" ng-show="hasPropertyError(deliveryServiceForm.cdn, 'required')">Required</small> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.cdnId != dsCurrent.cdnId">Current Value: [ {{dsCurrent.cdnName}} ]</small> + <small ng-show="deliveryService.cdnId"><a href="/#!/cdns/{{deliveryService.cdnId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> @@ -244,6 +247,7 @@ <option value="">Select...</option> </select> <small class="input-diff" ng-show="settings.isRequest && open() && deliveryService.profileId != dsCurrent.profileId">Current Value: [ {{dsCurrent.profileName}} ]</small> + <small ng-show="deliveryService.profileId"><a href="/#!/profiles/{{deliveryService.profileId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> diff --git a/traffic_portal/app/src/common/modules/form/physLocation/form.physLocation.tpl.html b/traffic_portal/app/src/common/modules/form/physLocation/form.physLocation.tpl.html index 55d9ba0ff..c33f335d9 100644 --- a/traffic_portal/app/src/common/modules/form/physLocation/form.physLocation.tpl.html +++ b/traffic_portal/app/src/common/modules/form/physLocation/form.physLocation.tpl.html @@ -47,6 +47,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(physLocationForm.region, 'required')">Required</small> + <small ng-show="physLocation.regionId"><a href="/#!/regions/{{physLocation.regionId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group"> diff --git a/traffic_portal/app/src/common/modules/form/profile/form.profile.tpl.html b/traffic_portal/app/src/common/modules/form/profile/form.profile.tpl.html index 8a05925ee..a9061677a 100644 --- a/traffic_portal/app/src/common/modules/form/profile/form.profile.tpl.html +++ b/traffic_portal/app/src/common/modules/form/profile/form.profile.tpl.html @@ -62,6 +62,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(profileForm.cdn, 'required')">Required</small> + <small ng-show="profile.cdn"><a href="/#!/cdns/{{profile.cdn}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(profileForm.type), 'has-feedback': hasError(profileForm.type)}"> diff --git a/traffic_portal/app/src/common/modules/form/region/form.region.tpl.html b/traffic_portal/app/src/common/modules/form/region/form.region.tpl.html index f87fce3c9..480154289 100644 --- a/traffic_portal/app/src/common/modules/form/region/form.region.tpl.html +++ b/traffic_portal/app/src/common/modules/form/region/form.region.tpl.html @@ -47,6 +47,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(regionForm.division, 'required')">Required</small> + <small ng-show="region.division"><a href="/#!/divisions/{{region.division}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="modal-footer"> diff --git a/traffic_portal/app/src/common/modules/form/server/form.server.tpl.html b/traffic_portal/app/src/common/modules/form/server/form.server.tpl.html index e9ecce23d..50ef74fb6 100644 --- a/traffic_portal/app/src/common/modules/form/server/form.server.tpl.html +++ b/traffic_portal/app/src/common/modules/form/server/form.server.tpl.html @@ -90,6 +90,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(serverForm.cdn, 'required')">Required</small> + <small ng-show="server.cdnId"><a href="/#!/cdns/{{server.cdnId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(serverForm.cachegroup), 'has-feedback': hasError(serverForm.cachegroup)}"> @@ -99,6 +100,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(serverForm.cachegroup, 'required')">Required</small> + <small ng-show="server.cachegroupId"><a href="/#!/cache-groups/{{server.cachegroupId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(serverForm.type), 'has-feedback': hasError(serverForm.type)}"> @@ -108,6 +110,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(serverForm.type, 'required')">Required</small> + <small ng-show="server.typeId"><a href="/#!/types/{{server.typeId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(serverForm.profile), 'has-feedback': hasError(serverForm.profile)}"> @@ -117,6 +120,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(serverForm.profile, 'required')">Required</small> + <small ng-show="server.profileId"><a href="/#!/profiles/{{server.profileId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(serverForm.interfaceName), 'has-feedback': hasError(serverForm.interfaceName)}"> @@ -174,6 +178,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(serverForm.physLocation, 'required')">Required</small> + <small ng-show="server.physLocationId"><a href="/#!/phys-locations/{{server.physLocationId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(serverForm.ip6Address), 'has-feedback': hasError(serverForm.ip6Address)}"> diff --git a/traffic_portal/app/src/common/modules/form/tenant/form.tenant.tpl.html b/traffic_portal/app/src/common/modules/form/tenant/form.tenant.tpl.html index 1f03a77d8..4aac13e68 100644 --- a/traffic_portal/app/src/common/modules/form/tenant/form.tenant.tpl.html +++ b/traffic_portal/app/src/common/modules/form/tenant/form.tenant.tpl.html @@ -57,6 +57,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(tenantForm.parentId, 'required')">Required</small> + <small ng-show="tenant.parentId"><a href="/#!/tenants/{{tenant.parentId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="modal-footer"> diff --git a/traffic_portal/app/src/common/modules/form/user/form.user.tpl.html b/traffic_portal/app/src/common/modules/form/user/form.user.tpl.html index 3a923865b..2a6031ee3 100644 --- a/traffic_portal/app/src/common/modules/form/user/form.user.tpl.html +++ b/traffic_portal/app/src/common/modules/form/user/form.user.tpl.html @@ -77,6 +77,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(userForm.tenantId, 'required')">Required</small> + <small ng-show="user.tenantId"><a href="/#!/tenants/{{user.tenantId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="form-group" ng-class="{'has-error': hasError(userForm.uPass), 'has-feedback': hasError(userForm.uPass)}"> diff --git a/traffic_portal/app/src/common/modules/form/user/register/form.user.register.tpl.html b/traffic_portal/app/src/common/modules/form/user/register/form.user.register.tpl.html index 50c70d969..85c6ce5ce 100644 --- a/traffic_portal/app/src/common/modules/form/user/register/form.user.register.tpl.html +++ b/traffic_portal/app/src/common/modules/form/user/register/form.user.register.tpl.html @@ -55,6 +55,7 @@ <option value="">Select...</option> </select> <small class="input-error" ng-show="hasPropertyError(registerForm.tenantId, 'required')">Required</small> + <small ng-show="registration.tenantId"><a href="/#!/tenants/{{registration.tenantId}}" target="_blank">View Details <i class="fa fs-xs fa-external-link"></i></a></small> </div> </div> <div class="modal-footer"> ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services