From c070e473c5a9b6e819c315ad23303983db3990ba Mon Sep 17 00:00:00 2001 From: Mathijs Verbeeck Date: Thu, 26 May 2022 22:29:19 +0200 Subject: [PATCH 1/3] Temp check in of changes --- .../SharePoint/ContentTypeTests.cs | 30 ++- .../SharePoint/Core/Internal/ContentType.cs | 180 ++++++++++++++++++ .../Core/Internal/ContentTypeCollection.cs | 14 ++ .../Core/Internal/ContentTypeInfo.cs | 24 +++ .../SharePoint/Core/Internal/DocumentSet.cs | 47 +++++ .../Core/Internal/DocumentSetContent.cs | 26 +++ .../SharePoint/Core/Public/IContentType.cs | 22 +++ .../Core/Public/IContentTypeCollection.cs | 18 ++ .../Core/Public/IContentTypeInfo.cs | 19 ++ .../SharePoint/Core/Public/IDocumentSet.cs | 72 +++++++ .../Core/Public/IDocumentSetContent.cs | 25 +++ .../Options/DocumentSetUpdateOptions.cs | 14 ++ 12 files changed, 490 insertions(+), 1 deletion(-) create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeInfo.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSetContent.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeInfo.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSetContent.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs diff --git a/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs b/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs index d9d836494f..7e302c78b2 100644 --- a/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs +++ b/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs @@ -218,7 +218,7 @@ public async Task ContentTypesWithFieldsGetByIdTest() [TestMethod] public async Task ContentTypesAddTest() { - //TestCommon.Instance.Mocking = false; + TestCommon.Instance.Mocking = false; using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) { IContentType newContentType = await context.Web.ContentTypes.AddAsync("0x0100302EF0D1F1DB4C4EBF58251BCCF5968F", "TEST ADD", "TESTING", "TESTING"); @@ -790,5 +790,33 @@ public async Task ContentTypesOrderingOnListTest() } } + #region Document Sets + + [TestMethod] + public async Task GetContentTypeAsDocumentSet() + { + TestCommon.Instance.Mocking = false; + using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) + { + IContentType contentType = (from ct in context.Web.ContentTypes + where ct.StringId == "0x0120D520" + select ct) + .QueryProperties(ct => ct.StringId, ct => ct.Id) + .FirstOrDefault(); + + Assert.IsNotNull(contentType); + // Test Id property + Assert.AreEqual(contentType.Id, "0x0120D520"); + + var documentSet = contentType.AsDocumentSet(); + + + + Assert.AreEqual(documentSet.ContentTypeId, contentType.Id); + } + } + + #endregion + } } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs index a1f375d668..b059b2989b 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs @@ -2,6 +2,7 @@ using PnP.Core.Services.Core.CSOM.Requests; using PnP.Core.Services.Core.CSOM.Requests.Web; using PnP.Core.Services.Core.CSOM.Utils.Model; +using System; using System.Collections.Generic; using System.Dynamic; using System.Net.Http; @@ -128,6 +129,184 @@ public ContentType() public object All { get => null; } #endregion + #region Methods + + public async Task AsDocumentSetAsync() + { + if (!Id.StartsWith("0x0120D520")) + { + throw new ClientException(ErrorType.Unsupported, "The specified content type is not of type 'Document Set'"); + } + + var apiCall = GetDocumentSetApiCall(); + + var response = await RawRequestAsync(apiCall, HttpMethod.Get).ConfigureAwait(false); + + if (response.StatusCode != System.Net.HttpStatusCode.OK) + { + throw new ClientException("Error occured on obtaining the content type"); + } + + var documentSet = new DocumentSet + { + PnPContext = PnPContext, + Parent = this, + ContentTypeId = Id, + }; + + var json = JsonSerializer.Deserialize(response.Json); + DeserializeDocumentSet(json, documentSet); + + return documentSet; + } + + public IDocumentSet AsDocumentSet() + { + return AsDocumentSetAsync().GetAwaiter().GetResult(); + } + + private ApiCall GetDocumentSetApiCall() + { + // implement web / list ct later + var requestUrl = $"sites/{PnPContext.Site.Id}/contentTypes/{Id}"; + + return new ApiCall(requestUrl, ApiType.Graph); + } + + #region Deserialization of document set + + private void DeserializeDocumentSet(JsonElement json, DocumentSet documentSet) + { + if (json.TryGetProperty("documentSet", out JsonElement documentSetJson)) + { + if (documentSetJson.TryGetProperty("shouldPrefixNameToFile", out JsonElement shouldPrefix)) + { + documentSet.ShouldPrefixNameToFile = shouldPrefix.GetBoolean(); + } + if (documentSetJson.TryGetProperty("welcomePageUrl", out JsonElement welcomePageUrl)) + { + documentSet.WelcomePageUrl = welcomePageUrl.GetString(); + } + if (documentSetJson.TryGetProperty("allowedContentTypes", out JsonElement allowedContentTypes)) + { + var allowedContentTypesList = new List(); + + foreach (var allowedContentType in allowedContentTypes.EnumerateArray()) + { + allowedContentTypesList.Add(DeserializeContentType(allowedContentType)); + } + + documentSet.AllowedContentTypes = allowedContentTypesList; + } + if (documentSetJson.TryGetProperty("defaultContents", out JsonElement defaultContents)) + { + var defaultContentsList = new List(); + + foreach (var defaultContent in defaultContents.EnumerateArray()) + { + defaultContentsList.Add(DeseralizeDefaultContent(defaultContent)); + } + + documentSet.DefaultContents = defaultContentsList; + } + if (documentSetJson.TryGetProperty("sharedColumns", out JsonElement sharedColumns)) + { + var sharedColumnsList = new List(); + + foreach (var sharedColumn in sharedColumns.EnumerateArray()) + { + sharedColumnsList.Add(DeseralizeField(sharedColumn)); + } + + documentSet.SharedColumns = sharedColumnsList; + } + if (documentSetJson.TryGetProperty("welcomePageColumns", out JsonElement welcomePageColumns)) + { + var welcomePageColumnsList = new List(); + + foreach (var welcomePageColumn in welcomePageColumns.EnumerateArray()) + { + welcomePageColumnsList.Add(DeseralizeField(welcomePageColumn)); + } + + documentSet.WelcomePageColumns = welcomePageColumnsList; + } + + } + } + + private IField DeseralizeField(JsonElement sharedColumn) + { + var field = new Field(); + + if (sharedColumn.TryGetProperty("name", out JsonElement name)) + { + field.Title = name.GetString(); + } + + if (sharedColumn.TryGetProperty("id", out JsonElement id)) + { + field.Id = id.GetGuid(); + } + + return field; + } + + private IDocumentSetContent DeseralizeDefaultContent(JsonElement defaultContent) + { + var documentSetContent = new DocumentSetContent(); + + if (defaultContent.TryGetProperty("fileName", out JsonElement fileName)) + { + documentSetContent.FileName = fileName.GetString(); + } + + if (defaultContent.TryGetProperty("folderName", out JsonElement folderName)) + { + documentSetContent.FolderName = folderName.GetString(); + } + + if (defaultContent.TryGetProperty("contentType", out JsonElement contentType)) + { + var contentTypeInfo = new ContentTypeInfo(); + + if (contentType.TryGetProperty("id", out JsonElement ctId)) + { + contentTypeInfo.Id = ctId.GetString(); + } + + if (contentType.TryGetProperty("name", out JsonElement ctName)) + { + contentTypeInfo.Name = ctName.GetString(); + } + + documentSetContent.ContentType = contentTypeInfo; + } + + return documentSetContent; + } + + private IContentTypeInfo DeserializeContentType(JsonElement allowedContentType) + { + var contentTypeInfo = new ContentTypeInfo(); + + if (allowedContentType.TryGetProperty("id", out JsonElement id)) + { + contentTypeInfo.Id = id.GetString(); + } + + if (allowedContentType.TryGetProperty("name", out JsonElement name)) + { + contentTypeInfo.Name = name.GetString(); + } + + return contentTypeInfo; + } + + #endregion + + #endregion + #region Extension methods #region AddAvailableContentType private ApiCall AddAvailableContentTypeApiCall(string id) @@ -157,6 +336,7 @@ internal async Task AddAvailableContentTypeAsync(string id) await RequestAsync(apiCall, HttpMethod.Post).ConfigureAwait(false); return this; } + #endregion #endregion } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs index b67c9504da..1c242aa834 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs @@ -129,5 +129,19 @@ public IContentType AddAvailableContentType(string id) } #endregion + + #region Document Set + + public async Task AddDocumentSetAsync(DocumentSetOptions options) + { + return null; + } + + public IDocumentSet AddDocumentSet(DocumentSetOptions options) + { + return AddDocumentSetAsync(options).GetAwaiter().GetResult(); + } + + #endregion } } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeInfo.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeInfo.cs new file mode 100644 index 0000000000..dcaa4be11d --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeInfo.cs @@ -0,0 +1,24 @@ +namespace PnP.Core.Model.SharePoint +{ + [GraphType] + internal sealed class ContentTypeInfo : BaseDataModel, IContentTypeInfo + { + #region Construction + public ContentTypeInfo() + { + } + #endregion + + #region Properties + + public string Id { get => GetValue(); set => SetValue(value); } + + public string Name { get => GetValue(); set => SetValue(value); } + + [KeyProperty(nameof(Id))] + public override object Key { get => Id; set => Id = value.ToString(); } + + #endregion + + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs new file mode 100644 index 0000000000..4381695566 --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs @@ -0,0 +1,47 @@ +using System.Collections.Generic; +using System.Threading.Tasks; + +namespace PnP.Core.Model.SharePoint +{ + [GraphType] + internal sealed class DocumentSet : BaseDataModel, IDocumentSet + { + + #region Properties + + public string ContentTypeId { get => GetValue(); set => SetValue(value); } + + public IList AllowedContentTypes { get => GetValue>(); set => SetValue(value); } + + public IList DefaultContents { get => GetModelCollectionValue>(); set => SetValue(value); } + + public bool PropagateWelcomePageChanges { get => GetValue(); set => SetValue(value); } + + public bool ShouldPrefixNameToFile { get => GetValue(); set => SetValue(value); } + + public string WelcomePageUrl { get => GetValue(); set => SetValue(value); } + + public IList SharedColumns { get => GetValue>(); set => SetValue(value); } + + public IList WelcomePageColumns { get => GetValue>(); set => SetValue(value); } + + [KeyProperty(nameof(ContentTypeId))] + public override object Key { get => ContentTypeId; set => ContentTypeId = value.ToString(); } + + #endregion + + #region Methods + + public async Task UpdateAsync(DocumentSetOptions options) + { + + } + + public void Update(DocumentSetOptions options) + { + UpdateAsync(options).GetAwaiter().GetResult(); + } + + #endregion + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSetContent.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSetContent.cs new file mode 100644 index 0000000000..556e31fbe0 --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSetContent.cs @@ -0,0 +1,26 @@ +namespace PnP.Core.Model.SharePoint +{ + [GraphType] + internal sealed class DocumentSetContent : BaseDataModel, IDocumentSetContent + { + #region Construction + public DocumentSetContent() + { + } + #endregion + + #region Properties + + public IContentTypeInfo ContentType { get => GetModelValue(); set => SetModelValue(value); } + + public string FileName { get => GetValue(); set => SetValue(value); } + + public string FolderName { get => GetValue(); set => SetValue(value); } + + [KeyProperty(nameof(FileName))] + public override object Key { get => FileName; set => FileName = value.ToString(); } + + #endregion + + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs index 4d6054b3d8..75ea234fad 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs @@ -1,4 +1,5 @@ using System.Linq; +using System.Threading.Tasks; namespace PnP.Core.Model.SharePoint { @@ -8,6 +9,9 @@ namespace PnP.Core.Model.SharePoint [ConcreteType(typeof(ContentType))] public interface IContentType : IDataModel, IDataModelGet, IDataModelLoad, IDataModelUpdate, IDataModelDelete, IQueryableDataModel { + + #region Properties + /// /// The unique ID of the Content Type as string /// @@ -171,5 +175,23 @@ public interface IContentType : IDataModel, IDataModelGet //public IWorkflowAssociationCollection WorkflowAssociations { get; } #endregion + + #endregion + + #region Methods + + /// + /// + /// + /// The content type as a document set + Task AsDocumentSetAsync(); + + /// + /// + /// + /// The content type as a document set + IDocumentSet AsDocumentSet(); + + #endregion } } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs index cd61f44804..44d8147380 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs @@ -138,6 +138,24 @@ public interface IContentTypeCollection : IQueryable, IAsyncEnumer #endregion + #region Document Sets + + /// + /// Creates a document set + /// + /// Options for creating the document set + /// Newly created document set + Task AddDocumentSetAsync(DocumentSetOptions options); + + /// + /// Creates a document set + /// + /// Options for creating the document set + /// Newly created document set + IDocumentSet AddDocumentSet(DocumentSetOptions options); + + #endregion + #endregion } } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeInfo.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeInfo.cs new file mode 100644 index 0000000000..151bf3279d --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeInfo.cs @@ -0,0 +1,19 @@ +namespace PnP.Core.Model.SharePoint +{ + /// + /// The contentTypeInfo resource indicates the SharePoint content type of an item. + /// + [ConcreteType(typeof(ContentTypeInfo))] + public interface IContentTypeInfo : IDataModel + { + /// + /// The id of the content type. + /// + public string Id { get; set; } + + /// + /// The name of the content type. + /// + public string Name { get; set; } + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs new file mode 100644 index 0000000000..57a1979af7 --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs @@ -0,0 +1,72 @@ +using System.Collections.Generic; +using System.Threading.Tasks; + +namespace PnP.Core.Model.SharePoint +{ + /// + /// Public interface to define a Document Set. + /// + [ConcreteType(typeof(DocumentSet))] + public interface IDocumentSet : IDataModel + { + #region Properties + + /// + /// Content Type Id + /// + public string ContentTypeId { get; set; } + + /// + /// Content types allowed in document set. + /// + public IList AllowedContentTypes { get; set; } + + /// + /// Default contents of document set. + /// + public IList DefaultContents { get; set; } + + /// + /// Specifies whether to push welcome page changes to inherited content types. + /// + public bool PropagateWelcomePageChanges { get; set; } + + /// + /// Indicates whether to add the name of the document set to each file name. + /// + public bool ShouldPrefixNameToFile { get; set; } + + /// + /// Welcome page absolute URL. + /// + public string WelcomePageUrl { get; set; } + + /// + /// Columns edited on the document set that synchronize to all documents in the set. + /// These are read-only on the documents themselves. + /// + public IList SharedColumns { get; set; } + + /// + /// Specifies columns to show on the welcome page for the document set. + /// + public IList WelcomePageColumns { get; set; } + + #endregion + + #region Methods + + /// + /// Updates the document set + /// + /// + Task UpdateAsync(DocumentSetOptions options); + + /// + /// Updates the document set + /// + void Update(DocumentSetOptions options); + + #endregion + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSetContent.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSetContent.cs new file mode 100644 index 0000000000..7336447066 --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSetContent.cs @@ -0,0 +1,25 @@ +namespace PnP.Core.Model.SharePoint +{ + /// + /// Represents the default content of document set in SharePoint. + /// + [ConcreteType(typeof(DocumentSetContent))] + public interface IDocumentSetContent : IDataModel + { + + /// + /// Content type information of the file. + /// + public IContentTypeInfo ContentType { get; set; } + + /// + /// Name of the file in resource folder that should be added as a default content or a template in the document set. + /// + public string FileName { get; set; } + + /// + /// Folder name in which the file will be placed when a new document set is created in the library. + /// + public string FolderName { get; set; } + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs new file mode 100644 index 0000000000..7ba2088c3e --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs @@ -0,0 +1,14 @@ +namespace PnP.Core.Model.SharePoint +{ + /// + /// Available options for a Document Set + /// + public class DocumentSetOptions + { + + /// + /// Name of the content type + /// + public string Name { get; set; } + } +} From 2046e48d9b5e0116e5a8daac5d050d2f686a2596 Mon Sep 17 00:00:00 2001 From: Mathijs Verbeeck Date: Tue, 31 May 2022 21:38:09 +0200 Subject: [PATCH 2/3] Added functionality for creating document sets using pnp core sdk --- .../SharePoint/ContentTypeTests.cs | 185 +++++++++++++++- ...entTypeAsDocumentSet-0-00000.response.json | 1 + ...entTypeAsDocumentSet-0-00001.response.json | 1 + ...entTypeAsDocumentSet-0-00002.response.json | 1 + ...entTypeAsDocumentSet-0-00003.response.json | 1 + ...entTypeAsDocumentSet-0-00004.response.json | 1 + ...entTypeAsDocumentSet-0-00005.response.json | 1 + ...entTypeAsDocumentSet-0-00006.response.json | 1 + ...entTypeAsDocumentSet-0-00007.response.json | 1 + ...entTypeAsDocumentSet-0-00008.response.json | 1 + ...entTypeAsDocumentSet-0-00009.response.json | 1 + ...entTypeAsDocumentSet-0-00010.response.json | 1 + ...entTypeAsDocumentSet-0-00011.response.json | 1 + ...entTypeAsDocumentSet-0-00012.response.json | 1 + ...entTypeAsDocumentSet-0-00013.response.json | 1 + ...entTypeAsDocumentSet-0-00014.response.json | 1 + ...entTypeAsDocumentSet-0-00015.response.json | 1 + ...entTypeAsDocumentSet-0-00016.response.json | 1 + ...entTypeAsDocumentSet-0-00017.response.json | 1 + ...entTypeAsDocumentSet-0-00018.response.json | 1 + ...entTypeAsDocumentSet-0-00019.response.json | 1 + ...entTypeAsDocumentSet-0-00020.response.json | 1 + ...entTypeAsDocumentSet-0-00021.response.json | 1 + ...entTypeAsDocumentSet-0-00022.response.json | 1 + ...entTypeAsDocumentSet-0-00023.response.json | 1 + ...entTypeAsDocumentSet-0-00024.response.json | 1 + ...entTypeAsDocumentSet-0-00025.response.json | 1 + ...entTypeAsDocumentSet-0-00026.response.json | 1 + ...entTypeAsDocumentSet-1-00000.response.json | 1 + ...entTypeAsDocumentSet-1-00001.response.json | 1 + ...etExceptionAsyncTest-0-00000.response.json | 1 + ...etExceptionAsyncTest-0-00001.response.json | 1 + ...entTypeAsDocumentSet-0-00000.response.json | 1 + ...entTypeAsDocumentSet-0-00001.response.json | 1 + ...entTypeAsDocumentSet-0-00002.response.json | 1 + ...entTypeAsDocumentSet-0-00003.response.json | 1 + ...mentSetExceptionTest-0-00000.response.json | 1 + ...mentSetExceptionTest-0-00001.response.json | 1 + ...mentSetExceptionTest-0-00002.response.json | 1 + ...entTypeAsDocumentSet-0-00000.response.json | 1 + ...entTypeAsDocumentSet-0-00001.response.json | 1 + ...entTypeAsDocumentSet-0-00002.response.json | 1 + ...entTypeAsDocumentSet-0-00003.response.json | 1 + ...entTypeAsDocumentSet-0-00004.response.json | 1 + ...entTypeAsDocumentSet-0-00005.response.json | 1 + ...entTypeAsDocumentSet-0-00006.response.json | 1 + ...entTypeAsDocumentSet-0-00007.response.json | 1 + ...entTypeAsDocumentSet-0-00008.response.json | 1 + ...entTypeAsDocumentSet-0-00009.response.json | 1 + ...entTypeAsDocumentSet-0-00010.response.json | 1 + ...entTypeAsDocumentSet-0-00011.response.json | 1 + ...entTypeAsDocumentSet-0-00012.response.json | 1 + ...entTypeAsDocumentSet-0-00013.response.json | 1 + ...entTypeAsDocumentSet-0-00014.response.json | 1 + ...entTypeAsDocumentSet-0-00015.response.json | 1 + ...entTypeAsDocumentSet-0-00016.response.json | 1 + ...entTypeAsDocumentSet-0-00017.response.json | 1 + ...entTypeAsDocumentSet-0-00018.response.json | 1 + ...entTypeAsDocumentSet-0-00019.response.json | 1 + ...entTypeAsDocumentSet-0-00020.response.json | 1 + ...entTypeAsDocumentSet-0-00021.response.json | 1 + ...entTypeAsDocumentSet-0-00022.response.json | 1 + ...entTypeAsDocumentSet-0-00023.response.json | 1 + ...entTypeAsDocumentSet-0-00024.response.json | 1 + ...entTypeAsDocumentSet-0-00025.response.json | 1 + ...entTypeAsDocumentSet-0-00026.response.json | 1 + ...entTypeAsDocumentSet-0-00027.response.json | 1 + ...entTypeAsDocumentSet-0-00028.response.json | 1 + .../SharePoint/Core/Internal/ContentType.cs | 91 +++++++- .../Core/Internal/ContentTypeCollection.cs | 22 +- .../SharePoint/Core/Internal/DocumentSet.cs | 200 +++++++++++++++++- .../Model/SharePoint/Core/Internal/Field.cs | 1 + .../SharePoint/Core/Public/IContentType.cs | 12 ++ .../Core/Public/IContentTypeCollection.cs | 16 +- .../SharePoint/Core/Public/IDocumentSet.cs | 9 +- .../Options/DocumentSetContentOptions.cs | 28 +++ .../Core/Public/Options/DocumentSetOptions.cs | 66 ++++++ .../Options/DocumentSetUpdateOptions.cs | 14 -- 78 files changed, 665 insertions(+), 46 deletions(-) create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00000.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00001.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00002.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00003.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00004.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00005.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00006.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00007.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00008.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00009.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00010.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00011.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00012.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00013.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00014.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00015.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00016.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00017.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00018.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00019.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00020.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00021.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00022.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00023.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00024.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00025.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00026.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00000.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00001.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00000.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00001.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00000.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00001.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00002.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00003.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00000.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00001.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00002.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00000.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00001.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00002.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00003.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00004.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00005.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00006.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00007.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00008.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00009.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00010.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00011.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00012.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00013.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00014.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00015.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00016.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00017.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00018.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00019.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00020.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00021.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00022.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00023.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00024.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00025.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00026.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00027.response.json create mode 100644 src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00028.response.json create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetContentOptions.cs create mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetOptions.cs delete mode 100644 src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs diff --git a/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs b/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs index 7e302c78b2..41edd101fd 100644 --- a/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs +++ b/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs @@ -6,12 +6,15 @@ using System; using System.Linq; using System.Threading.Tasks; +using System.Collections.Generic; namespace PnP.Core.Test.SharePoint { [TestClass] public class ContentTypeTests { + private const string docSetId = "0x0120D520002E5AAE78D8DB1947903FC99D0979E4A5"; + [ClassInitialize] public static void TestFixtureSetup(TestContext context) { @@ -218,7 +221,7 @@ public async Task ContentTypesWithFieldsGetByIdTest() [TestMethod] public async Task ContentTypesAddTest() { - TestCommon.Instance.Mocking = false; + //TestCommon.Instance.Mocking = false; using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) { IContentType newContentType = await context.Web.ContentTypes.AddAsync("0x0100302EF0D1F1DB4C4EBF58251BCCF5968F", "TEST ADD", "TESTING", "TESTING"); @@ -795,7 +798,7 @@ public async Task ContentTypesOrderingOnListTest() [TestMethod] public async Task GetContentTypeAsDocumentSet() { - TestCommon.Instance.Mocking = false; + //TestCommon.Instance.Mocking = false; using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) { IContentType contentType = (from ct in context.Web.ContentTypes @@ -810,9 +813,183 @@ public async Task GetContentTypeAsDocumentSet() var documentSet = contentType.AsDocumentSet(); - - Assert.AreEqual(documentSet.ContentTypeId, contentType.Id); + Assert.IsNotNull(documentSet.DefaultContents); + Assert.IsNotNull(documentSet.SharedColumns); + Assert.IsNotNull(documentSet.WelcomePageColumns); + Assert.IsNotNull(documentSet.AllowedContentTypes); + } + } + + [TestMethod] + public async Task AddContentTypeAsDocumentSet() + { + //TestCommon.Instance.Mocking = false; + using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) + { + var list = await context.Web.Lists.GetByTitle("Documents").GetAsync(); + var rootFolder = await list.RootFolder.GetAsync(); + + (_, _, string documentUrl) = await TestAssets.CreateTestDocumentAsync(1, parentFolder: rootFolder); + + var categoriesField = await context.Web.Fields.FirstAsync(y => y.InternalName == "Categories").ConfigureAwait(false); + var managersField = await context.Web.Fields.FirstAsync(y => y.InternalName == "ManagersName").ConfigureAwait(false); + var file = await context.Web.GetFileByServerRelativeUrlAsync(documentUrl); + var documentCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Document"); + var formCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Form"); + + var documentSetOptions = new DocumentSetOptions + { + AllowedContentTypes = new List + { + documentCt, + formCt + }, + ShouldPrefixNameToFile = true, + PropagateWelcomePageChanges = true, + SharedColumns = new List + { + managersField, + categoriesField + }, + WelcomePageColumns = new List + { + managersField, + categoriesField + }, + DefaultContents = new List + { + new DocumentSetContentOptions + { + FileName = "Test.docx", + FolderName = "FolderName", + File = file, + ContentTypeId = documentCt.StringId + } + } + }; + + IDocumentSet newDocumentSet = await context.Web.ContentTypes.AddDocumentSetAsync(docSetId, "Document set name", "TESTING", "TESTING", documentSetOptions); + IContentType newContentType = newDocumentSet.Parent as IContentType; + // Test the created object + Assert.IsNotNull(newContentType); + Assert.IsNotNull(newDocumentSet); + + Assert.AreEqual(newDocumentSet.SharedColumns.Count, documentSetOptions.SharedColumns.Count); + Assert.AreEqual(newDocumentSet.WelcomePageColumns.Count, documentSetOptions.WelcomePageColumns.Count); + Assert.AreEqual(newDocumentSet.DefaultContents.Count, documentSetOptions.DefaultContents.Count); + Assert.AreEqual(newDocumentSet.AllowedContentTypes.Count, documentSetOptions.AllowedContentTypes.Count); + Assert.AreEqual(newDocumentSet.ShouldPrefixNameToFile, documentSetOptions.ShouldPrefixNameToFile); + + await newContentType.DeleteAsync(); + await file.DeleteAsync(); + } + } + + [TestMethod] + public async Task UpdateContentTypeAsDocumentSet() + { + //TestCommon.Instance.Mocking = false; + using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) + { + var list = await context.Web.Lists.GetByTitle("Documents").GetAsync(); + var rootFolder = await list.RootFolder.GetAsync(); + + (_, _, string documentUrl) = await TestAssets.CreateTestDocumentAsync(parentFolder: rootFolder); + + var categoriesField = await context.Web.Fields.FirstAsync(y => y.InternalName == "Categories").ConfigureAwait(false); + var managersField = await context.Web.Fields.FirstAsync(y => y.InternalName == "ManagersName").ConfigureAwait(false); + var documentCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Document"); + + var file = await context.Web.GetFileByServerRelativeUrlAsync(documentUrl); + + var documentSetOptions = new DocumentSetOptions + { + SharedColumns = new List + { + categoriesField + }, + WelcomePageColumns = new List + { + categoriesField + }, + DefaultContents = new List + { + new DocumentSetContentOptions + { + FileName = "Test.docx", + FolderName = "FolderName", + File = file, + ContentTypeId = documentCt.StringId + } + } + }; + + IDocumentSet newDocumentSet = await context.Web.ContentTypes.AddDocumentSetAsync(docSetId, "Document Set Name", "TESTING", "TESTING", documentSetOptions); + + Assert.IsNotNull(newDocumentSet); + Assert.AreEqual(newDocumentSet.SharedColumns.Count, documentSetOptions.SharedColumns.Count); + Assert.AreEqual(newDocumentSet.WelcomePageColumns.Count, documentSetOptions.WelcomePageColumns.Count); + Assert.AreEqual(newDocumentSet.DefaultContents.Count, documentSetOptions.DefaultContents.Count); + + var documentSetOptionsUpdate = new DocumentSetOptions + { + SharedColumns = new List + { + managersField + }, + WelcomePageColumns = new List + { + managersField + }, + DefaultContents = new List + { + new DocumentSetContentOptions + { + FileName = "Test2.docx", + FolderName = "FolderName2", + File = file, + ContentTypeId = documentCt.StringId + } + } + }; + newDocumentSet = await newDocumentSet.UpdateAsync(documentSetOptionsUpdate); + IContentType newContentType = newDocumentSet.Parent as IContentType; + + Assert.IsNotNull(newDocumentSet); + Assert.AreEqual(newDocumentSet.SharedColumns.Count, documentSetOptionsUpdate.SharedColumns.Count + documentSetOptions.SharedColumns.Count); + Assert.AreEqual(newDocumentSet.WelcomePageColumns.Count, documentSetOptionsUpdate.WelcomePageColumns.Count + documentSetOptions.WelcomePageColumns.Count); + Assert.AreEqual(newDocumentSet.DefaultContents.Count, documentSetOptionsUpdate.DefaultContents.Count + documentSetOptions.DefaultContents.Count); + + await newContentType.DeleteAsync(); + await file.DeleteAsync(); + } + } + + [TestMethod] + [ExpectedException(typeof(ArgumentException))] + public async Task AddContentTypeAsDocumentSetExceptionAsyncTest() + { + //TestCommon.Instance.Mocking = false; + using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) + { + IDocumentSet newDocumentSet = await context.Web.ContentTypes.AddDocumentSetAsync("0x0101mlalalala", "Document set name"); + } + } + + [TestMethod] + [ExpectedException(typeof(ClientException))] + public async Task GetContentTypeAsDocumentSetExceptionTest() + { + //TestCommon.Instance.Mocking = false; + using (var context = await TestCommon.Instance.GetContextAsync(TestCommon.TestSite)) + { + IContentType contentType = (from ct in context.Web.ContentTypes + where ct.StringId == "0x0101" + select ct) + .QueryProperties(ct => ct.StringId, ct => ct.Id) + .FirstOrDefault(); + var documentSet = contentType.AsDocumentSet(); } } diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00000.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00000.response.json new file mode 100644 index 0000000000..2b47eb2d1e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00000.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-c032-4000-4c6b-a2dff63a4ea3","SPClientServiceRequestDuration":"12","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022RegionalSettings\u0022:{\u0022TimeZone\u0022:{\u0022Description\u0022:\u0022(UTC-08:00) Pacific Time (US and Canada)\u0022,\u0022Id\u0022:13,\u0022Information\u0022:{\u0022Bias\u0022:480,\u0022DaylightBias\u0022:-60,\u0022StandardBias\u0022:0}},\u0022AdjustHijriDays\u0022:0,\u0022AlternateCalendarType\u0022:0,\u0022AM\u0022:\u0022AM\u0022,\u0022CalendarType\u0022:1,\u0022Collation\u0022:25,\u0022CollationLCID\u0022:2070,\u0022DateFormat\u0022:0,\u0022DateSeparator\u0022:\u0022/\u0022,\u0022DecimalSeparator\u0022:\u0022.\u0022,\u0022DigitGrouping\u0022:\u00223;0\u0022,\u0022FirstDayOfWeek\u0022:0,\u0022FirstWeekOfYear\u0022:0,\u0022IsEastAsia\u0022:false,\u0022IsRightToLeft\u0022:false,\u0022IsUIRightToLeft\u0022:false,\u0022ListSeparator\u0022:\u0022,\u0022,\u0022LocaleId\u0022:1033,\u0022NegativeSign\u0022:\u0022-\u0022,\u0022NegNumberMode\u0022:1,\u0022PM\u0022:\u0022PM\u0022,\u0022PositiveSign\u0022:\u0022\u0022,\u0022ShowWeeks\u0022:false,\u0022ThousandSeparator\u0022:\u0022,\u0022,\u0022Time24\u0022:false,\u0022TimeMarkerPosition\u0022:0,\u0022TimeSeparator\u0022:\u0022:\u0022,\u0022WorkDayEndHour\u0022:1020,\u0022WorkDays\u0022:62,\u0022WorkDayStartHour\u0022:480},\u0022Id\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022Url\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00001.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00001.response.json new file mode 100644 index 0000000000..15ee845c25 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00001.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-5037-4000-4c6b-ad656c469a01","SPClientServiceRequestDuration":"10","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022GroupId\u0022:\u00220ad55b5d-6a79-467b-ad21-d4bef7948a79\u0022,\u0022Id\u0022:\u00220f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00002.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00002.response.json new file mode 100644 index 0000000000..b1e1d6e457 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00002.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-e03d-4000-4c6b-a42cc0dca2ca","SPClientServiceRequestDuration":"40","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AllowContentTypes\u0022:true,\u0022BaseTemplate\u0022:101,\u0022BaseType\u0022:1,\u0022ContentTypesEnabled\u0022:false,\u0022CrawlNonDefaultViews\u0022:false,\u0022Created\u0022:\u00222022-03-06T01:58:24Z\u0022,\u0022CurrentChangeToken\u0022:{\u0022StringValue\u0022:\u00221;3;68e9c7c6-94e1-4422-9eef-ca5a274ee7c6;637896226038600000;496856759\u0022},\u0022DefaultContentApprovalWorkflowId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022DefaultItemOpenUseListSetting\u0022:false,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022DisableCommenting\u0022:false,\u0022DisableGridEditing\u0022:false,\u0022DocumentTemplateUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/Forms/template.dotx\u0022,\u0022DraftVersionVisibility\u0022:0,\u0022EnableAttachments\u0022:false,\u0022EnableFolderCreation\u0022:true,\u0022EnableMinorVersions\u0022:false,\u0022EnableModeration\u0022:false,\u0022EnableRequestSignOff\u0022:true,\u0022EnableVersioning\u0022:true,\u0022EntityTypeName\u0022:\u0022Shared_x0020_Documents\u0022,\u0022ExemptFromBlockDownloadOfNonViewableFiles\u0022:false,\u0022FileSavePostProcessingEnabled\u0022:false,\u0022ForceCheckout\u0022:false,\u0022HasExternalDataSource\u0022:false,\u0022Hidden\u0022:false,\u0022Id\u0022:\u002268e9c7c6-94e1-4422-9eef-ca5a274ee7c6\u0022,\u0022ImagePath\u0022:{\u0022DecodedUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022},\u0022ImageUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022,\u0022DefaultSensitivityLabelForLibrary\u0022:\u0022\u0022,\u0022IrmEnabled\u0022:false,\u0022IrmExpire\u0022:false,\u0022IrmReject\u0022:false,\u0022IsApplicationList\u0022:false,\u0022IsCatalog\u0022:false,\u0022IsPrivate\u0022:false,\u0022ItemCount\u0022:4,\u0022LastItemDeletedDate\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022LastItemModifiedDate\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022LastItemUserModifiedDate\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022ListExperienceOptions\u0022:1,\u0022ListItemEntityTypeFullName\u0022:\u0022SP.Data.Shared_x0020_DocumentsItem\u0022,\u0022MajorVersionLimit\u0022:500,\u0022MajorWithMinorVersionsLimit\u0022:0,\u0022MultipleDataList\u0022:false,\u0022NoCrawl\u0022:false,\u0022ParentWebPath\u0022:{\u0022DecodedUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022},\u0022ParentWebUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022ParserDisabled\u0022:false,\u0022ServerTemplateCanCreateFolders\u0022:true,\u0022TemplateFeatureId\u0022:\u002200bfea71-e717-4e80-aa17-d0c71b360101\u0022,\u0022Title\u0022:\u0022Documents\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00003.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00003.response.json new file mode 100644 index 0000000000..131ea6056c --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00003.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-b043-4000-4767-d130dc146c8d","SPClientServiceRequestDuration":"65","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022AllowContentTypes\u0022:true,\u0022BaseTemplate\u0022:101,\u0022BaseType\u0022:1,\u0022ContentTypesEnabled\u0022:false,\u0022CrawlNonDefaultViews\u0022:false,\u0022Created\u0022:\u00222022-03-06T01:58:24Z\u0022,\u0022CurrentChangeToken\u0022:{\u0022StringValue\u0022:\u00221;3;68e9c7c6-94e1-4422-9eef-ca5a274ee7c6;637896226049000000;496856760\u0022},\u0022DefaultContentApprovalWorkflowId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022DefaultItemOpenUseListSetting\u0022:false,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022DisableCommenting\u0022:false,\u0022DisableGridEditing\u0022:false,\u0022DocumentTemplateUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/Forms/template.dotx\u0022,\u0022DraftVersionVisibility\u0022:0,\u0022EnableAttachments\u0022:false,\u0022EnableFolderCreation\u0022:true,\u0022EnableMinorVersions\u0022:false,\u0022EnableModeration\u0022:false,\u0022EnableRequestSignOff\u0022:true,\u0022EnableVersioning\u0022:true,\u0022EntityTypeName\u0022:\u0022Shared_x0020_Documents\u0022,\u0022ExemptFromBlockDownloadOfNonViewableFiles\u0022:false,\u0022FileSavePostProcessingEnabled\u0022:false,\u0022ForceCheckout\u0022:false,\u0022HasExternalDataSource\u0022:false,\u0022Hidden\u0022:false,\u0022Id\u0022:\u002268e9c7c6-94e1-4422-9eef-ca5a274ee7c6\u0022,\u0022ImagePath\u0022:{\u0022DecodedUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022},\u0022ImageUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022,\u0022DefaultSensitivityLabelForLibrary\u0022:\u0022\u0022,\u0022IrmEnabled\u0022:false,\u0022IrmExpire\u0022:false,\u0022IrmReject\u0022:false,\u0022IsApplicationList\u0022:false,\u0022IsCatalog\u0022:false,\u0022IsPrivate\u0022:false,\u0022ItemCount\u0022:4,\u0022LastItemDeletedDate\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022LastItemModifiedDate\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022LastItemUserModifiedDate\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022ListExperienceOptions\u0022:1,\u0022ListItemEntityTypeFullName\u0022:\u0022SP.Data.Shared_x0020_DocumentsItem\u0022,\u0022MajorVersionLimit\u0022:500,\u0022MajorWithMinorVersionsLimit\u0022:0,\u0022MultipleDataList\u0022:false,\u0022NoCrawl\u0022:false,\u0022ParentWebPath\u0022:{\u0022DecodedUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022},\u0022ParentWebUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022ParserDisabled\u0022:false,\u0022ServerTemplateCanCreateFolders\u0022:true,\u0022TemplateFeatureId\u0022:\u002200bfea71-e717-4e80-aa17-d0c71b360101\u0022,\u0022Title\u0022:\u0022Documents\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00004.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00004.response.json new file mode 100644 index 0000000000..3a6e7cd1a7 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00004.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-204b-4000-4c6b-aa7f8aeabe27","SPClientServiceRequestDuration":"19","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022Exists\u0022:true,\u0022IsWOPIEnabled\u0022:false,\u0022ItemCount\u0022:4,\u0022Name\u0022:\u0022Shared Documents\u0022,\u0022ProgID\u0022:null,\u0022ServerRelativeUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents\u0022,\u0022TimeCreated\u0022:\u00222022-03-06T01:58:24Z\u0022,\u0022TimeLastModified\u0022:\u00222022-05-31T19:36:44Z\u0022,\u0022UniqueId\u0022:\u00222a0ba280-7c53-4eb9-a460-2c31576f90a8\u0022,\u0022WelcomePage\u0022:\u0022\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00005.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00005.response.json new file mode 100644 index 0000000000..7bd79a0f52 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00005.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-3058-4000-4767-de0c5fad5584","SPClientServiceRequestDuration":"183","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022CheckInComment\u0022:\u0022\u0022,\u0022CheckOutType\u0022:2,\u0022ContentTag\u0022:\u0022{AD260C10-2802-46D1-B023-EF4FF5EB84EB},1,2\u0022,\u0022CustomizedPageStatus\u0022:0,\u0022ETag\u0022:\u0022\\\u0022{AD260C10-2802-46D1-B023-EF4FF5EB84EB},1\\\u0022\u0022,\u0022Exists\u0022:true,\u0022IrmEnabled\u0022:false,\u0022Length\u0022:\u002218333\u0022,\u0022Level\u0022:1,\u0022LinkingUri\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared%20Documents/PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx?d=wad260c10280246d1b023ef4ff5eb84eb\u0022,\u0022LinkingUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx?d=wad260c10280246d1b023ef4ff5eb84eb\u0022,\u0022MajorVersion\u0022:1,\u0022MinorVersion\u0022:0,\u0022Name\u0022:\u0022PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx\u0022,\u0022ServerRelativeUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx\u0022,\u0022TimeCreated\u0022:\u00222022-05-31T19:36:45Z\u0022,\u0022TimeLastModified\u0022:\u00222022-05-31T19:36:45Z\u0022,\u0022Title\u0022:\u0022\u0022,\u0022UIVersion\u0022:512,\u0022UIVersionLabel\u0022:\u00221.0\u0022,\u0022UniqueId\u0022:\u0022ad260c10-2802-46d1-b023-ef4ff5eb84eb\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00006.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00006.response.json new file mode 100644 index 0000000000..3b93dc3911 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00006.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-7067-4000-4c6b-ab85ab0a9cef","SPClientServiceRequestDuration":"38","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Categories\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Base Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Categories\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{9EBCD900-9D05-46c8-8F4D-E46E87328844}\\\u0022 Name=\\\u0022Categories\\\u0022 StaticName=\\\u0022Categories\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Categories\\\u0022 Group=\\\u0022Base Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Categories\u0022,\u0022Title\u0022:\u0022Categories\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00007.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00007.response.json new file mode 100644 index 0000000000..0749795087 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00007.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-006e-4000-4c6b-a9574fa29d7b","SPClientServiceRequestDuration":"35","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ManagersName\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ManagersName\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{BA934502-D68D-4960-A54B-51E15FEF5FD3}\\\u0022 Name=\\\u0022ManagersName\\\u0022 StaticName=\\\u0022ManagersName\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Manager\u0026#39;s Name\\\u0022 Group=\\\u0022Core Contact and Calendar Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022ManagersName\u0022,\u0022Title\u0022:\u0022Manager\u0027s Name\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00008.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00008.response.json new file mode 100644 index 0000000000..b4df985ba5 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00008.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-9074-4000-4c6b-a5dc718c982b","SPClientServiceRequestDuration":"14","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022CheckInComment\u0022:\u0022\u0022,\u0022CheckOutType\u0022:2,\u0022ContentTag\u0022:\u0022{AD260C10-2802-46D1-B023-EF4FF5EB84EB},1,2\u0022,\u0022CustomizedPageStatus\u0022:0,\u0022ETag\u0022:\u0022\\\u0022{AD260C10-2802-46D1-B023-EF4FF5EB84EB},1\\\u0022\u0022,\u0022Exists\u0022:true,\u0022IrmEnabled\u0022:false,\u0022Length\u0022:\u002218333\u0022,\u0022Level\u0022:1,\u0022LinkingUri\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared%20Documents/PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx?d=wad260c10280246d1b023ef4ff5eb84eb\u0022,\u0022LinkingUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx?d=wad260c10280246d1b023ef4ff5eb84eb\u0022,\u0022MajorVersion\u0022:1,\u0022MinorVersion\u0022:0,\u0022Name\u0022:\u0022PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx\u0022,\u0022ServerRelativeUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_AddContentTypeAsDocumentSet.docx\u0022,\u0022TimeCreated\u0022:\u00222022-05-31T19:36:45Z\u0022,\u0022TimeLastModified\u0022:\u00222022-05-31T19:36:45Z\u0022,\u0022Title\u0022:\u0022\u0022,\u0022UIVersion\u0022:512,\u0022UIVersionLabel\u0022:\u00221.0\u0022,\u0022UniqueId\u0022:\u0022ad260c10-2802-46d1-b023-ef4ff5eb84eb\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00009.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00009.response.json new file mode 100644 index 0000000000..41865cc276 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00009.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-6079-4000-4767-d48b1c4caf9c","SPClientServiceRequestDuration":"25","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022ClientFormCustomFormatter\u0022:\u0022\u0022,\u0022Description\u0022:\u0022Create a new document.\u0022,\u0022DisplayFormClientSideComponentId\u0022:null,\u0022DisplayFormClientSideComponentProperties\u0022:null,\u0022DisplayFormTarget\u0022:0,\u0022DisplayFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022DisplayFormUrl\u0022:\u0022\u0022,\u0022DocumentTemplate\u0022:\u0022\u0022,\u0022DocumentTemplateUrl\u0022:\u0022\u0022,\u0022EditFormClientSideComponentId\u0022:null,\u0022EditFormClientSideComponentProperties\u0022:null,\u0022EditFormTarget\u0022:0,\u0022EditFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022EditFormUrl\u0022:\u0022\u0022,\u0022Group\u0022:\u0022Document Content Types\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:{\u0022StringValue\u0022:\u00220x0101\u0022},\u0022JSLink\u0022:\u0022\u0022,\u0022MobileDisplayFormUrl\u0022:\u0022\u0022,\u0022MobileEditFormUrl\u0022:\u0022\u0022,\u0022MobileNewFormUrl\u0022:\u0022\u0022,\u0022Name\u0022:\u0022Document\u0022,\u0022NewFormClientSideComponentId\u0022:null,\u0022NewFormClientSideComponentProperties\u0022:null,\u0022NewFormTarget\u0022:0,\u0022NewFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022NewFormUrl\u0022:\u0022\u0022,\u0022ReadOnly\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CContentType ID=\\\u00220x0101\\\u0022 Name=\\\u0022Document\\\u0022 Group=\\\u0022Document Content Types\\\u0022 Description=\\\u0022Create a new document.\\\u0022 Version=\\\u00220\\\u0022 FeatureId=\\\u0022{695b6570-a48b-4a8e-8ea5-26ea7fc1d162}\\\u0022\u003E\u003CFolder TargetName=\\\u0022_cts/Document\\\u0022 /\u003E\u003CFields\u003E\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{5f47e085-2150-41dc-b661-442f3027f552}\\\u0022 Name=\\\u0022SelectFilename\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022SelectFilename\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Select\\\u0022 Hidden=\\\u0022TRUE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 AuthoringInfo=\\\u0022(web part connection)\\\u0022 HeaderImage=\\\u0022blank.gif\\\u0022 Sortable=\\\u0022FALSE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{1d22ea11-1e32-424e-89ab-9fedbadb6ce1}\\\u0022 Name=\\\u0022ID\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CIfEqual\u003E\u003CExpr1\u003E\u003CGetVar Name=\\\u0022SelectedID\\\u0022 /\u003E\u003C/Expr1\u003E\u003CExpr2\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/Expr2\u003E\u003CThen\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cimg align=\\\u0022absmiddle\\\u0022 style=\\\u0022cursor: hand\\\u0022 src=\\\u0022/_layouts/15/images/rbsel.gif?rev=47\\\u0022 alt=\\\u0022]]\u003E\u003C/HTML\u003E\u003CHTML\u003ESelected\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003C/Then\u003E\u003CElse\u003E\u003CHTML\u003E\u003C![CDATA[\u003Ca href=\\\u0022javascript:SelectField(\u0027]]\u003E\u003C/HTML\u003E\u003CGetVar Name=\\\u0022View\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\u0027,\u0027]]\u003E\u003C/HTML\u003E\u003CScriptQuote NotAddingQuote=\\\u0022TRUE\\\u0022\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/ScriptQuote\u003E\u003CHTML\u003E\u003C![CDATA[\u0027);return false;\\\u0022 onclick=\\\u0022javascript:SelectField(\u0027]]\u003E\u003C/HTML\u003E\u003CGetVar Name=\\\u0022View\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\u0027,\u0027]]\u003E\u003C/HTML\u003E\u003CScriptQuote NotAddingQuote=\\\u0022TRUE\\\u0022\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/ScriptQuote\u003E\u003CHTML\u003E\u003C![CDATA[\u0027);return false;\\\u0022 target=\\\u0022_self\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cimg border=\\\u00220\\\u0022 align=\\\u0022absmiddle\\\u0022 style=\\\u0022cursor: hand\\\u0022 src=\\\u0022/_layouts/15/images/rbunsel.gif?rev=47\\\u0022 alt=\\\u0022]]\u003E\u003C/HTML\u003E\u003CHTML\u003ENormal\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\u003C/a\u003E]]\u003E\u003C/HTML\u003E\u003C/Else\u003E\u003C/IfEqual\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{8c06beca-0777-48f7-91c7-6da68bc07b69}\\\u0022 Name=\\\u0022Created\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Created\\\u0022 Group=\\\u0022_Hidden\\\u0022 ColName=\\\u0022tp_Created\\\u0022 RowOrdinal=\\\u00220\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022DateTime\\\u0022 DisplayName=\\\u0022Created\\\u0022 StorageTZ=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\\\u0022 Name=\\\u0022Title\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Title\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Title\\\u0022 Required=\\\u0022FALSE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 ShowInNewForm=\\\u0022FALSE\\\u0022 ShowInEditForm=\\\u0022TRUE\\\u0022 /\u003E\u003CField ID=\\\u0022{28cf69c5-fa48-462a-b5cd-27b6f9d2bd5f}\\\u0022 Name=\\\u0022Modified\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Modified\\\u0022 Group=\\\u0022_Hidden\\\u0022 ColName=\\\u0022tp_Modified\\\u0022 RowOrdinal=\\\u00220\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022DateTime\\\u0022 DisplayName=\\\u0022Modified\\\u0022 StorageTZ=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{822c78e3-1ea9-4943-b449-57863ad33ca9}\\\u0022 Name=\\\u0022Modified_x0020_By\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Modified_x0020_By\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Document Modified By\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{4dd7e525-8d6b-4cb4-9d3e-44ee25f973eb}\\\u0022 Name=\\\u0022Created_x0020_By\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Created_x0020_By\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Document Created By\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u003C/Fields\u003E\u003CXmlDocuments\u003E\u003CXmlDocument NamespaceURI=\\\u0022http://schemas.microsoft.com/sharepoint/v3/contenttype/forms\\\u0022\u003E\u003CFormTemplates xmlns=\\\u0022http://schemas.microsoft.com/sharepoint/v3/contenttype/forms\\\u0022\u003E\u003CDisplay\u003EDocumentLibraryForm\u003C/Display\u003E\u003CEdit\u003EDocumentLibraryForm\u003C/Edit\u003E\u003CNew\u003EDocumentLibraryForm\u003C/New\u003E\u003C/FormTemplates\u003E\u003C/XmlDocument\u003E\u003C/XmlDocuments\u003E\u003C/ContentType\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022StringId\u0022:\u00220x0101\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00010.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00010.response.json new file mode 100644 index 0000000000..87822be615 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00010.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-f07d-4000-4c6b-ab0700321de2","SPClientServiceRequestDuration":"28","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022ClientFormCustomFormatter\u0022:\u0022\u0022,\u0022Description\u0022:\u0022Fill out this form.\u0022,\u0022DisplayFormClientSideComponentId\u0022:null,\u0022DisplayFormClientSideComponentProperties\u0022:null,\u0022DisplayFormTarget\u0022:0,\u0022DisplayFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022DisplayFormUrl\u0022:\u0022\u0022,\u0022DocumentTemplate\u0022:\u0022\u0022,\u0022DocumentTemplateUrl\u0022:\u0022\u0022,\u0022EditFormClientSideComponentId\u0022:null,\u0022EditFormClientSideComponentProperties\u0022:null,\u0022EditFormTarget\u0022:0,\u0022EditFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022EditFormUrl\u0022:\u0022\u0022,\u0022Group\u0022:\u0022Document Content Types\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:{\u0022StringValue\u0022:\u00220x010101\u0022},\u0022JSLink\u0022:\u0022\u0022,\u0022MobileDisplayFormUrl\u0022:\u0022\u0022,\u0022MobileEditFormUrl\u0022:\u0022\u0022,\u0022MobileNewFormUrl\u0022:\u0022\u0022,\u0022Name\u0022:\u0022Form\u0022,\u0022NewFormClientSideComponentId\u0022:null,\u0022NewFormClientSideComponentProperties\u0022:null,\u0022NewFormTarget\u0022:0,\u0022NewFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022NewFormUrl\u0022:\u0022\u0022,\u0022ReadOnly\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CContentType ID=\\\u00220x010101\\\u0022 Name=\\\u0022Form\\\u0022 Group=\\\u0022Document Content Types\\\u0022 Description=\\\u0022Fill out this form.\\\u0022 Version=\\\u00220\\\u0022 FeatureId=\\\u0022{695b6570-a48b-4a8e-8ea5-26ea7fc1d162}\\\u0022\u003E\u003CFolder TargetName=\\\u0022_cts/Form\\\u0022 /\u003E\u003CFields\u003E\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{5f47e085-2150-41dc-b661-442f3027f552}\\\u0022 Name=\\\u0022SelectFilename\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022SelectFilename\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Select\\\u0022 Hidden=\\\u0022TRUE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 AuthoringInfo=\\\u0022(web part connection)\\\u0022 HeaderImage=\\\u0022blank.gif\\\u0022 Sortable=\\\u0022FALSE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{1d22ea11-1e32-424e-89ab-9fedbadb6ce1}\\\u0022 Name=\\\u0022ID\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CIfEqual\u003E\u003CExpr1\u003E\u003CGetVar Name=\\\u0022SelectedID\\\u0022 /\u003E\u003C/Expr1\u003E\u003CExpr2\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/Expr2\u003E\u003CThen\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cimg align=\\\u0022absmiddle\\\u0022 style=\\\u0022cursor: hand\\\u0022 src=\\\u0022/_layouts/15/images/rbsel.gif?rev=47\\\u0022 alt=\\\u0022]]\u003E\u003C/HTML\u003E\u003CHTML\u003ESelected\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003C/Then\u003E\u003CElse\u003E\u003CHTML\u003E\u003C![CDATA[\u003Ca href=\\\u0022javascript:SelectField(\u0027]]\u003E\u003C/HTML\u003E\u003CGetVar Name=\\\u0022View\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\u0027,\u0027]]\u003E\u003C/HTML\u003E\u003CScriptQuote NotAddingQuote=\\\u0022TRUE\\\u0022\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/ScriptQuote\u003E\u003CHTML\u003E\u003C![CDATA[\u0027);return false;\\\u0022 onclick=\\\u0022javascript:SelectField(\u0027]]\u003E\u003C/HTML\u003E\u003CGetVar Name=\\\u0022View\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\u0027,\u0027]]\u003E\u003C/HTML\u003E\u003CScriptQuote NotAddingQuote=\\\u0022TRUE\\\u0022\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/ScriptQuote\u003E\u003CHTML\u003E\u003C![CDATA[\u0027);return false;\\\u0022 target=\\\u0022_self\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cimg border=\\\u00220\\\u0022 align=\\\u0022absmiddle\\\u0022 style=\\\u0022cursor: hand\\\u0022 src=\\\u0022/_layouts/15/images/rbunsel.gif?rev=47\\\u0022 alt=\\\u0022]]\u003E\u003C/HTML\u003E\u003CHTML\u003ENormal\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\u003C/a\u003E]]\u003E\u003C/HTML\u003E\u003C/Else\u003E\u003C/IfEqual\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{8c06beca-0777-48f7-91c7-6da68bc07b69}\\\u0022 Name=\\\u0022Created\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Created\\\u0022 Group=\\\u0022_Hidden\\\u0022 ColName=\\\u0022tp_Created\\\u0022 RowOrdinal=\\\u00220\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022DateTime\\\u0022 DisplayName=\\\u0022Created\\\u0022 StorageTZ=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{28cf69c5-fa48-462a-b5cd-27b6f9d2bd5f}\\\u0022 Name=\\\u0022Modified\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Modified\\\u0022 Group=\\\u0022_Hidden\\\u0022 ColName=\\\u0022tp_Modified\\\u0022 RowOrdinal=\\\u00220\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022DateTime\\\u0022 DisplayName=\\\u0022Modified\\\u0022 StorageTZ=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{822c78e3-1ea9-4943-b449-57863ad33ca9}\\\u0022 Name=\\\u0022Modified_x0020_By\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Modified_x0020_By\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Document Modified By\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{4dd7e525-8d6b-4cb4-9d3e-44ee25f973eb}\\\u0022 Name=\\\u0022Created_x0020_By\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Created_x0020_By\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Document Created By\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{E52012A0-51EB-4c0c-8DFB-9B8A0EBEDCB6}\\\u0022 Name=\\\u0022Combine\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Combine\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022Computed\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Merge\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{30BB605F-5BAE-48fe-B4E3-1F81D9772AF9}\\\u0022 Name=\\\u0022FSObjType\\\u0022 Key=\\\u0022Primary\\\u0022 /\u003E\u003CFieldRef ID=\\\u0022{7177CFC7-F399-4d4d-905D-37DD51BC90BF}\\\u0022 Name=\\\u0022EncodedAbsUrl\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CIfEqual\u003E\u003CExpr1\u003E\u003CField Name=\\\u0022FSObjType\\\u0022 /\u003E\u003C/Expr1\u003E\u003CExpr2\u003E0\u003C/Expr2\u003E\u003CThen\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cinput ID=\\\u0022chkCombine\\\u0022 TYPE=\\\u0022CHECKBOX\\\u0022 Title=\\\u0022Merge\\\u0022 HREF=\\\u0022]]\u003E\u003C/HTML\u003E\u003CField Name=\\\u0022EncodedAbsUrl\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003C/Then\u003E\u003C/IfEqual\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{086F2B30-460C-4251-B75A-DA88A5B205C1}\\\u0022 Type=\\\u0022Text\\\u0022 Group=\\\u0022_Hidden\\\u0022 Name=\\\u0022ShowCombineView\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ShowCombineView\\\u0022 DisplayName=\\\u0022Show Combine View\\\u0022 Filterable=\\\u0022TRUE\\\u0022 Sortable=\\\u0022TRUE\\\u0022 Hidden=\\\u0022TRUE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{5D36727B-BCB2-47d2-A231-1F0BC63B7439}\\\u0022 Name=\\\u0022RepairDocument\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022RepairDocument\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022Computed\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Relink\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{30BB605F-5BAE-48fe-B4E3-1F81D9772AF9}\\\u0022 Name=\\\u0022FSObjType\\\u0022 Key=\\\u0022Primary\\\u0022 /\u003E\u003CFieldRef ID=\\\u0022{1D22EA11-1E32-424e-89AB-9FEDBADB6CE1}\\\u0022 Name=\\\u0022ID\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CIfEqual\u003E\u003CExpr1\u003E\u003CField Name=\\\u0022FSObjType\\\u0022 /\u003E\u003C/Expr1\u003E\u003CExpr2\u003E0\u003C/Expr2\u003E\u003CThen\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cinput ID=\\\u0022chkRepair\\\u0022 TYPE=\\\u0022CHECKBOX\\\u0022 Title=\\\u0022Relink\\\u0022 docID=\\\u0022]]\u003E\u003C/HTML\u003E\u003CField Name=\\\u0022ID\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003C/Then\u003E\u003C/IfEqual\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{11851948-B05E-41be-9D9F-BC3BF55D1DE3}\\\u0022 Name=\\\u0022ShowRepairView\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ShowRepairView\\\u0022 Type=\\\u0022Text\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Show Repair View\\\u0022 Filterable=\\\u0022TRUE\\\u0022 Sortable=\\\u0022TRUE\\\u0022 Hidden=\\\u0022TRUE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{4B1BF6C6-4F39-45ac-ACD5-16FE7A214E5E}\\\u0022 Name=\\\u0022TemplateUrl\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022TemplateUrl\\\u0022 Type=\\\u0022Text\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Template Link\\\u0022 XName=\\\u0022TemplateUrl\\\u0022 Filterable=\\\u0022TRUE\\\u0022 Sortable=\\\u0022TRUE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Hidden=\\\u0022TRUE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 PITarget=\\\u0022mso-infoPathSolution\\\u0022 PIAttribute=\\\u0022href\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{CD1ECB9F-DD4E-4f29-AB9E-E9FF40048D64}\\\u0022 Type=\\\u0022Text\\\u0022 Group=\\\u0022_Hidden\\\u0022 Name=\\\u0022xd_ProgID\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022xd_ProgID\\\u0022 DisplayName=\\\u0022HTML File Link\\\u0022 XName=\\\u0022ProgID\\\u0022 Filterable=\\\u0022TRUE\\\u0022 Sortable=\\\u0022TRUE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Hidden=\\\u0022TRUE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 PITarget=\\\u0022mso-application\\\u0022 PIAttribute=\\\u0022progid\\\u0022 PrimaryPITarget=\\\u0022mso-application\\\u0022 PrimaryPIAttribute=\\\u0022versionProgid\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u003C/Fields\u003E\u003CXmlDocuments\u003E\u003CXmlDocument NamespaceURI=\\\u0022http://schemas.microsoft.com/sharepoint/v3/contenttype/forms\\\u0022\u003E\u003CFormTemplates xmlns=\\\u0022http://schemas.microsoft.com/sharepoint/v3/contenttype/forms\\\u0022\u003E\u003CDisplay\u003EDocumentLibraryForm\u003C/Display\u003E\u003CEdit\u003EDocumentLibraryForm\u003C/Edit\u003E\u003CNew\u003EDocumentLibraryForm\u003C/New\u003E\u003C/FormTemplates\u003E\u003C/XmlDocument\u003E\u003C/XmlDocuments\u003E\u003C/ContentType\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022StringId\u0022:\u00220x010101\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00011.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00011.response.json new file mode 100644 index 0000000000..d4b724f92b --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00011.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-7083-4000-4c6b-a75191cedfeb","SPClientServiceRequestDuration":"309","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"[\r{\r\u0022SchemaVersion\u0022:\u002215.0.0.0\u0022,\u0022LibraryVersion\u0022:\u002216.0.22511.12008\u0022,\u0022ErrorInfo\u0022:null,\u0022TraceCorrelationId\u0022:\u0022bbdc42a0-7083-4000-4c6b-a75191cedfeb\u0022\r},5,{\r\u0022IsNull\u0022:false\r},6,{\r\u0022_ObjectIdentity_\u0022:\u0022bbdc42a0-7083-4000-4c6b-a75191cedfeb|740c6a0b-85e2-48a0-a494-e0f1759d4aa7:site:0f9b8f4f-0e8e-4630-bb0a-501442db9b64:web:ceb5fd80-a434-4a62-a60b-b272f10ba1df:contenttype:0x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022\r}\r]"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00012.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00012.response.json new file mode 100644 index 0000000000..65f41ff4f9 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00012.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"f26ddf0d-7e38-410f-8229-66855fbc7457","client-request-id":"f26ddf0d-7e38-410f-8229-66855fbc7457","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:45 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(documentSet,documentSet/sharedColumns(),documentSet/welcomePageColumns())/$entity\u0022,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:true,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document set name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022sharedColumns\u0022:[],\u0022welcomePageColumns\u0022:[]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00013.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00013.response.json new file mode 100644 index 0000000000..9cd9da8d61 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00013.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-50a7-4000-4c6b-a8bf64e1de33","SPClientServiceRequestDuration":"21","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00014.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00014.response.json new file mode 100644 index 0000000000..d39475f263 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00014.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-30ab-4000-4767-d8963be60543","SPClientServiceRequestDuration":"32","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022Fields\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ContentType\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022c042a256-787d-4a6f-8a8a-cf6ab767f12d\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ContentType\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:null,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ContentType\u0022,\u0022Title\u0022:\u0022Content Type\u0022,\u0022FieldTypeKind\u0022:12,\u0022TypeAsString\u0022:\u0022Computed\u0022,\u0022TypeDisplayName\u0022:\u0022Computed\u0022,\u0022TypeShortDescription\u0022:\u0022Computed\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022EnableLookup\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ItemChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022b824e17e-a1b3-426e-aecf-f0184d900485\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ItemChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{b824e17e-a1b3-426e-aecf-f0184d900485}\\\u0022 Name=\\\u0022ItemChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ItemChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Item Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022ItemChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ItemChildCount\u0022,\u0022Title\u0022:\u0022Item Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022ItemChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FolderChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022960ff01f-2b6d-4f1b-9c3f-e19ad8927341\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FolderChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{960ff01f-2b6d-4f1b-9c3f-e19ad8927341}\\\u0022 Name=\\\u0022FolderChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FolderChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Folder Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022FolderChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022FolderChildCount\u0022,\u0022Title\u0022:\u0022Folder Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022FolderChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Title\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:true,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:true,\u0022Id\u0022:\u0022fa564e0f-0c70-4ab9-b863-0177e6ddd247\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Title\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\\\u0022 Name=\\\u0022Title\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Title\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Title\\\u0022 Required=\\\u0022FALSE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Title\u0022,\u0022Title\u0022:\u0022Title\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FileLeafRef\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00228553196d-ec8d-4564-9861-3dbe931050c8\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FileLeafRef\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:true,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022FileLeafRef\u0022,\u0022Title\u0022:\u0022Name\u0022,\u0022FieldTypeKind\u0022:18,\u0022TypeAsString\u0022:\u0022File\u0022,\u0022TypeDisplayName\u0022:\u0022File\u0022,\u0022TypeShortDescription\u0022:\u0022File\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022A description of the Document Set\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022DocumentSetDescription\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022cbb92da4-fd46-4c7d-af6c-3128c2a5576e\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022DocumentSetDescription\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{CBB92DA4-FD46-4C7D-AF6C-3128C2A5576E}\\\u0022 Indexed=\\\u0022FALSE\\\u0022 Name=\\\u0022DocumentSetDescription\\\u0022 StaticName=\\\u0022DocumentSetDescription\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Description\\\u0022 Description=\\\u0022A description of the Document Set\\\u0022 Type=\\\u0022Note\\\u0022 NumLines=\\\u00225\\\u0022 UnlimitedLengthInDocumentLibrary=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Required=\\\u0022FALSE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 ShowInNewForm=\\\u0022TRUE\\\u0022 ShowInEditForm=\\\u0022TRUE\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022DocumentSetDescription\u0022,\u0022Title\u0022:\u0022Description\u0022,\u0022FieldTypeKind\u0022:3,\u0022TypeAsString\u0022:\u0022Note\u0022,\u0022TypeDisplayName\u0022:\u0022Multiple lines of text\u0022,\u0022TypeShortDescription\u0022:\u0022Multiple lines of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowHyperlink\u0022:false,\u0022AppendOnly\u0022:false,\u0022IsLongHyperlink\u0022:false,\u0022NumberOfLines\u0022:5,\u0022RestrictedMode\u0022:true,\u0022RichText\u0022:false,\u0022UnlimitedLengthInDocumentLibrary\u0022:true,\u0022WikiLinking\u0022:false}],\u0022StringId\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00015.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00015.response.json new file mode 100644 index 0000000000..7e46f13783 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00015.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00220\u0022","Location":"https://graph.microsoft.com/","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"d2d99251-0503-4b34-ba5c-7652c6fd89cd","client-request-id":"d2d99251-0503-4b34-ba5c-7652c6fd89cd","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:45 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(\u00270x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0027)/columns/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Manager\u0027s Name\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022ManagersName\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022text\u0022:{\u0022allowMultipleLines\u0022:false,\u0022appendChangesToExistingText\u0022:false,\u0022linesForEditing\u0022:0,\u0022maxLength\u0022:255},\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00016.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00016.response.json new file mode 100644 index 0000000000..c00654704e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00016.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-70bc-4000-4c6b-a35c8343c088","SPClientServiceRequestDuration":"26","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00017.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00017.response.json new file mode 100644 index 0000000000..f668b04f72 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00017.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-b0c1-4000-4c6b-a95cff2563c5","SPClientServiceRequestDuration":"30","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022Fields\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ContentType\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022c042a256-787d-4a6f-8a8a-cf6ab767f12d\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ContentType\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:null,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ContentType\u0022,\u0022Title\u0022:\u0022Content Type\u0022,\u0022FieldTypeKind\u0022:12,\u0022TypeAsString\u0022:\u0022Computed\u0022,\u0022TypeDisplayName\u0022:\u0022Computed\u0022,\u0022TypeShortDescription\u0022:\u0022Computed\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022EnableLookup\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ItemChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022b824e17e-a1b3-426e-aecf-f0184d900485\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ItemChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{b824e17e-a1b3-426e-aecf-f0184d900485}\\\u0022 Name=\\\u0022ItemChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ItemChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Item Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022ItemChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ItemChildCount\u0022,\u0022Title\u0022:\u0022Item Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022ItemChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FolderChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022960ff01f-2b6d-4f1b-9c3f-e19ad8927341\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FolderChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{960ff01f-2b6d-4f1b-9c3f-e19ad8927341}\\\u0022 Name=\\\u0022FolderChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FolderChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Folder Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022FolderChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022FolderChildCount\u0022,\u0022Title\u0022:\u0022Folder Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022FolderChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Title\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:true,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:true,\u0022Id\u0022:\u0022fa564e0f-0c70-4ab9-b863-0177e6ddd247\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Title\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\\\u0022 Name=\\\u0022Title\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Title\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Title\\\u0022 Required=\\\u0022FALSE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Title\u0022,\u0022Title\u0022:\u0022Title\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FileLeafRef\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00228553196d-ec8d-4564-9861-3dbe931050c8\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FileLeafRef\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:true,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022FileLeafRef\u0022,\u0022Title\u0022:\u0022Name\u0022,\u0022FieldTypeKind\u0022:18,\u0022TypeAsString\u0022:\u0022File\u0022,\u0022TypeDisplayName\u0022:\u0022File\u0022,\u0022TypeShortDescription\u0022:\u0022File\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022A description of the Document Set\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022DocumentSetDescription\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022cbb92da4-fd46-4c7d-af6c-3128c2a5576e\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022DocumentSetDescription\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{CBB92DA4-FD46-4C7D-AF6C-3128C2A5576E}\\\u0022 Indexed=\\\u0022FALSE\\\u0022 Name=\\\u0022DocumentSetDescription\\\u0022 StaticName=\\\u0022DocumentSetDescription\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Description\\\u0022 Description=\\\u0022A description of the Document Set\\\u0022 Type=\\\u0022Note\\\u0022 NumLines=\\\u00225\\\u0022 UnlimitedLengthInDocumentLibrary=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Required=\\\u0022FALSE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 ShowInNewForm=\\\u0022TRUE\\\u0022 ShowInEditForm=\\\u0022TRUE\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022DocumentSetDescription\u0022,\u0022Title\u0022:\u0022Description\u0022,\u0022FieldTypeKind\u0022:3,\u0022TypeAsString\u0022:\u0022Note\u0022,\u0022TypeDisplayName\u0022:\u0022Multiple lines of text\u0022,\u0022TypeShortDescription\u0022:\u0022Multiple lines of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowHyperlink\u0022:false,\u0022AppendOnly\u0022:false,\u0022IsLongHyperlink\u0022:false,\u0022NumberOfLines\u0022:5,\u0022RestrictedMode\u0022:true,\u0022RichText\u0022:false,\u0022UnlimitedLengthInDocumentLibrary\u0022:true,\u0022WikiLinking\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ManagersName\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ManagersName\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{BA934502-D68D-4960-A54B-51E15FEF5FD3}\\\u0022 Name=\\\u0022ManagersName\\\u0022 StaticName=\\\u0022ManagersName\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Manager\u0026#39;s Name\\\u0022 Group=\\\u0022Core Contact and Calendar Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022ManagersName\u0022,\u0022Title\u0022:\u0022Manager\u0027s Name\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}],\u0022StringId\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00018.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00018.response.json new file mode 100644 index 0000000000..b103b60822 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00018.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00220\u0022","Location":"https://graph.microsoft.com/","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"f576379d-c3a0-485d-92d3-4d78cacf8875","client-request-id":"f576379d-c3a0-485d-92d3-4d78cacf8875","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:46 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(\u00270x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0027)/columns/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022text\u0022:{\u0022allowMultipleLines\u0022:false,\u0022appendChangesToExistingText\u0022:false,\u0022linesForEditing\u0022:0,\u0022maxLength\u0022:255},\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00019.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00019.response.json new file mode 100644 index 0000000000..80f04c4dc0 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00019.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-00dd-4000-4767-d6c6a6b8e9f1","SPClientServiceRequestDuration":"73","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ManagersName\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ManagersName\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{BA934502-D68D-4960-A54B-51E15FEF5FD3}\\\u0022 Name=\\\u0022ManagersName\\\u0022 StaticName=\\\u0022ManagersName\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Manager\u0026#39;s Name\\\u0022 Group=\\\u0022Core Contact and Calendar Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022ManagersName\u0022,\u0022Title\u0022:\u0022Manager\u0027s Name\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00020.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00020.response.json new file mode 100644 index 0000000000..b4c34a4f6e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00020.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-60e7-4000-4c6b-a016ef357b4c","SPClientServiceRequestDuration":"30","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Categories\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Base Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Categories\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{9EBCD900-9D05-46c8-8F4D-E46E87328844}\\\u0022 Name=\\\u0022Categories\\\u0022 StaticName=\\\u0022Categories\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Categories\\\u0022 Group=\\\u0022Base Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Categories\u0022,\u0022Title\u0022:\u0022Categories\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00021.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00021.response.json new file mode 100644 index 0000000000..ec25d6dcad --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00021.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-a0ee-4000-4c6b-a88f14320075","SPClientServiceRequestDuration":"44","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022ListItemAllFields\u0022:{\u0022FileSystemObjectType\u0022:0,\u0022Id\u0022:650,\u0022ServerRedirectedEmbedUri\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_layouts/15/Doc.aspx?sourcedoc={ad260c10-2802-46d1-b023-ef4ff5eb84eb}\u0026action=interactivepreview\u0022,\u0022ServerRedirectedEmbedUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_layouts/15/Doc.aspx?sourcedoc={ad260c10-2802-46d1-b023-ef4ff5eb84eb}\u0026action=interactivepreview\u0022,\u0022ContentTypeId\u0022:\u00220x01010085F20CEF42E3A14F8BD3E307F88FEEDE\u0022,\u0022Modified\u0022:\u00222022-05-31T12:36:45\u0022,\u0022ComplianceAssetId\u0022:null,\u0022Title\u0022:null,\u0022SharedWithUsersId\u0022:null,\u0022SharedWithDetails\u0022:null,\u0022ID\u0022:650,\u0022Created\u0022:\u00222022-05-31T12:36:45\u0022,\u0022AuthorId\u0022:9,\u0022EditorId\u0022:9,\u0022OData__CopySource\u0022:null,\u0022CheckoutUserId\u0022:null,\u0022OData__UIVersionString\u0022:\u00221.0\u0022,\u0022GUID\u0022:\u002275f2d953-55a4-4e97-aea1-4424f14b9901\u0022},\u0022ListId\u0022:\u002268e9c7c6-94e1-4422-9eef-ca5a274ee7c6\u0022,\u0022UniqueId\u0022:\u0022ad260c10-2802-46d1-b023-ef4ff5eb84eb\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00022.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00022.response.json new file mode 100644 index 0000000000..991476af08 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00022.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":204,"Headers":{"Cache-Control":"no-store, no-cache","Strict-Transport-Security":"max-age=31536000","request-id":"badb6acc-d716-4388-af64-f0d91dec3e13","client-request-id":"badb6acc-d716-4388-af64-f0d91dec3e13","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","Date":"Tue, 31 May 2022 19:36:46 GMT"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00023.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00023.response.json new file mode 100644 index 0000000000..cff4fc9f3e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00023.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00224\u0022","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"df3e76ee-6715-4417-83de-a682f45e3aae","client-request-id":"df3e76ee-6715-4417-83de-a682f45e3aae","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:47 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00224\\\u0022\u0022,\u0022id\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022,\u0022isBuiltIn\u0022:false,\u0022description\u0022:\u0022TESTING\u0022,\u0022group\u0022:\u0022TESTING\u0022,\u0022hidden\u0022:false,\u0022name\u0022:\u0022Document set name\u0022,\u0022parentId\u0022:\u00220x0120D520\u0022,\u0022readOnly\u0022:false,\u0022sealed\u0022:false,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:true,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document set name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022},{\u0022id\u0022:\u00220x010101\u0022,\u0022name\u0022:\u0022Form\u0022}],\u0022defaultContents\u0022:[{\u0022fileName\u0022:\u0022Test.docx\u0022,\u0022folderName\u0022:\u0022FolderName/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}}]},\u0022base\u0022:{\u0022id\u0022:\u00220x0120D520\u0022,\u0022description\u0022:\u0022Create a document set when you want to manage multiple documents as a single work product.\u0022,\u0022group\u0022:\u0022Document Set Content Types\u0022,\u0022hidden\u0022:false,\u0022name\u0022:\u0022Document Set\u0022,\u0022readOnly\u0022:false,\u0022sealed\u0022:false}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00024.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00024.response.json new file mode 100644 index 0000000000..ad87ec2242 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00024.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"be69b95a-6a3a-4fa6-86cb-11c72c1304c4","client-request-id":"be69b95a-6a3a-4fa6-86cb-11c72c1304c4","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:47 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(documentSet,documentSet/sharedColumns(),documentSet/welcomePageColumns())/$entity\u0022,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:true,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document set name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022},{\u0022id\u0022:\u00220x010101\u0022,\u0022name\u0022:\u0022Form\u0022}],\u0022defaultContents\u0022:[{\u0022fileName\u0022:\u0022Test.docx\u0022,\u0022folderName\u0022:\u0022FolderName/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}}],\u0022sharedColumns\u0022:[{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}},{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Manager\u0027s Name\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022ManagersName\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}],\u0022welcomePageColumns\u0022:[{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Manager\u0027s Name\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022ManagersName\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}},{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00025.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00025.response.json new file mode 100644 index 0000000000..944ca38a0d --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00025.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bcdc42a0-4034-4000-4c6b-a51062a5e5f3","SPClientServiceRequestDuration":"80","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00026.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00026.response.json new file mode 100644 index 0000000000..052659ee84 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-0-00026.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bcdc42a0-b03d-4000-4767-da71cd5b0073","SPClientServiceRequestDuration":"67","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00000.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00000.response.json new file mode 100644 index 0000000000..ee3814ff63 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00000.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-b04f-4000-4c6b-a545b1cc28f6","SPClientServiceRequestDuration":"12","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022RegionalSettings\u0022:{\u0022TimeZone\u0022:{\u0022Description\u0022:\u0022(UTC-08:00) Pacific Time (US and Canada)\u0022,\u0022Id\u0022:13,\u0022Information\u0022:{\u0022Bias\u0022:480,\u0022DaylightBias\u0022:-60,\u0022StandardBias\u0022:0}},\u0022AdjustHijriDays\u0022:0,\u0022AlternateCalendarType\u0022:0,\u0022AM\u0022:\u0022AM\u0022,\u0022CalendarType\u0022:1,\u0022Collation\u0022:25,\u0022CollationLCID\u0022:2070,\u0022DateFormat\u0022:0,\u0022DateSeparator\u0022:\u0022/\u0022,\u0022DecimalSeparator\u0022:\u0022.\u0022,\u0022DigitGrouping\u0022:\u00223;0\u0022,\u0022FirstDayOfWeek\u0022:0,\u0022FirstWeekOfYear\u0022:0,\u0022IsEastAsia\u0022:false,\u0022IsRightToLeft\u0022:false,\u0022IsUIRightToLeft\u0022:false,\u0022ListSeparator\u0022:\u0022,\u0022,\u0022LocaleId\u0022:1033,\u0022NegativeSign\u0022:\u0022-\u0022,\u0022NegNumberMode\u0022:1,\u0022PM\u0022:\u0022PM\u0022,\u0022PositiveSign\u0022:\u0022\u0022,\u0022ShowWeeks\u0022:false,\u0022ThousandSeparator\u0022:\u0022,\u0022,\u0022Time24\u0022:false,\u0022TimeMarkerPosition\u0022:0,\u0022TimeSeparator\u0022:\u0022:\u0022,\u0022WorkDayEndHour\u0022:1020,\u0022WorkDays\u0022:62,\u0022WorkDayStartHour\u0022:480},\u0022Id\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022Url\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00001.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00001.response.json new file mode 100644 index 0000000000..6147849ea8 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSet-1-00001.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-5054-4000-4c6b-a18b0ee627d8","SPClientServiceRequestDuration":"10","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022GroupId\u0022:\u00220ad55b5d-6a79-467b-ad21-d4bef7948a79\u0022,\u0022Id\u0022:\u00220f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00000.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00000.response.json new file mode 100644 index 0000000000..93164b9b89 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00000.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bcdc42a0-2047-4000-4c6b-aa1c3a721719","SPClientServiceRequestDuration":"14","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022RegionalSettings\u0022:{\u0022TimeZone\u0022:{\u0022Description\u0022:\u0022(UTC-08:00) Pacific Time (US and Canada)\u0022,\u0022Id\u0022:13,\u0022Information\u0022:{\u0022Bias\u0022:480,\u0022DaylightBias\u0022:-60,\u0022StandardBias\u0022:0}},\u0022AdjustHijriDays\u0022:0,\u0022AlternateCalendarType\u0022:0,\u0022AM\u0022:\u0022AM\u0022,\u0022CalendarType\u0022:1,\u0022Collation\u0022:25,\u0022CollationLCID\u0022:2070,\u0022DateFormat\u0022:0,\u0022DateSeparator\u0022:\u0022/\u0022,\u0022DecimalSeparator\u0022:\u0022.\u0022,\u0022DigitGrouping\u0022:\u00223;0\u0022,\u0022FirstDayOfWeek\u0022:0,\u0022FirstWeekOfYear\u0022:0,\u0022IsEastAsia\u0022:false,\u0022IsRightToLeft\u0022:false,\u0022IsUIRightToLeft\u0022:false,\u0022ListSeparator\u0022:\u0022,\u0022,\u0022LocaleId\u0022:1033,\u0022NegativeSign\u0022:\u0022-\u0022,\u0022NegNumberMode\u0022:1,\u0022PM\u0022:\u0022PM\u0022,\u0022PositiveSign\u0022:\u0022\u0022,\u0022ShowWeeks\u0022:false,\u0022ThousandSeparator\u0022:\u0022,\u0022,\u0022Time24\u0022:false,\u0022TimeMarkerPosition\u0022:0,\u0022TimeSeparator\u0022:\u0022:\u0022,\u0022WorkDayEndHour\u0022:1020,\u0022WorkDays\u0022:62,\u0022WorkDayStartHour\u0022:480},\u0022Id\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022Url\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00001.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00001.response.json new file mode 100644 index 0000000000..dd039df542 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/AddContentTypeAsDocumentSetExceptionAsyncTest-0-00001.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bcdc42a0-604c-4000-4c6b-a62416977161","SPClientServiceRequestDuration":"12","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022GroupId\u0022:\u00220ad55b5d-6a79-467b-ad21-d4bef7948a79\u0022,\u0022Id\u0022:\u00220f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00000.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00000.response.json new file mode 100644 index 0000000000..5aaba9be7f --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00000.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-401c-4000-4c6b-ad4b9de200cd","SPClientServiceRequestDuration":"16","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022RegionalSettings\u0022:{\u0022TimeZone\u0022:{\u0022Description\u0022:\u0022(UTC-08:00) Pacific Time (US and Canada)\u0022,\u0022Id\u0022:13,\u0022Information\u0022:{\u0022Bias\u0022:480,\u0022DaylightBias\u0022:-60,\u0022StandardBias\u0022:0}},\u0022AdjustHijriDays\u0022:0,\u0022AlternateCalendarType\u0022:0,\u0022AM\u0022:\u0022AM\u0022,\u0022CalendarType\u0022:1,\u0022Collation\u0022:25,\u0022CollationLCID\u0022:2070,\u0022DateFormat\u0022:0,\u0022DateSeparator\u0022:\u0022/\u0022,\u0022DecimalSeparator\u0022:\u0022.\u0022,\u0022DigitGrouping\u0022:\u00223;0\u0022,\u0022FirstDayOfWeek\u0022:0,\u0022FirstWeekOfYear\u0022:0,\u0022IsEastAsia\u0022:false,\u0022IsRightToLeft\u0022:false,\u0022IsUIRightToLeft\u0022:false,\u0022ListSeparator\u0022:\u0022,\u0022,\u0022LocaleId\u0022:1033,\u0022NegativeSign\u0022:\u0022-\u0022,\u0022NegNumberMode\u0022:1,\u0022PM\u0022:\u0022PM\u0022,\u0022PositiveSign\u0022:\u0022\u0022,\u0022ShowWeeks\u0022:false,\u0022ThousandSeparator\u0022:\u0022,\u0022,\u0022Time24\u0022:false,\u0022TimeMarkerPosition\u0022:0,\u0022TimeSeparator\u0022:\u0022:\u0022,\u0022WorkDayEndHour\u0022:1020,\u0022WorkDays\u0022:62,\u0022WorkDayStartHour\u0022:480},\u0022Id\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022Url\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00001.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00001.response.json new file mode 100644 index 0000000000..45c8611f54 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00001.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-d020-4000-4c6b-a1b61e581163","SPClientServiceRequestDuration":"10","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022GroupId\u0022:\u00220ad55b5d-6a79-467b-ad21-d4bef7948a79\u0022,\u0022Id\u0022:\u00220f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00002.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00002.response.json new file mode 100644 index 0000000000..b5a5ebad98 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00002.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-7025-4000-4c6b-a9c5b945e1eb","SPClientServiceRequestDuration":"19","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022Id\u0022:{\u0022StringValue\u0022:\u00220x0120D520\u0022},\u0022StringId\u0022:\u00220x0120D520\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00003.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00003.response.json new file mode 100644 index 0000000000..e76d93e576 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSet-0-00003.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"7ad83fec-48b9-453e-8060-a5f3d1b2ea9e","client-request-id":"7ad83fec-48b9-453e-8060-a5f3d1b2ea9e","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:43 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(documentSet,documentSet/sharedColumns(),documentSet/welcomePageColumns())/$entity\u0022,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:true,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document Set/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022sharedColumns\u0022:[],\u0022welcomePageColumns\u0022:[]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00000.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00000.response.json new file mode 100644 index 0000000000..0eee7404be --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00000.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-600b-4000-4c6b-a684b5208028","SPClientServiceRequestDuration":"12","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022RegionalSettings\u0022:{\u0022TimeZone\u0022:{\u0022Description\u0022:\u0022(UTC-08:00) Pacific Time (US and Canada)\u0022,\u0022Id\u0022:13,\u0022Information\u0022:{\u0022Bias\u0022:480,\u0022DaylightBias\u0022:-60,\u0022StandardBias\u0022:0}},\u0022AdjustHijriDays\u0022:0,\u0022AlternateCalendarType\u0022:0,\u0022AM\u0022:\u0022AM\u0022,\u0022CalendarType\u0022:1,\u0022Collation\u0022:25,\u0022CollationLCID\u0022:2070,\u0022DateFormat\u0022:0,\u0022DateSeparator\u0022:\u0022/\u0022,\u0022DecimalSeparator\u0022:\u0022.\u0022,\u0022DigitGrouping\u0022:\u00223;0\u0022,\u0022FirstDayOfWeek\u0022:0,\u0022FirstWeekOfYear\u0022:0,\u0022IsEastAsia\u0022:false,\u0022IsRightToLeft\u0022:false,\u0022IsUIRightToLeft\u0022:false,\u0022ListSeparator\u0022:\u0022,\u0022,\u0022LocaleId\u0022:1033,\u0022NegativeSign\u0022:\u0022-\u0022,\u0022NegNumberMode\u0022:1,\u0022PM\u0022:\u0022PM\u0022,\u0022PositiveSign\u0022:\u0022\u0022,\u0022ShowWeeks\u0022:false,\u0022ThousandSeparator\u0022:\u0022,\u0022,\u0022Time24\u0022:false,\u0022TimeMarkerPosition\u0022:0,\u0022TimeSeparator\u0022:\u0022:\u0022,\u0022WorkDayEndHour\u0022:1020,\u0022WorkDays\u0022:62,\u0022WorkDayStartHour\u0022:480},\u0022Id\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022Url\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00001.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00001.response.json new file mode 100644 index 0000000000..0ac4271429 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00001.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-f00f-4000-4767-d278a51ee3a9","SPClientServiceRequestDuration":"56","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022GroupId\u0022:\u00220ad55b5d-6a79-467b-ad21-d4bef7948a79\u0022,\u0022Id\u0022:\u00220f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00002.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00002.response.json new file mode 100644 index 0000000000..4c094dc166 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/GetContentTypeAsDocumentSetExceptionTest-0-00002.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-d016-4000-4c6b-afd911eaa4b3","SPClientServiceRequestDuration":"20","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022Id\u0022:{\u0022StringValue\u0022:\u00220x0101\u0022},\u0022StringId\u0022:\u00220x0101\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00000.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00000.response.json new file mode 100644 index 0000000000..e15c189e8e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00000.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-60ca-4000-4c6b-a22902880f3a","SPClientServiceRequestDuration":"12","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022RegionalSettings\u0022:{\u0022TimeZone\u0022:{\u0022Description\u0022:\u0022(UTC-08:00) Pacific Time (US and Canada)\u0022,\u0022Id\u0022:13,\u0022Information\u0022:{\u0022Bias\u0022:480,\u0022DaylightBias\u0022:-60,\u0022StandardBias\u0022:0}},\u0022AdjustHijriDays\u0022:0,\u0022AlternateCalendarType\u0022:0,\u0022AM\u0022:\u0022AM\u0022,\u0022CalendarType\u0022:1,\u0022Collation\u0022:25,\u0022CollationLCID\u0022:2070,\u0022DateFormat\u0022:0,\u0022DateSeparator\u0022:\u0022/\u0022,\u0022DecimalSeparator\u0022:\u0022.\u0022,\u0022DigitGrouping\u0022:\u00223;0\u0022,\u0022FirstDayOfWeek\u0022:0,\u0022FirstWeekOfYear\u0022:0,\u0022IsEastAsia\u0022:false,\u0022IsRightToLeft\u0022:false,\u0022IsUIRightToLeft\u0022:false,\u0022ListSeparator\u0022:\u0022,\u0022,\u0022LocaleId\u0022:1033,\u0022NegativeSign\u0022:\u0022-\u0022,\u0022NegNumberMode\u0022:1,\u0022PM\u0022:\u0022PM\u0022,\u0022PositiveSign\u0022:\u0022\u0022,\u0022ShowWeeks\u0022:false,\u0022ThousandSeparator\u0022:\u0022,\u0022,\u0022Time24\u0022:false,\u0022TimeMarkerPosition\u0022:0,\u0022TimeSeparator\u0022:\u0022:\u0022,\u0022WorkDayEndHour\u0022:1020,\u0022WorkDays\u0022:62,\u0022WorkDayStartHour\u0022:480},\u0022Id\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022Url\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00001.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00001.response.json new file mode 100644 index 0000000000..3ac607d6e9 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00001.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-f0ce-4000-4c6b-a616819618b8","SPClientServiceRequestDuration":"11","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022GroupId\u0022:\u00220ad55b5d-6a79-467b-ad21-d4bef7948a79\u0022,\u0022Id\u0022:\u00220f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00002.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00002.response.json new file mode 100644 index 0000000000..0012b95310 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00002.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-90b4-4000-4c6b-a509ca724bff","SPClientServiceRequestDuration":"33","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AllowContentTypes\u0022:true,\u0022BaseTemplate\u0022:101,\u0022BaseType\u0022:1,\u0022ContentTypesEnabled\u0022:false,\u0022CrawlNonDefaultViews\u0022:false,\u0022Created\u0022:\u00222022-03-06T01:58:24Z\u0022,\u0022CurrentChangeToken\u0022:{\u0022StringValue\u0022:\u00221;3;68e9c7c6-94e1-4422-9eef-ca5a274ee7c6;637896225984600000;496856739\u0022},\u0022DefaultContentApprovalWorkflowId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022DefaultItemOpenUseListSetting\u0022:false,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022DisableCommenting\u0022:false,\u0022DisableGridEditing\u0022:false,\u0022DocumentTemplateUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/Forms/template.dotx\u0022,\u0022DraftVersionVisibility\u0022:0,\u0022EnableAttachments\u0022:false,\u0022EnableFolderCreation\u0022:true,\u0022EnableMinorVersions\u0022:false,\u0022EnableModeration\u0022:false,\u0022EnableRequestSignOff\u0022:true,\u0022EnableVersioning\u0022:true,\u0022EntityTypeName\u0022:\u0022Shared_x0020_Documents\u0022,\u0022ExemptFromBlockDownloadOfNonViewableFiles\u0022:false,\u0022FileSavePostProcessingEnabled\u0022:false,\u0022ForceCheckout\u0022:false,\u0022HasExternalDataSource\u0022:false,\u0022Hidden\u0022:false,\u0022Id\u0022:\u002268e9c7c6-94e1-4422-9eef-ca5a274ee7c6\u0022,\u0022ImagePath\u0022:{\u0022DecodedUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022},\u0022ImageUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022,\u0022DefaultSensitivityLabelForLibrary\u0022:\u0022\u0022,\u0022IrmEnabled\u0022:false,\u0022IrmExpire\u0022:false,\u0022IrmReject\u0022:false,\u0022IsApplicationList\u0022:false,\u0022IsCatalog\u0022:false,\u0022IsPrivate\u0022:false,\u0022ItemCount\u0022:4,\u0022LastItemDeletedDate\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022LastItemModifiedDate\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022LastItemUserModifiedDate\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022ListExperienceOptions\u0022:1,\u0022ListItemEntityTypeFullName\u0022:\u0022SP.Data.Shared_x0020_DocumentsItem\u0022,\u0022MajorVersionLimit\u0022:500,\u0022MajorWithMinorVersionsLimit\u0022:0,\u0022MultipleDataList\u0022:false,\u0022NoCrawl\u0022:false,\u0022ParentWebPath\u0022:{\u0022DecodedUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022},\u0022ParentWebUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022ParserDisabled\u0022:false,\u0022ServerTemplateCanCreateFolders\u0022:true,\u0022TemplateFeatureId\u0022:\u002200bfea71-e717-4e80-aa17-d0c71b360101\u0022,\u0022Title\u0022:\u0022Documents\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00003.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00003.response.json new file mode 100644 index 0000000000..0d941bd9f2 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00003.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-10bd-4000-4767-d88e454ab420","SPClientServiceRequestDuration":"39","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022AllowContentTypes\u0022:true,\u0022BaseTemplate\u0022:101,\u0022BaseType\u0022:1,\u0022ContentTypesEnabled\u0022:false,\u0022CrawlNonDefaultViews\u0022:false,\u0022Created\u0022:\u00222022-03-06T01:58:24Z\u0022,\u0022CurrentChangeToken\u0022:{\u0022StringValue\u0022:\u00221;3;68e9c7c6-94e1-4422-9eef-ca5a274ee7c6;637896225984600000;496856739\u0022},\u0022DefaultContentApprovalWorkflowId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022DefaultItemOpenUseListSetting\u0022:false,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022DisableCommenting\u0022:false,\u0022DisableGridEditing\u0022:false,\u0022DocumentTemplateUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/Forms/template.dotx\u0022,\u0022DraftVersionVisibility\u0022:0,\u0022EnableAttachments\u0022:false,\u0022EnableFolderCreation\u0022:true,\u0022EnableMinorVersions\u0022:false,\u0022EnableModeration\u0022:false,\u0022EnableRequestSignOff\u0022:true,\u0022EnableVersioning\u0022:true,\u0022EntityTypeName\u0022:\u0022Shared_x0020_Documents\u0022,\u0022ExemptFromBlockDownloadOfNonViewableFiles\u0022:false,\u0022FileSavePostProcessingEnabled\u0022:false,\u0022ForceCheckout\u0022:false,\u0022HasExternalDataSource\u0022:false,\u0022Hidden\u0022:false,\u0022Id\u0022:\u002268e9c7c6-94e1-4422-9eef-ca5a274ee7c6\u0022,\u0022ImagePath\u0022:{\u0022DecodedUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022},\u0022ImageUrl\u0022:\u0022/_layouts/15/images/itdl.png?rev=47\u0022,\u0022DefaultSensitivityLabelForLibrary\u0022:\u0022\u0022,\u0022IrmEnabled\u0022:false,\u0022IrmExpire\u0022:false,\u0022IrmReject\u0022:false,\u0022IsApplicationList\u0022:false,\u0022IsCatalog\u0022:false,\u0022IsPrivate\u0022:false,\u0022ItemCount\u0022:4,\u0022LastItemDeletedDate\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022LastItemModifiedDate\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022LastItemUserModifiedDate\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022ListExperienceOptions\u0022:1,\u0022ListItemEntityTypeFullName\u0022:\u0022SP.Data.Shared_x0020_DocumentsItem\u0022,\u0022MajorVersionLimit\u0022:500,\u0022MajorWithMinorVersionsLimit\u0022:0,\u0022MultipleDataList\u0022:false,\u0022NoCrawl\u0022:false,\u0022ParentWebPath\u0022:{\u0022DecodedUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022},\u0022ParentWebUrl\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022ParserDisabled\u0022:false,\u0022ServerTemplateCanCreateFolders\u0022:true,\u0022TemplateFeatureId\u0022:\u002200bfea71-e717-4e80-aa17-d0c71b360101\u0022,\u0022Title\u0022:\u0022Documents\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00004.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00004.response.json new file mode 100644 index 0000000000..6a8659db15 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00004.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-f0c4-4000-4c6b-a560422b8d11","SPClientServiceRequestDuration":"18","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022Exists\u0022:true,\u0022IsWOPIEnabled\u0022:false,\u0022ItemCount\u0022:4,\u0022Name\u0022:\u0022Shared Documents\u0022,\u0022ProgID\u0022:null,\u0022ServerRelativeUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents\u0022,\u0022TimeCreated\u0022:\u00222022-03-06T01:58:24Z\u0022,\u0022TimeLastModified\u0022:\u00222022-05-31T19:34:47Z\u0022,\u0022UniqueId\u0022:\u00222a0ba280-7c53-4eb9-a460-2c31576f90a8\u0022,\u0022WelcomePage\u0022:\u0022\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00005.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00005.response.json new file mode 100644 index 0000000000..799774593d --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00005.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-80d4-4000-4767-d36ab6ea7b2e","SPClientServiceRequestDuration":"206","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022CheckInComment\u0022:\u0022\u0022,\u0022CheckOutType\u0022:2,\u0022ContentTag\u0022:\u0022{3FC0AE3F-B207-4770-B3A6-502DE8B981DC},1,2\u0022,\u0022CustomizedPageStatus\u0022:0,\u0022ETag\u0022:\u0022\\\u0022{3FC0AE3F-B207-4770-B3A6-502DE8B981DC},1\\\u0022\u0022,\u0022Exists\u0022:true,\u0022IrmEnabled\u0022:false,\u0022Length\u0022:\u002218339\u0022,\u0022Level\u0022:1,\u0022LinkingUri\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared%20Documents/PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx?d=w3fc0ae3fb2074770b3a6502de8b981dc\u0022,\u0022LinkingUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx?d=w3fc0ae3fb2074770b3a6502de8b981dc\u0022,\u0022MajorVersion\u0022:1,\u0022MinorVersion\u0022:0,\u0022Name\u0022:\u0022PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx\u0022,\u0022ServerRelativeUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx\u0022,\u0022TimeCreated\u0022:\u00222022-05-31T19:36:39Z\u0022,\u0022TimeLastModified\u0022:\u00222022-05-31T19:36:39Z\u0022,\u0022Title\u0022:\u0022\u0022,\u0022UIVersion\u0022:512,\u0022UIVersionLabel\u0022:\u00221.0\u0022,\u0022UniqueId\u0022:\u00223fc0ae3f-b207-4770-b3a6-502de8b981dc\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00006.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00006.response.json new file mode 100644 index 0000000000..7c7106e831 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00006.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-20e6-4000-4c6b-a28a271475bf","SPClientServiceRequestDuration":"33","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Categories\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Base Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Categories\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{9EBCD900-9D05-46c8-8F4D-E46E87328844}\\\u0022 Name=\\\u0022Categories\\\u0022 StaticName=\\\u0022Categories\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Categories\\\u0022 Group=\\\u0022Base Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Categories\u0022,\u0022Title\u0022:\u0022Categories\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00007.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00007.response.json new file mode 100644 index 0000000000..3b394d55e1 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00007.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-80ee-4000-4c6b-a022f0967bce","SPClientServiceRequestDuration":"39","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ManagersName\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ManagersName\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{BA934502-D68D-4960-A54B-51E15FEF5FD3}\\\u0022 Name=\\\u0022ManagersName\\\u0022 StaticName=\\\u0022ManagersName\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Manager\u0026#39;s Name\\\u0022 Group=\\\u0022Core Contact and Calendar Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022ManagersName\u0022,\u0022Title\u0022:\u0022Manager\u0027s Name\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00008.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00008.response.json new file mode 100644 index 0000000000..30e1120266 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00008.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-00f6-4000-4c6b-aaf5f1ff8438","SPClientServiceRequestDuration":"23","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022ClientFormCustomFormatter\u0022:\u0022\u0022,\u0022Description\u0022:\u0022Create a new document.\u0022,\u0022DisplayFormClientSideComponentId\u0022:null,\u0022DisplayFormClientSideComponentProperties\u0022:null,\u0022DisplayFormTarget\u0022:0,\u0022DisplayFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022DisplayFormUrl\u0022:\u0022\u0022,\u0022DocumentTemplate\u0022:\u0022\u0022,\u0022DocumentTemplateUrl\u0022:\u0022\u0022,\u0022EditFormClientSideComponentId\u0022:null,\u0022EditFormClientSideComponentProperties\u0022:null,\u0022EditFormTarget\u0022:0,\u0022EditFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022EditFormUrl\u0022:\u0022\u0022,\u0022Group\u0022:\u0022Document Content Types\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:{\u0022StringValue\u0022:\u00220x0101\u0022},\u0022JSLink\u0022:\u0022\u0022,\u0022MobileDisplayFormUrl\u0022:\u0022\u0022,\u0022MobileEditFormUrl\u0022:\u0022\u0022,\u0022MobileNewFormUrl\u0022:\u0022\u0022,\u0022Name\u0022:\u0022Document\u0022,\u0022NewFormClientSideComponentId\u0022:null,\u0022NewFormClientSideComponentProperties\u0022:null,\u0022NewFormTarget\u0022:0,\u0022NewFormTemplateName\u0022:\u0022DocumentLibraryForm\u0022,\u0022NewFormUrl\u0022:\u0022\u0022,\u0022ReadOnly\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CContentType ID=\\\u00220x0101\\\u0022 Name=\\\u0022Document\\\u0022 Group=\\\u0022Document Content Types\\\u0022 Description=\\\u0022Create a new document.\\\u0022 Version=\\\u00220\\\u0022 FeatureId=\\\u0022{695b6570-a48b-4a8e-8ea5-26ea7fc1d162}\\\u0022\u003E\u003CFolder TargetName=\\\u0022_cts/Document\\\u0022 /\u003E\u003CFields\u003E\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{5f47e085-2150-41dc-b661-442f3027f552}\\\u0022 Name=\\\u0022SelectFilename\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022SelectFilename\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Select\\\u0022 Hidden=\\\u0022TRUE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 AuthoringInfo=\\\u0022(web part connection)\\\u0022 HeaderImage=\\\u0022blank.gif\\\u0022 Sortable=\\\u0022FALSE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{1d22ea11-1e32-424e-89ab-9fedbadb6ce1}\\\u0022 Name=\\\u0022ID\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CIfEqual\u003E\u003CExpr1\u003E\u003CGetVar Name=\\\u0022SelectedID\\\u0022 /\u003E\u003C/Expr1\u003E\u003CExpr2\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/Expr2\u003E\u003CThen\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cimg align=\\\u0022absmiddle\\\u0022 style=\\\u0022cursor: hand\\\u0022 src=\\\u0022/_layouts/15/images/rbsel.gif?rev=47\\\u0022 alt=\\\u0022]]\u003E\u003C/HTML\u003E\u003CHTML\u003ESelected\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003C/Then\u003E\u003CElse\u003E\u003CHTML\u003E\u003C![CDATA[\u003Ca href=\\\u0022javascript:SelectField(\u0027]]\u003E\u003C/HTML\u003E\u003CGetVar Name=\\\u0022View\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\u0027,\u0027]]\u003E\u003C/HTML\u003E\u003CScriptQuote NotAddingQuote=\\\u0022TRUE\\\u0022\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/ScriptQuote\u003E\u003CHTML\u003E\u003C![CDATA[\u0027);return false;\\\u0022 onclick=\\\u0022javascript:SelectField(\u0027]]\u003E\u003C/HTML\u003E\u003CGetVar Name=\\\u0022View\\\u0022 /\u003E\u003CHTML\u003E\u003C![CDATA[\u0027,\u0027]]\u003E\u003C/HTML\u003E\u003CScriptQuote NotAddingQuote=\\\u0022TRUE\\\u0022\u003E\u003CColumn Name=\\\u0022ID\\\u0022 /\u003E\u003C/ScriptQuote\u003E\u003CHTML\u003E\u003C![CDATA[\u0027);return false;\\\u0022 target=\\\u0022_self\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\u003Cimg border=\\\u00220\\\u0022 align=\\\u0022absmiddle\\\u0022 style=\\\u0022cursor: hand\\\u0022 src=\\\u0022/_layouts/15/images/rbunsel.gif?rev=47\\\u0022 alt=\\\u0022]]\u003E\u003C/HTML\u003E\u003CHTML\u003ENormal\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\\\u0022\u003E]]\u003E\u003C/HTML\u003E\u003CHTML\u003E\u003C![CDATA[\u003C/a\u003E]]\u003E\u003C/HTML\u003E\u003C/Else\u003E\u003C/IfEqual\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{8c06beca-0777-48f7-91c7-6da68bc07b69}\\\u0022 Name=\\\u0022Created\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Created\\\u0022 Group=\\\u0022_Hidden\\\u0022 ColName=\\\u0022tp_Created\\\u0022 RowOrdinal=\\\u00220\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022DateTime\\\u0022 DisplayName=\\\u0022Created\\\u0022 StorageTZ=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\\\u0022 Name=\\\u0022Title\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Title\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Title\\\u0022 Required=\\\u0022FALSE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 ShowInNewForm=\\\u0022FALSE\\\u0022 ShowInEditForm=\\\u0022TRUE\\\u0022 /\u003E\u003CField ID=\\\u0022{28cf69c5-fa48-462a-b5cd-27b6f9d2bd5f}\\\u0022 Name=\\\u0022Modified\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Modified\\\u0022 Group=\\\u0022_Hidden\\\u0022 ColName=\\\u0022tp_Modified\\\u0022 RowOrdinal=\\\u00220\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Type=\\\u0022DateTime\\\u0022 DisplayName=\\\u0022Modified\\\u0022 StorageTZ=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{822c78e3-1ea9-4943-b449-57863ad33ca9}\\\u0022 Name=\\\u0022Modified_x0020_By\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Modified_x0020_By\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Document Modified By\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u003CField ID=\\\u0022{4dd7e525-8d6b-4cb4-9d3e-44ee25f973eb}\\\u0022 Name=\\\u0022Created_x0020_By\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Created_x0020_By\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Document Created By\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u003C/Fields\u003E\u003CXmlDocuments\u003E\u003CXmlDocument NamespaceURI=\\\u0022http://schemas.microsoft.com/sharepoint/v3/contenttype/forms\\\u0022\u003E\u003CFormTemplates xmlns=\\\u0022http://schemas.microsoft.com/sharepoint/v3/contenttype/forms\\\u0022\u003E\u003CDisplay\u003EDocumentLibraryForm\u003C/Display\u003E\u003CEdit\u003EDocumentLibraryForm\u003C/Edit\u003E\u003CNew\u003EDocumentLibraryForm\u003C/New\u003E\u003C/FormTemplates\u003E\u003C/XmlDocument\u003E\u003C/XmlDocuments\u003E\u003C/ContentType\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022StringId\u0022:\u00220x0101\u0022}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00009.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00009.response.json new file mode 100644 index 0000000000..39a98bdfa6 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00009.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"b9dc42a0-90fb-4000-4767-d2c9c227d41a","SPClientServiceRequestDuration":"16","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022CheckInComment\u0022:\u0022\u0022,\u0022CheckOutType\u0022:2,\u0022ContentTag\u0022:\u0022{3FC0AE3F-B207-4770-B3A6-502DE8B981DC},1,2\u0022,\u0022CustomizedPageStatus\u0022:0,\u0022ETag\u0022:\u0022\\\u0022{3FC0AE3F-B207-4770-B3A6-502DE8B981DC},1\\\u0022\u0022,\u0022Exists\u0022:true,\u0022IrmEnabled\u0022:false,\u0022Length\u0022:\u002218339\u0022,\u0022Level\u0022:1,\u0022LinkingUri\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared%20Documents/PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx?d=w3fc0ae3fb2074770b3a6502de8b981dc\u0022,\u0022LinkingUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx?d=w3fc0ae3fb2074770b3a6502de8b981dc\u0022,\u0022MajorVersion\u0022:1,\u0022MinorVersion\u0022:0,\u0022Name\u0022:\u0022PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx\u0022,\u0022ServerRelativeUrl\u0022:\u0022/sites/pnpcoresdktestgroup/Shared Documents/PNP_SDK_TEST_UpdateContentTypeAsDocumentSet.docx\u0022,\u0022TimeCreated\u0022:\u00222022-05-31T19:36:39Z\u0022,\u0022TimeLastModified\u0022:\u00222022-05-31T19:36:39Z\u0022,\u0022Title\u0022:\u0022\u0022,\u0022UIVersion\u0022:512,\u0022UIVersionLabel\u0022:\u00221.0\u0022,\u0022UniqueId\u0022:\u00223fc0ae3f-b207-4770-b3a6-502de8b981dc\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00010.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00010.response.json new file mode 100644 index 0000000000..82ae6ae3d0 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00010.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-6004-4000-4c6b-a4a9ab756867","SPClientServiceRequestDuration":"287","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"[\r{\r\u0022SchemaVersion\u0022:\u002215.0.0.0\u0022,\u0022LibraryVersion\u0022:\u002216.0.22511.12008\u0022,\u0022ErrorInfo\u0022:null,\u0022TraceCorrelationId\u0022:\u0022badc42a0-6004-4000-4c6b-a4a9ab756867\u0022\r},5,{\r\u0022IsNull\u0022:false\r},6,{\r\u0022_ObjectIdentity_\u0022:\u0022badc42a0-6004-4000-4c6b-a4a9ab756867|740c6a0b-85e2-48a0-a494-e0f1759d4aa7:site:0f9b8f4f-0e8e-4630-bb0a-501442db9b64:web:ceb5fd80-a434-4a62-a60b-b272f10ba1df:contenttype:0x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022\r}\r]"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00011.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00011.response.json new file mode 100644 index 0000000000..41b1dba618 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00011.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"4a82e0ed-6104-4e6d-9cd6-4053e1abd56f","client-request-id":"4a82e0ed-6104-4e6d-9cd6-4053e1abd56f","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:39 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(documentSet,documentSet/sharedColumns(),documentSet/welcomePageColumns())/$entity\u0022,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:true,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document Set Name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022sharedColumns\u0022:[],\u0022welcomePageColumns\u0022:[]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00012.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00012.response.json new file mode 100644 index 0000000000..c888be58f6 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00012.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-e04e-4000-4c6b-a392030f023f","SPClientServiceRequestDuration":"21","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00013.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00013.response.json new file mode 100644 index 0000000000..efb8486a44 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00013.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-7054-4000-4767-d213961f52cf","SPClientServiceRequestDuration":"31","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022Fields\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ContentType\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022c042a256-787d-4a6f-8a8a-cf6ab767f12d\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ContentType\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:null,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ContentType\u0022,\u0022Title\u0022:\u0022Content Type\u0022,\u0022FieldTypeKind\u0022:12,\u0022TypeAsString\u0022:\u0022Computed\u0022,\u0022TypeDisplayName\u0022:\u0022Computed\u0022,\u0022TypeShortDescription\u0022:\u0022Computed\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022EnableLookup\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ItemChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022b824e17e-a1b3-426e-aecf-f0184d900485\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ItemChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{b824e17e-a1b3-426e-aecf-f0184d900485}\\\u0022 Name=\\\u0022ItemChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ItemChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Item Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022ItemChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ItemChildCount\u0022,\u0022Title\u0022:\u0022Item Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022ItemChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FolderChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022960ff01f-2b6d-4f1b-9c3f-e19ad8927341\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FolderChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{960ff01f-2b6d-4f1b-9c3f-e19ad8927341}\\\u0022 Name=\\\u0022FolderChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FolderChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Folder Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022FolderChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022FolderChildCount\u0022,\u0022Title\u0022:\u0022Folder Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022FolderChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Title\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:true,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:true,\u0022Id\u0022:\u0022fa564e0f-0c70-4ab9-b863-0177e6ddd247\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Title\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\\\u0022 Name=\\\u0022Title\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Title\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Title\\\u0022 Required=\\\u0022FALSE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Title\u0022,\u0022Title\u0022:\u0022Title\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FileLeafRef\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00228553196d-ec8d-4564-9861-3dbe931050c8\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FileLeafRef\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:true,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022FileLeafRef\u0022,\u0022Title\u0022:\u0022Name\u0022,\u0022FieldTypeKind\u0022:18,\u0022TypeAsString\u0022:\u0022File\u0022,\u0022TypeDisplayName\u0022:\u0022File\u0022,\u0022TypeShortDescription\u0022:\u0022File\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022A description of the Document Set\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022DocumentSetDescription\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022cbb92da4-fd46-4c7d-af6c-3128c2a5576e\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022DocumentSetDescription\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{CBB92DA4-FD46-4C7D-AF6C-3128C2A5576E}\\\u0022 Indexed=\\\u0022FALSE\\\u0022 Name=\\\u0022DocumentSetDescription\\\u0022 StaticName=\\\u0022DocumentSetDescription\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Description\\\u0022 Description=\\\u0022A description of the Document Set\\\u0022 Type=\\\u0022Note\\\u0022 NumLines=\\\u00225\\\u0022 UnlimitedLengthInDocumentLibrary=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Required=\\\u0022FALSE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 ShowInNewForm=\\\u0022TRUE\\\u0022 ShowInEditForm=\\\u0022TRUE\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022DocumentSetDescription\u0022,\u0022Title\u0022:\u0022Description\u0022,\u0022FieldTypeKind\u0022:3,\u0022TypeAsString\u0022:\u0022Note\u0022,\u0022TypeDisplayName\u0022:\u0022Multiple lines of text\u0022,\u0022TypeShortDescription\u0022:\u0022Multiple lines of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowHyperlink\u0022:false,\u0022AppendOnly\u0022:false,\u0022IsLongHyperlink\u0022:false,\u0022NumberOfLines\u0022:5,\u0022RestrictedMode\u0022:true,\u0022RichText\u0022:false,\u0022UnlimitedLengthInDocumentLibrary\u0022:true,\u0022WikiLinking\u0022:false}],\u0022StringId\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00014.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00014.response.json new file mode 100644 index 0000000000..b790f35bed --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00014.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00220\u0022","Location":"https://graph.microsoft.com/","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"644e3155-94a7-4228-9236-c9da9483d594","client-request-id":"644e3155-94a7-4228-9236-c9da9483d594","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:40 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(\u00270x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0027)/columns/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022text\u0022:{\u0022allowMultipleLines\u0022:false,\u0022appendChangesToExistingText\u0022:false,\u0022linesForEditing\u0022:0,\u0022maxLength\u0022:255},\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00015.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00015.response.json new file mode 100644 index 0000000000..00d49489c3 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00015.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-0072-4000-4c6b-a899eb084896","SPClientServiceRequestDuration":"26","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Categories\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Base Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Categories\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{9EBCD900-9D05-46c8-8F4D-E46E87328844}\\\u0022 Name=\\\u0022Categories\\\u0022 StaticName=\\\u0022Categories\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Categories\\\u0022 Group=\\\u0022Base Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Categories\u0022,\u0022Title\u0022:\u0022Categories\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00016.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00016.response.json new file mode 100644 index 0000000000..df573b0dc5 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00016.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-9077-4000-4767-df9666db1270","SPClientServiceRequestDuration":"65","X-SharePointHealthScore":"2","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022ListItemAllFields\u0022:{\u0022FileSystemObjectType\u0022:0,\u0022Id\u0022:649,\u0022ServerRedirectedEmbedUri\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_layouts/15/Doc.aspx?sourcedoc={3fc0ae3f-b207-4770-b3a6-502de8b981dc}\u0026action=interactivepreview\u0022,\u0022ServerRedirectedEmbedUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_layouts/15/Doc.aspx?sourcedoc={3fc0ae3f-b207-4770-b3a6-502de8b981dc}\u0026action=interactivepreview\u0022,\u0022ContentTypeId\u0022:\u00220x01010085F20CEF42E3A14F8BD3E307F88FEEDE\u0022,\u0022Modified\u0022:\u00222022-05-31T12:36:39\u0022,\u0022ComplianceAssetId\u0022:null,\u0022Title\u0022:null,\u0022SharedWithUsersId\u0022:null,\u0022SharedWithDetails\u0022:null,\u0022ID\u0022:649,\u0022Created\u0022:\u00222022-05-31T12:36:39\u0022,\u0022AuthorId\u0022:9,\u0022EditorId\u0022:9,\u0022OData__CopySource\u0022:null,\u0022CheckoutUserId\u0022:null,\u0022OData__UIVersionString\u0022:\u00221.0\u0022,\u0022GUID\u0022:\u0022a106b24a-4ccc-4bd7-a721-f84ec1dfa932\u0022},\u0022ListId\u0022:\u002268e9c7c6-94e1-4422-9eef-ca5a274ee7c6\u0022,\u0022UniqueId\u0022:\u00223fc0ae3f-b207-4770-b3a6-502de8b981dc\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00017.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00017.response.json new file mode 100644 index 0000000000..ed7c9e794f --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00017.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":204,"Headers":{"Cache-Control":"no-store, no-cache","Strict-Transport-Security":"max-age=31536000","request-id":"0f769d0c-d89f-4691-8a32-b5d1587a89db","client-request-id":"0f769d0c-d89f-4691-8a32-b5d1587a89db","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","Date":"Tue, 31 May 2022 19:36:40 GMT"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00018.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00018.response.json new file mode 100644 index 0000000000..22706be954 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00018.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00223\u0022","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"168f6a3c-463b-409b-b13b-0aa8136da2b4","client-request-id":"168f6a3c-463b-409b-b13b-0aa8136da2b4","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:41 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00223\\\u0022\u0022,\u0022id\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022,\u0022isBuiltIn\u0022:false,\u0022description\u0022:\u0022TESTING\u0022,\u0022group\u0022:\u0022TESTING\u0022,\u0022hidden\u0022:false,\u0022name\u0022:\u0022Document Set Name\u0022,\u0022parentId\u0022:\u00220x0120D520\u0022,\u0022readOnly\u0022:false,\u0022sealed\u0022:false,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:false,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document Set Name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022defaultContents\u0022:[{\u0022fileName\u0022:\u0022Test.docx\u0022,\u0022folderName\u0022:\u0022FolderName/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}}]},\u0022base\u0022:{\u0022id\u0022:\u00220x0120D520\u0022,\u0022description\u0022:\u0022Create a document set when you want to manage multiple documents as a single work product.\u0022,\u0022group\u0022:\u0022Document Set Content Types\u0022,\u0022hidden\u0022:false,\u0022name\u0022:\u0022Document Set\u0022,\u0022readOnly\u0022:false,\u0022sealed\u0022:false}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00019.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00019.response.json new file mode 100644 index 0000000000..28f7ffec80 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00019.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"fd0cbda0-b229-4005-a516-b105975d9ac2","client-request-id":"fd0cbda0-b229-4005-a516-b105975d9ac2","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:41 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(documentSet,documentSet/sharedColumns(),documentSet/welcomePageColumns())/$entity\u0022,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:false,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document Set Name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022defaultContents\u0022:[{\u0022fileName\u0022:\u0022Test.docx\u0022,\u0022folderName\u0022:\u0022FolderName/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}}],\u0022sharedColumns\u0022:[{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}],\u0022welcomePageColumns\u0022:[{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00020.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00020.response.json new file mode 100644 index 0000000000..6fcb992ed1 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00020.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-b0b7-4000-4c6b-afcce840cf36","SPClientServiceRequestDuration":"32","X-SharePointHealthScore":"0","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00021.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00021.response.json new file mode 100644 index 0000000000..b6736e63e2 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00021.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-30be-4000-4c6b-a18546bf7ca0","SPClientServiceRequestDuration":"29","X-SharePointHealthScore":"1","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022Fields\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ContentType\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022c042a256-787d-4a6f-8a8a-cf6ab767f12d\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ContentType\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:null,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{c042a256-787d-4a6f-8a8a-cf6ab767f12d}\\\u0022 Name=\\\u0022ContentType\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ContentType\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Computed\\\u0022 DisplayName=\\\u0022Content Type\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 RenderXMLUsingPattern=\\\u0022TRUE\\\u0022 PITarget=\\\u0022MicrosoftWindowsSharePointServices\\\u0022 PIAttribute=\\\u0022ContentTypeID\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003CFieldRefs\u003E\u003CFieldRef ID=\\\u0022{03e45e84-1992-4d42-9116-26f756012634}\\\u0022 Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/FieldRefs\u003E\u003CDisplayPattern\u003E\u003CMapToContentType\u003E\u003CColumn Name=\\\u0022ContentTypeId\\\u0022 /\u003E\u003C/MapToContentType\u003E\u003C/DisplayPattern\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ContentType\u0022,\u0022Title\u0022:\u0022Content Type\u0022,\u0022FieldTypeKind\u0022:12,\u0022TypeAsString\u0022:\u0022Computed\u0022,\u0022TypeDisplayName\u0022:\u0022Computed\u0022,\u0022TypeShortDescription\u0022:\u0022Computed\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022EnableLookup\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ItemChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022b824e17e-a1b3-426e-aecf-f0184d900485\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ItemChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{b824e17e-a1b3-426e-aecf-f0184d900485}\\\u0022 Name=\\\u0022ItemChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022ItemChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Item Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022ItemChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022ItemChildCount\u0022,\u0022Title\u0022:\u0022Item Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022ItemChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FolderChildCount\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022960ff01f-2b6d-4f1b-9c3f-e19ad8927341\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FolderChildCount\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:true,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{960ff01f-2b6d-4f1b-9c3f-e19ad8927341}\\\u0022 Name=\\\u0022FolderChildCount\\\u0022 DisplaceOnUpgrade=\\\u0022TRUE\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FolderChildCount\\\u0022 Group=\\\u0022_Hidden\\\u0022 ReadOnly=\\\u0022TRUE\\\u0022 Filterable=\\\u0022FALSE\\\u0022 Sortable=\\\u0022FALSE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Type=\\\u0022Lookup\\\u0022 DisplayName=\\\u0022Folder Child Count\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022FolderChildCount\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022FolderChildCount\u0022,\u0022Title\u0022:\u0022Folder Child Count\u0022,\u0022FieldTypeKind\u0022:7,\u0022TypeAsString\u0022:\u0022Lookup\u0022,\u0022TypeDisplayName\u0022:\u0022Lookup\u0022,\u0022TypeShortDescription\u0022:\u0022Lookup (information already on this site)\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowMultipleValues\u0022:false,\u0022DependentLookupInternalNames\u0022:[],\u0022IsDependentLookup\u0022:false,\u0022IsRelationship\u0022:false,\u0022LookupField\u0022:\u0022FolderChildCount\u0022,\u0022LookupList\u0022:\u0022\u0022,\u0022LookupWebId\u0022:\u0022ceb5fd80-a434-4a62-a60b-b272f10ba1df\u0022,\u0022PrimaryFieldId\u0022:\u0022ID\u0022,\u0022RelationshipDeleteBehavior\u0022:0,\u0022UnlimitedLengthInDocumentLibrary\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Title\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:true,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:true,\u0022Id\u0022:\u0022fa564e0f-0c70-4ab9-b863-0177e6ddd247\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Title\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\\\u0022 Name=\\\u0022Title\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022Title\\\u0022 Group=\\\u0022_Hidden\\\u0022 Type=\\\u0022Text\\\u0022 DisplayName=\\\u0022Title\\\u0022 Required=\\\u0022FALSE\\\u0022 FromBaseType=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 Hidden=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Title\u0022,\u0022Title\u0022:\u0022Title\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022FileLeafRef\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00228553196d-ec8d-4564-9861-3dbe931050c8\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022FileLeafRef\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:true,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{8553196d-ec8d-4564-9861-3dbe931050c8}\\\u0022 Name=\\\u0022FileLeafRef\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 StaticName=\\\u0022FileLeafRef\\\u0022 Group=\\\u0022_Hidden\\\u0022 ShowInFileDlg=\\\u0022FALSE\\\u0022 ShowInVersionHistory=\\\u0022FALSE\\\u0022 Type=\\\u0022File\\\u0022 DisplayName=\\\u0022Name\\\u0022 AuthoringInfo=\\\u0022(for use in forms)\\\u0022 List=\\\u0022Docs\\\u0022 FieldRef=\\\u0022ID\\\u0022 ShowField=\\\u0022LeafName\\\u0022 JoinColName=\\\u0022DoclibRowId\\\u0022 JoinRowOrdinal=\\\u00220\\\u0022 JoinType=\\\u0022INNER\\\u0022 Required=\\\u0022TRUE\\\u0022 DelayActivateTemplateBinding=\\\u0022GROUP,SPSPERS,SITEPAGEPUBLISHING\\\u0022 NoCustomize=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Customization=\\\u0022\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:false,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022FileLeafRef\u0022,\u0022Title\u0022:\u0022Name\u0022,\u0022FieldTypeKind\u0022:18,\u0022TypeAsString\u0022:\u0022File\u0022,\u0022TypeDisplayName\u0022:\u0022File\u0022,\u0022TypeShortDescription\u0022:\u0022File\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:false,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022A description of the Document Set\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022DocumentSetDescription\u0022,\u0022Filterable\u0022:false,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022_Hidden\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022cbb92da4-fd46-4c7d-af6c-3128c2a5576e\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022DocumentSetDescription\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{CBB92DA4-FD46-4C7D-AF6C-3128C2A5576E}\\\u0022 Indexed=\\\u0022FALSE\\\u0022 Name=\\\u0022DocumentSetDescription\\\u0022 StaticName=\\\u0022DocumentSetDescription\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 Group=\\\u0022_Hidden\\\u0022 DisplayName=\\\u0022Description\\\u0022 Description=\\\u0022A description of the Document Set\\\u0022 Type=\\\u0022Note\\\u0022 NumLines=\\\u00225\\\u0022 UnlimitedLengthInDocumentLibrary=\\\u0022TRUE\\\u0022 Hidden=\\\u0022FALSE\\\u0022 Required=\\\u0022FALSE\\\u0022 CanToggleHidden=\\\u0022TRUE\\\u0022 Sealed=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022 ShowInNewForm=\\\u0022TRUE\\\u0022 ShowInEditForm=\\\u0022TRUE\\\u0022 /\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:false,\u0022StaticName\u0022:\u0022DocumentSetDescription\u0022,\u0022Title\u0022:\u0022Description\u0022,\u0022FieldTypeKind\u0022:3,\u0022TypeAsString\u0022:\u0022Note\u0022,\u0022TypeDisplayName\u0022:\u0022Multiple lines of text\u0022,\u0022TypeShortDescription\u0022:\u0022Multiple lines of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022AllowHyperlink\u0022:false,\u0022AppendOnly\u0022:false,\u0022IsLongHyperlink\u0022:false,\u0022NumberOfLines\u0022:5,\u0022RestrictedMode\u0022:true,\u0022RichText\u0022:false,\u0022UnlimitedLengthInDocumentLibrary\u0022:true,\u0022WikiLinking\u0022:false},{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022Categories\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Base Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022Categories\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{9EBCD900-9D05-46c8-8F4D-E46E87328844}\\\u0022 Name=\\\u0022Categories\\\u0022 StaticName=\\\u0022Categories\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Categories\\\u0022 Group=\\\u0022Base Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022Categories\u0022,\u0022Title\u0022:\u0022Categories\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}],\u0022StringId\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00022.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00022.response.json new file mode 100644 index 0000000000..ac9ce5a33e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00022.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00220\u0022","Location":"https://graph.microsoft.com/","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"78045770-ac2d-40eb-8444-da2763f45575","client-request-id":"78045770-ac2d-40eb-8444-da2763f45575","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:42 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(\u00270x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0027)/columns/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Manager\u0027s Name\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022ManagersName\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022text\u0022:{\u0022allowMultipleLines\u0022:false,\u0022appendChangesToExistingText\u0022:false,\u0022linesForEditing\u0022:0,\u0022maxLength\u0022:255},\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00023.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00023.response.json new file mode 100644 index 0000000000..7c8ecae8ea --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00023.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-80cf-4000-4767-df5f484f961f","SPClientServiceRequestDuration":"28","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":"{\u0022value\u0022:[{\u0022AutoIndexed\u0022:false,\u0022CanBeDeleted\u0022:true,\u0022ClientSideComponentId\u0022:\u002200000000-0000-0000-0000-000000000000\u0022,\u0022ClientSideComponentProperties\u0022:null,\u0022ClientValidationFormula\u0022:null,\u0022ClientValidationMessage\u0022:null,\u0022CustomFormatter\u0022:null,\u0022DefaultFormula\u0022:null,\u0022DefaultValue\u0022:null,\u0022Description\u0022:\u0022\u0022,\u0022Direction\u0022:\u0022none\u0022,\u0022EnforceUniqueValues\u0022:false,\u0022EntityPropertyName\u0022:\u0022ManagersName\u0022,\u0022Filterable\u0022:true,\u0022FromBaseType\u0022:false,\u0022Group\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022Hidden\u0022:false,\u0022Id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022Indexed\u0022:false,\u0022IndexStatus\u0022:0,\u0022InternalName\u0022:\u0022ManagersName\u0022,\u0022IsModern\u0022:false,\u0022JSLink\u0022:\u0022clienttemplates.js\u0022,\u0022PinnedToFiltersPane\u0022:false,\u0022ReadOnlyField\u0022:false,\u0022Required\u0022:false,\u0022SchemaXml\u0022:\u0022\u003CField ID=\\\u0022{BA934502-D68D-4960-A54B-51E15FEF5FD3}\\\u0022 Name=\\\u0022ManagersName\\\u0022 StaticName=\\\u0022ManagersName\\\u0022 SourceID=\\\u0022http://schemas.microsoft.com/sharepoint/v3\\\u0022 DisplayName=\\\u0022Manager\u0026#39;s Name\\\u0022 Group=\\\u0022Core Contact and Calendar Columns\\\u0022 Type=\\\u0022Text\\\u0022 Sealed=\\\u0022TRUE\\\u0022 AllowDeletion=\\\u0022TRUE\\\u0022 Customization=\\\u0022\\\u0022\u003E\u003C/Field\u003E\u0022,\u0022Scope\u0022:\u0022/sites/pnpcoresdktestgroup\u0022,\u0022Sealed\u0022:true,\u0022ShowInFiltersPane\u0022:0,\u0022Sortable\u0022:true,\u0022StaticName\u0022:\u0022ManagersName\u0022,\u0022Title\u0022:\u0022Manager\u0027s Name\u0022,\u0022FieldTypeKind\u0022:2,\u0022TypeAsString\u0022:\u0022Text\u0022,\u0022TypeDisplayName\u0022:\u0022Single line of text\u0022,\u0022TypeShortDescription\u0022:\u0022Single line of text\u0022,\u0022ValidationFormula\u0022:null,\u0022ValidationMessage\u0022:null,\u0022MaxLength\u0022:255}]}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00024.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00024.response.json new file mode 100644 index 0000000000..f0c84410d8 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00024.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":204,"Headers":{"Cache-Control":"no-store, no-cache","Strict-Transport-Security":"max-age=31536000","request-id":"c5b0b69f-dda4-4bcc-8570-01f842b48b58","client-request-id":"c5b0b69f-dda4-4bcc-8570-01f842b48b58","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","Date":"Tue, 31 May 2022 19:36:42 GMT"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00025.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00025.response.json new file mode 100644 index 0000000000..c54793293e --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00025.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","ETag":"\u00226\u0022","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"c29d0aa0-768f-48c0-b0f4-5c9af3c49fe7","client-request-id":"c29d0aa0-768f-48c0-b0f4-5c9af3c49fe7","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:42 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes/$entity\u0022,\u0022@odata.etag\u0022:\u0022\\\u00226\\\u0022\u0022,\u0022id\u0022:\u00220x0120D520002E5AAE78D8DB1947903FC99D0979E4A5\u0022,\u0022isBuiltIn\u0022:false,\u0022description\u0022:\u0022TESTING\u0022,\u0022group\u0022:\u0022TESTING\u0022,\u0022hidden\u0022:false,\u0022name\u0022:\u0022Document Set Name\u0022,\u0022parentId\u0022:\u00220x0120D520\u0022,\u0022readOnly\u0022:false,\u0022sealed\u0022:false,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:false,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document Set Name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022defaultContents\u0022:[{\u0022fileName\u0022:\u0022Test2.docx\u0022,\u0022folderName\u0022:\u0022FolderName2/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}},{\u0022fileName\u0022:\u0022Test.docx\u0022,\u0022folderName\u0022:\u0022FolderName/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}}]},\u0022base\u0022:{\u0022id\u0022:\u00220x0120D520\u0022,\u0022description\u0022:\u0022Create a document set when you want to manage multiple documents as a single work product.\u0022,\u0022group\u0022:\u0022Document Set Content Types\u0022,\u0022hidden\u0022:false,\u0022name\u0022:\u0022Document Set\u0022,\u0022readOnly\u0022:false,\u0022sealed\u0022:false}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00026.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00026.response.json new file mode 100644 index 0000000000..e15769e625 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00026.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"Cache-Control":"no-store, no-cache","Transfer-Encoding":"chunked","Vary":"Accept-Encoding","Strict-Transport-Security":"max-age=31536000","request-id":"b1a53300-7f51-4e31-9fd6-f663082ad63b","client-request-id":"b1a53300-7f51-4e31-9fd6-f663082ad63b","x-ms-ags-diagnostic":"{\u0022ServerInfo\u0022:{\u0022DataCenter\u0022:\u0022North Europe\u0022,\u0022Slice\u0022:\u0022E\u0022,\u0022Ring\u0022:\u00224\u0022,\u0022ScaleUnit\u0022:\u0022002\u0022,\u0022RoleInstance\u0022:\u0022DU2PEPF00010805\u0022}}","OData-Version":"4.0","Date":"Tue, 31 May 2022 19:36:42 GMT"},"Response":"{\u0022@odata.context\u0022:\u0022https://graph.microsoft.com/v1.0/$metadata#sites(\u00270f9b8f4f-0e8e-4630-bb0a-501442db9b64\u0027)/contentTypes(documentSet,documentSet/sharedColumns(),documentSet/welcomePageColumns())/$entity\u0022,\u0022documentSet\u0022:{\u0022shouldPrefixNameToFile\u0022:false,\u0022welcomePageUrl\u0022:\u0022https://mathijsdev2.sharepoint.com/sites/pnpcoresdktestgroup/_cts/Document Set Name/docsethomepage.aspx\u0022,\u0022allowedContentTypes\u0022:[{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}],\u0022defaultContents\u0022:[{\u0022fileName\u0022:\u0022Test2.docx\u0022,\u0022folderName\u0022:\u0022FolderName2/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}},{\u0022fileName\u0022:\u0022Test.docx\u0022,\u0022folderName\u0022:\u0022FolderName/\u0022,\u0022contentType\u0022:{\u0022id\u0022:\u00220x0101\u0022,\u0022name\u0022:\u0022Document\u0022}}],\u0022sharedColumns\u0022:[{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}},{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Manager\u0027s Name\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022ManagersName\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}],\u0022welcomePageColumns\u0022:[{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Core Contact and Calendar Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Manager\u0027s Name\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u0022ba934502-d68d-4960-a54b-51e15fef5fd3\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022ManagersName\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}},{\u0022@odata.etag\u0022:\u0022\\\u00220\\\u0022\u0022,\u0022columnGroup\u0022:\u0022Base Columns\u0022,\u0022description\u0022:\u0022\u0022,\u0022displayName\u0022:\u0022Categories\u0022,\u0022enforceUniqueValues\u0022:false,\u0022hidden\u0022:false,\u0022id\u0022:\u00229ebcd900-9d05-46c8-8f4d-e46e87328844\u0022,\u0022indexed\u0022:false,\u0022isDeletable\u0022:true,\u0022isReorderable\u0022:true,\u0022isSealed\u0022:true,\u0022propagateChanges\u0022:false,\u0022name\u0022:\u0022Categories\u0022,\u0022readOnly\u0022:false,\u0022required\u0022:false,\u0022type\u0022:\u0022text\u0022,\u0022validation\u0022:{\u0022defaultLanguage\u0022:\u0022en-US\u0022,\u0022descriptions\u0022:[{\u0022languageTag\u0022:\u0022en-US\u0022}]}}]}}"} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00027.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00027.response.json new file mode 100644 index 0000000000..a8fd47c9a3 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00027.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"badc42a0-80f9-4000-4c6b-a98d90c92fd8","SPClientServiceRequestDuration":"65","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00028.response.json b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00028.response.json new file mode 100644 index 0000000000..c3bf955c32 --- /dev/null +++ b/src/sdk/PnP.Core.Test/SharePoint/MockData/ContentTypeTests/UpdateContentTypeAsDocumentSet-0-00028.response.json @@ -0,0 +1 @@ +{"IsSuccessStatusCode":true,"StatusCode":200,"Headers":{"SPRequestGuid":"bbdc42a0-f000-4000-4c6b-a06986820776","SPClientServiceRequestDuration":"75","X-SharePointHealthScore":"3","X-SP-SERVERSTATE":"ReadOnly=0"},"Response":""} \ No newline at end of file diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs index b059b2989b..1af00f0f2f 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs @@ -1,10 +1,12 @@ -using PnP.Core.Services; +using PnP.Core.QueryModel; +using PnP.Core.Services; using PnP.Core.Services.Core.CSOM.Requests; using PnP.Core.Services.Core.CSOM.Requests.Web; using PnP.Core.Services.Core.CSOM.Utils.Model; using System; using System.Collections.Generic; using System.Dynamic; +using System.Linq; using System.Net.Http; using System.Text.Json; using System.Threading.Tasks; @@ -27,6 +29,7 @@ public ContentType() // In the case of Add operation, the CSOM api is used and JSON mapping to model is not possible // So here, populate the Rest Id metadata field to enable actions upon // this content type without having to read it again from the server + Id = StringId; AddMetadata(PnPConstants.MetaDataRestId, StringId); AddMetadata(PnPConstants.MetaDataType, "SP.ContentType"); Requested = true; @@ -135,7 +138,7 @@ public async Task AsDocumentSetAsync() { if (!Id.StartsWith("0x0120D520")) { - throw new ClientException(ErrorType.Unsupported, "The specified content type is not of type 'Document Set'"); + throw new ClientException(ErrorType.Unsupported, "The specified content type is not of type 'Document Set'. Impossible to return this as Document Set"); } var apiCall = GetDocumentSetApiCall(); @@ -168,11 +171,39 @@ public IDocumentSet AsDocumentSet() private ApiCall GetDocumentSetApiCall() { // implement web / list ct later - var requestUrl = $"sites/{PnPContext.Site.Id}/contentTypes/{Id}"; + var requestUrl = $"sites/{PnPContext.Site.Id}/contentTypes/{Id}?$expand=DocumentSet/SharedColumns,DocumentSet/WelcomePageColumns&$select=documentSet"; return new ApiCall(requestUrl, ApiType.Graph); } + internal async Task AddFileToDefaultContentLocationAsync(string listId, string listItemId, string destinationName) + { + var apiCall = AddFileToDefaultContentLocationApiCall(listId, listItemId, destinationName); + await RequestAsync(apiCall, HttpMethod.Post).ConfigureAwait(false); + } + + private ApiCall AddFileToDefaultContentLocationApiCall(string listId, string listItemId, string destinationName) + { + var requestUrl = $"sites/{PnPContext.Site.Id}/contentTypes/{Id}/copyToDefaultContentLocation"; + + dynamic body = new ExpandoObject(); + body.destinationFileName = destinationName; + + dynamic sourceFile = new ExpandoObject(); + dynamic sharePointIds = new ExpandoObject(); + + sharePointIds.listId = listId; + sharePointIds.listItemId = listItemId; + + sourceFile.sharepointIds = sharePointIds; + + body.sourceFile = sourceFile; + + var bodyContent = JsonSerializer.Serialize(body, typeof(ExpandoObject), PnPConstants.JsonSerializer_WriteIndentedFalse); + + return new ApiCall(requestUrl, ApiType.Graph, bodyContent); + } + #region Deserialization of document set private void DeserializeDocumentSet(JsonElement json, DocumentSet documentSet) @@ -183,10 +214,12 @@ private void DeserializeDocumentSet(JsonElement json, DocumentSet documentSet) { documentSet.ShouldPrefixNameToFile = shouldPrefix.GetBoolean(); } + if (documentSetJson.TryGetProperty("welcomePageUrl", out JsonElement welcomePageUrl)) { documentSet.WelcomePageUrl = welcomePageUrl.GetString(); } + if (documentSetJson.TryGetProperty("allowedContentTypes", out JsonElement allowedContentTypes)) { var allowedContentTypesList = new List(); @@ -208,6 +241,10 @@ private void DeserializeDocumentSet(JsonElement json, DocumentSet documentSet) } documentSet.DefaultContents = defaultContentsList; + } + else + { + documentSet.DefaultContents = new List(); } if (documentSetJson.TryGetProperty("sharedColumns", out JsonElement sharedColumns)) { @@ -220,6 +257,10 @@ private void DeserializeDocumentSet(JsonElement json, DocumentSet documentSet) documentSet.SharedColumns = sharedColumnsList; } + else + { + documentSet.SharedColumns = new List(); + } if (documentSetJson.TryGetProperty("welcomePageColumns", out JsonElement welcomePageColumns)) { var welcomePageColumnsList = new List(); @@ -231,7 +272,10 @@ private void DeserializeDocumentSet(JsonElement json, DocumentSet documentSet) documentSet.WelcomePageColumns = welcomePageColumnsList; } - + else + { + documentSet.WelcomePageColumns = new List(); + } } } @@ -241,7 +285,7 @@ private IField DeseralizeField(JsonElement sharedColumn) if (sharedColumn.TryGetProperty("name", out JsonElement name)) { - field.Title = name.GetString(); + field.InternalName = name.GetString(); } if (sharedColumn.TryGetProperty("id", out JsonElement id)) @@ -308,6 +352,42 @@ private IContentTypeInfo DeserializeContentType(JsonElement allowedContentType) #endregion #region Extension methods + + #region Add Fields + + public async Task AddFieldAsync(IField field) + { + await LoadAsync(y => y.Fields).ConfigureAwait(false); + + if (Fields.AsRequested().FirstOrDefault(p => p.Id.Equals(field.Id)) != null) + { + throw new Exception("Field already exists on content-type, we can't add the field..."); + } + + var apiCall = GetFieldAddApiCall(field); + + await RawRequestAsync(apiCall, HttpMethod.Post).ConfigureAwait(false); + } + + public void AddField(IField field) + { + AddFieldAsync(field).GetAwaiter().GetResult(); + } + + private ApiCall GetFieldAddApiCall(IField field) + { + var requestUrl = $"sites/{PnPContext.Site.Id}/contentTypes/{Id}/columns"; + + dynamic body = new ExpandoObject(); + + ((IDictionary)body)["sourceColumn@odata.bind"] = $"https://graph.microsoft.com/v1.0/sites/{PnPContext.Site.Id}/columns/{field.Id}"; + + + return new ApiCall(requestUrl, ApiType.Graph, jsonBody: JsonSerializer.Serialize(body, typeof(ExpandoObject), PnPConstants.JsonSerializer_IgnoreNullValues_CamelCase)); + } + + #endregion + #region AddAvailableContentType private ApiCall AddAvailableContentTypeApiCall(string id) { @@ -336,7 +416,6 @@ internal async Task AddAvailableContentTypeAsync(string id) await RequestAsync(apiCall, HttpMethod.Post).ConfigureAwait(false); return this; } - #endregion #endregion } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs index 1c242aa834..4fa7482c19 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentTypeCollection.cs @@ -132,14 +132,28 @@ public IContentType AddAvailableContentType(string id) #region Document Set - public async Task AddDocumentSetAsync(DocumentSetOptions options) + public async Task AddDocumentSetAsync(string id, string name, string description = null, string group = null, DocumentSetOptions options = null) { - return null; + if (!id.StartsWith("0x0120D520")) + { + throw new ArgumentException("The specified content type is not of type 'Document Set'. Start your ID with 0x0120D520"); + } + + var contentType = await AddAsync(id, name, description, group).ConfigureAwait(false) as ContentType; + + var documentSet = await contentType.AsDocumentSetAsync().ConfigureAwait(false); + + if (options != null) + { + return await documentSet.UpdateAsync(options).ConfigureAwait(false); + } + + return documentSet; } - public IDocumentSet AddDocumentSet(DocumentSetOptions options) + public IDocumentSet AddDocumentSet(string id, string name, string description = null, string group = null, DocumentSetOptions options = null) { - return AddDocumentSetAsync(options).GetAwaiter().GetResult(); + return AddDocumentSetAsync(id, name, description, group, options).GetAwaiter().GetResult(); } #endregion diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs index 4381695566..737dd3d859 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/DocumentSet.cs @@ -1,4 +1,12 @@ -using System.Collections.Generic; +using PnP.Core.QueryModel; +using PnP.Core.Services; +using System; +using System.Collections.Generic; +using System.Dynamic; +using System.Linq; +using System.Net; +using System.Net.Http; +using System.Text.Json; using System.Threading.Tasks; namespace PnP.Core.Model.SharePoint @@ -13,9 +21,7 @@ internal sealed class DocumentSet : BaseDataModel, IDocumentSet public IList AllowedContentTypes { get => GetValue>(); set => SetValue(value); } - public IList DefaultContents { get => GetModelCollectionValue>(); set => SetValue(value); } - - public bool PropagateWelcomePageChanges { get => GetValue(); set => SetValue(value); } + public IList DefaultContents { get => GetValue>(); set => SetValue(value); } public bool ShouldPrefixNameToFile { get => GetValue(); set => SetValue(value); } @@ -32,14 +38,194 @@ internal sealed class DocumentSet : BaseDataModel, IDocumentSet #region Methods - public async Task UpdateAsync(DocumentSetOptions options) + public async Task UpdateAsync(DocumentSetOptions options) { + var parentCt = Parent as ContentType; + + dynamic body = new ExpandoObject(); + + dynamic documentSet = new ExpandoObject(); + + if (options.PropagateWelcomePageChanges.HasValue) + { + documentSet.propagateWelcomePageChanges = options.PropagateWelcomePageChanges; + } + + if (options.ShouldPrefixNameToFile.HasValue) + { + documentSet.shouldPrefixNameToFile = options.ShouldPrefixNameToFile; + } + + if (options.AllowedContentTypes != null && options.AllowedContentTypes.Count > 0) + { + var allowedContentTypes = new List(); + + foreach (var allowedContentType in options.AllowedContentTypes) + { + dynamic allowedCt = new ExpandoObject(); + + allowedCt.id = allowedContentType.Id; + allowedCt.name = allowedContentType.Name; + allowedContentTypes.Add(allowedCt); + } + + if (options.KeepExistingContentTypes && AllowedContentTypes.Count > 0) + { + foreach (var allowedContentType in AllowedContentTypes) + { + dynamic allowedCt = new ExpandoObject(); + + allowedCt.id = allowedContentType.Id; + allowedCt.name = allowedContentType.Name; + + allowedContentTypes.Add(allowedCt); + } + } + + documentSet.allowedContentTypes = allowedContentTypes; + } + + if (options.SharedColumns != null && options.SharedColumns.Count > 0) + { + foreach (var field in options.SharedColumns) + { + if (await parentCt.Fields.FirstOrDefaultAsync(y => y.Id == field.Id).ConfigureAwait(false) == null) + { + await parentCt.AddFieldAsync(field).ConfigureAwait(false); + } + } + + var sharedColumns = new List(); + + foreach (var column in options.SharedColumns) + { + dynamic sharedColumn = new ExpandoObject(); + + sharedColumn.id = column.Id; + sharedColumn.name = column.InternalName; + + sharedColumns.Add(sharedColumn); + } + + if (options.KeepExistingSharedColumns && SharedColumns.Count > 0) + { + foreach (var column in SharedColumns) + { + dynamic sharedColumn = new ExpandoObject(); + + sharedColumn.id = column.Id; + sharedColumn.name = column.InternalName; + + sharedColumns.Add(sharedColumn); + } + } + + documentSet.sharedColumns = sharedColumns; + } + + if (options.WelcomePageColumns != null && options.WelcomePageColumns.Count > 0) + { + foreach (var field in options.WelcomePageColumns) + { + // Check if field exists on CT, if not, add it. Otherwise --> Error + if (await parentCt.Fields.FirstOrDefaultAsync(y => y.Id == field.Id).ConfigureAwait(false) == null) + { + await parentCt.AddFieldAsync(field).ConfigureAwait(false); + } + } + + var welcomePageColumns = new List(); + + foreach (var column in options.WelcomePageColumns) + { + dynamic welcomeColumn = new ExpandoObject(); + + welcomeColumn.id = column.Id; + welcomeColumn.name = column.InternalName; + + welcomePageColumns.Add(welcomeColumn); + } + + if (options.KeepExistingWelcomePageColumns && WelcomePageColumns.Count > 0) + { + foreach (var column in WelcomePageColumns) + { + dynamic welcomeColumn = new ExpandoObject(); + + welcomeColumn.id = column.Id; + welcomeColumn.name = column.InternalName; + + welcomePageColumns.Add(welcomeColumn); + } + } + + documentSet.welcomePageColumns = welcomePageColumns; + } + + if (options.DefaultContents != null && options.DefaultContents.Count > 0) + { + var defaultContents = new List(); + + foreach (var defaultContent in options.DefaultContents) + { + if (!defaultContent.FolderName.EndsWith("/")) + { + defaultContent.FolderName += "/"; + } + + await defaultContent.File.EnsurePropertiesAsync(y => y.ListItemAllFields, y => y.ListId).ConfigureAwait(false); + + await parentCt.AddFileToDefaultContentLocationAsync(defaultContent.File.ListId.ToString(), defaultContent.File.ListItemAllFields.Id.ToString(), defaultContent.FileName).ConfigureAwait(false); + + dynamic defaultContentDynamic = new ExpandoObject(); + defaultContentDynamic.fileName = defaultContent.FileName; + defaultContentDynamic.folderName = defaultContent.FolderName; + + dynamic contentTypeInfo = new ExpandoObject(); + contentTypeInfo.id = defaultContent.ContentTypeId; + defaultContentDynamic.contentType = contentTypeInfo; + + defaultContents.Add(defaultContentDynamic); + } + + if (options.KeepExistingDefaultContent && DefaultContents.Count > 0) + { + foreach (var dc in DefaultContents) + { + dynamic defaultContentDynamic = new ExpandoObject(); + defaultContentDynamic.fileName = dc.FileName; + defaultContentDynamic.folderName = dc.FolderName; + + dynamic contentTypeInfo = new ExpandoObject(); + contentTypeInfo.id = dc.ContentType.Id; + defaultContentDynamic.contentType = contentTypeInfo; + + defaultContents.Add(defaultContentDynamic); + } + } + + documentSet.defaultContents = defaultContents; + } + + body.documentSet = documentSet; + + var apiCall = new ApiCall($"sites/{PnPContext.Site.Id}/contenttypes/{ContentTypeId}", ApiType.Graph, jsonBody: JsonSerializer.Serialize(body, typeof(ExpandoObject), PnPConstants.JsonSerializer_IgnoreNullValues_CamelCase)); + var response = await RawRequestAsync(apiCall, new HttpMethod("PATCH")).ConfigureAwait(false); + + if (response.StatusCode == HttpStatusCode.OK || response.StatusCode == HttpStatusCode.Created) + { + return await parentCt.AsDocumentSetAsync().ConfigureAwait(false); + } + else + { + throw new Exception("Error occured during update"); + } } - public void Update(DocumentSetOptions options) + public IDocumentSet Update(DocumentSetOptions options) { - UpdateAsync(options).GetAwaiter().GetResult(); + return UpdateAsync(options).GetAwaiter().GetResult(); } #endregion diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/Field.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/Field.cs index d64d8299ed..1b3dd48a80 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/Field.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/Field.cs @@ -12,6 +12,7 @@ namespace PnP.Core.Model.SharePoint /// /// Field class, write your custom code here /// + [SharePointType("SP.Field", Target = typeof(ContentType), Uri = "_api/Web/ContentTypes('{Parent.Id}')/Field('{Id}')", LinqGet = "_api/web/ContentTypes('{Parent.Id}')/Fields")] [SharePointType("SP.Field", Target = typeof(Web), Uri = "_api/Web/Fields('{Id}')", Get = "_api/Web/Fields", LinqGet = "_api/Web/Fields")] [SharePointType("SP.Field", Target = typeof(List), Uri = "_api/Web/Lists(guid'{Parent.Id}')/Fields('{Id}')", Get = "_api/Web/Lists(guid'{Parent.Id}')/Fields", LinqGet = "_api/Web/Lists(guid'{Parent.Id}')/Fields")] internal sealed class Field : BaseDataModel, IField diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs index 75ea234fad..e1688434e5 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs @@ -192,6 +192,18 @@ public interface IContentType : IDataModel, IDataModelGetThe content type as a document set IDocumentSet AsDocumentSet(); + /// + /// Adds a field to the content type + /// + /// + Task AddFieldAsync(IField field); + + /// + /// Adds a field to the content type + /// + /// + void AddField(IField field); + #endregion } } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs index 44d8147380..dfedb562aa 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentTypeCollection.cs @@ -143,16 +143,24 @@ public interface IContentTypeCollection : IQueryable, IAsyncEnumer /// /// Creates a document set /// + /// Id of the document set + /// Name of the document set + /// Description of the document set + /// Group of the document set /// Options for creating the document set - /// Newly created document set - Task AddDocumentSetAsync(DocumentSetOptions options); + /// The newly added document set + Task AddDocumentSetAsync(string id, string name, string description = null, string group = null, DocumentSetOptions options = null); /// /// Creates a document set /// + /// Id of the document set + /// Name of the document set + /// Description of the document set + /// Group of the document set /// Options for creating the document set - /// Newly created document set - IDocumentSet AddDocumentSet(DocumentSetOptions options); + /// The newly added document set + IDocumentSet AddDocumentSet(string id, string name, string description = null, string group = null, DocumentSetOptions options = null); #endregion diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs index 57a1979af7..b7c1f0d4f6 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IDocumentSet.cs @@ -26,11 +26,6 @@ public interface IDocumentSet : IDataModel /// public IList DefaultContents { get; set; } - /// - /// Specifies whether to push welcome page changes to inherited content types. - /// - public bool PropagateWelcomePageChanges { get; set; } - /// /// Indicates whether to add the name of the document set to each file name. /// @@ -60,12 +55,12 @@ public interface IDocumentSet : IDataModel /// Updates the document set /// /// - Task UpdateAsync(DocumentSetOptions options); + Task UpdateAsync(DocumentSetOptions options); /// /// Updates the document set /// - void Update(DocumentSetOptions options); + IDocumentSet Update(DocumentSetOptions options); #endregion } diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetContentOptions.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetContentOptions.cs new file mode 100644 index 0000000000..9c28c2db0b --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetContentOptions.cs @@ -0,0 +1,28 @@ +namespace PnP.Core.Model.SharePoint +{ + /// + /// Options for default document set content + /// + public class DocumentSetContentOptions + { + /// + /// File to add as default content + /// + public IFile File { get; set; } + + /// + /// Content type of the file to add as default content + /// + public string ContentTypeId { get; set; } + + /// + /// File name of the file to be added as default content + /// + public string FileName { get; set; } + + /// + /// Folder name of the default content + /// + public string FolderName { get; set; } + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetOptions.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetOptions.cs new file mode 100644 index 0000000000..5a61bbe2ff --- /dev/null +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetOptions.cs @@ -0,0 +1,66 @@ +using System.Collections.Generic; + +namespace PnP.Core.Model.SharePoint +{ + /// + /// Available options for a Document Set + /// + public class DocumentSetOptions + { + /// + /// Indicates whether to add the name of the document set to each file name. + /// + public bool? ShouldPrefixNameToFile { get; set; } + + /// + /// Welcome page absolute URL. + /// + public string WelcomePageUrl { get; set; } + + /// + /// Specifies whether to push welcome page changes to inherited content types. + /// + public bool? PropagateWelcomePageChanges { get; set; } + + /// + /// Defines if we keep the existing content types that are already allowed in the document set + /// + public bool KeepExistingContentTypes { get; set; } = true; + + /// + /// List of the allowed content types in the document set + /// + public List AllowedContentTypes { get; set; } + + /// + /// Defines if we keep the existing shared columns or delete those (by not adding them to our body) + /// + public bool KeepExistingSharedColumns { get; set; } = true; + + /// + /// Columns edited on the document set that synchronize to all documents in the set. + /// These are read-only on the documents themselves. + /// + public List SharedColumns { get; set; } + + /// + /// Defines if we keep the existing welcome page columns or delete those (by not adding them to our body) + /// + public bool KeepExistingWelcomePageColumns { get; set; } = true; + + /// + /// Specifies columns to show on the welcome page for the document set. + /// + public List WelcomePageColumns { get; set; } + + /// + /// Defines if we keep the existing default contents or delete those (by not adding them to our body) + /// + public bool KeepExistingDefaultContent { get; set; } = true; + + /// + /// Default contents of document set. + /// + public List DefaultContents { get; set; } + } +} diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs deleted file mode 100644 index 7ba2088c3e..0000000000 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/Options/DocumentSetUpdateOptions.cs +++ /dev/null @@ -1,14 +0,0 @@ -namespace PnP.Core.Model.SharePoint -{ - /// - /// Available options for a Document Set - /// - public class DocumentSetOptions - { - - /// - /// Name of the content type - /// - public string Name { get; set; } - } -} From e32b22cf1af9a17998c79c54bb8de66c78a978e3 Mon Sep 17 00:00:00 2001 From: Mathijs Verbeeck Date: Tue, 31 May 2022 21:58:09 +0200 Subject: [PATCH 3/3] Forgot some configureawaits, also added some comments --- src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs | 8 ++++---- .../Model/SharePoint/Core/Internal/ContentType.cs | 2 +- .../PnP.Core/Model/SharePoint/Core/Public/IContentType.cs | 7 ++++--- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs b/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs index 41edd101fd..8abc0397a0 100644 --- a/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs +++ b/src/sdk/PnP.Core.Test/SharePoint/ContentTypeTests.cs @@ -834,9 +834,9 @@ public async Task AddContentTypeAsDocumentSet() var categoriesField = await context.Web.Fields.FirstAsync(y => y.InternalName == "Categories").ConfigureAwait(false); var managersField = await context.Web.Fields.FirstAsync(y => y.InternalName == "ManagersName").ConfigureAwait(false); - var file = await context.Web.GetFileByServerRelativeUrlAsync(documentUrl); - var documentCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Document"); - var formCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Form"); + var file = await context.Web.GetFileByServerRelativeUrlAsync(documentUrl).ConfigureAwait(false); + var documentCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Document").ConfigureAwait(false); + var formCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Form").ConfigureAwait(false); var documentSetOptions = new DocumentSetOptions { @@ -899,7 +899,7 @@ public async Task UpdateContentTypeAsDocumentSet() var categoriesField = await context.Web.Fields.FirstAsync(y => y.InternalName == "Categories").ConfigureAwait(false); var managersField = await context.Web.Fields.FirstAsync(y => y.InternalName == "ManagersName").ConfigureAwait(false); - var documentCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Document"); + var documentCt = await context.Web.ContentTypes.FirstAsync(y => y.Name == "Document").ConfigureAwait(false); var file = await context.Web.GetFileByServerRelativeUrlAsync(documentUrl); diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs index 1af00f0f2f..11c3933452 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Internal/ContentType.cs @@ -138,7 +138,7 @@ public async Task AsDocumentSetAsync() { if (!Id.StartsWith("0x0120D520")) { - throw new ClientException(ErrorType.Unsupported, "The specified content type is not of type 'Document Set'. Impossible to return this as Document Set"); + throw new ClientException(ErrorType.Unsupported, "The specified content type is not of type 'Document Set'. Impossible to return this as C"); } var apiCall = GetDocumentSetApiCall(); diff --git a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs index e1688434e5..583f7f977b 100644 --- a/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs +++ b/src/sdk/PnP.Core/Model/SharePoint/Core/Public/IContentType.cs @@ -1,4 +1,5 @@ -using System.Linq; +using PnP.Core.Services; +using System.Linq; using System.Threading.Tasks; namespace PnP.Core.Model.SharePoint @@ -181,13 +182,13 @@ public interface IContentType : IDataModel, IDataModelGet - /// + /// Returns the content type as a document set /// /// The content type as a document set Task AsDocumentSetAsync(); /// - /// + /// Returns the content type as a document set /// /// The content type as a document set IDocumentSet AsDocumentSet();