@model Fab2ApprovalSystem.Models.LotDisposition @{ ViewBag.Title = "LotDisposition"; } @{ Layout = "_LotDispositionLayout.cshtml"; } @**@ @* *@ @**@ @using (Html.BeginForm()) { if (@Model.CurrentStep == 0) {
} else { if (ViewBag.IsApprover == "true") {
} }
Lot Disposition
@Html.TextBoxFor(model => model.IssueID, new { id = "txtIssueID", @class = "k-textbox", disabled = "disabled" })
@Html.TextBoxFor(model => model.IssueDate, new { id = "txtIssueDate", @class = "k-textbox", disabled = "disabled" })
@(Html.Kendo().MultiSelectFor(m => m.DepartmentIDs) .Name("DepartmentIDs") .BindTo(new SelectList(ViewBag.deps, "DepartmentID", "DepartmentName")) .Value(ViewBag.Nothing) )
@*
@Html.EditorFor(model => model.MRBRequired)
*@
@Html.TextBoxFor(model => model.Title, new { id = "txtTitle", @class = "k-textbox" })
@(Html.Kendo().DropDownList() .Name("Responsibility") .BindTo(new SelectList(ViewBag.ResponsibilityList, "ResponsibilityID", "ResponsibilityName")) .Value(Model.ResponsibilityID.ToString()) )
@(Html.Kendo().DropDownList() .Name("Issue") .BindTo(new SelectList(ViewBag.ResponsibilityIssueList, "ResponsibilityIssueID", "Issue")) .Value(Model.ResponsibilityIssueID.ToString()) .CascadeFrom("ResponsibilityID") )
@Html.TextBoxFor(model => model.CANo, new { @class = "k-textbox" }) View CA
@*@(Html.Kendo().DropDownList() .Name("OriginatorID") .BindTo(new SelectList(ViewBag.OriginatorList, "OriginatorID", "OriginatorName")) )*@ @Html.TextBoxFor(model => model.OriginatorName, new { id = "OriginatorName", @class = "k-textbox", disabled = "disabled" })
@Html.TextBoxFor(model => model.SPNScrapCode, new { id = "txtSPNScrapCode", @class = "k-textbox" })
@Html.EditorFor(model => model.PERequired)
@Html.EditorFor(model => model.DispositionByOCAP)
@Html.TextAreaFor(model => model.IssueDescription, 14, 30, new { id = "txtIssueDescription", @class = "form-control", style = "font-size: 11px" })
@if (Model.CurrentStep == 0) {
@Html.TextAreaFor(model => model.ReasonForDisposition, 14, 100, new { id = "txtReasonForDisposition", @class = "form-control", style = "font-size: 11px; width: 100%" })
} else {
@Html.TextAreaFor(model => model.ReasonForDisposition, 14, 100, new { id = "txtReasonForDisposition", @class = "form-control", style = "font-size: 11px; width: 100%", @readonly = "readonly" })
}
@(Html.Kendo().Upload() .Name("files") .Async(a => a .Save("AttachSave", "LotDisposition", new { issueID = Model.IssueID }) .AutoUpload(true) ) .ShowFileList(false) .Events(events => events .Success("onFileUploadSuccess") .Upload("checkFileType") ) ) @(Html.Kendo().Grid() .Name("Attachments") .Columns(columns => { columns.Bound(a => a.AttachmentID).Visible(false); columns.Bound(a => a.IssueID).Visible(false); columns.Bound(a => a.FileName); //.ClientTemplate((@Html.ActionLink("#=FileName#", "DownloadFile", "LotDisposition", new { attachmentID = "AAA"}, null).ToHtmlString().Replace("AAA", "#=AttachmentID#"))); //.ClientTemplate("#=FileName#"); columns.Bound(a => a.FullName); columns.Bound(a => a.UploadDate).Format("{0:MM/dd/yy hh:mm:ss}"); columns.Command(command => command.Custom("View").Click("DownloadAttachment")); columns.Command(command => command.Custom("Delete").Click("deleteAttachment")); }) .Sortable() .Scrollable() .HtmlAttributes(new { style = "height:157px; width:100%; font-size: 10px" }) .DataSource(dataSource => dataSource .Ajax() //.Batch(false) .ServerOperation(false) .Events(events => events.Error("error_handler")) .Model(model => { model.Id(p => p.AttachmentID); }) .PageSize(50) .Read(read => read.Action("Attachment_Read", "LotDisposition", new { issueID = Model.IssueID })) .Destroy(destroy => destroy.Action("Attachment_Destroy", "LotDisposition")) ) )
@(Html.Kendo().Upload() .Name("Lotfile") .Messages(m => m.Select("Import Lots using an Excel file")) .Async(a => a.Save("ExcelLotOpen", "LotDisposition", new { issueID = Model.IssueID }).AutoUpload(true)) .ShowFileList(false) .Events(events => events.Success("onLotFileUploadSuccess").Error("onLotUploadError").Upload("onLotUpload")) )
@**@
@(Html.Kendo().Grid() .Name("Lots") .Columns(columns => { columns.Bound(l => l.LotID).Visible(false); columns.Bound(l => l.ReleaseCount).Visible(false); columns.Bound(l => l.ScrapCount).Visible(false); columns.Bound(l => l.LotStatusOptionID).Visible(false); columns.Bound(l => l.MRBDispoType).Visible(false); columns.Bound(l => l.IssueIDWithoutMRB).Visible(false); columns.Bound(l => l.GoodToSubmit).Visible(false); columns.Bound(l => l.LotNumber); columns.Bound(l => l.DieLotNumber); columns.Bound(p => p.MRBsLinkedToLot).ClientTemplate("#=buildLinks(MRBsLinkedToLot)#"); columns.Bound(l => l.WipPartNo); columns.Bound(l => l.LotStatusOption).ClientTemplate("#=LotStatusOption.LotStatusOption#").Width("120px"); columns.Bound(l => l.WaferCount); columns.Bound(l => l.DiePartNo); columns.Bound(l => l.DieCount); columns.Bound(l => l.NewPartNo); columns.Bound(l => l.TotalCost); columns.Bound(l => l.ProductFamily).Width("50px"); columns.Bound(l => l.Gen).Width("50px"); columns.Bound(l => l.Hexsize).Width("50px"); columns.Bound(l => l.Voltage).Width("50px"); columns.Bound(l => l.Location).Width("50px"); columns.Bound(l => l.QualityCode).Width("50px"); columns.Command(command => command.Custom("Pick Wafers").Click("showScrapReleaseForm")).Width("100px"); columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) .ClientTemplate("View").Title("History").Width("50px"); columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) .ClientTemplate("View").Title("Probe Results").Width("50px"); columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) .ClientTemplate("View").Title("Wafer Maps").Width("50px"); columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) .ClientTemplate("View").Title("Yield Param Trends").Width("75px"); columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) .ClientTemplate("Show").Title("AVI").Width("50px"); //columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) //.ClientTemplate("Show").Title("Lot Data").Width("50px"); columns.Bound(l => l.LotID).Template(@ @Html.ActionLink(@item.LotNumber.ToString(), null)) .ClientTemplate("Show").Title("Lot Data").Width("50px"); columns.Template(t => { }).HeaderTemplate("").ClientTemplate(@" button edit button delete"); }) .Editable(editable => editable.Mode(GridEditMode.InLine)) .Sortable() .Scrollable() .HtmlAttributes(new { style = "height:250px; width:100%; font-size: 10px" }) .DataSource(dataSource => dataSource .Ajax() //.Batch(false) .ServerOperation(false) .Events(e => e.Error("error_handler").RequestEnd("RefreshLotSummary")) .Model(model => { model.Id(p => p.LotID); model.Field(p => p.LotID).Editable(false); //model.Field(p => p.TotalCost).Editable(false); }) .PageSize(25) .Read(read => read.Action("EditingCustom_Read", "LotDisposition", new { issueID = Model.IssueID })) .Update(update => update.Action("EditingCustom_Update", "LotDisposition")) .Destroy(destroy => destroy.Action("EditingCustom_Destroy", "LotDisposition"))) .Resizable(resize => resize.Columns(true)) .Pageable(pageable => pageable .Refresh(true) .PageSizes(true) .ButtonCount(5)) .Events(e => e.Edit("onEdit")) )
@if (@Model.CurrentStep == 1) {
@if (ViewBag.IsApprover == "true") { }
}
@if (Session[GlobalVars.IS_ADMIN] != null) { if ((bool)Session[GlobalVars.IS_ADMIN] && (Request.IsAuthenticated)) { @(Html.Kendo().Grid() .Name("ApproversList") .Columns(columns => { columns.Bound(a => a.UserID).Visible(false); columns.Bound(a => a.ApprovalID).Visible(false); columns.Bound(a => a.FullName); columns.Bound(a => a.RoleName); columns.Bound(a => a.SubRoleName); columns.Bound(a => a.Status); columns.Bound(a => a.AssignedDate).Format("{0:MM/dd/yy hh:mm:ss}"); ; columns.Bound(a => a.CompletedDate).Format("{0:MM/dd/yy hh:mm:ss}"); ; columns.Bound(a => a.Comments); //columns.Bound(p => p.Status).ClientTemplate("#=buildButtons(Status)#"); columns.Command(command => command.Custom("Re-Assign").Click("showReAssignRole")).Width("100px"); }) .Sortable() .Scrollable() .HtmlAttributes(new { style = "height:200px; width:100%; font-size: 10px" }) .DataSource(dataSource => dataSource .Ajax() //.Batch(false) .ServerOperation(false) .Model(model => { model.Id(p => p.ApprovalID); }) .PageSize(20) .Read(read => read.Action("GetApproversList", "LotDisposition", new { issueID = Model.IssueID, step = Model.CurrentStep })) ) .Resizable(resize => resize.Columns(true)) ) } else { @(Html.Kendo().Grid() .Name("ApproversList") .Columns(columns => { columns.Bound(a => a.UserID).Visible(false); columns.Bound(a => a.ApprovalID).Visible(false); columns.Bound(a => a.FullName); columns.Bound(a => a.RoleName); columns.Bound(a => a.SubRoleName); columns.Bound(a => a.Status); columns.Bound(a => a.AssignedDate).Format("{0:MM/dd/yy hh:mm:ss}"); ; columns.Bound(a => a.CompletedDate).Format("{0:MM/dd/yy hh:mm:ss}"); ; columns.Bound(a => a.Comments); }) .Sortable() .Scrollable() .HtmlAttributes(new { style = "height:200px; width:100%; font-size: 10px" }) .DataSource(dataSource => dataSource .Ajax() //.Batch(false) .ServerOperation(false) .Model(model => { model.Id(p => p.ApprovalID); }) .PageSize(20) .Read(read => read.Action("GetApproversList", "LotDisposition", new { issueID = Model.IssueID, step = Model.CurrentStep })) ) .Resizable(resize => resize.Columns(true)) ) } }
}