466 lines
12 KiB
JavaScript
466 lines
12 KiB
JavaScript
// import CapitalGood from "@ASSET/icon/CapitalGood.svg"; // 上游購買資本物品
|
|
// import CapitalGoodHover from "@ASSET/icon/CapitalGood-h.svg";
|
|
// import upstreamEnergyEmission from "@ASSET/icon/UpstreamEnergyEmission.svg"; // 與能源相關活動
|
|
// import upstreamEnergyEmissionHover from "@ASSET/icon/UpstreamEnergyEmission-h.svg";
|
|
// import Energy from "@ASSET/icon/Energy.svg"; // 外購能源排放
|
|
// import EnergyHover from "@ASSET/icon/Energy-h.svg";
|
|
// import Disposal from "@ASSET/icon/Disposal.svg"; // 上游廢棄
|
|
// import DisposalHover from "@ASSET/icon/Disposal-h.svg";
|
|
// import LeasedAsset from "@ASSET/icon/LeasedAsset.svg"; // 上游租賃資產
|
|
// import LeasedAssetHover from "@ASSET/icon/LeasedAsset-h.svg";
|
|
// import PurchasedGood from "@ASSET/icon/PurchasedGood.svg"; // 購買商品
|
|
// import PurchasedGoodHover from "@ASSET/icon/PurchasedGood-h.svg";
|
|
// import Consultant from "@ASSET/icon/Consultant.svg"; // 購買服務
|
|
// import ConsultantHover from "@ASSET/icon/Consultant-h.svg";
|
|
// import UpstreamTransport from "@ASSET/icon/UpstreamTransport.svg"; // 上游運輸及配送
|
|
// import UpstreamTransportHover from "@ASSET/icon/UpstreamTransport-h.svg";
|
|
// import BusinessTravel from "@ASSET/icon/BusinessTravel.svg"; // 商務旅行
|
|
// import BusinessTravelHover from "@ASSET/icon/BusinessTravel-h.svg";
|
|
// import Visitor from "@ASSET/icon/Visitor.svg"; // 訪客
|
|
// import VisitorHover from "@ASSET/icon/Visitor-h.svg";
|
|
// import Commuting from "@ASSET/icon/Commuting.svg"; // 員工通勤
|
|
// import CommutingHover from "@ASSET/icon/Commuting-h.svg";
|
|
|
|
// import StationaryCombustion from "@ASSET/icon/StationaryCombustion.svg"; // 固定源
|
|
// import StationaryCombustionHover from "@ASSET/icon/StationaryCombustion-h.svg";
|
|
// import MobileCombustion from "@ASSET/icon/MobileCombustion.svg"; // 移動源
|
|
// import MobileCombustionHover from "@ASSET/icon/MobileCombustion-h.svg";
|
|
// import DirectFugitiveEmission from "@ASSET/icon/DirectFugitiveEmission.svg"; // 逸散源
|
|
// import DirectFugitiveEmissionHover from "@ASSET/icon/DirectFugitiveEmission-h.svg";
|
|
// import DirectProcessEmission from "@ASSET/icon/DirectProcessEmission.svg"; // 製程
|
|
// import DirectProcessEmissionHover from "@ASSET/icon/DirectProcessEmission-h.svg";
|
|
// import Electricity from "@ASSET/icon/Electricity.svg"; // 用電量
|
|
// import ElectricityHover from "@ASSET/icon/Electricity-h.svg";
|
|
// import Steam from "@ASSET/icon/Steam.svg"; // 蒸氣
|
|
// import SteamHover from "@ASSET/icon/Steam-h.svg";
|
|
// import Refrigerant from "@ASSET/icon/Refrigerant.svg"; // 冷媒
|
|
// import RefrigerantHover from "@ASSET/icon/Refrigerant-h.svg";
|
|
// import OtherCompound from "@ASSET/icon/OtherCompound.svg"; // 其他關注類
|
|
// import OtherCompoundHover from "@ASSET/icon/OtherCompound-h.svg";
|
|
|
|
// import UseEmission from "@ASSET/icon/UseEmission.svg"; // 下游使用銷售產品
|
|
// import UseEmissionHover from "@ASSET/icon/UseEmission-h.svg";
|
|
// import DownstreamDisposal from "@ASSET/icon/DownstreamDisposal.svg"; // 下銷售產品廢棄處理
|
|
// import DownstreamDisposalHover from "@ASSET/icon/DownstreamDisposal-h.svg";
|
|
// import Investment from "@ASSET/icon/Investment.svg"; // 投資
|
|
// import InvestmentHover from "@ASSET/icon/Investment-h.svg";
|
|
|
|
// import Other from "@ASSET/icon/Other.svg"; // 投資
|
|
// import OtherHover from "@ASSET/icon/Other-h.svg";
|
|
|
|
// import WaterUsages from "@ASSET/icon/WaterUsages.png"; // 水
|
|
// import WaterUsagesHover from "@ASSET/icon/WaterUsagesHover.png";
|
|
|
|
import {
|
|
MONTHCOLUMNS,
|
|
WORKHOURSROW,
|
|
ELECTRICROW,
|
|
REFRIGERANTCOLUMNS,
|
|
} from "./CalculateTableColumn";
|
|
|
|
const alterSourceIcon = (sourceList) =>
|
|
sourceList.map(({ link, icon, hoverIcon, title, children = null }) => ({
|
|
icon,
|
|
hoverIcon,
|
|
title,
|
|
key: link,
|
|
link,
|
|
children,
|
|
}));
|
|
|
|
const sourceIconListForUpstreamS3 = alterSourceIcon([
|
|
{
|
|
icon: "CapitalGood",
|
|
hoverIcon: "CapitalGood-h",
|
|
link: "capitalGood",
|
|
title: "購買資本物品 C4",
|
|
children: [
|
|
{
|
|
title: "購買資本物品 C4",
|
|
editType: "lifecycle",
|
|
link: "capitalGood",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "UpstreamEnergyEmission",
|
|
hoverIcon: "UpstreamEnergyEmission-h",
|
|
link: "upstreamEmissions",
|
|
title: "輸入能源上游排放 C4",
|
|
children: [
|
|
{
|
|
title: "輸入能源上游排放 C4",
|
|
editType: "lifecycle",
|
|
link: "upstreamEmissions",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "WaterUsages",
|
|
hoverIcon: "WaterUsages-h",
|
|
link: "waterUsage",
|
|
title: "用水(水資源管理) C4",
|
|
children: [
|
|
{
|
|
title: "用水(水資源管理) C4",
|
|
editType: "lifecycle",
|
|
link: "waterUsage",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "PurchasedGood",
|
|
hoverIcon: "PurchasedGood-h",
|
|
link: "purchasedGood",
|
|
title: "購買商品 C4",
|
|
children: [
|
|
{
|
|
title: "購買商品 C4",
|
|
editType: "lifecycle",
|
|
link: "purchasedGood",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "LeasedAsset",
|
|
hoverIcon: "LeasedAsset-h",
|
|
link: "leasedAsset",
|
|
title: "上游租賃資產 C4",
|
|
children: [
|
|
{
|
|
title: "上游租賃資產 C4",
|
|
editType: "lifecycle",
|
|
link: "leasedAsset",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "Consultant",
|
|
hoverIcon: "Consultant-h",
|
|
link: "consultant",
|
|
title: "顧問諮詢、清潔、維護等 C4",
|
|
children: [
|
|
{
|
|
title: "顧問諮詢、清潔、維護等 C4",
|
|
editType: "lifecycle",
|
|
link: "consultant",
|
|
},
|
|
],
|
|
},
|
|
]);
|
|
|
|
const sourceIconListForBusinessS2UP = alterSourceIcon([
|
|
{
|
|
icon: "UpstreamTransport",
|
|
hoverIcon: "UpstreamTransport-h",
|
|
link: "upstreamTransport",
|
|
title: "上游運輸及配送 C3",
|
|
children: [
|
|
{
|
|
title: "上游運輸及配送 C3",
|
|
editType: "lifecycle",
|
|
link: "upstreamTransport",
|
|
},
|
|
],
|
|
},
|
|
]);
|
|
|
|
const sourceIconListForBusinessS1 = alterSourceIcon([
|
|
{
|
|
icon: "MobileCombustion",
|
|
hoverIcon: "MobileCombustion-h",
|
|
link: "mobileCombustion",
|
|
title: "移動源 C1",
|
|
children: [
|
|
{
|
|
title: "移動源 C1",
|
|
editType: "yearlyDevice",
|
|
link: "mobileCombustion",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "StationaryCombustion",
|
|
hoverIcon: "StationaryCombustion-h",
|
|
link: "stationaryCombustion",
|
|
title: "固定燃燒源 C1",
|
|
children: [
|
|
{
|
|
title: "固定燃燒源 C1",
|
|
editType: "yearlyDevice",
|
|
link: "stationaryCombustion",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "DirectProcessEmission",
|
|
hoverIcon: "DirectProcessEmission-h",
|
|
link: "directProcessEmission",
|
|
title: "工業製程 C1",
|
|
children: [
|
|
{
|
|
title: "工業製程 C1",
|
|
editType: "yearlyDevice",
|
|
link: "directProcessEmission",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "DirectFugitiveEmission",
|
|
hoverIcon: "DirectFugitiveEmission-h",
|
|
link: "directFugitiveEmission",
|
|
title: "人為逸散 C1",
|
|
children: [
|
|
{
|
|
title: "冷媒設備 B.2.2.d",
|
|
editType: "nonYearlyDevice",
|
|
link: "refrigerant",
|
|
cols: REFRIGERANTCOLUMNS,
|
|
main_system_tag: "ME",
|
|
sub_system_tag: "M10",
|
|
},
|
|
{
|
|
title: "工時計算 B.2.2.d",
|
|
editType: "lifecycle",
|
|
link: "workHour",
|
|
rows: WORKHOURSROW,
|
|
cols: MONTHCOLUMNS,
|
|
data_api: "./mock/workhour.json",
|
|
},
|
|
{
|
|
title: "消防設備 B.2.2.d",
|
|
editType: "nonYearlyDevice",
|
|
link: "fireEquipment",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "OtherCompound",
|
|
hoverIcon: "OtherCompound-h",
|
|
link: "otherCompound",
|
|
title: "其他關注類物質 C1",
|
|
children: [
|
|
{
|
|
title: "其他關注類物質 C1",
|
|
editType: "nonYearlyDevice",
|
|
link: "otherCompound",
|
|
},
|
|
],
|
|
},
|
|
|
|
{
|
|
icon: "Electricity",
|
|
hoverIcon: "Electricity-h",
|
|
link: "electricity",
|
|
title: "輸入電力 C2",
|
|
children: [
|
|
{
|
|
title: "一般用電 B.3.2.a",
|
|
editType: "month",
|
|
link: "plus",
|
|
rows: ELECTRICROW,
|
|
cols: MONTHCOLUMNS,
|
|
main_system_tag: "EE",
|
|
sub_system_tag: "E4",
|
|
data_api: "./mock/electricity.json",
|
|
},
|
|
// {
|
|
// title: "綠電 B.3.2.a",
|
|
// editType: "month",
|
|
// link: "minus",
|
|
// rows: ELECTRICROW,
|
|
// cols: MONTHCOLUMNS,
|
|
// },
|
|
],
|
|
},
|
|
{
|
|
icon: "Steam",
|
|
hoverIcon: "Steam-h",
|
|
link: "steam",
|
|
title: "輸入蒸汽 C2",
|
|
children: [
|
|
{
|
|
title: "蒸氣加項 B.3.2.b",
|
|
editType: "month",
|
|
link: "plus",
|
|
},
|
|
{
|
|
title: "蒸氣減項 B.3.2.b",
|
|
editType: "month",
|
|
link: "minus",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "Visitor",
|
|
hoverIcon: "Visitor-h",
|
|
link: "visitor",
|
|
title: "客戶和訪客運輸 C3",
|
|
children: [
|
|
{
|
|
title: "客戶和訪客運輸 C3",
|
|
editType: "lifecycle",
|
|
link: "visitor",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "BusinessTravel",
|
|
hoverIcon: "BusinessTravel-h",
|
|
link: "businessTravel",
|
|
title: "員工差旅 C3",
|
|
children: [
|
|
{
|
|
title: "員工差旅 C3",
|
|
editType: "lifecycle",
|
|
link: "businessTravel",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "Commuting",
|
|
hoverIcon: "Commuting-h",
|
|
link: "commuting",
|
|
title: "員工通勤 C3",
|
|
children: [
|
|
{
|
|
title: "員工通勤 C3",
|
|
editType: "lifecycle",
|
|
link: "commuting",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "Disposal",
|
|
hoverIcon: "Disposal-h",
|
|
link: "disposal",
|
|
title: "營運產生之廢棄物 C4",
|
|
children: [
|
|
{
|
|
title: "營運產生之廢棄物 C4",
|
|
editType: "lifecycle",
|
|
link: "disposal",
|
|
},
|
|
],
|
|
},
|
|
]);
|
|
|
|
const sourceIconListForBusinessS2Down = alterSourceIcon([
|
|
{
|
|
icon: "UpstreamTransport",
|
|
hoverIcon: "UpstreamTransport-h",
|
|
link: "downstreamTransport",
|
|
title: "下游運輸及配送 C3",
|
|
children: [
|
|
{
|
|
title: "下游運輸及配送 C3",
|
|
editType: "lifecycle",
|
|
link: "downstreamTransport",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "UpstreamTransport",
|
|
hoverIcon: "UpstreamTransport-h",
|
|
link: "disposalDownTransport",
|
|
title: "廢棄物運輸 C3",
|
|
children: [
|
|
{
|
|
title: "廢棄物運輸 C3",
|
|
editType: "lifecycle",
|
|
link: "disposalDownTransport",
|
|
},
|
|
],
|
|
},
|
|
]);
|
|
|
|
const sourceIconListForDownstreamS3 = alterSourceIcon([
|
|
{
|
|
icon: "LeasedAsset",
|
|
hoverIcon: "LeasedAsset-h",
|
|
link: "downLeasedAsset",
|
|
title: "下游租賃資產 C5",
|
|
children: [
|
|
{
|
|
title: "下游租賃資產 C5",
|
|
editType: "lifecycle",
|
|
link: "downLeasedAsset",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "UseEmission",
|
|
hoverIcon: "UseEmission-h",
|
|
link: "useEmission",
|
|
title: "產品使用階段 C5",
|
|
children: [
|
|
{
|
|
title: "產品使用階段 C5",
|
|
editType: "lifecycle",
|
|
link: "useEmission",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "Investment",
|
|
hoverIcon: "Investment-h",
|
|
link: "investment",
|
|
title: "投資 C5",
|
|
children: [
|
|
{
|
|
title: "投資 C5",
|
|
editType: "lifecycle",
|
|
link: "investment",
|
|
},
|
|
],
|
|
},
|
|
{
|
|
icon: "DownstreamDisposal",
|
|
hoverIcon: "DownstreamDisposal-h",
|
|
link: "downstreamDisposal",
|
|
title: "產品壽命終止階段 C5",
|
|
children: [
|
|
{
|
|
title: "產品壽命終止階段 C5",
|
|
editType: "lifecycle",
|
|
link: "downstreamDisposal",
|
|
},
|
|
],
|
|
},
|
|
]);
|
|
|
|
const sourceIconListForOtherS3 = alterSourceIcon([
|
|
{
|
|
icon: "Other",
|
|
hoverIcon: "Other-h",
|
|
link: "other",
|
|
title: "其它間接排放 C6",
|
|
children: [
|
|
{
|
|
title: "其它間接排放 C6",
|
|
editType: "lifecycle",
|
|
link: "other",
|
|
},
|
|
],
|
|
},
|
|
]);
|
|
|
|
const allSourceIconList = [
|
|
...sourceIconListForUpstreamS3,
|
|
...sourceIconListForBusinessS1,
|
|
...sourceIconListForBusinessS2UP,
|
|
...sourceIconListForBusinessS2Down,
|
|
...sourceIconListForDownstreamS3,
|
|
...sourceIconListForOtherS3,
|
|
];
|
|
|
|
export {
|
|
sourceIconListForUpstreamS3,
|
|
sourceIconListForBusinessS1,
|
|
sourceIconListForBusinessS2UP,
|
|
sourceIconListForBusinessS2Down,
|
|
sourceIconListForDownstreamS3,
|
|
sourceIconListForOtherS3,
|
|
allSourceIconList,
|
|
};
|