彩虹底紋ppt模板:企業(yè)內(nèi)容管理系統(tǒng)流程透視Alfresco_第1頁(yè)
彩虹底紋ppt模板:企業(yè)內(nèi)容管理系統(tǒng)流程透視Alfresco_第2頁(yè)
彩虹底紋ppt模板:企業(yè)內(nèi)容管理系統(tǒng)流程透視Alfresco_第3頁(yè)
彩虹底紋ppt模板:企業(yè)內(nèi)容管理系統(tǒng)流程透視Alfresco_第4頁(yè)
彩虹底紋ppt模板:企業(yè)內(nèi)容管理系統(tǒng)流程透視Alfresco_第5頁(yè)
已閱讀5頁(yè),還剩32頁(yè)未讀 繼續(xù)免費(fèi)閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)

文檔簡(jiǎn)介

1、Alfresco from an agile framework perspectiveJeff PAgenda Patterns of Alfresco Customization A Tale of Two Frameworks: Surf vs. Django Heavy Share Customization: A real-world example Conclusions & AdvicePATTERNS OF ALFRESCO CUSTOMIZATIONCustom Alfresco Patterns Non-Alfresco framework on top of Al

2、fresco Surf on top of Alfresco Light Share Customizations Heavy Share CustomizationsPatterns we arent going to talk about: Explorer client customizations Portal integration Embedded AlfrescoSource: thomas hawkNon-Alfresco FrameworkSource: Optaros+Surf on AlfrescoSource: OptarosLight Share Customizat

3、ionsHeavy Share CustomizationsA TALE OF TWO FRAMEWORKSSurf or Something Else? Share is a popular, extensible client with a great UI When Share is too much or too far from your business requirements Which framework on top of Alfresco? An experimentSource: irargerichA word on agile frameworks Agile fr

4、ameworks and scripting languages are very popular Examples: Rails, Grails, Django, Wicket, Symfony, Cake, etc. Productive, fast dev cycles Built-in Bootstrapping, ORM, MVC, tests/fixtures, administrative UIs Hundreds available across everylanguage imaginable Can be trendy, like frozen yogurtSource:

5、mswineCommon requirements Let content authors create chunks and upload files Chunks and files get tagged and categorized Not all objects have files-the UI cant freak out when it comes across content-less objects Front-end web site needs to be able to query for chunks, files, and content-less objects

6、 The front-end web site cannot look like Share Our users arent teams They dont care about “document libraries”A simple example: To DoBasic requirements End users create/manage to do list items To do list items are tagged End users can upload documents related to To DosExtended requirements Certain c

7、ategories of To Do Lists have associated content chunks that need to be displayed. Example: To do list that is categorized as Writing should display with content chunks that give advice on writing. Groupings of To Do lists Friends/Co-workers Projects, etc. RSS feedsApproaches To Dos, Users, and File

8、s are objects. Ill map URLs to various views on those objects. Ill probably use a relational database to persist everything except the files, which Ill let my framework handle. Files are documents. Thats easy. To Dos are “content-less” objects. I need to figure out a folder for all of this stuff to

9、live in and how I want to relate To Dos to files. Ill map URLs to various views which will request data from the repository via REST.Five-minute look at Django Creating a new Django app Defining a content model Creating a template Model View Controller Using the admin site to edit object instancesSo

10、urce: William GottliebFun Django Facts: Started as an internal project in 2003 at the Journal-World newspaper (Lawrence, KS) Named after jazz guitarist, Django Reinhardt The Onion recently migrated to Django from DrupalModelfrom django.db import modelsfrom django.contrib.auth.models import Userfrom

11、datetime import date, datetimeclass ToDoItem(models.Model): title = models.CharField(max_length=200) dueDate = models.DateField(default=date.today() priority = models.IntegerField(default=3) status = models.TextField() notes = models.TextField() createdDate = models.DateTimeField(default=datetime.to

12、day() creator = models.ForeignKey(User, related_name=todo_creator) assignee = models.ForeignKey(User, null=True, blank=True, related_name=todo_assignee) #attachments = Document # Array of CMIS documents def _unicode_(self): return self.titleclass Tag(models.Model): name = models.CharField(max_length

13、=64, unique=True) toDoItems = models.ManyToManyField(ToDoItem) def _unicode_(self): return models.pyURLs map to Viewsurlpatterns = patterns(, (radmin/, include(admin.site.urls), (r$, main_page), (ruser/(w+)/$, user_page), (rlogin/$, django.contrib.auth.views.login), (rlogout/$, logout_page)

14、, (rregister/$, register_page), (rregister/success/$, direct_to_template, template: registration/register_success.html), (rcreate/$, todo_create_page), (rsave/(d+)/$, todo_save_page), (rsite_media/(?P.*)$, django.views.static.serve, document_root: site_media), (rtag/(s+)/$, tag_page), (rtag/$, tag_c

15、loud_page),)settings.pydef user_page(request, username): user = get_object_or_404(User, username=username) todos = user.todo_assignee.order_by(-id) variables = RequestContext(request, username: username, todos: todos, show_tags: True, show_assignee: False, show_creator: True, show_edit: username = r

16、equest.user.username, ) return render_to_response( user_page.html, variables )views.py Django To Dos | % block title % endblock % home % if user.is_authenticated % welcome, user.username ! | new to do | logout % else % login register % endif % % block head % endblock % % block content % endblock % b

17、ase.html% extends base.html % block title % username % endblock % block head %To Dos for username % endblock % block content % % include todo_list.html % endblock %user_page.html% if todos % % for todo in todos % todo.title % if show_edit % todo_list.htmlTemplate InheritanceAlfresco approach Content

18、 Consumer UI Custom Surf pages/templates/components for the front-end user interface Administrative UI Lightly-customized Alfresco Share Data Persistence Custom content model for properties, associations (To Do data list happens to already exist) Document library for files and content chunks Data Li

19、st objects for To Do items Rule on a folder to add taggable and classifiable aspects to new objectsAlfresco approach Business Logic Share web scripts to generate UI and handle form posts Repo web scripts to handle JSON POSTs that create new data (file upload, new to do) Repo web scripts to handle GE

20、Ts that retrieve existing data (chunks for a given category, to do list info) JavaScript for all web-tier and repo-tier web script controllers (fast dev, cuts down on restarts)Demo: A tale of two frameworks Share site Data list content model Surf pages & web scripts (XML, FreeMarker, JavaScript)

21、 Repository web scripts (minimal) Surf config Alfresco user factory Share config (minimal) RDB back-end Schema managed by Django Python classes Model Controllers (“Views”) Forms URL mapping Admin UIWork Remaining Add file upload to both Django and Alfresco To Dos Django has a File type Django suppor

22、ts custom File Managers (Hello, CMIS!) Refactor django-alfresco to use CMIS; e.g., CmisDocument type Add “categorizable chunk” to both Search Friends listSource: jphilipgComparison Both have decent tooling pydev for Django Eclipse/STS, Roo, Maven, Ant for Alfresco Model, forms, query much easier in

23、Django “Learning where stuff goes” Much faster in Django Surf documentation is “still evolving”Source: TheBusyBrainTo Do Demo AppAlfrescoDjangoNumber of files7523Alfresco # of Files by TypeDjango # of Files by TypeComparison (contd) Gotchas Lack of query-able associations in DM repo was painful Add

24、user to Share site on user registration post Create a rule on the data list folder to set owner Keep track of assignee add/remove Attempt to simplify actually made Surf site harder Forms without JavaScript No pickers Not fully leveraging Alfrescos form serviceSource: automaniaTo Do DemoAlfrescoDjang

25、oLines of Code1,578674Alfresco LOC by TypeDjango LOC by TypeHEAVY SHARE CUSTOMIZATIONA real-world exampleSaaS platform wants a community site with resources their customers need to leverage the platform betterContent chunks & filesDiscussion threads, blogsEverything tagged against multiple taxon

26、omiesConsumer UIContent Management / Admin UIArchitectureLightly customized ShareAdmin UIConsumer UIHeavily customized ShareContent ModelBehaviorsRulesWeb ScriptsThemeYUIForm ServiceWeb ScriptsContent ManagersCommunity UsersData ModelGlobal Share SiteClient Share SitesProject Share SitesUsers & GroupsClient ID on cm:userOne group per clientClient Data ListSnippets & Resourc

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。

評(píng)論

0/150

提交評(píng)論