Fixed bug for expanding yield columns in javascript file, added database calls for unload temps and tools by wafer size, and included unload temps and tools by wafer size in production passdown report.

This commit is contained in:
Daniel Wathen
2022-12-02 15:48:06 -07:00
parent 740896adf0
commit 3409ad58b7
7 changed files with 158 additions and 14 deletions

View File

@ -115,14 +115,24 @@ namespace ReportingServices.Controllers
report.AddToolStateByType("HTR", task7.Result);
report.ReverseLists();
int[] toolsByWaferSize = _scrapeDatabaseRepository.GetNumberOfToolsByWaferSize();
report.NumberOfToolsWaferSize6IN = toolsByWaferSize[0];
report.NumberOfToolsWaferSize8IN = toolsByWaferSize[1];
List<ManualReportEntriesByDay> entries = _jsonFileHandler.LoadJSONFile<List<ManualReportEntriesByDay>>(_dailyRptFileName);
report.Entries = entries;
int[] singleLoadLocks = _scrapeDatabaseRepository.GetNumberOfSingleLoadLocks();
report.Entries[_reportIndex].Entries.SingleLoadLockASM = singleLoadLocks[0];
report.Entries[_reportIndex].Entries.SingleLoadLockHTR = singleLoadLocks[1];
report.Entries[_reportIndex].Entries.ASMSingleLoadLock = singleLoadLocks[0];
report.Entries[_reportIndex].Entries.HTRSingleLoadLock = singleLoadLocks[1];
int[] unloadTempsLessThan700 = _scrapeDatabaseRepository.GetNumberOfToolUnloadTempsLessThan700();
report.Entries[_reportIndex].Entries.ASMUnloadTempsLessThan700 = unloadTempsLessThan700[0];
report.Entries[_reportIndex].Entries.HTRUnloadTempsLessThan700 = unloadTempsLessThan700[1];
return report;
}

View File

@ -2,6 +2,7 @@
using ReportingServices.Models.PlanningReport;
using ReportingServices.ReportingObjects;
using System.Data;
using System.Text.RegularExpressions;
namespace ReportingServices.Dependency_Injections
{
@ -125,6 +126,43 @@ namespace ReportingServices.Dependency_Injections
return weeklyPartChanges;
}
public int[] GetNumberOfToolsByWaferSize()
{
int[] singleLoadLocks = new int[2];
OpenConnection();
SqlCommand cmd = _connection.CreateCommand();
string query = "SELECT " +
" SUSC_POCKET_SIZE, " +
" COUNT(SUSC_POCKET_SIZE) " +
" FROM REACTOR " +
" WHERE REACT_ASSIGNMENT IS NOT NULL " +
" AND REACT_ASSIGNMENT <> 'Out of Service' " +
" AND REACT_ASSIGNMENT <> '' " +
"GROUP BY SUSC_POCKET_SIZE";
cmd.CommandText = query;
using (SqlDataReader reader = cmd.ExecuteReader())
{
reader.Read();
singleLoadLocks[0] = int.Parse(reader[1].ToString());
reader.Read();
singleLoadLocks[1] = int.Parse(reader[1].ToString());
}
cmd.Dispose();
CloseConnection();
return singleLoadLocks;
}
public int[] GetNumberOfSingleLoadLocks()
{
int[] singleLoadLocks = new int[2];
@ -160,5 +198,39 @@ namespace ReportingServices.Dependency_Injections
return singleLoadLocks;
}
public int[] GetNumberOfToolUnloadTempsLessThan700()
{
int[] unloadTempTools = new int[2];
OpenConnection();
SqlCommand cmd = _connection.CreateCommand();
string query = "SELECT REACTOR_TYPE, COUNT(DISTINCT(REACTOR)) AS ULT FROM RDS " +
"INNER JOIN RDS_LAYER lay ON lay.RDS_NO = SEQ " +
"WHERE DATE_OUT > DATEADD(DAY, -1, SYSDATETIME()) " +
" AND UL_TEMP< 700 " +
"GROUP BY REACTOR_TYPE";
cmd.CommandText = query;
using (SqlDataReader reader = cmd.ExecuteReader())
{
reader.Read();
unloadTempTools[0] = int.Parse(reader[1].ToString());
reader.Read();
unloadTempTools[1] = int.Parse(reader[1].ToString());
}
cmd.Dispose();
CloseConnection();
return unloadTempTools;
}
}
}

View File

@ -10,6 +10,8 @@ namespace ReportingServices.Dependency_Injections
public List<ScrapByDay> GetScrapByDay(List<ReactorOutsByRDS> outs);
public List<ReactorPSNWORuns> GetReactorPSNWORuns(string startDate, string endDate);
public int GetNumberOfPartChanges(string startDate, string endDate);
public int[] GetNumberOfToolsByWaferSize();
public int[] GetNumberOfSingleLoadLocks();
public int[] GetNumberOfToolUnloadTempsLessThan700();
}
}

View File

@ -10,6 +10,8 @@ namespace ReportingServices.Models.ProductionReport
public Dictionary<string, List<EquipmentStateByDay>> ToolAvailibilityByType { get; set; }
public Dictionary<string, ToolStateByType> ToolStateByType { get; set; }
public List<ManualReportEntriesByDay> Entries { get; set; }
public int NumberOfToolsWaferSize6IN { get; set; }
public int NumberOfToolsWaferSize8IN { get; set; }
public DailyReport()
{

View File

@ -17,7 +17,9 @@
public string BottleChanges { get; set; }
public string DailyPartChanges { get; set; }
public string WeeklyPartChanges { get; set; }
public int SingleLoadLockASM { get; set; }
public int SingleLoadLockHTR { get; set; }
public int ASMSingleLoadLock { get; set; }
public int HTRSingleLoadLock { get; set; }
public int ASMUnloadTempsLessThan700 { get; set; }
public int HTRUnloadTempsLessThan700 { get; set; }
}
}

View File

@ -19,6 +19,9 @@
int ASMSLL = 0;
int HTRSLL = 0;
int ASMUnloadTemps = 0;
int HTRUnloadTemps = 0;
int reportIndex = (int)DateTime.Now.DayOfWeek;
ManualReportEntries rpt = Model.Entries[reportIndex].Entries;
@ -135,7 +138,12 @@
<td>Before Scrap</td>
</tr>
<tr>
<td scope="row" id="expandYield">Actual Yielded Wafers Out &nbsp;&nbsp;&nbsp; <img src="~/Images/plusIcon.png" width="20" style="padding-bottom: 3px" onclick="expandYield()" id="yieldImage" /></td>
<td scope="row" id="expandYield">
Actual Yielded Wafers Out &nbsp;&nbsp;&nbsp;
<button class="btn btn-default" onclick="expandYield()">
<img src="~/Images/plusIcon.png" width="20" style="padding-bottom: 3px" id="yieldImage" />
</button>
</td>
@for (int i = 0; i < 7; i++)
{
if (i < Model.OutsByDay.Count)
@ -407,13 +415,19 @@
</div>
<ul>
<li>Application ENG (0):</li>
<li>Reactors (Capacity )</li>
<li>Reactors (Capacity @(Model.NumberOfToolsWaferSize6IN + Model.NumberOfToolsWaferSize8IN))
<ul>
<li>150mm - @Model.NumberOfToolsWaferSize6IN</li>
<li>200mm - @Model.NumberOfToolsWaferSize8IN</li>
</ul>
</li>
<li>Scheduled Reactors: </li>
<li>Dual Layer Reactors</li>
<li>Engineering Focus Tools (Down > 12 hours)</li>
<li>Engineering Focus Tools (Down > 12 hours)
<ul>
<li>@string.Join(",", toolsDownGreaterThan12Hours)</li>
</ul>
</li>
<li>Metrology Down (): </li>
<li>Cleans (): </li>
</ul>
@ -527,9 +541,9 @@
{
int index = i == 6 ? 0 : i + 1;
<td>@Model.Entries[index].Entries.SingleLoadLockASM</td>
<td>@Model.Entries[index].Entries.ASMSingleLoadLock</td>
ASMSLL += @Model.Entries[index].Entries.SingleLoadLockASM;
ASMSLL += @Model.Entries[index].Entries.ASMSingleLoadLock;
}
else
{
@ -547,9 +561,9 @@
{
int index = i == 6 ? 0 : i + 1;
<td>@Model.Entries[index].Entries.SingleLoadLockHTR</td>
<td>@Model.Entries[index].Entries.HTRSingleLoadLock</td>
HTRSLL += @Model.Entries[index].Entries.SingleLoadLockHTR;
HTRSLL += @Model.Entries[index].Entries.HTRSingleLoadLock;
}
else
{
@ -559,6 +573,46 @@
<td>@(HTRSLL / count)</td>
<td>0</td>
</tr>
<tr>
<td scope="row">ASMs &lt;700C (Unload Temps)</td>
@for (int i = 0; i < 7; i++)
{
if (i < Model.Entries.Count)
{
int index = i == 6 ? 0 : i + 1;
<td>@Model.Entries[index].Entries.ASMUnloadTempsLessThan700</td>
ASMUnloadTemps += @Model.Entries[index].Entries.ASMUnloadTempsLessThan700;
}
else
{
<td></td>
}
}
<td>@(ASMUnloadTemps / count)</td>
<td>0</td>
</tr>
<tr>
<td scope="row">HTRs &lt;700C (Unload Temps)</td>
@for (int i = 0; i < 7; i++)
{
if (i < Model.Entries.Count)
{
int index = i == 6 ? 0 : i + 1;
<td>@Model.Entries[index].Entries.HTRUnloadTempsLessThan700</td>
HTRUnloadTemps += @Model.Entries[index].Entries.HTRUnloadTempsLessThan700;
}
else
{
<td></td>
}
}
<td>@(HTRUnloadTemps / count)</td>
<td>0</td>
</tr>
</tbody>
</table>
</div>

View File

@ -144,6 +144,8 @@ function expandYield() {
yieldDivs[i].classList.toggle("hidden");
}
var source = document.getElementById("yieldImage").src;
if (source.substring(source.indexOf("Images/") + 7) == "plusIcon.png")
document.getElementById("yieldImage").src = "../Images/minusIcon.png";
else