Renamed metric menu item from Categorie to Type.
This commit is contained in:
parent
b9f3d6b600
commit
65c359cfb8
3 changed files with 28 additions and 26 deletions
|
@ -60,26 +60,26 @@ public class ServiceMetricMenuView
|
|||
{
|
||||
TagDataManager data = new TagDataManager();
|
||||
|
||||
data.setAttribute("summaryCategoryButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + ".xhtml");
|
||||
data.setAttribute("genericCategoryButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + "-metrics-generic.xhtml");
|
||||
data.setAttribute("webCategoryButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + "-metrics-web.xhtml");
|
||||
data.setAttribute("specificCategoryButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + "-metrics-specific.xhtml");
|
||||
data.setAttribute("summaryTypeButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + ".xhtml");
|
||||
data.setAttribute("genericTypeButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + "-metrics-generic.xhtml");
|
||||
data.setAttribute("webTypeButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + "-metrics-web.xhtml");
|
||||
data.setAttribute("specificTypeButton", "href", service.getOrganization().getTechnicalName() + "-" + service.getTechnicalName() + "-metrics-specific.xhtml");
|
||||
|
||||
if ((item == null) || (item == MenuItem.SUMMARY))
|
||||
{
|
||||
data.appendAttribute("summaryCategoryButton", "class", "button selected");
|
||||
data.appendAttribute("summaryTypeButton", "class", "button selected");
|
||||
}
|
||||
else if (item == MenuItem.GENERIC)
|
||||
{
|
||||
data.appendAttribute("genericCategoryButton", "class", "button selected");
|
||||
data.appendAttribute("genericTypeButton", "class", "button selected");
|
||||
}
|
||||
else if (item == MenuItem.WEB)
|
||||
{
|
||||
data.appendAttribute("webCategoryButton", "class", "button selected");
|
||||
data.appendAttribute("webTypeButton", "class", "button selected");
|
||||
}
|
||||
else if (item == MenuItem.SPECIFIC)
|
||||
{
|
||||
data.appendAttribute("specificCategoryButton", "class", "button selected");
|
||||
data.appendAttribute("specificTypeButton", "class", "button selected");
|
||||
}
|
||||
|
||||
//
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
var ctx = document.getElementById('myChart');
|
||||
var myChart = new Chart(ctx,
|
||||
{
|
||||
type: 'line',
|
||||
type: 'bar',
|
||||
data:
|
||||
{
|
||||
datasets:
|
||||
|
@ -44,7 +44,7 @@
|
|||
fill: true,
|
||||
lineTension: 0,
|
||||
pointBorderWidth: 0.00000001,
|
||||
data: [1, 5, 9, 13, 15, 22]
|
||||
data: [{t: '2020-01', y: 7},{t: '2020-02', y: 9},{t: '2020-03', y: 4},{t: '2020-04', y: 2},{t: '2020-05', y: 1},{t: '2020-06', y: 7},{t: '2020-07', y: 0},{t: '2020-08', y: 0},{t: '2020-09', y: 0},{t: '2020-10', y: 0},{t: '2020-11', y: 0},{t: '2020-12', y: 0}]
|
||||
}
|
||||
]
|
||||
},
|
||||
|
@ -75,10 +75,11 @@
|
|||
beginAtZero: false,
|
||||
maxTicksLimit: 0
|
||||
},
|
||||
stacked: true,
|
||||
gridLines:
|
||||
{
|
||||
zeroLineColor: 'rgba(0, 0, 0, 0.1)',
|
||||
offsetGridLines: false
|
||||
offsetGridLines: true
|
||||
}
|
||||
}],
|
||||
yAxes:
|
||||
|
@ -88,7 +89,8 @@
|
|||
beginAtZero: false,
|
||||
suggestedMax: 10,
|
||||
precision: 0
|
||||
}
|
||||
},
|
||||
stacked: true,
|
||||
}]
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,11 +13,11 @@
|
|||
<body>
|
||||
<div>
|
||||
<div style="margin: 5px;">
|
||||
<span style="display: inline-block; width: 100px">Catégorie</span>
|
||||
<a onclick="javascript:selectCategoryMenu('summary');" href="#" id="summaryCategoryButton" class="button">Résumé</a>
|
||||
<a onclick="javascript:selectCategoryMenu('generic');" href="#" id="genericCategoryButton" class="button">Génériques</a>
|
||||
<a onclick="javascript:selectCategoryMenu('web');" href="#" id="webCategoryButton" class="button">Web</a>
|
||||
<a onclick="javascript:selectCategoryMenu('specific');" href="#" id="specificCategoryButton" class="button">Spécifiques</a>
|
||||
<span style="display: inline-block; width: 100px">Type</span>
|
||||
<a onclick="javascript:selectTypeMenu('summary');" href="#" id="summaryTypeButton" class="button">Résumé</a>
|
||||
<a onclick="javascript:selectTypeMenu('generic');" href="#" id="genericTypeButton" class="button">Génériques</a>
|
||||
<a onclick="javascript:selectTypeMenu('web');" href="#" id="webTypeButton" class="button">Web</a>
|
||||
<a onclick="javascript:selectTypeMenu('specific');" href="#" id="specificTypeButton" class="button">Spécifiques</a>
|
||||
</div>
|
||||
<div style="margin: 5px;">
|
||||
<span style="display: inline-block; width: 100px">Période</span>
|
||||
|
@ -36,28 +36,28 @@
|
|||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
function selectCategoryMenu(selection)
|
||||
function selectTypeMenu(selection)
|
||||
{
|
||||
document.getElementById ('summaryCategoryButton').classList.remove('selected');
|
||||
document.getElementById ('genericCategoryButton').classList.remove('selected');
|
||||
document.getElementById ('webCategoryButton').classList.remove('selected');
|
||||
document.getElementById ('specificCategoryButton').classList.remove('selected');
|
||||
document.getElementById ('summaryTypeButton').classList.remove('selected');
|
||||
document.getElementById ('genericTypeButton').classList.remove('selected');
|
||||
document.getElementById ('webTypeButton').classList.remove('selected');
|
||||
document.getElementById ('specificTypeButton').classList.remove('selected');
|
||||
|
||||
if (selection == 'summary')
|
||||
{
|
||||
document.getElementById ('summaryCategoryButton').classList.add('selected');
|
||||
document.getElementById ('summaryTypeButton').classList.add('selected');
|
||||
}
|
||||
else if (selection == 'generic')
|
||||
{
|
||||
document.getElementById ('genericCategoryButton').classList.add('selected');
|
||||
document.getElementById ('genericTypeButton').classList.add('selected');
|
||||
}
|
||||
else if (selection == 'web')
|
||||
{
|
||||
document.getElementById ('webCategoryButton').classList.add('selected');
|
||||
document.getElementById ('webTypeButton').classList.add('selected');
|
||||
}
|
||||
else if (selection == 'specific')
|
||||
{
|
||||
document.getElementById ('specificCategoryButton').classList.add('selected');
|
||||
document.getElementById ('specificTypeButton').classList.add('selected');
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue