Templates and Features – The Engine Under the SharePoint

Download Report

Transcript Templates and Features – The Engine Under the SharePoint

Provide strategies for developing templates, definitions, and features
Best practices for deploying code to a SharePoint farm
Understand the relationships between definitions,
templates, features, and solutions
Introduction to development tools such as Windows SharePoint
Services Extensions for Visual Studio .NET, ECM Starter Kit,
and SharePoint Solution Generator
A Vice President of Litware has been
given a demo by the IT department
Impressed with the use of
Microsoft Office SharePoint
Server for managing
job openings
Open positions
Candidates resumes
Interview process
The VP Challenge
Can this best practice be made
available to all departments?
Litware has a line-of-business (LOB)
application for job openings
IT department has been using
Team site with list of openings and assigned leads
List of contacts for candidates with resumes
Interview sites with survey, questions, and best practices
The HR department has standard
document templates for
Offer letters
Thank-you letters
etc.
Department Site
A turn-key solution that
List of Job Openings
each department can
decide to enable
Job Opening Site Collection
http://intranet/jobs/4321
on their site
Automatically creates
Job Details
appropriate customizations
Candidates
List of job openings
Workflow to create workspaces
for filling that job
Site collections for each
job where the team
Reviews candidates
Conducts interviews
Provides feedback
Doc Templates
Interview
Guidelines
Calendar
Survey
Best Practices
Interview
Guidelines
Calendar
Survey
Best Practices
Definitions
Templates
Supports Sites and Lists
Supports Sites and Lists
Stored on the file system
Stored in a content database
Created by Developer
Created by a Power User
Enterprise solution
Departmental or niche solution
Controlled deployment
Limited deployment
Some ability to change existing site instances
Each site instance is a copy of the template
The Job Openings Feature
List Instances
Workflow Association
Openings
List Definition
Workflow
Packaged sets of customizations
Can be scoped
Farm
Web Application
Site Collection
Web
Supports dependencies
Hidden and Visible
Build a Job Openings list that
includes LOB integration
Capture it as a list definition
(SharePoint Solution Generator included in Visual
Studio Extensions for WSS)
Build the workflow
(ECM Starter Kit included in MOSS SDK)
Wrap them together with the creation of:
Instance of the job openings list
The task and workflow history list instances
Automatic workflow association
Top-level site contains
Business Data Item Web
Part to show the
details of the job
Filter Web Part that
retrieves JobID from
the property bag
Contacts list for candidates
Site template for interviews
Interview site contains
Survey for feedback
Best practices docs
Calendar
Start with an empty site
Add Web Parts and create contacts list
Capture as a site definition (Solution Generator)
Build custom Web Part to expose
site’s property bag
Visual Studio extensions for
Windows SharePoint Services
Implement Filter interfaces
Insert into the onet.xml file
Save interview site as a site
template and add to the gallery
HR has documents for the interview process
All contain candidate contact data
Provide template for content types
Add a custom action feature to allow the insert
of a contact items into the document
Add a custom XML part to documents
Bind Word content controls
Incorporate them as content types
Use a feature
Add custom action to contact list items
Add custom application page to insert data
Add this feature to the Job Opening Site definition
Goal: Add custom functionality to
“Out of the Box” site definitions
Features work fine but require activation
A custom site definition may be overkill
Answer: Feature Stapling
(a.k.a. “Feature Site Template Associations”)
Farm-scoped feature attaches Web-scoped
feature(s) to specific site definitions
Features automatically activate when a site is created
Site definition can be changed independently
of stapled features
Developer packages their
customizations into a solution
Admin deploys to Web front-end servers
Stored in Config Database
Solutions can contain:
Feature definitions
Site definitions
Template pages and resources
Resources
Global, bin assemblies
Code access security policies
Pro SharePoint Solution Development
Combining .NET, SharePoint, and Office 2007
Topics included:
Microsoft Office
SharePoint Server
Visual Studio Tools for Office
Microsoft Office 2007 system
http://blogs.msdn.com/edhild