added translation of Child Space Total Proportion for SpaceCost in Web UI
parent
4e866dbc58
commit
852bb68ed8
|
@ -84,7 +84,7 @@ const SpaceCost = ({ setRedirect, setRedirectUrl, t }) => {
|
||||||
const [spaceLineChartData, setSpaceLineChartData] = useState({});
|
const [spaceLineChartData, setSpaceLineChartData] = useState({});
|
||||||
const [spaceLineChartOptions, setSpaceLineChartOptions] = useState([]);
|
const [spaceLineChartOptions, setSpaceLineChartOptions] = useState([]);
|
||||||
const [childSpaceProportionList, setChildSpaceProportionList] = useState([]);
|
const [childSpaceProportionList, setChildSpaceProportionList] = useState([]);
|
||||||
const [childSpacetotalProportion, setChildSpacetotalProportion] = useState([]);
|
const [childSpaceSubtotalShareData, setChildSpaceSubtotalShareData] = useState([]);
|
||||||
|
|
||||||
const [parameterLineChartLabels, setParameterLineChartLabels] = useState([]);
|
const [parameterLineChartLabels, setParameterLineChartLabels] = useState([]);
|
||||||
const [parameterLineChartData, setParameterLineChartData] = useState({});
|
const [parameterLineChartData, setParameterLineChartData] = useState({});
|
||||||
|
@ -342,23 +342,22 @@ const SpaceCost = ({ setRedirect, setRedirectUrl, t }) => {
|
||||||
});
|
});
|
||||||
setChildSpaceProportionList(childSpaceProportionArray);
|
setChildSpaceProportionList(childSpaceProportionArray);
|
||||||
|
|
||||||
let childSpacesProportionArray = [];
|
let childSpaceSubtotalShareDataArray = [];
|
||||||
if (json['child_space']['child_space_names_array'].length > 0) {
|
if (json['child_space']['child_space_names_array'].length > 0) {
|
||||||
json['child_space']['child_space_names_array'][0].forEach((currentSpaceName, spaceIndex) => {
|
json['child_space']['child_space_names_array'][0].forEach((currentSpaceName, spaceIndex) => {
|
||||||
let total = 0.0;
|
let subtotal = 0.0;
|
||||||
json['child_space']['energy_category_names'].forEach((currentValue, energyCategoryIndex) => {
|
json['child_space']['energy_category_names'].forEach((currentValue, energyCategoryIndex) => {
|
||||||
total += json['child_space']['subtotals_array'][energyCategoryIndex][spaceIndex]
|
subtotal += json['child_space']['subtotals_array'][energyCategoryIndex][spaceIndex];
|
||||||
total = total.toFixed()
|
|
||||||
});
|
});
|
||||||
let childSpacesProportionItemDataItem = {};
|
let childSpaceSubtotalDataItem = {};
|
||||||
childSpacesProportionItemDataItem['id'] = spaceIndex;
|
childSpaceSubtotalDataItem['id'] = spaceIndex;
|
||||||
childSpacesProportionItemDataItem['name'] = currentSpaceName;
|
childSpaceSubtotalDataItem['name'] = currentSpaceName;
|
||||||
childSpacesProportionItemDataItem['value'] = total;
|
childSpaceSubtotalDataItem['value'] = subtotal;
|
||||||
childSpacesProportionItemDataItem['color'] = "#"+((1<<24)*Math.random()|0).toString(16);
|
childSpaceSubtotalDataItem['color'] = "#"+((1<<24)*Math.random()|0).toString(16);
|
||||||
childSpacesProportionArray.push(childSpacesProportionItemDataItem);
|
childSpaceSubtotalShareDataArray.push(childSpaceSubtotalDataItem);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
setChildSpacetotalProportion(childSpacesProportionArray);
|
setChildSpaceSubtotalShareData(childSpaceSubtotalShareDataArray);
|
||||||
|
|
||||||
let timestamps = {}
|
let timestamps = {}
|
||||||
json['reporting_period']['timestamps'].forEach((currentValue, index) => {
|
json['reporting_period']['timestamps'].forEach((currentValue, index) => {
|
||||||
|
@ -691,8 +690,8 @@ const SpaceCost = ({ setRedirect, setRedirectUrl, t }) => {
|
||||||
))}
|
))}
|
||||||
<Col className="mb-3 pr-lg-2 mb-3">
|
<Col className="mb-3 pr-lg-2 mb-3">
|
||||||
<SharePie
|
<SharePie
|
||||||
data={childSpacetotalProportion}
|
data={childSpaceSubtotalShareData}
|
||||||
title={t('Child Space total Proportion CATEGORY UNIT')}
|
title={t('Child Space Total Proportion')}
|
||||||
/>
|
/>
|
||||||
</Col>
|
</Col>
|
||||||
|
|
||||||
|
|
|
@ -154,7 +154,8 @@ const resources = {
|
||||||
"Reporting Period Consumption ITEM CATEGORY UNIT": "Reporting Period Consumption {{ITEM}} {{CATEGORY}} {{UNIT}}",
|
"Reporting Period Consumption ITEM CATEGORY UNIT": "Reporting Period Consumption {{ITEM}} {{CATEGORY}} {{UNIT}}",
|
||||||
"Reporting Period Consumption ITEM CATEGORY VALUE UNIT": "Reporting Period Consumption {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Reporting Period Consumption ITEM CATEGORY VALUE UNIT": "Reporting Period Consumption {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Base Period Consumption ITEM CATEGORY VALUE UNIT": "Base Period Consumption {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Base Period Consumption ITEM CATEGORY VALUE UNIT": "Base Period Consumption {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Child Space Proportion CATEGORY UNIT": "Child Space Proportion {{CATEGORY}} {{UNIT}}",
|
"Child Space Proportion CATEGORY UNIT": "Child Space Proportion by Energy Category {{CATEGORY}} {{UNIT}}",
|
||||||
|
"Child Space Total Proportion": "Child Space Total Proportion",
|
||||||
"Reporting Period Costs CATEGORY UNIT": "Reporting Period Costs {{CATEGORY}} {{UNIT}}",
|
"Reporting Period Costs CATEGORY UNIT": "Reporting Period Costs {{CATEGORY}} {{UNIT}}",
|
||||||
"Reporting Period Costs CATEGORY VALUE UNIT": "Reporting Period Costs {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Reporting Period Costs CATEGORY VALUE UNIT": "Reporting Period Costs {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Base Period Costs CATEGORY VALUE UNIT": "Base Period Costs {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Base Period Costs CATEGORY VALUE UNIT": "Base Period Costs {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
|
@ -500,7 +501,8 @@ const resources = {
|
||||||
"Reporting Period Consumption ITEM CATEGORY UNIT": "Verbrauch des Berichtszeitraums {{ITEM}} {{CATEGORY}} {{UNIT}}",
|
"Reporting Period Consumption ITEM CATEGORY UNIT": "Verbrauch des Berichtszeitraums {{ITEM}} {{CATEGORY}} {{UNIT}}",
|
||||||
"Reporting Period Consumption ITEM CATEGORY VALUE UNIT": "Verbrauch des Berichtszeitraums {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Reporting Period Consumption ITEM CATEGORY VALUE UNIT": "Verbrauch des Berichtszeitraums {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Base Period Consumption ITEM CATEGORY VALUE UNIT": "Verbrauch des Basiszeitraums {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Base Period Consumption ITEM CATEGORY VALUE UNIT": "Verbrauch des Basiszeitraums {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Child Space Proportion CATEGORY UNIT": "Anteil des Teil Platz {{CATEGORY}} {{UNIT}}",
|
"Child Space Proportion CATEGORY UNIT": "Anteil des Teil Platz nach Energiekategorie {{CATEGORY}} {{UNIT}}",
|
||||||
|
"Child Space Total Proportion": "Anteil des Teil Platz Gesamtanteil",
|
||||||
"Reporting Period Costs CATEGORY UNIT": "Berichtszeitraumkosten {{CATEGORY}} {{UNIT}}",
|
"Reporting Period Costs CATEGORY UNIT": "Berichtszeitraumkosten {{CATEGORY}} {{UNIT}}",
|
||||||
"Reporting Period Costs CATEGORY VALUE UNIT": "Berichtszeitraumkosten {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Reporting Period Costs CATEGORY VALUE UNIT": "Berichtszeitraumkosten {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Base Period Costs CATEGORY VALUE UNIT": "Kosten des Basiszeitraums {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Base Period Costs CATEGORY VALUE UNIT": "Kosten des Basiszeitraums {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
|
@ -838,7 +840,6 @@ const resources = {
|
||||||
"Incomes by Energy Category": "收入占比",
|
"Incomes by Energy Category": "收入占比",
|
||||||
"Electricity Consumption by Time-Of-Use": "分时消耗电量",
|
"Electricity Consumption by Time-Of-Use": "分时消耗电量",
|
||||||
"Electricity Cost by Time-Of-Use": "分时用电成本",
|
"Electricity Cost by Time-Of-Use": "分时用电成本",
|
||||||
"Child Space total Proportion CATEGORY UNIT": "子空间总成本占比",
|
|
||||||
"CATEGORY UNIT Consumption by Energy Items": "{{CATEGORY}} {{UNIT}} 分项消耗占比",
|
"CATEGORY UNIT Consumption by Energy Items": "{{CATEGORY}} {{UNIT}} 分项消耗占比",
|
||||||
"Ton of Standard Coal by Energy Category": "吨标准煤(TCE)占比",
|
"Ton of Standard Coal by Energy Category": "吨标准煤(TCE)占比",
|
||||||
"Ton of Carbon Dioxide Emissions by Energy Category": "吨二氧化碳排放(TCO2E)占比",
|
"Ton of Carbon Dioxide Emissions by Energy Category": "吨二氧化碳排放(TCO2E)占比",
|
||||||
|
@ -850,7 +851,8 @@ const resources = {
|
||||||
"Reporting Period Consumption ITEM CATEGORY UNIT": "报告期消耗 {{ITEM}} {{CATEGORY}} {{UNIT}}",
|
"Reporting Period Consumption ITEM CATEGORY UNIT": "报告期消耗 {{ITEM}} {{CATEGORY}} {{UNIT}}",
|
||||||
"Reporting Period Consumption ITEM CATEGORY VALUE UNIT": "报告期消耗 {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Reporting Period Consumption ITEM CATEGORY VALUE UNIT": "报告期消耗 {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Base Period Consumption ITEM CATEGORY VALUE UNIT": "基准期消耗 {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Base Period Consumption ITEM CATEGORY VALUE UNIT": "基准期消耗 {{ITEM}} {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Child Space Proportion CATEGORY UNIT": "子空间占比 {{CATEGORY}} {{UNIT}}",
|
"Child Space Proportion CATEGORY UNIT": "子空间分类占比 {{CATEGORY}} {{UNIT}}",
|
||||||
|
"Child Space Total Proportion": "子空间总计占比",
|
||||||
"Reporting Period Costs CATEGORY UNIT": "报告期成本 {{CATEGORY}} {{UNIT}}",
|
"Reporting Period Costs CATEGORY UNIT": "报告期成本 {{CATEGORY}} {{UNIT}}",
|
||||||
"Reporting Period Costs CATEGORY VALUE UNIT": "报告期成本 {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Reporting Period Costs CATEGORY VALUE UNIT": "报告期成本 {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
"Base Period Costs CATEGORY VALUE UNIT": "基准期成本 {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
"Base Period Costs CATEGORY VALUE UNIT": "基准期成本 {{CATEGORY}} {{VALUE}} {{UNIT}}",
|
||||||
|
|
Loading…
Reference in New Issue