diff --git a/AMESCoreStudio.Web/Resources/Localization/CustomStringLocalizerFactory.cs b/AMESCoreStudio.Web/Resources/Localization/CustomStringLocalizerFactory.cs index 5bdf8e1..bd4c8d9 100644 --- a/AMESCoreStudio.Web/Resources/Localization/CustomStringLocalizerFactory.cs +++ b/AMESCoreStudio.Web/Resources/Localization/CustomStringLocalizerFactory.cs @@ -24,6 +24,11 @@ namespace AMESCoreStudio.Web.Resources.Localization { baseName = "Views.PCS.Shared"; } + // 自訂邏輯:如果是 Views.RPT,或是 Controllers.RPT,使用 Shared 資源 + if (baseName.Contains("Views.RPT") || baseName.Contains("Controllers.RPT")) + { + baseName = "Views.RPT.Shared"; + } return _baseFactory.Create(baseName, location); } } diff --git a/AMESCoreStudio.Web/Resources/Views/RPT/Shared.en-US.resx b/AMESCoreStudio.Web/Resources/Views/RPT/Shared.en-US.resx new file mode 100644 index 0000000..6c7471f --- /dev/null +++ b/AMESCoreStudio.Web/Resources/Views/RPT/Shared.en-US.resx @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Current Work Order + + + Planned Quantity + + + Line Head Dashboard + + + Line Head Dashboard (Carousel) + + + Engineering Number + + + Production Process + + + Production Line + + + Query + + + Start Time + + + Current Time + + + Standard CT + + + Total Input + + + Station + + + Expected<br/>Input Quantity + + + Actual<br/>Input Quantity + + + Production<br/>Efficiency + + + Line + + \ No newline at end of file diff --git a/AMESCoreStudio.Web/Resources/Views/RPT/Shared.zh-TW.resx b/AMESCoreStudio.Web/Resources/Views/RPT/Shared.zh-TW.resx new file mode 100644 index 0000000..9fd5cb3 --- /dev/null +++ b/AMESCoreStudio.Web/Resources/Views/RPT/Shared.zh-TW.resx @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 當前工單 + + + 計畫產量 + + + 線頭看板 + + + 生產效率 + + + 實際投入數量 + + + 生產線別 + + + 線頭看板(輪播) + + + 查詢 + + + 生產製程 + + + 開工時間 + + + 目前時間 + + + 標準工時 + + + 累計投入數 + + + 站別 + + + 應投入數量 + + + 工程編號 + + + 目前線別 + + \ No newline at end of file diff --git a/AMESCoreStudio.Web/Views/RPT/RPT004.cshtml b/AMESCoreStudio.Web/Views/RPT/RPT004.cshtml index de2492c..8496d64 100644 --- a/AMESCoreStudio.Web/Views/RPT/RPT004.cshtml +++ b/AMESCoreStudio.Web/Views/RPT/RPT004.cshtml @@ -1,7 +1,9 @@ @model AMESCoreStudio.WebApi.DTO.AMES.RPT004ViewDto +@using Microsoft.AspNetCore.Mvc.Localization +@inject IViewLocalizer Localizer @{ - ViewData["Title"] = "線頭看板"; + ViewData["Title"] = @Localizer["LineHeadDashboard"]; Layout = "~/Views/Shared/_AMESLayout.cshtml"; } @@ -72,18 +74,18 @@
- +
- +
@@ -91,15 +93,15 @@
- +
- +
- +
@@ -107,11 +109,11 @@
- +
- +
@@ -119,15 +121,15 @@
- +
- +
- +
@@ -136,8 +138,8 @@
-
-

應投入數量

+
+

@Localizer["ExpectedInputQuantity"]

@@ -152,8 +154,8 @@
-
-

實際投入數量

+
+

@Localizer["ActualInputQuantity"]

@@ -168,8 +170,8 @@
-
-

生產效率

+
+

@Localizer["ProductionEfficiency"]

diff --git a/AMESCoreStudio.Web/Views/RPT/RPT005.cshtml b/AMESCoreStudio.Web/Views/RPT/RPT005.cshtml index eabe04c..e92ef56 100644 --- a/AMESCoreStudio.Web/Views/RPT/RPT005.cshtml +++ b/AMESCoreStudio.Web/Views/RPT/RPT005.cshtml @@ -1,7 +1,9 @@ @model AMESCoreStudio.WebApi.DTO.AMES.RPT004ViewDto +@using Microsoft.AspNetCore.Mvc.Localization +@inject IViewLocalizer Localizer @{ - ViewData["Title"] = "線頭看板(輪播)"; + ViewData["Title"] = @Localizer["LineHeadDashboardCarousel"]; Layout = "~/Views/Shared/_AMESLayout.cshtml"; } @@ -75,18 +77,18 @@
- +
- +
@@ -94,15 +96,15 @@
- +
- +
- +
@@ -110,11 +112,11 @@
- +
- +
@@ -122,15 +124,15 @@
- +
- +
- +
@@ -139,8 +141,8 @@
-
-

應投入數量

+
+

@Localizer["ExpectedInputQuantity"]

@@ -155,8 +157,8 @@
-
-

實際投入數量

+
+

@Localizer["ActualInputQuantity"]

@@ -171,8 +173,8 @@
-
-

生產效率

+
+

@Localizer["ProductionEfficiency"]