My problem is that our application page has an "Edit" button on it. The idea is that when a user navigates to an "Edit" page all the contents of the page are disabled. The user needs to click the "Edit" button which puts the page in "edit" mode (enables all the controls including the RadGrid that will be used to upload files). Clicking the "Edit" button causes the "conditionalPostback" function to fire. Once the page is in "edit" mode I try to insert a file via the RadGrid and the conditionalPostback does not occur when I click the Insert button (radUpload.UploadedFiles.Count = 0).
Do I somehow need to "reset" the ClientEvents-OnRequestStart event on my RadAjaxManager in this scenario?
Does anyone know what's going wrong here and how to fix this problem?
Below is the aspx code:
<
html
xmlns
=
"http://www.w3.org/1999/xhtml"
>
<
head
runat
=
"server"
>
<
title
></
title
>
</
head
>
<
body
>
<
form
id
=
"form1"
runat
=
"server"
>
<
telerik:RadScriptManager
ID
=
"radScriptManager"
runat
=
"server"
/>
<
telerik:RadCodeBlock
ID
=
"RadCodeBlock1"
runat
=
"server"
>
<
script
type
=
"text/javascript"
>
function conditionalPostback(sender, args) {
alert('conditionalPostback');
var theRegexp = new RegExp("\.RadButtonInsert$", "ig");
if (args.get_eventTarget().match(theRegexp)) {
var upload = $find(window['UploadId']);
if (upload.getFileInputs()[0].value != "") {
args.set_enableAjax(false);
}
}
}
</
script
>
</
telerik:RadCodeBlock
>
<
telerik:RadAjaxManager
ID
=
"radAjaxManager"
runat
=
"server"
ClientEvents-OnRequestStart
=
"conditionalPostback"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"radGridAttachments"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"radGridAttachments"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"radButtonEdit"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelToolbar"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelContent"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"radButtonSave"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelToolbar"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelContent"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
<
asp:Panel
runat
=
"server"
>
<
asp:Panel
ID
=
"panelToolbar"
runat
=
"server"
>
<
telerik:RadButton
ID
=
"radButtonEdit"
runat
=
"server"
Text
=
"Edit"
CausesValidation
=
"false"
OnClick
=
"radButtonEdit_Click"
/>
<
telerik:RadButton
ID
=
"radButtonSave"
runat
=
"server"
Text
=
"Save"
CausesValidation
=
"true"
OnClick
=
"radButtonSave_Click"
/>
</
asp:Panel
>
<
asp:Panel
ID
=
"panelContent"
runat
=
"server"
>
<
telerik:RadPanelBar
ID
=
"radPanelBarAttachments"
runat
=
"server"
Width
=
"100%"
>
<
Items
>
<
telerik:RadPanelItem
Text
=
"Attachments"
Expanded
=
"true"
>
<
ContentTemplate
>
<
telerik:RadGrid
ID
=
"radGridAttachments"
runat
=
"server"
AutoGenerateColumns
=
"false"
Enabled
=
"false"
OnNeedDataSource
=
"radGridAttachments_NeedDataSource"
OnItemDataBound
=
"radGridAttachments_ItemDataBound"
OnInsertCommand
=
"radGridAttachments_InsertCommand"
OnDeleteCommand
=
"radGridAttachments_DeleteCommand"
OnItemCommand
=
"radGridAttachments_ItemCommand"
>
<
MasterTableView
CommandItemDisplay
=
"Top"
DataKeyNames
=
"ID"
>
<
CommandItemTemplate
>
<
telerik:RadButton
ID
=
"radButtonAdd"
runat
=
"server"
Text
=
"Add New Record"
CommandName
=
"InitInsert"
Visible='<%# !radGridAttachments.MasterTableView.IsItemInserted %>' ButtonType="LinkButton">
</
telerik:RadButton
>
</
CommandItemTemplate
>
<
Columns
>
<
telerik:GridBoundColumn
DataField
=
"ID"
HeaderText
=
"ID"
ReadOnly
=
"true"
/>
<
telerik:GridBoundColumn
UniqueName
=
"FileName"
DataField
=
"FileName"
HeaderText
=
"File Name"
ReadOnly
=
"true"
/>
<
telerik:GridTemplateColumn
HeaderText
=
"Attachment"
>
<
ItemTemplate
>
<
asp:LinkButton
ID
=
"ViewAttachmentLinkButton"
runat
=
"server"
CommandName
=
"ViewAttachment"
>View</
asp:LinkButton
>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
telerik:GridButtonColumn
UniqueName
=
"DeleteColumn"
ButtonType
=
"PushButton"
Text
=
"Delete"
CommandName
=
"Delete"
/>
</
Columns
>
<
EditFormSettings
EditFormType
=
"Template"
>
<
FormTemplate
>
<
telerik:RadUpload
ID
=
"RadUpload1"
runat
=
"server"
InitialFileInputsCount
=
"1"
MaxFileInputsCount
=
"1"
ControlObjectsVisibility
=
"None"
/>
<
telerik:RadButton
ID
=
"RadButtonInsert"
runat
=
"server"
Text='<%# (Container is GridEditFormInsertItem) ? "Insert" : "Update" %>' CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>' />
<
telerik:RadButton
ID
=
"RadButtonCancel"
runat
=
"server"
Text
=
"Cancel"
CausesValidation
=
"false"
CommandName
=
"Cancel"
/>
</
FormTemplate
>
</
EditFormSettings
>
</
MasterTableView
>
</
telerik:RadGrid
>
</
ContentTemplate
>
</
telerik:RadPanelItem
>
</
Items
>
</
telerik:RadPanelBar
>
</
asp:Panel
>
</
asp:Panel
>
</
form
>
</
body
>
</
html
>
Here is the code behind for the grid's ItemDataBound event:
protected
void
radGridAttachments_ItemDataBound(
object
sender, GridItemEventArgs e)
{
if
(e.Item
is
GridEditableItem && e.Item.IsInEditMode)
{
RadUpload radUpload = (RadUpload)e.Item.FindControl(
"RadUpload1"
);
radAjaxManager.ResponseScripts.Add(String.Format(
"window['UploadId'] = '{0}';"
, radUpload.ClientID));
}
}
3 Answers, 1 is accepted
The experienced behavior is caused by a known issue with the RadAjaxManager when ajaxifying panels. Please try to change your setting such that the button will update the RadGrid and not its wrapping panel.
<
telerik:RadAjaxManager
ID
=
"radAjaxManager"
runat
=
"server"
ClientEvents-OnRequestStart
=
"conditionalPostback"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"radGridAttachments"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"radGridAttachments"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"radButtonEdit"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelToolbar"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelContent"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"radButtonSave"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"panelToolbar"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"radGridAttachments
"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
Regards,
Dimitar Terziev
the Telerik team
Hi Chad..Please Help me as..Telerik RadGrid File Upload inside formview Not working in Chrome and working fine in i.explore ..
here is my Ajax Setting
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" EnableAJAX ="true">
<ClientEvents OnRequestStart="requestStart" />
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RadcboAlias">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RadcboVendor" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="btnSearch">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsSummaryRadGrid"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsRadGrid" LoadingPanelID="RadAjaxLoadingPanel1"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView"/>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAuditsSummaryRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsRadGrid"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAuditsRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAuditFormView">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsSummaryRadGrid"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsRadGrid" LoadingPanelID="RadAjaxLoadingPanel1"/>
<%--Test--%>
<%--<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />--%>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
Here is my .aspx
<%@ Page Language="C#" AutoEventWireup="true" Inherits="MCCAuditPage" Codebehind="MCCAudit.aspx.cs" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<link id="Link2" href="~/Skins/Vista/Grid.Vista.css" rel="stylesheet" type="text/css" runat ="server" />
<title>MCC Assessments</title>
<style type="text/css">
.RadGrid_Vista .rgSelectedRow
{
background:url('Grid/sprite.gif') 0 -800px repeat-x #dcf1fc !important;
}
</style>
<style type="text/css">
.HyperStyle a
{
color: Blue !important;
text-decoration:none !important;
}
</style>
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
<script type= "text/javascript" >
function Expand(sender, arge) {
sender.style.width = 250;
sender.style.height = 150;
}
function Resize(sender, arge) {
sender.style.width = 150;
sender.style.height = 18;
}
function ScrolltoSelectedItem() {
var grd = $find("<%=MCCAuditsSummaryRadGrid.ClientID%>")
//gets the main table scrollArea HTLM element
var scrollArea = document.getElementById(grd.get_element().id + "_GridData");
var row = grd.get_masterTableView().get_selectedItems()[0];
//if the position of the selected row is below the viewable grid area
if (row) {
if ((row.get_element().offsetTop - scrollArea.scrollTop) + row.get_element().offsetHeight + 20 > scrollArea.offsetHeight) {
//scroll down to selected row
scrollArea.scrollTop = scrollArea.scrollTop + ((row.get_element().offsetTop - scrollArea.scrollTop) +
row.get_element().offsetHeight - scrollArea.offsetHeight) + row.get_element().offsetHeight;
}
//if the position of the the selected row is above the viewable grid area
else if ((row.get_element().offsetTop - scrollArea.scrollTop) < 0) {
//scroll the selected row to the top
scrollArea.scrollTop = row.get_element().offsetTop;
}
}
}
function RowSelected(sender, eventArgs) {
__doPostBack(sender.get_id(), eventArgs.get_itemIndexHierarchical());
}
function requestStart(sender, eventArgs) {
//alert('Request start initiated by: ' +
//eventArgs.get_eventTarget());
var s = eventArgs.get_eventTarget();
if (s == 'MCCAuditFormView$MCCAttachmentsRadGrid$ctl00$ctl02$ctl02$PerformInsertButton') {
eventArgs.set_enableAjax(false);
}
else {
centerLoadingPanel();
}
}
window.scrollTo = function () { }
function ScrollView() {
var el = $get("VCAFormView_ValidationSummary1");
if (el != null) {
el.scrollIntoView();
//el.focus();
}
}
function centerLoadingPanel() {
centerElementOnScreen($get("<%= RadAjaxLoadingPanel1.ClientID %>"));
}
function centerElementOnScreen(element) {
var scrollTop = document.body.scrollTop;
var scrollLeft = document.body.scrollLeft;
var viewPortHeight = document.body.clientHeight;
var viewPortWidth = document.body.clientWidth;
if (document.compatMode == "CSS1Compat") {
viewPortHeight = document.documentElement.clientHeight;
viewPortWidth = document.documentElement.clientWidth;
if (!$telerik.isSafari) {
scrollTop = document.documentElement.scrollTop;
scrollLeft = document.documentElement.scrollLeft;
}
}
var topOffset = Math.ceil(viewPortHeight / 2 - element.offsetHeight / 2);
var leftOffset = Math.ceil(viewPortWidth / 2 - element.offsetWidth / 2);
var top = scrollTop + topOffset - 40;
var left = scrollLeft + leftOffset - 70;
element.style.position = "absolute";
element.style.top = top + "px";
element.style.left = left + "px";
}
function clientBlur(sender, args) {
if (sender.get_text() == "") {
sender.clearSelection();
//sender.get_items().clear();
__doPostBack(sender.get_id(), '{\"Command\" : \"Select\"}');
}
}
</script>
<script language ="javascript" type ="text/javascript">
function GridAttachmentColumn_RowClick(sender, args)
{
alert(sender.get_id());
}
</script>
</telerik:RadCodeBlock>
<style type="text/css">
.LabelsStyle
{
font-family:Calibri;
font-size:11pt;
}
.TextBoxStyle
{
width:200px;
border-style:groove;
border-width:thin;
}
</style>
</head>
<body onload="ScrolltoSelectedItem();">
<form id="form1" runat="server">
<p id="browser"></p>
<asp:HiddenField ID="hfFilePath" runat="server" />
<asp:HiddenField ID="hfFileName" runat="server" />
<asp:ScriptManager ID="ScriptManager1" runat="server" OnAsyncPostBackError="ScriptManager1_OnAsyncPostBackError" AllowCustomErrorsRedirect="false">
</asp:ScriptManager>
<script type= "text/javascript" language="javascript">
Sys.WebForms.PageRequestManager.getInstance().add_endRequest(EndRequestHandler);
function EndRequestHandler(sender, args) {
if (args.get_error() != undefined && args.get_error().httpStatusCode == '500') {
var errorMessage = args.get_error().message
args.set_errorHandled(true);
alert(errorMessage);
}
}
</script>
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" EnableAJAX ="true">
<ClientEvents OnRequestStart="requestStart" />
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RadcboAlias">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RadcboVendor" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="btnSearch">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsSummaryRadGrid"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsRadGrid" LoadingPanelID="RadAjaxLoadingPanel1"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView"/>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAuditsSummaryRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsRadGrid"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAuditsRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAuditFormView">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsSummaryRadGrid"/>
<telerik:AjaxUpdatedControl ControlID="MCCAuditsRadGrid" LoadingPanelID="RadAjaxLoadingPanel1"/>
<%--Test--%>
<%--<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />--%>
</UpdatedControls>
</telerik:AjaxSetting>
<%--Test--%>
<%--<telerik:AjaxSetting AjaxControlID="MCCAttachmentsRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>--%>
<%-- <telerik:AjaxSetting AjaxControlID="ajaxDiv">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAttachmentsRadGrid" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="MCCAttachmentsRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="ajaxDiv" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>--%>
<%--<telerik:AjaxSetting AjaxControlID="MCCAuditFormView">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAttachmentsRadGrid" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>--%>
<%--<telerik:AjaxSetting AjaxControlID="MCCAttachmentsRadGrid">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>--%>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="MCCAuditFormView" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px"
Width="75px" Transparency="1" InitialDelayTime="100" MinDisplayTime="100" >
<img alt="Loading..." src ="Images/ajax-loader.gif"
style="border: 0px;"/>
</telerik:RadAjaxLoadingPanel>
<div>
<h2 align="center">MCC Assessments</h2>
<div style="position:absolute; right:50px; top:40px">
<a href="https://microsoft.sharepoint.com/teams/gpg/process/oms/Shared%20Documents/Forms/Master%20Compliance%20Checks%20Program.aspx" target="_blank" style="font-size:smaller">Master Compliance Process</a> |
<a href="mailto:MCCSME@microsoft.com" style="font-size:smaller">Contact Form Owner </a>
</div>
<fieldset class ="LabelsStyle">
<legend><em>Search</em></legend>
<span style="font-size:smaller">Use the RL and/or Supplier fields to find a MCC Assessment for a Supplier</span>
<table>
<tr>
<td>
Select RL :
</td>
<td>
<telerik:RadComboBox ID="RadcboAlias" runat="server" Skin="Vista" AllowCustomText ="true" MarkFirstMatch="true" EmptyMessage="Select an Alias" AutoPostBack="true" OnSelectedIndexChanged="RadcboAlias_SelectedIndexChanged" OnClientBlur="clientBlur">
</telerik:RadComboBox>
</td>
<td> </td>
<td>
Select Supplier :
</td>
<td>
<telerik:RadComboBox ID="RadcboVendor" runat="server" Skin="Vista" Width="300" AllowCustomText ="true" MarkFirstMatch="true" EmptyMessage="Select a Supplier" OnClientBlur="clientBlur">
</telerik:RadComboBox>
</td>
<td> </td>
<td>
<asp:Button ID="btnSearch" runat="server" Text="Go" onclick="btnSearch_Click"/>
</td>
<td> </td>
</tr>
</table>
<asp:TextBox ID="txtVendor" runat="server" Visible="false"></asp:TextBox>
<asp:TextBox ID="txtAlias" runat="server" Visible="false"></asp:TextBox>
</fieldset>
<br />
<asp:ObjectDataSource ID="MCCAuditSummaryObjectDataSource" runat="server"
SelectMethod="GetVendorsMCCAuditsStatusList" TypeName="MCCAuditDBClass">
<SelectParameters>
<asp:ControlParameter ControlID="txtVendor" Name="VendorName"
PropertyName="Text" Type="String" />
<asp:ControlParameter ControlID="txtAlias" Name="RelationshipLead"
PropertyName="Text" Type="String" />
</SelectParameters>
</asp:ObjectDataSource>
<asp:ObjectDataSource ID="MCCAuditsGridObjectDataSource" runat="server"
SelectMethod="GetMCCAudits" TypeName="MCCAuditDBClass" OldValuesParameterFormatString="original_{0}">
<SelectParameters>
<asp:ControlParameter ControlID="MCCAuditsSummaryRadGrid" Name="VendorName"
PropertyName="SelectedValues['VendorName']" Type="String" />
<asp:ControlParameter ControlID="MCCAuditsSummaryRadGrid" Name="AuditType"
PropertyName="SelectedValues['AuditType']" Type="String" />
</SelectParameters>
</asp:ObjectDataSource>
<asp:ObjectDataSource ID="MCCAuditFormViewObjectDataSource" runat="server"
SelectMethod="GetMCCAudit" TypeName="MCCAuditDBClass"
oninserted="MCCAuditFormViewObjectDataSource_Inserted"
onupdated="MCCAuditFormViewObjectDataSource_Updated"
oninserting="MCCAuditFormViewObjectDataSource_Inserting"
onupdating="MCCAuditFormViewObjectDataSource_Updating"
ondeleted="MCCAuditFormViewObjectDataSource_Deleted"
OldValuesParameterFormatString="original_{0}"
DataObjectTypeName="Domain.MCCAudit" DeleteMethod="DeleteMCCAudit"
InsertMethod="InsertMCCAudit" UpdateMethod="UpdateMCCAudit" >
<SelectParameters>
<asp:ControlParameter ControlID="MCCAuditsRadGrid"
Name="AuditId" PropertyName="SelectedValue" Type="Int32" />
</SelectParameters>
</asp:ObjectDataSource>
<asp:ObjectDataSource ID="NotificationsFormViewObjectDataSource" runat="server"
SelectMethod="GetMCCAuditNotifications" TypeName="MCCAuditDBClass">
<SelectParameters>
<asp:ControlParameter ControlID="MCCAuditsRadGrid" Name="AuditId"
PropertyName="SelectedValue" Type="Int32" />
</SelectParameters>
</asp:ObjectDataSource>
<b class="LabelsStyle">MCC Assessments Summary</b>
<telerik:RadGrid ID="MCCAuditsSummaryRadGrid" runat="server" Skin="Vista"
OnPreRender="MCCAuditsSummaryRadGrid_PreRender"
Ondatabound="MCCAuditsSummaryRadGrid_DataBound"
OnItemDataBound="MCCAuditsSummaryRadGrid_ItemDataBound"
OnSelectedIndexChanged="MCCAuditsSummaryRadGrid_SelectedIndexChange"
DataSourceID="MCCAuditSummaryObjectDataSource" GridLines="None">
<MasterTableView AutoGenerateColumns="False" DataSourceID="MCCAuditSummaryObjectDataSource" DataKeyNames="VendorName, AuditType">
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="VendorName" SortOrder="Ascending" HeaderText="Supplier Name" />
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="VendorName" SortOrder="Ascending" HeaderText="Supplier Name" />
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
<RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>
<ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
<Columns>
<telerik:GridBoundColumn DataField="AuditType" Display="true"
FilterControlAltText="Filter AuditType column" HeaderText="Assessment Type" ItemStyle-Font-Bold="true"
SortExpression="AuditType" UniqueName="AuditType">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Grade"
FilterControlAltText="Filter Grade column" HeaderText="Current Grade"
SortExpression="Grade" UniqueName="Grade">
</telerik:GridBoundColumn>
<telerik:GridImageColumn DataType="System.String" DataImageUrlFields="ImageName" DataImageUrlFormatString="Images/{0}.png" AlternateText="Grade image" DataAlternateTextField="Grade" ImageAlign="Middle"
HeaderText="" FooterText="">
</telerik:GridImageColumn>
<telerik:GridBoundColumn DataField="VendorName" Display="false"
FilterControlAltText="Filter VendorName column" HeaderText="VendorName"
SortExpression="VendorName" UniqueName="VendorName">
</telerik:GridBoundColumn>
<telerik:GridCheckBoxColumn DataField="IsAdhoc" Display="false"
FilterControlAltText="Filter IsAdhoc column" HeaderText="IsAdhoc"
SortExpression="IsAdhoc" UniqueName="IsAdhoc">
</telerik:GridCheckBoxColumn>
<telerik:GridBoundColumn DataField="RelationshipLead" Display="false"
FilterControlAltText="Filter RelationshipLead column" HeaderText="RelationshipLead"
SortExpression="RelationshipLead" UniqueName="RelationshipLead">
</telerik:GridBoundColumn>
<telerik:GridHyperLinkColumn DataTextField="AuditType" Display="false" NavigateUrl="http://sharepoint/sites/mgoweb-processes/Pages/MCC.aspx" ItemStyle-CssClass="HyperStyle"
FilterControlAltText="Filter AuditType column" HeaderText="Assessment Type" ItemStyle-Font-Bold="true" Target="_new"
SortExpression="AuditType" UniqueName="AuditTypeURL">
</telerik:GridHyperLinkColumn>
<telerik:GridBoundColumn DataField="AuditTypeDescription" Display="false"
FilterControlAltText="Filter AuditTypeDescription column" HeaderText="AuditTypeDescription" ItemStyle-Font-Bold="false"
SortExpression="AuditTypeDescription" UniqueName="AuditTypeDescription">
</telerik:GridBoundColumn>
</Columns>
<EditFormSettings>
<EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
</EditFormSettings>
</MasterTableView>
<FilterMenu EnableImageSprites="False"></FilterMenu>
<HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Vista"></HeaderContextMenu>
<ClientSettings>
<Selecting AllowRowSelect="True" />
<ClientEvents OnRowSelected="RowSelected"/>
<Scrolling AllowScroll="True" ScrollHeight="175" UseStaticHeaders="true" SaveScrollPosition="true"/>
</ClientSettings>
</telerik:RadGrid>
<br />
<b class="LabelsStyle">MCC Assessment Records</b>
<telerik:RadGrid ID="MCCAuditsRadGrid" runat="server" Skin="Vista" Height="100"
OnPreRender="MCCAuditsRadGrid_PreRender"
Ondatabound="MCCAuditsRadGrid_DataBound"
OnItemDataBound="MCCAuditsRadGrid_ItemDataBound"
DataSourceID="MCCAuditsGridObjectDataSource" GridLines="None">
<MasterTableView AutoGenerateColumns="False" DataSourceID="MCCAuditsGridObjectDataSource" DataKeyNames="AuditId">
<CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
<RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>
<ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
<Columns>
<telerik:GridBoundColumn DataField="AuditId" DataType="System.Int32"
FilterControlAltText="Filter AuditId column" HeaderText="Assessment Id"
SortExpression="AuditId" UniqueName="AuditId">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="VendorName"
FilterControlAltText="Filter VendorName column" HeaderText="Supplier Name"
SortExpression="VendorName" UniqueName="VendorName">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="RelationshipLead"
FilterControlAltText="Filter RelationshipLead column" HeaderText="Relationship Lead"
SortExpression="RelationshipLead" UniqueName="RelationshipLead">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="AuditType"
FilterControlAltText="Filter AuditType column" HeaderText="Assessment Type"
SortExpression="AuditType" UniqueName="AuditType">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="SubAuditType"
FilterControlAltText="Filter SubAuditType column" HeaderText="Assessment Sub Type"
SortExpression="SubAuditType" UniqueName="SubAuditType">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="StartDate" DataType="System.DateTime" DataFormatString="{0:d}"
FilterControlAltText="Filter StartDate column" HeaderText="Start Date"
SortExpression="StartDate" UniqueName="StartDate">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="EndDate" DataType="System.DateTime" DataFormatString="{0:d}"
FilterControlAltText="Filter EndDate column" HeaderText="End Date"
SortExpression="EndDate" UniqueName="EndDate">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="TargetCompletionDate" DataType="System.DateTime" DataFormatString="{0:d}"
FilterControlAltText="Filter EndDate column" HeaderText="Target Completion Date"
SortExpression="TargetCompletionDate" UniqueName="TargetCompletionDate">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Grade"
FilterControlAltText="Filter Grade column" HeaderText="Grade"
SortExpression="Grade" UniqueName="Grade">
</telerik:GridBoundColumn>
<telerik:GridCheckBoxColumn DataField="IsComplete" Display="false"
FilterControlAltText="Filter IsComplete column" HeaderText="IsComplete"
SortExpression="IsComplete" UniqueName="IsComplete">
</telerik:GridCheckBoxColumn>
</Columns>
<EditFormSettings>
<EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
</EditFormSettings>
</MasterTableView>
<FilterMenu EnableImageSprites="False"></FilterMenu>
<HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Vista"></HeaderContextMenu>
<ClientSettings>
<Selecting AllowRowSelect="True" />
<ClientEvents OnRowSelected="RowSelected" />
<Scrolling AllowScroll="True" ScrollHeight="175" UseStaticHeaders="true"/>
</ClientSettings>
</telerik:RadGrid>
<br />
<asp:FormView Width="90%" ID="MCCAuditFormView" runat="server" onitemcreated="MCCAuditFormView_ItemCreated" OnDataBound="MCCAuditFormView_DataBound" OnModeChanging="MCCAuditFormView_ModeChanging" OnPreRender="MCCAuditFormView_PreRender"
DataSourceID="MCCAuditFormViewObjectDataSource">
<EditItemTemplate>
<fieldset style="background-color:#F0F8FF">
<legend><em><b>MCC Assessment Details</b></em></legend>
<table class ="LabelsStyle">
<tr>
<td align="center">
<asp:ValidationSummary ID="ValidationSummary1" runat="server" ValidationGroup ="SaveGroup" HeaderText="<b><u>Please Correct the following errors</u></b>" />
</td>
</tr>
</table>
<div style="float:left; width:63%;">
<table class="LabelsStyle" >
<tr>
<td>Assessment Id</td>
<td>
<asp:TextBox ID="txtAuditId" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("AuditId")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Supplier Name</td>
<td>
<asp:TextBox ID="txtVendorName" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("VendorName")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Relationship Lead</td>
<td>
<asp:TextBox ID="txtRL" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("RelationshipLead")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Assessment Type</td>
<td>
<asp:TextBox ID="txtAuditType" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("AuditType")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Assessment Sub Type (if any)</td>
<td>
<telerik:RadComboBox ID="RadcboAuditSubType" runat="server" AppendDataBoundItems="true" >
<Items>
<telerik:RadComboBoxItem Text="N/A" Value="" />
</Items>
</telerik:RadComboBox>
</td>
</tr>
<tr>
<td>Start Date <asp:Image ID="StartDate" runat="server" ToolTip="This is the start date of MCC assessment validity" ImageUrl="Images/Info.png" ImageAlign="Middle" /> <span style="color:Red">*</span></td>
<td>
<telerik:RadDatePicker ID="dpStartDate" runat="server" SelectedDate='<%# Bind("StartDate")%>'>
</telerik:RadDatePicker>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpStartDate" Text="*" ErrorMessage="Start Date is a required field" ToolTip="Start Date is a required field"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>End Date <asp:Image ID="EndDate" runat="server" ToolTip="This is the end date of MCC assessment validity" ImageUrl="Images/Info.png" ImageAlign="Middle" />
<asp:label id="lblEndDateRequired" runat="server" Text="*" ForeColor="Red" />
</td>
<td>
<telerik:RadDatePicker ID="dpEndDate" runat="server" SelectedDate='<%# Bind("EndDate")%>'>
</telerik:RadDatePicker>
<asp:RequiredFieldValidator ID="rfvEndDate" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpEndDate" Text="*" ErrorMessage="End Date is a required field" ToolTip="End Date is a required field"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator2" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpEndDate" ControlToCompare="dpStartDate" Operator="GreaterThan" ErrorMessage="End Date must be after the Start Date" ToolTip="End Date must be after the Start Date" Text="*"></asp:CompareValidator>
</td>
</tr>
<tr>
<td>Target Completion Date <asp:Image ID="Image1" runat="server" ToolTip="This is the date to complete this assessment" ImageUrl="Images/Info.png" ImageAlign="Middle" /> <span style="color:Red">*</span></td>
<td>
<telerik:RadDatePicker ID="dpTargetCompletionDate" runat="server" SelectedDate='<%# Bind("TargetCompletionDate")%>'>
</telerik:RadDatePicker>
<asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpTargetCompletionDate" Text="*" ErrorMessage="Target Completion Date is a required field" ToolTip="Target Completion Date is a required field"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>Comments</td>
<td>
<telerik:RadTextBox ID="txtComments" runat="server" Text='<%# Bind("Comments") %>' Skin="Vista" Font-Names="Calibri" Font-Size="11pt" Width="400" Height="100" TextMode="MultiLine">
</telerik:RadTextBox>
</td>
</tr>
<tr>
<td colspan="2"> </td>
</tr>
</table>
</div>
<div class="LabelsStyle" style="float:right; width:35%;">
<fieldset>
<fieldset>
<legend><em><b>Expiration Notifications</b></em></legend>
<table>
<tr>
<td>Notify (semi-colon separated list of alias)</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtNotify" runat="server" Width="300" Text='<%# Bind("ExpirationNotify") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="txtNotify" ErrorMessage="Please enter the people who you want to be notified" ToolTip="Please enter the people who you want to be notified" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>Time Before Expiration (days/months)</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtDelta" runat="server" Text='<%# Bind("Delta") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="txtDelta" ErrorMessage="Please enter a value for the Time Before Expiration field" ToolTip="Please enter a value for the Time Before Expiration field" Text="*"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator1" runat="server" ValidationGroup = "SaveGroup" Type="Integer" Operator="DataTypeCheck" ControlToValidate="txtDelta" ErrorMessage="Time Before Exiration should a an integer value" ToolTip="Time Before Exiration should a an integer value" Text="*"></asp:CompareValidator>
</td>
</tr>
<tr>
<td>Unit</td>
</tr>
<tr>
<td>
<asp:DropDownList ID="cboUnit" runat="server" SelectedValue='<%# Bind("Unit") %>'>
<asp:ListItem></asp:ListItem>
<asp:ListItem>Days</asp:ListItem>
<asp:ListItem>Months</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="cboUnit" ErrorMessage="Please choose a value for the Unit field" ToolTip="Please choose a value for the Unit field" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><em><b>Score Change Notifications</b></em></legend>
<table>
<tr>
<td>
Notify (semi-colon separated list of alias)
</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtScoreChangeNotify" runat="server" Width="300" Text='<%# Bind("ScoreChangeNotify") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="txtScoreChangeNotify" ErrorMessage="Please enter the people who you want to be notified" ToolTip="Please enter the people who you want to be notified" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
</table>
</fieldset>
<asp:CheckBox ID="chkFutureApplication" runat="server" Checked='<%# Bind("ApplyToVendorLevel") %>' Text='Apply this change to all future assessments of this type for this supplier?' />
</fieldset>
</div>
<div style="clear:both">
<fieldset>
<legend><em><b></b></em></legend>
<table id="AuditChecklistTable" runat="server" width="100%" class ="LabelsStyle" style="background-color:#F5F5F5">
<tr>
<td>
<telerik:RadGrid ID="grdChecks" runat="server" Skin="Vista" AutoGenerateColumns ="false" AllowMultiRowEdit="true"
OnItemDataBound="ChecksGrid_ItemDataBound" OnItemCreated="ChecksGrid_ItemCreated"
Onprerender="ChecksGrid_PreRender" >
<HeaderContextMenu EnableTheming="True">
<CollapseAnimation Duration="200" Type="OutQuint" />
</HeaderContextMenu>
<MasterTableView EditMode="InPlace">
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="HasValue" HeaderText="HasValue"/>
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="HasValue"/>
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<Columns>
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckId" HeaderText="CheckId" DataField="CheckId" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="RequiredForCompliance" HeaderText="RequiredForCompliance" DataField="RequiredForCompliance" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="CompletionStatus" HeaderText="Status" DataField="CompletionStatus"/>
<telerik:GridBoundColumn UniqueName="RequiredCheckText" HeaderText="" DataField="RequiredCheckText" Display ="true" ReadOnly="true" ItemStyle-BorderStyle ="None" ItemStyle-ForeColor ="Red" ItemStyle-Font-Bold="true" />
<telerik:GridBoundColumn UniqueName="CheckSequenceNo" HeaderText="No" DataField="CheckSequenceNo" ReadOnly="true" Display="true" />
<telerik:GridBoundColumn UniqueName="Check" HeaderText="Check" DataField="Check" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="HelpText" HeaderText="HelpText" DataField="HelpText" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="HelpHyperlink" HeaderText="HelpHyperlink" DataField="HelpHyperlink" ReadOnly="true" Display="false" />
<telerik:GridHyperLinkColumn UniqueName="DisplayHyperlink" HeaderText="Help" DataTextField="HelpText" DataNavigateUrlFields="HelpHyperlink" Target="_new" />
<telerik:GridCheckBoxColumn UniqueName="HasValue" HeaderText="HasValue" DataField="HasValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="TargetValue" HeaderText="Target Value" DataField="TargetValue" ReadOnly ="true" Display="false" />
<telerik:GridBoundColumn UniqueName="ActualValue" HeaderText="Actual Value" DataField="ActualValue" Display="false" />
<telerik:GridBoundColumn UniqueName="Comments" HeaderText="Comments (if any)" DataField="Comments"/>
<telerik:GridCheckBoxColumn UniqueName="TriggersNAStatus" HeaderText="TriggersNAStatus" DataField="TriggersNAStatus" ReadOnly="true" Display="false" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td>
<telerik:RadGrid ID="grdValueChecks" runat="server" Skin="Vista" AutoGenerateColumns ="false" AllowMultiRowEdit="true"
OnItemDataBound="ChecksGrid_ItemDataBound" OnItemCreated="ChecksGrid_ItemCreated"
Onprerender="ChecksGrid_PreRender" >
<HeaderContextMenu EnableTheming="True">
<CollapseAnimation Duration="200" Type="OutQuint" />
</HeaderContextMenu>
<MasterTableView EditMode="InPlace">
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="HasValue" HeaderText="HasValue"/>
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="HasValue"/>
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<Columns>
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckId" HeaderText="CheckId" DataField="CheckId" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="RequiredForCompliance" HeaderText="RequiredForCompliance" DataField="RequiredForCompliance" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="CompletionStatus" HeaderText="Status" DataField="CompletionStatus" Display="false" />
<telerik:GridBoundColumn UniqueName="RequiredCheckText" HeaderText="" DataField="RequiredCheckText" Display ="true" ReadOnly="true" ItemStyle-BorderStyle ="None" ItemStyle-ForeColor ="Red" ItemStyle-Font-Bold="true" />
<telerik:GridBoundColumn UniqueName="CheckSequenceNo" HeaderText="No" DataField="CheckSequenceNo" ReadOnly="true" Display="true" />
<telerik:GridBoundColumn UniqueName="Check" HeaderText="Check" DataField="Check" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="HelpText" HeaderText="HelpText" DataField="HelpText" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="HelpHyperlink" HeaderText="HelpHyperlink" DataField="HelpHyperlink" ReadOnly="true" Display="false" />
<telerik:GridHyperLinkColumn UniqueName="DisplayHyperlink" HeaderText="Help" DataTextField="HelpText" DataNavigateUrlFields="HelpHyperlink" Target="_new" />
<telerik:GridCheckBoxColumn UniqueName="HasValue" HeaderText="HasValue" DataField="HasValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="TargetValue" HeaderText="Target Value" DataField="TargetValue" ReadOnly ="true" />
<telerik:GridBoundColumn UniqueName="ActualValue" HeaderText="Actual Value" DataField="ActualValue" />
<telerik:GridBoundColumn UniqueName="Comments" HeaderText="Comments (if any)" DataField="Comments"/>
<telerik:GridCheckBoxColumn UniqueName="TriggersNAStatus" HeaderText="TriggersNAStatus" DataField="TriggersNAStatus" ReadOnly="true" Display="false" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
</table>
</fieldset>
<br />
<fieldset>
<telerik:RadProgressManager ID="RadProgressManager1" runat="server" />
<telerik:RadProgressArea ID="RadProgressArea1" runat="server" Skin="Vista">
</telerik:RadProgressArea>
<legend><em><b>Attachments</b></em></legend>
<table width="100%" class ="LabelsStyle" style="background-color:#F5F5F5">
<tr>
<td>
<telerik:RadGrid ID="MCCAttachmentsRadGrid" runat="server" Skin="Vista" AutoGenerateColumns ="false"
OnNeedDataSource ="MCCAttachmentsRadGrid_NeedDataSource"
OnItemCommand ="MCCAttachmentsRadGrid_ItemCommand"
OnItemCreated ="MCCAttachmentsRadGrid_ItemCreated" >
<MasterTableView CommandItemDisplay="Top" CommandItemSettings-AddNewRecordText="Add new fileA">
<EditFormSettings EditFormType="AutoGenerated" FormCaptionStyle-Font-Bold="true" FormCaptionStyle-Wrap="true" FormMainTableStyle-BackColor="AliceBlue" InsertCaption="Please use the 'Browse' button to select a file and then click the 'Upload' button to upload it." FormTableButtonRowStyle-HorizontalAlign="Left" FormMainTableStyle-BorderStyle="Outset" FormMainTableStyle-BorderWidth="1" FormMainTableStyle-BorderColor="Blue" >
<EditColumn UniqueName="EditCommandColumn" InsertText ="Upload" UpdateText ="Upload" CancelText ="Cancel" EditText ="Edit" ButtonType="PushButton">
</EditColumn>
</EditFormSettings>
<Columns>
<telerik:GridButtonColumn UniqueName="DeleteColumn" Text="Delete" ConfirmText="Are you sure you want to remove this file from the assessment record?" CommandName="Delete" />
<telerik:GridBoundColumn UniqueName="AttachmentId" HeaderText="AttachmentId" DataField="AttachmentId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="FileName" HeaderText="File Name" DataField="FileName" ReadOnly ="true" />
<telerik:GridBoundColumn UniqueName="UploadDate" HeaderText="Upload Date" DataField="UploadDate" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="UploadedBy" HeaderText="Uploaded By" DataField="UploadedBy" ReadOnly ="true" />
<telerik:GridAttachmentColumn Display ="false"
EditFormHeaderTextFormat="Upload File:"
HeaderText="Download"
AttachmentDataField="FileContents"
AttachmentKeyFields="AttachmentId"
FileNameTextField="FileName"
DataTextField="FileName"
UniqueName="FileContents">
</telerik:GridAttachmentColumn>
</Columns>
</MasterTableView>
<ClientSettings>
<ClientEvents OnRowClick="GridAttachmentColumn_RowClick" />
</ClientSettings>
</telerik:RadGrid>
</td>
</tr>
</table>
</fieldset>
<table width ="100%" class ="LabelsStyle">
<tr>
<td align="left"><span style="color:Red">*</span> = Required</td>
<td align ="right">
<asp:Button ID="UpdateButton" runat="server" CausesValidation="True"
CommandName="Update" Text="Save" ValidationGroup="SaveGroup" />
<asp:Button ID="UpdateCancelButton" runat="server"
CausesValidation="False" CommandName="Cancel" Text="Cancel" />
</td>
</tr>
</table>
</div>
</EditItemTemplate>
<InsertItemTemplate>
<fieldset style="background-color:#F0F8FF">
<legend><em><b>MCC Assessment Details</b></em></legend>
<table class ="LabelsStyle">
<tr>
<td align="center">
<asp:ValidationSummary ID="ValidationSummary1" runat="server" ValidationGroup ="SaveGroup" HeaderText="<b><u>Please Correct the following errors</u></b>" />
</td>
</tr>
</table>
<div style="float:left; width:63%;">
<table class="LabelsStyle" >
<tr>
<td>Assessment Id</td>
<td>
<asp:TextBox ID="txtAuditId" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Eval("AuditId")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Supplier Name</td>
<td>
<asp:TextBox ID="txtVendorName" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("VendorName")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Relationship Lead</td>
<td>
<asp:TextBox ID="txtRL" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("RelationshipLead")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Assessment Type</td>
<td>
<asp:TextBox ID="txtAuditType" runat="server" BackColor ="LightGray" ReadOnly ="true" Text='<%# Bind("AuditType")%>'></asp:TextBox>
</td>
</tr>
<tr>
<td>Assessment Sub Type (if any)</td>
<td>
<telerik:RadComboBox ID="RadcboAuditSubType" runat="server" Width="200" AppendDataBoundItems="true">
<Items>
<telerik:RadComboBoxItem Text="N/A" Value="" />
</Items>
</telerik:RadComboBox>
</td>
</tr>
<tr>
<td>Start Date <asp:Image ID="StartDate" runat="server" ToolTip="This is the start date of MCC assessment validity" ImageUrl="Images/Info.png" ImageAlign="Middle" /> <span style="color:Red">*</span></td>
<td>
<telerik:RadDatePicker ID="dpStartDate" runat="server" SelectedDate='<%# Bind("StartDate")%>'>
</telerik:RadDatePicker>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpStartDate" Text="*" ErrorMessage="Start Date is a required field" ToolTip="Start Date is a required field"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>End Date <asp:Image ID="EndDate" runat="server" ToolTip="This is the end date of MCC assessment validity" ImageUrl="Images/Info.png" ImageAlign="Middle" />
<asp:label id="lblEndDateRequired" runat="server" Text="*" ForeColor="Red" />
</td>
<td>
<telerik:RadDatePicker ID="dpEndDate" runat="server" SelectedDate='<%# Bind("EndDate")%>'>
</telerik:RadDatePicker>
<asp:RequiredFieldValidator ID="rfvEndDate" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpEndDate" Text="*" ErrorMessage="End Date is a required field" ToolTip="End Date is a required field"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator2" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpEndDate" ControlToCompare="dpStartDate" Operator="GreaterThan" ErrorMessage="End Date must be after the Start Date" ToolTip="End Date must be after the Start Date" Text="*"></asp:CompareValidator>
</td>
</tr>
<tr>
<td>Target Completion Date <asp:Image ID="Image1" runat="server" ToolTip="This is the date to complete this assessment" ImageUrl="Images/Info.png" ImageAlign="Middle" /> <span style="color:Red">*</span></td>
<td>
<telerik:RadDatePicker ID="dpTargetCompletionDate" runat="server" SelectedDate='<%# Bind("TargetCompletionDate")%>'>
</telerik:RadDatePicker>
<asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ValidationGroup="SaveGroup" ControlToValidate="dpTargetCompletionDate" Text="*" ErrorMessage="Target Completion Date is a required field" ToolTip="Target Completion Date is a required field"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>Comments</td>
<td>
<telerik:RadTextBox ID="txtComments" runat="server" Text='<%# Bind("Comments") %>' Skin="Vista" Font-Names="Calibri" Font-Size="11pt" Width="400" Height="100" TextMode="MultiLine">
</telerik:RadTextBox>
</td>
</tr>
<tr>
<td colspan="2"> </td>
</tr>
</table>
</div>
<div class="LabelsStyle" style="float:right; width:35%;">
<fieldset>
<fieldset>
<legend><em><b>Expiration Notifications</b></em></legend>
<table>
<tr>
<td>Notify (semi-colon separated list of alias)</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtNotify" runat="server" Width="300" Text='<%# Bind("ExpirationNotify") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="txtNotify" ErrorMessage="Please enter the people who you want to be notified" ToolTip="Please enter the people who you want to be notified" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>Time Before Expiration (days/months)</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtDelta" runat="server" Text='<%# Bind("Delta") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="txtDelta" ErrorMessage="Please enter a value for the Time Before Expiration field" ToolTip="Please enter a value for the Time Before Expiration field" Text="*"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator1" runat="server" ValidationGroup = "SaveGroup" Type="Integer" Operator="DataTypeCheck" ControlToValidate="txtDelta" ErrorMessage="Time Before Exiration should a an integer value" ToolTip="Time Before Exiration should a an integer value" Text="*"></asp:CompareValidator>
</td>
</tr>
<tr>
<td>Unit</td>
</tr>
<tr>
<td>
<asp:DropDownList ID="cboUnit" runat="server" SelectedValue='<%# Bind("Unit") %>'>
<asp:ListItem></asp:ListItem>
<asp:ListItem>Days</asp:ListItem>
<asp:ListItem>Months</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="cboUnit" ErrorMessage="Please choose a value for the Unit field" ToolTip="Please choose a value for the Unit field" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><em><b>Score Change Notifications</b></em></legend>
<table>
<tr>
<td>
Notify (semi-colon separated list of alias)
</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtScoreChangeNotify" runat="server" Width="300" Text='<%# Bind("ScoreChangeNotify") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ValidationGroup = "SaveGroup" ControlToValidate="txtScoreChangeNotify" ErrorMessage="Please enter the people who you want to be notified" ToolTip="Please enter the people who you want to be notified" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
</table>
</fieldset>
<asp:CheckBox ID="chkFutureApplication" runat="server" Checked='<%# Bind("ApplyToVendorLevel") %>' Text='Apply this change to all future assessments of this type for this supplier?' />
</fieldset>
</div>
<div style="clear:both">
<fieldset>
<legend><em><b></b></em></legend>
<table id="AuditChecklistTable" runat="server" width="100%" class ="LabelsStyle" style="background-color:#F5F5F5">
<tr>
<td>
<telerik:RadGrid ID="grdChecks" runat="server" Skin="Vista" AutoGenerateColumns ="false" AllowMultiRowEdit="true"
OnItemDataBound="ChecksGrid_ItemDataBound" OnItemCreated="ChecksGrid_ItemCreated"
Onprerender="ChecksGrid_PreRender" >
<HeaderContextMenu EnableTheming="True">
<CollapseAnimation Duration="200" Type="OutQuint" />
</HeaderContextMenu>
<MasterTableView EditMode="InPlace">
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="HasValue" HeaderText="HasValue"/>
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="HasValue"/>
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<Columns>
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckId" HeaderText="CheckId" DataField="CheckId" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="RequiredForCompliance" HeaderText="RequiredForCompliance" DataField="RequiredForCompliance" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="CompletionStatus" HeaderText="Status" DataField="CompletionStatus" />
<telerik:GridBoundColumn UniqueName="RequiredCheckText" HeaderText="" DataField="RequiredCheckText" Display ="true" ReadOnly="true" ItemStyle-BorderStyle ="None" ItemStyle-ForeColor ="Red" ItemStyle-Font-Bold="true" />
<telerik:GridBoundColumn UniqueName="CheckSequenceNo" HeaderText="No" DataField="CheckSequenceNo" ReadOnly="true" Display="true" />
<telerik:GridBoundColumn UniqueName="Check" HeaderText="Check" DataField="Check" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="HelpText" HeaderText="HelpText" DataField="HelpText" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="HelpHyperlink" HeaderText="HelpHyperlink" DataField="HelpHyperlink" ReadOnly="true" Display="false" />
<telerik:GridHyperLinkColumn UniqueName="DisplayHyperlink" HeaderText="Help" DataTextField="HelpText" DataNavigateUrlFields="HelpHyperlink" Target="_new" />
<telerik:GridCheckBoxColumn UniqueName="HasValue" HeaderText="HasValue" DataField="HasValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="TargetValue" HeaderText="Target Value" DataField="TargetValue" ReadOnly ="true" Display="false" />
<telerik:GridBoundColumn UniqueName="ActualValue" HeaderText="Actual Value" DataField="ActualValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="Comments" HeaderText="Comments (if any)" DataField="Comments"/>
<telerik:GridCheckBoxColumn UniqueName="TriggersNAStatus" HeaderText="TriggersNAStatus" DataField="TriggersNAStatus" ReadOnly="true" Display="false" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td>
<telerik:RadGrid ID="grdValueChecks" runat="server" Skin="Vista" AutoGenerateColumns ="false" AllowMultiRowEdit="true"
OnItemDataBound="ChecksGrid_ItemDataBound" OnItemCreated="ChecksGrid_ItemCreated"
Onprerender="ChecksGrid_PreRender" >
<HeaderContextMenu EnableTheming="True">
<CollapseAnimation Duration="200" Type="OutQuint" />
</HeaderContextMenu>
<MasterTableView EditMode="InPlace">
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="HasValue" HeaderText="HasValue"/>
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="HasValue"/>
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<Columns>
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckId" HeaderText="CheckId" DataField="CheckId" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="RequiredForCompliance" HeaderText="RequiredForCompliance" DataField="RequiredForCompliance" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="CompletionStatus" HeaderText="Status" DataField="CompletionStatus" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="RequiredCheckText" HeaderText="" DataField="RequiredCheckText" Display ="true" ReadOnly="true" ItemStyle-BorderStyle ="None" ItemStyle-ForeColor ="Red" ItemStyle-Font-Bold="true" />
<telerik:GridBoundColumn UniqueName="CheckSequenceNo" HeaderText="No" DataField="CheckSequenceNo" ReadOnly="true" Display="true" />
<telerik:GridBoundColumn UniqueName="Check" HeaderText="Check" DataField="Check" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="HelpText" HeaderText="HelpText" DataField="HelpText" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="HelpHyperlink" HeaderText="HelpHyperlink" DataField="HelpHyperlink" ReadOnly="true" Display="false" />
<telerik:GridHyperLinkColumn UniqueName="DisplayHyperlink" HeaderText="Help" DataTextField="HelpText" DataNavigateUrlFields="HelpHyperlink" Target="_new" />
<telerik:GridCheckBoxColumn UniqueName="HasValue" HeaderText="HasValue" DataField="HasValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="TargetValue" HeaderText="Target Value" DataField="TargetValue" ReadOnly ="true" />
<telerik:GridBoundColumn UniqueName="ActualValue" HeaderText="Actual Value" DataField="ActualValue" />
<telerik:GridBoundColumn UniqueName="Comments" HeaderText="Comments (if any)" DataField="Comments"/>
<telerik:GridCheckBoxColumn UniqueName="TriggersNAStatus" HeaderText="TriggersNAStatus" DataField="TriggersNAStatus" ReadOnly="true" Display="false" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
</table>
</fieldset>
<br />
<fieldset>
<telerik:RadProgressManager ID="RadProgressManager1" runat="server" />
<telerik:RadProgressArea ID="RadProgressArea1" runat="server" Skin="Vista">
</telerik:RadProgressArea>
<legend><em><b>Attachments</b></em></legend>
<div id="ajaxDiv" runat="server">
<table width="100%" class ="LabelsStyle" style="background-color:#F5F5F5">
<tr>
<td>
<telerik:RadGrid ID="MCCAttachmentsRadGrid" runat="server" Skin="Vista" AutoGenerateColumns ="false"
OnNeedDataSource ="MCCAttachmentsRadGrid_NeedDataSource"
OnItemCommand ="MCCAttachmentsRadGrid_ItemCommand"
OnItemCreated ="MCCAttachmentsRadGrid_ItemCreated" >
<MasterTableView CommandItemDisplay="Top" CommandItemSettings-AddNewRecordText="Add new fileB">
<EditFormSettings EditFormType="AutoGenerated" FormCaptionStyle-Font-Bold="true" FormCaptionStyle-Wrap="true" FormMainTableStyle-BackColor="AliceBlue" InsertCaption="Please use the 'Browse' button to select a file and then click the 'Upload' button to upload it." FormTableButtonRowStyle-HorizontalAlign="Left" FormMainTableStyle-BorderStyle="Outset" FormMainTableStyle-BorderWidth="1" FormMainTableStyle-BorderColor="Blue" >
<EditColumn UniqueName="EditCommandColumn" InsertText ="Upload" UpdateText ="Upload" CancelText ="Cancel" EditText ="Edit" ButtonType="PushButton">
</EditColumn>
</EditFormSettings>
<Columns>
<telerik:GridButtonColumn UniqueName="DeleteColumn" Text="Delete" ConfirmText="Are you sure you want to remove this file from the assessment record?" CommandName="Delete" />
<telerik:GridBoundColumn UniqueName="AttachmentId" HeaderText="AttachmentId" DataField="AttachmentId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="FileName" HeaderText="File Name" DataField="FileName" ReadOnly ="true" />
<telerik:GridBoundColumn UniqueName="UploadDate" HeaderText="Upload Date" DataField="UploadDate" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="UploadedBy" HeaderText="Uploaded By" DataField="UploadedBy" ReadOnly ="true" />
<telerik:GridAttachmentColumn Display ="false"
EditFormHeaderTextFormat="Upload File:"
HeaderText="Download"
AttachmentDataField="FileContents"
AttachmentKeyFields="AttachmentId"
FileNameTextField="FileName"
DataTextField="FileName"
UniqueName="FileContents">
</telerik:GridAttachmentColumn>
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
</table>
</div>
</fieldset>
<table width ="100%" class ="LabelsStyle">
<tr>
<td align="left"><span style="color:Red">*</span> = Required</td>
<td align ="right">
<asp:Button ID="InsertButton" runat="server" CausesValidation="True"
CommandName="Insert" Text="Save" ValidationGroup ="SaveGroup" />
<asp:Button ID="InsertCancelButton" runat="server"
CausesValidation="False" CommandName="Cancel" Text="Cancel" />
</td>
</tr>
</table>
</div>
</InsertItemTemplate>
<ItemTemplate>
<table class ="LabelsStyle" width ="100%">
<tr align="left">
<td align ="left">
<asp:LinkButton ID="NewButton" runat="server" CausesValidation="False"
CommandName="New" Text="Create a New MCC Assessment Record" />
<asp:LinkButton ID="EditButton" runat="server" CausesValidation="False"
CommandName="Edit" Text="Edit this MCC Assessment Record" />
</td>
<td align ="right">
<asp:HyperLink ID="hlViewAuditHistory" runat="server" Target="_blank" NavigateUrl="~/MCCAuditHistory.aspx" >View Historical MCC Assessment Records</asp:HyperLink>
</td>
</tr>
<tr>
<td> </td>
</tr>
</table>
<div style="float:left; width:70%;">
<fieldset class="LabelsStyle">
<legend><em><b>MCC Assessment Details</b></em></legend>
<table class="LabelsStyle" >
<tr>
<td>Assessment Id</td>
<td class="TextBoxStyle"><%#: Eval("AuditId")%> </td>
</tr>
<tr>
<td>Supplier Name</td>
<td class="TextBoxStyle"><%#: Eval("VendorName") %> </td>
</tr>
<tr>
<td>Relationship Lead</td>
<td class="TextBoxStyle"><%#: Eval("RelationshipLead") %> </td>
</tr>
<tr>
<td>Assessment Type</td>
<td class="TextBoxStyle"><%#: Eval("AuditType") %> </td>
</tr>
<tr>
<td>Assessment Sub Type</td>
<td class="TextBoxStyle"><%#: Eval("SubAuditType") %> </td>
</tr>
<tr>
<td>Start Date</td>
<td class ="TextBoxStyle"><%#: String.Format("{0:d MMMM yyyy}", Eval("StartDate"))%> </td>
</tr>
<tr>
<td>End Date</td>
<td class ="TextBoxStyle"><%#: String.Format("{0:d MMMM yyyy}", Eval("EndDate"))%> </td>
</tr>
<tr>
<td>Target Completion Date</td>
<td class ="TextBoxStyle"><%#: String.Format("{0:d MMMM yyyy}", Eval("TargetCompletionDate"))%> </td>
</tr>
<tr>
<td>Comments</td>
<td class="TextBoxStyle"><p style="overflow:auto; max-height:300px; width: 300px;"><%#: Eval("Comments")%> </p></td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td colspan="2">
<telerik:RadGrid ID="grdChecks" runat="server" Skin="Vista" DataSource ='<%# Eval("MCCAuditCompletionChecks") %>' AutoGenerateColumns ="false" OnItemDataBound="ChecksGrid_ItemDataBound">
<MasterTableView>
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="HasValue" HeaderText="HasValue"/>
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="HasValue"/>
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<Columns>
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckId" HeaderText="CheckId" DataField="CheckId" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="RequiredForCompliance" HeaderText="RequiredForCompliance" DataField="RequiredForCompliance" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="CompletionStatus" HeaderText="Status" DataField="CompletionStatus" />
<telerik:GridBoundColumn UniqueName="CheckSequenceNo" HeaderText="No" DataField="CheckSequenceNo" ReadOnly="true" Display="true" />
<telerik:GridBoundColumn UniqueName="Check" HeaderText="Check" DataField="Check" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="HelpText" HeaderText="HelpText" DataField="HelpText" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="HelpHyperlink" HeaderText="HelpHyperlink" DataField="HelpHyperlink" ReadOnly="true" Display="false" />
<telerik:GridHyperLinkColumn UniqueName="DisplayHyperlink" HeaderText="Help" DataTextField="HelpText" DataNavigateUrlFields="HelpHyperlink" Target="_new" />
<telerik:GridCheckBoxColumn UniqueName="HasValue" HeaderText="HasValue" DataField="HasValue" Display="false" />
<telerik:GridBoundColumn UniqueName="TargetValue" HeaderText="Target Value" DataField="TargetValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="ActualValue" HeaderText="Actual Value" DataField="ActualValue" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="Comments" HeaderText="Comments (if any)" DataField="Comments"/>
<telerik:GridCheckBoxColumn UniqueName="TriggersNAStatus" HeaderText="TriggersNAStatus" DataField="TriggersNAStatus" ReadOnly="true" Display="false" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
<tr>
<td colspan="2"> </td>
</tr>
<tr>
<td colspan="2">
<telerik:RadGrid ID="grdValueChecks" runat="server" Skin="Vista" DataSource ='<%# Eval("MCCAuditValueChecks") %>' AutoGenerateColumns ="false" OnItemDataBound="ChecksGrid_ItemDataBound">
<MasterTableView>
<GroupByExpressions>
<telerik:GridGroupByExpression>
<SelectFields>
<telerik:GridGroupByField FieldName="HasValue" HeaderText="HasValue"/>
</SelectFields>
<GroupByFields>
<telerik:GridGroupByField FieldName="HasValue"/>
</GroupByFields>
</telerik:GridGroupByExpression>
</GroupByExpressions>
<Columns>
<telerik:GridBoundColumn UniqueName="AuditId" HeaderText="AuditId" DataField="AuditId" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckId" HeaderText="CheckId" DataField="CheckId" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="RequiredForCompliance" HeaderText="RequiredForCompliance" DataField="RequiredForCompliance" ReadOnly="true" Display="false" />
<telerik:GridCheckBoxColumn UniqueName="CompletionStatus" HeaderText="Status" DataField="CompletionStatus" Display="false" />
<telerik:GridBoundColumn UniqueName="CheckSequenceNo" HeaderText="No" DataField="CheckSequenceNo" ReadOnly="true" Display="true" />
<telerik:GridBoundColumn UniqueName="Check" HeaderText="Check" DataField="Check" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="HelpText" HeaderText="HelpText" DataField="HelpText" ReadOnly="true" Display="false" />
<telerik:GridBoundColumn UniqueName="HelpHyperlink" HeaderText="HelpHyperlink" DataField="HelpHyperlink" ReadOnly="true" Display="false" />
<telerik:GridHyperLinkColumn UniqueName="DisplayHyperlink" HeaderText="Help" DataTextField="HelpText" DataNavigateUrlFields="HelpHyperlink" Target="_new" />
<telerik:GridCheckBoxColumn UniqueName="HasValue" HeaderText="HasValue" DataField="HasValue" Display="false" />
<telerik:GridBoundColumn UniqueName="TargetValue" HeaderText="Target Value" DataField="TargetValue" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="ActualValue" HeaderText="Actual Value" DataField="ActualValue" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="Comments" HeaderText="Comments (if any)" DataField="Comments"/>
<telerik:GridCheckBoxColumn UniqueName="TriggersNAStatus" HeaderText="TriggersNAStatus" DataField="TriggersNAStatus" ReadOnly="true" Display="false" />
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><em><b>Attachments</b></em></legend>
<table width="100%" class ="LabelsStyle" style="background-color:#F5F5F5">
<tr>
<td>
<telerik:RadGrid ID="MCCAttachmentsRadGrid" runat="server" Skin="Vista" DataSource ='<%# Eval("MCCAuditAttachments") %>' AutoGenerateColumns ="false">
<MasterTableView>
<Columns>
<telerik:GridHyperLinkColumn UniqueName="FileName" HeaderText="File Name" DataTextField="FileName" DataNavigateUrlFields ="FilePath" />
<telerik:GridBoundColumn UniqueName="UploadDate" HeaderText="Upload Date" DataField="UploadDate" ReadOnly="true" />
<telerik:GridBoundColumn UniqueName="UploadedBy" HeaderText="Uploaded By" DataField="UploadedBy"/>
</Columns>
</MasterTableView>
</telerik:RadGrid>
</td>
</tr>
</table>
</fieldset>
</div>
<div style="float:right; width:28%;">
<fieldset class="LabelsStyle">
<legend><em><b>MCC Assessment Notifications</b></em></legend>
<asp:DataList ID="NotificationsDataList" runat="server" DataSourceID="NotificationsFormViewObjectDataSource"
OnEditCommand="NotificationsDataList_EditCommand"
OnCancelCommand="NotificationsDataList_CancelCommand"
OnUpdateCommand="NotificationsDataList_UpdateCommand"
OnItemDataBound ="NotificationsDataList_ItemDataBound" >
<ItemTemplate>
<br />
<asp:Panel ID="Panel1" runat="server" Visible='<%# Eval("NotificationType").ToString()=="Expiration" %>'>
Notify the following people <b><%#: Eval("Delta")%> <%#: Eval("Unit") %></b> before the expiration date <br /><br />[<b><%#: Eval("Notify") %></b>]
</asp:Panel>
<asp:Panel ID="Panel2" runat="server" Visible='<%# Eval("NotificationType").ToString()=="ScoreChange" %>'>
Notify the following people when the score changes <br /><br />
[<b><%#: Eval("Notify") %></b>]
</asp:Panel>
<asp:LinkButton ID="btn" CommandName="Edit" runat="server" CausesValidation="False"
Text="Change" />
<hr />
</ItemTemplate>
<EditItemTemplate>
<fieldset style="background-color:#F0F8FF">
<legend><em></em></legend>
<table id="Table1" runat="server">
<tr>
<td> </td>
</tr>
<tr>
<td>
<asp:ValidationSummary ID="ValidationSummary2" runat="server" ValidationGroup = "NotificationsSave" />
</td>
</tr>
<tr>
<td>
<asp:HiddenField ID="hfNotificationType" runat="server" Value='<%# Eval("NotificationType") %>' />
</td>
</tr>
<tr>
<td>
<b>
<%# Eval("NotificationType").ToString()=="ScoreChange" ? "Score Change Notification" : "Expiration Notification"%>
</b>
</td>
</tr>
<tr>
<td>Notify (semi-colon separated list of alias)</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtNotify" runat="server" Width="300" Text='<%# Eval("Notify") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ValidationGroup = "NotificationsSave" ControlToValidate="txtNotify" ErrorMessage="Please enter the people who you want to be notified" ToolTip="Please enter the people who you want to be notified" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td>
<asp:Panel ID="pnlNotification" runat="server" Visible='<%# Eval("NotificationType").ToString()=="Expiration" %>'>
<table>
<tr>
<td>Time Before Expiration (days/months)</td>
</tr>
<tr>
<td>
<asp:TextBox ID="txtDelta" runat="server" Text='<%# Eval("Delta") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ValidationGroup = "NotificationsSave" ControlToValidate="txtDelta" ErrorMessage="Please enter a value for the Time Before Expiration field" ToolTip="Please enter a value for the Time Before Expiration field" Text="*"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator1" runat="server" ValidationGroup = "NotificationsSave" Type="Integer" Operator="DataTypeCheck" ControlToValidate="txtDelta" ErrorMessage="Time Before Exiration should a an integer value" ToolTip="Time Before Exiration should a an integer value" Text="*"></asp:CompareValidator>
</td>
</tr>
<tr>
<td>Unit</td>
</tr>
<tr>
<td>
<asp:DropDownList ID="cboUnit" runat="server" SelectedValue='<%# Eval("Unit") %>'>
<asp:ListItem></asp:ListItem>
<asp:ListItem>Days</asp:ListItem>
<asp:ListItem>Months</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ValidationGroup = "NotificationsSave" ControlToValidate="cboUnit" ErrorMessage="Please choose a value for the Unit field" ToolTip="Please choose a value for the Unit field" Text="*"></asp:RequiredFieldValidator>
</td>
</tr>
</table>
</asp:Panel>
</td>
</tr>
<tr>
<td>
<asp:CheckBox ID="chkFutureApplication" runat="server" Text='Apply this change to all future assessments of this type for this supplier?' />
</td>
</tr>
<tr>
<td align="Right">
<asp:Button ID="btnSave" CommandName="Update" runat="server" CausesValidation="True" Text="Save" ValidationGroup = "NotificationsSave" />
<asp:Button ID="btnCancel" CommandName="Cancel" runat="server" Text="Cancel" />
</td>
</tr>
</table>
</fieldset>
<hr /><br />
</EditItemTemplate>
</asp:DataList>
</fieldset>
</div>
</ItemTemplate>
<EmptyDataTemplate>
<table class ="LabelsStyle" width ="100%">
<tr>
<td align ="left">
<asp:LinkButton ID="NewButton" runat="server" CausesValidation="False"
CommandName="New" Text="Create a New MCC Assessment Record" />
</td>
<td align ="right">
<asp:HyperLink ID="hlViewAuditHistory" runat="server" Target="_blank" NavigateUrl="~/MCCAuditHistory.aspx" >View Historical MCC Assessment Records</asp:HyperLink>
</td>
</tr>
</table>
</EmptyDataTemplate>
</asp:FormView>
</div>
</form>
</body>
</html>