SlideShare ist ein Scribd-Unternehmen logo
1 von 32
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 1
Jay Landrum
Co-Founder, Almond Labs
@AlmondLabs
Almond Labs Identity Service Application
Simple external authentication for on premise SharePoint
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 2
Pranav Sharma Eugene Wilson Hector Ramos
Almond Labs
“Working to create products and solutions that improve
user adoption, engagement and productivity with
SharePoint.”
Leveraging
Knockout and
REST in
SharePoint 2013
ALMOND LABS
THURSDAY JUNE 20, 2013
+1 (866) 773-9175 | SALES@ALMONDLABS.COM 36/28/2013
Customizing SharePoint
• SharePoint 2007 – Server side code
• SharePoint 2010 - Client side object model
• CSOM built to support Silverlight but not complete
• SharePoint 2013 - Prioritizes client side
development
• App model
• Office 365 and hosted SharePoint environments
• Search display templates
• List views
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 4
Why client side solutions?
• Fast prototyping and development
• Low impact deployment and updates
• No more recycled app pools!
• No downtime!
• No need to access the server
• Allows significant customizations with just
SharePoint designer
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 5
Required learning
• JavaScript
• jQuery
• Knockout
• JSON
• SharePoint REST Services
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 6
Java… script?
Pros
• Client side code (runs in the browser, not on the server)
• Easy deployment enables quick, iterative development
• Dynamic typing and magic!
Cons
• Development and cross browser support can be
cumbersome
• Getting at back-end data can be difficult
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 7
jQuery
Built on top of JavaScript, jQuery
provides a verb oriented framework
that simplifies almost every aspect of
client side development.
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 8
jQuery
Pros
• Simplifies and enables very quick client side development
• Solves the problem of cross browser support
• Numerous plugins exist to enhance the functionality
• Formally adopted by Microsoft
Cons
• Constantly being supported/updated so you won’t have the
latest version for very long
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 9
Without jQuery
if (!document.getElementsByClassName) {
document.getElementsByClassName = function (cn) {
var allT = document.getElementsByTagName('*'), allCN = [], i = 0, a;
while (a = allT[i++]) {
a.className == cn ? allCN[allCN.length] = a : null;
}
return allCN;
}
}
var flyouts = document.getElementsByClassName("Flyout");
for (var x = 0; x < flyouts.length; x++) {
flyouts[0].styles.display = "none";
}
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 10
With jQuery
$(".Flyout").hide();
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 11
Knockout.js
Knockout provides a complete solution
for using MVVM practices in client side
development, including two way data-
binding and easy extensibility.
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 12
Knockout.js
Pros
• Solves the problem of creating dynamic, data-driven UI’s on the client
side
• Does not depend on jQuery or other libraries
• Very complete and well documented
• Almost forces good development practices
• Adopted by Microsoft
Cons
•Does not integrate with jQuery
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 13
Without Knockout.js
<div id="Container"></div>
<script type="text/javascript">
var data = […];
var ul = document.createElement("ul");
for (var x = 0; x < data.length; x++) {
var li = document.createElement("li");
li.innerHTML = data[x].Name;
ul.appendChild(li);
}
document.getElementById("Container").appendChild(ul);
</script>
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 14
With Knockout.js
<div>
<ul data-bind="foreach: Data">
<li data-bind="text: Name"></li>
</ul>
</div>
<script type="text/javascript">
function ViewModel() {
var self = this;
self.Data = […];
}
ko.applyBindings(new ViewModel());
</script>
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 15
JSON
• Most simply, a way of representing data
• Lightweight and designed to be readable
• Becoming the standard of how data is
passed on the web
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 16
JavaScript Object Notation
• Single record (object)
{
Name: "SharePoint User Group Baltimore",
Description: "Our mission is to bring the..."
}
• Collection of records (array of objects)
[
{
Name: "SharePoint User Group Baltimore",
Description: "Our mission is to bring the..."
},
{
Name: "SharePoint User Group DC",
Description: "A year-round resource..."
}
]
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 17
Demo
• JavaScript
• jQuery
• Knockout
• JSON
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 18
REST-ful web APIs
• REST web API’s provide a technology agnostic method of
interacting with data.
• Generally, API endpoints support Create, Read, Update, and
Delete operations (GET, POST, PUT, DELETE)
• Generally defined by readable Urls
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 19
REST Example
Google Search
https://www.google.com/search?q=Baltimore SharePoint User Group
Google Search API
http://ajax.googleapis.com/ajax/services/search/web?v=1.0&q=Baltimo
re SharePoint User Group
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 20
SharePoint 2013 REST API
All REST endpoint exist under /_api/
(aka /_vti_bin/client.svc)
Some highlights are:
• Retrieving the state of a site, sub site or list
• Retrieving data from a list or document library
• Running search queries
• Read the current user’s social feed
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 21
Tips for the SharePoint API
• Operates similarly to the existing CSOM
• Deferred loading of collections or complex types
• ?expand=<field> query string parameter expands deferred types
• Collections
• For list data, lookup and choice values
• $filter=<query> QS parameter is used to filter returned data
• $select=<fields> QS parameter is used to limit the returned fields
• If possible, use a more specific API endpoint
• Use: /_api/lists(guid’<Guid>’)/Fields
• Instead of: /_api/lists(guid’<Guid>’)?expand=Fields
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 22
Demo
SharePoint search tasks rollup
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 23
SharePoint Customizations
• Search
• Display templates
• Supports customizing specific types of search results
• Common customization: enabling PDF hover panel previews
• List Views
• JSLink property
• Supports customizing entire list views or individual field rendering
• Common customization: creating a simple KPI
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 24
The Best Part
Display templates and customized list views can be
applied through configuration.
List Views
• List View Web Part
Display Templates
• Content Search Web Part
• Search Configuration
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 25
JSLink to Customize List
Views
• Configuration point to register a custom
JavaScript file designed to override the
default behavior of a list, list view or
individual field
• JSLink can be configured
• Through schema (deployed as a feature)
• Through the List View Web Part properties
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 26
Demo
• Task List KPI
• Associated Document Upload
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 27
Search Display Templates
• Configuration point to register a custom
template file (built in JavaScript) to change
the display of search results
• Configured through
• Search Settings
• Content Search Web Part
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 28
Demo
Interactive Search Ratings
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 29
Summary
SharePoint 2013 prioritizes client side development by providing REST
data services and allowing complex customizations without needing
access to the server.
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 30
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 31
References
• SharePoint 2013 REST Services: http://msdn.microsoft.com/en-
us/library/fp142385.aspx, http://msdn.microsoft.com/en-us/library/jj860569.aspx
• SharePoint 2013 Search REST API
http://blogs.msdn.com/b/nadeemis/archive/2012/08/24/sharepoint-2013-search-rest-
api.aspx
•SharePoint 2013 Rest API http://platinumdogs.me/2013/03/14/sharepoint-adventures-
with-the-rest-api-part-1/
• Search keyword query syntax: http://msdn.microsoft.com/en-us/library/ee558911.aspx
• Search Display Templates: http://msdn.microsoft.com/en-us/library/jj945138.aspx
• JSLink feld rendering: http://www.lestersconyers.com/custom-field-rendering-with-jslink/
• JSLink Primer: http://www.idubbs.com/blog/2012/js-link-for-sharepoint-2013-web-
partsa-quick-functional-primer/
• Knockout.js http://knockoutjs.com/
• jQuery http://jquery.com/
6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 32

Weitere ähnliche Inhalte

Kürzlich hochgeladen

Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdfSandro Moreira
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamUiPathCommunity
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 

Kürzlich hochgeladen (20)

Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 

Empfohlen

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by HubspotMarius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 

Empfohlen (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Client Script In SharePoint 2013

  • 1. 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 1 Jay Landrum Co-Founder, Almond Labs @AlmondLabs Almond Labs Identity Service Application Simple external authentication for on premise SharePoint
  • 2. 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 2 Pranav Sharma Eugene Wilson Hector Ramos Almond Labs “Working to create products and solutions that improve user adoption, engagement and productivity with SharePoint.”
  • 3. Leveraging Knockout and REST in SharePoint 2013 ALMOND LABS THURSDAY JUNE 20, 2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 36/28/2013
  • 4. Customizing SharePoint • SharePoint 2007 – Server side code • SharePoint 2010 - Client side object model • CSOM built to support Silverlight but not complete • SharePoint 2013 - Prioritizes client side development • App model • Office 365 and hosted SharePoint environments • Search display templates • List views 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 4
  • 5. Why client side solutions? • Fast prototyping and development • Low impact deployment and updates • No more recycled app pools! • No downtime! • No need to access the server • Allows significant customizations with just SharePoint designer 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 5
  • 6. Required learning • JavaScript • jQuery • Knockout • JSON • SharePoint REST Services 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 6
  • 7. Java… script? Pros • Client side code (runs in the browser, not on the server) • Easy deployment enables quick, iterative development • Dynamic typing and magic! Cons • Development and cross browser support can be cumbersome • Getting at back-end data can be difficult 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 7
  • 8. jQuery Built on top of JavaScript, jQuery provides a verb oriented framework that simplifies almost every aspect of client side development. 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 8
  • 9. jQuery Pros • Simplifies and enables very quick client side development • Solves the problem of cross browser support • Numerous plugins exist to enhance the functionality • Formally adopted by Microsoft Cons • Constantly being supported/updated so you won’t have the latest version for very long 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 9
  • 10. Without jQuery if (!document.getElementsByClassName) { document.getElementsByClassName = function (cn) { var allT = document.getElementsByTagName('*'), allCN = [], i = 0, a; while (a = allT[i++]) { a.className == cn ? allCN[allCN.length] = a : null; } return allCN; } } var flyouts = document.getElementsByClassName("Flyout"); for (var x = 0; x < flyouts.length; x++) { flyouts[0].styles.display = "none"; } 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 10
  • 11. With jQuery $(".Flyout").hide(); 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 11
  • 12. Knockout.js Knockout provides a complete solution for using MVVM practices in client side development, including two way data- binding and easy extensibility. 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 12
  • 13. Knockout.js Pros • Solves the problem of creating dynamic, data-driven UI’s on the client side • Does not depend on jQuery or other libraries • Very complete and well documented • Almost forces good development practices • Adopted by Microsoft Cons •Does not integrate with jQuery 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 13
  • 14. Without Knockout.js <div id="Container"></div> <script type="text/javascript"> var data = […]; var ul = document.createElement("ul"); for (var x = 0; x < data.length; x++) { var li = document.createElement("li"); li.innerHTML = data[x].Name; ul.appendChild(li); } document.getElementById("Container").appendChild(ul); </script> 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 14
  • 15. With Knockout.js <div> <ul data-bind="foreach: Data"> <li data-bind="text: Name"></li> </ul> </div> <script type="text/javascript"> function ViewModel() { var self = this; self.Data = […]; } ko.applyBindings(new ViewModel()); </script> 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 15
  • 16. JSON • Most simply, a way of representing data • Lightweight and designed to be readable • Becoming the standard of how data is passed on the web 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 16
  • 17. JavaScript Object Notation • Single record (object) { Name: "SharePoint User Group Baltimore", Description: "Our mission is to bring the..." } • Collection of records (array of objects) [ { Name: "SharePoint User Group Baltimore", Description: "Our mission is to bring the..." }, { Name: "SharePoint User Group DC", Description: "A year-round resource..." } ] 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 17
  • 18. Demo • JavaScript • jQuery • Knockout • JSON 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 18
  • 19. REST-ful web APIs • REST web API’s provide a technology agnostic method of interacting with data. • Generally, API endpoints support Create, Read, Update, and Delete operations (GET, POST, PUT, DELETE) • Generally defined by readable Urls 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 19
  • 20. REST Example Google Search https://www.google.com/search?q=Baltimore SharePoint User Group Google Search API http://ajax.googleapis.com/ajax/services/search/web?v=1.0&q=Baltimo re SharePoint User Group 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 20
  • 21. SharePoint 2013 REST API All REST endpoint exist under /_api/ (aka /_vti_bin/client.svc) Some highlights are: • Retrieving the state of a site, sub site or list • Retrieving data from a list or document library • Running search queries • Read the current user’s social feed 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 21
  • 22. Tips for the SharePoint API • Operates similarly to the existing CSOM • Deferred loading of collections or complex types • ?expand=<field> query string parameter expands deferred types • Collections • For list data, lookup and choice values • $filter=<query> QS parameter is used to filter returned data • $select=<fields> QS parameter is used to limit the returned fields • If possible, use a more specific API endpoint • Use: /_api/lists(guid’<Guid>’)/Fields • Instead of: /_api/lists(guid’<Guid>’)?expand=Fields 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 22
  • 23. Demo SharePoint search tasks rollup 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 23
  • 24. SharePoint Customizations • Search • Display templates • Supports customizing specific types of search results • Common customization: enabling PDF hover panel previews • List Views • JSLink property • Supports customizing entire list views or individual field rendering • Common customization: creating a simple KPI 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 24
  • 25. The Best Part Display templates and customized list views can be applied through configuration. List Views • List View Web Part Display Templates • Content Search Web Part • Search Configuration 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 25
  • 26. JSLink to Customize List Views • Configuration point to register a custom JavaScript file designed to override the default behavior of a list, list view or individual field • JSLink can be configured • Through schema (deployed as a feature) • Through the List View Web Part properties 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 26
  • 27. Demo • Task List KPI • Associated Document Upload 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 27
  • 28. Search Display Templates • Configuration point to register a custom template file (built in JavaScript) to change the display of search results • Configured through • Search Settings • Content Search Web Part 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 28
  • 29. Demo Interactive Search Ratings 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 29
  • 30. Summary SharePoint 2013 prioritizes client side development by providing REST data services and allowing complex customizations without needing access to the server. 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 30
  • 31. 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 31
  • 32. References • SharePoint 2013 REST Services: http://msdn.microsoft.com/en- us/library/fp142385.aspx, http://msdn.microsoft.com/en-us/library/jj860569.aspx • SharePoint 2013 Search REST API http://blogs.msdn.com/b/nadeemis/archive/2012/08/24/sharepoint-2013-search-rest- api.aspx •SharePoint 2013 Rest API http://platinumdogs.me/2013/03/14/sharepoint-adventures- with-the-rest-api-part-1/ • Search keyword query syntax: http://msdn.microsoft.com/en-us/library/ee558911.aspx • Search Display Templates: http://msdn.microsoft.com/en-us/library/jj945138.aspx • JSLink feld rendering: http://www.lestersconyers.com/custom-field-rendering-with-jslink/ • JSLink Primer: http://www.idubbs.com/blog/2012/js-link-for-sharepoint-2013-web- partsa-quick-functional-primer/ • Knockout.js http://knockoutjs.com/ • jQuery http://jquery.com/ 6/28/2013 +1 (866) 773-9175 | SALES@ALMONDLABS.COM 32

Hinweis der Redaktion

  1. “Leveraging Knockout and REST to enable rich client side customizations in SharePoint 2013”HighlightsReview the technologies used in client side development Show examples of functional solutions developed using these technologies
  2. document.getElementsByClassName() is not supported by IE8This isn’t even the largest example I found online.
  3. Change this transition to type out each individual character.One line of code.
  4. - In previous iterations, Microsoft supplied “Object Model” implementations for specific languages such as .NET and JavaScript.