Added View, Recipe Paramaters and Export
This commit is contained in:
@ -60,17 +60,17 @@ function DisplayWSMessage(severity, description, e, ex) {
|
||||
}
|
||||
|
||||
$("#spanMessageText").text(description);
|
||||
if (e.status === 403) {
|
||||
if (e !== null && e.status === 403) {
|
||||
$("#spanMessageText").append("<br /><b>" + forbiddenMsg + "</b>");
|
||||
}
|
||||
else if (e.status === 444) {
|
||||
else if (e !== null && e.status === 444) {
|
||||
$("#MessageModalContent").removeClass("modal-content-error");
|
||||
$("#MessageModalContent").addClass("modal-content-info");
|
||||
$("#MessageModalTitle").text("");
|
||||
$("#spanMessageText").text(expiredMsg);
|
||||
}
|
||||
else if (e.responseText !== null) {
|
||||
if (e.responseText !== "") {
|
||||
else if (e !== null && e.responseText !== null) {
|
||||
if (e !== null && e.responseText !== "") {
|
||||
try {
|
||||
wsError = jQuery.parseJSON(e.responseText);
|
||||
if (wsError.Message !== null)
|
||||
@ -95,7 +95,7 @@ function DisplayWSMessage(severity, description, e, ex) {
|
||||
else {
|
||||
|
||||
var msg = description + "\r\n";
|
||||
if (e.responseText !== null) {
|
||||
if (e !== null && e.responseText !== null) {
|
||||
if (e.responseText !== "") {
|
||||
wsError = jQuery.parseJSON(e.responseText);
|
||||
if (wsError.ExceptionMessage !== null) {
|
||||
@ -103,7 +103,7 @@ function DisplayWSMessage(severity, description, e, ex) {
|
||||
}
|
||||
}
|
||||
}
|
||||
if (e.status === 403)
|
||||
if (e !== null && e.status === 403)
|
||||
msg += forbiddenMsg;
|
||||
|
||||
alert(msg);
|
||||
|
@ -217,12 +217,16 @@ function loadHeaderGridRunInfo() {
|
||||
function disableHeaderButtonsRunInfo() {
|
||||
$("#GetDataButton").prop("disabled", true);
|
||||
$("#ReviewButton").prop("disabled", true);
|
||||
$("#RecipeParametersButton").prop("disabled", true);
|
||||
$("#ViewButton").prop("disabled", true);
|
||||
$("#PinButton").prop("disabled", true);
|
||||
}
|
||||
|
||||
function enableHeaderButtonsRunInfo() {
|
||||
$("#GetDataButton").prop("disabled", false);
|
||||
$("#ReviewButton").prop("disabled", false);
|
||||
$("#RecipeParametersButton").prop("disabled", false);
|
||||
$("#ViewButton").prop("disabled", false);
|
||||
$("#PinButton").prop("disabled", false);
|
||||
}
|
||||
|
||||
@ -459,10 +463,151 @@ function reviewButtonRunInfo() {
|
||||
});
|
||||
}
|
||||
|
||||
function recipeParametersButtonRunInfo() {
|
||||
var selectedRow = $("#HeaderGrid").data("igGridSelection").selectedRow();
|
||||
if (selectedRow !== null) {
|
||||
loadDetailsRunInfo();
|
||||
$("#RecipeParametersButton").prop("disabled", true);
|
||||
var rowData = $("#HeaderGrid").data("igGrid").dataSource.dataView()[selectedRow.index];
|
||||
var stringified = JSON.stringify(rowData);
|
||||
stringified = stringified.replace(/"Tool":/gm, '"MesEntity":');
|
||||
stringified = stringified.replace(/"Equipment ID":/gm, '"MesEntity":');
|
||||
var jsonObject = JSON.parse(stringified);
|
||||
DisplayWSMessage("info", "Recipe Parameters - Work In Progress ***", null);
|
||||
$("#ModalHeaderGrid").igGrid({
|
||||
dataSource: jsonObject,
|
||||
dataSourceType: 'json',
|
||||
features: [
|
||||
{ name: 'Resizing' }
|
||||
],
|
||||
columns: [
|
||||
{ headerText: "Tool", key: "MesEntity", dataType: "string", width: "10%" },
|
||||
{ key: "Reactor", dataType: "string", width: "10%" },
|
||||
{ key: "RDS", dataType: "string", width: "10%" },
|
||||
{ key: "PSN", dataType: "string", width: "10%" },
|
||||
{ key: "Layer", dataType: "string", width: "10%" },
|
||||
{ key: "Zone", dataType: "string", width: "10%" }
|
||||
]
|
||||
});
|
||||
var gridCreated = $("#ModalBodyGrid").data("igGrid");
|
||||
if (gridCreated)
|
||||
$("#ModalBodyGrid").igGrid("destroy");
|
||||
$.getJSON('http://messa020ec.ec.local/api/oiWizard/materials/rds/' + jsonObject.RDS, function (data) {
|
||||
$("#RecipeParametersButton").prop("disabled", false);
|
||||
var text = "";
|
||||
for (var i = 0; i < data.rds.rdsLayers.length; i++) {
|
||||
text = text
|
||||
+ data.rds.rdsLayers[i].EpiTime
|
||||
+ "\t" + data.rds.rdsLayers[i].EpiH2Flow
|
||||
+ "\t" + data.rds.rdsLayers[i].TCSFlow
|
||||
+ "\t" + data.rds.rdsLayers[i].DiluentAdjParam
|
||||
+ "\t" + data.rds.rdsLayers[i].EpiH2Flow
|
||||
+ "\t" + data.rds.rdsLayers[i].DopantFlow
|
||||
+ "\t" + data.rds.rdsLayers[i].FOffset
|
||||
+ "\t" + data.rds.rdsLayers[i].SOffset
|
||||
+ "\t" + data.rds.rdsLayers[i].ROffset
|
||||
+ "\t" + data.rds.rdsLayers[i].SuscEtch
|
||||
+ "\r"
|
||||
}
|
||||
$("#textareaClipboard").val(text);
|
||||
$("#ModalBodyGrid").igGrid({
|
||||
dataSource: data.rds.rdsLayers,
|
||||
features: [
|
||||
{ name: 'Resizing' }
|
||||
],
|
||||
columns: [
|
||||
{ headerText: "Dep Time", key: "EpiTime", dataType: "number", width: "10%" },
|
||||
{ headerText: "H2", key: "EpiH2Flow", dataType: "number", width: "10%" },
|
||||
{ headerText: "TCS", key: "TCSFlow", dataType: "number", width: "10%" },
|
||||
{ headerText: "DIL", key: "DiluentAdjParam", dataType: "string", width: "10%" },
|
||||
{ headerText: "SRC", key: "EpiH2Flow", dataType: "number", width: "10%" },
|
||||
{ headerText: "INJ", key: "DopantFlow", dataType: "string", width: "10%" },
|
||||
{ headerText: "F", key: "FOffset", dataType: "string", width: "10%" },
|
||||
{ headerText: "S", key: "SOffset", dataType: "string", width: "10%" },
|
||||
{ headerText: "R", key: "ROffset", dataType: "string", width: "10%" },
|
||||
{ headerText: "Susc Etch", key: "SuscEtch", dataType: "string", width: "10%" },
|
||||
],
|
||||
responseDataKey: "Results",
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function viewButtonRunInfo() {
|
||||
var selectedRow = $("#HeaderGrid").data("igGridSelection").selectedRow();
|
||||
if (selectedRow !== null) {
|
||||
$("#ViewButton").prop("disabled", true);
|
||||
loadDetailsRunInfo();
|
||||
var rowData = $("#HeaderGrid").data("igGrid").dataSource.dataView()[selectedRow.index];
|
||||
var stringified = JSON.stringify(rowData);
|
||||
stringified = stringified.replace(/"Tool":/gm, '"MesEntity":');
|
||||
stringified = stringified.replace(/"Equipment ID":/gm, '"MesEntity":');
|
||||
var jsonObject = JSON.parse(stringified);
|
||||
DisplayWSMessage("info", "View", null);
|
||||
$("#ModalHeaderGrid").igGrid({
|
||||
dataSource: jsonObject,
|
||||
dataSourceType: 'json',
|
||||
features: [
|
||||
{ name: 'Resizing' }
|
||||
],
|
||||
columns: [
|
||||
{ headerText: "Tool", key: "MesEntity", dataType: "string", width: "10%" },
|
||||
{ key: "Reactor", dataType: "string", width: "10%" },
|
||||
{ key: "RDS", dataType: "string", width: "10%" },
|
||||
{ key: "PSN", dataType: "string", width: "10%" },
|
||||
{ key: "Layer", dataType: "string", width: "10%" },
|
||||
{ key: "Zone", dataType: "string", width: "10%" }
|
||||
]
|
||||
});
|
||||
var gridCreated = $("#ModalBodyGrid").data("igGrid");
|
||||
if (gridCreated)
|
||||
$("#ModalBodyGrid").igGrid("destroy");
|
||||
var headerId = $("#HeaderId").text();
|
||||
var toolTypeID = $("#ToolTypeID").text();
|
||||
var detailsURL = _apiUrl + "/tooltypes/" + toolTypeID + "/headers/" + headerId + "/data";
|
||||
$.getJSON(detailsURL, function (data) {
|
||||
var obj = {};
|
||||
var text = "";
|
||||
for (var i = 0; i < data.Results.length && i < 9; i++) {
|
||||
if (data.Results[i].Thickness) {
|
||||
text = text + data.Results[i].Thickness + "\t";
|
||||
obj['Point' + (i + 1)] = data.Results[i].Thickness;
|
||||
}
|
||||
else if (data.Results[i].Rs) {
|
||||
text = text + data.Results[i].Rs + "\t";
|
||||
obj['Point' + (i + 1)] = data.Results[i].Rs;
|
||||
}
|
||||
}
|
||||
text = text + "\r";
|
||||
$("#textareaClipboard").val(text);
|
||||
$("#ModalBodyGrid").igGrid({
|
||||
dataSource: obj,
|
||||
dataSourceType: 'json',
|
||||
features: [
|
||||
{ name: 'Resizing' }
|
||||
],
|
||||
columns: [
|
||||
{ headerText: "Point 1", key: "Point1", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 2", key: "Point2", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 3", key: "Point3", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 4", key: "Point4", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 5", key: "Point5", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 6", key: "Point6", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 7", key: "Point7", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 8", key: "Point8", dataType: "string", width: "10%" },
|
||||
{ headerText: "Point 9", key: "Point9", dataType: "string", width: "10%" },
|
||||
]
|
||||
});
|
||||
$("#ViewButton").prop("disabled", false);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function pinButtonRunInfo() {
|
||||
var toolTypeId = $("#ToolTypeID").text();
|
||||
var selectedRow = $("#HeaderGrid").data("igGridSelection").selectedRow();
|
||||
if (selectedRow !== null) {
|
||||
loadDetailsRunInfo();
|
||||
$("#PinButton").prop("disabled", true);
|
||||
var rowData = $("#HeaderGrid").data("igGrid").dataSource.dataView()[selectedRow.index];
|
||||
var stringified = JSON.stringify(rowData);
|
||||
@ -474,10 +619,13 @@ function pinButtonRunInfo() {
|
||||
url: _apiUrl + '/pin/' + toolTypeId + "/markAsPinned",
|
||||
data: jsonObject,
|
||||
success: function (e) {
|
||||
var gridCreated = $("#ModalBodyGrid").data("igGrid");
|
||||
if (gridCreated)
|
||||
$("#ModalBodyGrid").igGrid("destroy");
|
||||
DisplayWSMessage("info", "Marked as pinned", e);
|
||||
// DisplayWSMessage("info", stringified, e);
|
||||
$("#PinButton").prop("disabled", false);
|
||||
$.getJSON(_apiUrl + '/pin/' + toolTypeId + "/pinned?biorad_id=" + _BioRadId + "&cde_id=" + _CdeId + "&rds=" + rowData.RDS, function (data) {
|
||||
$.getJSON(_apiUrl + '/pin/' + toolTypeId + "/pinned?biorad_id=" + _BioRadId + "&cde_id=" + _CdeId + "&rds=" + jsonObject.RDS, function (data) {
|
||||
$("#ModalHeaderGrid").igGrid({
|
||||
dataSource: data,
|
||||
features: [
|
||||
@ -497,7 +645,17 @@ function pinButtonRunInfo() {
|
||||
});
|
||||
var text = "";
|
||||
for (var i = 0; i < data.Results.length; i++) {
|
||||
text = text + data.Results[i].Point1 + "\t" + data.Results[i].Point2 + "\t" + data.Results[i].Point3 + "\t" + data.Results[i].Point4 + "\t" + data.Results[i].Point5 + "\t" + data.Results[i].Point6 + "\t" + data.Results[i].Point7 + "\t" + data.Results[i].Point8 + "\t" + data.Results[i].Point9 + "\r";
|
||||
text = text
|
||||
+ data.Results[i].Point1
|
||||
+ "\t" + data.Results[i].Point2
|
||||
+ "\t" + data.Results[i].Point3
|
||||
+ "\t" + data.Results[i].Point4
|
||||
+ "\t" + data.Results[i].Point5
|
||||
+ "\t" + data.Results[i].Point6
|
||||
+ "\t" + data.Results[i].Point7
|
||||
+ "\t" + data.Results[i].Point8
|
||||
+ "\t" + data.Results[i].Point9
|
||||
+ "\r";
|
||||
}
|
||||
$("#textareaClipboard").val(text);
|
||||
$("#ModalBodyGrid").igGrid({
|
||||
@ -604,6 +762,8 @@ function initRunInfo(apiUrl, initialToolTypeID, initialHeaderId, initialHeaderAt
|
||||
$("#LoadHeadersButton").click(loadHeaderGridRunInfo);
|
||||
$("#GetDataButton").click(loadDetailsRunInfo);
|
||||
$("#ReviewButton").click(reviewButtonRunInfo);
|
||||
$("#RecipeParametersButton").click(recipeParametersButtonRunInfo);
|
||||
$("#ViewButton").click(viewButtonRunInfo);
|
||||
$("#PinButton").click(pinButtonRunInfo);
|
||||
$("#OIExportButton").click(oiExportButtonRunInfo);
|
||||
setInterval(function () {
|
||||
@ -632,6 +792,6 @@ function copy() {
|
||||
copyText.select();
|
||||
copyText.setSelectionRange(0, 99999); // For mobile devices
|
||||
|
||||
// Copy the text inside the text field
|
||||
// Copy the text inside the text field
|
||||
navigator.clipboard.writeText(copyText.value);
|
||||
}
|
Reference in New Issue
Block a user