mirror of
https://github.com/ansible/awx.git
synced 2026-03-20 10:27:34 -02:30
show inventory source details
This commit is contained in:
@@ -180,6 +180,20 @@ function getInventoryJobNameDetails () {
|
|||||||
return { label, link, tooltip, value };
|
return { label, link, tooltip, value };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getInventorySourceDetails () {
|
||||||
|
if (!resource.model.has('summary_fields.inventory_source.source')) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
const { source } = resource.model.get('summary_fields.inventory_source');
|
||||||
|
const choices = mapChoices(resource.model.options('actions.GET.source.choices'));
|
||||||
|
|
||||||
|
const label = 'Source';
|
||||||
|
const value = choices[source];
|
||||||
|
|
||||||
|
return { label, value };
|
||||||
|
}
|
||||||
|
|
||||||
function getLaunchedByDetails () {
|
function getLaunchedByDetails () {
|
||||||
const createdBy = resource.model.get('summary_fields.created_by');
|
const createdBy = resource.model.get('summary_fields.created_by');
|
||||||
const jobTemplate = resource.model.get('summary_fields.job_template');
|
const jobTemplate = resource.model.get('summary_fields.job_template');
|
||||||
@@ -643,6 +657,7 @@ function JobDetailsController (
|
|||||||
vm.extraVars = getExtraVarsDetails();
|
vm.extraVars = getExtraVarsDetails();
|
||||||
vm.labels = getLabelDetails();
|
vm.labels = getLabelDetails();
|
||||||
vm.inventoryJobName = getInventoryJobNameDetails();
|
vm.inventoryJobName = getInventoryJobNameDetails();
|
||||||
|
vm.inventorySource = getInventorySourceDetails();
|
||||||
|
|
||||||
// Relaunch and Delete Components
|
// Relaunch and Delete Components
|
||||||
vm.job = angular.copy(_.get(resource.model, 'model.GET', {}));
|
vm.job = angular.copy(_.get(resource.model, 'model.GET', {}));
|
||||||
|
|||||||
@@ -220,6 +220,14 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- INVENTORY SOURCE DETAIL -->
|
||||||
|
<div class="JobResults-resultRow" ng-show="vm.inventorySource">
|
||||||
|
<label class="JobResults-resultRowLabel">{{ vm.inventorySource.label }}</label>
|
||||||
|
<div class="JobResults-resultRowText">
|
||||||
|
{{ vm.inventorySource.value }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- FORKS DETAIL -->
|
<!-- FORKS DETAIL -->
|
||||||
<div class="JobResults-resultRow" ng-if="vm.forks">
|
<div class="JobResults-resultRow" ng-if="vm.forks">
|
||||||
<label class="JobResults-resultRowLabel">{{ vm.forks.label }}</label>
|
<label class="JobResults-resultRowLabel">{{ vm.forks.label }}</label>
|
||||||
|
|||||||
Reference in New Issue
Block a user