mirror of
https://github.com/ANL-CEEESA/RELOG.git
synced 2025-12-06 07:48:50 -06:00
Web: Fix parsing of disposal limit
This commit is contained in:
@@ -235,7 +235,7 @@ const InputPage = () => {
|
|||||||
"disposal limit (tonne)",
|
"disposal limit (tonne)",
|
||||||
].forEach((key) => {
|
].forEach((key) => {
|
||||||
newData.plants[plantName][key] = { ...newData.plants[plantName][key] };
|
newData.plants[plantName][key] = { ...newData.plants[plantName][key] };
|
||||||
newData.plants[plantName][key][productName] = 0;
|
newData.plants[plantName][key][productName] = "0";
|
||||||
});
|
});
|
||||||
save(newData);
|
save(newData);
|
||||||
return newData;
|
return newData;
|
||||||
|
|||||||
@@ -277,7 +277,7 @@ export const exportPlant = (original, parameters) => {
|
|||||||
const v = exportValueAcf(dispCost, origDict);
|
const v = exportValueAcf(dispCost, origDict);
|
||||||
if (v) {
|
if (v) {
|
||||||
resDict.disposal[dispName] = { "cost ($/tonne)": v };
|
resDict.disposal[dispName] = { "cost ($/tonne)": v };
|
||||||
const limit = original["disposal limit (tonne)"][dispName];
|
const limit = String(original["disposal limit (tonne)"][dispName]);
|
||||||
if (limit.length > 0) {
|
if (limit.length > 0) {
|
||||||
resDict.disposal[dispName]["limit (tonne)"] = exportValue(
|
resDict.disposal[dispName]["limit (tonne)"] = exportValue(
|
||||||
limit,
|
limit,
|
||||||
|
|||||||
@@ -213,7 +213,7 @@ const samplePlantsOriginal = [
|
|||||||
},
|
},
|
||||||
"disposal limit (tonne)": {
|
"disposal limit (tonne)": {
|
||||||
"Hydrogen gas": "10",
|
"Hydrogen gas": "10",
|
||||||
"Carbon dioxide": "",
|
"Carbon dioxide": 0,
|
||||||
Tar: "",
|
Tar: "",
|
||||||
},
|
},
|
||||||
"emissions (tonne/tonne)": {
|
"emissions (tonne/tonne)": {
|
||||||
@@ -406,6 +406,7 @@ const samplePlantsExported = [
|
|||||||
},
|
},
|
||||||
"Carbon dioxide": {
|
"Carbon dioxide": {
|
||||||
"cost ($/tonne)": [0, 0, 0],
|
"cost ($/tonne)": [0, 0, 0],
|
||||||
|
"limit (tonne)": [0, 0, 0],
|
||||||
},
|
},
|
||||||
Tar: {
|
Tar: {
|
||||||
"cost ($/tonne)": [200, 400, 800],
|
"cost ($/tonne)": [200, 400, 800],
|
||||||
@@ -439,6 +440,7 @@ const samplePlantsExported = [
|
|||||||
},
|
},
|
||||||
"Carbon dioxide": {
|
"Carbon dioxide": {
|
||||||
"cost ($/tonne)": [0, 0, 0],
|
"cost ($/tonne)": [0, 0, 0],
|
||||||
|
"limit (tonne)": [0, 0, 0],
|
||||||
},
|
},
|
||||||
Tar: {
|
Tar: {
|
||||||
"cost ($/tonne)": [100, 200.0, 400],
|
"cost ($/tonne)": [100, 200.0, 400],
|
||||||
|
|||||||
Reference in New Issue
Block a user