This commit is contained in:
史萬澤 2023-05-12 10:20:28 +08:00
commit 3e1c5c369c
4098 changed files with 3328010 additions and 0 deletions

12
.build/ResxToJs.targets Normal file
View File

@ -0,0 +1,12 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<UsingTask TaskName="ResxToJsTask" AssemblyFile="..\bin\RequireJsNet.ResxToJs.dll" />
<Target Name="ResxForBuild" AfterTargets="AfterBuild">
<MsBuild Projects="$(MSBuildProjectFile)" Targets="Resources" Properties="DestinationDir=$(MSBuildProjectDirectory)" />
</Target>
<Target Name="ResourcesForDeploy" AfterTargets="CopyAllFilesToSingleFolderForMsdeploy">
<MsBuild Projects="$(MSBuildProjectFile)" Targets="Resources" Properties="DestinationDir=$(_PackageTempDir)" />
</Target>
<Target Name="Resources">
<ResxToJsTask RootResx="..\Resources\Resource.resx" RootJS="$(DestinationDir)\Scripts\Nls\app-resx.js" />
</Target>
</Project>

File diff suppressed because it is too large Load Diff

BIN
.vs/QcarbonDev/v16/.suo Normal file

Binary file not shown.

Binary file not shown.

19
App_Data/Electric.csv Normal file
View File

@ -0,0 +1,19 @@
Default
Default
Default
台灣,華北區域,東北區域,華東區域,華中區域,西北區域,南方區域,海南省
台湾,华北区域,东北区域,华东区域,华中区​​域,西北区域,南方区域,海南省
Taiwan,China north,China eastnorth,China east,China middle,China westnorth,china south,Hainan
0.637,0.993,1.1914,0.9384,1.191,0.9842,0.9422,0.8204
0.632,1.1208,1.2404,0.9421,1.2899,1.1257,1.0119,0.9209
0.631,1.1169,1.2561,0.954,1.2783,1.1225,1.0608,0.8944
0.616,1.0069,1.1293,0.8825,1.1255,1.0246,0.9987,0.8154
0.612,0.9914,1.1109,0.8592,1.0871,0.9947,0.9762,0.7972
0.612,0.9803,1.0852,0.8367,1.0297,1.0001,0.9489,0.7972
0.69,1.0021,1.0935,0.8244,0.9944,0.9913,0.9344,0.9344
0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223
0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223
1 Default
2 Default
3 Default
4 台灣,華北區域,東北區域,華東區域,華中區域,西北區域,南方區域,海南省
5 台湾,华北区域,东北区域,华东区域,华中区​​域,西北区域,南方区域,海南省
6 Taiwan,China north,China eastnorth,China east,China middle,China westnorth,china south,Hainan
7 0.637,0.993,1.1914,0.9384,1.191,0.9842,0.9422,0.8204
8 0.632,1.1208,1.2404,0.9421,1.2899,1.1257,1.0119,0.9209
9 0.631,1.1169,1.2561,0.954,1.2783,1.1225,1.0608,0.8944
10 0.616,1.0069,1.1293,0.8825,1.1255,1.0246,0.9987,0.8154
11 0.612,0.9914,1.1109,0.8592,1.0871,0.9947,0.9762,0.7972
12 0.612,0.9803,1.0852,0.8367,1.0297,1.0001,0.9489,0.7972
13 0.69,1.0021,1.0935,0.8244,0.9944,0.9913,0.9344,0.9344
14 0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223
15 0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223

View File

@ -0,0 +1,15 @@
Default
Default
Default
台灣,華北區域,東北區域,華東區域,華中區域,西北區域,南方區域,海南省
台湾,华北区域,东北区域,华东区域,华中区​​域,西北区域,南方区域,海南省
Taiwan,China north,China eastnorth,China east,China middle,China westnorth,china south,Hainan
0.637,0.993,1.1914,0.9384,1.191,0.9842,0.9422,0.8204
0.632,1.1208,1.2404,0.9421,1.2899,1.1257,1.0119,0.9209
0.631,1.1169,1.2561,0.954,1.2783,1.1225,1.0608,0.8944
0.616,1.0069,1.1293,0.8825,1.1255,1.0246,0.9987,0.8154
0.612,0.9914,1.1109,0.8592,1.0871,0.9947,0.9762,0.7972
0.612,0.9803,1.0852,0.8367,1.0297,1.0001,0.9489,0.7972
0.69,1.0021,1.0935,0.8244,0.9944,0.9913,0.9344,0.9344
0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223
0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223
1 Default
2 Default
3 Default
4 台灣,華北區域,東北區域,華東區域,華中區域,西北區域,南方區域,海南省
5 台湾,华北区域,东北区域,华东区域,华中区​​域,西北区域,南方区域,海南省
6 Taiwan,China north,China eastnorth,China east,China middle,China westnorth,china south,Hainan
7 0.637,0.993,1.1914,0.9384,1.191,0.9842,0.9422,0.8204
8 0.632,1.1208,1.2404,0.9421,1.2899,1.1257,1.0119,0.9209
9 0.631,1.1169,1.2561,0.954,1.2783,1.1225,1.0608,0.8944
10 0.616,1.0069,1.1293,0.8825,1.1255,1.0246,0.9987,0.8154
11 0.612,0.9914,1.1109,0.8592,1.0871,0.9947,0.9762,0.7972
12 0.612,0.9803,1.0852,0.8367,1.0297,1.0001,0.9489,0.7972
13 0.69,1.0021,1.0935,0.8244,0.9944,0.9913,0.9344,0.9344
14 0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223
15 0.69,1.0302,1.112,0.81,0.9779,0.972,0.9223,0.9223

View File

@ -0,0 +1,5 @@
CO2,CO2,CO2,1
FM-200,FM-200,FM-200,3220
Halon1211,Halon1211,Halon1211,1890
Halon1301,Halon1301,Halon1301,7140
Halon2402,Halon2402,Halon2402,1640
1 CO2 CO2 CO2 1
2 FM-200 FM-200 FM-200 3220
3 Halon1211 Halon1211 Halon1211 1890
4 Halon1301 Halon1301 Halon1301 7140
5 Halon2402 Halon2402 Halon2402 1640

View File

@ -0,0 +1,16 @@
固定源柴油KgCO2e/L,移動源柴油KgCO2e/L
固定源柴油KgCO2e/L,移动源柴油KgCO2e/L
Stationary source diesel KgCO2e/L, mobile source diesel KgCO2e/L
台灣,大陸
台湾,大陆
Taiwan,China
2.7393608,2.663496192,2.776512,2.69971044
2.7393608,2.663496192,2.776512,2.69971044
2.7393608,2.663496192,2.776512,2.69971044
2.614908,2.663496192,2.650251,2.69971044
2.614908,2.663496192,2.650251,2.69971044
2.614908,2.663496192,2.650251,2.69971044
3.45,2.667,3.45,2.703
3.45,2.667,3.45,2.703
3.45,2.667,3.45,2.703
1 固定源柴油KgCO2e/L,移動源柴油KgCO2e/L
2 固定源柴油KgCO2e/L,移动源柴油KgCO2e/L
3 Stationary source diesel KgCO2e/L, mobile source diesel KgCO2e/L
4 台灣,大陸
5 台湾,大陆
6 Taiwan,China
7 2.7393608,2.663496192,2.776512,2.69971044
8 2.7393608,2.663496192,2.776512,2.69971044
9 2.7393608,2.663496192,2.776512,2.69971044
10 2.614908,2.663496192,2.650251,2.69971044
11 2.614908,2.663496192,2.650251,2.69971044
12 2.614908,2.663496192,2.650251,2.69971044
13 3.45,2.667,3.45,2.703
14 3.45,2.667,3.45,2.703
15 3.45,2.667,3.45,2.703

16
App_Data/Kitchen.csv Normal file
View File

@ -0,0 +1,16 @@
無煙煤KgCO2e/Kg,天然氣KgCO2e/M3,液化石油氣KgCO2e/Kg,固定源汽油KgCO2e/L,重油KgCO2e/L,環保油
无烟煤KgCO2e/Kg,天然气KgCO2e/M3,液化石油气KgCO2e/Kg,固定源汽油KgCO2e/L,重油KgCO2e/L,环保油
Anthracite KgCO2e/Kg, gas KgCO2e/M3, LPG KgCO2e/Kg, fixed source of gasoline KgCO2e/L, heavy KgCO2e/L, green oil
台灣,大陸
台湾,大陆
Taiwan,China
2.9340333,2.09204404,2.09204404,2.1921372,3.243561926,3.17275096,2.2682908,2.18925029,2.9875788,3.179115944,,
2.9340333,2.09204404,2.09204404,2.1921372,3.243561926,3.17275096,2.2682908,2.18925029,2.9875788,3.179115944,,
2.9340333,2.09204404,2.09204404,2.1921372,3.243561926,3.17275096,2.2682908,2.18925029,2.9875788,3.179115944,,
2.93616,1.880719,1.880719,2.1921372,3.249248148,3.17275096,2.27141,2.18925029,3.121177,3.179115944,,
2.93616,1.880719,1.880719,2.1921372,3.249248148,3.17275096,2.27141,2.18925029,3.121177,3.179115944,,
2.93616,1.880719,1.880719,2.1921372,3.249248148,3.17275096,2.27141,2.18925029,3.121177,3.179115944,,
2.93616,1.99023,2.52,2.1888,2.09,3.1729982,3,2.189229763,3.121177,3.204066764,,1.496
2.93616,1.99023,2.52,2.1888,2.09,3.1729982,3,2.189229763,3.121177,3.204066764,,1.496
2.93616,1.99023,2.52,2.1888,2.09,3.1729982,3,2.189229763,3.121177,3.204066764,,1.496
1 無煙煤KgCO2e/Kg,天然氣KgCO2e/M3,液化石油氣KgCO2e/Kg,固定源汽油KgCO2e/L,重油KgCO2e/L,環保油
2 无烟煤KgCO2e/Kg,天然气KgCO2e/M3,液化石油气KgCO2e/Kg,固定源汽油KgCO2e/L,重油KgCO2e/L,环保油
3 Anthracite KgCO2e/Kg, gas KgCO2e/M3, LPG KgCO2e/Kg, fixed source of gasoline KgCO2e/L, heavy KgCO2e/L, green oil
4 台灣,大陸
5 台湾,大陆
6 Taiwan,China
7 2.9340333,2.09204404,2.09204404,2.1921372,3.243561926,3.17275096,2.2682908,2.18925029,2.9875788,3.179115944,,
8 2.9340333,2.09204404,2.09204404,2.1921372,3.243561926,3.17275096,2.2682908,2.18925029,2.9875788,3.179115944,,
9 2.9340333,2.09204404,2.09204404,2.1921372,3.243561926,3.17275096,2.2682908,2.18925029,2.9875788,3.179115944,,
10 2.93616,1.880719,1.880719,2.1921372,3.249248148,3.17275096,2.27141,2.18925029,3.121177,3.179115944,,
11 2.93616,1.880719,1.880719,2.1921372,3.249248148,3.17275096,2.27141,2.18925029,3.121177,3.179115944,,
12 2.93616,1.880719,1.880719,2.1921372,3.249248148,3.17275096,2.27141,2.18925029,3.121177,3.179115944,,
13 2.93616,1.99023,2.52,2.1888,2.09,3.1729982,3,2.189229763,3.121177,3.204066764,,1.496
14 2.93616,1.99023,2.52,2.1888,2.09,3.1729982,3,2.189229763,3.121177,3.204066764,,1.496
15 2.93616,1.99023,2.52,2.1888,2.09,3.1729982,3,2.189229763,3.121177,3.204066764,,1.496

View File

@ -0,0 +1,48 @@
1,PC外殼採購量(Kg),PC外殼採購量(Kg),PC外殼採購量(Kg)
1,套袋(PE袋),套袋(PE袋),套袋(PE袋)
1,線材,線材,線材
1,一次側大電容,一次側大電容,一次側大電容
1,PCB,PCB,PCB
1,主變壓器,主變壓器,主變壓器
1,半導體控制IC,半導體控制IC,半導體控制IC
1,洗板水,洗板水,洗板水
1,錫棒,錫棒,錫棒
2,PC外殼採購量(Kg),PC外殼採購量(Kg),PC外殼採購量(Kg)
2,套袋(PE袋),套袋(PE袋),套袋(PE袋)
2,線材,線材,線材
2,一次側大電容,一次側大電容,一次側大電容
2,PCB,PCB,PCB
2,主變壓器,主變壓器,主變壓器
2,半導體控制IC,半導體控制IC,半導體控制IC
2,洗板水,洗板水,洗板水
2,錫棒,錫棒,錫棒
2,商務旅行(國際),商務旅行(國際),商務旅行(國際)
2,員工通勤,員工通勤,員工通勤
2,客戶和訪客運輸造成之排放,客戶和訪客運輸造成之排放,客戶和訪客運輸造成之排放
3,車輛用油上游能源採購,車輛用油上游能源採購,車輛用油上游能源採購
3,電力上游能源採購,電力上游能源採購,電力上游能源採購
3,C2外購電力,C2外購電力,C2外購電力
3,用水,用水,用水
3,上游租賃,上游租賃,上游租賃
3,各項投資所產生之溫室氣體排放,各項投資所產生之溫室氣體排放,各項投資所產生之溫室氣體排放
3,購買顧問服務,購買顧問服務,購買顧問服務
3,C2輸入能源,C2輸入能源,C2輸入能源
3,資本貨物,資本貨物,資本貨物
3,下游租賃,下游租賃,下游租賃
4,廢棄物運輸,廢棄物運輸,廢棄物運輸
4,回收物運輸,回收物運輸,回收物運輸
4,貨物運輸(陸運),貨物運輸(陸運),貨物運輸(陸運)
4,貨物運輸(海運),貨物運輸(海運),貨物運輸(海運)
5,產品使用造成溫室氣體排放,產品使用造成溫室氣體排放,產品使用造成溫室氣體排放
5,產品廢棄階段溫室氣體排放(回收),產品廢棄階段溫室氣體排放(回收),產品廢棄階段溫室氣體排放(回收)
5,產品廢棄階段溫室氣體排放(焚化),產品廢棄階段溫室氣體排放(焚化),產品廢棄階段溫室氣體排放(焚化)
6,碎編帶,碎編帶,碎編帶
6,長編帶,長編帶,長編帶
6,元件腳,元件腳,元件腳
6,空管(IC空管),空管(IC空管),空管(IC空管)
6,膠紙,膠紙,膠紙
6,廢膠罐,廢膠罐,廢膠罐
6,鐵皮,鐵皮,鐵皮
6,廢紙皮,廢紙皮,廢紙皮
6,紙碎電子帶,紙碎電子帶,紙碎電子帶
6,一般事业废弃物处理,一般事业废弃物处理,一般事业废弃物处理
1 1 PC外殼採購量(Kg) PC外殼採購量(Kg) PC外殼採購量(Kg)
2 1 套袋(PE袋) 套袋(PE袋) 套袋(PE袋)
3 1 線材 線材 線材
4 1 一次側大電容 一次側大電容 一次側大電容
5 1 PCB PCB PCB
6 1 主變壓器 主變壓器 主變壓器
7 1 半導體控制IC 半導體控制IC 半導體控制IC
8 1 洗板水 洗板水 洗板水
9 1 錫棒 錫棒 錫棒
10 2 PC外殼採購量(Kg) PC外殼採購量(Kg) PC外殼採購量(Kg)
11 2 套袋(PE袋) 套袋(PE袋) 套袋(PE袋)
12 2 線材 線材 線材
13 2 一次側大電容 一次側大電容 一次側大電容
14 2 PCB PCB PCB
15 2 主變壓器 主變壓器 主變壓器
16 2 半導體控制IC 半導體控制IC 半導體控制IC
17 2 洗板水 洗板水 洗板水
18 2 錫棒 錫棒 錫棒
19 2 商務旅行(國際) 商務旅行(國際) 商務旅行(國際)
20 2 員工通勤 員工通勤 員工通勤
21 2 客戶和訪客運輸造成之排放 客戶和訪客運輸造成之排放 客戶和訪客運輸造成之排放
22 3 車輛用油上游能源採購 車輛用油上游能源採購 車輛用油上游能源採購
23 3 電力上游能源採購 電力上游能源採購 電力上游能源採購
24 3 C2外購電力 C2外購電力 C2外購電力
25 3 用水 用水 用水
26 3 上游租賃 上游租賃 上游租賃
27 3 各項投資所產生之溫室氣體排放 各項投資所產生之溫室氣體排放 各項投資所產生之溫室氣體排放
28 3 購買顧問服務 購買顧問服務 購買顧問服務
29 3 C2輸入能源 C2輸入能源 C2輸入能源
30 3 資本貨物 資本貨物 資本貨物
31 3 下游租賃 下游租賃 下游租賃
32 4 廢棄物運輸 廢棄物運輸 廢棄物運輸
33 4 回收物運輸 回收物運輸 回收物運輸
34 4 貨物運輸(陸運) 貨物運輸(陸運) 貨物運輸(陸運)
35 4 貨物運輸(海運) 貨物運輸(海運) 貨物運輸(海運)
36 5 產品使用造成溫室氣體排放 產品使用造成溫室氣體排放 產品使用造成溫室氣體排放
37 5 產品廢棄階段溫室氣體排放(回收) 產品廢棄階段溫室氣體排放(回收) 產品廢棄階段溫室氣體排放(回收)
38 5 產品廢棄階段溫室氣體排放(焚化) 產品廢棄階段溫室氣體排放(焚化) 產品廢棄階段溫室氣體排放(焚化)
39 6 碎編帶 碎編帶 碎編帶
40 6 長編帶 長編帶 長編帶
41 6 元件腳 元件腳 元件腳
42 6 空管(IC空管) 空管(IC空管) 空管(IC空管)
43 6 膠紙 膠紙 膠紙
44 6 廢膠罐 廢膠罐 廢膠罐
45 6 鐵皮 鐵皮 鐵皮
46 6 廢紙皮 廢紙皮 廢紙皮
47 6 紙碎電子帶 紙碎電子帶 紙碎電子帶
48 6 一般事业废弃物处理 一般事业废弃物处理 一般事业废弃物处理

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,33 @@
Carbon tetrachloride,Carbon tetrachloride,Carbon tetrachloride,1400
Methyl bromide,Methyl bromide,Methyl bromide,5
Methyl chloroform,Methyl chloroform,Methyl chloroform,146
Sulfur hexafluoride,Sulfur hexafluoride,Sulfur hexafluoride,22800
Nitrogen trifluoride,Nitrogen trifluoride,Nitrogen trifluoride,17200
PFC-14,PFC-14,PFC-14,7390
PFC-116,PFC-116,PFC-116,12200
PFC-218,PFC-218,PFC-218,8830
PFC-318,PFC-318,PFC-318,10300
PFC-3-1-10,PFC-3-1-10,PFC-3-1-10,8860
PFC-4-1-12,PFC-4-1-12,PFC-4-1-12,9160
PFC-5-1-14,PFC-5-1-14,PFC-5-1-14,9300
PFC-9-1-18,PFC-9-1-18,PFC-9-1-18,7500
Trifluoromethyl sulfurpentafluoride,Trifluoromethyl sulfurpentafluoride,Trifluoromethyl sulfurpentafluoride,17700
HFE-125,HFE-125,HFE-125,14900
HFE-134,HFE-134,HFE-134,6320
HFE-1343a,HFE-1343a,HFE-1343a,750
HCFE-235da2,HCFE-235da2,HCFE-235da2,350
HFE-245cb2,HFE-245cb2,HFE-245cb2,708
HFE-245fa2,HFE-245fa2,HFE-245fa2,659
HFE-254cb2,HFE-254cb2,HFE-254cb2,359
HFE-347pcf2,HFE-347pcf2,HFE-347pcf2,580
HFE-356pcc3,HFE-356pcc3,HFE-356pcc3,110
HFE-449sl(HFE-7100),HFE-449sl(HFE-7100),HFE-449sl(HFE-7100),297
HFE-569sf2(HFE-7200),HFE-569sf2(HFE-7200),HFE-569sf2(HFE-7200),59
HFE-43-10-pccc124(H-Galden 1040x),HFE-43-10-pccc124(H-Galden 1040x),HFE-43-10-pccc124(H-Galden 1040x),1870
HFE-236ca12(HG-10),HFE-236ca12(HG-10),HFE-236ca12(HG-10),2800
HFE-338pcc13(HG-01),HFE-338pcc13(HG-01),HFE-338pcc13(HG-01),1500
PFPMIE,PFPMIE,PFPMIE,10300
Dimethylether,Dimethylether,Dimethylether,1
Methylene chloride,Methylene chloride,Methylene chloride,8.7
CO2,CO2,CO2,1
Methyl chloride,Methyl chloride,Methyl chloride,13
1 Carbon tetrachloride Carbon tetrachloride Carbon tetrachloride 1400
2 Methyl bromide Methyl bromide Methyl bromide 5
3 Methyl chloroform Methyl chloroform Methyl chloroform 146
4 Sulfur hexafluoride Sulfur hexafluoride Sulfur hexafluoride 22800
5 Nitrogen trifluoride Nitrogen trifluoride Nitrogen trifluoride 17200
6 PFC-14 PFC-14 PFC-14 7390
7 PFC-116 PFC-116 PFC-116 12200
8 PFC-218 PFC-218 PFC-218 8830
9 PFC-318 PFC-318 PFC-318 10300
10 PFC-3-1-10 PFC-3-1-10 PFC-3-1-10 8860
11 PFC-4-1-12 PFC-4-1-12 PFC-4-1-12 9160
12 PFC-5-1-14 PFC-5-1-14 PFC-5-1-14 9300
13 PFC-9-1-18 PFC-9-1-18 PFC-9-1-18 7500
14 Trifluoromethyl sulfurpentafluoride Trifluoromethyl sulfurpentafluoride Trifluoromethyl sulfurpentafluoride 17700
15 HFE-125 HFE-125 HFE-125 14900
16 HFE-134 HFE-134 HFE-134 6320
17 HFE-1343a HFE-1343a HFE-1343a 750
18 HCFE-235da2 HCFE-235da2 HCFE-235da2 350
19 HFE-245cb2 HFE-245cb2 HFE-245cb2 708
20 HFE-245fa2 HFE-245fa2 HFE-245fa2 659
21 HFE-254cb2 HFE-254cb2 HFE-254cb2 359
22 HFE-347pcf2 HFE-347pcf2 HFE-347pcf2 580
23 HFE-356pcc3 HFE-356pcc3 HFE-356pcc3 110
24 HFE-449sl(HFE-7100) HFE-449sl(HFE-7100) HFE-449sl(HFE-7100) 297
25 HFE-569sf2(HFE-7200) HFE-569sf2(HFE-7200) HFE-569sf2(HFE-7200) 59
26 HFE-43-10-pccc124(H-Galden 1040x) HFE-43-10-pccc124(H-Galden 1040x) HFE-43-10-pccc124(H-Galden 1040x) 1870
27 HFE-236ca12(HG-10) HFE-236ca12(HG-10) HFE-236ca12(HG-10) 2800
28 HFE-338pcc13(HG-01) HFE-338pcc13(HG-01) HFE-338pcc13(HG-01) 1500
29 PFPMIE PFPMIE PFPMIE 10300
30 Dimethylether Dimethylether Dimethylether 1
31 Methylene chloride Methylene chloride Methylene chloride 8.7
32 CO2 CO2 CO2 1
33 Methyl chloride Methyl chloride Methyl chloride 13

BIN
App_Data/Refrigerant.csv Normal file

Binary file not shown.
1 家用冰箱 家用冰箱 Household refrigerators 0.003
2 飲水機 饮水机 drinking fountains 0.003
3 除濕機 除湿机 dehumidifiers 0.003
4 餐廳冷藏櫃 餐厅冷藏柜 restaurant freezers 0.08
5 恆溫恆濕機 恒温恒湿机 constant temperature and humidity 0.08
6 冰水主機 冰水主机 chiller 0.085
7 分離式冷氣 分离式冷气 split air conditioners 0.055
8 公務車 公务车 official cars 0.15
9 家用冷凍冷藏設備 家用冷冻冷藏设备 household refrigeration equipment 0.003
10 獨立商用冷凍冷藏設備 独立商用冷冻冷藏设备 commercial refrigeration equipment independent 0.08
11 中大型冷凍冷藏設備 中大型冷冻冷藏设备 medium and large refrigeration equipment 0.225
12 交通用冷凍冷藏設備 交通用冷冻冷藏设备 traffic refrigerated equipment 0.325
13 工業冷凍冷藏設備 工业冷冻冷藏设备 industrial refrigeration equipment 0.16
14 冰水機 冰水机 ice machines 0.085
15 住宅及商業建築冷氣機 住宅及商业建筑冷气机 residential and commercial building air conditioners 0.055
16 移動式空氣清淨機 移动式空气清净机 portable air cleaners 0.15

View File

@ -0,0 +1,75 @@
R-11,R-11,R-11,4750
R-12,R-12,R-12,10900
R-113,R-113,R-113,6130
R-114,R-114,R-114,10000
R-115,R-115,R-115,7370
R-22,R-22,R-22,1810
R-123,R-123,R-123,77
R-124,R-124,R-124,609
R-141b,R-141b,R-141b,725
R-142b,R-142b,R-142b,2310
R-23,R-23,R-23,14800
R-32,R-32,R-32,675
R-41,R-41,R-41,150
R-125,R-125,R-125,3500
R-134,R-134,R-134,1100
R-134a,R-134a,R-134a,1430
R-143,R-143,R-143,3300
R-143a,R-143a,R-143a,4470
R-152,R-152,R-152,12
R-152a,R-152a,R-152a,124
HFC-43-10mee,HFC-43-10mee,HFC-43-10mee,1640
R-161,R-161,R-161,1.1
R-401a,R-401a,R-401a,1182
R-401b,R-401b,R-401b,1288
R-401c,R-401c,R-401c,933
R-402a,R-402a,R-402a,2788
R-402b,R-402b,R-402b,2416
R-403a,R-403a,R-403a,1534
R-403b,R-403b,R-403b,4457
R-404a,R-404a,R-404a,3922
R-405a,R-405a,R-405a,5328
R-406a,R-406a,R-406a,1943
R-407a,R-407a,R-407a,2107
R-407b,R-407b,R-407b,2804
R-407c,R-407c,R-407c,1774
R-407d,R-407d,R-407d,1627
R-407e,R-407e,R-407e,1552
R-408a,R-408a,R-408a,3152
R-409a,R-409a,R-409a,1585
R-409b,R-409b,R-409b,1560
R-410a,R-410a,R-410a,2088
R-410b,R-410b,R-410b,1946
R-411a,R-411a,R-411a,1597
R-411b,R-411b,R-411b,1705
R-411c,R-411c,R-411c,1730
R-412a,R-412a,R-412a,2286
R-413a,R-413a,R-413a,2053
R-414a,R-414a,R-414a,1478
R-414b,R-414b,R-414b,1362
R-415a,R-415a,R-415a,1507
R-415b,R-415b,R-415b,546
R-416a,R-416a,R-416a,1084
R-417a,R-417a,R-417a,2346
R-418a,R-418a,R-418a,1741
R-419a,R-419a,R-419a,2967
R-420a,R-420a,R-420a,1536
R-421a,R-421a,R-421a,2631
R-421b,R-421b,R-421b,3190
R-422a,R-422a,R-422a,3143
R-422b,R-422b,R-422b,2526
R-422c,R-422c,R-422c,3085
R-500,R-500,R-500,8077
R-501,R-501,R-501,4083
R-502,R-502,R-502,4657
R-503,R-503,R-503,14560
R-504,R-504,R-504,4143
R-505,R-505,R-505,8502
R-506,R-506,R-506,4490
R-507a,R-507a,R-507a,3985
R-507,R-507,R-507,3800
R-508a,R-508a,R-508a,13214
R-508b,R-508b,R-508b,13396
R-509a,R-509a,R-509a,5741
FX80,FX80,FX80,2360
Others,Others,Others,0
1 R-11 R-11 R-11 4750
2 R-12 R-12 R-12 10900
3 R-113 R-113 R-113 6130
4 R-114 R-114 R-114 10000
5 R-115 R-115 R-115 7370
6 R-22 R-22 R-22 1810
7 R-123 R-123 R-123 77
8 R-124 R-124 R-124 609
9 R-141b R-141b R-141b 725
10 R-142b R-142b R-142b 2310
11 R-23 R-23 R-23 14800
12 R-32 R-32 R-32 675
13 R-41 R-41 R-41 150
14 R-125 R-125 R-125 3500
15 R-134 R-134 R-134 1100
16 R-134a R-134a R-134a 1430
17 R-143 R-143 R-143 3300
18 R-143a R-143a R-143a 4470
19 R-152 R-152 R-152 12
20 R-152a R-152a R-152a 124
21 HFC-43-10mee HFC-43-10mee HFC-43-10mee 1640
22 R-161 R-161 R-161 1.1
23 R-401a R-401a R-401a 1182
24 R-401b R-401b R-401b 1288
25 R-401c R-401c R-401c 933
26 R-402a R-402a R-402a 2788
27 R-402b R-402b R-402b 2416
28 R-403a R-403a R-403a 1534
29 R-403b R-403b R-403b 4457
30 R-404a R-404a R-404a 3922
31 R-405a R-405a R-405a 5328
32 R-406a R-406a R-406a 1943
33 R-407a R-407a R-407a 2107
34 R-407b R-407b R-407b 2804
35 R-407c R-407c R-407c 1774
36 R-407d R-407d R-407d 1627
37 R-407e R-407e R-407e 1552
38 R-408a R-408a R-408a 3152
39 R-409a R-409a R-409a 1585
40 R-409b R-409b R-409b 1560
41 R-410a R-410a R-410a 2088
42 R-410b R-410b R-410b 1946
43 R-411a R-411a R-411a 1597
44 R-411b R-411b R-411b 1705
45 R-411c R-411c R-411c 1730
46 R-412a R-412a R-412a 2286
47 R-413a R-413a R-413a 2053
48 R-414a R-414a R-414a 1478
49 R-414b R-414b R-414b 1362
50 R-415a R-415a R-415a 1507
51 R-415b R-415b R-415b 546
52 R-416a R-416a R-416a 1084
53 R-417a R-417a R-417a 2346
54 R-418a R-418a R-418a 1741
55 R-419a R-419a R-419a 2967
56 R-420a R-420a R-420a 1536
57 R-421a R-421a R-421a 2631
58 R-421b R-421b R-421b 3190
59 R-422a R-422a R-422a 3143
60 R-422b R-422b R-422b 2526
61 R-422c R-422c R-422c 3085
62 R-500 R-500 R-500 8077
63 R-501 R-501 R-501 4083
64 R-502 R-502 R-502 4657
65 R-503 R-503 R-503 14560
66 R-504 R-504 R-504 4143
67 R-505 R-505 R-505 8502
68 R-506 R-506 R-506 4490
69 R-507a R-507a R-507a 3985
70 R-507 R-507 R-507 3800
71 R-508a R-508a R-508a 13214
72 R-508b R-508b R-508b 13396
73 R-509a R-509a R-509a 5741
74 FX80 FX80 FX80 2360
75 Others Others Others 0

View File

@ -0,0 +1,7 @@
R-11,R-12,R-113,R-114,R-115,R-22,R-123,R-124,R-141b,R-142b,R-23,R-32,R-41,R-125,R-134,R-134a,R-143,R-143a,R-152,R-152a,HFC-43-10mee,R-161,R-401a,R-401b,R-401c,R-402a,R-402b,R-403a,R-403b,R-404a,R-405a,R-406a,R-407a,R-407b,R-407c,R-407d,R-407e,R-408a,R-409a,R-409b,R-410a,R-410b,R-411a,R-411b,R-411c,R-412a,R-413a,R-414a,R-414b,R-415a,R-415b,R-416a,R-417a,R-418a,R-419a,R-420a,R-421a,R-421b,R-422a,R-422b,R-422c,R-500,R-501,R-502,R-503,R-504,R-505,R-506,R-507a,R-507,R-508a,R-508b,R-509a,FX80,Others
R-11,R-12,R-113,R-114,R-115,R-22,R-123,R-124,R-141b,R-142b,R-23,R-32,R-41,R-125,R-134,R-134a,R-143,R-143a,R-152,R-152a,HFC-43-10mee,R-161,R-401a,R-401b,R-401c,R-402a,R-402b,R-403a,R-403b,R-404a,R-405a,R-406a,R-407a,R-407b,R-407c,R-407d,R-407e,R-408a,R-409a,R-409b,R-410a,R-410b,R-411a,R-411b,R-411c,R-412a,R-413a,R-414a,R-414b,R-415a,R-415b,R-416a,R-417a,R-418a,R-419a,R-420a,R-421a,R-421b,R-422a,R-422b,R-422c,R-500,R-501,R-502,R-503,R-504,R-505,R-506,R-507a,R-507,R-508a,R-508b,R-509a,FX80,Others
R-11,R-12,R-113,R-114,R-115,R-22,R-123,R-124,R-141b,R-142b,R-23,R-32,R-41,R-125,R-134,R-134a,R-143,R-143a,R-152,R-152a,HFC-43-10mee,R-161,R-401a,R-401b,R-401c,R-402a,R-402b,R-403a,R-403b,R-404a,R-405a,R-406a,R-407a,R-407b,R-407c,R-407d,R-407e,R-408a,R-409a,R-409b,R-410a,R-410b,R-411a,R-411b,R-411c,R-412a,R-413a,R-414a,R-414b,R-415a,R-415b,R-416a,R-417a,R-418a,R-419a,R-420a,R-421a,R-421b,R-422a,R-422b,R-422c,R-500,R-501,R-502,R-503,R-504,R-505,R-506,R-507a,R-507,R-508a,R-508b,R-509a,FX80,Others
4750,10900,6130,10000,7370,1810,77,609,725,2310,14800,675,150,3500,1100,1430,3300,4470,12,124,1640,1.1,1182,1288,933,2788,2416,1534,4457,3922,5328,1943,2107,2804,1774,1627,1552,3152,1585,1560,2088,1946,1597,1705,1730,2286,2053,1478,1362,1507,546,1084,2346,1741,2967,1536,2631,3190,3143,2526,3085,8077,4083,4657,14560,4143,8502,4490,3985,3800,13214,13396,5741,2360,0
1 R-11 R-12 R-113 R-114 R-115 R-22 R-123 R-124 R-141b R-142b R-23 R-32 R-41 R-125 R-134 R-134a R-143 R-143a R-152 R-152a HFC-43-10mee R-161 R-401a R-401b R-401c R-402a R-402b R-403a R-403b R-404a R-405a R-406a R-407a R-407b R-407c R-407d R-407e R-408a R-409a R-409b R-410a R-410b R-411a R-411b R-411c R-412a R-413a R-414a R-414b R-415a R-415b R-416a R-417a R-418a R-419a R-420a R-421a R-421b R-422a R-422b R-422c R-500 R-501 R-502 R-503 R-504 R-505 R-506 R-507a R-507 R-508a R-508b R-509a FX80 Others
2 R-11 R-12 R-113 R-114 R-115 R-22 R-123 R-124 R-141b R-142b R-23 R-32 R-41 R-125 R-134 R-134a R-143 R-143a R-152 R-152a HFC-43-10mee R-161 R-401a R-401b R-401c R-402a R-402b R-403a R-403b R-404a R-405a R-406a R-407a R-407b R-407c R-407d R-407e R-408a R-409a R-409b R-410a R-410b R-411a R-411b R-411c R-412a R-413a R-414a R-414b R-415a R-415b R-416a R-417a R-418a R-419a R-420a R-421a R-421b R-422a R-422b R-422c R-500 R-501 R-502 R-503 R-504 R-505 R-506 R-507a R-507 R-508a R-508b R-509a FX80 Others
3 R-11 R-12 R-113 R-114 R-115 R-22 R-123 R-124 R-141b R-142b R-23 R-32 R-41 R-125 R-134 R-134a R-143 R-143a R-152 R-152a HFC-43-10mee R-161 R-401a R-401b R-401c R-402a R-402b R-403a R-403b R-404a R-405a R-406a R-407a R-407b R-407c R-407d R-407e R-408a R-409a R-409b R-410a R-410b R-411a R-411b R-411c R-412a R-413a R-414a R-414b R-415a R-415b R-416a R-417a R-418a R-419a R-420a R-421a R-421b R-422a R-422b R-422c R-500 R-501 R-502 R-503 R-504 R-505 R-506 R-507a R-507 R-508a R-508b R-509a FX80 Others
4 4750 10900 6130 10000 7370 1810 77 609 725 2310 14800 675 150 3500 1100 1430 3300 4470 12 124 1640 1.1 1182 1288 933 2788 2416 1534 4457 3922 5328 1943 2107 2804 1774 1627 1552 3152 1585 1560 2088 1946 1597 1705 1730 2286 2053 1478 1362 1507 546 1084 2346 1741 2967 1536 2631 3190 3143 2526 3085 8077 4083 4657 14560 4143 8502 4490 3985 3800 13214 13396 5741 2360 0

BIN
App_Data/Septic.csv Normal file

Binary file not shown.
1 排放因子(kgCH4/kgBOD) 排放因子(kgCH4/kgBOD) Emission Factor (kgCH4 / kgBOD) 0.6
2 汙水濃度(mg/L) 污水浓度(mg/L) effluent concentration (mg / L) 200
3 每人每天污水量(L/day) 每人每天污水量(L/day) the amount of sewage per day (L / day) 125
4 化糞池處理效率(85%) 化粪池处理效率(85%) septic treatment efficiency (85%) 0.85
5 單位換算(10^-6 kg/mg) 单位换算(10^-6 kg/mg) unit conversion per person (10 ^ -6 kg / mg) 0.000001
6 GWP GWP GWP 25

15
App_Data/Steam.csv Normal file
View File

@ -0,0 +1,15 @@
Default
Default
Default
台灣,大陸
台湾,大陸
Taiwan,China
0.319565,0.319565
0.319565,0.319565
0.319565,0.319565
0.319565,0.319565
0.319511,0.319511
0.319511,0.319511
0.319511,0.319511
0.319511,0.319511
0.319511,0.319511
1 Default
2 Default
3 Default
4 台灣,大陸
5 台湾,大陸
6 Taiwan,China
7 0.319565,0.319565
8 0.319565,0.319565
9 0.319565,0.319565
10 0.319565,0.319565
11 0.319511,0.319511
12 0.319511,0.319511
13 0.319511,0.319511
14 0.319511,0.319511
15 0.319511,0.319511

View File

@ -0,0 +1 @@


11
App_Data/Transport.csv Normal file
View File

@ -0,0 +1,11 @@
陸運_運輸 貨車 3.5-7.5噸 EURO5/RER S , 陆运_运输 货车3.5-7.5吨EURO5/ RER S,Road_Transport lorry 3.5-7.5t EURO5/RER S,0.484
陸運_運輸 貨車 7.5-16噸 EURO5/RER S , 陆运_运输 货车 7.5-16吨EURO5/ RER S,Road_Transport lorry 7.5-16t EURO5/RER S ,0.238
陸運_運輸 貨車 Delivery van <3.5t,陆运_运输 货车 Delivery van <3.5t,Road_Transport Delivery van <3.5t,1.94
1 陸運_運輸 貨車 3.5-7.5噸 EURO5/RER S 陆运_运输 货车3.5-7.5吨EURO5/ RER S Road_Transport lorry 3.5-7.5t EURO5/RER S 0.484
2 陸運_運輸 貨車 7.5-16噸 EURO5/RER S 陆运_运输 货车 7.5-16吨EURO5/ RER S Road_Transport lorry 7.5-16t EURO5/RER S 0.238
3 陸運_運輸 貨車 Delivery van <3.5t 陆运_运输 货车 Delivery van <3.5t Road_Transport Delivery van <3.5t 1.94

15
App_Data/Vehicle.csv Normal file
View File

@ -0,0 +1,15 @@
移動源汽油KgCO2e/L,移動源柴油KgCO2e/L
移动源汽油KgCO2e/L,移动源柴油KgCO2e/L
migration source gasoline KgCO2e / L,migration source diesel KgCO2e / L
台灣,大陸
台湾,大陆
Taiwan,China
2.358178,2.2774613,2.776512,2.69971044
2.358178,2.2774613,2.776512,2.69971044
2.358178,2.2774613,2.776512,2.69971044
2.361178,2.2774613,2.650251,2.69971044
2.361178,2.2774613,2.650251,2.69971044
2.361178,2.2774613,2.650251,2.69971044
3.1,2.756,3.45,2.703
3.1,2.756,3.45,2.703
3.1,2.756,3.45,2.703
1 移動源汽油KgCO2e/L,移動源柴油KgCO2e/L
2 移动源汽油KgCO2e/L,移动源柴油KgCO2e/L
3 migration source gasoline KgCO2e / L,migration source diesel KgCO2e / L
4 台灣,大陸
5 台湾,大陆
6 Taiwan,China
7 2.358178,2.2774613,2.776512,2.69971044
8 2.358178,2.2774613,2.776512,2.69971044
9 2.358178,2.2774613,2.776512,2.69971044
10 2.361178,2.2774613,2.650251,2.69971044
11 2.361178,2.2774613,2.650251,2.69971044
12 2.361178,2.2774613,2.650251,2.69971044
13 3.1,2.756,3.45,2.703
14 3.1,2.756,3.45,2.703
15 3.1,2.756,3.45,2.703

View File

@ -0,0 +1 @@


BIN
App_Data/Waste.csv Normal file

Binary file not shown.
1 垃圾_處置_惰性廢物_5%的水_惰性物質填埋/會堂S 垃圾_处置_惰性废物_5%的水_惰性物质填埋/会堂S Garbage_Disposal_inert waste_5% water_ to inert material landfill/CH S 0.007100808
2 垃圾_處置_城市固體廢棄物_22.9%的水_市政焚化/會堂S 垃圾_处置_城市固体废弃物_22.9%的水_市政焚化/会堂S Garbage_Disposal_ municipal solid waste_ 22.9% water_ to municipal incineration/CH S 0.50460689
3 廢高溫松香油_處置_混合溶劑_16.5%的水_危險廢物焚燒/會堂S 废高温松香油_处置_混合溶剂_16.5%的水_危险废物焚烧/会堂S Wastesolvents_Disposal_ solvents mixture_ 16.5% water_ to hazardous waste incineration/CH S 1.9834933
4 廢高溫松香油_特定工藝的負擔_危險廢物焚燒廠 /會堂S 废高温松香油_特定工艺的负担_危险废物焚烧厂/会堂S Wastesolvents_Process-specific burdens_ hazardous waste incineration plant/CH S 0.014905309
5 廢礦物油_處置_使用礦物油_10%的水_危險廢物焚燒/會堂S 废矿物油_处置_使用矿物油_10%的水_危险废物焚烧/会堂S Wasteoil_Disposal_ used mineral oil_ 10% water_ to hazardous waste incineration/CH S 2.8525048
6 其他_處置_包裝紙箱_19.6%的水_惰性物質填埋/會堂S 其他_处置_包装纸箱_19.6%的水_惰性物质填埋/会堂S Other_Disposal_ packaging cardboard_ 19.6% water_ to inert material landfill/CH S 0.007100808
7 其他_處置_油漆_0%的水_惰性物質填埋/會堂S 其他_处置_油漆_0%的水_惰性物质填埋/会堂S Other_Disposal_ paint_ 0% water_ to inert material landfill/CH S 0.007100808

4
App_Data/WasteWater.csv Normal file
View File

@ -0,0 +1,4 @@
廢水_Wastewater treatment COD,废水_Wastewater treatment COD,Waste water_Wastewater treatment COD,0.72
1 廢水_Wastewater treatment COD 废水_Wastewater treatment COD Waste water_Wastewater treatment COD 0.72

16
App_Data/Water.csv Normal file
View File

@ -0,0 +1,16 @@
Default
Default
Default
台灣,大陸
台湾,大陸
Taiwan,China
0.191,0.191
0.191,0.191
0.191,0.191
0.191,0.191
0.193,0.193
0.193,0.193
0.17,0.17
0.17,0.17
0.17,0.17
1 Default
2 Default
3 Default
4 台灣,大陸
5 台湾,大陸
6 Taiwan,China
7 0.191,0.191
8 0.191,0.191
9 0.191,0.191
10 0.191,0.191
11 0.193,0.193
12 0.193,0.193
13 0.17,0.17
14 0.17,0.17
15 0.17,0.17

BIN
App_Data/使用係數.xlsx Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

125
App_Start/BundleConfig.cs Normal file
View File

@ -0,0 +1,125 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Optimization;
using Weee.Extensions;
namespace Weee
{
public class BundleConfig
{
public static void RegisterBundles(BundleCollection bundles)
{
bundles.IgnoreList.Clear();
bundles.Add(new StyleBundle("~/bootstrap/css")
.Include("~/Content/bootstrap.css")
.Include("~/Content/kendo/2014.2.716/kendo.common-bootstrap.min.css")
.Include("~/Content/kendo/2014.2.716/kendo.bootstrap.min.css")
.Include("~/Content/bootstrap-theme.css"));
bundles.Add(new StyleBundle("~/admin/Content/css")
.Include("~/Areas/Admin/Content/css/adminarea.css"));
bundles.Add(new StyleBundle("~/account/css")
.Include("~/Browser_Local/css/Account/general.css"));
bundles.Add(new StyleBundle("~/certification/css")
.Include("~/Areas/Certification/Content/css/general.css"));
bundles.Add(new StyleBundle("~/module/scrollHash/css")
.Include("~/Browser_Local/css/Module/ScrollHash.css"));
bundles.Add(new StyleBundle("~/fancybox/css")
.Include("~/Content/fancybox/source/jquery.fancybox.css"));
bundles.Add(new StyleBundle("~/publicFiles/css")
.Include("~/Browser_Local/css/Home/public_files.css"));
bundles.Add(new StyleBundle("~/Browser_Local")
.Include("~/Browser_Local/css/html5-doctor-reset-stylesheet.css")
.Include("~/Browser_Local/css/table_view.css")
.Include("~/Browser_Local/css/simapro.css")
.Include("~/Browser_Local/css/datepicker.css")
.Include("~/Browser_Local/css/normal_table.css")
.Include("~/Browser_Local/css/popout.css")
.Include("~/Browser_Local/css/table_edit.css")
.Include("~/Browser_Local/css/quality.css")
.Include("~/Browser_Local/css/reply_mode.css")
.Include("~/Browser_Local/css/loading.css")
.Include("~/Browser_Local/css/validate.css")
.Include("~/Browser_Local/css/tooltip.css")
.Include("~/Browser_Local/css/image.css")
.Include("~/Browser_Local/css/input.css"));
bundles.Add(new ScriptBundle("~/admin/Scripts")
.Include("~/Scripts/jquery-{version}.js")
.Include("~/scripts/bootstrap.js")
.Include("~/Scripts/kendo/2014.2.716/jquery.min.js")
.Include("~/Scripts/kendo/2014.2.716/kendo.core.min.js")
.Include("~/Scripts/kendo/2014.2.716/kendo.data.min.js")
.Include("~/Scripts/kendo/2014.2.716/kendo.popup.min.js")
.Include("~/Scripts/kendo/2014.2.716/kendo.list.min.js")
.Include("~/Scripts/kendo/2014.2.716/kendo.multiselect.min.js"));
bundles.Add(new ScriptBundle("~/jQuery")
.Include("~/Scripts/jquery-1.10.2.min.js"));
bundles.Add(new ScriptBundle("~/bootstrap")
.Include("~/Scripts/bootstrap.min.js")
.Include("~/Scripts/bootstrap-datepicker.js"));
bundles.Add(new ScriptBundle("~/sticky")
.Include("~/Scripts/Sticky/jquery.sticky.js"));
bundles.Add(new ScriptBundle("~/multiLanguage/resource")
.Include("~/Scripts/Nls/en/app-resx.js")
.Include("~/Scripts/Nls/root/app-resx.js")
.Include("~/Scripts/Nls/zh/app-resx.js"));
bundles.Add(new ScriptBundle("~/parameterDatabase")
.Include("~/Browser_Local/js/ParameterDatabase/SwitchSimaproType.js"));
bundles.Add(new ScriptBundle("~/fancybox")
.Include("~/Content/fancybox/source/jquery.fancybox.pack.js"));
bundles.Add(new ScriptBundle("~/certification/lca/detail")
.Include("~/Areas/Certification/Content/js/detail.js"));
bundles.Add(new ScriptBundle("~/setCulture")
.Include("~/Browser_Local/js/Module/SetCulture.js"));
bundles.Add(new ScriptBundle("~/ReplyRequest")
.Include("~/Content/fancybox/source/jquery.fancybox.pack.js")
.Include("~/Browser_Local/js/Module/GetUrlParameters.js")
.Include("~/Browser_Local/js/LandingPage/ReplyRequest.js"));
bundles.Add(new ScriptBundle("~/papaParse")
.Include("~/Scripts/PapaParse-4.1.0/papaparse.min.js"));
bundles.Add(new ScriptBundle("~/linq")
.Include("~/Scripts/linq.min.js"));
bundles.Add(new ScriptBundle("~/moment")
.Include("~/Scripts/moment.min.js"));
bundles.Add(new ScriptBundle("~/survey")
.Include("~/Scripts/require.js")
.Include("~/Scripts/angular.min.js")
.Include("~/Scripts/angular-animate.min.js")
.Include("~/Scripts/angular-route.min.js")
.Include("~/Scripts/angular-resource.min.js")
.Include("~/Scripts/angular-cookies.min.js")
.Include("~/Scripts/angular-ui-notification.min.js")
.Include("~/Browser_Local/js/Basic.MultiLanguage.Config.js")
.Include("~/Browser_Local/js/Main.js")
.Include("~/Browser_Local/js/UploadFile.js")
.Include("~/Browser_Local/js/Services.js")
.Include("~/Browser_Local/js/ExportService.js")
.Include("~/Browser_Local/js/ImportService.js")
.Include("~/Browser_Local/js/Model.js").WithLastModifiedToken()
.Include("~/Browser_Local/js/BasicLogic.js")
.Include("~/Browser_Local/js/Resources.Config.js")
.Include("~/Browser_Local/js/View.Directive.js")
.Include("~/Browser_Local/js/Directive/*.js")
.Include("~/Browser_Local/js/datepicker.js")
.Include("~/Browser_Local/js/LCA/*.js").WithLastModifiedToken()
.Include("~/Browser_Local/js/LCA/DetailSurveyForm/*.js")
.Include("~/Browser_Local/js/LCA/DetailSurveyForm/RiskAssmt/*.js")
.Include("~/Browser_Local/js/MultiLanguageService.js")
.Include("~/Browser_Local/js/Services.js")
.Include("~/Browser_Local/js/CRUD.js")
.Include("~/Browser_Local/js/Product/*.js")
.Include("~/Browser_Local/js/Fab/*.js")
.Include("~/Browser_Local/js/Report/*.js")
.Include("~/Browser_Local/js/Management/*.js")
.Include("~/Browser_Local/js/Filter/*.js")
.Include("~/Browser_Local/js/detect-zoom.js")
.Include("~/Browser_Local/js/ListTable.Filter.js"));
bundles.Add(new ScriptBundle("~/chartjs")
.Include("~/Scripts/chart.min.js"));
}
}
}

View File

@ -0,0 +1,37 @@
using System;
using System.Web.Optimization;
using System.IO;
using System.Web.Hosting;
namespace Weee.Extensions
{
internal static class BundleExtensions
{
/// <summary>
/// Versioning for Bundles
/// Source: H-Dog's answer https://stackoverflow.com/questions/15005481/mvc4-stylebundle-can-you-add-a-cache-busting-query-string-in-debug-mode
/// </summary>
/// <param name="sb"></param>
/// <returns></returns>
public static Bundle WithLastModifiedToken(this Bundle sb)
{
sb.Transforms.Add(new LastModifiedBundleTransform());
return sb;
}
public class LastModifiedBundleTransform : IBundleTransform
{
public void Process(BundleContext context, BundleResponse response)
{
foreach (var file in response.Files)
{
// require some exception handle here to avoid illegal characters in the filename
if (!file.IncludedVirtualPath.Contains("?v=")) {
var lastWrite = File.GetLastWriteTime(HostingEnvironment.MapPath(file.IncludedVirtualPath)).Ticks.ToString();
file.IncludedVirtualPath = string.Concat(file.IncludedVirtualPath, "?v=", lastWrite);
}
}
}
}
}
}

93
App_Start/IoCConfig.cs Normal file
View File

@ -0,0 +1,93 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Http;
using System.Web.Mvc;
using Autofac;
using Autofac.Integration.Mvc;
using Autofac.Integration.WebApi;
using Microsoft.AspNet.Identity.EntityFramework;
using Microsoft.AspNet.Identity;
using Weee.DAL;
using Weee.Models;
using Weee.Service;
using Weee.Controllers;
using System.Reflection;
using Weee.Filter;
namespace Weee
{
public class IoCConfig
{
public static void RegisterDependencies()
{
var containerBuilder = new ContainerBuilder();
containerBuilder.RegisterControllers(typeof(MvcApplication).Assembly);
containerBuilder.RegisterApiControllers(typeof(MvcApplication).Assembly);
containerBuilder.RegisterModule(new AutofacWebTypesModule());
// to do registration module includes dependency injection bindings which is defined at the end of the post
containerBuilder.RegisterModule(new RegistrationModule());
containerBuilder.RegisterFilterProvider();
containerBuilder.RegisterWebApiFilterProvider(GlobalConfiguration.Configuration);
var container = containerBuilder.Build();
DependencyResolver.SetResolver(new AutofacDependencyResolver(container));
GlobalConfiguration.Configuration.DependencyResolver = new AutofacWebApiDependencyResolver(container);
// DependencyResolver.SetResolver(new AutofacWebApiDependencyResolver(container));
}
}
public class RegistrationModule : Autofac.Module
{
protected override void Load(ContainerBuilder builder)
{
//builder.RegisterType<UnitOfWork>()
// .As<IUnitOfWork>()
// .InstancePerLifetimeScope();
builder.RegisterType<WeeeDataContext>()
.AsSelf()
.InstancePerRequest();
builder.RegisterType<UserManager<User>>()
.AsSelf();
builder.Register(x => new UserStore<User>(x.Resolve<WeeeDataContext>()))
.As<IUserStore<User>>();
builder.Register(x => new UserStore<User>(x.Resolve<WeeeDataContext>()))
.AsSelf();
builder.RegisterType<MvcLogAttribute>().PropertiesAutowired();
builder.RegisterType<ApiLogAttribute>().PropertiesAutowired();
//builder.RegisterType<UserStore<User>>()
// .As<IUserStore<User>>();
//builder.RegisterType<WeeeDataService>()
// .AsSelf()
// .InstancePerRequest();
//builder.RegisterType<WeeeLCADataService>()
// .AsSelf()
// .InstancePerRequest();
//builder.RegisterType<WeeeMaterialDataService>()
// .AsSelf()
// .InstancePerRequest();
string @namespace = "Weee.Service";
var q = from t in Assembly.GetExecutingAssembly().GetTypes()
where t.IsClass && t.Namespace == @namespace
select t;
builder.RegisterTypes(q.ToArray())
.AsSelf()
.InstancePerRequest();
builder.RegisterType<Storage.AzureStorage>()
.SingleInstance();
builder.RegisterType<EmailService.Service>()
.SingleInstance();
//builder.RegisterType<WeeeDataContext>()
//.As<IWeeeDataContext>()
//.InstancePerRequest();
//builder.RegisterType<UserStore<User>>()
// .As<IUserStore<User>>();
}
}
}

26
App_Start/RouteConfig.cs Normal file
View File

@ -0,0 +1,26 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Web.Routing;
namespace Weee
{
public class RouteConfig
{
public static void RegisterRoutes(RouteCollection routes)
{
routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
routes.MapMvcAttributeRoutes();
routes.MapRoute(
name: "Default",
url: "{area}/{controller}/{action}/{id}",
namespaces: new string[] { "Weee.Controllers"},
defaults: new {area="", controller = "Home", action = "WeeeCarbonFootprint", id = UrlParameter.Optional }
);
}
}
}

38
App_Start/Startup.Auth.cs Normal file
View File

@ -0,0 +1,38 @@
using Microsoft.AspNet.Identity;
using Microsoft.Owin;
using Microsoft.Owin.Security.Cookies;
using Owin;
namespace Weee
{
public partial class Startup
{
// For more information on configuring authentication, please visit http://go.microsoft.com/fwlink/?LinkId=301864
public void ConfigureAuth(IAppBuilder app)
{
// Enable the application to use a cookie to store information for the signed in user
app.UseCookieAuthentication(new CookieAuthenticationOptions
{
AuthenticationType = DefaultAuthenticationTypes.ApplicationCookie,
LoginPath = new PathString("/Account/Login")
});
// Use a cookie to temporarily store information about a user logging in with a third party login provider
//app.UseExternalSignInCookie(DefaultAuthenticationTypes.ExternalCookie);
// Uncomment the following lines to enable logging in with third party login providers
//app.UseMicrosoftAccountAuthentication(
// clientId: "",
// clientSecret: "");
//app.UseTwitterAuthentication(
// consumerKey: "",
// consumerSecret: "");
//app.UseFacebookAuthentication(
// appId: "",
// appSecret: "");
//app.UseGoogleAuthentication();
}
}
}

22
App_Start/WebApiConfig.cs Normal file
View File

@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Http;
namespace Weee
{
public static class WebApiConfig
{
public static void Register(HttpConfiguration config)
{
config.MapHttpAttributeRoutes();
config.Routes.MapHttpRoute(
name: "DefaultApi",
routeTemplate: "api/{controller}/{action}/{id}",
defaults: new { id = RouteParameter.Optional }
);
}
}
}

View File

@ -0,0 +1,24 @@
using System.Web.Mvc;
namespace Weee.Areas.Certification
{
public class CertificationAreaRegistration : AreaRegistration
{
public override string AreaName
{
get
{
return "Certification";
}
}
public override void RegisterArea(AreaRegistrationContext context)
{
context.MapRoute(
"Certification_default",
"Certification/{controller}/{action}/{id}",
new {controller="home", action = "Index", id = UrlParameter.Optional }
);
}
}
}

View File

@ -0,0 +1,404 @@
/* reset bootstrap style */
.nav > li > a {
padding-top: 2px;
padding-bottom: 2px;
}
.panel-default > .panel-heading.docs-panel-heading {
background: #89c2d8;
border-color: #595858;
}
.table-bordered > tbody > tr > th {
border: 1px solid #474747;
}
.table-bordered > tbody > tr > td {
border: 1px solid #474747;
}
/* self define */
/*#docs-scroll-hash-nav {
width:160px;
}*/
.docs-body {
color: #000;
background-color: #f5f5f5;
/*padding-top: 90px;*/
font-family: "微軟正黑體";
}
.docs-header {
min-height: 24px;
background-image: none;
background-color: #fff;
box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.25);
}
.docs-footer {
width: 100%;
text-align: center;
display: block;
bottom: 0px;
background-color: #cfcfcf;
padding: 12px 0;
color: #595858;
font-size: 12px;
line-height: 18px;
position: fixed;
z-index: 99;
}
.docs-footer p {
margin: 0;
text-align: left;
}
.docs-table {
margin-top: 12px;
margin-bottom: 36px;
}
.docs-table th {
text-align: center;
color: #fff;
background-color: #A1A1A1;
font-weight: 100;
}
.docs-table tr:hover {
background-color: rgb(222, 222, 222);
}
.docs-table tr:first-child:hover {
background-color: rgb(201, 201, 201);
}
.docs-panel {
padding: 0 20px;
}
.docs-ul {
-webkit-padding-start: 0px;
background: inherit;
}
.docs-ul li {
margin: 5px 0px 5px 0px;
}
.docs-wrapper-inline {
display: inline-block;
}
.docs-back-to-top {
height: 26px;
width: 26px;
position: fixed;
bottom: 35px;
right: 5px;
background-color: white;
color: rgb(100, 100, 100);
border-radius: 5px;
padding: 3px 6px;
border: 1px solid rgb(201, 201, 201);
}
.docs-back-to-top:hover {
color: white;
background-color: rgb(35, 176, 99);
}
.docs-textarea-width-mx {
width: 100%;
height: 20%;
}
.docs-content-gap-sm {
margin-bottom: 24px;
}
.docs-content-gap-sm h1 {
margin-bottom: 48px;
}
.docs-p-md {
font-size: 16px;
}
/*.docs-logo {
height: 24px;
width: 24px;
}
.docs-logo img {
height: 100%;
width: 100%;
}*/
.survey_form_logo {
height: 60px;
float: left;
}
.survey_form_logo img {
width: 100%;
height: 100%;
}
.docs-lca-detail {
border-bottom: 1px solid #cdcdcd;
padding: 15px;
line-height: 30px;
margin-bottom: 30px;
}
.docs-btn-group {
margin-bottom: 30px;
}
.docs-inline {
display: inline;
}
.docs-btn-blue {
border-color: #595858;
color: #595858;
background-color: #89c2d8;
margin-right: 12px;
}
.docs-btn-blue:hover {
background-color: #77a7b9;
}
.docs-btn-default {
border-color: #595858;
color: #595858;
background-color: #cfcfcf;
margin-right: 12px;
}
.docs-input-default {
border-color: #595858;
}
.docs-btn-default:hover {
background-color: #c6c6c6;
}
.docs-validate-area {
display: block;
height: 16px;
color: red;
}
.panel-default.docs-panel-default {
border-color: #595858;
}
.docs-container {
max-width: 1440px;
min-width: 1440px;
padding: 0;
}
.docs-container .docs-footer-column {
display: inline-block;
margin: 0 10px;
}
.certification_table > tbody > tr > td, .certification_table > tbody > tr > th {
border: 1px solid rgb(201, 201, 201);
text-align: center;
}
/*.certification_table_header > th {
background: rgb(161, 161, 161);
color: white;
}*/
/*.nav-pills > li > a {
color: rgb(112, 112, 112);
border-radius: 0;
}
.nav-pills > li.active > a {
background: rgb(35, 176, 99);
}
.nav-pills > li.active > a:focus {
background: rgb(35, 176, 99);
}
.nav-pills > li.active > a:hover {
background: rgb(35, 176, 99);
}
.nav-pills > li > a:hover {
background: rgb(35, 176, 99);
color: white;
}*/
.header-button {
position: relative;
float: right;
margin-left: 12px;
padding: 1px 24px;
line-height: 24px;
font-size: 14px;
color: rgb(100, 100, 100);
border: 1px solid rgb(184, 184, 184);
background: white;
}
.header-button:hover {
background: rgb(35, 173, 99);
color: white;
cursor: pointer;
}
.side-bar {
background: #f5f5f5;
z-index: 77;
position: fixed;
/*top: 90px;*/
left: 0;
width: 195px;
}
.side-bar ul {
background: #f5f5f5;
}
.side-bar ul li {
background: #f5f5f5;
}
.panel {
border-radius: 0;
margin: 50px 0;
}
.panel-heading {
border-radius: 0;
}
.panel-default > .panel-heading.docs-panel-heading {
background: rgb(161, 161, 161);
color: white
}
/*#docs-scroll-hash-content {
position: relative;
left: 195px;
}*/
.side-bar-top-empty {
position: fixed;
top: 25px;
left: 0;
width: 195px;
height: 65px;
z-index: 99;
background: #f5f5f5;
}
.sheetheader {
display: inline-block;
margin-left: 15px;
white-space: nowrap;
}
.sheetheader-label {
display: inline-block;
vertical-align: top;
margin-left: 25px;
}
.sheetheader-text {
display: inline-block;
max-width: 200px;
overflow: hidden;
vertical-align: top;
text-overflow: ellipsis;
}
.home_user_login {
float: right;
color: #000;
text-decoration: none;
}
.home_culture_select {
float: right;
color: #000;
text-decoration: none;
}
.home_culture_select > ul {
list-style-type: none;
}
.culture_select_btn {
display: block;
float: right;
line-height: 32px;
margin-right: 15px;
cursor: pointer;
}
.dropdown-toggle {
color: #000;
margin-right: 10px;
}
.tab_header {
padding: 0 0 11px;
color: rgb(89, 89, 89);
font-weight: bold;
}
.tab-toggle {
margin-left: 20px;
margin-right: 20px;
}
.tab_content {
position: relative;
}
.tab {
position: relative;
top: 1px;
height: 28px;
font-size: 18px;
float: left;
margin-right: 4px;
color: rgb(128, 128, 128);
font-size: 1.2em;
}
.active .tab {
cursor: default;
border-bottom: 3px solid green;
color: #32353F;
}
.content_bg {
box-shadow: 0 0 1px 0 rgba(9, 30, 66, 0.31), 0 4px 8px -2px rgba(9, 30, 66, 0.25);
border: unset;
margin: 20px;
}
.org-split-left {
width: 17%;
display: block;
float: left;
}
.org-split-right {
width: 83%;
display: block;
float: right;
background-color: #fff;
}

View File

@ -0,0 +1,95 @@
(function ($) {
$(function () {
// start of fancybox
$('.iframe').fancybox({
maxWidth: 800,
maxHeight: 600,
minHeight: 400,
fitToView: false,
width: '70%',
height: '50%',
autoSize: false,
closeClick: false,
openEffect: 'none',
closeEffect: 'none',
beforeShow: function () {
$(".fancybox-skin").css("backgroundColor", "#fff");
}
});
$('#product-pictue').fancybox({
helpers: {
title: {
tyle: 'float'
}
}
});
// end of fancybox
// start of scroll spy animation
$('.scroller').click(function (event) {
var activeDestination = $(this).attr("href");
var scrollDistance = 0;
var activeLi = $('#docs-scroll-hash-nav').find('li.active a')[0];
var scrollTop = $($(activeLi).attr('href')).offset().top;
scrollDistance = Math.abs($(activeDestination).offset().top - 30 - scrollTop);
var scrollTime = 400 + scrollDistance / 2 >= 1000 ? 1000 : 400 + scrollDistance / 2;
$('html, body').animate({
scrollTop: $(activeDestination).offset().top - 30
}, scrollTime);
event.preventDefault();
});
// end of scroll spy animation
// start of sticky effect
var contentHeight = $($('#docs-scroll-hash-content')[0]).height();
$($('.side-bar')).height(contentHeight);
$($('.is-sticky')).height(contentHeight);
$($('#docs-scroll-hash-nav')).height(contentHeight);
// end of sticky effect
// start of confirm window
$('#confirm-button').click(function () {
if (confirm("你確定要確認該次盤查嗎?")) {
$('#lca-confirm').submit();
}
});
$('#reject-button').click(function () {
if (confirm("你確定要駁回該次盤查嗎?")) {
$('#lca-reject').submit();
}
});
$('#confirm-button2').click(function () {
if (confirm("你確定要確認該次盤查嗎?")) {
$('#lca-confirm2').submit();
}
});
$('#reject-button2').click(function () {
if (confirm("你確定要駁回該次盤查嗎?")) {
$('#lca-reject2').submit();
}
});
$('#refuse-button').click(function () {
if (confirm("你確定要拒絕查證該盤查案嗎?")) {
$('#lca-refuse').submit();
}
});
$('#refuse-button2').click(function () {
if (confirm("你確定要拒絕查證該盤查案嗎?")) {
$('#lca-refuse2').submit();
}
});
$('#ProductLca_ScheduledVerificationDate').change(function () {
$('#lca-ChangeScheduledVerificationDate').submit();
})
$('#ScheduledVerificationDate').change(function () {
$('#lca-ChangeScheduledVerificationDate').submit();
})
// end
$($('#empty')).height($(window).height() - $('table').last().height() - 160);
});
})($);

View File

@ -0,0 +1,85 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.EntityFramework;
using Weee.Models;
using Weee.Areas.Certification.Models;
using Weee.DAL;
using Resources;
namespace Weee.Areas.Certification.Controllers
{
public class AccountController : CertificationControllerBase
{
private readonly UserManager<User> userManager;
private readonly UserStore<User> userStore;
//private WeeeDataContext _db;
public AccountController(WeeeDataContext db)
:base(db)
{
userManager = DependencyResolver.Current.GetService<UserManager<User>>();
userStore = DependencyResolver.Current.GetService<UserStore<User>>();
//_db = new WeeeDataContext();
}
public ActionResult ChangePassword()
{
return View();
}
[HttpPost]
public ActionResult ChangePassword(ChangePassword changePassword)
{
if (ModelState.IsValid) {
var user = userManager.Find(User.Identity.GetUserName(), changePassword.OriginalPassword);
if (user == null) {
ViewBag.PasswordIsInvalid = Resource.InvalidPasswordMsg;
return View();
}
var hashed = userManager.PasswordHasher.HashPassword(changePassword.NewPassword);
userStore.SetPasswordHashAsync(user, hashed).Wait();
userStore.UpdateAsync(user).Wait();
return RedirectToAction("Index", "Home");
}
return View();
}
public ActionResult UpdateCompanyInfo()
{
var userId = User.Identity.GetUserId();
var user = db.Users.Where(x => x.Id == userId).First();
var company = user.Company;
return View(company);
}
[HttpPost]
public ActionResult UpdateCompanyInfo(CertificationCompany toBeSave)
{
var userId = User.Identity.GetUserId();
var user = db.Users.Where(x => x.Id == userId).First();
var company = user.Company;
if (ModelState.IsValid)
{
company.Name = toBeSave.Name;
company.EnglishName = toBeSave.EnglishName;
company.Address = toBeSave.Address;
company.VATNumber = toBeSave.VATNumber;
company.CEOName = toBeSave.CEOName;
company.IndustryDescription = toBeSave.IndustryDescription;
company.Description = toBeSave.Description;
db.SaveChanges();
}
return View(company);
}
}
}

View File

@ -0,0 +1,45 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.EntityFramework;
using Weee.Service;
using Resources.Helper;
using System.Threading;
using Weee.Controllers;
using Weee.DAL;
using CScommon;
namespace Weee.Areas.Certification.Controllers
{
[Authorize(Roles = ProgramConstants.certification)]
public class CertificationControllerBase : QcarbonControllerBase
{
public CertificationControllerBase(WeeeDataContext db) : base(db)
{
}
protected override IAsyncResult BeginExecuteCore(AsyncCallback callback, object state)
{
string cultureName = null;
// Attempt to read the culture cookie from Request
HttpCookie cultureCookie = Request.Cookies["_culture"];
if (cultureCookie != null)
cultureName = cultureCookie.Value;
else
cultureName = Request.UserLanguages != null && Request.UserLanguages.Length > 0 ? Request.UserLanguages[0] : null; // obtain it from HTTP header AcceptLanguages
// Validate culture name
cultureName = CultureHelper.GetImplementedCulture(cultureName); // This is safe
// Modify current thread's cultures
Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo(cultureName);
Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture;
return base.BeginExecuteCore(callback, state);
}
}
}

View File

@ -0,0 +1,57 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Microsoft.AspNet.Identity;
using Weee.Areas.Certification.ViewModels;
using Weee.Models;
using Weee.Models.Paramemter;
using Weee.Service;
using Resources;
using Weee.DAL;
namespace Weee.Areas.Certification.Controllers
{
public class CommentController : CertificationControllerBase
{
protected WeeeLCADataService lcaDataService;
protected WeeeCommentDataService commentDataService;
public CommentController(WeeeDataContext db
,WeeeLCADataService lcaDataService
, WeeeCommentDataService commentDataService)
:base(db)
{
this.lcaDataService = lcaDataService;
this.commentDataService = commentDataService;
}
protected override void Initialize(System.Web.Routing.RequestContext requestContext)
{
base.Initialize(requestContext);
this.lcaDataService.Initialize(User.Identity.GetUserId());
this.commentDataService.Initialize(User.Identity.GetUserId());
}
public ActionResult Index(int lcaId, string category)
{
var commentViewModel = new CommentViewModel();
var lca = lcaDataService.GetLCA(lcaId);
commentViewModel.History = lca.Comments.Where(x => x.Category == category && x.IsHistory).ToList();
commentViewModel.CurrentComment = lca.Comments.Where(x => x.Category == category && !x.IsHistory).SingleOrDefault();
if (commentViewModel.CurrentComment == null) commentViewModel.CurrentComment = new Comment() { LCAID = lca.ID, Category = category };
ViewBag.Message = TempData["Message"];
commentViewModel.LcaStatus = lca.Status;
return View(commentViewModel);
}
[HttpPost]
public ActionResult Save(CommentViewModel ToBeSave)
{
this.commentDataService.SaveComment(ToBeSave.CurrentComment);
TempData["Message"] = Resource.CommentSaved;
return RedirectToAction("Index", new { lcaId = ToBeSave.CurrentComment.LCAID, category = ToBeSave.CurrentComment.Category });
}
}
}

View File

@ -0,0 +1,230 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Data.Entity;
using Weee.Models;
using Microsoft.AspNet.Identity.EntityFramework;
using Microsoft.AspNet.Identity;
using Weee.DAL;
using PagedList;
using Weee.ViewModels;
using Resources;
using CScommon;
using System.Net;
namespace Weee.Areas.Certification.Controllers
{
[Authorize(Roles = ProgramConstants.certification)]
public class HomeController : CertificationControllerBase
{
//private WeeeDataContext _db;
private int? currentcompanyid;
public HomeController(WeeeDataContext db)
: base(db)
{
//this._db = db;
}
// GET: /Consultant/Home/
public ActionResult Index()
{
//Start CFT-30
//var verifyLCAs = _db.LCAs
// .Where(x => x.Status == LCAStatus.Waiting
// && x.VerifierCompanyID == currentcompanyid)
// .OrderByDescending(x => x.ID)
// .ToList();
var verifyLCAs = GetVerifyLCADataList((int)currentcompanyid, LCAStatus.Waiting);
//End CFT-30
//var verifyLCAs = (from a in _db.LCAs
// join b in _db.ProductLCAs on a.ID equals b.ID into ab
// from c in ab.DefaultIfEmpty()
// join d in _db.Products on c.ProductID equals d.ID into cd
// from e in cd.DefaultIfEmpty()
// where a.Status == LCAStatus.Waiting
// && a.VerifierCompanyID == currentcompanyid
// select new CertificationViewModel
// {
// ID = a.ID,
// LCAname = a.LCAname,
// StartDate = a.StartDate,
// EndDate = a.EndDate,
// LCATypeName = (c == null) ? Resource.StaticLabelOrganizationLCA
// : Resource.StaticLabelProductLCA,
// Description = a.Description,
// CreatedDate = a.CreatedDate,
// LCAitemName = e.Name
// })
// .OrderByDescending(x => x.ID)
// .ToList();
return View(verifyLCAs);
}
public ActionResult All(int page = 1, string searchString = "")
{
var query = db.LCAs
.Where(x => x.VerifierCompanyID == currentcompanyid)
//.Where(x => x.Status != LCAStatus.Waiting || x.Status != LCAStatus.New);
;
if (searchString != "")
query = query.Where(x => x.Description.Contains(searchString));
var LCAs = query.OrderByDescending(x => x.ID).ToPagedList(page, 20);
var onePage = LCAs;
ViewBag.SearchString = searchString;
return View(LCAs);
}
public ActionResult LCAStatusNew()
{
//Start CFT-30
//var verifyLCAs = _db.LCAs
// .Where(x => x.Status == LCAStatus.New
// && x.VerifierCompanyID == currentcompanyid)
// .OrderByDescending(x => x.ID)
// .ToList();
var verifyLCAs = GetVerifyLCADataList((int)currentcompanyid, LCAStatus.New);
//End CFT-30
return View(verifyLCAs);
}
public ActionResult LCAStatusProcessing()
{
//Start CFT-30
//var verifyLCAs = _db.LCAs
// .Where(x => x.Status == LCAStatus.Processing
// && x.VerifierCompanyID == currentcompanyid)
// .OrderByDescending(x => x.ID)
// .ToList();
var verifyLCAs = GetVerifyLCADataList((int)currentcompanyid, LCAStatus.Processing);
//End CFT-30
return View(verifyLCAs);
}
public ActionResult LCAStatusRejected()
{
//Start CFT-30
//var verifyLCAs = _db.LCAs
// .Where(x => x.Status == LCAStatus.Rejected
// && x.VerifierCompanyID == currentcompanyid)
// .OrderByDescending(x => x.ID)
// .ToList();
var verifyLCAs = GetVerifyLCADataList((int)currentcompanyid, LCAStatus.Rejected);
//End CFT-30
return View(verifyLCAs);
}
public ActionResult LCAStatusConfirmed()
{
//Start CFT-30
//var verifyLCAs = _db.LCAs
// .Where(x => x.Status == LCAStatus.Confirmed
// && x.VerifierCompanyID == currentcompanyid)
// .OrderByDescending(x => x.ID)
// .ToList();
var verifyLCAs = GetVerifyLCADataList((int)currentcompanyid, LCAStatus.Confirmed);
//End CFT-30
return View(verifyLCAs);
}
public ActionResult LCAStatusCompleted()
{
//Start CFT-30
//var verifyLCAs = _db.LCAs
// .Where(x => x.Status == LCAStatus.Completed
// && x.VerifierCompanyID == currentcompanyid)
// .OrderByDescending(x => x.ID)
// .ToList();
var verifyLCAs = GetVerifyLCADataList((int)currentcompanyid, LCAStatus.Completed);
//End CFT-30
return View(verifyLCAs);
}
protected override void OnActionExecuting(ActionExecutingContext filterContext)
{
var loggedInUserId = User.Identity.GetUserId();
currentcompanyid = db.Users.AsNoTracking().First(x => x.Id == loggedInUserId).CompanyID;
base.OnActionExecuting(filterContext);
}
//CFT-30
public List<CertificationViewModel> GetVerifyLCADataList( int companyID, LCAStatus status)
{
var verifyLCAs = (from a in db.LCAs
join b in db.ProductLCAs on a.ID equals b.ID into ab
from c in ab.DefaultIfEmpty()
join d in db.Products on c.ProductID equals d.ID into cd
from e in cd.DefaultIfEmpty()
where a.Status == status
&& a.VerifierCompanyID == companyID
select new CertificationViewModel
{
ID = a.ID,
LCAname = a.LCAname,
StartDate = a.StartDate,
EndDate = a.EndDate,
LCATypeName = (c == null) ? Resource.StaticLabelOrganizationLCA
: Resource.StaticLabelProductLCA,
Description = a.Description,
CreatedDate = a.CreatedDate,
LCAitemName = e.Name
})
.OrderByDescending(x => x.ID)
.ToList();
return verifyLCAs;
}
public ActionResult UploadFileFA(int updType)
{
if (Request == null)
return new HttpStatusCodeResult(HttpStatusCode.BadRequest);
HttpPostedFileBase file = Request.Files["UploadedFile"];
try
{
if (file.ContentLength == 0)
{
TempData["ErrMsg"] = "未選擇檔案";
return RedirectToAction("Index");
}
if (file != null)
{
var userNm = User.Identity.GetUserName();
string newFileName = "";
if (updType == 1) newFileName = ProgramConstants.OrganizationLCAApplicationFile;
else if (updType == 2) newFileName = ProgramConstants.ProductLCAApplicationFile;
string extesion = file.FileName.Substring(file.FileName.LastIndexOf(".") + 1);
if (extesion.ToLower() != "zip")
{
TempData["ErrMsg"] = "僅支持zip類型";
return RedirectToAction("Index");
}
var storage = System.Web.Http.GlobalConfiguration.Configuration.DependencyResolver.GetService(typeof(Storage.AzureStorage)) as Storage.AzureStorage;
var uri = storage.SaveToAzure(file.InputStream, file.FileName, baseUrl, userNm, false
, newFileName);
TempData["SuccessMsg"] = "[" + newFileName + "]上傳成功";
return RedirectToAction("Index");
}
else
{
TempData["ErrMsg"] = "上傳失敗";
return RedirectToAction("Index");
}
}
catch (Exception ex)
{
TempData["ErrMsg"] = ex.Message;
return RedirectToAction("Index");
}
}
}
}

View File

@ -0,0 +1,341 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Weee.Areas.Certification.ViewModels;
using Weee.DAL;
using Weee.Models;
using Weee.Service;
using Weee.Areas.Certification.Models;
using Weee.Models.ExtensionMethods;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.EntityFramework;
using Weee.Models.Paramemter;
using Weee.DataTransferObject;
using System.IO;
using EmailService.others;
using System.Net;
using System.Web.Configuration;
using System.Web.Http;
using Weee.Controllers;
namespace Weee.Areas.Certification.Controllers
{
// to do: Add parameter id in workhour, power usage, water usage
public class LCAController : CertificationControllerBase
{
protected WeeeDataContext _db;
protected WeeeLCADataService lcaDataService;
protected WeeeSheetDataService sheetDataService;
private readonly WeeeParameterDataService parameterservice;
private readonly SignificanceAssmtDataService significanceAssmtservice;
private readonly LifecycleAssmtDataService lifecycleservice;
private readonly EmailService.Service service = DependencyResolver.Current.GetService<EmailService.Service>();//CFT-89
private string fileSavedPath = WebConfigurationManager.AppSettings["UploadPath"];//CFT-89
protected override void Initialize(System.Web.Routing.RequestContext requestContext)
{
base.Initialize(requestContext);
this.lcaDataService.Initialize(User.Identity.GetUserId());
this.sheetDataService.Initialize(User.Identity.GetUserId());
this.significanceAssmtservice.Initialize(User.Identity.GetUserId());
this.lifecycleservice.Initialize(User.Identity.GetUserId());
}
public LCAController(WeeeDataContext db, WeeeLCADataService lcaDataService
, WeeeSheetDataService sheetDataService
, WeeeCompanyDataService companyDataService
, WeeeParameterDataService parameterservice
, SignificanceAssmtDataService significanceAssmtservice
, LifecycleAssmtDataService lifecycleservice)
: base(db)
{
this.lcaDataService = lcaDataService;
this.sheetDataService = sheetDataService;
this.parameterservice = parameterservice;
this.significanceAssmtservice = significanceAssmtservice;
this.lifecycleservice = lifecycleservice;
this._db = new WeeeDataContext();
}
public ActionResult ProductLcaDetail(int id)
{
//var qry = (from a in uow.productRepository.Get()
// select a).AsQueryable();
var viewModel = new ProductLcaViewModel();
var productLca = lcaDataService.GetProductLCA(id);
viewModel.ProductLca = productLca;
var inventoryStage = productLca.TargetInventoryStageData;
var usageStage = new ProductUsageStageDTO();
if (inventoryStage != null)
{
usageStage.WattInOperation = inventoryStage.WattInOperation;
usageStage.WattInLowOperation = inventoryStage.WattInLowOperation;
usageStage.TurnOnHourPerDayInWorkDay = inventoryStage.TurnOnHourPerDayInWorkDay;
usageStage.TurnOnHourPerDayInOffDay = inventoryStage.TurnOnHourPerDayInOffDay;
usageStage.WorkDayPerYear = inventoryStage.WorkDayPerYear;
usageStage.PowerFactor = inventoryStage.ProductUsageStagePowerFactor;
usageStage.Description = inventoryStage.ProductUsageStageDescription;
usageStage.CalculateResult = inventoryStage.GetUsageStageCarbonFootprint();
}
viewModel.UsageStage = usageStage;
var abandonedStage = _db.ProductLCAAbandonedStages.Where(x => x.OwnerLCA.ID == id).Count() > 0 ? _db.ProductLCAAbandonedStages.Where(x => x.OwnerLCA.ID == id).First() : null;
var abandonedStageDTO = new AbandonedStageDTO();
if (inventoryStage != null && abandonedStage != null)
{
//abandonedStageDTO.WasteWeight = abandonedStage.WasteWeight;
//abandonedStageDTO.RecyclePercentage = abandonedStage.RecyclePercentage;
//abandonedStageDTO.ReusePercentage = abandonedStage.ReusePercentage;
//abandonedStageDTO.RecoverPercentage = abandonedStage.RecoverPercentage;
//abandonedStageDTO.IncinerationParameter = abandonedStage.IncinerationParameter;
//abandonedStageDTO.AbandonedParameter = abandonedStage.AbandonedParameter;
//abandonedStageDTO.Description = abandonedStage.Description;
//abandonedStageDTO.CalculateResult = inventoryStage.ProductAbandonedStageCarbonFootprint;
}
viewModel.AbandonedStage = abandonedStageDTO;
/*
if (productLca.PCRID == null)
{
viewModel.DirectMaterial = this.sheetDataService.GetSheetHeader(id, Categories.BOM);
}
else
{
viewModel.DirectMaterial = this.sheetDataService.GetSheetHeader(id, Categories.DirectMaterial);
}
*/
viewModel.DirectMaterial = this.sheetDataService.GetSheetHeader(id, Categories.DirectMaterial);
viewModel.IndirectMaterial = this.sheetDataService.GetSheetHeader(id, Categories.IndirectMaterial);
viewModel.WrapMaterial = this.sheetDataService.GetSheetHeader(id, Categories.WrapMaterial);
viewModel.WorkHourHeader = this.sheetDataService.GetSheetHeader(id, Categories.Septic);
viewModel.PowerHeader = this.sheetDataService.GetSheetHeader(id, Categories.Electric);
viewModel.WaterHeader = this.sheetDataService.GetSheetHeader(id, Categories.Water);
viewModel.WasteWaterHeader = this.sheetDataService.GetSheetHeader(id, Categories.WasteWater);
viewModel.TransportHeader = this.sheetDataService.GetSheetHeader(id, Categories.Transport);
viewModel.WasteTransportHeader = this.sheetDataService.GetSheetHeader(id, Categories.SheetHeaderWasteTransport);
viewModel.VehicleHeader = this.sheetDataService.GetSheetHeader(id, Categories.Vehicle);
viewModel.GasolineHeader = this.sheetDataService.GetSheetHeader(id, Categories.GasolineEquipment);
viewModel.KitchenHeader = this.sheetDataService.GetSheetHeader(id, Categories.Kitchen);
viewModel.RefrigerantHeader = this.sheetDataService.GetSheetHeader(id, Categories.Refrigerant);
viewModel.FireEquipmentHeader = this.sheetDataService.GetSheetHeader(id, Categories.FireEquipment);
viewModel.SteamHeader = this.sheetDataService.GetSheetHeader(id, Categories.Steam);
viewModel.OtherHeader = this.sheetDataService.GetSheetHeader(id, Categories.OtherCompound);
ViewData["DownloadZipReport"] =baseUrl+ viewModel.ProductLca.UploadZipReportUrl;
return View(viewModel);
}
public ActionResult OrganizationLcaDetail(int id)
{
var organizationLca = lcaDataService.GetOrganizationLCA(id);
//return View(organizationLca);
//根據LCAID新加folder
// Thomas Mao 3/21 found error, the uploaded part use Lca folder but template folder
//used here, can never work at all
ViewData["DownloadZipReport"] =baseUrl+ organizationLca.UploadZipReportUrl;
ViewData["sources"] = parameterservice.GetNonYearlyParameterOptions(Categories.OtherCompound);
return View(organizationLca);
}
public ActionResult OrganizationLcaDetailLifecycleAssmt(int id)
{
var organizationLca = lcaDataService.GetOrganizationLCA(id);
//return View(organizationLca);
//根據LCAID新加folder
// Thomas Mao 3/21 found error, the uploaded part use Lca folder but template folder
//used here, can never work at all
ViewData["StageOptions"] = CScommon.ProgramConstants.lifeCycleStages;
ViewData["DownloadZipReport"] =baseUrl+ organizationLca.UploadZipReportUrl;
ViewData["sources"] = parameterservice.GetNonYearlyParameterOptions(Categories.OtherCompound);
return View(organizationLca);
}
public ActionResult OrganizationLcaDetailSignificance(int id)
{
var organizationLca = lcaDataService.GetOrganizationLCA(id);
var query = significanceAssmtservice.GetList(id);
query = query.OrderBy(x => x.LifeCycleStage).ThenBy(x => x.ID);
var assmtFactors = significanceAssmtservice.GetAssmtFactors(id).ToList().Select(x =>
new { x.ID, x.FactorName, FactorScores = x.FactorScores.Select(s => new { s.OptionScore, OptionDescription = $"{s.OptionScore}{s.OptionDescription}" }) });
var lca = significanceAssmtservice.GetLCA(id);
ViewData["StageOptions"] = CScommon.ProgramConstants.lifeCycleStages;
ViewData["significanceAssmt"] = query.ToList();
ViewData["AssmtFactors"] = assmtFactors;
ViewData["GradingScore"] = lca.GradingScore;
return View(organizationLca);
}
public ActionResult SupplierLcaDetail(int supplierLcaId, int productLcaId)
{
ProductLCA supplierLca = lcaDataService.GetProductLCA(supplierLcaId);
var viewModel = new ProductLcaViewModel();
viewModel.ProductLca = supplierLca;
/*
if (supplierLca.PCRID == null)
{
viewModel.DirectMaterial = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.BOM);
}
else
{
viewModel.DirectMaterial = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.DirectMaterial);
}
*/
viewModel.DirectMaterial = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.DirectMaterial);
viewModel.IndirectMaterial = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.IndirectMaterial);
viewModel.WrapMaterial = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.WrapMaterial);
viewModel.WorkHourHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Septic);
viewModel.PowerHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Electric);
viewModel.WaterHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Water);
viewModel.WasteWaterHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.WasteWater);
viewModel.TransportHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Transport);
viewModel.WasteTransportHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.SheetHeaderWasteTransport);
viewModel.VehicleHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Vehicle);
viewModel.GasolineHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.GasolineEquipment);
viewModel.KitchenHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Kitchen);
viewModel.RefrigerantHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Refrigerant);
viewModel.FireEquipmentHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.FireEquipment);
viewModel.SteamHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.Steam);
viewModel.OtherHeader = this.sheetDataService.GetSheetHeader(supplierLcaId, Categories.OtherCompound);
ViewBag.ProductLcaId = productLcaId;
return View("ProductLcaDetail" ,viewModel);
}
[System.Web.Mvc.HttpPost]
public ActionResult ProductLcaConfirm(int lcaId)
{
lcaDataService.ProductLCAWaitToConfirmed(lcaId);
return RedirectToAction("index", "Home");
}
[System.Web.Mvc.HttpPost]
public ActionResult ProductLcaReject(int lcaId)
{
lcaDataService.ProductLCAWaitToRejected(lcaId);
return RedirectToAction("index", "Home");
}
[System.Web.Mvc.HttpPost]
public ActionResult ProductLcaRefuse(int lcaId)
{
lcaDataService.LCARefuse(lcaId);
return RedirectToAction("index", "Home");
}
[System.Web.Mvc.HttpPost]
public ActionResult OrganizationLcaConfirm(int lcaId)
{
lcaDataService.OrganizationLCAWaitToConfirmed(lcaId);
return RedirectToAction("index", "Home");
}
[System.Web.Mvc.HttpPost]
public ActionResult OrganizationLcaReject(int lcaId)
{
lcaDataService.OrganizationLCAWaitToRejected(lcaId);
return RedirectToAction("index", "Home");
}
[System.Web.Mvc.HttpPost]
public ActionResult OrganizationLcaRefuse(int lcaId)
{
lcaDataService.LCARefuse(lcaId);
return RedirectToAction("index", "Home");
}
[System.Web.Mvc.HttpPost]
public ActionResult ProductLcaChangeScheduledVerificationDate(int lcaId, ProductLcaViewModel model)
{
lcaDataService.LcaChangeScheduledVerificationDate(lcaId, model.ProductLca.ScheduledVerificationDate);
return RedirectToAction("ProductLcaDetail", "LCA", new { id = lcaId });
}
[System.Web.Mvc.HttpPost]
public ActionResult OrganizationLcaChangeScheduledVerificationDate(int lcaId, OrganizationLCA model)
{
lcaDataService.LcaChangeScheduledVerificationDate(lcaId, model.ScheduledVerificationDate);
return RedirectToAction("OrganizationLcaDetail", "LCA", new { id = lcaId });
}
[System.Web.Mvc.HttpPost]
public ActionResult OrganizationLcaUploadFile(int lcaId)
{
if (Request == null)
return new HttpStatusCodeResult(HttpStatusCode.BadRequest);
HttpPostedFileBase file = Request.Files["UploadedFile"];
try
{
if(file != null)
{
//string fileName = file.FileName.ToString();
string fileName = "";
string extesion = file.FileName.Substring(file.FileName.LastIndexOf(".") + 1);
var storage = GlobalConfiguration.Configuration.DependencyResolver.GetService(typeof(Storage.AzureStorage)) as Storage.AzureStorage;
var uri = storage.SaveToAzure(file.InputStream, file.FileName, baseUrl, "lca" + lcaId, false
, $"{CScommon.ProgramConstants.OrganizationDownloadReply}.zip");
if (uri.ToString().Contains("Browser_Local"))
{
fileName = uri.ToString().Substring(uri.ToString().IndexOf("Browser_Local") - 1);
}
//var fullFilePath = this.FileUploadHandler(file);
lcaDataService.SaveCertificationZipFile(lcaId, fileName);
TempData["successMsg"] = "File Import Success!";
}
}
catch (Exception exception)
{
TempData["errorMsg"] = exception.Message;
return RedirectToAction("OrganizationLcaDetail","LCA", new { id = lcaId });
}
return RedirectToAction("OrganizationLcaDetail", "LCA", new { id = lcaId });
}
[System.Web.Mvc.HttpPost]
public ActionResult ProductLcaUploadFile(int lcaId)
{
if (Request == null)
return new HttpStatusCodeResult(HttpStatusCode.BadRequest);
HttpPostedFileBase file = Request.Files["UploadedFile"];
try
{
if (file != null)
{
//string fileName = file.FileName.ToString();
string fileName = "";
string extesion = file.FileName.Substring(file.FileName.LastIndexOf(".") + 1);
var storage = GlobalConfiguration.Configuration.DependencyResolver.GetService(typeof(Storage.AzureStorage)) as Storage.AzureStorage;
var uri = storage.SaveToAzure(file.InputStream, file.FileName, baseUrl, "lca" + lcaId, false
, $"{CScommon.ProgramConstants.ProductDownloadReply}.zip");
if (uri.ToString().Contains("Browser_Local"))
{
fileName = uri.ToString().Substring(uri.ToString().IndexOf("Browser_Local") - 1);
}
//var fullFilePath = this.FileUploadHandler(file);
lcaDataService.SaveCertificationZipFile(lcaId, fileName);
TempData["successMsg"] = "File Import Success!";
}
}
catch (Exception exception)
{
TempData["errorMsg"] = exception.Message;
return RedirectToAction("ProductLcaDetail", "LCA", new { id = lcaId });
}
return RedirectToAction("ProductLcaDetail", "LCA", new { id = lcaId });
}
}
}

View File

@ -0,0 +1,47 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Weee.DAL;
using Weee.Service;
namespace Weee.Areas.Certification.Controllers
{
public class ParameterController : CertificationControllerBase
{
protected WeeeParameterDataService parameterDataService;
public ParameterController(WeeeDataContext db
,WeeeParameterDataService parameterDataService)
:base(db)
{
this.parameterDataService = parameterDataService;
}
public ActionResult Remark(int id = 0)
{
if (id == 0) return HttpNotFound();
var simaproParameter = parameterDataService.GetSimaproParameter(id);
ViewBag.Remark = simaproParameter.Remark;
return View();
}
public ActionResult NonYearly(int id = 0)
{
if (id == 0) return HttpNotFound();
var nonYearlyParameter = parameterDataService.GetNonYearlyParameter(id);
return View(nonYearlyParameter);
}
public ActionResult Yearly(int id = 0)
{
if (id == 0) return HttpNotFound();
var yearlyParameter = parameterDataService.GetYearlyParameter(id);
return View(yearlyParameter);
}
}
}

View File

@ -0,0 +1,25 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
using Resources;
namespace Weee.Areas.Certification.Models
{
public class ChangePassword
{
[Required(ErrorMessageResourceName = "RequiredMessage", ErrorMessageResourceType = typeof(Resource))]
[Display(Name = "OriginalPassword", ResourceType = typeof(Resource))]
public string OriginalPassword { get; set; }
[Required(ErrorMessageResourceName = "RequiredMessage", ErrorMessageResourceType = typeof(Resource))]
[Display(Name = "NewPassword", ResourceType = typeof(Resource))]
[Compare("ConfirmPassword", ErrorMessageResourceName = "PwValidationConfirmationMsg", ErrorMessageResourceType = typeof(Resource))]
public string NewPassword { get; set; }
[Required(ErrorMessageResourceName = "RequiredMessage", ErrorMessageResourceType = typeof(Resource))]
[Display(Name = "ConfirmPassword", ResourceType = typeof(Resource))]
public string ConfirmPassword { get; set; }
}
}

View File

@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace Weee.Areas.Certification.Supports
{
public static class ViewHelper
{
public static string GetEntityCategory(string toBeAnalysis)
{
return toBeAnalysis.Split(',').First();
}
public static string GetProcessOrType(string toBeAnalysis)
{
var strings = toBeAnalysis.Split(',');
if (strings.Length > 1) return strings[1];
return strings[0];
}
}
}

View File

@ -0,0 +1,15 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Weee.Models;
namespace Weee.Areas.Certification.ViewModels
{
public class CommentViewModel
{
public Comment CurrentComment { get; set; }
public List<Comment> History { get; set; }
public LCAStatus LcaStatus { get; set; }
}
}

View File

@ -0,0 +1,32 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Weee.DataTransferObject;
using Weee.Models;
namespace Weee.Areas.Certification.ViewModels
{
public class ProductLcaViewModel
{
public ProductLCA ProductLca { get; set; }
public AbandonedStageDTO AbandonedStage { get; set; }
public ProductUsageStageDTO UsageStage { get; set; }
public SheetHeader DirectMaterial { get; set; }
public SheetHeader IndirectMaterial { get; set; }
public SheetHeader WrapMaterial { get; set; }
public SheetHeader WorkHourHeader { get; set; }
public SheetHeader PowerHeader { get; set; }
public SheetHeader WaterHeader { get; set; }
public SheetHeader WasteWaterHeader { get; set; }
public SheetHeader TransportHeader { get; set; }
public SheetHeader WasteTransportHeader { get; set; }
public SheetHeader VehicleHeader { get; set; }
public SheetHeader GasolineHeader { get; set; }
public SheetHeader KitchenHeader { get; set; }
public SheetHeader RefrigerantHeader { get; set; }
public SheetHeader FireEquipmentHeader { get; set; }
public SheetHeader SteamHeader { get; set; }
public SheetHeader OtherHeader { get; set; }
}
}

View File

@ -0,0 +1,62 @@
@using Resources
@model Weee.Areas.Certification.Models.ChangePassword
@{
ViewBag.Title = "Change Password";
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
@using (Html.BeginForm("ChangePassword", "Account", FormMethod.Post, new { @class = "form-horizontal" }))
{
@Html.AntiForgeryToken()
<div class="row panel panel-default">
<div class="col-xs-12">
<h2>@Resource.StaticLabelChangePassword</h2>
<hr />
</div>
<div class="col-xs-12">
<div class="col-xs-11">
<div class="form-group">
@Html.LabelFor(m => m.OriginalPassword, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.PasswordFor(m => m.OriginalPassword, new { @class = "form-control" })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.OriginalPassword, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.NewPassword, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.PasswordFor(m => m.NewPassword, new { @class = "form-control" })
<span class="docs-validate-area">
@Html.ValidationMessageFor(m => m.NewPassword, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.ConfirmPassword, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.PasswordFor(m => m.ConfirmPassword, new { @class = "form-control" })
<span class="docs-validate-area">
@Html.ValidationMessageFor(m => m.ConfirmPassword, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-4 col-sm-8">
<button type="submit" class="btn docs-btn-blue">@Resource.StaticLabelGlobal_Save</button>
<a href="~/Certification" class="btn docs-btn-default">@Resource.StaticLabelGlobal_Cancel</a>
</div>
</div>
</div>
</div>
</div>
}

View File

@ -0,0 +1,112 @@
@using Resources
@model Weee.Models.CertificationCompany
@{
ViewBag.Title = "Update Company Info";
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
@using (Html.BeginForm("UpdateCompanyInfo", "Account", FormMethod.Post, new { @class = "form-horizontal" }))
{
@Html.AntiForgeryToken()
<div class="row panel panel-default">
<div class="col-xs-12">
<h2>@Resource.EditCompanyInfo</h2>
<hr />
</div>
<div class="col-xs-12">
<div class="col-xs-11">
<div class="form-group">
@Html.LabelFor(m => m.Name, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.Name, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.Name, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.EnglishName, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.EnglishName, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.EnglishName, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.Address, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.Address, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.Address, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.VATNumber, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.VATNumber, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.VATNumber, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.CEOName, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.CEOName, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.CEOName, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.IndustryDescription, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.IndustryDescription, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.IndustryDescription, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
@Html.LabelFor(m => m.Description, new { @class = "col-sm-4 control-label" })
<div class="col-sm-8">
@Html.EditorFor(m => m.Description, new { htmlAttributes = new { @class = "form-control" } })
<span class="docs-validate-area">
@ViewBag.PasswordIsInvalid
@Html.ValidationMessageFor(m => m.Description, "", new { @class = "text-danger" })
</span>
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-4 col-sm-8">
<button type="submit" class="btn docs-btn-blue">@Resource.StaticLabelGlobal_Save</button>
<a href="~/Certification" class="btn docs-btn-default">@Resource.StaticLabelGlobal_Cancel</a>
</div>
</div>
</div>
</div>
</div>
}

View File

@ -0,0 +1,64 @@
@using Weee.Models.Paramemter
@using Resources
@model Weee.Areas.Certification.ViewModels.CommentViewModel
@{
Layout = null;
}
@Styles.Render("~/bootstrap/css")
@Styles.Render("~/certification/css")
<style>
textarea {
resize: none;
}
</style>
<div class="docs-panel">
@using (Html.BeginForm("Save",
"Comment",
new { },
FormMethod.Post))
{
<div class="docs-content-gap-sm">
@Html.HiddenFor(model => model.CurrentComment.ID)
@Html.HiddenFor(model => model.CurrentComment.LCAID)
@Html.HiddenFor(model => model.CurrentComment.Category)
<h1 class="text-center">@Resource.Category</h1>
<div class="panel panel-default docs-panel-default">
<div class="panel-heading docs-panel-heading">
<div class="row">
<div class="col-xs-9">@Resource.Comment</div>
<div class="col-xs-3">@Resource.UpdateTime</div>
</div>
</div>
<div class="panel-body">
@foreach (var comment in Model.History)
{
<div class="row">
<div class="col-xs-9"><textarea class="docs-textarea-width-mx form-control" readonly="readonly" rows="5">@comment.CommentText</textarea></div>
<div class="col-xs-3">@comment.UpdateTime</div>
</div>
}
<div class="row">
<div class="col-xs-9">
@Html.TextAreaFor(model => model.CurrentComment.CommentText, new { @class = "docs-textarea-width-mx form-control docs-input-default", rows = "5", placeholder = Resource.EnterComment})
</div>
<div class="col-xs-3">@Model.CurrentComment.UpdateTime</div>@*CFT-24*@
</div>
</div>
</div>
<span>@ViewBag.Message</span>
</div>
if (Model.LcaStatus == Weee.Models.LCAStatus.Waiting)
{
<div class="docs-content-gap-sm">
<input class="pull-right header-button" type="submit" value="@Resource.StaticLabelGlobal_Save" />
</div>
}
}
</div>

View File

@ -0,0 +1,67 @@
@model IEnumerable<Weee.Models.LCA>
@using Weee.Models
@using Resources
@using PagedList.Mvc
@using PagedList
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="row docs-row">
<div class="col-xs-5">
<h2 class="docs-h2">歷史紀錄</h2>
</div>
<div class="col-xs-7" style="margin-top: 20px;margin-bottom: 10px;">
@using (Html.BeginForm("all", "home", FormMethod.Get, new { id = "search-filter", @class = "form-horizontal" }))
{
<div class="form-group">
<div class="col-sm-8">
<input name="searchString" class="form-control" type="text" value="@ViewBag.SearchString" />
</div>
<div class="col-sm-4">
<input type="submit" value="@Resource.StaticLabelGlobal_Search" class="btn btn-default" />
@Html.ActionLink(Resource.StaticLabelGlobal_Cancel, "", new { }, new { @class = "btn btn-default" })
</div>
</div>
}
</div>
</div>
<div>
<table class="table table-bordered docs-table">
<tr class="certification_table_header">
@*<th>@Html.ActionLink("ID","All",new{((IPagedList)Model).PageNumber,searchString=ViewBag.SearchString})</th>*@
<th>ID</th>
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>
@if (item.LCAType == typeof(ProductLCA))
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
else if (item.LCAType == typeof(OrganizationLCA))
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
</table>
<div class="text-center">
@Html.PagedListPager((IPagedList)Model, page => Url.Action("All", new { page, searchString = ViewBag.SearchString }))
</div>
</div>
</div>

View File

@ -0,0 +1,119 @@
@using Weee.Models
@using Resources
@model IEnumerable<Weee.ViewModels.CertificationViewModel> /*CFT-30*/
@*@model IEnumerable<Weee.Models.LCA>*@@*CFT-30*@
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="tab_header">
<div class="active tab-toggle">
<div class="tab">@Resource.LCAStatusWaiting</div>
</div>
</div>
<div class="tab_content card content_bg">
<div style="align-self:flex-start">
<button class="header-button" id="upload-button-2" onclick="showModel(2)">上傳產品型申請表</button> &nbsp;&nbsp;&nbsp;
<button class="header-button" id="upload-button-1" onclick="showModel(1)">上傳組織型申請表</button> &nbsp;&nbsp;&nbsp;
</div>
<div>
@if (TempData["ErrMsg"] != null)
{
<p class="text-danger">@TempData["ErrMsg"]</p>
}
@if (TempData["SuccessMsg"] != null)
{
<p class="font-weight-bold" style="color: green;">@TempData["SuccessMsg"]</p>
}
</div>
<div style="margin: 20px">
<div class="table-responsive">
<div style="overflow-x:auto;">
<table class="table">
@*<table class="table table-bordered docs-table">*@
<tr style="color: #fff; background-color: #A1A1A1; text-align: center">
@*<tr class="certification_table_header">*@
<th>@Html.DisplayNameFor(x => x.ID)</th>
<th>@Html.DisplayNameFor(x => x.LCAname)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.CreatedDate)</th>
<th>@Html.DisplayNameFor(x => x.LCAitemName)</th> @*CFT-30*@
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@Html.DisplayFor(x => item.LCAname)</td>
@*<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>*@ @*CFT-30*@
<td>@Html.DisplayFor(x => item.LCATypeName)</td> @*CFT_30*@
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.CreatedDate)</td>
<td>@Html.DisplayFor(x => item.LCAitemName)</td>
@*CFT-30*@
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
@*@if (item.LCAType == typeof(ProductLCA))*@@*CFT-30*@
@if (item.LCATypeName == Resource.StaticLabelProductLCA) /*CFT-30*/
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
//else if (item.LCAType == typeof(OrganizationLCA)) CFT-30
else if (item.LCATypeName == Resource.StaticLabelOrganizationLCA) /*CFT-30*/
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
@if (Model.Count() == 0)
{
<tr><td colspan="8">@Resource.NoData @Resource.Click@Html.ActionLink(Resource.Here, "all")@Resource.SeeHistory</td></tr>
}
</table>
</div>
</div>
</div>
</div>
</div>
@using (Html.BeginForm("UploadFileFA", "Home", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
<div class="table_edit_wrap transition show_table_edit" id="file-upload-fa" style="display: none; width: 100%; height: calc(100vh + 150px); background-color: rgb(128,128,128, 0.6); position: fixed; z-index: 1001;margin-top: -150px">
<div>
<div class="edit_form" style="z-index: 1001; position: fixed; margin: auto; left: 0; right: 0; top: 30%; background-color: #eeeeee; width: 500px; border: 1px solid #bbb; border-radius: 5px; padding-bottom: 20px; box-shadow: 1px 1px 1px 1px #ddd; height: 140px;">
<div style="float:right;margin: 10px 10px;cursor: pointer;" onclick="cancel()">
<img src="~/Browser_Local/img/header_image7_1.png" alt="close" />
</div>
<div id="upload-file-result-msg" style="padding: 20px 0 10px 10px;">上傳文件:</div>
<div style="margin-left: 30px;">
<input id="fileUpload" type="file" name="uploadedFile" required/>
<input type="submit" value="@Resource.StaticLabelImport" class="btn btn-default" />
</div>
<p style="color:red;margin-top: 0;margin-left:28px;">僅支持的文件類型zip</p>
</div>
<input type="hidden" id="hdn_upd" name="updType" value=""/>
</div>
</div>
}
<script>
function showModel(updType) {
document.getElementById("hdn_upd").value = updType;
var model = document.getElementById("file-upload-fa");
model.style.display = "block";
}
function cancel() {
let box = document.getElementById('file-upload-fa');
box.style.display = 'none';
}
</script>

View File

@ -0,0 +1,72 @@
@using Weee.Models
@using Resources
@*@model IEnumerable<Weee.Models.LCA>*@ @*CFT-30*@
@model IEnumerable<Weee.ViewModels.CertificationViewModel> /*CFT-30*/
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="tab_header">
<div class="active tab-toggle">
<div class="tab">@Resource.LCAStatusCompleted</div>
</div>
</div>
<div>
<div class="tab_content card content_bg">
<div style="margin: 20px">
<div class="table-responsive">
<div style="overflow-x:auto;">
<table class="table">
<tr style="color: #fff; background-color: #A1A1A1; text-align: center">
<th>@Html.DisplayNameFor(x => x.ID)</th>
<th>@Html.DisplayNameFor(x => x.LCAname)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.CreatedDate)</th>
<th>@Html.DisplayNameFor(x => x.LCAitemName)</th>
@*CFT-30*@
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@Html.DisplayFor(x => item.LCAname)</td>
<!--<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>-->@*CFT-30*@
<td>@Html.DisplayFor(x => item.LCATypeName)</td>
@*CFT-30*@
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.CreatedDate)</td>
<td>@Html.DisplayFor(x => item.LCAitemName)</td>
@*CFT-30*@
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
@*@if (item.LCAType == typeof(ProductLCA))*@@*CFT-30*@
@if (item.LCATypeName == Resource.StaticLabelProductLCA)/*CFT-30*/
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
//else if (item.LCAType == typeof(OrganizationLCA))@*CFT-30*@
else if (item.LCATypeName == Resource.StaticLabelOrganizationLCA)/*CFT-30*/
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
@if (Model.Count() == 0)
{
<tr><td colspan="8">@Resource.NoData @Resource.Click@Html.ActionLink(Resource.Here, "all")@Resource.SeeHistory</td></tr>
}
</table>
</div>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,73 @@
@using Weee.Models
@using Resources
@*@model IEnumerable<Weee.Models.LCA>*@ @*CFT-30*@
@model IEnumerable<Weee.ViewModels.CertificationViewModel> /*CFT-30*/
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="tab_header">
<div class="active tab-toggle">
<div class="tab">@Resource.LCAStatusConfirmed</div>
</div>
</div>
<div>
<div class="tab_content card content_bg">
<div style="margin: 20px">
<div class="table-responsive">
<div style="overflow-x:auto;">
<table class="table">
<tr style="color: #fff; background-color: #A1A1A1; text-align: center">
<th>@Html.DisplayNameFor(x => x.ID)</th>
<th>@Html.DisplayNameFor(x => x.LCAname)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.CreatedDate)</th>
<th>@Html.DisplayNameFor(x => x.LCAitemName)</th>
@*CFT-30*@
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@Html.DisplayFor(x => item.LCAname)</td>
<!--<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>-->@*CFT-30*@
<td>@Html.DisplayFor(x => item.LCATypeName)</td>
@*CFT-30*@
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.CreatedDate)</td>
<td>@Html.DisplayFor(x => item.LCAitemName)</td>
@*CFT-30*@
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
@*@if (item.LCAType == typeof(ProductLCA))CFT-30*@
@if (item.LCATypeName == Resource.StaticLabelProductLCA)/*CFT-30*/
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
//else if (item.LCAType == typeof(OrganizationLCA))@*CFT-30*@
else if (item.LCATypeName == Resource.StaticLabelOrganizationLCA) /*CFT-30*/
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
@if (Model.Count() == 0)
{
<tr><td colspan="8">@Resource.NoData @Resource.Click@Html.ActionLink(Resource.Here, "all")@Resource.SeeHistory</td></tr>
}
</table>
</div>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,72 @@
@using Weee.Models
@using Resources
@*@model IEnumerable<Weee.Models.LCA>*@ @*CFT-30*@
@model IEnumerable<Weee.ViewModels.CertificationViewModel> /*CFT-30*/
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="tab_header">
<div class="active tab-toggle">
<div class="tab">@Resource.LCAStatusNew</div>
</div>
</div>
<div>
<div class="tab_content card content_bg">
<div style="margin: 20px">
<div class="table-responsive">
<div style="overflow-x:auto;">
<table class="table">
<tr style="color: #fff; background-color: #A1A1A1; text-align: center">
<th>@Html.DisplayNameFor(x => x.ID)</th>
<th>@Html.DisplayNameFor(x => x.LCAname)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.CreatedDate)</th>
<th>@Html.DisplayNameFor(x => x.LCAitemName)</th>
@*CFT-30*@
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@Html.DisplayFor(x => item.LCAname)</td>
@*<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>*@@*CFT-30*@
<td>@Html.DisplayFor(x => item.LCATypeName)</td>
@*CFT_30*@
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.CreatedDate)</td>
<td>@Html.DisplayFor(x => item.LCAitemName)</td>
@*CFT-30*@
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
@*@if (item.LCAType == typeof(ProductLCA))*@ @*CFT-30*@
@if (item.LCATypeName == Resource.StaticLabelProductLCA)/*CFT-30*/
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
//else if (item.LCAType == typeof(OrganizationLCA)) /*CFT-30*/
else if (item.LCATypeName == Resource.StaticLabelOrganizationLCA) /*CFT-30*/
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
@if (Model.Count() == 0)
{
<tr><td colspan="8">@Resource.NoData @Resource.Click@Html.ActionLink(Resource.Here, "all")@Resource.SeeHistory</td></tr>
}
</table>
</div>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,71 @@
@using Weee.Models
@using Resources
@*@model IEnumerable<Weee.Models.LCA>*@@*CFT-30*@
@model IEnumerable<Weee.ViewModels.CertificationViewModel> /*CFT-30*/
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="tab_header">
<div class="active tab-toggle">
<div class="tab">@Resource.LCAStatusProcessing</div>
</div>
</div>
<div>
<div class="tab_content card content_bg">
<div style="margin: 20px">
<div class="table-responsive">
<div style="overflow-x:auto;">
<table class="table">
<tr style="color: #fff; background-color: #A1A1A1; text-align: center">
<th>@Html.DisplayNameFor(x => x.ID)</th>
<th>@Html.DisplayNameFor(x => x.LCAname)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.CreatedDate)</th>
<th>@Html.DisplayNameFor(x => x.LCAitemName)</th> @*CFT-30*@
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@Html.DisplayFor(x => item.LCAname)</td>
<!--<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>-->@*CFT-30*@
<td>@Html.DisplayFor(x => item.LCATypeName)</td>
@*CFT-30*@
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.CreatedDate)</td>
<td>@Html.DisplayFor(x => item.LCAitemName)</td>
@*CFT-30*@
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
@*@if (item.LCAType == typeof(ProductLCA))*@ @*CFT-30*@
@if (item.LCATypeName == Resource.StaticLabelProductLCA) /*CFT-30*/
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
//else if (item.LCAType == typeof(OrganizationLCA))/* CFT-30*/
else if (item.LCATypeName == Resource.StaticLabelOrganizationLCA)/* CFT-30*/
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
@if (Model.Count() == 0)
{
<tr><td colspan="8">@Resource.NoData @Resource.Click@Html.ActionLink(Resource.Here, "all")@Resource.SeeHistory</td></tr>
}
</table>
</div>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,72 @@
@using Weee.Models
@using Resources
@*@model IEnumerable<Weee.Models.LCA>*@ @*CFT-30*@
@model IEnumerable<Weee.ViewModels.CertificationViewModel> /*CFT-30*/
@{
ViewBag.Title = Resource.HomePage;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
}
<div class="panel panel-default docs-panel">
<div class="tab_header">
<div class="active tab-toggle">
<div class="tab">@Resource.LCAStatusRejected</div>
</div>
</div>
<div>
<div class="tab_content card content_bg">
<div style="margin: 20px">
<div class="table-responsive">
<div style="overflow-x:auto;">
<table class="table">
<tr style="color: #fff; background-color: #A1A1A1; text-align: center">
<th>@Html.DisplayNameFor(x => x.ID)</th>
<th>@Html.DisplayNameFor(x => x.LCAname)</th>
<th>@Html.DisplayNameFor(x => x.LCAType)</th>
<th>@Html.DisplayNameFor(x => x.Description)</th>
<th>@Html.DisplayNameFor(x => x.CreatedDate)</th>
<th>@Html.DisplayNameFor(x => x.LCAitemName)</th>
@*CFT-30*@
<th>@Html.DisplayNameFor(x => x.StartDate)</th>
<th>@Html.DisplayNameFor(x => x.EndDate)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@Html.DisplayFor(x => item.ID)</td>
<td>@Html.DisplayFor(x => item.LCAname)</td>
@*<td>@Html.DisplayFor(x => item.LCATypeDisplayName)</td>*@@*CFT-30*@
<td>@Html.DisplayFor(x => item.LCATypeName)</td>
@*CFT-30*@
<td>@Html.DisplayFor(x => item.Description)</td>
<td>@Html.DisplayFor(x => item.CreatedDate)</td>
<td>@Html.DisplayFor(x => item.LCAitemName)</td>
@*CFT-30*@
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
@*@if (item.LCAType == typeof(ProductLCA))*@ @*CFT-30*@
@if (item.LCATypeName == Resource.StaticLabelProductLCA) /*CFT-30*/
{
<td>@Html.ActionLink("Detail", "ProductLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
//else if (item.LCAType == typeof(OrganizationLCA))/*CFT-30*/
else if (item.LCATypeName == Resource.StaticLabelOrganizationLCA)/*CFT-30*/
{
<td>@Html.ActionLink("Detail", "OrganizationLcaDetail", "LCA", new { id = item.ID }, null)</td>
}
</tr>
}
@if (Model.Count() == 0)
{
<tr><td colspan="8">@Resource.NoData @Resource.Click@Html.ActionLink(Resource.Here, "all")@Resource.SeeHistory</td></tr>
}
</table>
</div>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,900 @@
@*
the Comment.Category is defined in ProductLCADetail.cshtml
used by Normal company and Certificate company
possible value of Category:
LCI_Direct_Material,
LCI_Indirect_Material,
LCI_Wrap_Material,
WorkHour,
PowerUsage,
WaterUsage,
Waste_Water,
Waste_Other,
Transport,
WasteTransport,
Vehicle,
GasolineEquipment,
Kitchen_Company,
Kitchen_Outsourcing,
Kitchen_Other,
Refrigerant,
FireEquipment,
SteamUsage,
OtherCompound
*@
@using Resources
@using Weee.Models.ExtensionMethods
@using Weee.Areas.Certification.Supports
@using Weee.Models
@model Weee.Models.OrganizationLCA
@{
ViewBag.Title = Resource.StaticLabelOrganizationLCA;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
var kitchensOwned = Model.KitchenSheet.Where(x => x.Type == LCACommonSurveyForm_Kitchens.KitchenType.owned);
var kitchensOutsourcing = Model.KitchenSheet.Where(x => x.Type == LCACommonSurveyForm_Kitchens.KitchenType.outsourcing);
var kitchensOther = Model.KitchenSheet.Where(x => x.Type == LCACommonSurveyForm_Kitchens.KitchenType.other);
var sources = ViewData["sources"] as Dictionary<int, string>;
}
@section PageStyles {
@Styles.Render("~/fancybox/css")
}
@section PageScripts {
@Scripts.Render("~/fancybox")
@Scripts.Render("~/sticky")
@Scripts.Render("~/certification/lca/detail")
}
@*<div class="side-bar-top-empty"></div>*@
@*<div class="side-bar col-xs-2 js-scrollspy">*@
<html style="scroll-behavior: smooth;">
<div class="container-fluid">
<div class="panel row">
<div class="col-md-2 org-split-left side-bar js-scrollspy">
<ul id="docs-scroll-hash-nav" class="navbar-nav nav-pills">
@*<ul id="docs-scroll-hash-nav" class="nav nav-pills nav-stacked nav-float docs-ul">*@
<li class="nav-item"><a class="active nav-link" href="#lca-detail">@Resource.BasicInfo</a></li>
<li class="nav-item"><a class="nav-link" href="#total-workhour">@Resource.TotalWorkHours</a></li>
<li class="nav-item"><a class="nav-link" href="#power-usage">@Resource.PowerUsage</a></li>
<li class="nav-item"><a class="nav-link" href="#vehicle">@Resource.ParamemterCategoriesVehicle</a></li>
<li class="nav-item"><a class="nav-link" href="#gasoline">@Resource.DieselEquipment</a></li>
<li class="nav-item"><a class="nav-link" href="#kitchen-owned">@Resource.Kitchen</a></li>
<li style="display:none" class="nav-item"><a class="nav-link" href="#kitchen-outsourcing">@Resource.Kitchen (@Resource.Outsourcing)</a></li>
<li style="display:none" class="nav-item"><a class="nav-link" href="#kitchen-other">@Resource.Kitchen (@Resource.Other)</a></li>
<li class="nav-item"><a class="nav-link" href="#fire-equipment">@Resource.FireEquipment</a></li>
<li class="nav-item"><a class="nav-link" href="#refrigerant">@Resource.ContainsRefrigerant</a></li>
<li class="nav-item"><a class="nav-link" href="#steam-usage">@Resource.SteamUsage</a></li>
<li class="nav-item"><a class="nav-link" href="#other-compound">@Resource.OtherCompound</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetailLifecycleAssmt","LCA", new { id = Model.ID })">@Resource.LifecycleStageAssessment</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetailSignificance","LCA", new { id = Model.ID })">@Resource.RASignificance</a></li>
</ul>
</div>
<div id="docs-scroll-hash-content" class="col-md-10 org-split-right" style="margin-left: auto">
@*<div id="docs-scroll-hash-content" class="col-xs-10 panel panel-default">*@
<div id="lca-detail" class="docs-lca-detail">
<div class="row">
<div class="col-md-4">
<label>@(Resource.Starter): </label>
<span>@Model.LCAStarter</span>
</div>
<div class="col-md-4">
<label>@(Resource.PhoneNumber): </label>
<span>@Model.LCAStarterPhone</span>
</div>
<div class="col-md-4">
<label>@(Resource.LCAStartDate): </label>
<span>@Model.StartDate.ToShortDateString()</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
<label>@(Resource.Job): </label>
<span>@Model.LCAStarterJob</span>
</div>
<div class="col-md-4">
<label>@(Resource.Department): </label>
<span>@Model.LCAStarterDepartment</span>
</div>
<div class="col-md-4">
<label>@(Resource.LCAEndDate): </label>
<span>@Model.EndDate.ToShortDateString()</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
@*<label>@Resource.InterrogationResultReport @Resource.StaticLabelGlobal_And @Resource.CarbonFootprintReport: </label>
@if (ViewData["templates"] != null)
{
<span><a href="@ViewData["templates"]">@Resource.DownloadLink</a></span>
}*@
@*<span><a href="@ViewData["UploadZipReply"]">@Resource.UploadZipReply</a></span>*@
<span><a href="@ViewData["DownloadZipReport"]">@Resource.ZipReport</a></span>
@*<label>@(Resource.InterrogationResultReport): </label>
@if (Model.InterrogationResultUrl != null && Model.InterrogationResultUrl != "")
{
//Start CFT-6
if (Model.InterrogationResultUrl.Contains("Browser_Local"))
{
<span><a href="@Model.InterrogationResultUrl.Substring(Model.InterrogationResultUrl.IndexOf("Browser_Local") - 1)">@Resource.DownloadLink</a></span>
}
else
{
<span><a href="@Model.InterrogationResultUrl">@Resource.DownloadLink</a></span>
}
<!--<span><a href="@Model.InterrogationResultUrl">@Resource.DownloadLink</a></span>-->
//End CFT-6
}
*@
</div>
<div class="col-md-4">
@*<label>@(Resource.CarbonFootprintReport): </label>
@if (Model.CarbonFootprintDocxUrl != null && Model.CarbonFootprintDocxUrl != "")
{
//Start CFT-6
if (Model.CarbonFootprintDocxUrl.Contains("Browser_Local"))
{
<span><a href="@Model.CarbonFootprintDocxUrl.Substring(Model.CarbonFootprintDocxUrl.IndexOf("Browser_Local")-1)">@Resource.DownloadLink</a></span>
}
else
{
<span><a href="@Model.CarbonFootprintDocxUrl">@Resource.DownloadLink</a></span>
}
<!--<span><a href="@Model.CarbonFootprintDocxUrl">@Resource.DownloadLink</a></span>-->
//End CFT -6
}*@
</div>
<div class="col-md-4">
<label>@Resource.ScheduledVerificationDate: </label>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
using (Html.BeginForm("OrganizationLcaChangeScheduledVerificationDate", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-ChangeScheduledVerificationDate", @class = "docs-inline" }))
{
@Html.TextBoxFor(model => model.ScheduledVerificationDate, new { @type = "date" , @Value = Model.ScheduledVerificationDate.HasValue ? Model.ScheduledVerificationDate.Value.ToString("yyyy-MM-dd") : ""})
}
}
else
{
<span>@(Model.ScheduledVerificationDate.HasValue ? (Model.ScheduledVerificationDate.Value).ToString("YYYY/MM/DD") : "")</span>
}
</div>
</div>
</div>
<div class="message text-danger" style="background-color:yellow">
@TempData["successMsg"]
@TempData["errorMsg"]
</div>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
<div class="pull-right docs-btn-group">
<input id="confirm-button" type="button" value="@Resource.Approve" class="header-button" />
@using (Html.BeginForm("OrganizationLcaConfirm", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-confirm", @class = "docs-inline" })) { }
<input id="reject-button" type="button" value="@Resource.Reject" class="header-button" />
@using (Html.BeginForm("OrganizationLcaReject", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-reject", @class = "docs-inline" })) { }
<button class="header-button" id="upload-button" onclick="showModel()">@Resource.StaticLabelGlobal_Upload</button>
</div>
}
@if (Model.Status == Weee.Models.LCAStatus.Processing)
{
<div class="pull-right docs-btn-group">
<input id="refuse-button" type="button" value="@Resource.Refuse" class="header-button" />
@using (Html.BeginForm("OrganizationLcaRefuse", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-refuse", @class = "docs-inline" })) { }
</div>
}
<div>
<div>
<h4 id="total-workhour" class="docs-inline">@Resource.TotalWorkHours - @Resource.DirectStaff</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=WorkHour" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.StaticLabelGlobal_Month</th>
<th>@Resource.WorkerNumber</th>
<th>@Resource.WorkDays</th>
<th>@Resource.AverageHourPerDay</th>
<th>@(Resource.ProportionOfWorkingHours)(%)</th>
<th>@(Resource.TotalWorkHours)(Hours)</th>
<th>KgCO2e</th>
</tr>
@foreach (var workHour in Model.WorkHourSheet)
{
if (workHour.Type.ToString() == "Direct")
{
<tr align="right">
<td>@workHour.MonthLabel()</td>
<td>@workHour.WorkerNumber.ToString("F0")</td>
<td>@workHour.WorkDay.ToString("F")</td>
<td>@workHour.AverageHourPerDay.ToString("F4")</td>
<td>@((workHour.AverageHourPerDay / 8).ToString("F4"))</td>
<td>@((workHour.WorkerNumber * workHour.WorkDay * workHour.AverageHourPerDay).ToString("F4"))</td>
<td>@workHour.KgCO2e.ToString("F4")</td>
</tr>
}
}
<tr align="right">
<td>@Resource.Total</td>
<td>@Model.WorkHourSheet.ToList().GetTotalDirectWorkerNumber().ToString("F0")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalDirectWorkDay().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalDirectAverageHourPerDay().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalDirectProportionWorkHour().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalDirectWorkHours().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalKgCO2e().ToString("F4")</td>
</tr>
</table>
<h4 class="docs-inline">@Resource.TotalWorkHours - @Resource.IndirectStaff</h4>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.StaticLabelGlobal_Month</th>
<th>@Resource.WorkerNumber</th>
<th>@Resource.WorkDays</th>
<th>@Resource.AverageHourPerDay</th>
<th>@(Resource.ProportionOfWorkingHours)(%)</th>
<th>@(Resource.TotalWorkHours)(Hours)</th>
<th>KgCO2e</th>
</tr>
@foreach (var workHour in Model.WorkHourSheet)
{
if (workHour.Type.ToString() == "Indirect")
{
<tr align="right">
<td>@workHour.MonthLabel()</td>
<td>@workHour.WorkerNumber.ToString("F0")</td>
<td>@workHour.WorkDay.ToString("F4")</td>
<td>@workHour.AverageHourPerDay.ToString("F4")</td>
<td>@((workHour.AverageHourPerDay / 8).ToString("F4"))</td>
<td>@((workHour.WorkerNumber * workHour.WorkDay * workHour.AverageHourPerDay).ToString("F4"))</td>
<td>@workHour.KgCO2e.ToString("F4")</td>
</tr>
}
}
<tr align="right">
<td>@Resource.Total</td>
<td>@Model.WorkHourSheet.ToList().GetTotalIndirectWorkerNumber().ToString("F0")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalIndirectWorkDay().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalIndirectAverageHourPerDay().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalIndirectProportionWorkHour().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalIndirectWorkHours().ToString("F4")</td>
<td>@Model.WorkHourSheet.ToList().GetTotalKgCO2e().ToString("F4")</td>
</tr>
</table>
</div>
<div>
<h4 id="power-usage" class="docs-inline">@Resource.PowerNormal / @Resource.PowerGreen</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=PowerUsage" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.StaticLabelGlobal_Month</th>
<th>@Resource.Peak</th>
<th>@Resource.HalfPeak</th>
<th>@Resource.SaturdayHalfPeak</th>
<th>@Resource.OffPeak</th>
<th>@Resource.TotalPowerUsage</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>KgCO2e</th>
<th>@Resource.StaticLabelEvidenceOfElectronicFile</th>
</tr>
@foreach (var powerUsage in Model.PowerUsageSheet)
{
<tr>
<td align="right">@powerUsage.MonthLabel()</td>
<td align="right">@(powerUsage.Peak.HasValue ? powerUsage.Peak.Value.ToString("F4") : null)</td>
<td align="right">@(powerUsage.HalfPeak.HasValue ? powerUsage.HalfPeak.Value.ToString("F4") : null)</td>
<td align="right">@(powerUsage.SaturdayHalfPeak.HasValue ? powerUsage.SaturdayHalfPeak.Value.ToString("F4") : null)</td>
<td align="right">@(powerUsage.OffPeak.HasValue ? powerUsage.OffPeak.Value.ToString("F4") : null)</td>
<td align="right">@((powerUsage.Peak.Value + powerUsage.HalfPeak.Value + powerUsage.SaturdayHalfPeak.Value + powerUsage.OffPeak.Value).ToString("F4"))</td>
<td align="right">@powerUsage.Year</td>
<td align="right">@powerUsage.KgCO2e.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(powerUsage.ReferenceFileLink))
{<a href="@powerUsage.ReferenceFileLink">@Resource.StaticLabelDownload</a>}
</td>
</tr>
}
<tr align="right">
<td>@Resource.Total</td>
<td>@Model.PowerUsageSheet.ToList().GetTotalPowerPeak().ToString("F4")</td>
<td>@Model.PowerUsageSheet.ToList().GetTotalPowerHalfPeak().ToString("F4")</td>
<td>@Model.PowerUsageSheet.ToList().GetTotalPowerSaturdayHalfPeak().ToString("F4")</td>
<td>@Model.PowerUsageSheet.ToList().GetTotalPowerOffPeak().ToString("F4")</td>
<td>@Model.PowerUsageSheet.ToList().GetTotalPowerUsage().ToString("F4")</td>
<td></td>
<td>@Model.PowerUsageSheet.ToList().GetTotalKgCO2e().ToString("F4")</td>
<td></td>
</tr>
</table>
</div>
<div>
<h4 id="vehicle" class="docs-inline">@Resource.ParamemterCategoriesVehicle</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=Vehicle" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.VehicleVehicleType</th>
@*<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>
<th>@Resource.OfficialDepotVehicleModel</th>*@
<th>@Resource.CarPlateNo</th>
<th>@Resource.Area</th>
<th>@Resource.FuelType</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>@Resource.FuelConsumptionDuringInterrogation</th>
<th>@Resource.RefuelingRecord</th>
<th>@Resource.OfficialVehiclePhoto</th>
<th>@Resource.EmitPara</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (Model.VehicleSheet.Count() == 0)
{
<tr>
<td class="text-center" colspan="13">@Resource.NoData</td>
</tr>
}
@foreach (var vehicle in Model.VehicleSheet)
{
<tr>
<td>@vehicle.Type.ToString()</td>
@*<td>@vehicle.ProcessName</td>
<td>@vehicle.ResponsibleUnit</td>
<td>@vehicle.Name</td>*@
<td>@vehicle.CarPlateNo</td>
<td>
@(vehicle.Parameter != null && vehicle.Parameter.Area != null ? vehicle.Parameter.Area.DisplayName : "")
</td>
<td>
@(vehicle.Parameter != null && vehicle.Parameter.Type != null ? ViewHelper.GetEntityCategory(vehicle.Parameter.Type.DisplayName) : "")
</td>
<td align="right">@(vehicle.Parameter != null ? vehicle.Parameter.Year.ToString() : "")</td>
<td align="right">@vehicle.Scalar.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(vehicle.ReferenceFileUrl))
{<a href="@vehicle.ReferenceFileUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>
@if (!string.IsNullOrEmpty(vehicle.ReferencePhotoUrl))
{<a href="@vehicle.ReferencePhotoUrl">@Resource.StaticLabelDownload</a>}
</td>
<td align="right">@vehicle.Parameter.CO2Value</td>
<td align="right">@vehicle.KgCO2e.ToString("F4")</td>
<td>
<a class="iframe" href="~/Certification/Parameter/yearly/@vehicle.ParameterID" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
</td>
</tr>
}
</table>
</div>
<div>
<h4 id="gasoline" class="docs-inline">@Resource.DieselEquipment</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=GasolineEquipment" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>
<th>@Resource.OilEquipment</th>
<th>@Resource.Area</th>
<th>@Resource.FuelType</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>@(Resource.FuelConsumptionDuringInterrogation)(L)</th>
<th>@Resource.SupportDocumentOfUsageAmount</th>
<th>@Resource.EquipmentAndPhoto</th>
<th>@Resource.EmitPara</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (Model.GasolineEquipmentSheet.Count() == 0)
{
<tr>
<td class="text-center" colspan="11">@Resource.NoData</td>
</tr>
}
@foreach (var gasolineEquipment in Model.GasolineEquipmentSheet)
{
<tr>
<td>@gasolineEquipment.ProcessName</td>
<td>@gasolineEquipment.ResponsibleUnit</td>
<td>@gasolineEquipment.Name</td>
<td>
@(gasolineEquipment.Parameter != null && gasolineEquipment.Parameter.Area != null ? gasolineEquipment.Parameter.Area.DisplayName : "")
</td>
<td>
@(gasolineEquipment.Parameter != null && gasolineEquipment.Parameter.Type != null ? ViewHelper.GetEntityCategory(gasolineEquipment.Parameter.Type.DisplayName) : "")
</td>
<td align="right">
@(gasolineEquipment.Parameter != null ? gasolineEquipment.Parameter.Year.ToString() : "")
</td>
<td align="right">@gasolineEquipment.Scalar.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(gasolineEquipment.ReferenceFileUrl))
{<a href="@gasolineEquipment.ReferenceFileUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>
@if (!string.IsNullOrEmpty(gasolineEquipment.ReferencePhotoUrl))
{<a href="@gasolineEquipment.ReferencePhotoUrl">@Resource.StaticLabelDownload</a>}
</td>
<td align="right">@gasolineEquipment.Parameter.CO2Value</td>
<td align="right">@gasolineEquipment.KgCO2e.ToString("F4")</td>
<td>
@if (gasolineEquipment.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/yearly/@gasolineEquipment.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
</table>
</div>
<div>
<h4 id="kitchen-owned" class="docs-inline">@(Resource.Kitchen)</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=Kitchen_Company" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>
<th>@Resource.DeviceName</th>
<th>@Resource.Area</th>
<th>@Resource.FuelType</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>@(Resource.FuelConsumptionDuringInterrogation)(L)</th>
<th>@Resource.SupportDocumentOfUsageAmount</th>
<th>@Resource.EquipmentAndPhoto</th>
<th>@Resource.EmitPara</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (kitchensOwned.Count() == 0)
{
<tr>
<td class="text-center" colspan="11">@Resource.NoData</td>
</tr>
}
@foreach (var kitchen in kitchensOwned)
{
<tr>
<td>@kitchen.ProcessName</td>
<td>@kitchen.ResponsibleUnit</td>
<td>@kitchen.Name</td>
<td>
@(kitchen.Parameter != null && kitchen.Parameter.Area != null ? kitchen.Parameter.Area.DisplayName : "")
</td>
<td>
@(kitchen.Parameter != null && kitchen.Parameter.Type != null ? ViewHelper.GetEntityCategory(kitchen.Parameter.Type.DisplayName) : "")
</td>
<td align="right">
@(kitchen.Parameter != null ? kitchen.Parameter.Year.ToString() : "")
</td>
<td align="right">@kitchen.Scalar.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(kitchen.ReferenceFileUrl))
{<a href="@kitchen.ReferenceFileUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>
@if (!string.IsNullOrEmpty(kitchen.ReferencePhotoUrl))
{<a href="@kitchen.ReferencePhotoUrl">@Resource.StaticLabelDownload</a>}
</td>
<td align="right">@kitchen.Parameter.CO2Value</td>
<td align="right">@kitchen.KgCO2e.ToString("F4")</td>
<td>
@if (kitchen.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/yearly/@kitchen.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
</table>
</div>
<div style="display:none">
<h4 id="kitchen-outsourcing" class="docs-inline">@(Resource.Kitchen)(@Resource.Outsourcing)</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=Kitchen_Outsourcing" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
@*<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>*@
<th>@Resource.DeviceName</th>
<th>@Resource.Area</th>
<th>@Resource.FuelType</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>@(Resource.FuelConsumptionDuringInterrogation)(L)</th>
<th>@Resource.SupportDocumentOfUsageAmount</th>
<th>@Resource.EquipmentAndPhoto</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (kitchensOutsourcing.Count() == 0)
{
<tr>
<td class="text-center" colspan="11">@Resource.NoData</td>
</tr>
}
@foreach (var kitchen in kitchensOutsourcing)
{
<tr>
@*<td>@kitchen.ProcessName</td>
<td>@kitchen.ResponsibleUnit</td>*@
<td>@kitchen.Name</td>
<td>
@(kitchen.Parameter != null && kitchen.Parameter.Area != null ? kitchen.Parameter.Area.DisplayName : "")
</td>
<td>
@(kitchen.Parameter != null && kitchen.Parameter.Type != null ? ViewHelper.GetEntityCategory(kitchen.Parameter.Type.DisplayName) : "")
</td>
<td>
@(kitchen.Parameter != null ? kitchen.Parameter.Year.ToString() : "")
</td>
<td>@kitchen.Scalar.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(kitchen.ReferenceFileUrl))
{<a href="@kitchen.ReferenceFileUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>
@if (!string.IsNullOrEmpty(kitchen.ReferencePhotoUrl))
{<a href="@kitchen.ReferencePhotoUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>@kitchen.KgCO2e.ToString("F4")</td>
<td>
@if (kitchen.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/yearly/@kitchen.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
</table>
</div>
<div style="display:none">
<h4 id="kitchen-other" class="docs-inline">@(Resource.Kitchen)(@Resource.Other)</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=Kitchen_Other" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>
<th>@Resource.DeviceName</th>
<th>@Resource.Area</th>
<th>@Resource.FuelType</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>@(Resource.FuelConsumptionDuringInterrogation)(L)</th>
<th>@Resource.SupportDocumentOfUsageAmount</th>
<th>@Resource.EquipmentAndPhoto</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (kitchensOther.Count() == 0)
{
<tr>
<td class="text-center" colspan="11">@Resource.NoData</td>
</tr>
}
@foreach (var kitchen in kitchensOther)
{
<tr>
<td>@kitchen.ProcessName</td>
<td>@kitchen.ResponsibleUnit</td>
<td>@kitchen.Name</td>
<td>
@(kitchen.Parameter != null && kitchen.Parameter.Area != null ? kitchen.Parameter.Area.DisplayName : "")
</td>
<td>
@(kitchen.Parameter != null && kitchen.Parameter.Type != null ? ViewHelper.GetEntityCategory(kitchen.Parameter.Type.DisplayName) : "")
</td>
<td>
@(kitchen.Parameter != null ? kitchen.Parameter.Year.ToString() : "")
</td>
<td>@kitchen.Scalar.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(kitchen.ReferenceFileUrl))
{<a href="@kitchen.ReferenceFileUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>
@if (!string.IsNullOrEmpty(kitchen.ReferencePhotoUrl))
{<a href="@kitchen.ReferencePhotoUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>@kitchen.KgCO2e.ToString("F4")</td>
<td>
@if (kitchen.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/yearly/@kitchen.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
</table>
</div>
<div>
<h4 id="fire-equipment" class="docs-inline">@Resource.FireEquipment</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=FireEquipment" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
@*<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>*@
<th>@Resource.DeviceName</th>
<th>@Resource.Quantity</th>
<th>@Resource.EmissionSources</th>
<th>@(Resource.UsageAmount)(kg)</th>
<th>@Resource.Notes</th>
<th>@Resource.EmitPara</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (Model.FireEquipmentSheet.Count() == 0)
{
<tr>
<td class="text-center" colspan="9">@Resource.NoData</td>
</tr>
}
@foreach (var fireEquipment in Model.FireEquipmentSheet)
{
<tr>
@*<td>@fireEquipment.ProcessName</td>
<td>@fireEquipment.ResponsibleUnit</td>*@
<td>@fireEquipment.Name</td>
<td align="right">@fireEquipment.Quantity</td>
<td>
@(fireEquipment.ARnGWP != null ? fireEquipment.ARnGWP.ingredientName : "")
</td>
<td align="right">@fireEquipment.Scalar.ToString("F4")</td>
<td>@fireEquipment.Description</td>
<td align="right">
@(fireEquipment.ARnGWP != null ? (Model.ARversion == "AR4" ? fireEquipment.ARnGWP.AR4GWP100.ToString()
: Model.ARversion == "AR5" ? fireEquipment.ARnGWP.AR5GWP100.ToString()
: Model.ARversion == "AR6" ? fireEquipment.ARnGWP.AR6GWP100.ToString() : "0" ) : "0"))
</td>
<td align="right">@fireEquipment.KgCO2e.ToString("F4")</td>
<td>
@if (fireEquipment.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/nonYearly/@fireEquipment.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
</table>
</div>
<div>
<h4 id="refrigerant" class="docs-inline">@Resource.RefrigerantEquipment</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=Refrigerant" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.FactoryAndProcessItems</th>
@*<th>@Resource.ResponsibleUnit</th>*@
<th>@Resource.DeviceName</th>
<th>@Resource.MaterialType</th>
<th>@Resource.UnitsNumberOfWholeFactory</th>
<th>@(Resource.OriginalFillingAmountOfRefrigerant)(kg)</th>
<th>@Resource.UsedMonth</th>
<th>@Resource.TypeOfRefrigerant</th>
<th>GWP</th>
<th>@Resource.DeviceTypeAndEmissionFactor</th>
<th>@Resource.EmitPara</th>
<th>KgCO2e</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@if (Model.RefrigerantSheet.Count() == 0)
{
<tr>
<td class="text-center" colspan="10">@Resource.NoData</td>
</tr>
}
@foreach (var refrigerant in Model.RefrigerantSheet)
{
<tr>
<td>@refrigerant.ProcessName</td>
@*<td>@refrigerant.ResponsibleUnit</td>*@
<td>@refrigerant.Name</td>
<td>@refrigerant.ModelNumber</td>
<td align="right">@refrigerant.TotalNumber</td>
<td align="right">@refrigerant.Scalar.ToString("F4")</td>
<td align="right">@refrigerant.UsedMonth</td>
<td>
@(refrigerant.ARnGWP != null ? refrigerant.ARnGWP.ingredientName : "")
</td>
<td align="right">
@(refrigerant.ARnGWP != null ? (Model.ARversion == "AR4" ? refrigerant.ARnGWP.AR4GWP100.ToString()
: Model.ARversion == "AR5" ? refrigerant.ARnGWP.AR5GWP100.ToString()
: Model.ARversion == "AR6" ? refrigerant.ARnGWP.AR6GWP100.ToString() : "0" ) : "0"))
</td>
<td>
@(refrigerant.Factor != null && refrigerant.Factor.Type != null ? refrigerant.Factor.Type.DisplayName : "")
</td>
<td align="right">@refrigerant.Factor.Value</td>
<td align="right">@refrigerant.KgCO2e.ToString("F4")</td>
<td>
@if (refrigerant.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/nonYearly/@refrigerant.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
</table>
</div>
<div>
<h4 id="steam-usage" class="docs-inline">@Resource.SteamUsage</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=SteamUsage" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.StaticLabelGlobal_Month</th>
<th>@(Resource.UsageAmount)(Kg)</th>
<th>@Resource.StaticLabelGlobal_Years</th>
<th>KgCO2e</th>
<th>@Resource.EvidenceEBooks</th>
<th>@Resource.SimaproParametersRemark</th>
</tr>
@foreach (var steam in Model.SteamUsageSheet)
{
<tr>
<td align="right">@steam.MonthLabel()</td>
<td align="right">@steam.Scalar.ToString("F4")</td>
<td align="right">
@(steam.Parameter != null ? steam.Parameter.Year.ToString() : "")
</td>
<td align="right">@steam.KgCO2e</td>
<td>
@if (!string.IsNullOrEmpty(steam.ReferenceFileLink))
{<a href="@steam.ReferenceFileLink">@Resource.StaticLabelDownload</a>}
</td>
<td>
@if (steam.ParameterID.HasValue)
{
<a class="iframe" href="~/Certification/Parameter/yearly/@steam.ParameterID.Value" data-fancybox-type="iframe">@Resource.StaticLabelGlobal_CheckOut</a>
}
</td>
</tr>
}
<tr align="right">
<td>@Resource.Total</td>
<td>@Model.SteamUsageSheet.ToList().GetTotalSteamUsage().ToString("F4")</td>
<td></td>
<td>@Model.SteamUsageSheet.ToList().GetTotalKgCO2e().ToString("F4")</td>
<td></td>
<td></td>
</tr>
</table>
</div>
<div>
<h4 id="other-compound" class="docs-inline">@Resource.OtherCompound</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=OtherCompound" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>
<th>@Resource.DeviceName</th>
<th>@Resource.EmissionSources</th>
<th>@Resource.CO2Factor</th>
<th>@Resource.UsageAmount</th>
<th>@Resource.RefuelingRecord</th>
<th>@Resource.StaticLabelGlobal_Remark</th>
<th>@Resource.KgCO2e (KgCO2e)</th>
</tr>
@foreach (var other in Model.OtherCompound)
{
<tr>
<td>@other.ProcessName</td>
<td>@other.ResponsibleUnit</td>
<td>@other.Name</td>
<td>@other.ingredientName</td>
<td align="right">@other.CO2Factor</td>
<td align="right">@other.Scalar.ToString("F4")</td>
<td>
@if (!string.IsNullOrEmpty(other.ReferenceFileUrl))
{<a href="@other.ReferenceFileUrl">@Resource.StaticLabelDownload</a>}
</td>
<td>@other.Description</td>
<td align="right">@other.KgCO2e.ToString("F4")</td>
</tr>
}
@if (Model.OtherCompound.Count() == 0)
{
<tr>
<td class="text-center" colspan="9">@Resource.NoData</td>
</tr>
}
</table>
</div>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
<div class="pull-right docs-btn-group">
<input id="confirm-button2" type="button" value="@Resource.Approve" class="header-button" />
@using (Html.BeginForm("OrganizationLcaConfirm", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-confirm2", @class = "docs-inline" })) { }
<input id="reject-button2" type="button" value="@Resource.Reject" class="header-button" />
@using (Html.BeginForm("OrganizationLcaReject", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-reject2", @class = "docs-inline" })) { }
<button class="header-button" id="upload-button" onclick="showModel()">@Resource.StaticLabelGlobal_Upload</button>
</div>
}
@if (Model.Status == Weee.Models.LCAStatus.Processing)
{
<div class="pull-right docs-btn-group">
<input id="refuse-button2" type="button" value="@Resource.Refuse" class="header-button" />
@using (Html.BeginForm("OrganizationLcaRefuse", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-refuse2", @class = "docs-inline" })) { }
</div>
}
<div class="pull-right docs-btn-group">
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
</div>
</div>
</div>
</div>
@using (Html.BeginForm("OrganizationLcaUploadFile", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { enctype = "multipart/form-data" }))
{
<div class="table_edit_wrap transition show_table_edit" id="file-upload" style="display: none; width: 100%; height: calc(100vh + 150px); background-color: rgb(128,128,128, 0.6); position: fixed; z-index: 1001;margin-top: -150px">
<div>
<div class="edit_form" style="z-index: 1001; position: fixed; margin: auto; left: 0; right: 0; top: 30%; background-color: #eeeeee; width: 500px; border: 1px solid #bbb; border-radius: 5px; padding-bottom: 20px; box-shadow: 1px 1px 1px 1px #ddd; height: 140px;">
<div style="float:right;margin: 10px 10px;cursor: pointer;" onclick="cancel()">
<img src="~/Browser_Local/img/header_image7_1.png" alt="close" />
</div>
<div id="upload-file-result-msg" style="padding: 20px 0 10px 10px;">上传文件:</div>
<div style="margin-left: 30px;">
<input id="fileUpload" type="file" name="uploadedFile" />
<input type="submit" value="@Resource.StaticLabelImport" class="btn btn-default" />
</div>
<p style="color:red;margin-top: 0;margin-left:28px;">仅支持的文件类型zip</p>
</div>
</div>
</div>
}
</div>
</html>
<script>
function cancel() {
let box = document.getElementById('file-upload');
box.style.display = 'none';
}
</script>
@Scripts.Render("~/jQuery")
@Scripts.Render("~/bootstrap")
<script>
function showModel() {
var model = document.getElementById("file-upload");
model.style.display = "block";
}
</script>

View File

@ -0,0 +1,291 @@
@*
the Comment.Category is defined in ProductLCADetail.cshtml
used by Normal company and Certificate company
possible value of Category:
LCI_Direct_Material,
LCI_Indirect_Material,
LCI_Wrap_Material,
WorkHour,
PowerUsage,
WaterUsage,
Waste_Water,
Waste_Other,
Transport,
WasteTransport,
Vehicle,
GasolineEquipment,
Kitchen_Company,
Kitchen_Outsourcing,
Kitchen_Other,
Refrigerant,
FireEquipment,
SteamUsage,
OtherCompound
*@
@using Resources
@using Weee.Models.ExtensionMethods
@using Weee.Areas.Certification.Supports
@using Weee.Models
@model Weee.Models.OrganizationLCA
@{
ViewBag.Title = Resource.StaticLabelOrganizationLCA;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
var stageOptions = ViewData["StageOptions"] as Dictionary<int, string>;
}
@section PageStyles {
@Styles.Render("~/fancybox/css")
}
@section PageScripts {
@Scripts.Render("~/fancybox")
@Scripts.Render("~/sticky")
@Scripts.Render("~/certification/lca/detail")
}
@*<div class="side-bar-top-empty"></div>*@
@*<div class="side-bar col-xs-2 js-scrollspy">*@
<html style="scroll-behavior: smooth;">
<div class="container-fluid">
<div class="panel row">
<div class="col-md-2 org-split-left side-bar js-scrollspy">
<ul id="docs-scroll-hash-nav" class="navbar-nav nav-pills">
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#lca-detail">@Resource.BasicInfo</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#total-workhour">@Resource.TotalWorkHours</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#power-usage">@Resource.PowerUsage</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#vehicle">@Resource.ParamemterCategoriesVehicle</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#gasoline">@Resource.DieselEquipment</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#kitchen-owned">@Resource.Kitchen</a></li>
<li class="nav-item" style="display:none"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#kitchen-outsourcing">@Resource.Kitchen (@Resource.Outsourcing)</a></li>
<li class="nav-item" style="display:none"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#kitchen-other">@Resource.Kitchen (@Resource.Other)</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#fire-equipment">@Resource.FireEquipment</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#refrigerant">@Resource.ContainsRefrigerant</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#steam-usage">@Resource.SteamUsage</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#other-compound">@Resource.OtherCompound</a></li>
<li class="nav-item"><a class="active nav-link" href="#lifecycle-assmt">@Resource.LifecycleStageAssessment</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetailSignificance","LCA", new { id = Model.ID })">@Resource.RASignificance</a></li>
</ul>
</div>
<div id="docs-scroll-hash-content" class="col-md-10 org-split-right" style="margin-left: auto">
@*<div id="docs-scroll-hash-content" class="col-xs-10 panel panel-default">*@
<div id="lca-detail" class="docs-lca-detail">
<div class="row">
<div class="col-md-4">
<label>@(Resource.Starter): </label>
<span>@Model.LCAStarter</span>
</div>
<div class="col-md-4">
<label>@(Resource.PhoneNumber): </label>
<span>@Model.LCAStarterPhone</span>
</div>
<div class="col-md-4">
<label>@(Resource.LCAStartDate): </label>
<span>@Model.StartDate.ToShortDateString()</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
<label>@(Resource.Job): </label>
<span>@Model.LCAStarterJob</span>
</div>
<div class="col-md-4">
<label>@(Resource.Department): </label>
<span>@Model.LCAStarterDepartment</span>
</div>
<div class="col-md-4">
<label>@(Resource.LCAEndDate): </label>
<span>@Model.EndDate.ToShortDateString()</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
@*<label>@Resource.InterrogationResultReport @Resource.StaticLabelGlobal_And @Resource.CarbonFootprintReport: </label>
@if (ViewData["templates"] != null)
{
<span><a href="@ViewData["templates"]">@Resource.DownloadLink</a></span>
}*@
@*<span><a href="@ViewData["UploadZipReply"]">@Resource.UploadZipReply</a></span>*@
<span><a href="@ViewData["DownloadZipReport"]">@Resource.ZipReport</a></span>
@*<label>@(Resource.InterrogationResultReport): </label>
@if (Model.InterrogationResultUrl != null && Model.InterrogationResultUrl != "")
{
//Start CFT-6
if (Model.InterrogationResultUrl.Contains("Browser_Local"))
{
<span><a href="@Model.InterrogationResultUrl.Substring(Model.InterrogationResultUrl.IndexOf("Browser_Local") - 1)">@Resource.DownloadLink</a></span>
}
else
{
<span><a href="@Model.InterrogationResultUrl">@Resource.DownloadLink</a></span>
}
<!--<span><a href="@Model.InterrogationResultUrl">@Resource.DownloadLink</a></span>-->
//End CFT-6
}
*@
</div>
<div class="col-md-4">
@*<label>@(Resource.CarbonFootprintReport): </label>
@if (Model.CarbonFootprintDocxUrl != null && Model.CarbonFootprintDocxUrl != "")
{
//Start CFT-6
if (Model.CarbonFootprintDocxUrl.Contains("Browser_Local"))
{
<span><a href="@Model.CarbonFootprintDocxUrl.Substring(Model.CarbonFootprintDocxUrl.IndexOf("Browser_Local")-1)">@Resource.DownloadLink</a></span>
}
else
{
<span><a href="@Model.CarbonFootprintDocxUrl">@Resource.DownloadLink</a></span>
}
<!--<span><a href="@Model.CarbonFootprintDocxUrl">@Resource.DownloadLink</a></span>-->
//End CFT -6
}*@
</div>
<div class="col-md-4"></div>
</div>
</div>
<div class="message">
@TempData["successMsg"]
@TempData["errorMsg"]
</div>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
<div class="pull-right docs-btn-group">
<input id="confirm-button" type="button" value="@Resource.Approve" class="header-button" />
@using (Html.BeginForm("OrganizationLcaConfirm", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-confirm", @class = "docs-inline" })) { }
<input id="reject-button" type="button" value="@Resource.Reject" class="header-button" />
@using (Html.BeginForm("OrganizationLcaReject", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-reject", @class = "docs-inline" })) { }
<button class="header-button" id="upload-button" onclick="showModel()">@Resource.StaticLabelGlobal_Upload</button>
</div>
}
@if (Model.Status == Weee.Models.LCAStatus.Processing)
{
<div class="pull-right docs-btn-group">
<input id="refuse-button" type="button" value="@Resource.Refuse" class="header-button" />
@using (Html.BeginForm("OrganizationLcaRefuse", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-refuse", @class = "docs-inline" })) { }
</div>
}
<div>
<div>
<h4 id="lifecycle-assmt" class="docs-inline">@Resource.LifecycleStageAssessment</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=RASignificance" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.LifecycleStage</th>
<th>@Resource.CategorySubItem</th>
<th>@Resource.EvaluationItem</th>
<th>@Resource.MaterialNo</th>
<th>@Resource.ActivityStrength</th>
<th>@Resource.Parameter (kgCO2e)</th>
<th>@Resource.DeclareUnit</th>
<th>@Resource.CarbonEmitQuan (@Resource.Ton)</th>
<th>@Resource.Percentage</th>
<th>@Resource.ParaDesc</th>
<th>@Resource.UncertaintyAnalysis</th>
</tr>
@foreach (var lifecycleAssmt in Model.LifecycleAssmt.OrderBy(x => x.LifeCycleStage))
{
<tr>
<td>@stageOptions[lifecycleAssmt.LifeCycleStage]</td>
<td>@lifecycleAssmt.categorySubItem</td>
<td>@lifecycleAssmt.GHGEvaluateItem</td>
<td>@lifecycleAssmt.MaterialNo</td>
<td align="right">@lifecycleAssmt.ActivityIntensity.ToString("F4")</td>
<td align="right">@lifecycleAssmt.KgCO2e.ToString("F10")</td>
<td align="right">@lifecycleAssmt.Unit</td>
<td align="right">@lifecycleAssmt.EmissionT.ToString("F4")</td>
<td align="right">@lifecycleAssmt.Percentage</td>
<td>@lifecycleAssmt.Instruction</td>
<td>@lifecycleAssmt.UncertaintyAnalysis</td>
</tr>
}
@if (Model.LifecycleAssmt.Count() == 0)
{
<tr>
<td class="text-center" colspan="11">@Resource.NoData</td>
</tr>
}
</table>
</div>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
<div class="pull-right docs-btn-group">
<input id="confirm-button2" type="button" value="@Resource.Approve" class="header-button" />
@using (Html.BeginForm("OrganizationLcaConfirm", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-confirm2", @class = "docs-inline" })) { }
<input id="reject-button2" type="button" value="@Resource.Reject" class="header-button" />
@using (Html.BeginForm("OrganizationLcaReject", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-reject2", @class = "docs-inline" })) { }
<button class="header-button" id="upload-button" onclick="showModel()">@Resource.StaticLabelGlobal_Upload</button>
</div>
}
@if (Model.Status == Weee.Models.LCAStatus.Processing)
{
<div class="pull-right docs-btn-group">
<input id="refuse-button2" type="button" value="@Resource.Refuse" class="header-button" />
@using (Html.BeginForm("OrganizationLcaRefuse", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-refuse2", @class = "docs-inline" })) { }
</div>
}
<div class="pull-right docs-btn-group">
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
</div>
</div>
</div>
</div>
@using (Html.BeginForm("OrganizationLcaUploadFile", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { enctype = "multipart/form-data" }))
{
<div class="table_edit_wrap transition show_table_edit" id="file-upload" style="display: none; width: 100%; height: calc(100vh + 150px); background-color: rgb(128,128,128, 0.6); position: fixed; z-index: 1001;margin-top: -150px">
<div>
<div class="edit_form" style="z-index: 1001; position: fixed; margin: auto; left: 0; right: 0; top: 30%; background-color: #eeeeee; width: 500px; border: 1px solid #bbb; border-radius: 5px; padding-bottom: 20px; box-shadow: 1px 1px 1px 1px #ddd; height: 140px;">
<div style="float:right;margin: 10px 10px;cursor: pointer;" onclick="cancel()">
<img src="~/Browser_Local/img/header_image7_1.png" alt="close" />
</div>
<div id="upload-file-result-msg" style="padding: 20px 0 10px 10px;">上传文件:</div>
<div style="margin-left: 30px;">
<input id="fileUpload" type="file" name="uploadedFile" />
<input type="submit" value="@Resource.StaticLabelImport" class="btn btn-default" />
</div>
<p style="color:red;margin-top: 0;margin-left:28px;">仅支持的文件类型zip</p>
</div>
</div>
</div>
}
</div>
</html>
<script>
function cancel() {
let box = document.getElementById('file-upload');
box.style.display = 'none';
}
</script>
@Scripts.Render("~/jQuery")
@Scripts.Render("~/bootstrap")
<script>
function showModel() {
var model = document.getElementById("file-upload");
model.style.display = "block";
}
</script>

View File

@ -0,0 +1,296 @@
@*
the Comment.Category is defined in ProductLCADetail.cshtml
used by Normal company and Certificate company
possible value of Category:
LCI_Direct_Material,
LCI_Indirect_Material,
LCI_Wrap_Material,
WorkHour,
PowerUsage,
WaterUsage,
Waste_Water,
Waste_Other,
Transport,
WasteTransport,
Vehicle,
GasolineEquipment,
Kitchen_Company,
Kitchen_Outsourcing,
Kitchen_Other,
Refrigerant,
FireEquipment,
SteamUsage,
OtherCompound
*@
@using Resources
@using Weee.Models.ExtensionMethods
@using Weee.Areas.Certification.Supports
@using Weee.Models
@using Weee.ViewModels.Lca.LCARiskAssmtSurveyForm
@model OrganizationLCA
@{
ViewBag.Title = Resource.StaticLabelOrganizationLCA;
Layout = "~/Areas/Certification/Views/Shared/_CertificationLayout.cshtml";
var assmtFactors = ViewData["AssmtFactors"] as Dictionary<int, string>;
var gradingScore = ViewData["GradingScore"];
var significanceAssmt = ViewData["significanceAssmt"] as List<LCARiskAssmtSurveyForm_SignificanceAssmtQuery>;
var stageOptions = ViewData["StageOptions"] as Dictionary<int, string>;
}
@section PageStyles {
@Styles.Render("~/fancybox/css")
}
@section PageScripts {
@Scripts.Render("~/fancybox")
@Scripts.Render("~/sticky")
@Scripts.Render("~/certification/lca/detail")
}
@*<div class="side-bar-top-empty"></div>*@
@*<div class="side-bar col-xs-2 js-scrollspy">*@
<html style="scroll-behavior: smooth;">
<div class="container-fluid">
<div class="panel row">
<div class="col-md-2 org-split-left side-bar js-scrollspy">
<ul id="docs-scroll-hash-nav" class="navbar-nav nav-pills">
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#lca-detail">@Resource.BasicInfo</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#total-workhour">@Resource.TotalWorkHours</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#power-usage">@Resource.PowerUsage</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#vehicle">@Resource.ParamemterCategoriesVehicle</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#gasoline">@Resource.DieselEquipment</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#kitchen-owned">@Resource.Kitchen</a></li>
<li class="nav-item" style="display:none"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#kitchen-outsourcing">@Resource.Kitchen (@Resource.Outsourcing)</a></li>
<li class="nav-item" style="display:none"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#kitchen-other">@Resource.Kitchen (@Resource.Other)</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#fire-equipment">@Resource.FireEquipment</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#refrigerant">@Resource.ContainsRefrigerant</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#steam-usage">@Resource.SteamUsage</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetail","LCA", new { id = Model.ID })#other-compound">@Resource.OtherCompound</a></li>
<li class="nav-item"><a class="nav-link" href="@Url.Action("OrganizationLcaDetailLifecycleAssmt","LCA", new { id = Model.ID })">@Resource.LifecycleStageAssessment</a></li>
<li class="nav-item"><a class="active nav-link" href="#significance">@Resource.RASignificance</a></li>
</ul>
</div>
<div id="docs-scroll-hash-content" class="col-md-10 org-split-right" style="margin-left: auto">
@*<div id="docs-scroll-hash-content" class="col-xs-10 panel panel-default">*@
<div id="lca-detail" class="docs-lca-detail">
<div class="row">
<div class="col-md-4">
<label>@(Resource.Starter): </label>
<span>@Model.LCAStarter</span>
</div>
<div class="col-md-4">
<label>@(Resource.PhoneNumber): </label>
<span>@Model.LCAStarterPhone</span>
</div>
<div class="col-md-4">
<label>@(Resource.LCAStartDate): </label>
<span>@Model.StartDate.ToShortDateString()</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
<label>@(Resource.Job): </label>
<span>@Model.LCAStarterJob</span>
</div>
<div class="col-md-4">
<label>@(Resource.Department): </label>
<span>@Model.LCAStarterDepartment</span>
</div>
<div class="col-md-4">
<label>@(Resource.LCAEndDate): </label>
<span>@Model.EndDate.ToShortDateString()</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
@*<label>@Resource.InterrogationResultReport @Resource.StaticLabelGlobal_And @Resource.CarbonFootprintReport: </label>
@if (ViewData["templates"] != null)
{
<span><a href="@ViewData["templates"]">@Resource.DownloadLink</a></span>
}*@
@*<span><a href="@ViewData["UploadZipReply"]">@Resource.UploadZipReply</a></span>*@
<span><a href="@ViewData["DownloadZipReport"]">@Resource.ZipReport</a></span>
@*<label>@(Resource.InterrogationResultReport): </label>
@if (Model.InterrogationResultUrl != null && Model.InterrogationResultUrl != "")
{
//Start CFT-6
if (Model.InterrogationResultUrl.Contains("Browser_Local"))
{
<span><a href="@Model.InterrogationResultUrl.Substring(Model.InterrogationResultUrl.IndexOf("Browser_Local") - 1)">@Resource.DownloadLink</a></span>
}
else
{
<span><a href="@Model.InterrogationResultUrl">@Resource.DownloadLink</a></span>
}
<!--<span><a href="@Model.InterrogationResultUrl">@Resource.DownloadLink</a></span>-->
//End CFT-6
}
*@
</div>
<div class="col-md-4">
@*<label>@(Resource.CarbonFootprintReport): </label>
@if (Model.CarbonFootprintDocxUrl != null && Model.CarbonFootprintDocxUrl != "")
{
//Start CFT-6
if (Model.CarbonFootprintDocxUrl.Contains("Browser_Local"))
{
<span><a href="@Model.CarbonFootprintDocxUrl.Substring(Model.CarbonFootprintDocxUrl.IndexOf("Browser_Local")-1)">@Resource.DownloadLink</a></span>
}
else
{
<span><a href="@Model.CarbonFootprintDocxUrl">@Resource.DownloadLink</a></span>
}
<!--<span><a href="@Model.CarbonFootprintDocxUrl">@Resource.DownloadLink</a></span>-->
//End CFT -6
}*@
</div>
<div class="col-md-4"></div>
</div>
</div>
<div class="message">
@TempData["successMsg"]
@TempData["errorMsg"]
</div>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
<div class="pull-right docs-btn-group">
<input id="confirm-button" type="button" value="@Resource.Approve" class="header-button" />
@using (Html.BeginForm("OrganizationLcaConfirm", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-confirm", @class = "docs-inline" })) { }
<input id="reject-button" type="button" value="@Resource.Reject" class="header-button" />
@using (Html.BeginForm("OrganizationLcaReject", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-reject", @class = "docs-inline" })) { }
<button class="header-button" id="upload-button" onclick="showModel()">@Resource.StaticLabelGlobal_Upload</button>
</div>
}
@if (Model.Status == Weee.Models.LCAStatus.Processing)
{
<div class="pull-right docs-btn-group">
<input id="refuse-button" type="button" value="@Resource.Refuse" class="header-button" />
@using (Html.BeginForm("OrganizationLcaRefuse", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-refuse", @class = "docs-inline" })) { }
</div>
}
<div style="float: right;">
<label for="areaSelect">@Resource.AssmtScore : </label>
<input style="width: 100px;"
type="number" step="any" disabled
value="@gradingScore" />
@*<button class="header_button"
style="line-height: 22px; padding-bottom: 0px;"
ng-click="updateGradingScore()">
@Resource.StaticLabelGlobal_Save
</button>*@
</div>
<div>
<div>
<h4 id="significance" class="docs-inline">@Resource.RASignificance</h4>
<a class="iframe pull-right" href="~/Certification/Comment?lcaId=@(Model.ID)&category=RASignificance" data-fancybox-type="iframe">@Resource.Comment</a>
<table class="table docs-table">
<tr class="certification_table_header">
<th>@Resource.LifecycleStage</th>
<th>@Resource.Category</th>
<th>@Resource.WarmGasItem</th>
<th>@Resource.EmitPercentage (%)</th>
<th>@Resource.TotalScore</th>
<th>@Resource.Significance>=@gradingScore@Resource.Points</th>
</tr>
@foreach (var row in significanceAssmt)
{
<tr>
<td>@stageOptions[row.LifeCycleStage]</td>
<td>@("category" + row.Category)</td>
<td>@row.GHGEvaluateItem</td>
<td align="right">@row.emitPercentage</td>
<td align="right">@row.Score</td>
<td>@(row.Significance == 0 ? "non-significant" : "significant")</td>
</tr>
}
@if (significanceAssmt.Count() == 0)
{
<tr>
<td class="text-center" colspan="6">@Resource.NoData</td>
</tr>
}
</table>
</div>
@if (Model.Status == Weee.Models.LCAStatus.Waiting)
{
<div class="pull-right docs-btn-group">
<input id="confirm-button2" type="button" value="@Resource.Approve" class="header-button" />
@using (Html.BeginForm("OrganizationLcaConfirm", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-confirm2", @class = "docs-inline" })) { }
<input id="reject-button2" type="button" value="@Resource.Reject" class="header-button" />
@using (Html.BeginForm("OrganizationLcaReject", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-reject2", @class = "docs-inline" })) { }
<button class="header-button" id="upload-button" onclick="showModel()">@Resource.StaticLabelGlobal_Upload</button>
</div>
}
@if (Model.Status == Weee.Models.LCAStatus.Processing)
{
<div class="pull-right docs-btn-group">
<input id="refuse-button2" type="button" value="@Resource.Refuse" class="header-button" />
@using (Html.BeginForm("OrganizationLcaRefuse", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { @id = "lca-refuse2", @class = "docs-inline" })) { }
</div>
}
<div class="pull-right docs-btn-group">
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
<div class="row">
<div class="col-lg-12">&nbsp;</div>
</div>
</div>
</div>
</div>
</div>
@using (Html.BeginForm("OrganizationLcaUploadFile", "LCA", new { lcaId = Model.ID }, FormMethod.Post, new { enctype = "multipart/form-data" }))
{
<div class="table_edit_wrap transition show_table_edit" id="file-upload" style="display: none; width: 100%; height: calc(100vh + 150px); background-color: rgb(128,128,128, 0.6); position: fixed; z-index: 1001;margin-top: -150px">
<div>
<div class="edit_form" style="z-index: 1001; position: fixed; margin: auto; left: 0; right: 0; top: 30%; background-color: #eeeeee; width: 500px; border: 1px solid #bbb; border-radius: 5px; padding-bottom: 20px; box-shadow: 1px 1px 1px 1px #ddd; height: 140px;">
<div style="float:right;margin: 10px 10px;cursor: pointer;" onclick="cancel()">
<img src="~/Browser_Local/img/header_image7_1.png" alt="close" />
</div>
<div id="upload-file-result-msg" style="padding: 20px 0 10px 10px;">上传文件:</div>
<div style="margin-left: 30px;">
<input id="fileUpload" type="file" name="uploadedFile" />
<input type="submit" value="@Resource.StaticLabelImport" class="btn btn-default" />
</div>
<p style="color:red;margin-top: 0;margin-left:28px;">仅支持的文件类型zip</p>
</div>
</div>
</div>
}
</div>
</html>
<script>
function cancel() {
let box = document.getElementById('file-upload');
box.style.display = 'none';
}
</script>
@Scripts.Render("~/jQuery")
@Scripts.Render("~/bootstrap")
<script>
function showModel() {
var model = document.getElementById("file-upload");
model.style.display = "block";
}
</script>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,19 @@
@using Resources
@model Weee.Models.Paramemter.NonYearlyParameter
@{
Layout = null;
}
@Styles.Render("~/bootstrap/css")
@Styles.Render("~/certification/css")
<div class="container">
<div>
<h2 class="text-center">@Resource.StaticLabelGlobal_Remark</h2>
</div>
<div>
<p class="docs-p-md">@Model.Description</p>
</div>
</div>

View File

@ -0,0 +1,17 @@
@using Resources
@{
Layout = null;
}
@Styles.Render("~/bootstrap/css")
@Styles.Render("~/certification/css")
<div class="container">
<div>
<h2 class="text-center">@Resource.StaticLabelGlobal_Remark</h2>
</div>
<div>
<p class="docs-p-md">@ViewBag.Remark</p>
</div>
</div>

View File

@ -0,0 +1,19 @@
@using Resources
@model Weee.Models.Paramemter.YearlyParameter
@{
Layout = null;
}
@Styles.Render("~/bootstrap/css")
@Styles.Render("~/certification/css")
<div class="container">
<div>
<h2 class="text-center">@Resource.StaticLabelGlobal_Remark</h2>
</div>
<div>
<p class="docs-p-md">@Model.Description</p>
</div>
</div>

View File

@ -0,0 +1,55 @@
@using Resources
@{
var controller = ViewContext.RouteData.Values["controller"].ToString();
}
@helper actived(string c, string controller)
{
var Clist = c.ToLowerInvariant().Split(',').ToList();
if (Clist.Contains(controller.ToLowerInvariant()))
{
@:active
}
}
<nav class="navbar navbar-light nav_body">
<div class="survey_form_logo">
@if (string.IsNullOrEmpty(ViewBag.customLoginImg))
{
<img src="~/Browser_Local/img/carbon_Logo.svg"
style="border-style: none; border: none; outline: none;" />
}
</div>
<div>
<div>
<div class="home_user_login">
<a href="~/account/logout" style="color: #000">@Resource.StaticLabelGlobal_Logout</a>
</div>
<div class="home_culture_select">
<div class="dropdown">
<a href="#" class="dropdown-toggle" role="button" id="dropdownMenuLink" data-toggle="dropdown" aria-expanded="false">
@Resource.StaticLabelCulture
</a>
<ul id="setculture" class="dropdown-menu" aria-labelledby="dropdownMenuLink">
<li class="dropdown-item">繁體中文<input type="hidden" value="zh-tw" /></li>
<li class="dropdown-item">簡體中文<input type="hidden" value="zh-cn" /></li>
<li class="dropdown-item">English<input type="hidden" value="en-us" /></li>
</ul>
</div>
</div>
<div class="home_culture_select">
<div class="dropdown @actived("PublicReferenceFile, PublicMessage, account", controller)">
<a href="#" class="dropdown-toggle" role="button" id="dropdownMenuLink" data-toggle="dropdown" aria-expanded="false">
@Resource.LCAStatus<span class="caret"></span>
</a>
<ul class="dropdown-menu" aria-labelledby="dropdownMenuLink">
<li class="dropdown-item">@Html.ActionLink(Resource.LCAStatusNew, "LCAStatusNew", "Home", new { Area = "Certification" }, new { })</li>
<li class="dropdown-item">@Html.ActionLink(Resource.LCAStatusProcessing, "LCAStatusProcessing", "Home", new { Area = "Certification" }, new { })</li>
<li class="dropdown-item">@Html.ActionLink(Resource.LCAStatusWaiting, "Index", "Home", new { Area = "Certification" }, new { })</li>
<li class="dropdown-item">@Html.ActionLink(Resource.LCAStatusRejected, "LCAStatusRejected", "Home", new { Area = "Certification" }, new { })</li>
<li class="dropdown-item">@Html.ActionLink(Resource.LCAStatusConfirmed, "LCAStatusConfirmed", "Home", new { Area = "Certification" }, new { })</li>
<li class="dropdown-item">@Html.ActionLink(Resource.LCAStatusCompleted, "LCAStatusCompleted", "Home", new { Area = "Certification" }, new { })</li>
</ul>
</div>
</div>
</div>
</div>
</nav>

View File

@ -0,0 +1,45 @@
@using Resources
@{
var controller = ViewContext.RouteData.Values["controller"].ToString();
}
@helper actived(string c, string controller)
{
var Clist = c.ToLowerInvariant().Split(',').ToList();
if (Clist.Contains(controller.ToLowerInvariant()))
{
@:active
}
}
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width" />
<meta http-equiv="cache-control" content="max-age=0" />
<meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate" />
<title>@ViewBag.Title - @Resource.StaticLabelCertificationCompany</title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
@RenderSection("PageStyles", required: false)
@Scripts.Render("~/jQuery")
@*@Styles.Render("~/bootstrap/css")*@
@Styles.Render("~/certification/css")
</head>
<body role="document" data-spy="scroll" data-target=".js-scrollspy" data-offset="35"
class="docs-body">
<header class="navbar-fixed-top docs-header">
@RenderPage("~/Areas/Certification/Views/Shared/_CertificationHeader.cshtml")
</header>
<div>
@*<div class="container docs-container">*@
@RenderBody()
</div>
@Scripts.Render("~/bootstrap")
@Scripts.Render("~/setCulture")
@Scripts.Render("~/papaParse")
@RenderSection("PageScripts", required: false)
<script src="https://code.jquery.com/jquery-3.3.1.min.js" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" crossorigin="anonymous"></script>
</body>
</html>

View File

@ -0,0 +1,44 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="cache-control" content="max-age=0" />
<meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate" />
<title>@ViewBag.Title - My ASP.NET Application</title>
@Styles.Render("~/Content/css")
@Styles.Render("~/Browser_Local/css")
@Scripts.Render("~/bundles/modernizr")
</head>
<body>
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
@Html.ActionLink("Application name", "Index", "Home", new { area = "" }, new { @class = "navbar-brand" })
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
</ul>
</div>
</div>
</div>
<div class="container body-content">
@RenderBody()
<hr />
<footer>
<p>&copy; @DateTime.Now.Year - My ASP.NET Application</p>
</footer>
</div>
@Scripts.Render("~/bundles/jquery")
@Scripts.Render("~/bundles/bootstrap")
@RenderSection("scripts", required: false)
</body>
</html>

View File

@ -0,0 +1,3 @@
@{
Layout = "~/Areas/Certification/Views/Shared/_Layout.cshtml";
}

View File

@ -0,0 +1,36 @@
<?xml version="1.0"?>
<configuration>
<configSections>
<sectionGroup name="system.web.webPages.razor" type="System.Web.WebPages.Razor.Configuration.RazorWebSectionGroup, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="host" type="System.Web.WebPages.Razor.Configuration.HostSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" />
<section name="pages" type="System.Web.WebPages.Razor.Configuration.RazorPagesSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" />
</sectionGroup>
</configSections>
<system.web.webPages.razor>
<host factoryType="System.Web.Mvc.MvcWebRazorHostFactory, System.Web.Mvc, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<pages pageBaseType="System.Web.Mvc.WebViewPage">
<namespaces>
<add namespace="System.Web.Mvc" />
<add namespace="System.Web.Mvc.Ajax" />
<add namespace="System.Web.Mvc.Html" />
<add namespace="System.Web.Routing" />
<add namespace="System.Web.Optimization" />
<add namespace="Weee" />
</namespaces>
</pages>
</system.web.webPages.razor>
<appSettings>
<add key="webpages:Enabled" value="false" />
</appSettings>
<system.webServer>
<handlers>
<remove name="BlockViewHandler"/>
<add name="BlockViewHandler" path="*" verb="*" preCondition="integratedMode" type="System.Web.HttpNotFoundHandler" />
</handlers>
</system.webServer>
</configuration>

View File

@ -0,0 +1,49 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Weee.Controllers;
using Weee.DAL;
using Weee.Service;
using Weee.ViewModels.Lca;
namespace Weee.Areas.Lca.Controllers
{
public class DetailController : QcarbonControllerBase
{
private readonly WeeeParameterDataService parameterservice;
private readonly WeeeSheetDataService service;
//private readonly WeeeDataContext db;
private readonly OtherCompoundService otherCompoundService;
public DetailController(WeeeDataContext _db
, WeeeSheetDataService d
, WeeeParameterDataService s
, OtherCompoundService otherCompoundService)
: base(_db)
{
service = d;
parameterservice = s;
//db = _db;
this.otherCompoundService = otherCompoundService;
}
// GET: Lca/Detail
public ActionResult Index()
{
return View();
}
//[Route("OtherCompound/{LCAID}")]
public ActionResult OtherCompound(string LCAID)
{
LcaOtherCompoundViewModel viewModel;
viewModel = otherCompoundService.GetOrgByLcaId(LCAID);
return View(viewModel);
}
[HttpPost]
public ActionResult OtherCompound(LcaOtherCompoundViewModel viewModel)
{
return View(viewModel);
}
}
}

View File

@ -0,0 +1,45 @@
using Microsoft.AspNet.Identity;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Weee.Controllers;
using Weee.DAL;
using Weee.Models;
using Weee.Service;
using Weee.ViewModels.Lca;
using CScommon;
namespace Weee.Areas.Lca.Controllers
{
public class HomeController : QcarbonControllerBase
{
private UserService userService;
public HomeController(WeeeDataContext d, UserManager<User> m)
: base(d)
{
userService = new UserService(d, m);
}
// GET: Lca/Home
public ActionResult Index()
{
//var qry = (from a in uow.LCArepository.Get()
// select a).AsQueryable();
LcaIndexViewModel viewModel = new LcaIndexViewModel();
var currentId = User.Identity.GetUserId();
var qry = userService.GetByMyCompany(currentId);
string json = JsonUtl.fromT(qry);
viewModel.users =JsonUtl.toT<List<UserViewModel>>(json);
return View(viewModel);
}
[HttpPost]
public ActionResult Index(LcaIndexViewModel viewModel)
{
return View(viewModel);
}
}
}

View File

@ -0,0 +1,42 @@
using CScommon;
using Resources.Helper;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Web;
using System.Web.Mvc;
using Weee.Controllers;
using Weee.DAL;
namespace Weee.Areas.Lca.Controllers
{
[Authorize(Roles = ProgramConstants.normalcompany)]
public class LCAcontrollerBase : QcarbonControllerBase
{
public LCAcontrollerBase(WeeeDataContext db) : base(db)
{
}
protected override IAsyncResult BeginExecuteCore(AsyncCallback callback, object state)
{
string cultureName = null;
// Attempt to read the culture cookie from Request
HttpCookie cultureCookie = Request.Cookies["_culture"];
if (cultureCookie != null)
cultureName = cultureCookie.Value;
else
cultureName = Request.UserLanguages != null && Request.UserLanguages.Length > 0 ? Request.UserLanguages[0] : null; // obtain it from HTTP header AcceptLanguages
// Validate culture name
cultureName = CultureHelper.GetImplementedCulture(cultureName); // This is safe
// Modify current thread's cultures
Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo(cultureName);
Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture;
return base.BeginExecuteCore(callback, state);
}
}
}

View File

@ -0,0 +1,194 @@
using CScommon;
using Microsoft.AspNet.Identity;
using Qcarbon.ViewModels.DTO;
using Resources;
using System;
using System.Collections.Generic;
using System.Data.Entity;
using System.Linq;
using System.Threading;
using System.Web;
using System.Web.Mvc;
using Weee.DAL;
using Weee.Models;
using Weee.Models.ExtensionMethods;
using Weee.Service;
namespace Weee.Areas.Lca.Controllers
{
//[Authorize(Roles = ProgramConstants.normalcompany)]
public class RiskMaterialTransportController : LCAcontrollerBase
{
protected MaterialC3EmissionDataService service;
public RiskMaterialTransportController(WeeeDataContext db)
: base(db)
{
service = new MaterialC3EmissionDataService(db);
}
// GET: Lca/RiskMaterialTransport
//[Route("LCA/RiskMaterialTransport/Index/{LCAID?}")]
//[Route("RiskMaterialTransport/Index/{LCAID?}")]
//[Route("LCA/RiskMaterialTransport/{LCAID}")]
public ActionResult Index(int? LCAID)
{
ViewBag.activeRisk = "materialTransport";
//var v = User.Identity.GetUserAccountType(db);
RiskMaterialListViewModel viewModel = new RiskMaterialListViewModel();
if (LCAID == null)
viewModel.errMsg = "LCAID null!";
if (viewModel.errMsg=="")
{
viewModel.LCAID =(int) LCAID;
ViewBag.LCAID = viewModel.LCAID;
loadMaterialList(viewModel);
}
return View(viewModel);
}
private string loadMaterialList(RiskMaterialListViewModel viewModel)
{
string ret = "";
// get view model from LCAID
var qry = (from a in uow.LCARiskAssmtSurveyFormMaterialC3EmissionRepository.Get()
where a.LCAID ==viewModel.LCAID
select a).AsQueryable();
if (qry == null)
viewModel.errMsg = "No record(s)!";
else
{
if (viewModel.modelList == null)
viewModel.modelList = new List<LCARiskAssmtSurveyForm_MaterialC3Emission>();
foreach (var rec in qry.ToList())
{
//string json = CScommon.JsonUtl.fromT(rec);
//LCARiskAssmtSurveyForm_MaterialC3Emission toAdd =
// CScommon.JsonUtl.toT<LCARiskAssmtSurveyForm_MaterialC3Emission>(json);
viewModel.modelList.Add(rec);// toAdd);
}
}
return ret;
}
private string updateSelectedModel(RiskMaterialListViewModel viewModel)
{
string ret = "";
var qry = (from a in uow.LCARiskAssmtSurveyFormMaterialC3EmissionRepository.Get()
where a.LCAID==viewModel.LCAID && a.MaterialNo==viewModel.selectedID
select a).FirstOrDefault();
viewModel.selectedModel = qry;
return ret;
}
[HttpPost]
public ActionResult Index(RiskMaterialListViewModel viewModel)
{
string err = "";
switch(viewModel.cmd)
{
case "選取":
err = updateSelectedModel(viewModel);
TempData["selectedModel"] = viewModel.selectedModel;
break;
case "btnAdd":
return RedirectToAction("AddUpdate", new { LCAID = viewModel.LCAID });
break;
case "btnEdit":
RiskMaterialViewModel editModel = new RiskMaterialViewModel();
editModel.editing = true;
editModel.LCAID = viewModel.LCAID;
editModel.singleRec =(LCARiskAssmtSurveyForm_MaterialC3Emission) TempData["selectedModel"];// viewModel.selectedModel;
TempData["viewModel"] = editModel;
return RedirectToAction("AddUpdate", new { LCAID = viewModel.LCAID });
break;
case "btnDelete":
break;
default:
break;
}
err = loadMaterialList(viewModel);
return View(viewModel);
}
public ActionResult AddUpdate(int? LCAID)
{
RiskMaterialViewModel viewModel;
if (LCAID == null)
{
viewModel = new RiskMaterialViewModel();
viewModel.errMsg = "LCAID parameter missing!";
return View(viewModel);
}
ViewBag.LCAID = LCAID;
var qry = TempData["viewModel"] as RiskMaterialViewModel;
if (qry != null)//editing
viewModel = qry;
else//adding
{
viewModel = new RiskMaterialViewModel();
viewModel.LCAID = (int)LCAID;
}
return View(viewModel);
}
[HttpPost]
//public ActionResult Add(RiskMaterialViewModel viewModel)
public ActionResult AddUpdate(RiskMaterialViewModel viewModel)
{
verifyAdd(viewModel);
if (!ModelState.IsValid)
return View(viewModel);
viewModel.singleRec.ActivityIntensity = viewModel.singleRec.MaterialSpec
* viewModel.singleRec.AnnualPurchaseAmount;
viewModel.singleRec.Emission = viewModel.singleRec.ActivityIntensity
* viewModel.singleRec.KgCO2e;
switch (viewModel.cmd)
{
case "更新":
break;
case "儲存":
//service.Save(viewModel.singleRec);
LCARiskAssmtSurveyForm_MaterialC3Emission toBeSave = viewModel.singleRec;
toBeSave.LCAID = viewModel.LCAID;
var entry = db.Entry(toBeSave);
if (toBeSave.ID == 0)
{
var qry = (from a in db.LCARiskAssmtSurveyForm_MaterialC3Emissions
where a.LCAID == toBeSave.LCAID && a.ID > 0
&& a.MaterialNo == toBeSave.MaterialNo
select a);
if (qry.Any())
{
ModelState.AddModelError("", $"料號 {toBeSave.MaterialNo} 已存在!");
return View(viewModel);
}
//toBeSave.ID = Guid.NewGuid();
toBeSave.CreatedBy =User.Identity.GetUserId();
toBeSave.CreatedDate = DateTime.Now;
entry.State = EntityState.Added;
}
else
{
toBeSave.ModifiedBy = User.Identity.GetUserId();
toBeSave.ModifiedDate = DateTime.Now;
entry.State = EntityState.Modified;
entry.Property(x => x.LCAID).IsModified = false;
}
db.SaveChanges();
viewModel.successMsg = "新增成功!";
break;
default:
break;
}
return View(viewModel);
}
protected string verifyAdd(RiskMaterialViewModel viewModel)
{
string ret = "";
if (string.IsNullOrWhiteSpace(viewModel.singleRec.MaterialNo))
ModelState.AddModelError("",$"{Resource.MaterialNo} {Resource.HeaderMessageRequire}" );
if (string.IsNullOrWhiteSpace(viewModel.singleRec.MaterialName))
ModelState.AddModelError("", $"{Resource.RAMC3EMaterialName} {Resource.HeaderMessageRequire}");
if (string.IsNullOrWhiteSpace(viewModel.singleRec.Unit))
ModelState.AddModelError("", $"{Resource.RAMC3EMaterialActivityUnit} {Resource.HeaderMessageRequire}");
//!!...檢查料號是否重複
return ret;
}
}
}

View File

@ -0,0 +1,24 @@
using System.Web.Mvc;
namespace Weee.Areas.Lca
{
public class LcaAreaRegistration : AreaRegistration
{
public override string AreaName
{
get
{
return "Lca";
}
}
public override void RegisterArea(AreaRegistrationContext context)
{
context.MapRoute(
"Lca_default",
"Lca/{controller}/{action}/{id}",
new { controller = "home", action = "Index", id = UrlParameter.Optional }
);
}
}
}

View File

@ -0,0 +1,127 @@
@using Resources
@model Weee.ViewModels.Lca.LcaOtherCompoundViewModel
@{
ViewBag.Title = "Index";
Layout = "~/Areas/Lca/Views/Shared/_LcaLayout.cshtml";
}
@*Html.Partial("~/Views/Partial/LCA/DetailLayout.cshtml")*@
<div class="survey_form">
<div class="survey_form_body" style="width: 84%; margin-right: 0;" lca-detail>
@if (true)//todo 暫時隱藏
{
<div class="survey_form_filter" >
<form >
<div class="form-row">
<div class="col">
<input type="text" class="form-control" aria-label="Default" aria-describedby="inputGroup-sizing-default"
ng-model="sheetHeader.SheetFillerName" ng-readonly="!sheetHeaderForm.editable" placeholder="@Resource.StaticLabelFillerName">
</div>
<div class="col">
<input type="text" class="form-control" aria-label="Default" aria-describedby="inputGroup-sizing-default"
ng-model="sheetHeader.Phone" ng-readonly="!sheetHeaderForm.editable" placeholder="@Resource.StaticLabelUserPhoneNumber">
</div>
<div class="col">
<input type="text" class="form-control" aria-label="Default" aria-describedby="inputGroup-sizing-default"
ng-model="sheetHeader.Department" ng-readonly="!sheetHeaderForm.editable" placeholder="@Resource.StaticLabelUserDepartment">
</div>
<div class="survey_order_btn"
ng-click="editSheetHeader()"
ng-show="!sheetHeaderForm.editable">@Resource.UpdateSheetHeader</div>
<div class="survey_order_btn"
ng-click="saveSheetHeader()"
ng-show="sheetHeaderForm.editable">@Resource.StaticLabelGlobal_Save</div>
<div class="survey_order_btn"
ng-click="cancelEditSheetHeader()"
ng-show="sheetHeaderForm.editable">@Resource.StaticLabelGlobal_Cancel</div>
<div class="sheetheader-result-msg">{{ sheetHeaderForm.resultMsg }}</div>
</div>
<div class="form-row" style="margin: 20px 0px; justify-content: flex-end">
@*CFT-89*@
<div class="survey_order_btn"
ng-click="toGenerateReport()"
@*ng-show="lcaDetail.Status == 1"*@
ng-show="true">
@Resource.StartCreateReport
</div>
<div class="survey_order_btn"
ng-click="uploadZipReport(lcaDetail.ID,lcaDetail.isProductLCA)"
ng-show="lcaDetail.Status != 5"
@*ng-show="true"*@>
@Resource.UploadZipReport
</div>
<div class="survey_order_btn"
ng-click="downloadZipReport(lcaDetail.ID)"
ng-show="lcaDetail.Status != 1 && lcaDetail.Status != 2"
@*ng-show="true"*@
>
@Resource.DownloadZipReply
</div>
<div class="survey_order_btn">
lcaDetail.Status:{{lcaDetail.Status}}
</div>
<div class="survey_order_btn"
ng-click="toWaitState()"
@*ng-show="lcaDetail.Status == 1"*@
ng-show="true"
>
@Resource.StaticLabelCompleteLCAAndWaitVerification
</div>
<div class="survey_order_btn"
ng-click="toProcessState()"
ng-show="lcaDetail.Status == 3">
@Resource.StaticLabelModifyData
</div>
<div class="survey_order_btn"
ng-click="toCompleteState()"
ng-show="lcaDetail.Status == 4 && lcaDetail.hasPCR || (lcaDetail.Status == 4 && !lcaDetail.isProductLCA)">
@*CFT-38*@@Resource.StartCreateReport
</div>
</div>
<div style="margin-top: 2px;">
@*<div id="download-generated-report">
<div class="survey_order_btn" ng-show="lcaDetail.Status == 1">
<span><a href="#">@Resource.CarbonFootprintReport@Resource.DownloadLink</a></span>
</div>
</div>*@
</div>
<hr />
</form>
</div>
}
@Html.Partial("~/Areas/lca/Views/Detail/Index/Detail.cshtml")
@*<div ng-include="IncludeTemplate">
</div>*@
</div>
@Html.Partial("~/Areas/lca/Views/Detail/Index/side_bar.cshtml")
@*<side-bar>
</side-bar>*@
</div>
@if (false) // todo 暫時隱藏
{
<table-edit-modal display-option="reportUploadOption" >
<form name="editForm">
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.UploadZipReport</label>
<input class="col col-sm-8" type="file" file read-file="reportUploadOption.selectFile(file)" />
</div>
<div class="row">
<label class="col-sm-4 prompt-msg" style="color: red">
@Resource.ZipFileOnly
</label>
<div class="col" id="upload-file-result-msg"></div>
</div>
<div class="survey_btn_wrap">
<div class="survey_content" style="float: right">
<div class="row">
<button class="header_button" ng-click="uploadZipReportPost()">@Resource.StaticLabelGlobal_Upload</button>
</div>
</div>
</div>
</form>
</table-edit-modal>
}

View File

@ -0,0 +1,237 @@
@using Resources
@*
this view is responsibe for display Product and Organization LCA
*@
<div class="add_survey_body" ng-controller="LCADetailController" lca-detail>
<div class="survey_info">
<div class="title" ng-hide="lcaDetail.isProductLCA">@Resource.StaticLabelLCAInfo</div>
<div class="title" ng-show="lcaDetail.isProductLCA">@Resource.StaticLabelProductLCAInfo</div>
<div class="survey_content">
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.LCAname</label>
<div class="col col-sm-4">
<input type="text" disabled ng-model="lcaDetail.LCAname" />
</div>
</div>
@*End CFT-26*@
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.LCAStartDate</label>
<div class="col">
<input type="text" disabled value="{{ lcaDetail.StartDate | date: 'yyyy/MM/dd' }}" />
</div>
<label class="col-sm-2 col-form-label">@Resource.LCAEndDate</label>
<div class="col">
<input type="text" disabled value="{{ lcaDetail.EndDate | date: 'yyyy/MM/dd' }}" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.Starter</label>
<div class="col">
<input type="text" ng-model="lcaDetail.LCAStarter" name="uCreater" />
</div>
<label class="col-sm-2 col-form-label">@Resource.SurveyJob</label>
<div class="col">
<input type="text" ng-model="lcaDetail.LCAStarterJob" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.Department</label>
<div class="col">
<input type="text" ng-model="lcaDetail.LCAStarterDepartment" />
</div>
<label class="col-sm-2 col-form-label">@Resource.PhoneNumber</label>
<div class="col">
<input type="text" ng-model="lcaDetail.LCAStarterPhone" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.UserEmail</label>
<div class="col">
<input type="email" ng-model="lcaDetail.LCAStarterEmail" />
</div>
</div>
<div class="row" ng-show="lcaDetail.isProductLCA">
<label class="col-sm-2 col-form-label">@Resource.StaticLabelStaffTotalWorkHour</label>
<div class="col">
<input type="number" step="any"
ng-model="lcaDetail.FabProductionHour"
name="FabProductionHour" />
</div>
<label class="col-sm-2 col-form-label">@Resource.StaticLabelProductionTotalWorkHour</label>
<div class="col input-group" style="flex-wrap: nowrap !important">
<input type="number" step="any"
ng-model="lcaDetail.ProductProductionHour"
name="ProductProductionHour" />
<div class="input-group-append">
<span class="unit">hr</span>
</div>
</div>
</div>
<div class="row" ng-show="lcaDetail.isProductLCA">
<label class="col-sm-2 col-form-label">@Resource.ProductLCAFabProductionWeight</label>
<div class="col input-group" style="flex-wrap: nowrap !important">
<input type="number" step="any"
ng-model="lcaDetail.FabProductionWeight" />
<div class="input-group-append">
<span class="unit">kg</span>
</div>
</div>
<label class="col-sm-2 col-form-label">@Resource.ProductLCAFabProductionArea</label>
<div class="col input-group" style="flex-wrap: nowrap !important">
<input type="number" step="any" ng-model="lcaDetail.FabProductionArea" />
<div class="input-group-append">
<span class="unit">m2</span>
</div>
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.StaticLabelCertificationCompany</label>
<div class="col col-sm-4">
<input type="text" ng-disabled="true" ng-model="certificationConpamy.Name" />
</div>
<label ng-show="pcr" class="col-sm-2 col-form-label">PCR</label>
<div ng-show="pcr" class="col">
<input type="text" disabled ng-model="pcr.DisplayName" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.DescriptionAndExplanation</label>
<div class="col">
<textarea class="form-control" rows="3" ng-model="lcaDetail.Description" name="uDescription"></textarea>
</div>
</div>
<div class="survey_content" style="float: right"
ng-show="lcaDetail.Status==1||lcaDetail.Status==0">
<div class="save_LCAInfo_btn" ng-click="updateLCA(lcaDetail.isProductLCA)">
@Resource.StaticLabelGlobal_Save
</div>
<div class="save_LCAInfo_result_msg">{{saveResultMsg}}</div>
</div>
</div>
</div>
<div class="survey_info" ng-show="lcaDetail.isProductLCA">
<div class="title">
@Resource.StaticLabelSubjectProductInfo
</div>
<div class="survey_content">
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.StaticLabelSubjectProductName</label>
<div class="col">
<input type="text" ng-disabled="true"
ng-model="product.Name" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.StaticLabelSubjectProductSerialNumber</label>
<div class="col">
<input type="text" ng-disabled="true"
ng-model="product.SerialNumber" />
</div>
<label class="col-sm-2 col-form-label">@Resource.StaticLabelSubjectProductPcsPerYear</label>
<div class="col input-group" style="flex-wrap: nowrap !important">
<input type="number" step="any"
ng-model="lcaDetail.ProductProductionPcs" />
<div class="input-group-append">
<span class="unit">pcs</span>
</div>
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.StaticLabelSubjectProductWeight</label>
<div class="col input-group" style="flex-wrap: nowrap !important">
<input type="number" step="any" ng-disabled="true"
ng-model="product.Weight" />
<div class="input-group-append">
<span class="unit">kg</span>
</div>
</div>
<label class="col-sm-2 col-form-label">@Resource.StaticLabelSubjectProductAreaSize</label>
<div class="col input-group" style="flex-wrap: nowrap !important">
<input type="number" step="any" ng-disabled="true"
ng-model="product.AreaSize" />
<div class="input-group-append">
<span class="unit">m2</span>
</div>
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.CustomerPartNumber</label>
<div class="col">
<input type="text" disabled ng-model="lcaDetail.CustomerPartNumber" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.StaticLabelSubjectProductSpec</label>
<div class="col">
<input type="text" ng-disabled="true"
ng-model="product.SpecDescription" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.ProductEcoFriendlySymbol</label>
<div class="col">
<input type="text" ng-disabled="true" ng-model="product.EcoFriendlySymbol" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.ProductEcoFriendlyDescription</label>
<div class="col">
<input type="text" ng-disabled="true" ng-model="product.EcoFriendlyDescription" />
</div>
</div>
</div>
</div>
<div class="survey_info">
<div class="title">
@Resource.StaticLabelFabInfo
</div>
<div class="survey_content">
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.FabName</label>
<div class="col col-sm-4">
<input type="text" ng-disabled="true" ng-model="fab.Name" />
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.FabPhone</label>
<div class="col">
<input type="text" ng-disabled="true"
ng-model="fab.Phone" required />
</div>
<label class="col-sm-2 col-form-label">@Resource.IsIso14064Passed</label>
<div class="col">
<select class="form-select"
disabled="disabled"
ng-model="fab.IsIso14064Passed"
ng-options="option.value as option.text for option in isoOptions"></select>
</div>
</div>
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.FabAddress</label>
<div class="col">
<input type="text" ng-disabled="true" ng-model="fab.Address" required />
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,510 @@
@using Resources
@*
the Comment.Category is defined in areas/certification/views/LCA/ProductLCADetail.cshtml
used by Normal company and Certificate company
possible value of Category:
LCI_Direct_Material,
LCI_Indirect_Material,
LCI_Wrap_Material,
WorkHour,
PowerUsage,
WaterUsage,
Waste_Water,
Waste_Other,
Transport,
WasteTransport,
Vehicle,
GasolineEquipment,
Kitchen_Company,
Kitchen_Outsourcing,
Kitchen_Other,
Refrigerant,
FireEquipment,
SteamUsage,
OtherCompound
*@
<div class="side_bar_right_vertical_line" style="height: 812px;"><div></div></div>
<div class="side_bar" ng-show="lcaDetail" lca-detail>
<div style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Detail/{{lcaDetail.ID}}" class="Item_Active">
<div>@Resource.StaticLabelLCAInfo</div>
<div class="sidebar_triangle"></div>
</a>
</div>
<div ng-show="lcaDetail.isProductLCA&&!lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/BOM/{{lcaDetail.ID}}" class="Item">
<div>BOM</div>
<div class="sidebar_triangle"></div>
</a>
</div>
<div ng-show="lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/HighLevelAnalyze/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelGlobal_HighLevelAnalysis</div>
<div class="sidebar_triangle"></div>
</a>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/DirectMaterial/{{lcaDetail.ID}}" class="Item">
<div>BOM</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showDirectComment=true;"
ng-show="directMaterialCommits.length>0"
ng-bind="directMaterialCommits.length">
</div>
<table-edit-modal display-option="showDirectComment">
<div class="comment">
<div ng-repeat="item in directMaterialCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/InDirectMaterial/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelGlobal_LCIIndirectMaterial</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showIndirectComment=true;"
ng-show="indirectMaterialCommits.length>0"
ng-bind="indirectMaterialCommits.length">
</div>
<table-edit-modal display-option="showIndirectComment">
<div class="comment">
<div ng-repeat="item in indirectMaterialCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WrapMaterial/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelGlobal_LCIWrapMaterial</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWrapMaterialCommits=true;"
ng-show="wrapMaterialCommits.length>0"
ng-bind="wrapMaterialCommits.length">
</div>
<table-edit-modal display-option="showWrapMaterialCommits">
<div class="comment">
<div ng-repeat="item in wrapMaterialCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WorkHour/{{lcaDetail.ID}}" class="Item">
<div>@Resource.TotalWorkHours</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWorkHourCommits=true;"
ng-show="workHourCommits.length>0"
ng-bind="workHourCommits.length">
</div>
<table-edit-modal display-option="showWorkHourCommits">
<div class="comment">
<div ng-repeat="item in workHourCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/PowerUsage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.PowerUsage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showPowerUsageCommits=true;"
ng-show="powerUsageCommits.length>0"
ng-bind="powerUsageCommits.length">
</div>
<table-edit-modal display-option="showPowerUsageCommits">
<div class="comment">
<div ng-repeat="item in powerUsageCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WaterUsage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.WaterUsage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWaterUsageCommits=true;"
ng-show="waterUsageCommits.length>0"
ng-bind="waterUsageCommits.length">
</div>
<table-edit-modal display-option="showWaterUsageCommits">
<div class="comment">
<div ng-repeat="item in waterUsageCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Waste/{{lcaDetail.ID}}" class="Item">
<div>@Resource.Waste</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWasteOtherCommits=true;"
ng-show="wasteOtherCommits.length>0"
ng-bind="wasteOtherCommits.length">
</div>
<table-edit-modal display-option="showWasteOtherCommits">
<div class="comment">
<div ng-repeat="item in wasteOtherCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WasteWater/{{lcaDetail.ID}}" class="Item">
<div>@Resource.ParamemterCategoriesWasteWater</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWasteWaterCommits=true;"
ng-show="wasteWaterCommits.length>0"
ng-bind="wasteWaterCommits.length">
</div>
<table-edit-modal display-option="showWasteWaterCommits">
<div class="comment">
<div ng-repeat="item in wasteWaterCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0 && lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Transport/{{lcaDetail.ID}}" class="Item">
<div>@Resource.Transport</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showTransportComment=true;"
ng-show="transportCommits.length > 0"
ng-bind="transportCommits.length">
</div>
<table-edit-modal display-option="showTransportComment">
<div class="comment">
<div ng-repeat="item in transportCommits track by item.ID"
style="height:auto; color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WasteTransport/{{lcaDetail.ID}}" class="Item">
<div>@Resource.WasteTransportation</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWasteTransportCommits=true;"
ng-show="wasteTransportCommits.length>0"
ng-bind="wasteTransportCommits.length">
</div>
<table-edit-modal display-option="showWasteTransportCommits">
<div class="comment">
<div ng-repeat="item in wasteTransportCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Vehicle/{{lcaDetail.ID}}" class="Item">
<div>@Resource.VehicleVehicleType</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showVehicleCommits=true;"
ng-show="vehicleCommits.length>0"
ng-bind="vehicleCommits.length">
</div>
<table-edit-modal display-option="showVehicleCommits">
<div class="comment">
<div ng-repeat="item in vehicleCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/GasolineEquipment/{{lcaDetail.ID}}" class="Item">
<div>@Resource.ParamemterCategoriesGasolineEquipment</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showGasolineEquipmentCommits=true;"
ng-show="gasolineEquipmentCommits.length>0"
ng-bind="gasolineEquipmentCommits.length">
</div>
<table-edit-modal display-option="showGasolineEquipmentCommits">
<div class="comment">
<div ng-repeat="item in gasolineEquipmentCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Kitchen/{{lcaDetail.ID}}" class="Item">
<div>@Resource.Kitchen</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showkitchenCommits=true;"
ng-show="kitchenCommits.length>0"
ng-bind="kitchenCommits.length">
</div>
<table-edit-modal display-option="showkitchenCommits">
<div class="comment">
<div ng-repeat="item in kitchenCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/FireEquipment/{{lcaDetail.ID}}" class="Item">
<div>@Resource.FireEquipment</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showFireEquipmentCommits=true;"
ng-show="fireEquipmentCommits.length>0"
ng-bind="fireEquipmentCommits.length">
</div>
<table-edit-modal display-option="showFireEquipmentCommits">
<div class="comment">
<div ng-repeat="item in fireEquipmentCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Refrigerant/{{lcaDetail.ID}}" class="Item">
<div>@Resource.RefrigerantEquipment</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showRefrigerantCommits=true;"
ng-show="refrigerantCommits.length>0"
ng-bind="refrigerantCommits.length">
</div>
<table-edit-modal display-option="showRefrigerantCommits">
<div class="comment">
<div ng-repeat="item in refrigerantCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/SteamUsage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.SteamUsage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showSteamUsageCommits=true;"
ng-show="steamUsageCommits.length>0"
ng-bind="steamUsageCommits.length">
</div>
<table-edit-modal display-option="showSteamUsageCommits">
<div class="comment">
<div ng-repeat="item in steamUsageCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0" @*&&lcaDetail.isProductLCA*@ @*CFT-50*@
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/OtherCompound/{{lcaDetail.ID}}" class="Item">
<div>@Resource.OtherCompound</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showOtherCompoundCommits=true;"
ng-show="otherCompoundCommits.length>0"
ng-bind="otherCompoundCommits.length">
</div>
<table-edit-modal display-option="showOtherCompoundCommits">
<div class="comment">
<div ng-repeat="item in otherCompoundCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/ProductUsageStage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.ProductUsageStage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint"
ng-click="showUsageStageCommits=true;"
ng-show="usageStageCommits.length>0"
ng-bind="usageStageCommits.length">
</div>
<table-edit-modal display-option="showUsageStageCommits">
<div class="comment">
<div ng-repeat="item in usageStageCommits track by item.ID"
style="height:auto; color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/AbandonedStage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.AbandonedStage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint"
ng-click="showAbandonedStageCommits=true;"
ng-show="abandonedStageCommits.length>0"
ng-bind="abandonedStageCommits.length">
</div>
<table-edit-modal display-option="showAbandonedStageCommits">
<div class="comment">
<div ng-repeat="item in abandonedStageCommits track by item.ID"
style="height:auto; color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
</div>

View File

@ -0,0 +1,122 @@
@using Resources
@model Weee.ViewModels.Lca.LcaOtherCompoundViewModel
@{
ViewBag.Title = "OtherCompound";
Layout = "~/Areas/Lca/Views/Shared/_LcaLayout.cshtml";
}
@*Html.Partial("~/Views/Partial/LCA/DetailLayout.cshtml")*@
<div class="survey_form">
<div class="survey_form_body" style="width: 84%; margin-right: 0;" lca-detail>
@if (false)//暫時隱藏
{
<div class="survey_form_filter" >
<form ng-hide="isHideSheetHeader">
<div class="form-row">
<div class="col">
<input type="text" class="form-control" aria-label="Default" aria-describedby="inputGroup-sizing-default"
ng-model="sheetHeader.SheetFillerName" ng-readonly="!sheetHeaderForm.editable" placeholder="@Resource.StaticLabelFillerName">
</div>
<div class="col">
<input type="text" class="form-control" aria-label="Default" aria-describedby="inputGroup-sizing-default"
ng-model="sheetHeader.Phone" ng-readonly="!sheetHeaderForm.editable" placeholder="@Resource.StaticLabelUserPhoneNumber">
</div>
<div class="col">
<input type="text" class="form-control" aria-label="Default" aria-describedby="inputGroup-sizing-default"
ng-model="sheetHeader.Department" ng-readonly="!sheetHeaderForm.editable" placeholder="@Resource.StaticLabelUserDepartment">
</div>
<div class="survey_order_btn"
ng-click="editSheetHeader()"
ng-show="!sheetHeaderForm.editable">@Resource.UpdateSheetHeader</div>
<div class="survey_order_btn"
ng-click="saveSheetHeader()"
ng-show="sheetHeaderForm.editable">@Resource.StaticLabelGlobal_Save</div>
<div class="survey_order_btn"
ng-click="cancelEditSheetHeader()"
ng-show="sheetHeaderForm.editable">@Resource.StaticLabelGlobal_Cancel</div>
<div class="sheetheader-result-msg">{{ sheetHeaderForm.resultMsg }}</div>
</div>
<div class="form-row" style="margin: 20px 0px; justify-content: flex-end">
@*CFT-89*@
<div class="survey_order_btn"
ng-click="toGenerateReport()"
ng-show="lcaDetail.Status == 1"
@*ng-show="true"*@>
@Resource.StartCreateReport
</div>
<div class="survey_order_btn"
ng-click="uploadZipReport(lcaDetail.ID)"
ng-show="lcaDetail.Status != 5"
@*ng-show="true"*@>
@Resource.UploadZipReport
</div>
<div class="survey_order_btn"
ng-click="downloadZipReport(lcaDetail.ID)"
ng-show="lcaDetail.Status != 1 && lcaDetail.Status != 2"
@*ng-show="true"*@
>
@Resource.DownloadZipReply
</div>
<div class="survey_order_btn"
ng-click="toWaitState()"
ng-show="lcaDetail.Status == 1">
@Resource.StaticLabelCompleteLCAAndWaitVerification
</div>
<div class="survey_order_btn"
ng-click="toProcessState()"
ng-show="lcaDetail.Status == 3">
@Resource.StaticLabelModifyData
</div>
<div class="survey_order_btn"
ng-click="toCompleteState()"
ng-show="lcaDetail.Status == 4 && lcaDetail.hasPCR || (lcaDetail.Status == 4 && !lcaDetail.isProductLCA)">
@*CFT-38*@@Resource.StartCreateReport
</div>
</div>
<div style="margin-top: 2px;">
@*<div id="download-generated-report">
<div class="survey_order_btn" ng-show="lcaDetail.Status == 1">
<span><a href="#">@Resource.CarbonFootprintReport@Resource.DownloadLink</a></span>
</div>
</div>*@
</div>
<hr />
</form>
</div>
}
@Html.Partial("~/Areas/lca/Views/Detail/OtherCompound/OtherCompound.cshtml", Model)
@*<div ng-include="IncludeTemplate">
</div>*@
</div>
@Html.Partial("~/Areas/lca/Views/Detail/OtherCompound/side_bar.cshtml")
@*<side-bar>
</side-bar>*@
</div>
@if (false) // todo 暫時隱藏
{
<table-edit-modal display-option="reportUploadOption" style="display:none">
<form name="editForm">
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.UploadZipReport</label>
<input class="col col-sm-8" type="file" file read-file="reportUploadOption.selectFile(file)" />
</div>
<div class="row">
<label class="col-sm-4 prompt-msg" style="color: red">
@Resource.ZipFileOnly
</label>
<div class="col" id="upload-file-result-msg"></div>
</div>
<div class="survey_btn_wrap">
<div class="survey_content" style="float: right">
<div class="row">
<button class="header_button" ng-click="uploadZipReportPost()">@Resource.StaticLabelGlobal_Upload</button>
</div>
</div>
</div>
</form>
</table-edit-modal>
}

View File

@ -0,0 +1,305 @@
@using Resources
@model Weee.ViewModels.Lca.LcaOtherCompoundViewModel
@* the select function is provided by select-row directive*@
<div ng-controller="LCAOtherCompoundCtrl" select-row lca-detail>
@* header *@
@* header's button style is controlled by header-content-layout, the business logic(ng-show) is controlled here *@
<div class="body_content container" style="margin-top: 10px;">
<div header-content-layout>
@*header content layout provide the general function like mouse over and background image*@
<div class="header_image_button"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image1_1.png');">
<!--ng-style="{ backgroundImage: headerLayout.header_image1 }"
ng-show="lcaDetail.Status==1"
ng-click="createProcess()"
ng-mouseover="headerLayout.headerImageChange(1, 2)"
ng-mouseleave="headerLayout.headerImageChange(1, 1)"-->
<div class="tooltip" ng-show="headerLayout.show1">
<div ng-style="{width: headerLayout.tooltipWidth(1)}">
@Resource.StaticLabelAddNew
</div>
</div>
</div>
<div class="header_image_button"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image8_1.png');">
<!--ng-style="{ backgroundImage: headerLayout.header_image4 }"
ng-click="editProcess(selectRow.getSelected())"
ng-mouseover="headerLayout.headerImageChange(4, 2)"
ng-mouseleave="headerLayout.headerImageChange(4, 1)"
ng-show="selectRow.getSelected() != null"-->
<div class="tooltip" ng-show="headerLayout.show4">
<div ng-style="{ width: headerLayout.tooltipWidth(4) }">
@Resource.StaticLabelGlobal_Edit
</div>
</div>
</div>
<div class="header_image_button"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image9_1.png');">
<!--ng-style="{ backgroundImage: headerLayout.header_image6 }"
ng-click="deleteProcess(selectRow.getSelected())"
ng-mouseover="headerLayout.headerImageChange(6, 2)"
ng-mouseleave="headerLayout.headerImageChange(6, 1)"
ng-show="selectRow.getSelected() != null"-->
<div class="tooltip" ng-show="headerLayout.show6">
<div ng-style="{ width: headerLayout.tooltipWidth(6) }">
@Resource.StaticLabelGlobal_Delete
</div>
</div>
</div>
<div class="header_image_button"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image17_1.png');">
<!--ng-style="{ backgroundImage: headerLayout.header_image8 }"
ng-click="modelBuilder.export(model)"
ng-mouseover="headerLayout.headerImageChange(8, 2)"
ng-mouseleave="headerLayout.headerImageChange(8, 1)"-->
<div class="tooltip" ng-show="headerLayout.show8">
<div ng-style="{ width: tooltipWidth(8) }">
@Resource.StaticLabelExportBOM
</div>
</div>
</div>
<div class="header_image_button"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image11_1.png');">
<!--ng-style="{ backgroundImage: headerLayout.header_image9 }"
ng-click="fileImportModal.show = true;"
ng-mouseover="headerLayout.headerImageChange(9, 2)"
ng-mouseleave="headerLayout.headerImageChange(9, 1)"-->
<div class="tooltip" ng-show="headerLayout.show9">
<div ng-style="{ width: tooltipWidth(9) }">
@Resource.StaticLabelImprotBOM
</div>
</div>
</div>
<div class="header_image_button"
ng-style="{ backgroundImage: headerLayout.header_image17 }"
ng-click="quoteModal.show = true;"
ng-mouseover="headerLayout.headerImageChange(17, 2)"
ng-mouseleave="headerLayout.headerImageChange(17, 1)">
<div class="tooltip" ng-show="headerLayout.show17">
<div ng-style="{ width: tooltipWidth(17) }">
@Resource.StaticLabelReferenceData
</div>
</div>
</div>
<div class="header_image_button"
ng-style="{ backgroundImage: headerLayout.header_image11 }"
ng-click="search_box = !search_box"
ng-mouseover="headerLayout.headerImageChange(11, 2)"
ng-mouseleave="headerLayout.headerImageChange(11, 1)">
<div class="tooltip" ng-show="headerLayout.show11">
<div ng-style="{ width: tooltipWidth(11) }">
@Resource.StaticLabelGlobal_Search
</div>
</div>
</div>
<div class="header_search" ng-show="!Table_Edit_State">
<input type="text" class="transition" ng-model="searchText" ng-class="{ expand: search_box }" />
</div>
</div>
</div>
@* end of header *@
@* the body of index *@
<div class="body_content" ng-model="currentPage" ng-init="currentPage = 1">
<div class="table_overflow">
<table class="table">
<thead>
<tr class="table-active">
<th>@Resource.FactoryAndProcessItems</th>
<th>@Resource.ResponsibleUnit</th>
<th>@Resource.DeviceName</th>
<th>@Resource.EmissionSources</th>
<th>@Resource.UsageAmount</th>
<th>@Resource.StaticLabelGlobal_Remark</th>
<th>@Resource.KgCO2e</th>
</tr>
</thead>
<tbody ng-mouseleave="setHoverColumnRow(-1, -1, -1)">
@if (Model.OtherCompounds == null || Model.OtherCompounds.Count <= 0)
{
<tr style="border-bottom: solid 1px rgb(214, 214, 214);">
<td ng-show="model.length == 0">
@Resource.NoData
</td>
</tr>
}
else
{
foreach (var rec in Model.OtherCompounds)
{
<tr class="survey_order_table_row"
ng-class="{ selected: row == selectRow.getSelected() }"
ng-click="selectRow.select(row)"
ng-dblclick="editProcess(row)"
ng-repeat="row in model | filter: searchText | smarterLimitTo : 10 : (currentPage - 1) * 10">
<td ng-bind="row.ProcessName">@rec.ProcessName</td>
<td ng-bind="row.ResponsibleUnit">@rec.ResponsibleUnit</td>
<td ng-bind="row.Name">@rec.Name</td>
<td ng-bind="sources[row.ParameterID]">@rec.ParameterID</td>
<td ng-bind="row.Scalar">@rec.Scalar</td>
<td ng-bind="row.Description">@rec.Description</td>
<td ng-bind="row.KgCO2e">@rec.KgCO2e</td>
</tr>
}
}
</tbody>
</table>
</div>
@* end of the body of index *@
<page passed-total-page="Math.ceil(model.length / 10)" passed-current-page="currentPage"></page>
@* the detail modal form *@
@if (false) // todo 暫時隱藏
{
<form name="editForm" novalidate>
<table-edit-modal display-option="modalFormOption" passed-form="editForm">
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.FactoryAndProcessItems</label>
<div class="col col-sm-8">
<input type="text" ng-model="selectRow.toBeEdit.ProcessName" />
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.ResponsibleUnit</label>
<div class="col col-sm-8">
<input type="text" ng-model="selectRow.toBeEdit.ResponsibleUnit">
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.DeviceName</label>
<div class="col col-sm-8">
<input type="text" ng-model="selectRow.toBeEdit.Name">
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.EmissionSources</label>
<div class="col col-sm-8">
<select name="emissionSource" required ng-model="selectRow.toBeEdit.Source" ng-options="value for (key, value) in sources">
<option value="">-- @Resource.StaticLabelGlobal_Select --</option>
</select>
</div>
<div class="validation_block">
<div ng-show="editForm.emissionSource.$dirty">
<small ng-show="editForm.emissionSource.$error.required">
@Resource.SelectValidateMsg
</small>
</div>
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.IngredientName</label>
<div class="col col-sm-8">
<input type="text" ng-model="selectRow.toBeEdit.ingredientName">
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.WarmGasType</label>
<div class="col col-sm-8">
<select name="warmGasType" required ng-model="selectRow.toBeEdit.warmGasType" id="warmGasType">
<option value="">-- @Resource.StaticLabelGlobal_Select --</option>
<option value="1">@Resource.fixedSource</option>
<option value="2">@Resource.movingSource</option>
<option value="3">@Resource.escapeSource</option>
<option value="4">@Resource.manufactureSource</option>
<option value="5">@Resource.landUsageSource</option>
<option value="6">@Resource.externalEnergySource</option>
</select>
</div>
<div class="validation_block">
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.UsageAmount</label>
<div class="col col-sm-8">
<input name="scalar"
type="number" step="any"
placeholder="@Resource.RequiredMessage"
required
ng-model="selectRow.toBeEdit.Scalar">
</div>
<div class="validation_block">
<div ng-show="editForm.scalar.$dirty">
<small ng-show="editForm.scalar.$error.required &&
!editForm.scalar.$error.number">
@Resource.RequiredMessage
</small>
<small ng-show="editForm.scalar.$error.number">
@Resource.NumberValidateMsg
</small>
</div>
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.StaticLabelGlobal_Remark</label>
<div class="col col-sm-8">
<input type="text" ng-model="selectRow.toBeEdit.Description">
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.KgCO2e</label>
<div class="col col-sm-8">
<input type="number" step="any" readonly="readonly" ng-model="selectRow.toBeEdit.KgCO2e" />
</div>
<div class="validation_block"></div>
</div>
<div class="survey_btn_wrap">
<div class="survey_content" style="float: right">
<div class="row">
<button class="header_button"
style="float: left; margin-left: 16px;"
ng-click="save()"
ng-show="lcaDetail.Status==1"
ng-disabled="editForm.$invalid">
@Resource.StaticLabelGlobal_Save
</button>
</div>
</div>
</div>
</table-edit-modal>
</form>
@* end of the detail modal form *@
}
<table-edit-modal display-option="fileImportModal">
<div file-import-process import-option="fileImportOptions"></div>
</table-edit-modal>
<table-edit-modal display-option="quoteModal">
<div></div>
<div quote quote-options="quoteOptions"></div>
</table-edit-modal>
<div class="footnote">
@Resource.FootnoteOtherCompound.Replace("\r\n", "<br>")
</div>
</div>
</div>

View File

@ -0,0 +1,510 @@
@using Resources
@*
the Comment.Category is defined in areas/certification/views/LCA/ProductLCADetail.cshtml
used by Normal company and Certificate company
possible value of Category:
LCI_Direct_Material,
LCI_Indirect_Material,
LCI_Wrap_Material,
WorkHour,
PowerUsage,
WaterUsage,
Waste_Water,
Waste_Other,
Transport,
WasteTransport,
Vehicle,
GasolineEquipment,
Kitchen_Company,
Kitchen_Outsourcing,
Kitchen_Other,
Refrigerant,
FireEquipment,
SteamUsage,
OtherCompound
*@
<div class="side_bar_right_vertical_line" style="height: 812px;"><div></div></div>
<div class="side_bar" ng-show="lcaDetail" lca-detail>
<div style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Detail/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelLCAInfo</div>
<div class="sidebar_triangle"></div>
</a>
</div>
<div ng-show="lcaDetail.isProductLCA&&!lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/BOM/{{lcaDetail.ID}}" class="Item">
<div>BOM</div>
<div class="sidebar_triangle"></div>
</a>
</div>
<div ng-show="lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/HighLevelAnalyze/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelGlobal_HighLevelAnalysis</div>
<div class="sidebar_triangle"></div>
</a>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/DirectMaterial/{{lcaDetail.ID}}" class="Item">
<div>BOM</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showDirectComment=true;"
ng-show="directMaterialCommits.length>0"
ng-bind="directMaterialCommits.length">
</div>
<table-edit-modal display-option="showDirectComment">
<div class="comment">
<div ng-repeat="item in directMaterialCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/InDirectMaterial/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelGlobal_LCIIndirectMaterial</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showIndirectComment=true;"
ng-show="indirectMaterialCommits.length>0"
ng-bind="indirectMaterialCommits.length">
</div>
<table-edit-modal display-option="showIndirectComment">
<div class="comment">
<div ng-repeat="item in indirectMaterialCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WrapMaterial/{{lcaDetail.ID}}" class="Item">
<div>@Resource.StaticLabelGlobal_LCIWrapMaterial</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWrapMaterialCommits=true;"
ng-show="wrapMaterialCommits.length>0"
ng-bind="wrapMaterialCommits.length">
</div>
<table-edit-modal display-option="showWrapMaterialCommits">
<div class="comment">
<div ng-repeat="item in wrapMaterialCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WorkHour/{{lcaDetail.ID}}" class="Item">
<div>@Resource.TotalWorkHours</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWorkHourCommits=true;"
ng-show="workHourCommits.length>0"
ng-bind="workHourCommits.length">
</div>
<table-edit-modal display-option="showWorkHourCommits">
<div class="comment">
<div ng-repeat="item in workHourCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/PowerUsage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.PowerUsage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showPowerUsageCommits=true;"
ng-show="powerUsageCommits.length>0"
ng-bind="powerUsageCommits.length">
</div>
<table-edit-modal display-option="showPowerUsageCommits">
<div class="comment">
<div ng-repeat="item in powerUsageCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WaterUsage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.WaterUsage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWaterUsageCommits=true;"
ng-show="waterUsageCommits.length>0"
ng-bind="waterUsageCommits.length">
</div>
<table-edit-modal display-option="showWaterUsageCommits">
<div class="comment">
<div ng-repeat="item in waterUsageCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Waste/{{lcaDetail.ID}}" class="Item">
<div>@Resource.Waste</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWasteOtherCommits=true;"
ng-show="wasteOtherCommits.length>0"
ng-bind="wasteOtherCommits.length">
</div>
<table-edit-modal display-option="showWasteOtherCommits">
<div class="comment">
<div ng-repeat="item in wasteOtherCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WasteWater/{{lcaDetail.ID}}" class="Item">
<div>@Resource.ParamemterCategoriesWasteWater</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWasteWaterCommits=true;"
ng-show="wasteWaterCommits.length>0"
ng-bind="wasteWaterCommits.length">
</div>
<table-edit-modal display-option="showWasteWaterCommits">
<div class="comment">
<div ng-repeat="item in wasteWaterCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0 && lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Transport/{{lcaDetail.ID}}" class="Item">
<div>@Resource.Transport</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showTransportComment=true;"
ng-show="transportCommits.length > 0"
ng-bind="transportCommits.length">
</div>
<table-edit-modal display-option="showTransportComment">
<div class="comment">
<div ng-repeat="item in transportCommits track by item.ID"
style="height:auto; color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/WasteTransport/{{lcaDetail.ID}}" class="Item">
<div>@Resource.WasteTransportation</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showWasteTransportCommits=true;"
ng-show="wasteTransportCommits.length>0"
ng-bind="wasteTransportCommits.length">
</div>
<table-edit-modal display-option="showWasteTransportCommits">
<div class="comment">
<div ng-repeat="item in wasteTransportCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Vehicle/{{lcaDetail.ID}}" class="Item">
<div>@Resource.VehicleVehicleType</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showVehicleCommits=true;"
ng-show="vehicleCommits.length>0"
ng-bind="vehicleCommits.length">
</div>
<table-edit-modal display-option="showVehicleCommits">
<div class="comment">
<div ng-repeat="item in vehicleCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/GasolineEquipment/{{lcaDetail.ID}}" class="Item">
<div>@Resource.ParamemterCategoriesGasolineEquipment</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showGasolineEquipmentCommits=true;"
ng-show="gasolineEquipmentCommits.length>0"
ng-bind="gasolineEquipmentCommits.length">
</div>
<table-edit-modal display-option="showGasolineEquipmentCommits">
<div class="comment">
<div ng-repeat="item in gasolineEquipmentCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Kitchen/{{lcaDetail.ID}}" class="Item">
<div>@Resource.Kitchen</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showkitchenCommits=true;"
ng-show="kitchenCommits.length>0"
ng-bind="kitchenCommits.length">
</div>
<table-edit-modal display-option="showkitchenCommits">
<div class="comment">
<div ng-repeat="item in kitchenCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/FireEquipment/{{lcaDetail.ID}}" class="Item">
<div>@Resource.FireEquipment</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showFireEquipmentCommits=true;"
ng-show="fireEquipmentCommits.length>0"
ng-bind="fireEquipmentCommits.length">
</div>
<table-edit-modal display-option="showFireEquipmentCommits">
<div class="comment">
<div ng-repeat="item in fireEquipmentCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/Refrigerant/{{lcaDetail.ID}}" class="Item">
<div>@Resource.RefrigerantEquipment</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showRefrigerantCommits=true;"
ng-show="refrigerantCommits.length>0"
ng-bind="refrigerantCommits.length">
</div>
<table-edit-modal display-option="showRefrigerantCommits">
<div class="comment">
<div ng-repeat="item in refrigerantCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/SteamUsage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.SteamUsage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showSteamUsageCommits=true;"
ng-show="steamUsageCommits.length>0"
ng-bind="steamUsageCommits.length">
</div>
<table-edit-modal display-option="showSteamUsageCommits">
<div class="comment">
<div ng-repeat="item in steamUsageCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0" @*&&lcaDetail.isProductLCA*@ @*CFT-50*@
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/OtherCompound/{{lcaDetail.ID}}" class="Item_Active">
<div>@Resource.OtherCompound</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint" ng-click="showOtherCompoundCommits=true;"
ng-show="otherCompoundCommits.length>0"
ng-bind="otherCompoundCommits.length">
</div>
<table-edit-modal display-option="showOtherCompoundCommits">
<div class="comment">
<div ng-repeat="item in otherCompoundCommits track by item.ID"
style="height:auto;color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/ProductUsageStage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.ProductUsageStage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint"
ng-click="showUsageStageCommits=true;"
ng-show="usageStageCommits.length>0"
ng-bind="usageStageCommits.length">
</div>
<table-edit-modal display-option="showUsageStageCommits">
<div class="comment">
<div ng-repeat="item in usageStageCommits track by item.ID"
style="height:auto; color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
<div ng-show="lcaDetail.Status!=0&&lcaDetail.isProductLCA&&lcaDetail.hasPCR"
style="clear: both; width: 100%; height: 28px; position: relative;">
<a href="#LCA/AbandonedStage/{{lcaDetail.ID}}" class="Item">
<div>@Resource.AbandonedStage</div>
<div class="sidebar_triangle"></div>
</a>
<div class="comment_hint"
ng-click="showAbandonedStageCommits=true;"
ng-show="abandonedStageCommits.length>0"
ng-bind="abandonedStageCommits.length">
</div>
<table-edit-modal display-option="showAbandonedStageCommits">
<div class="comment">
<div ng-repeat="item in abandonedStageCommits track by item.ID"
style="height:auto; color:#595757">
@*<textarea class="comment_textarea"
readonly
ng-bind="item.CommentText"></textarea>*@
<textarea class="form-control" readonly rows="3" ng-bind="item.CommentText"></textarea>
<div class="comment_line"></div>
</div>
</div>
</table-edit-modal>
</div>
</div>

View File

@ -0,0 +1,169 @@
@using Resources
@model Weee.ViewModels.Lca.LcaIndexViewModel
@{
ViewBag.Title = "Index";
Layout = "~/Areas/Lca/Views/Shared/_LcaLayout.cshtml";
}
<div class="survey_form" ng-style="{ height: Survey_Height * 28 + 24 + 'px' }" style="padding: 28px 16px;">
<div class="survey_form_body" ng-style="{ height: sidebar.length * 28 + 'px' }" style="margin: 0; padding: 0;">
<div class="tab_header_main">
<div class="tab_header">
<div class="tab-toggle">
<div ng-class="{ active: selectedTab == 'management' }"
ng-click="selectedTab = 'management'">
<div class="tab">@Resource.ManagementList</div>
</div>
</div>
</div>
<div class="tab_header">
<div class="survey_order_btn_wrap tab-toggle" ng-show="selectedTab=='management'">
<div class="survey_order_btn" ng-click="goToUserCreate()">
@Resource.NewUser
</div>
<div class="survey_order_btn" ng-click="uploadCompanyLogo()">
@Resource.UploadCompanyLogo
</div>
<div class="survey_order_btn">
<span>
<a href="/Browser_Local/WebFilesRoot/@User.Identity.Name/OrganizationLCADocTemplate.docx" style="color: #a1a2a2;">
@Resource.OrganizationLCADocTemplate@Resource.DownloadLink
</a>
</span>
</div>
<div class="survey_order_btn" ng-click="uploadCompanyTemplates()">
@Resource.UploadTemplates
</div>
</div>
</div>
</div>
<div class="tab_content card content_bg">
<div style="margin: 20px">
@*<div ng-include="'../Partials/management-Index'" ng-show="selectedTab == 'management'"></div>
Html.Partial("~/Views/Partial/Management/Index.cshtml", Model)
{
Html.RenderPartial("~/Views/Partial/Management/Index.cshtml", Model.user);
}*@
<div class="body_content receive_tool_menu">
@*<div class="header_search">
<img class="header_image_button" src="../Browser_Local/img/header_image11_1.png" />
<input type="text" class="expand" ng-model="searchText" />
</div>*@
<form class="form-inline header_search" style="float: right">
<input class="form-control mr-sm-2" type="search" ng-model="searchText"
placeholder="@Resource.StaticLabelGlobal_Search" aria-label="Search">
</form>
</div>
<div class="body_content"
ng-model="currentPage"
ng-init="currentPage = 1">
<div class="table-responsive">
<div class="table_overflow">
<table class="table">
<!-- Table header -->
<thead>
<tr class="table-active">
<th>@Resource.StaticLabelGlobal_Name</th>
<th>@Resource.StaticLabelUserPhoneNumber</th>
<th>@Resource.StaticLabelUserEmail</th>
<th>@Resource.SurveyJob</th>
<th></th>
</tr>
</thead>
<!-- Table row -->
<tbody>
@foreach (var rec in Model.users)
{
<tr>
<td>@rec.Name</td>
<td>@rec.PhoneNumber</td>
<td>@rec.Email</td>
<td>@rec.Job</td>
<td>
<img style="cursor: pointer;"
ng-init="editIcon = 'edit'"
ng-src="@ViewBag.baseUrl/Browser_Local/img/{{ editIcon }}.png"
ng-click="editUser(user)"
ng-mouseenter="editIcon = 'edit_active'"
ng-mouseleave="editIcon = 'edit'" />
</td>
</tr>
}
@*<tr ng-repeat="user in userList | filter : searchText | orderBy : predicate : reverse | smarterLimitTo : 10 : (currentPage - 1) * 10">
<td ng-bind="user.Name"></td>
<td ng-bind="user.PhoneNumber"></td>
<td ng-bind="user.Email"></td>
<td ng-bind="user.Job"></td>
<td>
<img style="cursor: pointer;"
ng-init="editIcon = 'edit'"
ng-src="../../../Browser_Local/img/{{ editIcon }}.png"
ng-click="editUser(user)"
ng-mouseenter="editIcon = 'edit_active'"
ng-mouseleave="editIcon = 'edit'" />
</td>
</tr>*@
</tbody>
</table>
</div>
</div>
</div>
<page passed-total-page="Math.ceil((userList | filter : searchText).length / 10)" passed-current-page="currentPage"></page>
</div>
</div>
</div>
</div>
@if (false)//todo 暫時隱藏
{
<table-edit-modal display-option="">
<div file-import-process import-option="fileImportOption"></div>
</table-edit-modal>
<table-edit-modal display-option="logoImportOption">
<form name="editForm">
<div class="row">
<label class="col-sm-2 col-form-label">@Resource.UploadCompanyLogo</label>
<div class="col col-sm-8">
<input type="file" style="margin-top: 7px;" file read-file="logoImportOption.selectFile(file)" />
</div>
</div>
<div class="survey_btn_wrap">
<div class="survey_content" style="float: right">
<div class="row">
<button class="header_button" ng-click="uploadLogo()">@Resource.StaticLabelGlobal_Upload</button>
</div>
</div>
</div>
</form>
</table-edit-modal>
<table-edit-modal display-option="templateImportOption">
<form name="editForm">
<div class="row">
<label class="col-sm-4 col-form-label">
@Resource.TemplateUpload
</label>
<div class="col col-sm-8">
<input type="file" file read-file="templateImportOption.selectFile(file)" />
</div>
</div>
<div class="row">
<label class="col col-sm-4 prompt-msg" style="color: red">
@Resource.TemplateUploadPromptMessage
</label>
<div class="col" id="upload-file-result-msg"></div>
</div>
<div class="survey_btn_wrap">
<div class="survey_content" style="float: right">
<div class="row">
<button class="header_button" ng-click="uploadTemplates()">@Resource.StaticLabelGlobal_Upload</button>
</div>
</div>
</div>
</form>
</table-edit-modal>
}

View File

@ -0,0 +1,167 @@
@using Resources
@model Qcarbon.ViewModels.DTO.RiskMaterialViewModel
@{
ViewBag.Title = "Index";
Layout = "~/Areas/Lca/Views/Shared/_LcaRiskLayout.cshtml";
}
@* the detail modal form *@
@using (Html.BeginForm())
{
@Html.AntiForgeryToken()
@Html.HiddenFor(x=>x.cmd, new { @id="cmd"})
@Html.HiddenFor(x=>x.singleRec.LCAID)
<div class="survey_form container" style="padding: 0 16px;">
<div class="add_survey_body">
<div class="add_survey_header_title"></div>
<div class="survey_info">
<div class="title">
新增原物料
</div>
<div class="survey_content">
@Html.ValidationSummary(false, "", new { @class="text-danger", style="margin-left:15px;font-weight: bold;" })
</div>
<div class="survey_content">
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.MaterialNo</label>
<div class="col col-sm-8">
@Html.EditorFor(x=>x.singleRec.MaterialNo, new { htmlAttributes = new { placeholder = Resource.RequiredMessage}})
@*<input name="materialNo"
type="text"
placeholder="@Resource.RequiredMessage"
required
ng-model="selectRow.toBeEdit.MaterialNo">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialName</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.MaterialName, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
@*<input type="text" ng-model="selectRow.toBeEdit.MaterialName" />*@
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialSpec</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.MaterialSpec, new { htmlAttributes = new { onchange = "onVarChange()", placeholder = Resource.RequiredMessage, type="number", step="any" } })
@*<input name="materialSpec"
type="number" step="any"
max="{{CONSTANTS.MAXNUMVALUE}}"
placeholder="@Resource.RequiredMessage"
required
ng-model="selectRow.toBeEdit.MaterialSpec"
ng-change="calcActivityAndEmission(selectRow.toBeEdit)">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialPCS</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.AnnualPurchaseAmount, new { htmlAttributes = new { onchange = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
@*<input name="annualPurchaseAmount"
type="number" step="any"
placeholder="@Resource.RequiredMessage"
required
max="{{CONSTANTS.MAXNUMVALUE}}"
ng-model="selectRow.toBeEdit.AnnualPurchaseAmount"
ng-change="calcActivityAndEmission(selectRow.toBeEdit)">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialScalar (@Resource.KgCO2e)</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.KgCO2e, new { htmlAttributes = new { onchange = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
@*<input name="kgCO2e"
type="number" step="any"
max="{{CONSTANTS.MAXNUMVALUE}}"
placeholder="@Resource.RequiredMessage"
required
ng-model="selectRow.toBeEdit.KgCO2e"
ng-change="calcEmission(selectRow.toBeEdit)">*@
<div class="header_image_button simapro-image-button"
click="selectSimaproProcess(selectRow.toBeEdit)">
</div>
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialActivity</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.ActivityIntensity, new { htmlAttributes = new {@readonly = "readonly" } })
@*<input name="activityIntensity"
type="number" step="any"
readonly="readonly"
ng-model="selectRow.toBeEdit.ActivityIntensity">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialQty (@Resource.KgCO2e)</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.Emission, new { htmlAttributes = new { @readonly = "readonly" } })
@*<input name="emission"
type="number" step="any"
readonly="readonly"
ng-model="selectRow.toBeEdit.Emission">*@
</div>
</div>
@*<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialAddressUnit</label>
<div class="col col-sm-8">
<input name="unit"
type="text"
required
placeholder="@Resource.RequiredMessage"
ng-model="selectRow.toBeEdit.Unit">
</div>
</div>*@
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialActivityUnit</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.Unit, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
@*<input name="activityIntensityUnit"
type="text"
required
placeholder="@Resource.RequiredMessage"
ng-model="selectRow.toBeEdit.ActivityIntensityUnit">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAIntlTravelRemark</label>
<div class="col col-sm-8">
@Html.EditorFor(x => x.singleRec.Comment)
@*<input type="text"
ng-model="selectRow.toBeEdit.Comment">*@
</div>
</div>
<div class="row">
<div class="survey_content" >
<button class="header_button"
type="button" onclick="$('#cmd').val('儲存');$('form').submit();">
@Resource.StaticLabelGlobal_Save
</button>
</div>
</div>
</div>
</div>
</div>
</div>
}
<script>
function onVarChange() {
console.log('onVarChange');
}
//活動強度=採購數量(PCS)*物料規格
//排放量=活動強度*係數
//係數選擇icon
</script>

View File

@ -0,0 +1,182 @@
@using Resources
@model Qcarbon.ViewModels.DTO.RiskMaterialViewModel
@{
ViewBag.Title = "Index";
Layout = "~/Areas/Lca/Views/Shared/_LcaRiskLayout.cshtml";
}
@* the detail modal form *@
@using (Html.BeginForm())
{
@Html.AntiForgeryToken()
@Html.HiddenFor(x => x.cmd, new { @id = "cmd" })
@Html.HiddenFor(x => x.singleRec.LCAID)
<div class="survey_form container" style="padding: 0 16px;">
<div class="add_survey_body">
<div class="add_survey_header_title"></div>
<div class="survey_info">
<div class="title">
新增原物料
</div>
@if (!string.IsNullOrWhiteSpace(Model.successMsg))
{
<div class="survey_content alert alert-success" role="alert">
@Model.successMsg
</div>
}
<div class="survey_content">
@Html.ValidationSummary(false, "", new { @class = "text-danger", style = "margin-left:15px;font-weight: bold;" })
</div>
<div class="survey_content">
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.MaterialNo</label>
<div class="col col-sm-7">
@if (!Model.editing)
{
@Html.EditorFor(x => x.singleRec.MaterialNo, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
}
else
{
@Html.EditorFor(x => x.singleRec.MaterialNo, new { htmlAttributes = new { placeholder = Resource.RequiredMessage, @readonly = "readonly" } })
@Html.HiddenFor(x=>x.singleRec.MaterialNo)
}
@*<input name="materialNo"
type="text"
placeholder="@Resource.RequiredMessage"
required
ng-model="selectRow.toBeEdit.MaterialNo">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialName</label>
<div class="col col-sm-7">
@Html.EditorFor(x => x.singleRec.MaterialName, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
@*<input type="text" ng-model="selectRow.toBeEdit.MaterialName" />*@
</div>
<div class="validation_block"></div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialSpec (kg)</label>
<div class="col col-sm-7">
@Html.EditorFor(x => x.singleRec.MaterialSpec, new { htmlAttributes = new { onblur = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
@*<input name="materialSpec"
type="number" step="any"
max="{{CONSTANTS.MAXNUMVALUE}}"
placeholder="@Resource.RequiredMessage"
required
ng-model="selectRow.toBeEdit.MaterialSpec"
ng-change="calcActivityAndEmission(selectRow.toBeEdit)">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialPCS</label>
<div class="col col-sm-7">
@Html.EditorFor(x => x.singleRec.AnnualPurchaseAmount, new { htmlAttributes = new { onblur = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
@*<input name="annualPurchaseAmount"
type="number" step="any"
placeholder="@Resource.RequiredMessage"
required
max="{{CONSTANTS.MAXNUMVALUE}}"
ng-model="selectRow.toBeEdit.AnnualPurchaseAmount"
ng-change="calcActivityAndEmission(selectRow.toBeEdit)">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialScalar (@Resource.KgCO2e)</label>
<div class="col col-sm-7">
<div class="row">
@Html.EditorFor(x => x.singleRec.KgCO2e, new { htmlAttributes = new { onblur = "onVarChange()", placeholder = Resource.RequiredMessage, type = "number", step = "any" } })
<div class="header_image_button simapro-image-button" style="right:-40px"
click="selectSimaproProcess(selectRow.toBeEdit)">
</div>
</div>
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialActivity</label>
<div class="col col-sm-7">
<input value="@Model.singleRec.ActivityIntensity" readonly="readonly"/>
@*@Html.HiddenFor(x => x.singleRec.ActivityIntensity)
@Html.EditorFor(x => x.singleRec.ActivityIntensity, new { htmlAttributes = new { @readonly = "readonly" } })*@
@*<input name="activityIntensity"
type="number" step="any"
readonly="readonly"
ng-model="selectRow.toBeEdit.ActivityIntensity">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialQty (@Resource.KgCO2e)</label>
<div class="col col-sm-7">
<input value="@Model.singleRec.Emission" readonly="readonly" />
@*@Html.HiddenFor(x=>x.singleRec.Emission)
@Html.EditorFor(x => x.singleRec.Emission, new { htmlAttributes = new { @readonly = "readonly" } })*@
@*<input name="emission"
type="number" step="any"
readonly="readonly"
ng-model="selectRow.toBeEdit.Emission">*@
</div>
</div>
@*<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialAddressUnit</label>
<div class="col col-sm-7">
<input name="unit"
type="text"
required
placeholder="@Resource.RequiredMessage"
ng-model="selectRow.toBeEdit.Unit">
</div>
</div>*@
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAMC3EMaterialActivityUnit</label>
<div class="col col-sm-7">
@Html.EditorFor(x => x.singleRec.Unit, new { htmlAttributes = new { placeholder = Resource.RequiredMessage } })
@*<input name="activityIntensityUnit"
type="text"
required
placeholder="@Resource.RequiredMessage"
ng-model="selectRow.toBeEdit.ActivityIntensityUnit">*@
</div>
</div>
<div class="row">
<label class="col-sm-4 col-form-label">@Resource.RAIntlTravelRemark</label>
<div class="col col-sm-7">
@Html.EditorFor(x => x.singleRec.Comment)
@*<input type="text"
ng-model="selectRow.toBeEdit.Comment">*@
</div>
</div>
<div class="row">
<div class="survey_content">
<button class="header_button"
type="button" onclick="$('#cmd').val('儲存');$('form').submit();">
@Resource.StaticLabelGlobal_Save
</button>
</div>
</div>
</div>
</div>
</div>
</div>
}
<script>
function onVarChange() {
//console.log('onVarChange');
$('#cmd').val('更新');
$('form').submit();
}
//活動強度=採購數量(PCS)*物料規格
//排放量=活動強度*係數
//係數選擇icon
</script>

View File

@ -0,0 +1,137 @@
@using Resources
@model Qcarbon.ViewModels.DTO.RiskMaterialListViewModel
@{
ViewBag.Title = "Index";
Layout = "~/Areas/Lca/Views/Shared/_LcaRiskLayout.cshtml";
ViewBag.selected = "";
}
<div select-row lca-detail>
@* header *@
@* header's button style is controlled by header-content-layout, the business logic(ng-show) is controlled here *@
<div class="body_content container" style="margin-top: 10px;">
<div header-content-layout>
@using (Html.BeginForm())
{
@Html.AntiForgeryToken()
@Html.HiddenFor(x => x.cmd, new { @id = "cmd" })
@Html.HiddenFor(x=>x.selectedID, new {@id="selectedID"})
<div>
@Html.ValidationSummary(true)
</div>
@*header content layout provide the general function like mouse over and background image*@
<div id="btnAdd" class="header_image_button" title="@Resource.StaticLabelAddNew"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image1_1.png');">
</div>
if (!string.IsNullOrWhiteSpace( Model.selectedID) || Model.selectedModel != null)
{
<div id="btnEdit" class="header_image_button" title="@Resource.StaticLabelGlobal_Edit"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image4_1.png');">
</div>
<div id="btnDelete" class="header_image_button" title="@Resource.StaticLabelGlobal_Delete"
style="background-image: url('@ViewBag.baseUrl/Browser_Local/img/header_image6_1.png');">
</div>
}
@*<div id="btnExport" class="header_image_button" title="@Resource.StaticLabelExportBOM"
style="background-image: url('../../Browser_Local/img/header_image8_1.png');">
</div>
<div id="btnImport" class="header_image_button" title="@Resource.StaticLabelImprotBOM"
style="background-image: url('../../Browser_Local/img/header_image9_1.png');">
</div>
<div id="btnReference" class="header_image_button" title="@Resource.StaticLabelReferenceData"
style="background-image: url('../../Browser_Local/img/header_image17_1.png');">
</div>
<div class="header_image_button" title="@Resource.StaticLabelGlobal_Search"
style="background-image: url('../../Browser_Local/img/header_image11_1.png');">
</div>
<div class="header_search" ng-show="!Table_Edit_State">
<input type="text" class="transition" ng-model="searchText" ng-class="{ expand: search_box }" />
</div>*@
}
</div>
</div>
@* end of header *@
@* the body of index *@
<div class="body_content">
<div class="table_overflow">
<table class="table">
<thead>
<tr class="table-active">
<th style="text-align:center">@Resource.MaterialNo</th>
<th style="text-align:center">@Resource.RAMC3EMaterialSpec (kg)</th>
<th style="text-align:center">@Resource.RAMC3EMaterialActivityUnit</th>
<th style="text-align:center">@Resource.RAMC3EMaterialPCS</th>
<th style="text-align:center">@Resource.RAMC3EMaterialScalar (@Resource.KgCO2e)</th>
<th style="text-align:center">@Resource.RAMC3EMaterialActivity</th>
<th style="text-align:center">@Resource.RAMC3EMaterialQty (@Resource.KgCO2e)</th>
@*<th style="text-align:center">DQI</th>*@
</tr>
</thead>
<tbody>
@if (Model.modelList == null || Model.modelList.Count <= 0)
{
<tr style="border-bottom: solid 1px rgb(214, 214, 214);">
<td>
@Resource.NoData
</td>
</tr>
}
else
{
foreach (var rec in Model.modelList)
{
if (rec.MaterialNo == Model.selectedID)
{
ViewBag.selected = "selected";
}
else
{
ViewBag.selected = "";
}
<tr class="survey_order_table_row @ViewBag.selected" id="@rec.MaterialNo"
@*ng-class="{ selected: row == selectRow.getSelected() }"
ng-click="selectRow.select(row)"
ng-dblclick="editProcess(row)"
ng-repeat="row in model | filter: searchText | smarterLimitTo : 10 : (currentPage - 1) * 10"*@
>
<td style="text-align:center">@rec.MaterialNo</td>
<td style="text-align:right">@rec.MaterialSpec.ToString("F04")</td>
<td style="text-align:center">@rec.Unit</td>
<td style="text-align:right">@rec.AnnualPurchaseAmount</td>
<td style="text-align:right">@rec.KgCO2e.ToString("F10")</td>
<td style="text-align:right">@rec.ActivityIntensity.ToString("F04")</td>
<td style="text-align:right">@rec.Emission.ToString("F04")</td>
@*<td></td>*@
</tr>
}
}
</tbody>
</table>
</div>
@* end of the body of index *@
@*<page passed-total-page="Math.ceil(model.length / 10)" passed-current-page="currentPage"></page>*@
</div>
</div>
<script>
$(document).on("click", ".header_image_button", function () {
var clickId = $(this).attr('id');
console.log('clicked id', clickId);
$('#cmd').val(clickId);
$('form').submit();
});
$(document).on("click", ".survey_order_table_row", function () {
var clickId = $(this).attr('id');
console.log('clicked id', clickId);
$('#cmd').val('選取');
$('#selectedID').val(clickId);
$('form').submit();
});
//$('#btnAdd').click(function () {
// console.log('btnAdd clicked');
// $("#addModel").show();
//});
</script>

View File

@ -0,0 +1,90 @@
@using Resources
@model Qcarbon.ViewModels.DTO.RiskMaterialListViewModel
<div select-row lca-detail>
@* header *@
@* header's button style is controlled by header-content-layout, the business logic(ng-show) is controlled here *@
<div class="body_content container" style="margin-top: 10px;">
<div header-content-layout>
@*header content layout provide the general function like mouse over and background image*@
<div class="header_image_button" title="@Resource.StaticLabelAddNew"
style="background-image: url('../../Browser_Local/img/header_image1_1.png');">
</div>
@if (Model.selectedModel != null)
{
<div class="header_image_button" title="@Resource.StaticLabelGlobal_Edit"
style="background-image: url('../../Browser_Local/img/header_image4_1.png');">
</div>
<div class="header_image_button" title="@Resource.StaticLabelGlobal_Delete"
style="background-image: url('../../Browser_Local/img/header_image6_1.png');">
</div>
}
@*<div class="header_image_button" title="@Resource.StaticLabelExportBOM"
style="background-image: url('../../Browser_Local/img/header_image8_1.png');">
</div>
<div class="header_image_button" title="@Resource.StaticLabelImprotBOM"
style="background-image: url('../../Browser_Local/img/header_image9_1.png');">
</div>
<div class="header_image_button" title="@Resource.StaticLabelReferenceData"
style="background-image: url('../../Browser_Local/img/header_image17_1.png');">
</div>
<div class="header_image_button" title="@Resource.StaticLabelGlobal_Search"
style="background-image: url('../../Browser_Local/img/header_image11_1.png');">
</div>
<div class="header_search" ng-show="!Table_Edit_State">
<input type="text" class="transition" ng-model="searchText" ng-class="{ expand: search_box }" />
</div>*@
</div>
</div>
@* end of header *@
@* the body of index *@
<div class="body_content" ng-model="currentPage" ng-init="currentPage = 1">
<div class="table_overflow">
<table class="table">
<thead>
<tr class="table-active">
<th>@Resource.MaterialNo</th>
<th>@Resource.RAMC3EMaterialSpec</th>
<th>@Resource.RAMC3EMaterialActivityUnit</th>
<th>@Resource.RAMC3EMaterialPCS</th>
<th>@Resource.RAMC3EMaterialScalar (@Resource.KgCO2e)</th>
<th>@Resource.RAMC3EMaterialActivity</th>
<th>@Resource.RAMC3EMaterialQty (@Resource.KgCO2e)</th>
<th>DQI</th>
</tr>
</thead>
<tbody ng-mouseleave="setHoverColumnRow(-1, -1, -1)">
@if (Model.modelList == null || Model.modelList.Count <= 0)
{
<tr style="border-bottom: solid 1px rgb(214, 214, 214);">
<td ng-show="model.length == 0">
@Resource.NoData
</td>
</tr>
}
else
{
foreach (var rec in Model.modelList)
{
<tr class="survey_order_table_row"
ng-class="{ selected: row == selectRow.getSelected() }"
ng-click="selectRow.select(row)"
ng-dblclick="editProcess(row)"
ng-repeat="row in model | filter: searchText | smarterLimitTo : 10 : (currentPage - 1) * 10">
<td ng-bind="row.KgCO2e">@rec.KgCO2e</td>
</tr>
}
}
</tbody>
</table>
</div>
@* end of the body of index *@
<page passed-total-page="Math.ceil(model.length / 10)" passed-current-page="currentPage"></page>
</div>
</div>

View File

@ -0,0 +1,349 @@
@using Resources
@using Weee.Models.ExtensionMethods
@using Weee.DAL
@using Weee.Models
@{
var baseUrl = ViewBag.baseUrl;
System.Threading.Thread.Sleep(0);
}
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
<!--meta http-equiv="X-UA-Compatible" content="IE=11" /-->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta http-equiv="cache-control" content="max-age=0" />
<meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate" />
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<link type="text/css" rel="stylesheet" href="~/Browser_Local/css/datepicker.css" />
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.7.2/font/bootstrap-icons.css">
@*<link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datetimepicker/4.7.14/js/bootstrap-datetimepicker.min.js" />*@
@*RenderSection("PageStyles", required: false)*@
@section PageStyles
{
}
@*Styles.Render("~/Browser_Local")
@Scripts.Render("~/jQuery")*@
<link href="~/Browser_Local/css/html5-doctor-reset-stylesheet.css" rel="stylesheet" />
<link href="~/Browser_Local/css/table_view.css" rel="stylesheet" />
<link href="~/Browser_Local/css/simapro.css" rel="stylesheet" />
<link href="~/Browser_Local/css/datepicker.css" rel="stylesheet" />
<link href="~/Browser_Local/css/normal_table.css" rel="stylesheet" />
<link href="~/Browser_Local/css/popout.css" rel="stylesheet" />
<script src="~/Scripts/jquery-1.10.2.min.js"></script>
<link href="~/Browser_Local/css/table_edit.css" rel="stylesheet" />
<link href="~/Browser_Local/css/quality.css" rel="stylesheet" />
<link href="~/Browser_Local/css/reply_mode.css" rel="stylesheet" />
<link href="~/Browser_Local/css/loading.css" rel="stylesheet" />
<link href="~/Browser_Local/css/validate.css" rel="stylesheet" />
<link href="~/Browser_Local/css/tooltip.css" rel="stylesheet" />
<link href="~/Browser_Local/css/image.css" rel="stylesheet" />
<style>
.home_header_wrap {
width: 100%;
height: 32px;
background: #000;
}
.header_body {
/*width: 100%;
max-width: 1100px;*/
width: 1070px;
height: inherit;
margin: 0 auto;
background: #000;
}
.header_body img {
width: 20px;
height: 20px;
float: left;
position: relative;
top: 5px;
margin-right: 4px;
}
.header_logo {
width: 40px;
height: 40px;
float: left;
}
.header_logo img {
width: 100%;
height: 100%;
}
.home_user_login {
/*display: block;*/
float: right;
line-height: 32px;
color: #000;
text-decoration: none;
}
.home_culture_select {
/*display: block;*/
float: right;
color: #000;
text-decoration: none;
}
.home_culture_select a {
color: #fff;
text-decoration: none;
}
.home_user_login form {
display: inline-block;
}
.culture_panel {
position: fixed;
background: #fff;
padding: 0px 20px;
text-align: center;
display: none;
z-index: 5;
}
.culture_panel ul li {
margin: 10px 0;
}
.culture_select_btn {
display: block;
float: right;
line-height: 32px;
margin-right: 15px;
cursor: pointer;
}
.triangle-down {
width: 0;
height: 0;
border-left: 15px solid transparent;
border-right: 15px solid transparent;
border-top: 30px solid #000;
}
</style>
</head>
<body>
<div>
<nav class="navbar navbar-light bg-light nav_body">
<div class="survey_form_logo">
@if (string.IsNullOrEmpty(ViewBag.customLoginImg)) {
<img src="~/Browser_Local/img/carbon_Logo.svg"
style="border-style: none; border: none; outline: none;" />
}
</div>
<div style="position: relative;">
<div class="home_user_login">
@Html.Partial("_LoginPartial")
</div>
<div class="home_culture_select">
<div class="culture_select_btn">
<a class="dropdown-toggle">@Resource.StaticLabelCulture</a>
</div>
<div class="culture_panel">
<ul id="setculture" class="list-unstyled">
<li style="cursor: pointer;">繁體中文<input type="hidden" value="zh-tw" /></li>
<li style="cursor: pointer;">簡體中文<input type="hidden" value="zh-cn" /></li>
<li style="cursor: pointer;">English<input type="hidden" value="en-us" /></li>
</ul>
</div>
</div>
@*<div style="position: absolute; top: 7px; left: 68px; cursor: pointer;" id="toLogin">@Resource.Login</div>*@
</div>
</nav>
</div>
<div id="CarbonFootprint" class="clearfix">
<div body-height>
<nav class="navbar navbar-expand-lg navbar-light subnav_bg" style="background-color: #EBEBEB;">
<div class="survey_form_order_wrap nav-item">
<a href="@ViewBag.baseUrl/app#LCA/LCA">
<div>@Resource.StaticLabelGlobal_Interrogation</div>
</a>
</div>
@if (@User.Identity.GetUserAccountType(new WeeeDataContext()) == ACCOUNT_TYPE.FULL_FUNCTION) {
<div class="survey_form_order_wrap nav-item" style="display: inline-block;">
<a href="@ViewBag.baseUrl/app#Product/Index">
<div>@Resource.StaticLabelGlobal_Product</div>
</a>
</div>
}
<div class="survey_form_order_wrap nav-item">
<a href="@ViewBag.baseUrl/app#Fab/Index">
<div>@Resource.StaticLabelGlobal_Fab</div>
</a>
</div>
<div class="survey_form_order_wrap nav-item">
<a href="@ViewBag.baseUrl/app#Report/Index">
<div>@Resource.StaticLabelGlobal_ReportForm</div>
</a>
</div>
<div class="survey_form_order_wrap nav-item">
<a href="@ViewBag.baseUrl/app#Management/Index">
<div>@Resource.StaticLabelManagement</div>
</a>
</div>
</nav>
<div class="survey_form_body_wrap clearfix">
<div class="body">
<div class="loading_wrap" id="loindCirclePNG" style="display:none">
<div class="loading">
<img src="~/Browser_Local/img/loadingcircle.png" />
</div>
</div>
<div>
@RenderBody()
</div>
</div>
</div>
</div>
</div>
<footer class="copyright_wrap">
<div class="copyright">
<p>@Resource.StaticLabelAddress: @Resource.WeeeAddress</p>
<p>@Resource.UserPhoneNumber: (02)7728-9341 @Resource.Fax: (02)2243-2586</p>
<p>E-mail: dafen@weeerohs.com.tw</p>
<p>Copyright &copy; 2014 - @Resource.WeeeAndRoHS</p>
</div>
</footer>
@Scripts.Render("~/papaParse")
@Scripts.Render("~/setCulture")
@RenderSection("PageScripts", required: false)
<script src="~/Scripts/bootstrap-datepicker.js" type="text/javascript"></script>
<script>
var baseUrl = '@baseUrl';
(function ($) {
$(function () {
$('.culture_select_btn').click(function () {
$('body').append('<div id="overlay"></div>');
$('#overlay')
.height($(document).height)
.css({
'position': 'absolute',
'top': 0,
'left': 0,
'width': '100%',
'height': '100%'
})
.click(function () {
$('div#overlay').remove();
$('.culture_panel').css('display', 'none');
});
var display = $('.culture_panel').css('display');
if (display == 'none') {
setCulturePanel('block');
}
});
$(window).resize(function () {
var display = $('.culture_panel').css('display');
setCulturePanel(display);
});
$(window).scroll(function () {
var display = $('.culture_panel').css('display');
setCulturePanel(display);
});
var setCulturePanel = function (display) {
var targetTop = $('.home_culture_select').offset().top;
var targetLeft = $('.home_culture_select').offset().left;
var targetHeight = $('.nav_body').height();
var scrollLeft = $(window).scrollLeft();
var panelLeft = -40;
$('.culture_panel').css({
'display': display,
'left': targetLeft + panelLeft - scrollLeft,
'top': targetHeight
});
};
});
})($);
</script>
<script>
function myBrowser() { // 暂时没用到
var userAgent = navigator.userAgent; // 取得浏览器的userAgent字符串
var isOpera = userAgent.indexOf("Opera") > -1; // 判断是否Opera浏览器
var isIE = userAgent.indexOf("compatible") > -1
&& userAgent.indexOf("MSIE") > -1 && !isOpera; // 判断是否IE浏览器
var isEdge = userAgent.indexOf("Edge") > -1; // 判断是否IE的Edge浏览器
var isFF = userAgent.indexOf("Firefox") > -1; // 判断是否Firefox浏览器
var isSafari = userAgent.indexOf("Safari") > -1
&& userAgent.indexOf("Chrome") == -1; // 判断是否Safari浏览器
var isChrome = userAgent.indexOf("Chrome") > -1
&& userAgent.indexOf("Safari") > -1; // 判断Chrome浏览器
if (isIE) {
var reIE = new RegExp("MSIE (\\d+\\.\\d+);");
reIE.test(userAgent);
var fIEVersion = parseFloat(RegExp["$1"]);
if (fIEVersion == 7) {
return "IE7";
} else if (fIEVersion == 8) {
return "IE8";
} else if (fIEVersion == 9) {
return "IE9";
} else if (fIEVersion == 10) {
return "IE10";
} else if (fIEVersion == 11) {
return "IE11";
} else {
return "0";
}//IE版本过低
return "IE";
}
if (isOpera) {
return "Opera";
}
if (isEdge) {
return "Edge";
}
if (isFF) {
return "FF";
}
if (isSafari) {
return "Safari";
}
if (isChrome) {
return "Chrome";
}
}
$(document).ready(function () {
$('#toLogin').click(function () {
window.location.href = '/account/login'
})
@*if ($('.home_user_login').css('display') == 'block') {
$('#toLogin').css({ 'display':'none'})
}*@
document.getElementsByClassName("home_user_login")[0].getElementsByTagName("a")[0].style.color = '#000'
})
</script>
@*<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>*@
</body>
</html>

View File

@ -0,0 +1,356 @@
@using Resources
@using Weee.Models.ExtensionMethods
@using Weee.DAL
@using Weee.Models
@{
var baseUrl = ViewBag.baseUrl;
System.Threading.Thread.Sleep(0);
}
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
<!--meta http-equiv="X-UA-Compatible" content="IE=11" /-->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta http-equiv="cache-control" content="max-age=0" />
<meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate" />
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<link type="text/css" rel="stylesheet" href="~/Browser_Local/css/datepicker.css" />
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.7.2/font/bootstrap-icons.css">
@*<link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datetimepicker/4.7.14/js/bootstrap-datetimepicker.min.js" />*@
@*RenderSection("PageStyles", required: false)*@
@section PageStyles
{
}
@*Styles.Render("~/Browser_Local")
@Scripts.Render("~/jQuery")*@
<link href="~/Browser_Local/css/html5-doctor-reset-stylesheet.css" rel="stylesheet" />
<link href="~/Browser_Local/css/table_view.css" rel="stylesheet" />
<link href="~/Browser_Local/css/simapro.css" rel="stylesheet" />
<link href="~/Browser_Local/css/datepicker.css" rel="stylesheet" />
<link href="~/Browser_Local/css/normal_table.css" rel="stylesheet" />
<link href="~/Browser_Local/css/popout.css" rel="stylesheet" />
<script src="~/Scripts/jquery-1.10.2.min.js"></script>
<link href="~/Browser_Local/css/table_edit.css" rel="stylesheet" />
<link href="~/Browser_Local/css/quality.css" rel="stylesheet" />
<link href="~/Browser_Local/css/reply_mode.css" rel="stylesheet" />
<link href="~/Browser_Local/css/loading.css" rel="stylesheet" />
<link href="~/Browser_Local/css/validate.css" rel="stylesheet" />
<link href="~/Browser_Local/css/tooltip.css" rel="stylesheet" />
<link href="~/Browser_Local/css/image.css" rel="stylesheet" />
<style>
.home_header_wrap {
width: 100%;
height: 32px;