diff --git a/jquery.SPServices-2013.02.min.js b/jquery.SPServices-2013.02.min.js deleted file mode 100644 index 3699d09..0000000 --- a/jquery.SPServices-2013.02.min.js +++ /dev/null @@ -1,21 +0,0 @@ -/* - * SPServices - Work with SharePoint's Web Services using jQuery - * Version 2013.02 - * @requires jQuery v1.8 or greater - jQuery 1.10.x recommended - * - * Copyright (c) 2009-2013 Sympraxis Consulting LLC - * Examples and docs at: - * http://spservices.codeplex.com - * Licensed under the MIT license: - * http://www.opensource.org/licenses/mit-license.php - */ -/* - * @description Work with SharePoint's Web Services using jQuery - * @type jQuery - * @name SPServices - * @category Plugins/SPServices - * @author Sympraxis Consulting LLC/marc.anderson@sympraxisconsulting.com - */ -/* jshint undef: true */ -/* global _spUserId, _spPageContextInfo, GipAddSelectedItems, GipRemoveSelectedItems, GipGetGroupData */ -(function(ak){var Z="2012.02";var P="/";var ah="Column not found on page";var ab="http://schemas.microsoft.com/sharepoint";var an="MultiLookupPicker";var g="MultiLookup";var A={};var b="Alerts";var u="Authentication";var am="Copy";var F="Forms";var at="Lists";var m="Meetings";var B="People";var f="Permissions";var h="PublishedLinksService";var ai="Search";var ag="SharePointDiagnostics";var Y="SiteData";var aA="Sites";var I="SocialDataService";var ae="SpellCheck";var o="TaxonomyClientService";var l="usergroup";var J="UserProfileService";var D="Versions";var az="Views";var e="WebPartPages";var aw="Webs";var E="Workflow";var ac=new ap();var N=0;var x=["listName","description"];var T=[];T.GetAlerts=[b,false];T.DeleteAlerts=[b,true];T.Mode=[u,false];T.Login=[u,false];T.CopyIntoItems=[am,true];T.CopyIntoItemsLocal=[am,true];T.GetItem=[am,false];T.GetForm=[F,false];T.GetFormCollection=[F,false];T.AddAttachment=[at,true];T.AddDiscussionBoardItem=[at,true];T.AddList=[at,true];T.AddListFromFeature=[at,true];T.ApplyContentTypeToList=[at,true];T.CheckInFile=[at,true];T.CheckOutFile=[at,true];T.CreateContentType=[at,true];T.DeleteAttachment=[at,true];T.DeleteContentType=[at,true];T.DeleteContentTypeXmlDocument=[at,true];T.DeleteList=[at,true];T.GetAttachmentCollection=[at,false];T.GetList=[at,false];T.GetListAndView=[at,false];T.GetListCollection=[at,false];T.GetListContentType=[at,false];T.GetListContentTypes=[at,false];T.GetListItemChanges=[at,false];T.GetListItemChangesSinceToken=[at,false];T.GetListItems=[at,false];T.GetVersionCollection=[at,false];T.UndoCheckOut=[at,true];T.UpdateContentType=[at,true];T.UpdateContentTypesXmlDocument=[at,true];T.UpdateContentTypeXmlDocument=[at,true];T.UpdateList=[at,true];T.UpdateListItems=[at,true];T.AddMeeting=[m,true];T.CreateWorkspace=[m,true];T.RemoveMeeting=[m,true];T.SetWorkSpaceTitle=[m,true];T.ResolvePrincipals=[B,false];T.SearchPrincipals=[B,false];T.AddPermission=[f,true];T.AddPermissionCollection=[f,true];T.GetPermissionCollection=[f,true];T.RemovePermission=[f,true];T.RemovePermissionCollection=[f,true];T.UpdatePermission=[f,true];T.GetLinks=[h,true];T.GetPortalSearchInfo=[ai,false];T.GetQuerySuggestions=[ai,false];T.GetSearchMetadata=[ai,false];T.Query=[ai,false];T.QueryEx=[ai,false];T.Registration=[ai,false];T.Status=[ai,false];T.SendClientScriptErrorReport=[ag,true];T.GetAttachments=[Y,false];T.EnumerateFolder=[Y,false];T.SiteDataGetList=[Y,false];T.SiteDataGetListCollection=[Y,false];T.SiteDataGetSite=[Y,false];T.SiteDataGetSiteUrl=[Y,false];T.SiteDataGetWeb=[Y,false];T.CreateWeb=[aA,true];T.DeleteWeb=[aA,false];T.GetSite=[aA,false];T.GetSiteTemplates=[aA,false];T.AddComment=[I,true];T.AddTag=[I,true];T.AddTagByKeyword=[I,true];T.CountCommentsOfUser=[I,false];T.CountCommentsOfUserOnUrl=[I,false];T.CountCommentsOnUrl=[I,false];T.CountRatingsOnUrl=[I,false];T.CountTagsOfUser=[I,false];T.DeleteComment=[I,true];T.DeleteRating=[I,true];T.DeleteTag=[I,true];T.DeleteTagByKeyword=[I,true];T.DeleteTags=[I,true];T.GetAllTagTerms=[I,false];T.GetAllTagTermsForUrlFolder=[I,false];T.GetAllTagUrls=[I,false];T.GetAllTagUrlsByKeyword=[I,false];T.GetCommentsOfUser=[I,false];T.GetCommentsOfUserOnUrl=[I,false];T.GetCommentsOnUrl=[I,false];T.GetRatingAverageOnUrl=[I,false];T.GetRatingOfUserOnUrl=[I,false];T.GetRatingOnUrl=[I,false];T.GetRatingsOfUser=[I,false];T.GetRatingsOnUrl=[I,false];T.GetSocialDataForFullReplication=[I,false];T.GetTags=[I,true];T.GetTagsOfUser=[I,true];T.GetTagTerms=[I,true];T.GetTagTermsOfUser=[I,true];T.GetTagTermsOnUrl=[I,true];T.GetTagUrlsOfUser=[I,true];T.GetTagUrlsOfUserByKeyword=[I,true];T.GetTagUrls=[I,true];T.GetTagUrlsByKeyword=[I,true];T.SetRating=[I,true];T.UpdateComment=[I,true];T.SpellCheck=[ae,false];T.AddTerms=[o,true];T.GetChildTermsInTerm=[o,false];T.GetChildTermsInTermSet=[o,false];T.GetKeywordTermsByGuids=[o,false];T.GetTermsByLabel=[o,false];T.GetTermSets=[o,false];T.AddGroup=[l,true];T.AddGroupToRole=[l,true];T.AddRole=[l,true];T.AddRoleDef=[l,true];T.AddUserCollectionToGroup=[l,true];T.AddUserCollectionToRole=[l,true];T.AddUserToGroup=[l,true];T.AddUserToRole=[l,true];T.GetAllUserCollectionFromWeb=[l,false];T.GetGroupCollection=[l,false];T.GetGroupCollectionFromRole=[l,false];T.GetGroupCollectionFromSite=[l,false];T.GetGroupCollectionFromUser=[l,false];T.GetGroupCollectionFromWeb=[l,false];T.GetGroupInfo=[l,false];T.GetRoleCollection=[l,false];T.GetRoleCollectionFromGroup=[l,false];T.GetRoleCollectionFromUser=[l,false];T.GetRoleCollectionFromWeb=[l,false];T.GetRoleInfo=[l,false];T.GetRolesAndPermissionsForCurrentUser=[l,false];T.GetRolesAndPermissionsForSite=[l,false];T.GetUserCollection=[l,false];T.GetUserCollectionFromGroup=[l,false];T.GetUserCollectionFromRole=[l,false];T.GetUserCollectionFromSite=[l,false];T.GetUserCollectionFromWeb=[l,false];T.GetUserInfo=[l,false];T.GetUserLoginFromEmail=[l,false];T.RemoveGroup=[l,true];T.RemoveGroupFromRole=[l,true];T.RemoveRole=[l,true];T.RemoveUserCollectionFromGroup=[l,true];T.RemoveUserCollectionFromRole=[l,true];T.RemoveUserCollectionFromSite=[l,true];T.RemoveUserFromGroup=[l,true];T.RemoveUserFromRole=[l,true];T.RemoveUserFromSite=[l,true];T.RemoveUserFromWeb=[l,true];T.UpdateGroupInfo=[l,true];T.UpdateRoleDefInfo=[l,true];T.UpdateRoleInfo=[l,true];T.UpdateUserInfo=[l,true];T.AddColleague=[J,true];T.AddLink=[J,true];T.AddMembership=[J,true];T.AddPinnedLink=[J,true];T.CreateMemberGroup=[J,true];T.CreateUserProfileByAccountName=[J,true];T.GetCommonColleagues=[J,false];T.GetCommonManager=[J,false];T.GetCommonMemberships=[J,false];T.GetInCommon=[J,false];T.GetPropertyChoiceList=[J,false];T.GetUserColleagues=[J,false];T.GetUserLinks=[J,false];T.GetUserMemberships=[J,false];T.GetUserPinnedLinks=[J,false];T.GetUserProfileByGuid=[J,false];T.GetUserProfileByIndex=[J,false];T.GetUserProfileByName=[J,false];T.GetUserProfileCount=[J,false];T.GetUserProfileSchema=[J,false];T.ModifyUserPropertyByAccountName=[J,true];T.RemoveAllColleagues=[J,true];T.RemoveAllLinks=[J,true];T.RemoveAllMemberships=[J,true];T.RemoveAllPinnedLinks=[J,true];T.RemoveColleague=[J,true];T.RemoveLink=[J,true];T.RemoveMembership=[J,true];T.RemovePinnedLink=[J,true];T.UpdateColleaguePrivacy=[J,true];T.UpdateLink=[J,true];T.UpdateMembershipPrivacy=[J,true];T.UpdatePinnedLink=[J,true];T.DeleteAllVersions=[D,true];T.DeleteVersion=[D,true];T.GetVersions=[D,false];T.RestoreVersion=[D,true];T.AddView=[az,true];T.DeleteView=[az,true];T.GetView=[az,false];T.GetViewHtml=[az,false];T.GetViewCollection=[az,false];T.UpdateView=[az,true];T.UpdateViewHtml=[az,true];T.AddWebPart=[e,true];T.AddWebPartToZone=[e,true];T.GetWebPart2=[e,false];T.GetWebPartPage=[e,false];T.GetWebPartProperties=[e,false];T.GetWebPartProperties2=[e,false];T.CreateContentType=[aw,true];T.GetColumns=[aw,false];T.GetContentType=[aw,false];T.GetContentTypes=[aw,false];T.GetCustomizedPageStatus=[aw,false];T.GetListTemplates=[aw,false];T.GetObjectIdFromUrl=[aw,false];T.GetWeb=[aw,false];T.GetWebCollection=[aw,false];T.GetAllSubWebCollection=[aw,false];T.UpdateColumns=[aw,true];T.UpdateContentType=[aw,true];T.WebUrlFromPageUrl=[aw,false];T.AlterToDo=[E,true];T.GetTemplatesForItem=[E,false];T.GetToDosForItem=[E,false];T.GetWorkflowDataForItem=[E,false];T.GetWorkflowTaskData=[E,false];T.StartWorkflow=[E,true];var S={};S.header="";S.footer="";S.payload="";var aa;ak.fn.SPServices=function(aB){var aD=ak.extend({},ak.fn.SPServices.defaults,aB);for(var aC=0;aC";aa=ab+"/soap/2002/1/alerts/";break;case m:S.opheader+="xmlns='"+ab+"/soap/meetings/' >";aa=ab+"/soap/meetings/";break;case f:S.opheader+="xmlns='"+ab+"/soap/directory/' >";aa=ab+"/soap/directory/";break;case h:S.opheader+="xmlns='http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService/' >";aa="http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService/";break;case ai:S.opheader+="xmlns='urn:Microsoft.Search' >";aa="urn:Microsoft.Search/";break;case ag:S.opheader+="xmlns='"+ab+"/diagnostics/' >";aa="http://schemas.microsoft.com/sharepoint/diagnostics/";break;case I:S.opheader+="xmlns='http://microsoft.com/webservices/SharePointPortalServer/SocialDataService' >";aa="http://microsoft.com/webservices/SharePointPortalServer/SocialDataService/";break;case ae:S.opheader+="xmlns='http://schemas.microsoft.com/sharepoint/publishing/spelling/' >";aa="http://schemas.microsoft.com/sharepoint/publishing/spelling/SpellCheck";break;case o:S.opheader+="xmlns='"+ab+"/taxonomy/soap/' >";aa=ab+"/taxonomy/soap/";break;case l:S.opheader+="xmlns='"+ab+"/soap/directory/' >";aa=ab+"/soap/directory/";break;case J:S.opheader+="xmlns='http://microsoft.com/webservices/SharePointPortalServer/UserProfileService' >";aa="http://microsoft.com/webservices/SharePointPortalServer/UserProfileService/";break;case e:S.opheader+="xmlns='http://microsoft.com/sharepoint/webpartpages' >";aa="http://microsoft.com/sharepoint/webpartpages/";break;case E:S.opheader+="xmlns='"+ab+"/soap/workflow/' >";aa=ab+"/soap/workflow/";break;default:S.opheader+="xmlns='"+ab+"/soap/'>";aa=ab+"/soap/";break}aa+=aD.operation;S.opfooter="";var aF="_vti_bin/"+T[aD.operation][0]+".asmx";if(aD.webURL.charAt(aD.webURL.length-1)===P){aF=aD.webURL+aF}else{if(aD.webURL.length>0){aF=aD.webURL+P+aF}else{aF=ak().SPServices.SPGetCurrentSite()+P+aF}}S.payload="";switch(aD.operation){case"GetAlerts":break;case"DeleteAlerts":S.payload+="";for(aC=0;aC";break;case"Mode":break;case"Login":aq(aD,["username","password"]);break;case"CopyIntoItems":aq(aD,["SourceUrl"]);S.payload+="";for(aC=0;aC";aq(aD,["Fields","Stream","Results"]);break;case"CopyIntoItemsLocal":aq(aD,["SourceUrl"]);S.payload+="";for(aC=0;aC";break;case"GetItem":aq(aD,["Url","Fields","Stream"]);break;case"GetForm":aq(aD,["listName","formUrl"]);break;case"GetFormCollection":aq(aD,["listName"]);break;case"AddAttachment":aq(aD,["listName","listItemID","fileName","attachment"]);break;case"AddDiscussionBoardItem":aq(aD,["listName","message"]);break;case"AddList":aq(aD,["listName","description","templateID"]);break;case"AddListFromFeature":aq(aD,["listName","description","featureID","templateID"]);break;case"ApplyContentTypeToList":aq(aD,["webUrl","contentTypeId","listName"]);break;case"CheckInFile":aq(aD,["pageUrl","comment","CheckinType"]);break;case"CheckOutFile":aq(aD,["pageUrl","checkoutToLocal","lastmodified"]);break;case"CreateContentType":aq(aD,["listName","displayName","parentType","fields","contentTypeProperties","addToView"]);break;case"DeleteAttachment":aq(aD,["listName","listItemID","url"]);break;case"DeleteContentType":aq(aD,["listName","contentTypeId"]);break;case"DeleteContentTypeXmlDocument":aq(aD,["listName","contentTypeId","documentUri"]);break;case"DeleteList":aq(aD,["listName"]);break;case"GetAttachmentCollection":aq(aD,["listName",["listItemID","ID"]]);break;case"GetList":aq(aD,["listName"]);break;case"GetListAndView":aq(aD,["listName","viewName"]);break;case"GetListCollection":break;case"GetListContentType":aq(aD,["listName","contentTypeId"]);break;case"GetListContentTypes":aq(aD,["listName"]);break;case"GetListItems":aq(aD,["listName","viewName",["query","CAMLQuery"],["viewFields","CAMLViewFields"],["rowLimit","CAMLRowLimit"],["queryOptions","CAMLQueryOptions"]]);break;case"GetListItemChanges":aq(aD,["listName","viewFields","since","contains"]);break;case"GetListItemChangesSinceToken":aq(aD,["listName","viewName","query","viewFields","rowLimit","queryOptions","changeToken","contains"]);break;case"GetVersionCollection":aq(aD,["strlistID","strlistItemID","strFieldName"]);break;case"UndoCheckOut":aq(aD,["pageUrl"]);break;case"UpdateContentType":aq(aD,["listName","contentTypeId","contentTypeProperties","newFields","updateFields","deleteFields","addToView"]);break;case"UpdateContentTypesXmlDocument":aq(aD,["listName","newDocument"]);break;case"UpdateContentTypeXmlDocument":aq(aD,["listName","contentTypeId","newDocument"]);break;case"UpdateList":aq(aD,["listName","listProperties","newFields","updateFields","deleteFields","listVersion"]);break;case"UpdateListItems":aq(aD,["listName"]);if(typeof aD.updates!=="undefined"&&aD.updates.length>0){aq(aD,["updates"])}else{S.payload+="";for(aC=0;aC"+K(aD.valuepairs[aC][1])+""}if(aD.batchCmd!=="New"){S.payload+=""+aD.ID+""}S.payload+=""}break;case"AddMeeting":aq(aD,["organizerEmail","uid","sequence","utcDateStamp","title","location","utcDateStart","utcDateEnd","nonGregorian"]);break;case"CreateWorkspace":aq(aD,["title","templateName","lcid","timeZoneInformation"]);break;case"RemoveMeeting":aq(aD,["recurrenceId","uid","sequence","utcDateStamp","cancelMeeting"]);break;case"SetWorkspaceTitle":aq(aD,["title"]);break;case"ResolvePrincipals":aq(aD,["principalKeys","principalType","addToUserInfoList"]);break;case"SearchPrincipals":aq(aD,["searchText","maxResults","principalType"]);break;case"AddPermission":aq(aD,["objectName","objectType","permissionIdentifier","permissionType","permissionMask"]);break;case"AddPermissionCollection":aq(aD,["objectName","objectType","permissionsInfoXml"]);break;case"GetPermissionCollection":aq(aD,["objectName","objectType"]);break;case"RemovePermission":aq(aD,["objectName","objectType","permissionIdentifier","permissionType"]);break;case"RemovePermissionCollection":aq(aD,["objectName","objectType","memberIdsXml"]);break;case"UpdatePermission":aq(aD,["objectName","objectType","permissionIdentifier","permissionType","permissionMask"]);break;case"GetLinks":break;case"GetPortalSearchInfo":S.opheader="<"+aD.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aD.operation;break;case"GetQuerySuggestions":S.opheader="<"+aD.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aD.operation;S.payload+=av("queryXml",j(aD.queryXml));break;case"GetSearchMetadata":S.opheader="<"+aD.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aD.operation;break;case"Query":S.payload+=av("queryXml",j(aD.queryXml));break;case"QueryEx":S.opheader="<"+aD.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aD.operation;S.payload+=av("queryXml",j(aD.queryXml));break;case"Registration":S.payload+=av("registrationXml",j(aD.registrationXml));break;case"Status":break;case"SendClientScriptErrorReport":aq(aD,["message","file","line","client","stack","team","originalFile"]);break;case"EnumerateFolder":aq(aD,["strFolderUrl"]);break;case"GetAttachments":aq(aD,["strListName","strItemId"]);break;case"SiteDataGetList":aq(aD,["strListName"]);S=k(S,aD.operation);break;case"SiteDataGetListCollection":S=k(S,aD.operation);break;case"SiteDataGetSite":S=k(S,aD.operation);break;case"SiteDataGetSiteUrl":aq(aD,["Url"]);S=k(S,aD.operation);break;case"SiteDataGetWeb":S=k(S,aD.operation);break;case"CreateWeb":aq(aD,["url","title","description","templateName","language","languageSpecified","locale","localeSpecified","collationLocale","collationLocaleSpecified","uniquePermissions","uniquePermissionsSpecified","anonymous","anonymousSpecified","presence","presenceSpecified"]);break;case"DeleteWeb":aq(aD,["url"]);break;case"GetSite":aq(aD,["SiteUrl"]);break;case"GetSiteTemplates":aq(aD,["LCID","TemplateList"]);break;case"AddComment":aq(aD,["url","comment","isHighPriority","title"]);break;case"AddTag":aq(aD,["url","termID","title","isPrivate"]);break;case"AddTagByKeyword":aq(aD,["url","keyword","title","isPrivate"]);break;case"CountCommentsOfUser":aq(aD,["userAccountName"]);break;case"CountCommentsOfUserOnUrl":aq(aD,["userAccountName","url"]);break;case"CountCommentsOnUrl":aq(aD,["url"]);break;case"CountRatingsOnUrl":aq(aD,["url"]);break;case"CountTagsOfUser":aq(aD,["userAccountName"]);break;case"DeleteComment":aq(aD,["url","lastModifiedTime"]);break;case"DeleteRating":aq(aD,["url"]);break;case"DeleteTag":aq(aD,["url","termID"]);break;case"DeleteTagByKeyword":aq(aD,["url","keyword"]);break;case"DeleteTags":aq(aD,["url"]);break;case"GetAllTagTerms":aq(aD,["maximumItemsToReturn"]);break;case"GetAllTagTermsForUrlFolder":aq(aD,["urlFolder","maximumItemsToReturn"]);break;case"GetAllTagUrls":aq(aD,["termID"]);break;case"GetAllTagUrlsByKeyword":aq(aD,["keyword"]);break;case"GetCommentsOfUser":aq(aD,["userAccountName","maximumItemsToReturn","startIndex"]);break;case"GetCommentsOfUserOnUrl":aq(aD,["userAccountName","url"]);break;case"GetCommentsOnUrl":aq(aD,["url","maximumItemsToReturn","startIndex"]);if(typeof aD.excludeItemsTime!=="undefined"&&aD.excludeItemsTime.length>0){S.payload+=av("excludeItemsTime",aD.excludeItemsTime)}break;case"GetRatingAverageOnUrl":aq(aD,["url"]);break;case"GetRatingOfUserOnUrl":aq(aD,["userAccountName","url"]);break;case"GetRatingOnUrl":aq(aD,["url"]);break;case"GetRatingsOfUser":aq(aD,["userAccountName"]);break;case"GetRatingsOnUrl":aq(aD,["url"]);break;case"GetSocialDataForFullReplication":aq(aD,["userAccountName"]);break;case"GetTags":aq(aD,["url"]);break;case"GetTagsOfUser":aq(aD,["userAccountName","maximumItemsToReturn","startIndex"]);break;case"GetTagTerms":aq(aD,["maximumItemsToReturn"]);break;case"GetTagTermsOfUser":aq(aD,["userAccountName","maximumItemsToReturn"]);break;case"GetTagTermsOnUrl":aq(aD,["url","maximumItemsToReturn"]);break;case"GetTagUrls":aq(aD,["termID"]);break;case"GetTagUrlsByKeyword":aq(aD,["keyword"]);break;case"GetTagUrlsOfUser":aq(aD,["termID","userAccountName"]);break;case"GetTagUrlsOfUserByKeyword":aq(aD,["keyword","userAccountName"]);break;case"SetRating":aq(aD,["url","rating","title","analysisDataEntry"]);break;case"UpdateComment":aq(aD,["url","lastModifiedTime","comment","isHighPriority"]);break;case"SpellCheck":aq(aD,["chunksToSpell","declaredLanguage","useLad"]);break;case"AddTerms":aq(aD,["sharedServiceId","termSetId","lcid","newTerms"]);break;case"GetChildTermsInTerm":aq(aD,["sspId","lcid","termId","termSetId"]);break;case"GetChildTermsInTermSet":aq(aD,["sspId","lcid","termSetId"]);break;case"GetKeywordTermsByGuids":aq(aD,["termIds","lcid"]);break;case"GetTermsByLabel":aq(aD,["label","lcid","matchOption","resultCollectionSize","termIds","addIfNotFound"]);break;case"GetTermSets":aq(aD,["sharedServiceId","termSetId","lcid","clientTimeStamps","clientVersions"]);break;case"AddGroup":aq(aD,["groupName","ownerIdentifier","ownerType","defaultUserLoginName","description"]);break;case"AddGroupToRole":aq(aD,["groupName","roleName"]);break;case"AddRole":aq(aD,["roleName","description","permissionMask"]);break;case"AddRoleDef":aq(aD,["roleName","description","permissionMask"]);break;case"AddUserCollectionToGroup":aq(aD,["groupName","usersInfoXml"]);break;case"AddUserCollectionToRole":aq(aD,["roleName","usersInfoXml"]);break;case"AddUserToGroup":aq(aD,["groupName","userName","userLoginName","userEmail","userNotes"]);break;case"AddUserToRole":aq(aD,["roleName","userName","userLoginName","userEmail","userNotes"]);break;case"GetAllUserCollectionFromWeb":break;case"GetGroupCollection":aq(aD,["groupNamesXml"]);break;case"GetGroupCollectionFromRole":aq(aD,["roleName"]);break;case"GetGroupCollectionFromSite":break;case"GetGroupCollectionFromUser":aq(aD,["userLoginName"]);break;case"GetGroupCollectionFromWeb":break;case"GetGroupInfo":aq(aD,["groupName"]);break;case"GetRoleCollection":aq(aD,["roleNamesXml"]);break;case"GetRoleCollectionFromGroup":aq(aD,["groupName"]);break;case"GetRoleCollectionFromUser":aq(aD,["userLoginName"]);break;case"GetRoleCollectionFromWeb":break;case"GetRoleInfo":aq(aD,["roleName"]);break;case"GetRolesAndPermissionsForCurrentUser":break;case"GetRolesAndPermissionsForSite":break;case"GetUserCollection":aq(aD,["userLoginNamesXml"]);break;case"GetUserCollectionFromGroup":aq(aD,["groupName"]);break;case"GetUserCollectionFromRole":aq(aD,["roleName"]);break;case"GetUserCollectionFromSite":break;case"GetUserCollectionFromWeb":break;case"GetUserInfo":aq(aD,["userLoginName"]);break;case"GetUserLoginFromEmail":aq(aD,["emailXml"]);break;case"RemoveGroup":aq(aD,["groupName"]);break;case"RemoveGroupFromRole":aq(aD,["roleName","groupName"]);break;case"RemoveRole":aq(aD,["roleName"]);break;case"RemoveUserCollectionFromGroup":aq(aD,["groupName","userLoginNamesXml"]);break;case"RemoveUserCollectionFromRole":aq(aD,["roleName","userLoginNamesXml"]);break;case"RemoveUserCollectionFromSite":aq(aD,["userLoginNamesXml"]);break;case"RemoveUserFromGroup":aq(aD,["groupName","userLoginName"]);break;case"RemoveUserFromRole":aq(aD,["roleName","userLoginName"]);break;case"RemoveUserFromSite":aq(aD,["userLoginName"]);break;case"RemoveUserFromWeb":aq(aD,["userLoginName"]);break;case"UpdateGroupInfo":aq(aD,["oldGroupName","groupName","ownerIdentifier","ownerType","description"]);break;case"UpdateRoleDefInfo":aq(aD,["oldRoleName","roleName","description","permissionMask"]);break;case"UpdateRoleInfo":aq(aD,["oldRoleName","roleName","description","permissionMask"]);break;case"UpdateUserInfo":aq(aD,["userLoginName","userName","userEmail","userNotes"]);break;case"AddColleague":aq(aD,["accountName","colleagueAccountName","group","privacy","isInWorkGroup"]);break;case"AddLink":aq(aD,["accountName","name","url","group","privacy"]);break;case"AddMembership":aq(aD,["accountName","membershipInfo","group","privacy"]);break;case"AddPinnedLink":aq(aD,["accountName","name","url"]);break;case"CreateMemberGroup":aq(aD,["membershipInfo"]);break;case"CreateUserProfileByAccountName":aq(aD,["accountName"]);break;case"GetCommonColleagues":aq(aD,["accountName"]);break;case"GetCommonManager":aq(aD,["accountName"]);break;case"GetCommonMemberships":aq(aD,["accountName"]);break;case"GetInCommon":aq(aD,["accountName"]);break;case"GetPropertyChoiceList":aq(aD,["propertyName"]);break;case"GetUserColleagues":aq(aD,["accountName"]);break;case"GetUserLinks":aq(aD,["accountName"]);break;case"GetUserMemberships":aq(aD,["accountName"]);break;case"GetUserPinnedLinks":aq(aD,["accountName"]);break;case"GetUserProfileByGuid":aq(aD,["guid"]);break;case"GetUserProfileByIndex":aq(aD,["index"]);break;case"GetUserProfileByName":if(typeof aD.accountName!=="undefined"&&aD.accountName.length>0){aq(aD,[["AccountName","accountName"]])}else{aq(aD,["AccountName"])}break;case"GetUserProfileCount":break;case"GetUserProfileSchema":break;case"ModifyUserPropertyByAccountName":aq(aD,["accountName","newData"]);break;case"RemoveAllColleagues":aq(aD,["accountName"]);break;case"RemoveAllLinks":aq(aD,["accountName"]);break;case"RemoveAllMemberships":aq(aD,["accountName"]);break;case"RemoveAllPinnedLinks":aq(aD,["accountName"]);break;case"RemoveColleague":aq(aD,["accountName","colleagueAccountName"]);break;case"RemoveLink":aq(aD,["accountName","id"]);break;case"RemoveMembership":aq(aD,["accountName","sourceInternal","sourceReference"]);break;case"RemovePinnedLink":aq(aD,["accountName","id"]);break;case"UpdateColleaguePrivacy":aq(aD,["accountName","colleagueAccountName","newPrivacy"]);break;case"UpdateLink":aq(aD,["accountName","data"]);break;case"UpdateMembershipPrivacy":aq(aD,["accountName","sourceInternal","sourceReference","newPrivacy"]);break;case"UpdatePinnedLink ":aq(aD,["accountName","data"]);break;case"DeleteAllVersions":aq(aD,["fileName"]);break;case"DeleteVersion":aq(aD,["fileName","fileVersion"]);break;case"GetVersions":aq(aD,["fileName"]);break;case"RestoreVersion":aq(aD,["fileName","fileVersion"]);break;case"AddView":aq(aD,["listName","viewName","viewFields","query","rowLimit","rowLimit","type","makeViewDefault"]);break;case"DeleteView":aq(aD,["listName","viewName"]);break;case"GetView":aq(aD,["listName","viewName"]);break;case"GetViewCollection":aq(aD,["listName"]);break;case"GetViewHtml":aq(aD,["listName","viewName"]);break;case"UpdateView":aq(aD,["listName","viewName","viewProperties","query","viewFields","aggregations","formats","rowLimit"]);break;case"UpdateViewHtml":aq(aD,["listName","viewName","viewProperties","toolbar","viewHeader","viewBody","viewFooter","viewEmpty","rowLimitExceeded","query","viewFields","aggregations","formats","rowLimit"]);break;case"AddWebPart":aq(aD,["pageUrl","webPartXml","storage"]);break;case"AddWebPartToZone":aq(aD,["pageUrl","webPartXml","storage","zoneId","zoneIndex"]);break;case"GetWebPart2":aq(aD,["pageUrl","storageKey","storage","behavior"]);break;case"GetWebPartPage":aq(aD,["documentName","behavior"]);break;case"GetWebPartProperties":aq(aD,["pageUrl","storage"]);break;case"GetWebPartProperties2":aq(aD,["pageUrl","storage","behavior"]);break;case"Webs.CreateContentType":aq(aD,["displayName","parentType","newFields","contentTypeProperties"]);break;case"GetColumns":aq(aD,["webUrl"]);break;case"GetContentType":aq(aD,["contentTypeId"]);break;case"GetContentTypes":break;case"GetCustomizedPageStatus":aq(aD,["fileUrl"]);break;case"GetListTemplates":break;case"GetObjectIdFromUrl":aq(aD,["objectUrl"]);break;case"GetWeb":aq(aD,[["webUrl","webURL"]]);break;case"GetWebCollection":break;case"GetAllSubWebCollection":break;case"UpdateColumns":aq(aD,["newFields","updateFields","deleteFields"]);break;case"Webs.UpdateContentType":aq(aD,["contentTypeId","contentTypeProperties","newFields","updateFields","deleteFields"]);break;case"WebUrlFromPageUrl":aq(aD,[["pageUrl","pageURL"]]);break;case"AlterToDo":aq(aD,["item","todoId","todoListId","taskData"]);break;case"GetTemplatesForItem":aq(aD,["item"]);break;case"GetToDosForItem":aq(aD,["item"]);break;case"GetWorkflowDataForItem":aq(aD,["item"]);break;case"GetWorkflowTaskData":aq(aD,["item","listId","taskId"]);break;case"StartWorkflow":aq(aD,["item","templateId","workflowParameters"]);break;default:break}var aG=S.header+S.opheader+S.payload+S.opfooter+S.footer;var aE;if(aD.cacheXML){aE=A[aG]}if(typeof aE==="undefined"){A[aG]=ak.ajax({url:aF,async:aD.async,beforeSend:function(i){if(T[aD.operation][1]){i.setRequestHeader("SOAPAction",aa)}},type:"POST",data:aG,dataType:"xml",contentType:"text/xml;charset='utf-8'",complete:function(aH,i){if(ak.isFunction(aD.completefunc)){aD.completefunc(aH,i)}}});return A[aG]}else{if(ak.isFunction(aD.completefunc)){aD.completefunc(aE,null)}return aE}};ak.fn.SPServices.defaults={cacheXML:false,operation:"",webURL:"",makeViewDefault:false,CAMLViewName:"",CAMLQuery:"",CAMLViewFields:"",CAMLRowLimit:0,CAMLQueryOptions:"",batchCmd:"Update",valuepairs:[],DestinationUrls:[],behavior:"Version3",storage:"Shared",objectType:"List",cancelMeeting:true,nonGregorian:false,fClaim:false,recurrenceId:0,sequence:0,maximumItemsToReturn:0,startIndex:0,isHighPriority:false,isPrivate:false,rating:1,maxResults:10,principalType:"User",async:true,completefunc:null};ak.fn.SPServices.SPGetCurrentSite=function(){if(ac.thisSite.length>0){return ac.thisSite}var i=S.header+""+((location.href.indexOf("?")>0)?location.href.substr(0,location.href.indexOf("?")):location.href)+""+S.footer;ak.ajax({async:false,url:"/_vti_bin/Webs.asmx",type:"POST",data:i,dataType:"xml",contentType:'text/xml;charset="utf-8"',complete:function(aC,aB){ac.thisSite=ak(aC.responseXML).find("WebUrlFromPageUrlResult").text()}});return ac.thisSite};ak.fn.SPServices.SPCascadeDropdowns=function(aJ){var aB=ak.extend({},{relationshipWebURL:"",relationshipList:"",relationshipListParentColumn:"",relationshipListChildColumn:"",relationshipListSortColumn:"",parentColumn:"",childColumn:"",listName:ak().SPServices.SPListNameFromUrl(),CAMLQuery:"",CAMLQueryOptions:"FALSE",promptText:"",noneText:"(None)",simpleChild:false,selectSingleOption:false,matchOnId:false,completefunc:null,debug:false},aJ);var aD=false;var aH="SPServices.SPCascadeDropdowns";var aE=new ar(aB.parentColumn);if(aE.Obj.html()===null&&aB.debug){W(aH,"parentColumn: "+aB.parentColumn,ah);return}var i=new ar(aB.childColumn);if(i.Obj.html()===null&&aB.debug){W(aH,"childColumn: "+aB.childColumn,ah);return}if(aB.simpleChild===true&&i.Type==="C"){ak().SPServices.SPComplexToSimpleDropdown({columnName:aB.childColumn});i=new ar(aB.childColumn)}var aI,aG;ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:aB.listName,completefunc:function(aK){ak(aK.responseXML).find("Fields").each(function(){ak(this).find("Field[DisplayName='"+aB.childColumn+"']").each(function(){aI=(ak(this).attr("Required")==="TRUE")?true:false;aG=ak(this).attr("StaticName");return false})})}});var aF={opt:aB,childSelect:i,childColumnStatic:aG,childColumnRequired:aI};var aC=aE.Obj.data("SPCascadeDropdownsChildColumns");if(typeof aC==="undefined"){aE.Obj.data("SPCascadeDropdownsChildColumns",[aF])}else{aC.push(aF);aE.Obj.data("SPCascadeDropdownsChildColumns",aC);aD=true}if(!aD){switch(aE.Type){case"S":aE.Obj.bind("change",function(){ay(aB.parentColumn,aE)});break;case"C":ak("input[id='"+aE.Obj.attr("optHid")+"']").bind("propertychange",function(){ay(aB.parentColumn,aE)});break;case"M":ak(aE.master.candidateControl).bind("dblclick",function(){ay(aB.parentColumn,aE)});ak(aE.master.resultControl).bind("dblclick",function(){ay(aB.parentColumn,aE)});ak(aE.master.addControl).bind("click",function(){ay(aB.parentColumn,aE)});ak(aE.master.removeControl).bind("click",function(){ay(aB.parentColumn,aE)});break;default:break}}ay(aB.parentColumn,aE)};function ay(aI,aD){var aJ="";var aC;var aF=null;var aH;var aE;var aG;var aB;var i=aD.Obj.data("SPCascadeDropdownsChildColumns");ak(i).each(function(){var aO=this.opt;var aM=this.childSelect;var aR=this.childColumnStatic;var aN=this.childColumnRequired;aC=c(aD,aO.matchOnId);var aL=aC.join(";#");if(aD.Obj.data("SPCascadeDropdown_Selected_"+aR)===aL){return}aD.Obj.data("SPCascadeDropdown_Selected_"+aR,aL);aF=c(aM,true);var aQ=(aO.relationshipListSortColumn.length>0)?aO.relationshipListSortColumn:aO.relationshipListChildColumn;var aK="";if(aO.CAMLQuery.length>0){aK+=""}if(aC.length===0){aK+=""}else{if(aC.length===1){aK+="":"'/>")+K(aC[0])+""}else{var aP=(aC.length>2)?true:false;for(N=0;N<(aC.length-1);N++){aK+=""}for(N=0;N":"'/>")+K(aC[N])+"";if(N>0&&(N<(aC.length-1))&&aP){aK+=""}}aK+=""}}if(aO.CAMLQuery.length>0){aK+=aO.CAMLQuery+""}aK+="";aK+="";ak().SPServices({operation:"GetListItems",async:false,webURL:aO.relationshipWebURL,listName:aO.relationshipList,CAMLQuery:aK,CAMLViewFields:"",CAMLRowLimit:0,CAMLQueryOptions:aO.CAMLQueryOptions,completefunc:function(aS){ak(aS.responseXML).find("errorstring").each(function(){var aU="SPServices.SPCascadeDropdowns";var aT=ak(this).text();if(aO.debug&&aT==="One or more field types are not installed properly. Go to the list settings page to delete these fields."){W(aU,"relationshipListParentColumn: "+aO.relationshipListParentColumn+" or relationshipListChildColumn: "+aO.relationshipListChildColumn,"Not found in relationshipList "+aO.relationshipList)}else{if(aO.debug&&aT==="Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."){W(aU,"relationshipList: "+aO.relationshipList,"List not found")}}return});switch(aM.Type){case"S":ak(aM.Obj).find("option").remove();if(!aN&&(aO.promptText.length>0)){aM.Obj.append("")}else{if(!aN){aM.Obj.append("")}}break;case"C":aJ=aN?"":aO.noneText+"|0";aM.Obj.attr("value","");break;case"M":ak(aM.master.candidateControl).find("option").remove();aH="";break;default:break}aE=parseFloat(ak(aS.responseXML).SPFilterNode("rs:data").attr("ItemCount"));ak(aS.responseXML).SPFilterNode("z:row").each(function(){var aU={};var aT=ak(this).attr("ows_"+aO.relationshipListChildColumn);if(typeof aT!=="undefined"&&aT.indexOf(";#")>0){aU=new n(aT)}else{aU.id=ak(this).attr("ows_ID");aU.value=aT}if(isNaN(aU.id)){aU.id=ak(this).attr("ows_ID")}aG=aU.id;aB=aU.value;switch(aM.Type){case"S":var aV=(ak(this).attr("ows_ID")===aF[0])?" selected='selected'":"";aM.Obj.append(""+aU.value+"");break;case"C":if(aU.id===aF[0]){aM.Obj.attr("value",aU.value)}aJ=aJ+((aJ.length>0)?"|":"")+aU.value+"|"+aU.id;break;case"M":ak(aM.master.candidateControl).append("");aH+=aU.id+"|t"+aU.value+"|t |t |t";break;default:break}});switch(aM.Type){case"S":aM.Obj.trigger("change");if(aE===1&&aO.selectSingleOption===true){ak(aM.Obj).find("option[value!='0']:first").attr("selected","selected")}break;case"C":aM.Obj.attr("choices",aJ);if(aE===1&&aO.selectSingleOption===true){ak(aM.Obj).attr("value",aB);ak("input[id='"+aM.Obj.attr("optHid")+"']").val(aG)}if(aM.Obj.val()===""){ak("input[id='"+aM.Obj.attr("optHid")+"']").val("")}break;case"M":aM.master.data="";aM.MultiLookupPickerdata.attr("value",aH);ak(aM.master.resultControl).find("option").each(function(){var aT=ak(this);aT.prop("selected",true);ak(aM.master.candidateControl).find("option[value='"+aT.val()+"']").each(function(){aT.prop("selected",false)})});GipRemoveSelectedItems(aM.master);ak(aM.master.candidateControl).find("option").each(function(){var aT=ak(this);ak(aM.master.resultControl).find("option[value='"+aT.val()+"']").each(function(){aT.remove()})});GipAddSelectedItems(aM.master);aM.master.data=GipGetGroupData(aH);ak(aM.master.candidateControl).trigger("dblclick");break;default:break}}});if(aO.completefunc!==null){aO.completefunc()}})}ak.fn.SPServices.SPComplexToSimpleDropdown=function(aJ){var i=ak.extend({},{columnName:"",completefunc:null,debug:false},aJ);var aC=new ar(i.columnName);if(aC.Obj.html()===null&&i.debug){W("SPServices.SPComplexToSimpleDropdown","columnName: "+i.columnName,ah);return}if(aC.Type!=="C"){return}var aH=ak(aC.Obj).attr("choices").split("|");var aD=ak(aC.Obj).attr("optHid");var aI=ak("input[id='"+aD+"']");var aB=ak("input[id='"+aD+"']").val();var aE=ad("SPComplexToSimpleDropdown",i.columnName);var aG="";ak(aC.Obj).closest("td").prepend(aG);ak(aC.Obj).closest("span").find("img").remove();ak(aC.Obj).closest("span").find("input").hide();ak("#"+aE).change(function(){var aK=ak(this).val();aI.val(aK);ak(aC.Obj).val(ak(this).find("option[value='"+(aK!=="0"?aK:"")+"']").html())});ak("#"+aE).trigger("change");if(i.completefunc!==null){i.completefunc()}};ak.fn.SPServices.SPDisplayRelatedInfo=function(aB){var aD=ak.extend({},{columnName:"",relatedWebURL:"",relatedList:"",relatedListColumn:"",relatedColumns:[],displayFormat:"table",headerCSSClass:"ms-vh2",rowCSSClass:"ms-vb",CAMLQuery:"",numChars:0,matchType:"Eq",matchOnId:false,completefunc:null,debug:false},aB);var i;var aC=[];var aG;var aF="SPServices.SPDisplayRelatedInfo";var aE=new ar(aD.columnName);if(aE.Obj.html()===null&&aD.debug){W(aF,"columnName: "+aD.columnName,ah);return}i=ad("SPDisplayRelatedInfo",aD.columnName);ak().SPServices({operation:"GetList",async:false,cacheXML:true,webURL:aD.relatedWebURL,listName:aD.relatedList,completefunc:function(aH){ak(aH.responseXML).find("faultcode").each(function(){if(aD.debug){W(aF,"relatedList: "+aD.relatedList,"List not found");return}});aG=ak(aH.responseXML).find("List");for(N=0;N Field[Name='"+aD.relatedColumns[N]+"']")}}});switch(aE.Type){case"S":aE.Obj.bind("change",function(){af(aD,i,aG,aC)});break;case"C":ak("input[id='"+aE.Obj.attr("optHid")+"']").bind("propertychange",function(){af(aD,i,aG,aC)});break;case"M":if(aD.debug){W(aF,"columnName: "+aD.columnName,"Multi-select columns not supported by this function")}break;default:break}af(aD,i,aG,aC)};function af(aC,aG,aI,aD){var aJ=null;var aF="SPServices.SPDisplayRelatedInfo";var aE=new ar(aC.columnName);aJ=c(aE,aC.matchOnId);if(aE.Type==="C"&&aC.numChars>0&&aJ[0].length");var i="";if(aC.CAMLQuery.length>0){i+=""}var aB=aD[aC.relatedListColumn].attr("Type");if(aB==="Lookup"){i+="":"'/>")+K(aJ[0])+""}else{i+="":aC.relatedListColumn+"'/>")+K(aJ[0])+""}if(aC.CAMLQuery.length>0){i+=aC.CAMLQuery+""}i+="";var aH=" ";for(N=0;N"}ak().SPServices({operation:"GetListItems",async:false,webURL:aC.relatedWebURL,listName:aC.relatedList,CAMLQuery:i,CAMLViewFields:""+aH+"",CAMLRowLimit:0,completefunc:function(aL){ak(aL.responseXML).find("errorstring").each(function(){var aM=ak(this).text();if(aC.debug&&aM==="One or more field types are not installed properly. Go to the list settings page to delete these fields."){W(aF,"relatedListColumn: "+aC.relatedListColumn,"Column not found in relatedList "+aC.relatedList)}else{if(aC.debug&&aM==="Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."){W(aF,"relatedList: "+aC.relatedList,"List not found")}}return});var aK;switch(aC.displayFormat){case"table":aK="";aK+="";for(N=0;N"+aD[aC.relatedColumns[N]].attr("DisplayName")+""}aK+="";ak(aL.responseXML).SPFilterNode("z:row").each(function(){aK+="";for(N=0;N"+V(aI,aD[aC.relatedColumns[N]],ak(this).attr("ows_"+aC.relatedColumns[N]),aC)+""}aK+=""});aK+="
";break;case"list":aK="";ak(aL.responseXML).SPFilterNode("z:row").each(function(){for(N=0;N"+aD[aC.relatedColumns[N]].attr("DisplayName")+"";aK+="";aK+=""}});aK+="
"+V(aI,aD[aC.relatedColumns[N]],ak(this).attr("ows_"+aC.relatedColumns[N]),aC)+"
";break;default:break}ak("#"+aG).html(aK)}});if(aC.completefunc!==null){aC.completefunc()}}ak.fn.SPServices.SPFilterDropdown=function(aK){var aB=ak.extend({},{relationshipWebURL:"",relationshipList:"",relationshipListColumn:"",relationshipListSortColumn:"",relationshipListSortAscending:true,columnName:"",listName:ak().SPServices.SPListNameFromUrl(),promptText:"",noneText:"(None)",CAMLQuery:"",CAMLQueryOptions:"FALSE",completefunc:null,debug:false},aK);var aJ="";var aI=null;var aH;var aG;var aF="SPServices.SPFilterDropdown";var aE=new ar(aB.columnName);if(aE.Obj.html()===null&&aB.debug){W(aF,"columnName: "+aB.columnName,ah);return}aI=c(aE,true);var aD=(aB.relationshipListSortColumn.length>0)?aB.relationshipListSortColumn:aB.relationshipListColumn;var aC=(aB.relationshipListSortAscending===true)?"":"Ascending='FALSE'";var i="";if(aB.CAMLQuery.length>0){i+=aB.CAMLQuery}i+="";ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:aB.listName,completefunc:function(aL){ak(aL.responseXML).find("Fields").each(function(){ak(this).find("Field[DisplayName='"+aB.columnName+"']").each(function(){aG=(ak(this).attr("Required")==="TRUE")?true:false;return false})})}});ak().SPServices({operation:"GetListItems",async:false,webURL:aB.relationshipWebURL,listName:aB.relationshipList,CAMLQuery:i,CAMLViewFields:"",CAMLRowLimit:0,CAMLQueryOptions:aB.CAMLQueryOptions,completefunc:function(aL){ak(aL.responseXML).find("errorstring").each(function(){var aM=ak(this).text();if(aB.debug&&aM==="One or more field types are not installed properly. Go to the list settings page to delete these fields."){W(aF,"relationshipListColumn: "+aB.relationshipListColumn,"Not found in relationshipList "+aB.relationshipList)}else{if(aB.debug&&aM==="Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."){W(aF,"relationshipList: "+aB.relationshipList,"List not found")}}return});switch(aE.Type){case"S":ak(aE.Obj).find("option").remove();if(!aG&&(aB.promptText.length>0)){aE.Obj.append("")}else{if(!aG){aE.Obj.append("")}}break;case"C":aJ=aG?"":aB.noneText+"|0";aE.Obj.attr("value","");break;case"M":ak(aE.master.candidateControl).find("option").remove();aH="";break;default:break}ak(aL.responseXML).SPFilterNode("z:row").each(function(){var aN={};var aM=ak(this).attr("ows_"+aB.relationshipListColumn);if(typeof aM!=="undefined"&&aM.indexOf(";#")>0){aN=new n(aM)}else{aN.id=ak(this).attr("ows_ID");aN.value=aM}if(isNaN(aN.id)){aN.id=ak(this).attr("ows_ID")}switch(aE.Type){case"S":var aO=(ak(this).attr("ows_ID")===aI[0])?" selected='selected'":"";aE.Obj.append(""+aN.value+"");break;case"C":if(aN.id===aI[0]){aE.Obj.attr("value",aN.value)}aJ=aJ+((aJ.length>0)?"|":"")+aN.value+"|"+aN.id;break;case"M":ak(aE.master.candidateControl).append("");aH+=aN.id+"|t"+aN.value+"|t |t |t";break;default:break}});switch(aE.Type){case"S":aE.Obj.trigger("change");break;case"C":aE.Obj.attr("choices",aJ);aE.Obj.trigger("propertychange");break;case"M":aE.master.data="";aE.MultiLookupPickerdata.attr("value",aH);ak(aE.master.resultControl).find("option").each(function(){var aM=ak(this);ak(this).attr("selected","selected");ak(aE.master.candidateControl).find("option").each(function(){if(ak(this).html()===aM.html()){aM.removeAttr("selected")}})});GipRemoveSelectedItems(aE.master);ak(aE.master.candidateControl).find("option").each(function(){var aM=ak(this);ak(aE.master.resultControl).find("option").each(function(){if(ak(this).html()===aM.html()){aM.remove()}})});GipAddSelectedItems(aE.master);aE.master.data=GipGetGroupData(aH);ak(aE.master.candidateControl).trigger("dblclick");break;default:break}}});if(aB.completefunc!==null){aB.completefunc()}};ak.fn.SPServices.SPDebugXMLHttpResult=function(aC){var aE=ak.extend({},{node:null,indent:0},aC);var aD;var aG=3;var aF=4;var aB="";aB+="";if(aE.node.nodeName==="DisplayPattern"){aB+=""}else{if(!aE.node.hasChildNodes()){aB+="";if(aE.node.attributes){aB+=""}}else{if(aE.node.hasChildNodes()&&aE.node.firstChild.nodeType===aF){aB+=""}else{if(aE.node.hasChildNodes()&&aE.node.firstChild.nodeType===aG){aB+=""}else{aB+="";if(aE.node.attributes){aB+=""}aB+=""}}}}aB+="
"+aE.node.nodeName+"
"+aE.node.nodeName+""+((aE.node.nodeValue!==null)?M(aE.node.nodeValue):" ")+"
"+t(aE.node)+"
"+aE.node.nodeName+"
"+aE.node.nodeName+""+M(aE.node.firstChild.nodeValue)+"
"+aE.node.nodeName+"
"+t(aE.node)+"
";for(aD=0;aD
";return aB};ak.fn.SPServices.SPGetCurrentUser=function(aE){var aG=ak.extend({},{webURL:"",fieldName:"Name",fieldNames:{},debug:false},aE);if(aG.fieldName==="ID"&&typeof ac.thisUserId!=="undefined"){return ac.thisUserId}var aC="";var aF={};var aH=aG.fieldNames.length>0?aG.fieldNames.length:1;var aD;var aB=aG.webURL.length>0?aG.webURL:ak().SPServices.SPGetCurrentSite();ak.ajax({async:false,url:aB+"/_layouts/userdisp.aspx?Force=True&"+new Date().getTime(),complete:function(aJ,aI){aD=aJ}});for(N=0;N1){i=RegExp('FieldInternalName="'+aG.fieldNames[N]+'"',"gi")}else{i=RegExp('FieldInternalName="'+aG.fieldName+'"',"gi")}ak(aD.responseText).find("table.ms-formtable td[id^='SPField']").each(function(){if(i.test(ak(this).html())){switch(ak(this).attr("id")){case"SPFieldText":aC=ak(this).text();break;case"SPFieldNote":aC=ak(this).find("div").html();break;case"SPFieldURL":aC=ak(this).find("img").attr("src");break;default:aC=ak(this).text();break}return false}})}if(aG.fieldNames[N]!=="ID"){aC=(typeof aC!=="undefined")?aC.replace(/(^[\s\xA0]+|[\s\xA0]+$)/g,""):null}if(aH>1){aF[aG.fieldNames[N]]=aC}}return(aH>1)?aF:aC};ak.fn.SPServices.SPLookupAddNew=function(aI){var aD=ak.extend({},{lookupColumn:"",promptText:"Add new {0}",newWindow:false,ContentTypeID:"",completefunc:null,debug:false},aI);var aF="SPServices.SPLookupAddNew";var aC=new ar(aD.lookupColumn);if(aC.Obj.html()===null&&aD.debug){W(aF,"lookupColumn: "+aD.lookupColumn,ah);return}var i="";var aH="";var aB="";ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:ak().SPServices.SPListNameFromUrl(),completefunc:function(aK,aJ){ak(aK.responseXML).find("Field[DisplayName='"+aD.lookupColumn+"']").each(function(){aB=ak(this).attr("StaticName");ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:ak(this).attr("List"),completefunc:function(aM,aL){ak(aM.responseXML).find("List").each(function(){aH=ak(this).attr("WebFullUrl");aH=aH!==P?aH+P:aH})}});i=C(ak(this).attr("List"),"NewForm");return false})}});if(aH.length===0&&aD.debug){W(aF,"lookupColumn: "+aD.lookupColumn,"This column does not appear to be a lookup column");return}if(i.length>0){var aG=aH+i;aG+=aD.newWindow?((aD.ContentTypeID.length>0)?"?ContentTypeID="+aD.ContentTypeID:"")+"' target='_blank'":"?"+((aD.ContentTypeID.length>0)?"ContentTypeID="+aD.ContentTypeID+"&":"")+"Source="+z(location.href)+"'";var aE="
"+aC+"";if(aD.CAMLQuery.length>0){i+=aD.CAMLQuery+""}i+="";ak().SPServices({operation:"GetListItems",async:false,webURL:aD.webURL,listName:aD.listName,CAMLQuery:i,CAMLViewFields:"",CAMLRowLimit:1,CAMLQueryOptions:"",completefunc:function(aF){ak(aF.responseXML).SPFilterNode("z:row").each(function(){aE=ak(this).attr("ows_ID")})}});return aE};ak.fn.SPServices.SPRequireUnique=function(aB){var aC=ak.extend({},{columnStaticName:"Title",duplicateAction:0,ignoreCase:false,initMsg:"This value must be unique.",initMsgCSSClass:"ms-vb",errMsg:"This value is not unique.",errMsgCSSClass:"ms-formvalidation",showDupes:false,completefunc:null},aB);var aG=ak().SPServices.SPGetQueryString();var aH=aG.ID;ac.thisList=ak().SPServices.SPListNameFromUrl();var aF="{1}
";var aE=aF.replace(/\{0\}/g,aC.initMsgCSSClass).replace(/\{1\}/g,aC.initMsg);var aD=ak().SPServices.SPGetDisplayFromStatic({listName:ac.thisList,columnStaticName:aC.columnStaticName});var i=ak("input[Title='"+aD+"']");ak(i).parent().append(aE);ak(i).blur(function(){var aK=[];var aL=ak(this).attr("value");if(aL.length===0){return false}ak().SPServices({operation:"GetListItems",async:false,listName:ac.thisList,CAMLQuery:"",CAMLViewFields:"",CAMLRowLimit:0,completefunc:function(aN){var aM=aC.ignoreCase?aL.toUpperCase():aL;ak(aN.responseXML).SPFilterNode("z:row").each(function(){var aO=aC.ignoreCase?ak(this).attr("ows_"+aC.columnStaticName).toUpperCase():ak(this).attr("ows_"+aC.columnStaticName);if((aM===aO)&&(ak(this).attr("ows_ID")!==aH)){aK.push([ak(this).attr("ows_ID"),ak(this).attr("ows_"+aC.columnStaticName)])}})}});var aJ=aC.initMsg;ak("span#SPRequireUnique"+aC.columnStaticName).html(aJ).attr("class",aC.initMsgCSSClass);ak("input[value='OK']:disabled, input[value='Save']:disabled").removeAttr("disabled");if(aK.length>0){aJ=aC.errMsg;ak("span#SPRequireUnique"+aC.columnStaticName).html(aJ).attr("class",aC.errMsgCSSClass);if(aC.duplicateAction===1){ak("input[Title='"+aC.columnDisplayName+"']").focus();ak("input[value='OK'], input[value='Save']").attr("disabled","disabled")}if(aC.showDupes){var aI=" "+aK.length+" duplicate item"+(aK.length>1?"s":"")+": ";for(N=0;N"+aK[N][1]+"
"}ak("span#SPRequireUnique"+aC.columnStaticName).append(aI)}}});if(aC.completefunc!==null){aC.completefunc()}};ak.fn.SPServices.SPGetDisplayFromStatic=function(aB){var aC=ak.extend({},{webURL:"",listName:"",columnStaticName:"",columnStaticNames:{}},aB);var i="";var aD={};var aE=aC.columnStaticNames.length>0?aC.columnStaticNames.length:1;ak().SPServices({operation:"GetList",async:false,cacheXML:true,webURL:aC.webURL,listName:aC.listName,completefunc:function(aF){if(aE>1){for(N=0;N1)?aD:i};ak.fn.SPServices.SPGetStaticFromDisplay=function(i){var aC=ak.extend({},{webURL:"",listName:"",columnDisplayName:"",columnDisplayNames:{}},i);var aB="";var aD={};var aE=aC.columnDisplayNames.length>0?aC.columnDisplayNames.length:1;ak().SPServices({operation:"GetList",async:false,cacheXML:true,webURL:aC.webURL,listName:aC.listName,completefunc:function(aF){if(aE>1){for(N=0;N1)?aD:aB};ak.fn.SPServices.SPRedirectWithID=function(aC){var aD=ak.extend({},{redirectUrl:"",qsParamName:"ID"},aC);ac.thisList=ak().SPServices.SPListNameFromUrl();var aH=ak().SPServices.SPGetQueryString();var aG=aH.ID;var aF=aH.List;var aB=aH.RootFolder;var aE=aH.ContentTypeId;if(typeof aH.ID==="undefined"){aG=ak().SPServices.SPGetLastItemId({listName:ac.thisList});ak("form[name='aspnetForm']").each(function(){var aJ=(location.href.indexOf("?")>0)?location.href.substring(0,location.href.indexOf("?")):location.href;var aK=(typeof aH.Source==="string")?"Source="+aH.Source.replace(/\//g,"%2f").replace(/:/g,"%3a"):"";var aI=[];if(typeof aF!=="undefined"){aI.push("List="+aF)}if(typeof aB!=="undefined"){aI.push("RootFolder="+aB)}if(typeof aE!=="undefined"){aI.push("ContentTypeId="+aE)}var aL=aJ+((aI.length>0)?("?"+aI.join("&")+"&"):"?")+"Source="+aJ+"?ID="+aG+((aK.length>0)?("%26RealSource="+aH.Source):"")+((typeof aH.RedirectURL==="string")?("%26RedirectURL="+aH.RedirectURL):"");ak(this).attr("action",aL)})}else{while(aH.ID===aG){aG=ak().SPServices.SPGetLastItemId({listName:ac.thisList})}var i=(typeof aH.RedirectURL==="string")?aH.RedirectURL:aD.redirectUrl;location.href=i+"?"+aD.qsParamName+"="+aG+((typeof aH.RealSource==="string")?("&Source="+aH.RealSource):"")}};ak.fn.SPServices.SPSetMultiSelectSizes=function(aI){var i=ak.extend({},{multiSelectColumn:"",minWidth:0,maxWidth:0,debug:false},aI);var aF="SPServices.SPSetMultiSelectSizes";var aE=new ar(i.multiSelectColumn);if(aE.Obj.html()===null&&i.debug){W(aF,"multiSelectColumn: "+i.multiSelectColumn,ah);return}if(aE.Type!=="M"&&i.debug){W(aF,"multiSelectColumn: "+i.multiSelectColumn,"Column is not multi-select.");return}var aG=ad("SPSetMultiSelectSizes",i.multiSelectColumn);var aD=ak("").appendTo(aE.container);aD.css({width:"auto",height:0,visibility:"hidden"});ak(aE.master.candidateControl).find("option").each(function(){aD.append("")});ak(aE.master.resultControl).find("option").each(function(){aD.append("")});var aB=aD.width()+5;var aH=aB;if(i.minWidth>0||i.maxWidth>0){if(aBi.maxWidth){aH=i.maxWidth}}var aC=aB;ak(aE.master.candidateControl).css("width",aC+"px").parent().css("width",aH+"px");ak(aE.master.resultControl).css("width",aC+"px").parent().css("width",aH+"px");aD.remove()};ak.fn.SPServices.SPScriptAudit=function(aC){var aD=ak.extend({},{webURL:"",listName:"",outputId:"",auditForms:true,auditViews:true,auditPages:true,auditPagesListName:"Pages",showHiddenLists:false,showNoScript:false,showSrc:true},aC);var aB=[["New","NewForm.aspx",false],["Display","DispForm.aspx",false],["Edit","EditForm.aspx",false]];var aE;ak("#"+aD.outputId).append(""+(aD.showSrc?"":"")+"
ListPage ClassPage TypePageScript References
");ak("#SPScriptAudit th").attr("class","ms-vh2-nofilter");if(aD.auditForms||aD.auditViews){ak().SPServices({operation:"GetListCollection",webURL:aD.webURL,async:false,completefunc:function(aH,aG){ak(aH.responseXML).find("List").each(function(){aE=ak(this);if((aD.listName.length===0)||(aE.attr("Title")===aD.listName)){if((aD.showHiddenLists&&aE.attr("Hidden")==="False")||!aD.showHiddenLists){if(aD.auditForms){ak().SPServices({operation:"GetListContentTypes",webURL:aD.webURL,listName:aE.attr("ID"),async:false,completefunc:function(aJ,aI){ak(aJ.responseXML).find("ContentType").each(function(){if(ak(this).attr("ID").substring(0,6)!=="0x0120"){var aL=ak(this).find("FormUrls");for(N=0;N0)?aD.webURL:ak().SPServices.SPGetCurrentSite())+P+ak(this).text());aB[N][2]=true});if(!aB[N][2]){var aK=aE.attr("DefaultViewUrl");ax(aD,aE,"Form",aB[N][0],aK.substring(0,aK.lastIndexOf(P)+1)+aB[N][1])}}for(N=0;NFolder",CAMLViewFields:"",CAMLRowLimit:0,completefunc:function(aG){ak(aG.responseXML).SPFilterNode("z:row").each(function(){var aJ=ak(this).attr("ows_FileRef").split(";#")[1];var aH=ak(this).attr("ows_Title");var aI=(typeof aH!=="undefined")?aH:"";if(aJ.indexOf(".aspx")>0){ax(aD,aE,"Page",aI,P+aJ)}})}})}}ak("#SPScriptAudit tr[class='ms-alternating']:even").removeAttr("class")};function ax(aB,aC,aJ,aF,aD){var aG=0;var aI=0;var aE={};aE.type=[];aE.src=[];aE.script=[];var aH=RegExp("","gi");ak.ajax({type:"GET",url:aD,dataType:"text",async:false,success:function(aP){var aO;while(aO=aH.exec(aP)){var aK=aj(aO,"language");var aQ=aj(aO,"type");var aM=aj(aO,"src");if(aM!==null&&aM.length>0&&!al(aM)){aE.type.push((aK!==null&&aK.length>0)?aK:aQ);aE.src.push(aM);aI++}}if((!aB.showNoScript&&(aE.type.length>0))||aB.showNoScript){var aN=aD.substring(0,aD.lastIndexOf(P)+1);var aL=""+aC.attr("Title")+((aC.attr("Hidden")==="True")?"(Hidden)":"")+""+aJ+""+aF+""+Q(aD)+"";if(aB.showSrc){var i;aL+="";for(aG=0;aG";aL+=""}aL+="
"+aE.type[aG]+""+Q(aE.src[aG])+"
"}ak("#SPScriptAudit").append(aL)}}})}function aj(aD,aB){var aC;var i=RegExp(aB+"=(\"([^\"]*)\")|('([^']*)')","gi");if(aC=i.exec(aD)){return aC[2]}return null}function al(aD){var aC;var aB=["WebResource.axd","_layouts"];for(aC=0;aC-1){return true}}return false}ak.fn.SPServices.SPArrangeChoices=function(aC){var aD=ak.extend({},{listName:ak().SPServices.SPListNameFromUrl(),columnName:"",perRow:99,randomize:false},aC);var aF=false;var aE=[];var aB;var i=ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:aD.listName});i.done(function(){ak(i.responseXML).find("Field[DisplayName='"+aD.columnName+"']").each(function(){aF=(ak(this).attr("FillInChoice")==="TRUE")?true:false;return false});var aK=y(aD.columnName);var aI=ak(aK).find("tr").length;var aH=0;var aJ;var aG;ak(aK).find("tr").each(function(){aH++;if(aF&&aH===(aI-1)){aJ=ak(this).find("td").html()}else{if(aF&&aH===aI){aG=ak(this).find("td").html()}else{aE.push(ak(this).html())}}});aB="";if(aD.randomize){aE.sort(q)}for(N=0;N"}}aB+="";if(aF){aB+=""+aJ+aG+""}ak(aK).find("tr").remove();ak(aK).find("table").append(aB)})};ak.fn.SPServices.SPAutocomplete=function(aC){var aD=ak.extend({},{webURL:"",sourceList:"",sourceColumn:"",columnName:"",CAMLQuery:"",CAMLQueryOptions:"",CAMLRowLimit:0,filterType:"BeginsWith",numChars:0,ignoreCase:false,highlightClass:"",uniqueVals:false,maxHeight:99999,slideDownSpeed:"fast",processingIndicator:"_layouts/images/REFRESH.GIF",debug:false},aC);var aF;var aB=ak("input[Title='"+aD.columnName+"']");aB.css("position","");var aE=aB.css("color");var aG=aB.css("width");if(aB.html()===null&&aD.debug){W("SPServices.SPAutocomplete","columnName: "+aD.columnName,"Column is not an input control or is not found on page");return}aB.closest("span").find("br").remove();aB.wrap("
");var i=ad("SPAutocomplete",aD.columnName);aB.after("
");ak("#"+i).css("width",aG);ak(aB).keyup(function(){var aP=ak(this).val();ak("#"+i).hide();if(aP.length";if(aD.CAMLQuery.length>0){aH+=""}aH+="<"+aD.filterType+">"+aP+"";if(aD.CAMLQuery.length>0){aH+=aD.CAMLQuery+""}aH+="";ak().SPServices({operation:"GetListItems",async:false,webURL:aD.WebURL,listName:aD.sourceList,CAMLQuery:aH,CAMLQueryOptions:aD.CAMLQueryOptions,CAMLViewFields:"",CAMLRowLimit:aD.CAMLRowLimit,completefunc:function(aS){var aR=aD.ignoreCase?aP.toUpperCase():aP;ak(aS.responseXML).SPFilterNode("z:row").each(function(){var aU=ak(this).attr("ows_"+aD.sourceColumn);var aV=aD.ignoreCase?ak(this).attr("ows_"+aD.sourceColumn).toUpperCase():ak(this).attr("ows_"+aD.sourceColumn);if(aD.filterType==="Contains"){var aT=aV.indexOf(aR);if((aT>=0)&&(!aD.uniqueVals||(ak.inArray(aU,aO)===-1))){aO.push(ak(this).attr("ows_"+aD.sourceColumn))}}else{if(aR===aV.substr(0,aR.length)&&(!aD.uniqueVals||(ak.inArray(aU,aO)===-1))){aO.push(ak(this).attr("ows_"+aD.sourceColumn))}}})}});var aK="";for(N=0;N0){var aJ=new RegExp(aP,aD.ignoreCase?"gi":"g");var aM=aO[N].match(aJ);var aL=0;for(aF=0;aF"+aM[aF]+"";aO[N]=aO[N].substr(0,aN)+aQ+aO[N].substr(aI);aL=aN+aQ.length}}aK+="
  • "+aO[N]+"
  • "}ak("#"+i).html(aK);ak("#"+i+" li").click(function(){ak("#"+i).fadeOut(aD.slideUpSpeed);aB.val(ak(this).text())}).mouseover(function(){var aR={cursor:"hand",color:"#ffffff",background:"#3399ff"};ak(this).css(aR)}).mouseout(function(){var aR={cursor:"inherit",color:aE,background:"transparent"};ak(this).css(aR)});if(aO.length>0){ak("#"+i).slideDown(aD.slideDownSpeed)}aB.css("background-image","")})};ak.fn.SPServices.SPGetQueryString=function(){var aG={};var aF;var aB=location.search.substring(1,location.search.length);var aC=aB.split("&");var aE=/^([^=]+)=(.*)/i;for(var aD=0;aD2){aG[aF[1]]=unescape(aF[2]).replace(/\+/g," ")}}}return aG};ak.fn.SPServices.SPListNameFromUrl=function(i){var aB=ak.extend({},{listName:""},i);if(aB.listName.length>0){ac.thisList=aB.listName;return ac.thisList}else{if(ac.thisList.length>0){return ac.thisList}}var aD=location.href;var aC=aD.substring(0,aD.indexOf(".aspx"));var aE=decodeURIComponent(aC.substring(0,aC.lastIndexOf(P)+1)).toUpperCase();ak().SPServices({operation:"GetListCollection",async:false,completefunc:function(aG,aF){ak(aG.responseXML).find("List").each(function(){var aH=ak(this).attr("DefaultViewUrl");var aI=aH.substring(0,aH.lastIndexOf(P)+1).toUpperCase();if(aE.indexOf(aI)>0){ac.thisList=ak(this).attr("ID");return false}})}});return ac.thisList};ak.fn.SPServices.SPUpdateMultipleListItems=function(aD){var aF=ak.extend({},{webURL:"",listName:"",CAMLQuery:"",batchCmd:"Update",valuepairs:[],completefunc:null,debug:false},aD);var aE;var aH=[];var aG=[];ak().SPServices({operation:"GetListItems",async:false,webURL:aF.webURL,listName:aF.listName,CAMLQuery:aF.CAMLQuery,CAMLQueryOptions:"",completefunc:function(i){ak(i.responseXML).SPFilterNode("z:row").each(function(){aH.push(ak(this).attr("ows_ID"));var aI=ak(this).attr("ows_FileRef");aI="/"+aI.substring(aI.indexOf(";#")+2);aG.push(aI)})}});var aB;var aC="";for(aE=0;aE";for(aB=0;aB"+K(aF.valuepairs[aB][1])+""}aC+=""+aH[aE]+"";if(aG[aE].length>0){aC+=""+aG[aE]+""}aC+=""}aC+="";ak().SPServices({operation:"UpdateListItems",async:false,webURL:aF.webURL,listName:aF.listName,updates:aC,completefunc:function(i){if(aF.completefunc!==null){aF.completefunc(i,Status)}}})};ak.fn.SPFilterNode=function(i){return this.find("*").filter(function(){return this.nodeName===i})};ak.fn.SPXmlToJson=function(i){var aC=ak.extend({},{mapping:{},includeAllAttrs:false,removeOws:true},i);var aD;var aB=[];this.each(function(){var aH={};var aJ=this.attributes;ak.each(aC.mapping,function(){aH[this.mappedName]=""});for(aD=0;aD0){aB.html(aD.valueToSet)}if(aD.checkNames){i.click()}var aF=ak.trim(aB.text());var aE=[];aB.children("span").each(function(){var aJ=ak(this).find("div[data]").attr("data");var aH={};if(typeof aJ!=="undefined"){var aK=ak.parseXML(aJ);var aI=ak(aK);aI.find("DictionaryEntry").each(function(){var aL=ak(this).find("Key").text();var aM=ak(this).find("Value").text();aH[aL]=aM});aE.push(aH)}else{ak().SPServices({operation:"GetUserInfo",async:false,cacheXML:true,userLoginName:ak(this).attr("title"),completefunc:function(aL){ak(aL.responseXML).find("User").each(function(){ak.each(this.attributes,function(aN,aP){var aM=aP.name;var aO=aP.value;aH[aM]=aO});aE.push(aH)})}})}});return{row:aG,contents:aB,currentValue:aF,checkNames:i,dictionaryEntries:aE}};ak.fn.SPServices.Version=function(){return Z};function ap(){if(typeof _spPageContextInfo!=="undefined"){this.thisSite=_spPageContextInfo.webAbsoluteUrl;this.thisList=_spPageContextInfo.pageListId;this.thisUserId=_spPageContextInfo.userId}else{this.thisSite="";this.thisList="";this.thisUserId=(typeof _spUserId!=="undefined")?_spUserId:undefined}}function V(aM,aI,aN,aD){if(typeof aN==="undefined"){return""}var aJ;var aK="";var aH;var aF;var aL=[];var aE=aD.relatedWebURL.length>0?aD.relatedWebURL:ak().SPServices.SPGetCurrentSite();switch(aI.attr("Type")){case"Text":aK=aN;break;case"URL":switch(aI.attr("Format")){case"Hyperlink":aK="
    "+aN.substring(aN.search(",")+1)+"";break;case"Image":aK=""+aN.substring(aN.search(",")+1)+"";break;default:aK=aN;break}break;case"User":case"UserMulti":var aB=aN.split(";#");for(aJ=0;aJ"+aB[aJ+1]+"")}aK=aL.join(", ");break;case"Calculated":var aG=aN.split(";#");aK=aG[1];break;case"Number":aF=aI.attr("Decimals");aK=typeof aF==="undefined"?parseFloat(aN).toString():parseFloat(aN).toFixed(aF).toString();break;case"Currency":aF=aI.attr("Decimals");aK=typeof aF==="undefined"?parseFloat(aN).toFixed(2).toString():parseFloat(aN).toFixed(aF).toString();break;case"Lookup":switch(aI.attr("Name")){case"FileRef":aH=aM.attr("BaseType")==="1"?aM.attr("RootFolder")+P+"Forms/DispForm.aspx":aM.attr("RootFolder")+P+"DispForm.aspx";aK=""+aN.substring(aN.search(";#")+2)+"";break;case"FileDirRef":aH=P+aN.substring(aN.search(";#")+2);aK=""+aN.substring(aN.search(";#")+2)+"";break;default:aH=C(aI.attr("List"),"DisplayForm");aK=""+aN.substring(aN.search(";#")+2)+"";break}break;case"LookupMulti":aH=C(aI.attr("List"),"DisplayForm");aK="";if(aN.length>0){var aC=aN.split(";#");for(aJ=0;aJ"+aC[(aJ*2)+1]+"")}}aK=aL.join(", ");break;case"File":Q=aN.substring(aN.search(";#")+2);aK=""+Q+"";break;case"Counter":aK=aN;break;case"DateTime":aK=aN;break;default:aK=aN;break}return aK}function t(aD){var aC;var aB="";for(aC=0;aC"}aB+="
    "+aC+""+aD.attributes.item(aC).nodeName+""+M(aD.attributes.item(aC).nodeValue)+"
    ";return aB}function ar(aB){if((this.Obj=ak("select[Title='"+aB+"']")).length===1){this.Type="S"}else{if((this.Obj=ak("input[Title='"+aB+"']")).length===1){this.Type="C"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title^='"+aB+" ']")).length===1){this.Type="M"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title$=': "+aB+"']")).length===1){this.Type="M"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title$='\""+aB+"\".']")).length===1){this.Type="M"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title$=' "+aB+"']")).length===1){this.Type="M"}else{this.Type=null}}}}}}if(this.Type==="M"){this.container=this.Obj.closest("span");this.MultiLookupPickerdata=this.container.find("input[id$='"+an+"_data'], input[id$='"+g+"_data']");var i=this.container.find("[id$='AddButton']").attr("id");this.master=window[i.replace(/AddButton/,an+"_m")]||window[i.replace(/AddButton/,g+"_m")]}}function c(aC,aB){var i=[];switch(aC.Type){case"S":if(aB){i.push(aC.Obj.find("option:selected").val()||[])}else{i.push(aC.Obj.find("option:selected").text()||[])}break;case"C":if(aB){i.push(ak("input[id='"+aC.Obj.attr("optHid")+"']").val()||[])}else{i.push(aC.Obj.val()||[])}break;case"M":ak(aC.master.resultControl).find("option").each(function(){if(aB){i.push(ak(this).val())}else{i.push(ak(this).html())}});break;default:break}return i}function W(aB,aD,aC){var i="Error in function
    "+aB+"
    Parameter
    "+aD+"
    Message
    "+aC+"

    Click to continue
    ";U(i)}function U(aF){var aC="position:absolute;width:300px;height:150px;padding:10px;background-color:#000000;color:#ffffff;z-index:30;font-family:'Arial';font-size:12px;display:none;";ak("#aspnetForm").parent().append("
    "+aF);var i=ak("#SPServices_msgBox").height();var aE=ak("#SPServices_msgBox").width();var aD=(ak(window).width()/2)-(aE/2)+"px";var aB=(ak(window).height()/2)-(i/2)-100+"px";ak("#SPServices_msgBox").css({border:"5px #C02000 solid",left:aD,top:aB}).show().fadeTo("slow",0.75).click(function(){ak(this).fadeOut("3000",function(){ak(this).remove()})})}function ad(i,aB){return i+"_"+ak().SPServices.SPGetStaticFromDisplay({listName:ak().SPServices.SPListNameFromUrl(),columnDisplayName:aB})}function C(i,aC){var aB;ak().SPServices({operation:"GetFormCollection",async:false,listName:i,completefunc:function(aE,aD){aB=ak(aE.responseXML).find("Form[Type='"+aC+"']").attr("Url")}});return aB}function aq(aD,aB){var aC;for(aC=0;aC"+i+""}function q(){return(Math.round(Math.random())-0.5)}function M(i){return((i.indexOf("http")===0)||(i.indexOf(P)===0))?""+i+"":i}function Q(i){return i.substring(i.lastIndexOf(P)+1,i.length)}var X={"&":"&",'"':""","<":"<",">":">"};var G={"&":"&",""":'"',"<":"<",">":">"};function j(i){return i.replace(/([\&"<>])/g,function(aC,aB){return X[aB]})}function H(i){return i.replace(/("|<|>|&)/g,function(aC,aB){return G[aB]})}function K(i){if(typeof i==="string"){return i.replace(/&(?![a-zA-Z]{1,8};)/g,"&")}else{return i}}function z(i){return i.replace(/&/g,"%26")}function n(i){var aB=i.split(";#");this.id=aB[0];this.value=aB[1]}})(jQuery); diff --git a/jquery.SPServices-2013.02.js b/jquery.SPServices-2013.02a.js similarity index 99% rename from jquery.SPServices-2013.02.js rename to jquery.SPServices-2013.02a.js index b10678d..05b892f 100644 --- a/jquery.SPServices-2013.02.js +++ b/jquery.SPServices-2013.02a.js @@ -1,6 +1,6 @@ /* * SPServices - Work with SharePoint's Web Services using jQuery - * Version 2013.02 + * Version 2013.02a * @requires jQuery v1.8 or greater - jQuery 1.10.x recommended * * Copyright (c) 2009-2013 Sympraxis Consulting LLC @@ -17,14 +17,14 @@ * @author Sympraxis Consulting LLC/marc.anderson@sympraxisconsulting.com */ /* jshint undef: true */ -/* global _spUserId, _spPageContextInfo, GipAddSelectedItems, GipRemoveSelectedItems, GipGetGroupData */ +/* global L_Menu_BaseUrl, _spUserId, _spPageContextInfo, GipAddSelectedItems, GipRemoveSelectedItems, GipGetGroupData */ (function ($) { "use strict"; // Version info - var VERSION = "2012.02"; // TODO: Update version + var VERSION = "2012.02a"; // TODO: Update version // String constants // General @@ -416,12 +416,13 @@ // Build the URL for the Ajax call based on which operation we're calling // If the webURL has been provided, then use it, else use the current site var ajaxURL = "_vti_bin/" + WSops[opt.operation][0] + ".asmx"; + var thisSite = $().SPServices.SPGetCurrentSite(); if(opt.webURL.charAt(opt.webURL.length - 1) === SLASH) { ajaxURL = opt.webURL + ajaxURL; } else if(opt.webURL.length > 0) { ajaxURL = opt.webURL + SLASH + ajaxURL; } else { - ajaxURL = $().SPServices.SPGetCurrentSite() + SLASH + ajaxURL; + ajaxURL = thisSite + ((thisSite.charAt(thisSite.length - 1) === SLASH) ? ajaxURL : (SLASH + ajaxURL)); } SOAPEnvelope.payload = ""; @@ -536,7 +537,7 @@ addToPayload(opt, ["listName", "viewFields", "since", "contains"]); break; case "GetListItemChangesSinceToken": - addToPayload(opt, ["listName", "viewName", "query", "viewFields", "rowLimit", "queryOptions", "changeToken", "contains"]); + addToPayload(opt, ["listName", "viewName", ["query", "CAMLQuery"], ["viewFields", "CAMLViewFields"], ["rowLimit", "CAMLRowLimit"], ["queryOptions", "CAMLQueryOptions"], {name: "changeToken", sendNull: false}, {name: "contains", sendNull: false}]); break; case "GetVersionCollection": addToPayload(opt, ["strlistID", "strlistItemID", "strFieldName"]); @@ -1813,9 +1814,10 @@ // Get info about the related list relatedListXML = $(xData.responseXML).find("List"); // Save the information about each column requested - for (i=0; i < opt.relatedColumns.length; i++) { + for(i=0; i < opt.relatedColumns.length; i++) { relatedColumnsXML[opt.relatedColumns[i]] = $(xData.responseXML).find("Fields > Field[Name='" + opt.relatedColumns[i] + "']"); } + relatedColumnsXML[opt.relatedListColumn] = $(xData.responseXML).find("Fields > Field[Name='" + opt.relatedListColumn + "']"); } }); @@ -1888,7 +1890,7 @@ camlQuery += "" : opt.relatedListColumn + "'/>") + escapeColumnValue(columnSelectSelected[0]) + ""; - }; + } if(opt.CAMLQuery.length > 0) { camlQuery += opt.CAMLQuery + ""; @@ -2709,7 +2711,7 @@ "width": "auto", // We want the clone to resize its width based on the contents "height": 0, // Just to keep the page clean while we are using the clone "visibility": "hidden" // And let's keep it hidden - }) + }); // Add all the values to the cloned select. First the left (possible values) select... $(thisMultiSelect.master.candidateControl).find("option").each(function() { @@ -3254,7 +3256,7 @@ matches = rxQS.exec(args[i]); if(rxQS.test(location.href)) { if(matches !== null && matches.length > 2) { - queryStringVals[matches[1]] = unescape(matches[2]).replace(/\+/g,' '); + queryStringVals[matches[1]] = decodeURIComponent(matches[2]).replace(/\+/g,' '); } } } @@ -3365,7 +3367,7 @@ completefunc: function(xData) { // If present, call completefunc when all else is done if(opt.completefunc !== null) { - opt.completefunc(xData, Status); + opt.completefunc(xData); } } }); @@ -3668,12 +3670,12 @@ // SharePoint 2010 gives us a context variable if(typeof _spPageContextInfo !== "undefined") { - this.thisSite = _spPageContextInfo.webAbsoluteUrl; + this.thisSite = _spPageContextInfo.webServerRelativeUrl; this.thisList = _spPageContextInfo.pageListId; this.thisUserId = _spPageContextInfo.userId; // In SharePoint 2007, we know the UserID only } else { - this.thisSite = ""; + this.thisSite = L_Menu_BaseUrl; this.thisList = ""; this.thisUserId = (typeof _spUserId !== "undefined") ? _spUserId : undefined; } @@ -3947,17 +3949,21 @@ // paramArray = an array of option names to add to the payload // "paramName" if the parameter name and the option name match // ["paramName", "optionName"] if the parameter name and the option name are different (this handles early "wrappings" with inconsistent naming) + // {name: "paramName", sendNull: false} indicates the element is marked as "add to payload only if non-null" function addToPayload(opt, paramArray) { var i; - for (i=0; i < paramArray.length; i++) { + for(i=0; i < paramArray.length; i++) { // the parameter name and the option name match if(typeof paramArray[i] === "string") { SOAPEnvelope.payload += wrapNode(paramArray[i], opt[paramArray[i]]); // the parameter name and the option name are different - } else if(paramArray[i].length === 2) { + } else if($.isArray(paramArray[i]) && paramArray[i].length === 2) { SOAPEnvelope.payload += wrapNode(paramArray[i][0], opt[paramArray[i][1]]); + // the element not a string or an array and is marked as "add to payload only if non-null" + } else if((typeof paramArray[i] === "object") && (paramArray[i].sendNull !== undefined)) { + SOAPEnvelope.payload += ((opt[paramArray[i].name] === undefined) || (opt[paramArray[i].name].length === 0)) ? "" : wrapNode(paramArray[i].name, opt[paramArray[i].name]); // something isn't right, so report it } else { errBox(opt.operation, "paramArray[" + i + "]: " + paramArray[i], "Invalid paramArray element passed to addToPayload()"); @@ -4063,5 +4069,4 @@ this.value = spl[1]; } - })(jQuery); \ No newline at end of file diff --git a/jquery.SPServices-2013.02a.min.js b/jquery.SPServices-2013.02a.min.js new file mode 100644 index 0000000..4b81ca0 --- /dev/null +++ b/jquery.SPServices-2013.02a.min.js @@ -0,0 +1,21 @@ +/* + * SPServices - Work with SharePoint's Web Services using jQuery + * Version 2013.02a + * @requires jQuery v1.8 or greater - jQuery 1.10.x recommended + * + * Copyright (c) 2009-2013 Sympraxis Consulting LLC + * Examples and docs at: + * http://spservices.codeplex.com + * Licensed under the MIT license: + * http://www.opensource.org/licenses/mit-license.php + */ +/* + * @description Work with SharePoint's Web Services using jQuery + * @type jQuery + * @name SPServices + * @category Plugins/SPServices + * @author Sympraxis Consulting LLC/marc.anderson@sympraxisconsulting.com + */ +/* jshint undef: true */ +/* global L_Menu_BaseUrl, _spUserId, _spPageContextInfo, GipAddSelectedItems, GipRemoveSelectedItems, GipGetGroupData */ +(function(ak){var Z="2012.02a";var P="/";var ah="Column not found on page";var ab="http://schemas.microsoft.com/sharepoint";var an="MultiLookupPicker";var g="MultiLookup";var A={};var b="Alerts";var u="Authentication";var am="Copy";var F="Forms";var at="Lists";var m="Meetings";var B="People";var f="Permissions";var h="PublishedLinksService";var ai="Search";var ag="SharePointDiagnostics";var Y="SiteData";var aA="Sites";var I="SocialDataService";var ae="SpellCheck";var o="TaxonomyClientService";var l="usergroup";var J="UserProfileService";var D="Versions";var az="Views";var e="WebPartPages";var aw="Webs";var E="Workflow";var ac=new ap();var N=0;var x=["listName","description"];var T=[];T.GetAlerts=[b,false];T.DeleteAlerts=[b,true];T.Mode=[u,false];T.Login=[u,false];T.CopyIntoItems=[am,true];T.CopyIntoItemsLocal=[am,true];T.GetItem=[am,false];T.GetForm=[F,false];T.GetFormCollection=[F,false];T.AddAttachment=[at,true];T.AddDiscussionBoardItem=[at,true];T.AddList=[at,true];T.AddListFromFeature=[at,true];T.ApplyContentTypeToList=[at,true];T.CheckInFile=[at,true];T.CheckOutFile=[at,true];T.CreateContentType=[at,true];T.DeleteAttachment=[at,true];T.DeleteContentType=[at,true];T.DeleteContentTypeXmlDocument=[at,true];T.DeleteList=[at,true];T.GetAttachmentCollection=[at,false];T.GetList=[at,false];T.GetListAndView=[at,false];T.GetListCollection=[at,false];T.GetListContentType=[at,false];T.GetListContentTypes=[at,false];T.GetListItemChanges=[at,false];T.GetListItemChangesSinceToken=[at,false];T.GetListItems=[at,false];T.GetVersionCollection=[at,false];T.UndoCheckOut=[at,true];T.UpdateContentType=[at,true];T.UpdateContentTypesXmlDocument=[at,true];T.UpdateContentTypeXmlDocument=[at,true];T.UpdateList=[at,true];T.UpdateListItems=[at,true];T.AddMeeting=[m,true];T.CreateWorkspace=[m,true];T.RemoveMeeting=[m,true];T.SetWorkSpaceTitle=[m,true];T.ResolvePrincipals=[B,false];T.SearchPrincipals=[B,false];T.AddPermission=[f,true];T.AddPermissionCollection=[f,true];T.GetPermissionCollection=[f,true];T.RemovePermission=[f,true];T.RemovePermissionCollection=[f,true];T.UpdatePermission=[f,true];T.GetLinks=[h,true];T.GetPortalSearchInfo=[ai,false];T.GetQuerySuggestions=[ai,false];T.GetSearchMetadata=[ai,false];T.Query=[ai,false];T.QueryEx=[ai,false];T.Registration=[ai,false];T.Status=[ai,false];T.SendClientScriptErrorReport=[ag,true];T.GetAttachments=[Y,false];T.EnumerateFolder=[Y,false];T.SiteDataGetList=[Y,false];T.SiteDataGetListCollection=[Y,false];T.SiteDataGetSite=[Y,false];T.SiteDataGetSiteUrl=[Y,false];T.SiteDataGetWeb=[Y,false];T.CreateWeb=[aA,true];T.DeleteWeb=[aA,false];T.GetSite=[aA,false];T.GetSiteTemplates=[aA,false];T.AddComment=[I,true];T.AddTag=[I,true];T.AddTagByKeyword=[I,true];T.CountCommentsOfUser=[I,false];T.CountCommentsOfUserOnUrl=[I,false];T.CountCommentsOnUrl=[I,false];T.CountRatingsOnUrl=[I,false];T.CountTagsOfUser=[I,false];T.DeleteComment=[I,true];T.DeleteRating=[I,true];T.DeleteTag=[I,true];T.DeleteTagByKeyword=[I,true];T.DeleteTags=[I,true];T.GetAllTagTerms=[I,false];T.GetAllTagTermsForUrlFolder=[I,false];T.GetAllTagUrls=[I,false];T.GetAllTagUrlsByKeyword=[I,false];T.GetCommentsOfUser=[I,false];T.GetCommentsOfUserOnUrl=[I,false];T.GetCommentsOnUrl=[I,false];T.GetRatingAverageOnUrl=[I,false];T.GetRatingOfUserOnUrl=[I,false];T.GetRatingOnUrl=[I,false];T.GetRatingsOfUser=[I,false];T.GetRatingsOnUrl=[I,false];T.GetSocialDataForFullReplication=[I,false];T.GetTags=[I,true];T.GetTagsOfUser=[I,true];T.GetTagTerms=[I,true];T.GetTagTermsOfUser=[I,true];T.GetTagTermsOnUrl=[I,true];T.GetTagUrlsOfUser=[I,true];T.GetTagUrlsOfUserByKeyword=[I,true];T.GetTagUrls=[I,true];T.GetTagUrlsByKeyword=[I,true];T.SetRating=[I,true];T.UpdateComment=[I,true];T.SpellCheck=[ae,false];T.AddTerms=[o,true];T.GetChildTermsInTerm=[o,false];T.GetChildTermsInTermSet=[o,false];T.GetKeywordTermsByGuids=[o,false];T.GetTermsByLabel=[o,false];T.GetTermSets=[o,false];T.AddGroup=[l,true];T.AddGroupToRole=[l,true];T.AddRole=[l,true];T.AddRoleDef=[l,true];T.AddUserCollectionToGroup=[l,true];T.AddUserCollectionToRole=[l,true];T.AddUserToGroup=[l,true];T.AddUserToRole=[l,true];T.GetAllUserCollectionFromWeb=[l,false];T.GetGroupCollection=[l,false];T.GetGroupCollectionFromRole=[l,false];T.GetGroupCollectionFromSite=[l,false];T.GetGroupCollectionFromUser=[l,false];T.GetGroupCollectionFromWeb=[l,false];T.GetGroupInfo=[l,false];T.GetRoleCollection=[l,false];T.GetRoleCollectionFromGroup=[l,false];T.GetRoleCollectionFromUser=[l,false];T.GetRoleCollectionFromWeb=[l,false];T.GetRoleInfo=[l,false];T.GetRolesAndPermissionsForCurrentUser=[l,false];T.GetRolesAndPermissionsForSite=[l,false];T.GetUserCollection=[l,false];T.GetUserCollectionFromGroup=[l,false];T.GetUserCollectionFromRole=[l,false];T.GetUserCollectionFromSite=[l,false];T.GetUserCollectionFromWeb=[l,false];T.GetUserInfo=[l,false];T.GetUserLoginFromEmail=[l,false];T.RemoveGroup=[l,true];T.RemoveGroupFromRole=[l,true];T.RemoveRole=[l,true];T.RemoveUserCollectionFromGroup=[l,true];T.RemoveUserCollectionFromRole=[l,true];T.RemoveUserCollectionFromSite=[l,true];T.RemoveUserFromGroup=[l,true];T.RemoveUserFromRole=[l,true];T.RemoveUserFromSite=[l,true];T.RemoveUserFromWeb=[l,true];T.UpdateGroupInfo=[l,true];T.UpdateRoleDefInfo=[l,true];T.UpdateRoleInfo=[l,true];T.UpdateUserInfo=[l,true];T.AddColleague=[J,true];T.AddLink=[J,true];T.AddMembership=[J,true];T.AddPinnedLink=[J,true];T.CreateMemberGroup=[J,true];T.CreateUserProfileByAccountName=[J,true];T.GetCommonColleagues=[J,false];T.GetCommonManager=[J,false];T.GetCommonMemberships=[J,false];T.GetInCommon=[J,false];T.GetPropertyChoiceList=[J,false];T.GetUserColleagues=[J,false];T.GetUserLinks=[J,false];T.GetUserMemberships=[J,false];T.GetUserPinnedLinks=[J,false];T.GetUserProfileByGuid=[J,false];T.GetUserProfileByIndex=[J,false];T.GetUserProfileByName=[J,false];T.GetUserProfileCount=[J,false];T.GetUserProfileSchema=[J,false];T.ModifyUserPropertyByAccountName=[J,true];T.RemoveAllColleagues=[J,true];T.RemoveAllLinks=[J,true];T.RemoveAllMemberships=[J,true];T.RemoveAllPinnedLinks=[J,true];T.RemoveColleague=[J,true];T.RemoveLink=[J,true];T.RemoveMembership=[J,true];T.RemovePinnedLink=[J,true];T.UpdateColleaguePrivacy=[J,true];T.UpdateLink=[J,true];T.UpdateMembershipPrivacy=[J,true];T.UpdatePinnedLink=[J,true];T.DeleteAllVersions=[D,true];T.DeleteVersion=[D,true];T.GetVersions=[D,false];T.RestoreVersion=[D,true];T.AddView=[az,true];T.DeleteView=[az,true];T.GetView=[az,false];T.GetViewHtml=[az,false];T.GetViewCollection=[az,false];T.UpdateView=[az,true];T.UpdateViewHtml=[az,true];T.AddWebPart=[e,true];T.AddWebPartToZone=[e,true];T.GetWebPart2=[e,false];T.GetWebPartPage=[e,false];T.GetWebPartProperties=[e,false];T.GetWebPartProperties2=[e,false];T.CreateContentType=[aw,true];T.GetColumns=[aw,false];T.GetContentType=[aw,false];T.GetContentTypes=[aw,false];T.GetCustomizedPageStatus=[aw,false];T.GetListTemplates=[aw,false];T.GetObjectIdFromUrl=[aw,false];T.GetWeb=[aw,false];T.GetWebCollection=[aw,false];T.GetAllSubWebCollection=[aw,false];T.UpdateColumns=[aw,true];T.UpdateContentType=[aw,true];T.WebUrlFromPageUrl=[aw,false];T.AlterToDo=[E,true];T.GetTemplatesForItem=[E,false];T.GetToDosForItem=[E,false];T.GetWorkflowDataForItem=[E,false];T.GetWorkflowTaskData=[E,false];T.StartWorkflow=[E,true];var S={};S.header="";S.footer="";S.payload="";var aa;ak.fn.SPServices=function(aC){var aE=ak.extend({},ak.fn.SPServices.defaults,aC);for(var aD=0;aD";aa=ab+"/soap/2002/1/alerts/";break;case m:S.opheader+="xmlns='"+ab+"/soap/meetings/' >";aa=ab+"/soap/meetings/";break;case f:S.opheader+="xmlns='"+ab+"/soap/directory/' >";aa=ab+"/soap/directory/";break;case h:S.opheader+="xmlns='http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService/' >";aa="http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService/";break;case ai:S.opheader+="xmlns='urn:Microsoft.Search' >";aa="urn:Microsoft.Search/";break;case ag:S.opheader+="xmlns='"+ab+"/diagnostics/' >";aa="http://schemas.microsoft.com/sharepoint/diagnostics/";break;case I:S.opheader+="xmlns='http://microsoft.com/webservices/SharePointPortalServer/SocialDataService' >";aa="http://microsoft.com/webservices/SharePointPortalServer/SocialDataService/";break;case ae:S.opheader+="xmlns='http://schemas.microsoft.com/sharepoint/publishing/spelling/' >";aa="http://schemas.microsoft.com/sharepoint/publishing/spelling/SpellCheck";break;case o:S.opheader+="xmlns='"+ab+"/taxonomy/soap/' >";aa=ab+"/taxonomy/soap/";break;case l:S.opheader+="xmlns='"+ab+"/soap/directory/' >";aa=ab+"/soap/directory/";break;case J:S.opheader+="xmlns='http://microsoft.com/webservices/SharePointPortalServer/UserProfileService' >";aa="http://microsoft.com/webservices/SharePointPortalServer/UserProfileService/";break;case e:S.opheader+="xmlns='http://microsoft.com/sharepoint/webpartpages' >";aa="http://microsoft.com/sharepoint/webpartpages/";break;case E:S.opheader+="xmlns='"+ab+"/soap/workflow/' >";aa=ab+"/soap/workflow/";break;default:S.opheader+="xmlns='"+ab+"/soap/'>";aa=ab+"/soap/";break}aa+=aE.operation;S.opfooter="";var aG="_vti_bin/"+T[aE.operation][0]+".asmx";var aB=ak().SPServices.SPGetCurrentSite();if(aE.webURL.charAt(aE.webURL.length-1)===P){aG=aE.webURL+aG}else{if(aE.webURL.length>0){aG=aE.webURL+P+aG}else{aG=aB+((aB.charAt(aB.length-1)===P)?aG:(P+aG))}}S.payload="";switch(aE.operation){case"GetAlerts":break;case"DeleteAlerts":S.payload+="";for(aD=0;aD";break;case"Mode":break;case"Login":aq(aE,["username","password"]);break;case"CopyIntoItems":aq(aE,["SourceUrl"]);S.payload+="";for(aD=0;aD";aq(aE,["Fields","Stream","Results"]);break;case"CopyIntoItemsLocal":aq(aE,["SourceUrl"]);S.payload+="";for(aD=0;aD";break;case"GetItem":aq(aE,["Url","Fields","Stream"]);break;case"GetForm":aq(aE,["listName","formUrl"]);break;case"GetFormCollection":aq(aE,["listName"]);break;case"AddAttachment":aq(aE,["listName","listItemID","fileName","attachment"]);break;case"AddDiscussionBoardItem":aq(aE,["listName","message"]);break;case"AddList":aq(aE,["listName","description","templateID"]);break;case"AddListFromFeature":aq(aE,["listName","description","featureID","templateID"]);break;case"ApplyContentTypeToList":aq(aE,["webUrl","contentTypeId","listName"]);break;case"CheckInFile":aq(aE,["pageUrl","comment","CheckinType"]);break;case"CheckOutFile":aq(aE,["pageUrl","checkoutToLocal","lastmodified"]);break;case"CreateContentType":aq(aE,["listName","displayName","parentType","fields","contentTypeProperties","addToView"]);break;case"DeleteAttachment":aq(aE,["listName","listItemID","url"]);break;case"DeleteContentType":aq(aE,["listName","contentTypeId"]);break;case"DeleteContentTypeXmlDocument":aq(aE,["listName","contentTypeId","documentUri"]);break;case"DeleteList":aq(aE,["listName"]);break;case"GetAttachmentCollection":aq(aE,["listName",["listItemID","ID"]]);break;case"GetList":aq(aE,["listName"]);break;case"GetListAndView":aq(aE,["listName","viewName"]);break;case"GetListCollection":break;case"GetListContentType":aq(aE,["listName","contentTypeId"]);break;case"GetListContentTypes":aq(aE,["listName"]);break;case"GetListItems":aq(aE,["listName","viewName",["query","CAMLQuery"],["viewFields","CAMLViewFields"],["rowLimit","CAMLRowLimit"],["queryOptions","CAMLQueryOptions"]]);break;case"GetListItemChanges":aq(aE,["listName","viewFields","since","contains"]);break;case"GetListItemChangesSinceToken":aq(aE,["listName","viewName",["query","CAMLQuery"],["viewFields","CAMLViewFields"],["rowLimit","CAMLRowLimit"],["queryOptions","CAMLQueryOptions"],{name:"changeToken",sendNull:false},{name:"contains",sendNull:false}]);break;case"GetVersionCollection":aq(aE,["strlistID","strlistItemID","strFieldName"]);break;case"UndoCheckOut":aq(aE,["pageUrl"]);break;case"UpdateContentType":aq(aE,["listName","contentTypeId","contentTypeProperties","newFields","updateFields","deleteFields","addToView"]);break;case"UpdateContentTypesXmlDocument":aq(aE,["listName","newDocument"]);break;case"UpdateContentTypeXmlDocument":aq(aE,["listName","contentTypeId","newDocument"]);break;case"UpdateList":aq(aE,["listName","listProperties","newFields","updateFields","deleteFields","listVersion"]);break;case"UpdateListItems":aq(aE,["listName"]);if(typeof aE.updates!=="undefined"&&aE.updates.length>0){aq(aE,["updates"])}else{S.payload+="";for(aD=0;aD"+K(aE.valuepairs[aD][1])+""}if(aE.batchCmd!=="New"){S.payload+=""+aE.ID+""}S.payload+=""}break;case"AddMeeting":aq(aE,["organizerEmail","uid","sequence","utcDateStamp","title","location","utcDateStart","utcDateEnd","nonGregorian"]);break;case"CreateWorkspace":aq(aE,["title","templateName","lcid","timeZoneInformation"]);break;case"RemoveMeeting":aq(aE,["recurrenceId","uid","sequence","utcDateStamp","cancelMeeting"]);break;case"SetWorkspaceTitle":aq(aE,["title"]);break;case"ResolvePrincipals":aq(aE,["principalKeys","principalType","addToUserInfoList"]);break;case"SearchPrincipals":aq(aE,["searchText","maxResults","principalType"]);break;case"AddPermission":aq(aE,["objectName","objectType","permissionIdentifier","permissionType","permissionMask"]);break;case"AddPermissionCollection":aq(aE,["objectName","objectType","permissionsInfoXml"]);break;case"GetPermissionCollection":aq(aE,["objectName","objectType"]);break;case"RemovePermission":aq(aE,["objectName","objectType","permissionIdentifier","permissionType"]);break;case"RemovePermissionCollection":aq(aE,["objectName","objectType","memberIdsXml"]);break;case"UpdatePermission":aq(aE,["objectName","objectType","permissionIdentifier","permissionType","permissionMask"]);break;case"GetLinks":break;case"GetPortalSearchInfo":S.opheader="<"+aE.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aE.operation;break;case"GetQuerySuggestions":S.opheader="<"+aE.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aE.operation;S.payload+=av("queryXml",j(aE.queryXml));break;case"GetSearchMetadata":S.opheader="<"+aE.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aE.operation;break;case"Query":S.payload+=av("queryXml",j(aE.queryXml));break;case"QueryEx":S.opheader="<"+aE.operation+" xmlns='http://microsoft.com/webservices/OfficeServer/QueryService'>";aa="http://microsoft.com/webservices/OfficeServer/QueryService/"+aE.operation;S.payload+=av("queryXml",j(aE.queryXml));break;case"Registration":S.payload+=av("registrationXml",j(aE.registrationXml));break;case"Status":break;case"SendClientScriptErrorReport":aq(aE,["message","file","line","client","stack","team","originalFile"]);break;case"EnumerateFolder":aq(aE,["strFolderUrl"]);break;case"GetAttachments":aq(aE,["strListName","strItemId"]);break;case"SiteDataGetList":aq(aE,["strListName"]);S=k(S,aE.operation);break;case"SiteDataGetListCollection":S=k(S,aE.operation);break;case"SiteDataGetSite":S=k(S,aE.operation);break;case"SiteDataGetSiteUrl":aq(aE,["Url"]);S=k(S,aE.operation);break;case"SiteDataGetWeb":S=k(S,aE.operation);break;case"CreateWeb":aq(aE,["url","title","description","templateName","language","languageSpecified","locale","localeSpecified","collationLocale","collationLocaleSpecified","uniquePermissions","uniquePermissionsSpecified","anonymous","anonymousSpecified","presence","presenceSpecified"]);break;case"DeleteWeb":aq(aE,["url"]);break;case"GetSite":aq(aE,["SiteUrl"]);break;case"GetSiteTemplates":aq(aE,["LCID","TemplateList"]);break;case"AddComment":aq(aE,["url","comment","isHighPriority","title"]);break;case"AddTag":aq(aE,["url","termID","title","isPrivate"]);break;case"AddTagByKeyword":aq(aE,["url","keyword","title","isPrivate"]);break;case"CountCommentsOfUser":aq(aE,["userAccountName"]);break;case"CountCommentsOfUserOnUrl":aq(aE,["userAccountName","url"]);break;case"CountCommentsOnUrl":aq(aE,["url"]);break;case"CountRatingsOnUrl":aq(aE,["url"]);break;case"CountTagsOfUser":aq(aE,["userAccountName"]);break;case"DeleteComment":aq(aE,["url","lastModifiedTime"]);break;case"DeleteRating":aq(aE,["url"]);break;case"DeleteTag":aq(aE,["url","termID"]);break;case"DeleteTagByKeyword":aq(aE,["url","keyword"]);break;case"DeleteTags":aq(aE,["url"]);break;case"GetAllTagTerms":aq(aE,["maximumItemsToReturn"]);break;case"GetAllTagTermsForUrlFolder":aq(aE,["urlFolder","maximumItemsToReturn"]);break;case"GetAllTagUrls":aq(aE,["termID"]);break;case"GetAllTagUrlsByKeyword":aq(aE,["keyword"]);break;case"GetCommentsOfUser":aq(aE,["userAccountName","maximumItemsToReturn","startIndex"]);break;case"GetCommentsOfUserOnUrl":aq(aE,["userAccountName","url"]);break;case"GetCommentsOnUrl":aq(aE,["url","maximumItemsToReturn","startIndex"]);if(typeof aE.excludeItemsTime!=="undefined"&&aE.excludeItemsTime.length>0){S.payload+=av("excludeItemsTime",aE.excludeItemsTime)}break;case"GetRatingAverageOnUrl":aq(aE,["url"]);break;case"GetRatingOfUserOnUrl":aq(aE,["userAccountName","url"]);break;case"GetRatingOnUrl":aq(aE,["url"]);break;case"GetRatingsOfUser":aq(aE,["userAccountName"]);break;case"GetRatingsOnUrl":aq(aE,["url"]);break;case"GetSocialDataForFullReplication":aq(aE,["userAccountName"]);break;case"GetTags":aq(aE,["url"]);break;case"GetTagsOfUser":aq(aE,["userAccountName","maximumItemsToReturn","startIndex"]);break;case"GetTagTerms":aq(aE,["maximumItemsToReturn"]);break;case"GetTagTermsOfUser":aq(aE,["userAccountName","maximumItemsToReturn"]);break;case"GetTagTermsOnUrl":aq(aE,["url","maximumItemsToReturn"]);break;case"GetTagUrls":aq(aE,["termID"]);break;case"GetTagUrlsByKeyword":aq(aE,["keyword"]);break;case"GetTagUrlsOfUser":aq(aE,["termID","userAccountName"]);break;case"GetTagUrlsOfUserByKeyword":aq(aE,["keyword","userAccountName"]);break;case"SetRating":aq(aE,["url","rating","title","analysisDataEntry"]);break;case"UpdateComment":aq(aE,["url","lastModifiedTime","comment","isHighPriority"]);break;case"SpellCheck":aq(aE,["chunksToSpell","declaredLanguage","useLad"]);break;case"AddTerms":aq(aE,["sharedServiceId","termSetId","lcid","newTerms"]);break;case"GetChildTermsInTerm":aq(aE,["sspId","lcid","termId","termSetId"]);break;case"GetChildTermsInTermSet":aq(aE,["sspId","lcid","termSetId"]);break;case"GetKeywordTermsByGuids":aq(aE,["termIds","lcid"]);break;case"GetTermsByLabel":aq(aE,["label","lcid","matchOption","resultCollectionSize","termIds","addIfNotFound"]);break;case"GetTermSets":aq(aE,["sharedServiceId","termSetId","lcid","clientTimeStamps","clientVersions"]);break;case"AddGroup":aq(aE,["groupName","ownerIdentifier","ownerType","defaultUserLoginName","description"]);break;case"AddGroupToRole":aq(aE,["groupName","roleName"]);break;case"AddRole":aq(aE,["roleName","description","permissionMask"]);break;case"AddRoleDef":aq(aE,["roleName","description","permissionMask"]);break;case"AddUserCollectionToGroup":aq(aE,["groupName","usersInfoXml"]);break;case"AddUserCollectionToRole":aq(aE,["roleName","usersInfoXml"]);break;case"AddUserToGroup":aq(aE,["groupName","userName","userLoginName","userEmail","userNotes"]);break;case"AddUserToRole":aq(aE,["roleName","userName","userLoginName","userEmail","userNotes"]);break;case"GetAllUserCollectionFromWeb":break;case"GetGroupCollection":aq(aE,["groupNamesXml"]);break;case"GetGroupCollectionFromRole":aq(aE,["roleName"]);break;case"GetGroupCollectionFromSite":break;case"GetGroupCollectionFromUser":aq(aE,["userLoginName"]);break;case"GetGroupCollectionFromWeb":break;case"GetGroupInfo":aq(aE,["groupName"]);break;case"GetRoleCollection":aq(aE,["roleNamesXml"]);break;case"GetRoleCollectionFromGroup":aq(aE,["groupName"]);break;case"GetRoleCollectionFromUser":aq(aE,["userLoginName"]);break;case"GetRoleCollectionFromWeb":break;case"GetRoleInfo":aq(aE,["roleName"]);break;case"GetRolesAndPermissionsForCurrentUser":break;case"GetRolesAndPermissionsForSite":break;case"GetUserCollection":aq(aE,["userLoginNamesXml"]);break;case"GetUserCollectionFromGroup":aq(aE,["groupName"]);break;case"GetUserCollectionFromRole":aq(aE,["roleName"]);break;case"GetUserCollectionFromSite":break;case"GetUserCollectionFromWeb":break;case"GetUserInfo":aq(aE,["userLoginName"]);break;case"GetUserLoginFromEmail":aq(aE,["emailXml"]);break;case"RemoveGroup":aq(aE,["groupName"]);break;case"RemoveGroupFromRole":aq(aE,["roleName","groupName"]);break;case"RemoveRole":aq(aE,["roleName"]);break;case"RemoveUserCollectionFromGroup":aq(aE,["groupName","userLoginNamesXml"]);break;case"RemoveUserCollectionFromRole":aq(aE,["roleName","userLoginNamesXml"]);break;case"RemoveUserCollectionFromSite":aq(aE,["userLoginNamesXml"]);break;case"RemoveUserFromGroup":aq(aE,["groupName","userLoginName"]);break;case"RemoveUserFromRole":aq(aE,["roleName","userLoginName"]);break;case"RemoveUserFromSite":aq(aE,["userLoginName"]);break;case"RemoveUserFromWeb":aq(aE,["userLoginName"]);break;case"UpdateGroupInfo":aq(aE,["oldGroupName","groupName","ownerIdentifier","ownerType","description"]);break;case"UpdateRoleDefInfo":aq(aE,["oldRoleName","roleName","description","permissionMask"]);break;case"UpdateRoleInfo":aq(aE,["oldRoleName","roleName","description","permissionMask"]);break;case"UpdateUserInfo":aq(aE,["userLoginName","userName","userEmail","userNotes"]);break;case"AddColleague":aq(aE,["accountName","colleagueAccountName","group","privacy","isInWorkGroup"]);break;case"AddLink":aq(aE,["accountName","name","url","group","privacy"]);break;case"AddMembership":aq(aE,["accountName","membershipInfo","group","privacy"]);break;case"AddPinnedLink":aq(aE,["accountName","name","url"]);break;case"CreateMemberGroup":aq(aE,["membershipInfo"]);break;case"CreateUserProfileByAccountName":aq(aE,["accountName"]);break;case"GetCommonColleagues":aq(aE,["accountName"]);break;case"GetCommonManager":aq(aE,["accountName"]);break;case"GetCommonMemberships":aq(aE,["accountName"]);break;case"GetInCommon":aq(aE,["accountName"]);break;case"GetPropertyChoiceList":aq(aE,["propertyName"]);break;case"GetUserColleagues":aq(aE,["accountName"]);break;case"GetUserLinks":aq(aE,["accountName"]);break;case"GetUserMemberships":aq(aE,["accountName"]);break;case"GetUserPinnedLinks":aq(aE,["accountName"]);break;case"GetUserProfileByGuid":aq(aE,["guid"]);break;case"GetUserProfileByIndex":aq(aE,["index"]);break;case"GetUserProfileByName":if(typeof aE.accountName!=="undefined"&&aE.accountName.length>0){aq(aE,[["AccountName","accountName"]])}else{aq(aE,["AccountName"])}break;case"GetUserProfileCount":break;case"GetUserProfileSchema":break;case"ModifyUserPropertyByAccountName":aq(aE,["accountName","newData"]);break;case"RemoveAllColleagues":aq(aE,["accountName"]);break;case"RemoveAllLinks":aq(aE,["accountName"]);break;case"RemoveAllMemberships":aq(aE,["accountName"]);break;case"RemoveAllPinnedLinks":aq(aE,["accountName"]);break;case"RemoveColleague":aq(aE,["accountName","colleagueAccountName"]);break;case"RemoveLink":aq(aE,["accountName","id"]);break;case"RemoveMembership":aq(aE,["accountName","sourceInternal","sourceReference"]);break;case"RemovePinnedLink":aq(aE,["accountName","id"]);break;case"UpdateColleaguePrivacy":aq(aE,["accountName","colleagueAccountName","newPrivacy"]);break;case"UpdateLink":aq(aE,["accountName","data"]);break;case"UpdateMembershipPrivacy":aq(aE,["accountName","sourceInternal","sourceReference","newPrivacy"]);break;case"UpdatePinnedLink ":aq(aE,["accountName","data"]);break;case"DeleteAllVersions":aq(aE,["fileName"]);break;case"DeleteVersion":aq(aE,["fileName","fileVersion"]);break;case"GetVersions":aq(aE,["fileName"]);break;case"RestoreVersion":aq(aE,["fileName","fileVersion"]);break;case"AddView":aq(aE,["listName","viewName","viewFields","query","rowLimit","rowLimit","type","makeViewDefault"]);break;case"DeleteView":aq(aE,["listName","viewName"]);break;case"GetView":aq(aE,["listName","viewName"]);break;case"GetViewCollection":aq(aE,["listName"]);break;case"GetViewHtml":aq(aE,["listName","viewName"]);break;case"UpdateView":aq(aE,["listName","viewName","viewProperties","query","viewFields","aggregations","formats","rowLimit"]);break;case"UpdateViewHtml":aq(aE,["listName","viewName","viewProperties","toolbar","viewHeader","viewBody","viewFooter","viewEmpty","rowLimitExceeded","query","viewFields","aggregations","formats","rowLimit"]);break;case"AddWebPart":aq(aE,["pageUrl","webPartXml","storage"]);break;case"AddWebPartToZone":aq(aE,["pageUrl","webPartXml","storage","zoneId","zoneIndex"]);break;case"GetWebPart2":aq(aE,["pageUrl","storageKey","storage","behavior"]);break;case"GetWebPartPage":aq(aE,["documentName","behavior"]);break;case"GetWebPartProperties":aq(aE,["pageUrl","storage"]);break;case"GetWebPartProperties2":aq(aE,["pageUrl","storage","behavior"]);break;case"Webs.CreateContentType":aq(aE,["displayName","parentType","newFields","contentTypeProperties"]);break;case"GetColumns":aq(aE,["webUrl"]);break;case"GetContentType":aq(aE,["contentTypeId"]);break;case"GetContentTypes":break;case"GetCustomizedPageStatus":aq(aE,["fileUrl"]);break;case"GetListTemplates":break;case"GetObjectIdFromUrl":aq(aE,["objectUrl"]);break;case"GetWeb":aq(aE,[["webUrl","webURL"]]);break;case"GetWebCollection":break;case"GetAllSubWebCollection":break;case"UpdateColumns":aq(aE,["newFields","updateFields","deleteFields"]);break;case"Webs.UpdateContentType":aq(aE,["contentTypeId","contentTypeProperties","newFields","updateFields","deleteFields"]);break;case"WebUrlFromPageUrl":aq(aE,[["pageUrl","pageURL"]]);break;case"AlterToDo":aq(aE,["item","todoId","todoListId","taskData"]);break;case"GetTemplatesForItem":aq(aE,["item"]);break;case"GetToDosForItem":aq(aE,["item"]);break;case"GetWorkflowDataForItem":aq(aE,["item"]);break;case"GetWorkflowTaskData":aq(aE,["item","listId","taskId"]);break;case"StartWorkflow":aq(aE,["item","templateId","workflowParameters"]);break;default:break}var aH=S.header+S.opheader+S.payload+S.opfooter+S.footer;var aF;if(aE.cacheXML){aF=A[aH]}if(typeof aF==="undefined"){A[aH]=ak.ajax({url:aG,async:aE.async,beforeSend:function(i){if(T[aE.operation][1]){i.setRequestHeader("SOAPAction",aa)}},type:"POST",data:aH,dataType:"xml",contentType:"text/xml;charset='utf-8'",complete:function(aI,i){if(ak.isFunction(aE.completefunc)){aE.completefunc(aI,i)}}});return A[aH]}else{if(ak.isFunction(aE.completefunc)){aE.completefunc(aF,null)}return aF}};ak.fn.SPServices.defaults={cacheXML:false,operation:"",webURL:"",makeViewDefault:false,CAMLViewName:"",CAMLQuery:"",CAMLViewFields:"",CAMLRowLimit:0,CAMLQueryOptions:"",batchCmd:"Update",valuepairs:[],DestinationUrls:[],behavior:"Version3",storage:"Shared",objectType:"List",cancelMeeting:true,nonGregorian:false,fClaim:false,recurrenceId:0,sequence:0,maximumItemsToReturn:0,startIndex:0,isHighPriority:false,isPrivate:false,rating:1,maxResults:10,principalType:"User",async:true,completefunc:null};ak.fn.SPServices.SPGetCurrentSite=function(){if(ac.thisSite.length>0){return ac.thisSite}var i=S.header+""+((location.href.indexOf("?")>0)?location.href.substr(0,location.href.indexOf("?")):location.href)+""+S.footer;ak.ajax({async:false,url:"/_vti_bin/Webs.asmx",type:"POST",data:i,dataType:"xml",contentType:'text/xml;charset="utf-8"',complete:function(aC,aB){ac.thisSite=ak(aC.responseXML).find("WebUrlFromPageUrlResult").text()}});return ac.thisSite};ak.fn.SPServices.SPCascadeDropdowns=function(aJ){var aB=ak.extend({},{relationshipWebURL:"",relationshipList:"",relationshipListParentColumn:"",relationshipListChildColumn:"",relationshipListSortColumn:"",parentColumn:"",childColumn:"",listName:ak().SPServices.SPListNameFromUrl(),CAMLQuery:"",CAMLQueryOptions:"FALSE",promptText:"",noneText:"(None)",simpleChild:false,selectSingleOption:false,matchOnId:false,completefunc:null,debug:false},aJ);var aD=false;var aH="SPServices.SPCascadeDropdowns";var aE=new ar(aB.parentColumn);if(aE.Obj.html()===null&&aB.debug){W(aH,"parentColumn: "+aB.parentColumn,ah);return}var i=new ar(aB.childColumn);if(i.Obj.html()===null&&aB.debug){W(aH,"childColumn: "+aB.childColumn,ah);return}if(aB.simpleChild===true&&i.Type==="C"){ak().SPServices.SPComplexToSimpleDropdown({columnName:aB.childColumn});i=new ar(aB.childColumn)}var aI,aG;ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:aB.listName,completefunc:function(aK){ak(aK.responseXML).find("Fields").each(function(){ak(this).find("Field[DisplayName='"+aB.childColumn+"']").each(function(){aI=(ak(this).attr("Required")==="TRUE")?true:false;aG=ak(this).attr("StaticName");return false})})}});var aF={opt:aB,childSelect:i,childColumnStatic:aG,childColumnRequired:aI};var aC=aE.Obj.data("SPCascadeDropdownsChildColumns");if(typeof aC==="undefined"){aE.Obj.data("SPCascadeDropdownsChildColumns",[aF])}else{aC.push(aF);aE.Obj.data("SPCascadeDropdownsChildColumns",aC);aD=true}if(!aD){switch(aE.Type){case"S":aE.Obj.bind("change",function(){ay(aB.parentColumn,aE)});break;case"C":ak("input[id='"+aE.Obj.attr("optHid")+"']").bind("propertychange",function(){ay(aB.parentColumn,aE)});break;case"M":ak(aE.master.candidateControl).bind("dblclick",function(){ay(aB.parentColumn,aE)});ak(aE.master.resultControl).bind("dblclick",function(){ay(aB.parentColumn,aE)});ak(aE.master.addControl).bind("click",function(){ay(aB.parentColumn,aE)});ak(aE.master.removeControl).bind("click",function(){ay(aB.parentColumn,aE)});break;default:break}}ay(aB.parentColumn,aE)};function ay(aI,aD){var aJ="";var aC;var aF=null;var aH;var aE;var aG;var aB;var i=aD.Obj.data("SPCascadeDropdownsChildColumns");ak(i).each(function(){var aO=this.opt;var aM=this.childSelect;var aR=this.childColumnStatic;var aN=this.childColumnRequired;aC=c(aD,aO.matchOnId);var aL=aC.join(";#");if(aD.Obj.data("SPCascadeDropdown_Selected_"+aR)===aL){return}aD.Obj.data("SPCascadeDropdown_Selected_"+aR,aL);aF=c(aM,true);var aQ=(aO.relationshipListSortColumn.length>0)?aO.relationshipListSortColumn:aO.relationshipListChildColumn;var aK="";if(aO.CAMLQuery.length>0){aK+=""}if(aC.length===0){aK+=""}else{if(aC.length===1){aK+="":"'/>")+K(aC[0])+""}else{var aP=(aC.length>2)?true:false;for(N=0;N<(aC.length-1);N++){aK+=""}for(N=0;N":"'/>")+K(aC[N])+"";if(N>0&&(N<(aC.length-1))&&aP){aK+=""}}aK+=""}}if(aO.CAMLQuery.length>0){aK+=aO.CAMLQuery+""}aK+="";aK+="";ak().SPServices({operation:"GetListItems",async:false,webURL:aO.relationshipWebURL,listName:aO.relationshipList,CAMLQuery:aK,CAMLViewFields:"",CAMLRowLimit:0,CAMLQueryOptions:aO.CAMLQueryOptions,completefunc:function(aS){ak(aS.responseXML).find("errorstring").each(function(){var aU="SPServices.SPCascadeDropdowns";var aT=ak(this).text();if(aO.debug&&aT==="One or more field types are not installed properly. Go to the list settings page to delete these fields."){W(aU,"relationshipListParentColumn: "+aO.relationshipListParentColumn+" or relationshipListChildColumn: "+aO.relationshipListChildColumn,"Not found in relationshipList "+aO.relationshipList)}else{if(aO.debug&&aT==="Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."){W(aU,"relationshipList: "+aO.relationshipList,"List not found")}}return});switch(aM.Type){case"S":ak(aM.Obj).find("option").remove();if(!aN&&(aO.promptText.length>0)){aM.Obj.append("")}else{if(!aN){aM.Obj.append("")}}break;case"C":aJ=aN?"":aO.noneText+"|0";aM.Obj.attr("value","");break;case"M":ak(aM.master.candidateControl).find("option").remove();aH="";break;default:break}aE=parseFloat(ak(aS.responseXML).SPFilterNode("rs:data").attr("ItemCount"));ak(aS.responseXML).SPFilterNode("z:row").each(function(){var aU={};var aT=ak(this).attr("ows_"+aO.relationshipListChildColumn);if(typeof aT!=="undefined"&&aT.indexOf(";#")>0){aU=new n(aT)}else{aU.id=ak(this).attr("ows_ID");aU.value=aT}if(isNaN(aU.id)){aU.id=ak(this).attr("ows_ID")}aG=aU.id;aB=aU.value;switch(aM.Type){case"S":var aV=(ak(this).attr("ows_ID")===aF[0])?" selected='selected'":"";aM.Obj.append(""+aU.value+"");break;case"C":if(aU.id===aF[0]){aM.Obj.attr("value",aU.value)}aJ=aJ+((aJ.length>0)?"|":"")+aU.value+"|"+aU.id;break;case"M":ak(aM.master.candidateControl).append("");aH+=aU.id+"|t"+aU.value+"|t |t |t";break;default:break}});switch(aM.Type){case"S":aM.Obj.trigger("change");if(aE===1&&aO.selectSingleOption===true){ak(aM.Obj).find("option[value!='0']:first").attr("selected","selected")}break;case"C":aM.Obj.attr("choices",aJ);if(aE===1&&aO.selectSingleOption===true){ak(aM.Obj).attr("value",aB);ak("input[id='"+aM.Obj.attr("optHid")+"']").val(aG)}if(aM.Obj.val()===""){ak("input[id='"+aM.Obj.attr("optHid")+"']").val("")}break;case"M":aM.master.data="";aM.MultiLookupPickerdata.attr("value",aH);ak(aM.master.resultControl).find("option").each(function(){var aT=ak(this);aT.prop("selected",true);ak(aM.master.candidateControl).find("option[value='"+aT.val()+"']").each(function(){aT.prop("selected",false)})});GipRemoveSelectedItems(aM.master);ak(aM.master.candidateControl).find("option").each(function(){var aT=ak(this);ak(aM.master.resultControl).find("option[value='"+aT.val()+"']").each(function(){aT.remove()})});GipAddSelectedItems(aM.master);aM.master.data=GipGetGroupData(aH);ak(aM.master.candidateControl).trigger("dblclick");break;default:break}}});if(aO.completefunc!==null){aO.completefunc()}})}ak.fn.SPServices.SPComplexToSimpleDropdown=function(aJ){var i=ak.extend({},{columnName:"",completefunc:null,debug:false},aJ);var aC=new ar(i.columnName);if(aC.Obj.html()===null&&i.debug){W("SPServices.SPComplexToSimpleDropdown","columnName: "+i.columnName,ah);return}if(aC.Type!=="C"){return}var aH=ak(aC.Obj).attr("choices").split("|");var aD=ak(aC.Obj).attr("optHid");var aI=ak("input[id='"+aD+"']");var aB=ak("input[id='"+aD+"']").val();var aE=ad("SPComplexToSimpleDropdown",i.columnName);var aG="";ak(aC.Obj).closest("td").prepend(aG);ak(aC.Obj).closest("span").find("img").remove();ak(aC.Obj).closest("span").find("input").hide();ak("#"+aE).change(function(){var aK=ak(this).val();aI.val(aK);ak(aC.Obj).val(ak(this).find("option[value='"+(aK!=="0"?aK:"")+"']").html())});ak("#"+aE).trigger("change");if(i.completefunc!==null){i.completefunc()}};ak.fn.SPServices.SPDisplayRelatedInfo=function(aB){var aD=ak.extend({},{columnName:"",relatedWebURL:"",relatedList:"",relatedListColumn:"",relatedColumns:[],displayFormat:"table",headerCSSClass:"ms-vh2",rowCSSClass:"ms-vb",CAMLQuery:"",numChars:0,matchType:"Eq",matchOnId:false,completefunc:null,debug:false},aB);var i;var aC=[];var aG;var aF="SPServices.SPDisplayRelatedInfo";var aE=new ar(aD.columnName);if(aE.Obj.html()===null&&aD.debug){W(aF,"columnName: "+aD.columnName,ah);return}i=ad("SPDisplayRelatedInfo",aD.columnName);ak().SPServices({operation:"GetList",async:false,cacheXML:true,webURL:aD.relatedWebURL,listName:aD.relatedList,completefunc:function(aH){ak(aH.responseXML).find("faultcode").each(function(){if(aD.debug){W(aF,"relatedList: "+aD.relatedList,"List not found");return}});aG=ak(aH.responseXML).find("List");for(N=0;N Field[Name='"+aD.relatedColumns[N]+"']")}aC[aD.relatedListColumn]=ak(aH.responseXML).find("Fields > Field[Name='"+aD.relatedListColumn+"']")}});switch(aE.Type){case"S":aE.Obj.bind("change",function(){af(aD,i,aG,aC)});break;case"C":ak("input[id='"+aE.Obj.attr("optHid")+"']").bind("propertychange",function(){af(aD,i,aG,aC)});break;case"M":if(aD.debug){W(aF,"columnName: "+aD.columnName,"Multi-select columns not supported by this function")}break;default:break}af(aD,i,aG,aC)};function af(aC,aG,aI,aD){var aJ=null;var aF="SPServices.SPDisplayRelatedInfo";var aE=new ar(aC.columnName);aJ=c(aE,aC.matchOnId);if(aE.Type==="C"&&aC.numChars>0&&aJ[0].length
    ");var i="";if(aC.CAMLQuery.length>0){i+=""}var aB=aD[aC.relatedListColumn].attr("Type");if(aB==="Lookup"){i+="":"'/>")+K(aJ[0])+""}else{i+="":aC.relatedListColumn+"'/>")+K(aJ[0])+""}if(aC.CAMLQuery.length>0){i+=aC.CAMLQuery+""}i+="";var aH=" ";for(N=0;N"}ak().SPServices({operation:"GetListItems",async:false,webURL:aC.relatedWebURL,listName:aC.relatedList,CAMLQuery:i,CAMLViewFields:""+aH+"",CAMLRowLimit:0,completefunc:function(aL){ak(aL.responseXML).find("errorstring").each(function(){var aM=ak(this).text();if(aC.debug&&aM==="One or more field types are not installed properly. Go to the list settings page to delete these fields."){W(aF,"relatedListColumn: "+aC.relatedListColumn,"Column not found in relatedList "+aC.relatedList)}else{if(aC.debug&&aM==="Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."){W(aF,"relatedList: "+aC.relatedList,"List not found")}}return});var aK;switch(aC.displayFormat){case"table":aK="";aK+="";for(N=0;N"+aD[aC.relatedColumns[N]].attr("DisplayName")+""}aK+="";ak(aL.responseXML).SPFilterNode("z:row").each(function(){aK+="";for(N=0;N"+V(aI,aD[aC.relatedColumns[N]],ak(this).attr("ows_"+aC.relatedColumns[N]),aC)+""}aK+=""});aK+="
    ";break;case"list":aK="";ak(aL.responseXML).SPFilterNode("z:row").each(function(){for(N=0;N"+aD[aC.relatedColumns[N]].attr("DisplayName")+"";aK+="";aK+=""}});aK+="
    "+V(aI,aD[aC.relatedColumns[N]],ak(this).attr("ows_"+aC.relatedColumns[N]),aC)+"
    ";break;default:break}ak("#"+aG).html(aK)}});if(aC.completefunc!==null){aC.completefunc()}}ak.fn.SPServices.SPFilterDropdown=function(aK){var aB=ak.extend({},{relationshipWebURL:"",relationshipList:"",relationshipListColumn:"",relationshipListSortColumn:"",relationshipListSortAscending:true,columnName:"",listName:ak().SPServices.SPListNameFromUrl(),promptText:"",noneText:"(None)",CAMLQuery:"",CAMLQueryOptions:"FALSE",completefunc:null,debug:false},aK);var aJ="";var aI=null;var aH;var aG;var aF="SPServices.SPFilterDropdown";var aE=new ar(aB.columnName);if(aE.Obj.html()===null&&aB.debug){W(aF,"columnName: "+aB.columnName,ah);return}aI=c(aE,true);var aD=(aB.relationshipListSortColumn.length>0)?aB.relationshipListSortColumn:aB.relationshipListColumn;var aC=(aB.relationshipListSortAscending===true)?"":"Ascending='FALSE'";var i="";if(aB.CAMLQuery.length>0){i+=aB.CAMLQuery}i+="";ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:aB.listName,completefunc:function(aL){ak(aL.responseXML).find("Fields").each(function(){ak(this).find("Field[DisplayName='"+aB.columnName+"']").each(function(){aG=(ak(this).attr("Required")==="TRUE")?true:false;return false})})}});ak().SPServices({operation:"GetListItems",async:false,webURL:aB.relationshipWebURL,listName:aB.relationshipList,CAMLQuery:i,CAMLViewFields:"",CAMLRowLimit:0,CAMLQueryOptions:aB.CAMLQueryOptions,completefunc:function(aL){ak(aL.responseXML).find("errorstring").each(function(){var aM=ak(this).text();if(aB.debug&&aM==="One or more field types are not installed properly. Go to the list settings page to delete these fields."){W(aF,"relationshipListColumn: "+aB.relationshipListColumn,"Not found in relationshipList "+aB.relationshipList)}else{if(aB.debug&&aM==="Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."){W(aF,"relationshipList: "+aB.relationshipList,"List not found")}}return});switch(aE.Type){case"S":ak(aE.Obj).find("option").remove();if(!aG&&(aB.promptText.length>0)){aE.Obj.append("")}else{if(!aG){aE.Obj.append("")}}break;case"C":aJ=aG?"":aB.noneText+"|0";aE.Obj.attr("value","");break;case"M":ak(aE.master.candidateControl).find("option").remove();aH="";break;default:break}ak(aL.responseXML).SPFilterNode("z:row").each(function(){var aN={};var aM=ak(this).attr("ows_"+aB.relationshipListColumn);if(typeof aM!=="undefined"&&aM.indexOf(";#")>0){aN=new n(aM)}else{aN.id=ak(this).attr("ows_ID");aN.value=aM}if(isNaN(aN.id)){aN.id=ak(this).attr("ows_ID")}switch(aE.Type){case"S":var aO=(ak(this).attr("ows_ID")===aI[0])?" selected='selected'":"";aE.Obj.append(""+aN.value+"");break;case"C":if(aN.id===aI[0]){aE.Obj.attr("value",aN.value)}aJ=aJ+((aJ.length>0)?"|":"")+aN.value+"|"+aN.id;break;case"M":ak(aE.master.candidateControl).append("");aH+=aN.id+"|t"+aN.value+"|t |t |t";break;default:break}});switch(aE.Type){case"S":aE.Obj.trigger("change");break;case"C":aE.Obj.attr("choices",aJ);aE.Obj.trigger("propertychange");break;case"M":aE.master.data="";aE.MultiLookupPickerdata.attr("value",aH);ak(aE.master.resultControl).find("option").each(function(){var aM=ak(this);ak(this).attr("selected","selected");ak(aE.master.candidateControl).find("option").each(function(){if(ak(this).html()===aM.html()){aM.removeAttr("selected")}})});GipRemoveSelectedItems(aE.master);ak(aE.master.candidateControl).find("option").each(function(){var aM=ak(this);ak(aE.master.resultControl).find("option").each(function(){if(ak(this).html()===aM.html()){aM.remove()}})});GipAddSelectedItems(aE.master);aE.master.data=GipGetGroupData(aH);ak(aE.master.candidateControl).trigger("dblclick");break;default:break}}});if(aB.completefunc!==null){aB.completefunc()}};ak.fn.SPServices.SPDebugXMLHttpResult=function(aC){var aE=ak.extend({},{node:null,indent:0},aC);var aD;var aG=3;var aF=4;var aB="";aB+="";if(aE.node.nodeName==="DisplayPattern"){aB+=""}else{if(!aE.node.hasChildNodes()){aB+="";if(aE.node.attributes){aB+=""}}else{if(aE.node.hasChildNodes()&&aE.node.firstChild.nodeType===aF){aB+=""}else{if(aE.node.hasChildNodes()&&aE.node.firstChild.nodeType===aG){aB+=""}else{aB+="";if(aE.node.attributes){aB+=""}aB+=""}}}}aB+="
    "+aE.node.nodeName+"
    "+aE.node.nodeName+""+((aE.node.nodeValue!==null)?M(aE.node.nodeValue):" ")+"
    "+t(aE.node)+"
    "+aE.node.nodeName+"
    "+aE.node.nodeName+""+M(aE.node.firstChild.nodeValue)+"
    "+aE.node.nodeName+"
    "+t(aE.node)+"
    ";for(aD=0;aD
    ";return aB};ak.fn.SPServices.SPGetCurrentUser=function(aE){var aG=ak.extend({},{webURL:"",fieldName:"Name",fieldNames:{},debug:false},aE);if(aG.fieldName==="ID"&&typeof ac.thisUserId!=="undefined"){return ac.thisUserId}var aC="";var aF={};var aH=aG.fieldNames.length>0?aG.fieldNames.length:1;var aD;var aB=aG.webURL.length>0?aG.webURL:ak().SPServices.SPGetCurrentSite();ak.ajax({async:false,url:aB+"/_layouts/userdisp.aspx?Force=True&"+new Date().getTime(),complete:function(aJ,aI){aD=aJ}});for(N=0;N1){i=RegExp('FieldInternalName="'+aG.fieldNames[N]+'"',"gi")}else{i=RegExp('FieldInternalName="'+aG.fieldName+'"',"gi")}ak(aD.responseText).find("table.ms-formtable td[id^='SPField']").each(function(){if(i.test(ak(this).html())){switch(ak(this).attr("id")){case"SPFieldText":aC=ak(this).text();break;case"SPFieldNote":aC=ak(this).find("div").html();break;case"SPFieldURL":aC=ak(this).find("img").attr("src");break;default:aC=ak(this).text();break}return false}})}if(aG.fieldNames[N]!=="ID"){aC=(typeof aC!=="undefined")?aC.replace(/(^[\s\xA0]+|[\s\xA0]+$)/g,""):null}if(aH>1){aF[aG.fieldNames[N]]=aC}}return(aH>1)?aF:aC};ak.fn.SPServices.SPLookupAddNew=function(aI){var aD=ak.extend({},{lookupColumn:"",promptText:"Add new {0}",newWindow:false,ContentTypeID:"",completefunc:null,debug:false},aI);var aF="SPServices.SPLookupAddNew";var aC=new ar(aD.lookupColumn);if(aC.Obj.html()===null&&aD.debug){W(aF,"lookupColumn: "+aD.lookupColumn,ah);return}var i="";var aH="";var aB="";ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:ak().SPServices.SPListNameFromUrl(),completefunc:function(aK,aJ){ak(aK.responseXML).find("Field[DisplayName='"+aD.lookupColumn+"']").each(function(){aB=ak(this).attr("StaticName");ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:ak(this).attr("List"),completefunc:function(aM,aL){ak(aM.responseXML).find("List").each(function(){aH=ak(this).attr("WebFullUrl");aH=aH!==P?aH+P:aH})}});i=C(ak(this).attr("List"),"NewForm");return false})}});if(aH.length===0&&aD.debug){W(aF,"lookupColumn: "+aD.lookupColumn,"This column does not appear to be a lookup column");return}if(i.length>0){var aG=aH+i;aG+=aD.newWindow?((aD.ContentTypeID.length>0)?"?ContentTypeID="+aD.ContentTypeID:"")+"' target='_blank'":"?"+((aD.ContentTypeID.length>0)?"ContentTypeID="+aD.ContentTypeID+"&":"")+"Source="+z(location.href)+"'";var aE="
    "+aC+"";if(aD.CAMLQuery.length>0){i+=aD.CAMLQuery+""}i+="";ak().SPServices({operation:"GetListItems",async:false,webURL:aD.webURL,listName:aD.listName,CAMLQuery:i,CAMLViewFields:"",CAMLRowLimit:1,CAMLQueryOptions:"",completefunc:function(aF){ak(aF.responseXML).SPFilterNode("z:row").each(function(){aE=ak(this).attr("ows_ID")})}});return aE};ak.fn.SPServices.SPRequireUnique=function(aB){var aC=ak.extend({},{columnStaticName:"Title",duplicateAction:0,ignoreCase:false,initMsg:"This value must be unique.",initMsgCSSClass:"ms-vb",errMsg:"This value is not unique.",errMsgCSSClass:"ms-formvalidation",showDupes:false,completefunc:null},aB);var aG=ak().SPServices.SPGetQueryString();var aH=aG.ID;ac.thisList=ak().SPServices.SPListNameFromUrl();var aF="{1}
    ";var aE=aF.replace(/\{0\}/g,aC.initMsgCSSClass).replace(/\{1\}/g,aC.initMsg);var aD=ak().SPServices.SPGetDisplayFromStatic({listName:ac.thisList,columnStaticName:aC.columnStaticName});var i=ak("input[Title='"+aD+"']");ak(i).parent().append(aE);ak(i).blur(function(){var aK=[];var aL=ak(this).attr("value");if(aL.length===0){return false}ak().SPServices({operation:"GetListItems",async:false,listName:ac.thisList,CAMLQuery:"",CAMLViewFields:"",CAMLRowLimit:0,completefunc:function(aN){var aM=aC.ignoreCase?aL.toUpperCase():aL;ak(aN.responseXML).SPFilterNode("z:row").each(function(){var aO=aC.ignoreCase?ak(this).attr("ows_"+aC.columnStaticName).toUpperCase():ak(this).attr("ows_"+aC.columnStaticName);if((aM===aO)&&(ak(this).attr("ows_ID")!==aH)){aK.push([ak(this).attr("ows_ID"),ak(this).attr("ows_"+aC.columnStaticName)])}})}});var aJ=aC.initMsg;ak("span#SPRequireUnique"+aC.columnStaticName).html(aJ).attr("class",aC.initMsgCSSClass);ak("input[value='OK']:disabled, input[value='Save']:disabled").removeAttr("disabled");if(aK.length>0){aJ=aC.errMsg;ak("span#SPRequireUnique"+aC.columnStaticName).html(aJ).attr("class",aC.errMsgCSSClass);if(aC.duplicateAction===1){ak("input[Title='"+aC.columnDisplayName+"']").focus();ak("input[value='OK'], input[value='Save']").attr("disabled","disabled")}if(aC.showDupes){var aI=" "+aK.length+" duplicate item"+(aK.length>1?"s":"")+": ";for(N=0;N"+aK[N][1]+"
    "}ak("span#SPRequireUnique"+aC.columnStaticName).append(aI)}}});if(aC.completefunc!==null){aC.completefunc()}};ak.fn.SPServices.SPGetDisplayFromStatic=function(aB){var aC=ak.extend({},{webURL:"",listName:"",columnStaticName:"",columnStaticNames:{}},aB);var i="";var aD={};var aE=aC.columnStaticNames.length>0?aC.columnStaticNames.length:1;ak().SPServices({operation:"GetList",async:false,cacheXML:true,webURL:aC.webURL,listName:aC.listName,completefunc:function(aF){if(aE>1){for(N=0;N1)?aD:i};ak.fn.SPServices.SPGetStaticFromDisplay=function(i){var aC=ak.extend({},{webURL:"",listName:"",columnDisplayName:"",columnDisplayNames:{}},i);var aB="";var aD={};var aE=aC.columnDisplayNames.length>0?aC.columnDisplayNames.length:1;ak().SPServices({operation:"GetList",async:false,cacheXML:true,webURL:aC.webURL,listName:aC.listName,completefunc:function(aF){if(aE>1){for(N=0;N1)?aD:aB};ak.fn.SPServices.SPRedirectWithID=function(aC){var aD=ak.extend({},{redirectUrl:"",qsParamName:"ID"},aC);ac.thisList=ak().SPServices.SPListNameFromUrl();var aH=ak().SPServices.SPGetQueryString();var aG=aH.ID;var aF=aH.List;var aB=aH.RootFolder;var aE=aH.ContentTypeId;if(typeof aH.ID==="undefined"){aG=ak().SPServices.SPGetLastItemId({listName:ac.thisList});ak("form[name='aspnetForm']").each(function(){var aJ=(location.href.indexOf("?")>0)?location.href.substring(0,location.href.indexOf("?")):location.href;var aK=(typeof aH.Source==="string")?"Source="+aH.Source.replace(/\//g,"%2f").replace(/:/g,"%3a"):"";var aI=[];if(typeof aF!=="undefined"){aI.push("List="+aF)}if(typeof aB!=="undefined"){aI.push("RootFolder="+aB)}if(typeof aE!=="undefined"){aI.push("ContentTypeId="+aE)}var aL=aJ+((aI.length>0)?("?"+aI.join("&")+"&"):"?")+"Source="+aJ+"?ID="+aG+((aK.length>0)?("%26RealSource="+aH.Source):"")+((typeof aH.RedirectURL==="string")?("%26RedirectURL="+aH.RedirectURL):"");ak(this).attr("action",aL)})}else{while(aH.ID===aG){aG=ak().SPServices.SPGetLastItemId({listName:ac.thisList})}var i=(typeof aH.RedirectURL==="string")?aH.RedirectURL:aD.redirectUrl;location.href=i+"?"+aD.qsParamName+"="+aG+((typeof aH.RealSource==="string")?("&Source="+aH.RealSource):"")}};ak.fn.SPServices.SPSetMultiSelectSizes=function(aI){var i=ak.extend({},{multiSelectColumn:"",minWidth:0,maxWidth:0,debug:false},aI);var aF="SPServices.SPSetMultiSelectSizes";var aE=new ar(i.multiSelectColumn);if(aE.Obj.html()===null&&i.debug){W(aF,"multiSelectColumn: "+i.multiSelectColumn,ah);return}if(aE.Type!=="M"&&i.debug){W(aF,"multiSelectColumn: "+i.multiSelectColumn,"Column is not multi-select.");return}var aG=ad("SPSetMultiSelectSizes",i.multiSelectColumn);var aD=ak("").appendTo(aE.container);aD.css({width:"auto",height:0,visibility:"hidden"});ak(aE.master.candidateControl).find("option").each(function(){aD.append("")});ak(aE.master.resultControl).find("option").each(function(){aD.append("")});var aB=aD.width()+5;var aH=aB;if(i.minWidth>0||i.maxWidth>0){if(aBi.maxWidth){aH=i.maxWidth}}var aC=aB;ak(aE.master.candidateControl).css("width",aC+"px").parent().css("width",aH+"px");ak(aE.master.resultControl).css("width",aC+"px").parent().css("width",aH+"px");aD.remove()};ak.fn.SPServices.SPScriptAudit=function(aC){var aD=ak.extend({},{webURL:"",listName:"",outputId:"",auditForms:true,auditViews:true,auditPages:true,auditPagesListName:"Pages",showHiddenLists:false,showNoScript:false,showSrc:true},aC);var aB=[["New","NewForm.aspx",false],["Display","DispForm.aspx",false],["Edit","EditForm.aspx",false]];var aE;ak("#"+aD.outputId).append(""+(aD.showSrc?"":"")+"
    ListPage ClassPage TypePageScript References
    ");ak("#SPScriptAudit th").attr("class","ms-vh2-nofilter");if(aD.auditForms||aD.auditViews){ak().SPServices({operation:"GetListCollection",webURL:aD.webURL,async:false,completefunc:function(aH,aG){ak(aH.responseXML).find("List").each(function(){aE=ak(this);if((aD.listName.length===0)||(aE.attr("Title")===aD.listName)){if((aD.showHiddenLists&&aE.attr("Hidden")==="False")||!aD.showHiddenLists){if(aD.auditForms){ak().SPServices({operation:"GetListContentTypes",webURL:aD.webURL,listName:aE.attr("ID"),async:false,completefunc:function(aJ,aI){ak(aJ.responseXML).find("ContentType").each(function(){if(ak(this).attr("ID").substring(0,6)!=="0x0120"){var aL=ak(this).find("FormUrls");for(N=0;N0)?aD.webURL:ak().SPServices.SPGetCurrentSite())+P+ak(this).text());aB[N][2]=true});if(!aB[N][2]){var aK=aE.attr("DefaultViewUrl");ax(aD,aE,"Form",aB[N][0],aK.substring(0,aK.lastIndexOf(P)+1)+aB[N][1])}}for(N=0;NFolder",CAMLViewFields:"",CAMLRowLimit:0,completefunc:function(aG){ak(aG.responseXML).SPFilterNode("z:row").each(function(){var aJ=ak(this).attr("ows_FileRef").split(";#")[1];var aH=ak(this).attr("ows_Title");var aI=(typeof aH!=="undefined")?aH:"";if(aJ.indexOf(".aspx")>0){ax(aD,aE,"Page",aI,P+aJ)}})}})}}ak("#SPScriptAudit tr[class='ms-alternating']:even").removeAttr("class")};function ax(aB,aC,aJ,aF,aD){var aG=0;var aI=0;var aE={};aE.type=[];aE.src=[];aE.script=[];var aH=RegExp("","gi");ak.ajax({type:"GET",url:aD,dataType:"text",async:false,success:function(aP){var aO;while(aO=aH.exec(aP)){var aK=aj(aO,"language");var aQ=aj(aO,"type");var aM=aj(aO,"src");if(aM!==null&&aM.length>0&&!al(aM)){aE.type.push((aK!==null&&aK.length>0)?aK:aQ);aE.src.push(aM);aI++}}if((!aB.showNoScript&&(aE.type.length>0))||aB.showNoScript){var aN=aD.substring(0,aD.lastIndexOf(P)+1);var aL=""+aC.attr("Title")+((aC.attr("Hidden")==="True")?"(Hidden)":"")+""+aJ+""+aF+""+Q(aD)+"";if(aB.showSrc){var i;aL+="";for(aG=0;aG";aL+=""}aL+="
    "+aE.type[aG]+""+Q(aE.src[aG])+"
    "}ak("#SPScriptAudit").append(aL)}}})}function aj(aD,aB){var aC;var i=RegExp(aB+"=(\"([^\"]*)\")|('([^']*)')","gi");if(aC=i.exec(aD)){return aC[2]}return null}function al(aD){var aC;var aB=["WebResource.axd","_layouts"];for(aC=0;aC-1){return true}}return false}ak.fn.SPServices.SPArrangeChoices=function(aC){var aD=ak.extend({},{listName:ak().SPServices.SPListNameFromUrl(),columnName:"",perRow:99,randomize:false},aC);var aF=false;var aE=[];var aB;var i=ak().SPServices({operation:"GetList",async:false,cacheXML:true,listName:aD.listName});i.done(function(){ak(i.responseXML).find("Field[DisplayName='"+aD.columnName+"']").each(function(){aF=(ak(this).attr("FillInChoice")==="TRUE")?true:false;return false});var aK=y(aD.columnName);var aI=ak(aK).find("tr").length;var aH=0;var aJ;var aG;ak(aK).find("tr").each(function(){aH++;if(aF&&aH===(aI-1)){aJ=ak(this).find("td").html()}else{if(aF&&aH===aI){aG=ak(this).find("td").html()}else{aE.push(ak(this).html())}}});aB="";if(aD.randomize){aE.sort(q)}for(N=0;N"}}aB+="";if(aF){aB+=""+aJ+aG+""}ak(aK).find("tr").remove();ak(aK).find("table").append(aB)})};ak.fn.SPServices.SPAutocomplete=function(aC){var aD=ak.extend({},{webURL:"",sourceList:"",sourceColumn:"",columnName:"",CAMLQuery:"",CAMLQueryOptions:"",CAMLRowLimit:0,filterType:"BeginsWith",numChars:0,ignoreCase:false,highlightClass:"",uniqueVals:false,maxHeight:99999,slideDownSpeed:"fast",processingIndicator:"_layouts/images/REFRESH.GIF",debug:false},aC);var aF;var aB=ak("input[Title='"+aD.columnName+"']");aB.css("position","");var aE=aB.css("color");var aG=aB.css("width");if(aB.html()===null&&aD.debug){W("SPServices.SPAutocomplete","columnName: "+aD.columnName,"Column is not an input control or is not found on page");return}aB.closest("span").find("br").remove();aB.wrap("
    ");var i=ad("SPAutocomplete",aD.columnName);aB.after("
    ");ak("#"+i).css("width",aG);ak(aB).keyup(function(){var aP=ak(this).val();ak("#"+i).hide();if(aP.length";if(aD.CAMLQuery.length>0){aH+=""}aH+="<"+aD.filterType+">"+aP+"";if(aD.CAMLQuery.length>0){aH+=aD.CAMLQuery+""}aH+="";ak().SPServices({operation:"GetListItems",async:false,webURL:aD.WebURL,listName:aD.sourceList,CAMLQuery:aH,CAMLQueryOptions:aD.CAMLQueryOptions,CAMLViewFields:"",CAMLRowLimit:aD.CAMLRowLimit,completefunc:function(aS){var aR=aD.ignoreCase?aP.toUpperCase():aP;ak(aS.responseXML).SPFilterNode("z:row").each(function(){var aU=ak(this).attr("ows_"+aD.sourceColumn);var aV=aD.ignoreCase?ak(this).attr("ows_"+aD.sourceColumn).toUpperCase():ak(this).attr("ows_"+aD.sourceColumn);if(aD.filterType==="Contains"){var aT=aV.indexOf(aR);if((aT>=0)&&(!aD.uniqueVals||(ak.inArray(aU,aO)===-1))){aO.push(ak(this).attr("ows_"+aD.sourceColumn))}}else{if(aR===aV.substr(0,aR.length)&&(!aD.uniqueVals||(ak.inArray(aU,aO)===-1))){aO.push(ak(this).attr("ows_"+aD.sourceColumn))}}})}});var aK="";for(N=0;N0){var aJ=new RegExp(aP,aD.ignoreCase?"gi":"g");var aM=aO[N].match(aJ);var aL=0;for(aF=0;aF"+aM[aF]+"";aO[N]=aO[N].substr(0,aN)+aQ+aO[N].substr(aI);aL=aN+aQ.length}}aK+="
  • "+aO[N]+"
  • "}ak("#"+i).html(aK);ak("#"+i+" li").click(function(){ak("#"+i).fadeOut(aD.slideUpSpeed);aB.val(ak(this).text())}).mouseover(function(){var aR={cursor:"hand",color:"#ffffff",background:"#3399ff"};ak(this).css(aR)}).mouseout(function(){var aR={cursor:"inherit",color:aE,background:"transparent"};ak(this).css(aR)});if(aO.length>0){ak("#"+i).slideDown(aD.slideDownSpeed)}aB.css("background-image","")})};ak.fn.SPServices.SPGetQueryString=function(){var aG={};var aF;var aB=location.search.substring(1,location.search.length);var aC=aB.split("&");var aE=/^([^=]+)=(.*)/i;for(var aD=0;aD2){aG[aF[1]]=decodeURIComponent(aF[2]).replace(/\+/g," ")}}}return aG};ak.fn.SPServices.SPListNameFromUrl=function(i){var aB=ak.extend({},{listName:""},i);if(aB.listName.length>0){ac.thisList=aB.listName;return ac.thisList}else{if(ac.thisList.length>0){return ac.thisList}}var aD=location.href;var aC=aD.substring(0,aD.indexOf(".aspx"));var aE=decodeURIComponent(aC.substring(0,aC.lastIndexOf(P)+1)).toUpperCase();ak().SPServices({operation:"GetListCollection",async:false,completefunc:function(aG,aF){ak(aG.responseXML).find("List").each(function(){var aH=ak(this).attr("DefaultViewUrl");var aI=aH.substring(0,aH.lastIndexOf(P)+1).toUpperCase();if(aE.indexOf(aI)>0){ac.thisList=ak(this).attr("ID");return false}})}});return ac.thisList};ak.fn.SPServices.SPUpdateMultipleListItems=function(aD){var aF=ak.extend({},{webURL:"",listName:"",CAMLQuery:"",batchCmd:"Update",valuepairs:[],completefunc:null,debug:false},aD);var aE;var aH=[];var aG=[];ak().SPServices({operation:"GetListItems",async:false,webURL:aF.webURL,listName:aF.listName,CAMLQuery:aF.CAMLQuery,CAMLQueryOptions:"",completefunc:function(i){ak(i.responseXML).SPFilterNode("z:row").each(function(){aH.push(ak(this).attr("ows_ID"));var aI=ak(this).attr("ows_FileRef");aI="/"+aI.substring(aI.indexOf(";#")+2);aG.push(aI)})}});var aB;var aC="";for(aE=0;aE";for(aB=0;aB"+K(aF.valuepairs[aB][1])+""}aC+=""+aH[aE]+"";if(aG[aE].length>0){aC+=""+aG[aE]+""}aC+=""}aC+="";ak().SPServices({operation:"UpdateListItems",async:false,webURL:aF.webURL,listName:aF.listName,updates:aC,completefunc:function(i){if(aF.completefunc!==null){aF.completefunc(i)}}})};ak.fn.SPFilterNode=function(i){return this.find("*").filter(function(){return this.nodeName===i})};ak.fn.SPXmlToJson=function(i){var aC=ak.extend({},{mapping:{},includeAllAttrs:false,removeOws:true},i);var aD;var aB=[];this.each(function(){var aH={};var aJ=this.attributes;ak.each(aC.mapping,function(){aH[this.mappedName]=""});for(aD=0;aD0){aB.html(aD.valueToSet)}if(aD.checkNames){i.click()}var aF=ak.trim(aB.text());var aE=[];aB.children("span").each(function(){var aJ=ak(this).find("div[data]").attr("data");var aH={};if(typeof aJ!=="undefined"){var aK=ak.parseXML(aJ);var aI=ak(aK);aI.find("DictionaryEntry").each(function(){var aL=ak(this).find("Key").text();var aM=ak(this).find("Value").text();aH[aL]=aM});aE.push(aH)}else{ak().SPServices({operation:"GetUserInfo",async:false,cacheXML:true,userLoginName:ak(this).attr("title"),completefunc:function(aL){ak(aL.responseXML).find("User").each(function(){ak.each(this.attributes,function(aN,aP){var aM=aP.name;var aO=aP.value;aH[aM]=aO});aE.push(aH)})}})}});return{row:aG,contents:aB,currentValue:aF,checkNames:i,dictionaryEntries:aE}};ak.fn.SPServices.Version=function(){return Z};function ap(){if(typeof _spPageContextInfo!=="undefined"){this.thisSite=_spPageContextInfo.webServerRelativeUrl;this.thisList=_spPageContextInfo.pageListId;this.thisUserId=_spPageContextInfo.userId}else{this.thisSite=L_Menu_BaseUrl;this.thisList="";this.thisUserId=(typeof _spUserId!=="undefined")?_spUserId:undefined}}function V(aM,aI,aN,aD){if(typeof aN==="undefined"){return""}var aJ;var aK="";var aH;var aF;var aL=[];var aE=aD.relatedWebURL.length>0?aD.relatedWebURL:ak().SPServices.SPGetCurrentSite();switch(aI.attr("Type")){case"Text":aK=aN;break;case"URL":switch(aI.attr("Format")){case"Hyperlink":aK="
    "+aN.substring(aN.search(",")+1)+"";break;case"Image":aK=""+aN.substring(aN.search(",")+1)+"";break;default:aK=aN;break}break;case"User":case"UserMulti":var aB=aN.split(";#");for(aJ=0;aJ"+aB[aJ+1]+"")}aK=aL.join(", ");break;case"Calculated":var aG=aN.split(";#");aK=aG[1];break;case"Number":aF=aI.attr("Decimals");aK=typeof aF==="undefined"?parseFloat(aN).toString():parseFloat(aN).toFixed(aF).toString();break;case"Currency":aF=aI.attr("Decimals");aK=typeof aF==="undefined"?parseFloat(aN).toFixed(2).toString():parseFloat(aN).toFixed(aF).toString();break;case"Lookup":switch(aI.attr("Name")){case"FileRef":aH=aM.attr("BaseType")==="1"?aM.attr("RootFolder")+P+"Forms/DispForm.aspx":aM.attr("RootFolder")+P+"DispForm.aspx";aK=""+aN.substring(aN.search(";#")+2)+"";break;case"FileDirRef":aH=P+aN.substring(aN.search(";#")+2);aK=""+aN.substring(aN.search(";#")+2)+"";break;default:aH=C(aI.attr("List"),"DisplayForm");aK=""+aN.substring(aN.search(";#")+2)+"";break}break;case"LookupMulti":aH=C(aI.attr("List"),"DisplayForm");aK="";if(aN.length>0){var aC=aN.split(";#");for(aJ=0;aJ"+aC[(aJ*2)+1]+"")}}aK=aL.join(", ");break;case"File":Q=aN.substring(aN.search(";#")+2);aK=""+Q+"";break;case"Counter":aK=aN;break;case"DateTime":aK=aN;break;default:aK=aN;break}return aK}function t(aD){var aC;var aB="";for(aC=0;aC"}aB+="
    "+aC+""+aD.attributes.item(aC).nodeName+""+M(aD.attributes.item(aC).nodeValue)+"
    ";return aB}function ar(aB){if((this.Obj=ak("select[Title='"+aB+"']")).length===1){this.Type="S"}else{if((this.Obj=ak("input[Title='"+aB+"']")).length===1){this.Type="C"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title^='"+aB+" ']")).length===1){this.Type="M"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title$=': "+aB+"']")).length===1){this.Type="M"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title$='\""+aB+"\".']")).length===1){this.Type="M"}else{if((this.Obj=ak("select[ID$='SelectCandidate'][Title$=' "+aB+"']")).length===1){this.Type="M"}else{this.Type=null}}}}}}if(this.Type==="M"){this.container=this.Obj.closest("span");this.MultiLookupPickerdata=this.container.find("input[id$='"+an+"_data'], input[id$='"+g+"_data']");var i=this.container.find("[id$='AddButton']").attr("id");this.master=window[i.replace(/AddButton/,an+"_m")]||window[i.replace(/AddButton/,g+"_m")]}}function c(aC,aB){var i=[];switch(aC.Type){case"S":if(aB){i.push(aC.Obj.find("option:selected").val()||[])}else{i.push(aC.Obj.find("option:selected").text()||[])}break;case"C":if(aB){i.push(ak("input[id='"+aC.Obj.attr("optHid")+"']").val()||[])}else{i.push(aC.Obj.val()||[])}break;case"M":ak(aC.master.resultControl).find("option").each(function(){if(aB){i.push(ak(this).val())}else{i.push(ak(this).html())}});break;default:break}return i}function W(aB,aD,aC){var i="Error in function
    "+aB+"
    Parameter
    "+aD+"
    Message
    "+aC+"

    Click to continue
    ";U(i)}function U(aF){var aC="position:absolute;width:300px;height:150px;padding:10px;background-color:#000000;color:#ffffff;z-index:30;font-family:'Arial';font-size:12px;display:none;";ak("#aspnetForm").parent().append("
    "+aF);var i=ak("#SPServices_msgBox").height();var aE=ak("#SPServices_msgBox").width();var aD=(ak(window).width()/2)-(aE/2)+"px";var aB=(ak(window).height()/2)-(i/2)-100+"px";ak("#SPServices_msgBox").css({border:"5px #C02000 solid",left:aD,top:aB}).show().fadeTo("slow",0.75).click(function(){ak(this).fadeOut("3000",function(){ak(this).remove()})})}function ad(i,aB){return i+"_"+ak().SPServices.SPGetStaticFromDisplay({listName:ak().SPServices.SPListNameFromUrl(),columnDisplayName:aB})}function C(i,aC){var aB;ak().SPServices({operation:"GetFormCollection",async:false,listName:i,completefunc:function(aE,aD){aB=ak(aE.responseXML).find("Form[Type='"+aC+"']").attr("Url")}});return aB}function aq(aD,aB){var aC;for(aC=0;aC"+i+""}function q(){return(Math.round(Math.random())-0.5)}function M(i){return((i.indexOf("http")===0)||(i.indexOf(P)===0))?""+i+"":i}function Q(i){return i.substring(i.lastIndexOf(P)+1,i.length)}var X={"&":"&",'"':""","<":"<",">":">"};var G={"&":"&",""":'"',"<":"<",">":">"};function j(i){return i.replace(/([\&"<>])/g,function(aC,aB){return X[aB]})}function H(i){return i.replace(/("|<|>|&)/g,function(aC,aB){return G[aB]})}function K(i){if(typeof i==="string"){return i.replace(/&(?![a-zA-Z]{1,8};)/g,"&")}else{return i}}function z(i){return i.replace(/&/g,"%26")}function n(i){var aB=i.split(";#");this.id=aB[0];this.value=aB[1]}})(jQuery); \ No newline at end of file