Skip to content

Commit

Permalink
Update (#1)
Browse files Browse the repository at this point in the history
* Updated the provisioning template by modifying the RegionalSettings attribute CalendarType="Gregorian". When set to "none", it causes blank pages after deployment. See pnp/PnP-Sites-Core#715 for more information. Now we can use the Pnp PowerShell cmdlet august version.

* Added the Part 3 article link of the documentation.

* Added the Part 4 of the documentation link (Navigation implementation)

* Updated the contextual menu behavior. Now the parent section is displayed for sub pages (i.e non root pages).

* Updating js core lib in samples add-in

* Added the Part 5 of the documentation (Localization)

* Updated the PnP JSCore library to 1.0.4

* Added the Provisioning.PnPDeployer.Console folder within the samples. A small console application for deploying PnP XML templates and open xml packages through a userfriendly sequences configuration file.

* Added the README.md file.

* Updated the README.md file with valid internal references.

* Updated internal references with page-relative references.

* Added sample readme tracking to all components, samples and solutions.

* Migrating ASP.NET Core Authentication library projects and structure

Added the first cut of the migration to RTM. Library and Sample Web ready

* Migrating ASP.NET Core Authentication library to RTM - added wwwroot

* Migrating Core Authentication from RC1 to RTM - cleanup

Cleaning up old solution files

* Migrating Core Authentication from RC1 to RTM - further cleanup

Cleaning up old solution files

* Updated sample to work with modern site contents page.

* Updated readme for the sub site sample on provided changes.

* Added metrics tracking for the portal sample solution readme

* Updated README.md to the readme-template standards

* Added usage tracking for the new PnP Deployer sample

* Migrated PnP Core Authentication to ASP.NET Core 1.0.0

This is the first cut build to use the SharePoint CSOM library with ASP.NET Core

* ASP.NET Core Authentication - added CliendId check and removed cookies

* Added the last part of the documentation (part 6).

* Casing fix for README files

* September 2016 release

* Rename to README.md

* Rename to README.md

* Rename to README.md

* Rename to README.md

* September 2016 release

* September 2016 release

* September 2016 release (pnp#1524)

* September 2016 release

September 2016 master merge

* September 2016 release

* Rename to README.md (pnp#1526)

* ASP.NET Core Authentication - README.md update (pnp#1527)

* AspNetCore Auth - Added a NuGet and NuSpec files

AspNetCore Auth - Added a NuGet and NuSpec files to reference the OfficeDevPnP.Core.Framework.Authentication.dll file in another project

* AspNetCore Auth - updated readme.md to clarify RTM support

* Improvements made to the O365 starter intranet solution (pnp#1529)

* Added a caoursel component.

* Updated the provisioning schema version to 201605.
Added promoted links on home page.
Added sample content for the carousel and links.
Fixed the "FR" labels translations with moment.js.
Added a custom theme with spcolor.
Updated nuget packages for the extensibility provider solution for the PnP core assembly.

* Updated the home page screenshot in the README file.

* Asp net core authentication (pnp#1533)

* AspNetCore Auth - Added a NuGet and NuSpec files

AspNetCore Auth - Added a NuGet and NuSpec files to reference the OfficeDevPnP.Core.Framework.Authentication.dll file in another project

* AspNetCore Auth - updated readme.md to clarify RTM support

* Cleanup and changed version to 1.1.0

* October 2016 release

* Fix a type that causes NullReference exception (pnp#1542)

* update to pnp.js from 1.0.5 release

* Commit example including knockout, accordion, and REST

* Fixed references to old Yammer group for discussion

* Update ISSUE_TEMPLATE.md

* Forced the 1.0.4 version for the sp-pnp-js package. Running "npm install" with the "^" caret character, will update to the 1.0.5 version causing issues with TypeScript versions. (pnp#1551)

* Provisioning.pn p deployer.console (pnp#1552)

* Added a configurable parameter that allows the deployer to ignore folders in order to speed up the tokenizing process. Updated the token file XSD for a more consistent XML. Fixed a bug related to tokens loaded from the App.config file. Removed the project build events.

* Update FieldsExtensibilityProvider.md

* Update README.md

* Added the custom Required attribute to the FieldsExtensibilityProvider serializable classes.

* Added the ignored extensions functionnality

Added the ignored extensions functionnality in order to be able to ignore specific file extensions for the tokenizing process. This makes sure that files such as images, videos, pnp packages etc aren't corrupted by the tokenizer opening them and saving them in a corrupted format.

* Added the ignored extensions functionnality

Added the ignored extensions functionality in order to be able to ignore specific file extensions for the tokenizing process. This makes sure that files such as images, videos, pnp packages etc aren't corrupted by the tokenizer opening them and saving them in a corrupted format.

* Added the ignored extensions functionnality

Added the ignored extensions functionnality in order to be able to ignore specific file extensions for the tokenizing process. This makes sure that files such as images, videos, pnp packages etc aren't corrupted by the tokenizer opening them and saving them in a corrupted format.

* Removed the previously added ignored extensions parameter

Removed the previously added ignored extensions parameter and replaced it by a more dynamic way of handling the problem.

* Removed the previously added ignored extensions parameter

Removed the previously added ignored extensions parameter and replaced it by a more dynamic way of handling the problem.

* Removed the previously added ignored extensions parameter

Removed the previously added ignored extensions parameter and replaced it by a more dynamic way of handling the problem.

* NuGet package reference fixes

* November 2016 release

* Update Program.cs (pnp#1567)

NullRef on pagedCollection

* Updated InjectResponsiveCSS to use PnP Core component - so that responsive samples are aligned and using the exact same solution.

* First implementation of a sample Office 365 Connector

* Small fixes to Office365.Connectors sample

* Anonymized config file.

* Added readme.md

* Updated PnP Core library to laterst version, fixed issue with JSON.NET. Fixed "UIVersion" error. (pnp#1570)

Closes pnp#1569

* Updated webcast link to readme

* December 2016 release

* ASP.NET Core Authentication - remove Microsoft.IdentityModel.Extensions.dll dependency (pnp#1572)

* AspNetCore Auth - Added a NuGet and NuSpec files

AspNetCore Auth - Added a NuGet and NuSpec files to reference the OfficeDevPnP.Core.Framework.Authentication.dll file in another project

* AspNetCore Auth - updated readme.md to clarify RTM support

* Cleanup and changed version to 1.1.0

* Work on removing Microsoft.IdentityMode.Extensions dependency

* Cleaned up SSL error catch

* Removed Microsoft.IdentityModel.Extensions.dll :)

* Updated readme with latest information and links

* Fix deploy cmdlets (pnp#1580)

* Fix changes in the cmdlets from *-SPO* to *-PnP*

* typo

* Fix changes in the cmdlets from *-SPO* to *-PnP*

* Remove DLL

* Remove DLL

* Fixed small md format issue

* January 2017 release

* Updated to use CSOM from SPO NuGet package. packages.config was for some reason missing.

* TaxonomyPicker: raise change event on hidden field (pnp#1591) (pnp#1592)

Raise the 'change' event on the hidden input field every time the value
changes

* Updated the solution with TypeScript 2.1.15 and PnPJs Core 2.0.0 + Fixed some typos

* Refactored the solution for SharePoint 2013. Used sp-pnp-js 1.0.6 instead of 2.0.0 because of wrong Webpack output (the 2.0.0 adds "const" in the outputed JS file).

* Fixed a bug in the pageInfo component due to SharePoint 2013 (the JSON response is different from SharePoint Online)

* Added refactoring notes for SharePoint 2013.
Updated the README file for installation.

* Updated the folder structure

* Updated the README.md to link with the refactoring notes.

* Updated the refactoring notes to add the October 2016 CU.

* Updated gitignore to include dlls

* Added dlls for extensibiliy provider

* Updated NuGet and modified code to be more flexible

* Fixed typos in the deployment script

* Updated readme based on issue pnp#1558

* Updated settings and tested for SPO

* Updated NuGet packages

* Added the SharePoint Online folder with the dedicated solution.
For now, the JS code is the same between the SharePoint Online and the SharePoint 2013 solution. Only the deployment is different.
Fixed a bug with the page layouts. The PnP token {contenttypeid:Page Layouts} is not applied (using the version 2.11.1701.1 of the PnP cmdlets). Replaced with the hard coded ContentTypeId value for page layouts (fixed also in the SharePoint 2013 RootSiteTemplate.xml file).

* Updated the README file for the SharePoint 2013 solution

* Updated file upload limit description to be more precise

* Fixed the master page content type id value for the template.
Updated the solution to be compatible with SharePoint 2013/2016 and Online.
All page layouts and master pages reference the 15.0.0.0 version to be compatible. No need to use the 16.0.0.0 version.
No webparts for now. Wait for the PnP fix (10th February).

* Fixed typos.

* Merged all the solution into a single folder (no more folder for each versions).

* Updated images and README.md
Updated folders to lower case

* Reset the folder

* Clean commit with remaned folders

* Clean commit with remaned folders

* Fixed some typos in the README.md file

* Updated the prerequisites about MMS for on-premises deployments in the README file

* Added missing image

* Updated README file

* Update LICENSE

* Added webparts to the PnP provisioning template for aspx pages. Webparts provisioning does not work with SharePoint 2013/2016 on-premises with the PnP Juanuary 2017 release (issue pnp/PnP-Sites-Core#866).

* Fixed typos

* Added webparts to the PnP provisioning template for aspx pages (pnp#1602)

* Added webparts to the PnP provisioning template for aspx pages. Webparts provisioning does not work with SharePoint 2013/2016 on-premises with the PnP Juanuary 2017 release (issue pnp/PnP-Sites-Core#866).

* Fixed typos

* Last minute fix for the assembly version of webparts in the provisioning template. We need to target the right assembly version according to the SharePoint version.

* Fix for PnP Intranet for webparts assembly version (pnp#1604)

* Added webparts to the PnP provisioning template for aspx pages. Webparts provisioning does not work with SharePoint 2013/2016 on-premises with the PnP Juanuary 2017 release (issue pnp/PnP-Sites-Core#866).

* Fixed typos

* Last minute fix for the assembly version of webparts in the provisioning template. We need to target the right assembly version according to the SharePoint version.

* Script bundling support for resources js (pnp#1593) (pnp#1596)

Instead of always loading the resources file via jQuery ajax, the global
namespace is first checked for the presence of the resources. If it's
there, then do not load the resources. This allowes pre-loading the
resources in the page.

* February 2017 release

* Fixed merge issue

* February 2017 release

February 2017 release

* Updated for the Feb release

* February 2017 release

* Updated readme to cross reference the webhook guidance

* Fixed TypeScript version to 2.2.0. The 2.2.1 version seems to have issues with the whatwg types (refer to SharePoint/PnP-JS-Core#331) (pnp#1615)

* Updated properly to VS2015 version

* Added simplistic sample on how to use SharePoint REST APIs from console application to provision modern team site with associated Office 365 group

* March 2017 release

* update pnp.js for latest version 2.0.2

* Sample showing how to use the PnP Support for programming modern pages

* Updated the PnP PowerShell commands used to use the new PnP prefix instead of the SPO so they will remain working once these are retired in June (pnp#1636)

* Change ps credential to web login (pnp#1637)

* Updated the PnP PowerShell commands used to use the new PnP prefix instead of the SPO so they will remain working once these are retired in June

* I suggest switching from credentials in the Connect-PnPOnline to a -UseWebLogin as that covers all scenarios, also the (hopefully) more likely one of using MFA which won't work with the current Credentials option

* TaxonomyPicker without JSOM (pnp#1640)

* Added MVC based TaxonomyPicker wich requires no add-in web

* Added Documenttation

* added documentation file

* updated documentation

* updated documentation again....

* again

* again

* and again..

* Updated Documentation

* Updated Documentation

* Folder rename for new taxonomy picker sample and added tracking image for usage details

* Add in permissions (pnp#1628)

* Removed Web Full Control and Sitecollection Full Control as it makes no sense since there's already Tenant FullControl

* Removed Web Full Control and Site Full Control permissions as it makes no sense since Tenant Full Control is already being requested

* Removed csproj reference to the missing TeamSiteSubSiteTemplate.xml file so at least it compiles again (pnp#1629)

* Removed commented out ClientSecret. Should be in appSettings.config anyway and someone left his ClientSecret commented out in the web.config. (pnp#1630)

* Added Dutch translation (nl-NL) (pnp#1631)

* Added Dutch translation (nl-NL)

* Fixed language error based on feedback from Erwin

* April 2017 release

* Update summary text for smoother reading (pnp#1651)

Updating summary text on README.md for smoother syntax and language.

* Mvc taxonomy picker updated (pnp#1644)

* No more ViewModel so it´s now MVC not MVVM.
Updated so that validation works for the hidden inputs

* updated documentation for cascading taxonomypickers

* updated documentation again

* fixed setting values from the controler

* fixed nullvalue for EditorTemplate Model

* Support for loading default value by label only (pnp#1646)

New option 'initialLabels' to allow loading defaults by label, where the
initial IDs are not known.

* Update tsconfig.json (pnp#1655)

Fix for Issue pnp#1645

As proposed by https://github.com/jbarrar

* May 2017 release

* Update ManagedMetadata.js (pnp#1657)

When the taxonomy field was null, the cascading drop downs were not rendered correctly. Only an empty drop down field was shown with message "Loading...."

* PnP Starter intranet v1.3 (pnp#1659)

* Initial commit for the starter intranet v1.3 solution

* UI updates

* Added missing files

* Added flag icons for the language switcher component

* Updated the deployment script + bug fixes

* Added missing files for the flags sprite

* Removed unused parameter from the provisioning template
Updated package.json information

* Added the bot chat panel. Need some branding and rework.

* Optimized sp-pnp-js imports (import only needed namespaces).

* Added the logic to see if the bot configuration has been set.

* Added the bot link in the header links.

* Added the locale support for the bot chat control.
Added a description for the HideSideBar field.

* Optimized the webpack bundle size

* Added missing fields for Bot configuration in the provisioning template.

* Updated the provisioning schema for the IntranetContact column (default value doesn't work with SharePoint 2013).
Removed the intranet logo file.

* Updated the search schema and display templates to replaced the EndDateOWSDATE by RefinableString05. In SharePoint Online, this managed proeprty doesn't exist anymore...
CSS updates
Updated images in the README file

* Updated the README file with the bot integration gif.

* Changed the release date in the README file

* Updated the README file

* Fixed script exception by adding a variable in front of Add-PnPFile (pnp#1663)

* Initial release

* Fixed formatting issues

* Updated readme content

* Updated readme content

* Fix bug when filterTerm == undefined due to .Name being used (pnp#1665)

* added userInfo control

* merge of pr1675

* June 2017 release

* Dal (pnp#1678)

* Corrected stock ticker control to use intended storage.

* formatting issue

* Updating NuGet packages for provisioning console sample

* fix typos (pnp#1685)

* Updated to show new capabilities

* August 2017 release

* RemoteCalendarAccess: fixed WKST casing in RRULES (pnp#1690)

* Updated sample to work with latest PnP Sites Core nuget package

* September 2017 release

* Cleaning intranet v2

* Intranet v2.0 release from Franck Cornu

* September 2017 release

* PnP Starter Intranet 2.0 - New folder (Business.SharePointIntranet) (pnp#1697)

* Removed previous code

* Added the code for the v2.0 of the PnP Starter Intranet Solution

* Updated README

* Fix button alignement

* PnP Starter Intranet v2.0 release

* Deleted old folder "Business.StarterIntranet" and created a new one for the version 2.0.0

* Reverted back to the original folder name

* September 2017 release

* PnP Starter Intranet  - Replaced the Myriad font by Segoe UI from Office UI fabric due to licence restriction. (pnp#1701)

* v1 of the Multi-Geo developer samples. Aligns with guidance provided via https://aka.ms/multigeo-developer-guidance

* Removing solution documentation section from the readme due business references

* September 2017 Release

* Adding simple console application for creating  Comm sites with REST API

* Wording update in readme for communication site rest api sample

* October 2017 release

* Added link to the associated blog post (pnp#1714)

@vesa I didn't see you striped out this part. Can I have at least a link to my own blog to indicate there is actually a documentation available?

Thanks!

* October 2017 release

* Added telemetry

* Added telemetry support

* Added telemetry

* Update to include new csom approach for getting personalsitehost

* New solution: Governance.EnsurePolicy

* November 2017 release

* Added the link to the associated PnP Webcast Youtube video (pnp#1720)

* Added the link to the associated PnP Webcast Youtube video (pnp#1720) (pnp#1722)

* November 2017 release

* November 2017 release

* Initial commit of Provisioning.CreateModernSites sample

* Added support for provisioning templates to Provisioning.CreateModernSites sample application.

* linking readme to new articles on docs.microsoft.com

* Code complete for Provisioning.CreateModernSites sample application.

* Code Fixup for Provisioning.CreateModernSites sample project

* Final stage of Provisioning.CreateModernSites: documentation

* Small fix to Provisioning.CreateModernSites documentation

* Small fixes to provisioning code of Provisioning.CreateModernSites sample

* Updated descriptions and small fix to the ModernSitesHelper class.

* Renamed projects, fixed webjob, removed site classification

* All good, just waiting for next SharePointPnP Core Library.

* December 2017 release

* December 2017 release

* Updated sample Provisionig.Cloud.Modern.Async with SharePoint PnP Core Library v. 2.21.1712.2

* Added more details to the Provisioning.Cloud.Modern.Async README.md file

* December 2017 release

* Fixed bug pnp#1736 when "PublishingImage" property was not present on the search item result. Added an "if" condition before displaying the HTML markup.

* January 2018 release

* Asp net core.2.0.authentication (pnp#1698)

* Visual Studio 2017 one way upgrade of xproj to csproj

* Updated to work with .net core 2.0 authentication changes.

* Update README.md

Updated version history and code examples

* Reverted AspNetCore.Mvc.StarterWeb to use localhost Kestrel web server instead of Azure App Service.
Reverted to .NET Framework 4.6.1 from 4.7
Removed IgnoreSslErrorsConnectionFilter.cs as it is no longer used.
Added OfficeDevPnP.Core.Framework.Authentication.2.0.0.nupkg nuget package.

* PnP Starter Intranet - Migrate to 2.1.0 version

* Updated screenshots in the README file.

* PnP Starter Intranet - Updated README file.

* PnP Starter Intranet - Added people search experience screenshot (desktop)

* PnP Starter Intranet - Fixed typos in the README file

* February 2018 release

* Sample extensibility provider to extract pages

* [PnP Starter Intranet] Added an unique identifier (the site collection relative URL) in the local storage values for navigation. now we are able to browse multiple instances of the solution within the same browser without navigation conflicts + minor fixes.

* New sample shows how to discover a multi-geo setup using the CSOM API

* Added PnP changelog

* Updated CHANGELOG.md to be up to date with all pending March release changes

* updated to be aligned for March release

* sample does compile with latest csom redist

* Modern and automated provisioning by using a Bot, Flow, Azure Function and SPFx (pnp#1759)

* first commit

* added the readme with a first description

* added more descriptions

* Added microsoft flow package

* new powershell script to create the list, readme updated and minor improvements

* readme updated

* images added

* uupdated

* minor changes

* updated

* solution architecture added

* Added telemetry and blog post url

* updated

* prep release notes for release

* March 2018 release
  • Loading branch information
AKrasheninnikov committed Mar 15, 2018
1 parent aef4d99 commit d5e365a
Show file tree
Hide file tree
Showing 10,859 changed files with 2,208,223 additions and 266,676 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
42 changes: 42 additions & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
Thank you for reporting an issue or suggesting an enhancement. We appreciate your feedback - to help the team to understand your needs, please complete the below template to ensure we have the necessary details to assist you. If you have a actual question, we would ask you to use [SharePoint Developer Group](http://aka.ms/sppnp-community) at Microsoft Tech Community. Thanks!

####Which PnP repository should you use to report the issue?####
*Please navigate to the appropriate repository by clicking on the link below and create your issue there. You can delete this section after you have navigated to the correct repository.*

- PnP Samples - https://github.com/OfficeDev/PnP
- PnP Sites Core - https://github.com/OfficeDev/PnP-Sites-Core
- PnP JS Core - https://github.com/OfficeDev/PnP-JS-Core
- PnP PowerShell - https://github.com/OfficeDev/PnP-PowerShell

#### Category
[ ] Bug
[ ] Enhancement

#### Environment
[ ] Office 365 / SharePoint Online
[ ] SharePoint 2016
[ ] SharePoint 2013

If SharePoint on-premises, what's exact CU version:

#### Expected or Desired Behavior
_If you are reporting a bug, please describe the expected behavior. If you are suggesting an enhancement please
describe thoroughly the enhancement, how it can be achieved, and expected benefit._

#### Observed Behavior
_If you are reporting a bug, please describe the behavior you expected to occur when performing the action. If you are making a suggestion, you can delete this section._

#### Steps to Reproduce
_If you are reporting a bug please describe the steps to reproduce the bug in sufficient detail to allow testing. Only way to fix things properly, is to have sufficient details to reproduce it. If you are making a suggestion, you can delete this section._

#### Submission Guidelines
_Delete this section after reading_
- All suggestions or bugs are welcome, please let us know what's on your mind.
- If you are reporting any issues around PnP Core Component, please reproduce the issue with latest release.
- If you are reporting issue around PnP Provisioning Engine, please share the xml template, if possible.
- If you are reporting an issue around any of the samples, please ensure that you have clear reference on the sample and possibly code file, which should be fixed.
- If you have a general question, please use the [SharePoint Developer Group](http://aka.ms/sppnp-community) at Microsoft Tech Community.
- Remember to include sufficient details and context.
- If you have multiple suggestions or bugs please submit them in seperate bugs so we can track resolution.

Thanks for your contribution! Sharing is caring.
16 changes: 16 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
| Q | A
| --------------- | ---
| Bug fix? | no - yes?
| New feature? | no - yes?
| New sample? | no - yes?
| Related issues? | fixes #X, partially #Y, mentioned in #Z

#### What's in this Pull Request?

Please describe the changes in this PR. Sample description or details around bugs which are being fixed.


#### Guidance
*You can delete this section when you are submitting the pull request.*
* *Please update this PR information accordingly. We'll use this as part of our release notes in monthly communications.*
* *Please target your PR to Dev branch.*
10 changes: 9 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -172,4 +172,12 @@ UpgradeLog*.htm

# Microsoft Fakes
FakesAssemblies/
OfficeDevPnP.Core/OfficeDevPnP.Core.Tests/App.config

# Visual Studio 2015 cache/options directory
.vs/

# Prevent the checkin of publishing settings as they typically contain environment
# specific information which should not be in the repo
*.pubxml
/Solutions/BusinessApps.HelpDesk/BusinessApps.HelpDesk
/Samples/Provisioning.Cloud.Async.WebJob
Binary file removed Assemblies/15/Microsoft.Office.Client.Education.dll
Binary file not shown.
Binary file removed Assemblies/15/Microsoft.Office.Client.Policy.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed Assemblies/15/Microsoft.SharePoint.Client.Search.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed Assemblies/15/Microsoft.SharePoint.Client.dll
Binary file not shown.
Binary file removed Assemblies/16/Microsoft.Office.Client.Policy.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed Assemblies/16/Microsoft.SharePoint.Client.Search.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed Assemblies/16/Microsoft.SharePoint.Client.dll
Binary file not shown.
11 changes: 0 additions & 11 deletions Assemblies/readme.md

This file was deleted.

Binary file not shown.
Binary file not shown.
4 changes: 0 additions & 4 deletions Binaries/readme.md

This file was deleted.

20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# PnP Changelog
*Please do not commit changes to this file, it is maintained by the repo owner.*

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).

## [March 2018]

### Added

- New solution O365.Modern.Provisioning: demonstrates how to integrate a typical enterprise scenario where the user can submit a creation's request for a new SharePoint team site, communication site or a Microsoft team through a node.js Bot (App Only) which is available on Teams, Skype, Direct line and so on
- New sample MultiGeo.TenantInformationCollectionCSOM: shows how to use CSOM to get geo location details for a multi-geo tenant
- New sample Provisioning.Extensibility.Pages: an extensibility handler that exports all client side pages of a site

### Changed

- Updated the Business.StarterIntranet solution: avoid conflicts in local storage data when using multiple instances of the solution

### Deprecated
164 changes: 164 additions & 0 deletions Components/Core.DocumentPicker/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
# Document picker for provider hosted apps #

### Summary ###
This control is used to browse documents that are stored in document libaries in SharePoint. It can show multiple document libraries in 1 tree structure. If you click on one of the selected documents, it will open. It is possible to configure filters on document extensions and specify the number of selected files. There is support for a custom datasource that you can implement yourself to get data from sources that the control itself does not support.

### Prerequisites ###
It's important that the provider hosted add-in that's running the document picker is using the same IE security zone as the SharePoint site it's installed on. If you get "Sorry we had trouble accessing your site" errors then please check this.

### Solution ###
Solution | Author(s)
---------|----------
Core.DocumentPicker | Stijn Neirinckx

### Version history ###
Version | Date | Comments
---------| -----| --------
1.0 | November 5th 2014 | Initial release

### Disclaimer ###
**THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**


----------

# HOW DOES THE DOCUMENT PICKER WORK? #
The document picker control makes it possible to browse one or more document libraries and select documents. An examle would be a provider hosted application in which create PDF's from existing documents: you could then use this document picker control to select the needed documents. Below picture shows the control on the page:

![Document picker UI](http://i.imgur.com/OmGyuNE.png)

One you click on the *document* icon right to the control a dialog opens in which you select documents:

![Selection of documents from library](http://i.imgur.com/gvVLyJj.png)

# HOW TO USE THE DOCUMENT PICKER IN YOUR PROVIDER HOSTED SP ADD-IN? #
Below you can find the steps needed to get the control working

## ENSURE YOU TRIGGER THE CREATION OF AN ADD-In WEB ##
When you build a provider hosted add-in it does not necessarily have an add-in web associated with it whereas a SharePoint hosted add-in always has an add-in web. Since the document picker control uses the CSOM object model from JavaScript it’s required to have an add-in web. To ensure you have an add-in web you can just add a empty element to your SharePoint add-in as shown below:

![Visual Studio project UI with an arrow pointing to element.xml](http://i.imgur.com/DYnXn5E.png)

## SETTING UP THE HTML ##
Add refences to javascript and css files to make the control work. The app.js file will be used to write our app specific code.

```ASPX
<link href="../Styles/documentpicker/documentpickercontrol.css" rel="stylesheet" />
<script type="text/javascript" src="../Scripts/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="../Scripts/MyCustomDocumentPickerDataSource.js"></script>
<script type="text/javascript" src="../Scripts/documentpickerdatasource.js"></script>
<script type="text/javascript" src="../Scripts/documentpickercontrol.js"></script>
<script type="text/javascript" src="../Scripts/app.js"></script>
```

We also need to add html on the page where we want the control to render. The control will be rendered inside the div. The heigth and width styling on the div determines the size of the control. The hiddenfield is used to get or set selected documents from the server.

```ASPX
<div id="BasicDocumentPicker" style="width:350px;height:100px;float:right"></div>
<asp:HiddenField runat="server" ID="BasicDocumentPickerValue" />
```

## CREATE THE CLIENTCONTEXT OBJECT ##
Below code shows how to load the relevant SP js files and how to create the cliencontext object. The clientcontext object is created is such a way (see the ProxyWebRequestExecutorFactory that's being hooked up) that it can be used in cross domain scenarios which will be the case when you’re integrating your provider hosted add-in via a dialog in SharePoint. The appContextSite is used to communicate to the hostweb (if your lists are located there). You need to add this code to your app.js file.

```JavaScript
$(document).ready(function () {

//Get the URI decoded SharePoint site url from the SPHostUrl parameter.
var spHostUrl = decodeURIComponent(getQueryStringParameter('SPHostUrl'));
var appWebUrl = decodeURIComponent(getQueryStringParameter('SPAppWebUrl'));
var spLanguage = decodeURIComponent(getQueryStringParameter('SPLanguage'));

//Build absolute path to the layouts root with the spHostUrl
var layoutsRoot = spHostUrl + '/_layouts/15/';

//load all appropriate scripts for the page to function
$.getScript(layoutsRoot + 'SP.Runtime.js',
function () {
$.getScript(layoutsRoot + 'SP.js',
function () {
//Load the SP.UI.Controls.js file to render the add-in Chrome
$.getScript(layoutsRoot + 'SP.UI.Controls.js', renderSPChrome);

//load scripts for cross site calls (needed to use the document picker control in an IFrame)
$.getScript(layoutsRoot + 'SP.RequestExecutor.js', function () {
context = new SP.ClientContext(appWebUrl);
var factory = new SP.ProxyWebRequestExecutorFactory(appWebUrl);
context.set_webRequestExecutorFactory(factory);
var appContextSite = new SP.AppContextSite(context, spHostUrl);
});

});
});
});
```

## TRANSFORM THE HTML INTO A DOCUMENTPICKER CONTROL ##
The final step is to transform the HTML inserted in the previous step into a document picker control. This is done by creating an instance of the documentpicker JavaScript class and providing it a reference to the HTML elements. The control gets data using a datasource. With the default datasource you can get data using a array of list titles or list id's.

```JavaScript
//param1: context of the site to get lists (host or add-in web)
//param2: array of library titles or ID's, to use in the control
//param3: type of identifier passed in the above parameter (possible choises= 'TITLE' or 'ID')
var basicDocumentPickerDatasource = new CAMControl.DocumentPickerDataSource(context, ["DocumentPickerDocLib"],"TITLE"); //pass list titles to find lists

basicDocumentPicker = new CAMControl.DocumentPicker();
//param1: id of div hosting this control
//param2: id of hiddenfield to store values
//param3: datasource to get the data (created above)
basicDocumentPicker.Initialize("BasicDocumentPicker", "BasicDocumentPickerValue", basicDocumentPickerDatasource);
```

# DOCUMENTPICKER CONFIGURATION OPTIONS #
The document picker control does have some configuration options which are explained below.

## LANGUAGE ##
The strings displayed by the control will be loaded dynamically based on the passed language. This requires you to pass the language via taking over the SPLanguage url parameter (see sample) or by hardcoding it. If no language is passed the control assumes the language is English.

```JavaScript
documentPickerWithOptions.Language = "en-us";
```

If you would like to add additional languages you need to create the appropriate JavaScript language resource files:

![Resource JS list](http://i.imgur.com/umTeI0h.png)

Such a resource file is simple collection of global variables:

![English variables](http://i.imgur.com/rLG8HbO.png)

![Dutch variables](http://i.imgur.com/SVQmC4f.png)

## SHOW MULTIPLE DOCUMENT LIBRARIES IN ONE TREE ##
The control is able to show multiple document libraries in the same treeview. Just pass a array of the list titles or id's to the documentpickerdatasource. Be sure to specify in the last parameter that you are passing ID's or Titles.

```JavaScript

//param1: context of the site to get lists (host or add-in web)
//param2: array of library titles or ID's, to use in the control
//param3: type of identifier passed in the above parameter (possible choises= 'TITLE' or 'ID')
var documentPickerWithOptionsDataSource = new CAMControl.DocumentPickerDataSource(context, ["DocumentPickerDocLib", "DocumentPickerDocLibExtra"], "TITLE"); //pass id's instead of titles
```

## MAXIMUM NUMBER OF FILES ##
This property sets the maximum number of files that can be selected in the control.

```JavaScript
documentPickerWithOptions.MaximumNumberOfFiles = 2; //only allow 2 documents to be selected
```

## FILTER ON DOCUMENT EXTENSION ##
If you set this property, only the documents matching that extension are shown in the control. This property is set on the datasource.

```JavaScript
documentPickerWithOptionsDataSource.AllowedFileTypes = ["docx", "xlsx"]; //only show docx and xlsx documents in picker
```

## EXPAND FOLDERS ##
If this setting is set to true, the folders will be expanded by default. If set to false, they will be collapsed.

```JavaScript
documentPickerWithOptions.ExpandFolders = false; //show the folders collapsed when dialog is opened
```

<img src="https://telemetry.sharepointpnp.com/pnp/components/Core.DocumentPicker" />

0 comments on commit d5e365a

Please sign in to comment.