Presentation is loading. Please wait.

Presentation is loading. Please wait.

Share Site Customizations Live David Erik (UI Team)

Similar presentations

Presentation on theme: "Share Site Customizations Live David Erik (UI Team)"— Presentation transcript:

1 Share Site Customizations Live David Erik (UI Team)

2 What were going to do… Possibilities Unique Organizing Extension points 3 demos = 3 extension modules …customizations applied LIVE! Create your own < 1 hour!

3 Acme Research & Development department Publishes R&D articles Partner portal Casting: Author: Alan Editor: Erik Partner: Patrick

4 Pre Demo: Nothing up our sleeves Alfresco Community 4.2.b (vanilla)

5 Step 1 1.Define R&D projects 2.Make it available

6 Dont worry, be happy!

7 Define R&D projects Site Presets Used in create site dialog Customize using preset-id in evaluators Config template

8 /alfresco/site-data/presets/ acme-rd-presets.xml page.acme-rd-dashboard.title [ { "pageId":"acme-rd-introduction" }, { "pageId":"documentlibrary" } ] Also: Custom properties Rename pages w *-presets.xml (v 4.1)

9 /alfresco/site-data/pages/ acme-rd-introduction.xml 1-column … column /components/wiki/page Tip! (v4.0b) 2-columns 2-columns-resizable 2-columns-narrow-left 3-columns

10 Make preset available Global module:

11 What is an extension module? (v4.0) /alfresco/site-data/extensions/*-extension.xml Add/remove/replace components in a Merge share-config Enhance templates & webscripts: markup / resources / model Module evaluators: site.module.evaluator (v4.0) portal.module.evaluator (v4.0) group.module.evaluator (v4.2b)

12 /alfresco/site-data/extensions/ acme-rd-extension.xml Acme Rd (1) Global changes true org.alfresco acme.rd.customizations

13 /alfresco/site-webscripts/org/alfresco/modules create-site.get.js model.sitePresets.push( { id: "acme-rd-preset", name: msg.get("preset.acme-rd.title") }); /alfresco/site-webscripts/acme/rd/customizations/modules create-site.get.js var sitePresets = [{ id: "site-dashboard", name: msg.get("title.collaborationSite") }]; model.sitePresets = sitePresets; Note! Separate runtime Common model

14 Demo 1: Create R&D project

15 How quick is Dave? …hes smart… %>ant create-project -Dcompany=Acme -Dusecase=RD …

16 Share Namespaced project structure: build targets Spring context file i18n Site preset Sample page & webscript Extension modules Doclib customizations

17 Repository Namespaced project structure: build targets Spring context file Content model Sample repo action Note! Not required…

18 Repository rd:article aspect rd:status property [ Draft | Published ] Repo action marks as Published Alternative solution: Folder rule kicks off a simple workflow

19 Step 2 1.Publishing articles 2.Show article info in the document library 3.Slim down Share for Editors

20 Publishing articles Doclib action SiteManager (editor) R&D Project only Site Preset module:

21 /alfresco/site-data/extensions/ acme-rd-extension.xml Acme Rd (2) Site changes.* acme-rd-preset false.* Actions, indicators etc

22 /alfresco/site-data/extensions/ acme-rd-extension.xml acme.rd.evaluator.doclib.hasArticleAspect acme.rd.evaluator.doclib.isStatusPublished evaluator.doclib.action.isSiteManager Write onActionSimpleRepoAction acme.rd.setPublishedStatus Also: (v4.2b) isSiteConsumer isSiteContributor isSiteCollaborator pagelink / link

23 Show Custom data only in R&D doclibs Indicators Metadata templates

24 /alfresco/site-data/extensions/ acme-rd-extension.xml acme.rd.evaluator.doclib.hasArticleAspect {} Tip! some-indicator-id action attribute

25 /alfresco/site-data/extensions/ acme-rd-extension.xml acme.rd.evaluator.doclib.hasArticleAspect {date}{size} {rd_status acme.rd.metadata.status} Renders objects with: (v4.2b) userName displayName iso8601 title name …or register a custom renderer (v.4.0)

26 Hide Documents for Editors Site Preset module:

27 /alfresco/site-data/extensions/ acme-rd-extension.xml template filter documentlibrary false SiteManager Also: Add & Replace Component evaluators: (v4.0) config.component.evaluator equals.component.evaluator portlet.component.evaluator site.component.evaluator preset.component.evaluator

28 Demo 2: R&D site customizations

29 Step 3 1.Partner portal 2.List R&D Projects 3.Only Published articles 4.inline previewer

30 Partner portal Dashboard page Partner Title List of R&D projects (api/sites?spf=acme-rd-preset) Document Library page Partner Title Document List (customized)

31 /alfresco/site-data/extensions/ acme-rd-extension.xml Acme Rd (3) Partner changes GROUP_Partner AND org.alfresco acme.rd.customizations-partner

32 /alfresco/templates/org/alfresco /dashboard.ftl /alfresco/templates/acme/rd/customizations-partner /dashboard.ftl

33 Only Published docs Custom repository webscript /slingshot/doclib2/acme-rd rd:status == Published Share surf-doclist webscript resolver.doclib.doclistDataUrl

34 /alfresco/site-data/extensions/ acme-rd-extension.xml /alfresco/web-extensions/ acme-rd-share-context.xml acme.rd.doclib.resolver.doclistDataUrl

35 inline previewer Document List viewRenderer Notes from Rays session

36 Demo 3: Partner portal

37 What we have done Site extension project Site Preset Global module Site preset module Group module

38 Start worrying! Engineering sessions Slides & code customizations-live customizations-live Blogs Site Extension project

Download ppt "Share Site Customizations Live David Erik (UI Team)"

Similar presentations

Ads by Google