|
|
|
<xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" version="1.0" exclude-result-prefixes="xsl msxsl ddwrt" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime" xmlns:asp="http://schemas.microsoft.com/ASPNET/20" xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:SharePoint="Microsoft.SharePoint.WebControls" xmlns:ddwrt2="urn:frontpage:internal"> |
|
<xsl:output method="html" indent="no"/> |
|
<xsl:decimal-format NaN=""/> |
|
<xsl:param name="dvt_apos">'</xsl:param> |
|
<xsl:param name="ManualRefresh"></xsl:param> |
|
<xsl:variable name="dvt_1_automode">0</xsl:variable> |
|
<xsl:template match="/" xmlns:x="http://www.w3.org/2001/XMLSchema" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:asp="http://schemas.microsoft.com/ASPNET/20" xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer" xmlns:SharePoint="Microsoft.SharePoint.WebControls"> |
|
<xsl:choose> |
|
<xsl:when test="($ManualRefresh = 'True')"> |
|
<table width="100%" border="0" cellpadding="0" cellspacing="0"> |
|
<tr> |
|
<td valign="top"> |
|
<xsl:call-template name="dvt_1"/> |
|
</td> |
|
<td width="1%" class="ms-vb" valign="top"> |
|
<img src="/_layouts/images/staticrefresh.gif" id="ManualRefresh" border="0" onclick="javascript: {ddwrt:GenFireServerEvent('__cancel')}" alt="Click here to refresh the dataview."/> |
|
</td> |
|
</tr> |
|
</table> |
|
</xsl:when> |
|
<xsl:otherwise> |
|
<xsl:call-template name="dvt_1"/> |
|
</xsl:otherwise> |
|
</xsl:choose> |
|
<script type="text/javascript"> |
|
<![CDATA[ |
|
$("label").each( |
|
function() { |
|
$(this).attr('for',$(this).next().find("input").attr("id")); |
|
} |
|
); |
|
$( "#tabs" ).tabs(); |
|
$("span[role=alert]").closest(".ui-tabs-panel").each(function() { |
|
$tmpID = this.id; |
|
$(".ui-tabs-nav > li > a").filter(function() { |
|
return(this.hash == '#' + $tmpID); |
|
}).each(function() { |
|
$tmpHTML = $(this).html(); |
|
$tmpHTML += ' <span style="color: red; font-weight: bold;">*</span>'; |
|
$(this).html($tmpHTML); |
|
}); |
|
}); |
|
|
|
$("span[role=alert]") |
|
.closest("#tabs") |
|
.before('<div class="ui-state-error ui-corner-all"><p style="padding: 0 5px;">There was a problem saving your record. Please check the form for errors by selecting each tab with a red asterisk (*)</p></div>'); |
|
$('input[id$=DateTimeFieldDate]').datepicker({ |
|
changeMonth: true, |
|
changeYear: true |
|
}); |
|
|
|
$('.ms-dtinput a').remove(); |
|
]]> |
|
</script> |
|
</xsl:template> |
|
|
|
<xsl:template name="dvt_1"> |
|
<xsl:variable name="dvt_StyleName">ListForm</xsl:variable> |
|
<xsl:variable name="Rows" select="/dsQueryResponse/Rows/Row"/> |
|
<div> |
|
<span id="part1"> |
|
<table border="0" width="100%"> |
|
<xsl:call-template name="dvt_1.body"> |
|
<xsl:with-param name="Rows" select="$Rows"/> |
|
</xsl:call-template> |
|
</table> |
|
</span> |
|
<SharePoint:AttachmentUpload runat="server" ControlMode="New"/> |
|
<SharePoint:ItemHiddenVersion runat="server" ControlMode="New"/> |
|
</div> |
|
</xsl:template> |
|
<xsl:template name="dvt_1.body"> |
|
<xsl:param name="Rows"/> |
|
<tr> |
|
<td class="ms-toolbar" nowrap="nowrap"> |
|
<table> |
|
<tr> |
|
<td width="99%" class="ms-toolbar" nowrap="nowrap"><IMG SRC="/_layouts/images/blank.gif" width="1" height="18"/></td> |
|
<td class="ms-toolbar" nowrap="nowrap"> |
|
<SharePoint:SaveButton runat="server" ControlMode="New" id="savebutton1"/> |
|
</td> |
|
<td class="ms-separator"> </td> |
|
<td class="ms-toolbar" nowrap="nowrap" align="right"> |
|
<SharePoint:GoBackButton runat="server" ControlMode="New" id="gobackbutton1"/> |
|
</td> |
|
</tr> |
|
</table> |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="ms-toolbar" nowrap="nowrap"> |
|
<SharePoint:FormToolBar runat="server" ControlMode="New"/> |
|
</td> |
|
</tr> |
|
<xsl:call-template name="dvt_1.rowedit"/> |
|
<tr> |
|
<td class="ms-toolbar" nowrap="nowrap"> |
|
<table> |
|
<tr> |
|
<td width="99%" class="ms-toolbar" nowrap="nowrap"><IMG SRC="/_layouts/images/blank.gif" width="1" height="18"/></td> |
|
<td class="ms-toolbar" nowrap="nowrap"> |
|
<SharePoint:SaveButton runat="server" ControlMode="New" id="savebutton2"/> |
|
</td> |
|
<td class="ms-separator"> </td> |
|
<td class="ms-toolbar" nowrap="nowrap" align="right"> |
|
<SharePoint:GoBackButton runat="server" ControlMode="New" id="gobackbutton2"/> |
|
</td> |
|
</tr> |
|
</table> |
|
</td> |
|
</tr> |
|
</xsl:template> |
|
<xsl:template name="dvt_1.rowedit"> |
|
<xsl:param name="Pos" select="position()"/> |
|
<tr> |
|
<td> |
|
<style> |
|
label { |
|
display: block; |
|
font-weight: bold; |
|
font-size: 1.1em; |
|
margin-bottom: .25em; |
|
} |
|
#tabs input { |
|
margin-bottom: 1.5em; |
|
} |
|
#tabs input.ms-input{ |
|
font-size: 8pt; |
|
} |
|
.ms-formvalidation span{ |
|
margin-top: -1em; |
|
display:block; |
|
} |
|
</style> |
|
<div id="tabs"> |
|
<ul> |
|
<li> |
|
<a href="#tabs-1">Basic Info</a> |
|
</li> |
|
<li> |
|
<a href="#tabs-2">Contact Info</a> |
|
</li> |
|
<li> |
|
<a href="#tabs-3">Other Info</a> |
|
</li> |
|
</ul> |
|
<div id="tabs-1"> |
|
<label for="">Last Name <span title="This is a required field." class="ms-formvalidation"> *</span></label> |
|
<SharePoint:FieldDescription runat="server" id="ff1description{$Pos}" FieldName="Title" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff1{$Pos}" ControlMode="New" FieldName="Title" __designer:bind="{ddwrt:DataBind('i',concat('ff1',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Title')}"/> |
|
|
|
<label for="">First Name</label> |
|
<SharePoint:FieldDescription runat="server" id="ff2description{$Pos}" FieldName="FirstName" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff2{$Pos}" ControlMode="New" FieldName="FirstName" __designer:bind="{ddwrt:DataBind('i',concat('ff2',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@FirstName')}"/> |
|
|
|
<label for="">Full Name</label> |
|
<SharePoint:FieldDescription runat="server" id="ff3description{$Pos}" FieldName="FullName" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff3{$Pos}" ControlMode="New" FieldName="FullName" __designer:bind="{ddwrt:DataBind('i',concat('ff3',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@FullName')}"/> |
|
|
|
<label for="">Email Address</label> |
|
<SharePoint:FieldDescription runat="server" id="ff4description{$Pos}" FieldName="Email" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff4{$Pos}" ControlMode="New" FieldName="Email" __designer:bind="{ddwrt:DataBind('i',concat('ff4',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Email')}"/> |
|
|
|
<label for="">Company</label> |
|
<SharePoint:FieldDescription runat="server" id="ff5description{$Pos}" FieldName="Company" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff5{$Pos}" ControlMode="New" FieldName="Company" __designer:bind="{ddwrt:DataBind('i',concat('ff5',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Company')}"/> |
|
|
|
<label for="">Job Title</label> |
|
<SharePoint:FieldDescription runat="server" id="ff6description{$Pos}" FieldName="JobTitle" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff6{$Pos}" ControlMode="New" FieldName="JobTitle" __designer:bind="{ddwrt:DataBind('i',concat('ff6',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@JobTitle')}"/> |
|
</div> |
|
<div id="tabs-2"> |
|
<label for="">Work Phone</label> |
|
<SharePoint:FieldDescription runat="server" id="ff7description{$Pos}" FieldName="WorkPhone" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff7{$Pos}" ControlMode="New" FieldName="WorkPhone" __designer:bind="{ddwrt:DataBind('i',concat('ff7',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkPhone')}"/> |
|
|
|
<label for="">Home Phone</label> |
|
<SharePoint:FieldDescription runat="server" id="ff8description{$Pos}" FieldName="HomePhone" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff8{$Pos}" ControlMode="New" FieldName="HomePhone" __designer:bind="{ddwrt:DataBind('i',concat('ff8',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@HomePhone')}"/> |
|
|
|
<label for="">Cell Phone</label> |
|
<SharePoint:FieldDescription runat="server" id="ff9description{$Pos}" FieldName="CellPhone" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff9{$Pos}" ControlMode="New" FieldName="CellPhone" __designer:bind="{ddwrt:DataBind('i',concat('ff9',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@CellPhone')}"/> |
|
|
|
<label for="">Work Fax</label> |
|
<SharePoint:FieldDescription runat="server" id="ff10description{$Pos}" FieldName="WorkFax" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff10{$Pos}" ControlMode="New" FieldName="WorkFax" __designer:bind="{ddwrt:DataBind('i',concat('ff10',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkFax')}"/> |
|
|
|
<label for="">Address</label> |
|
<SharePoint:FieldDescription runat="server" id="ff11description{$Pos}" FieldName="WorkAddress" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff11{$Pos}" ControlMode="New" FieldName="WorkAddress" __designer:bind="{ddwrt:DataBind('i',concat('ff11',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkAddress')}"/> |
|
|
|
<label for="">City</label> |
|
<SharePoint:FieldDescription runat="server" id="ff12description{$Pos}" FieldName="WorkCity" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff12{$Pos}" ControlMode="New" FieldName="WorkCity" __designer:bind="{ddwrt:DataBind('i',concat('ff12',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkCity')}"/> |
|
|
|
<label for="">State</label> |
|
<SharePoint:FieldDescription runat="server" id="ff13description{$Pos}" FieldName="WorkState" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff13{$Pos}" ControlMode="New" FieldName="WorkState" __designer:bind="{ddwrt:DataBind('i',concat('ff13',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkState')}"/> |
|
|
|
<label for="">Zip / Postal Code</label> |
|
<SharePoint:FieldDescription runat="server" id="ff14description{$Pos}" FieldName="WorkZip" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff14{$Pos}" ControlMode="New" FieldName="WorkZip" __designer:bind="{ddwrt:DataBind('i',concat('ff14',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkZip')}"/> |
|
|
|
<label for="">Country<span title="This is a required field." class="ms-formvalidation"> *</span></label> |
|
<SharePoint:FieldDescription runat="server" id="ff15description{$Pos}" FieldName="WorkCountry" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff15{$Pos}" ControlMode="New" FieldName="WorkCountry" __designer:bind="{ddwrt:DataBind('i',concat('ff15',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WorkCountry')}"/> |
|
</div> |
|
<div id="tabs-3"> |
|
<label for="">Home Page (URL)</label> |
|
<SharePoint:FieldDescription runat="server" id="ff16description{$Pos}" FieldName="WebPage" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff16{$Pos}" ControlMode="New" FieldName="WebPage" __designer:bind="{ddwrt:DataBind('i',concat('ff16',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@WebPage')}"/> |
|
|
|
<label for="">Additional Notes</label> |
|
<SharePoint:FieldDescription runat="server" id="ff17description{$Pos}" FieldName="Comments" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff17{$Pos}" ControlMode="New" FieldName="Comments" __designer:bind="{ddwrt:DataBind('i',concat('ff17',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Comments')}"/> |
|
|
|
<label for="">Birthday</label> |
|
<SharePoint:FieldDescription runat="server" id="ff18description{$Pos}" FieldName="Birthday" ControlMode="New"/> |
|
<SharePoint:FormField runat="server" id="ff18{$Pos}" ControlMode="New" FieldName="Birthday" __designer:bind="{ddwrt:DataBind('i',concat('ff18',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Birthday')}"/> |
|
</div> |
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<table border="0"> |
|
<tr id="idAttachmentsRow"> |
|
<td nowrap="true" valign="top" class="ms-formlabel" width="20%"> |
|
<SharePoint:FieldLabel ControlMode="New" FieldName="Attachments" |
|
runat="server"/> |
|
</td> |
|
<td valign="top" class="ms-formbody" width="80%"> |
|
<SharePoint:FormField runat="server" id="AttachmentsField" |
|
ControlMode="New" FieldName="Attachments" |
|
__designer:bind="{ddwrt:DataBind('i','AttachmentsField','Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Attachments')}"/> |
|
<script> |
|
var elm = document.getElementById("idAttachmentsTable"); |
|
if (elm == null || elm.rows.length == 0) |
|
document.getElementById("idAttachmentsRow").style.display='none'; |
|
</script> |
|
</td> |
|
</tr> |
|
</table> |
|
</td> |
|
</tr> |
|
</xsl:template> |
|
</xsl:stylesheet> |