Documentator: Difference between revisions
m →Theme |
|||
Line 101: | Line 101: | ||
* Copy page templates to your theme folder (e.g. sites/all/themes/my_fablab/) | * Copy page templates to your theme folder (e.g. sites/all/themes/my_fablab/) | ||
page-checkin2.tpl.php page-fabmoments.php | page-checkin2.tpl.php page-fabmoments.php | ||
page-checkin3.tpl.php page-fm.tpl.php | page-checkin3.tpl.php page-fm.tpl.php | ||
page-checkin.tpl.php page-node-add-fm.tpl.php | page-checkin.tpl.php page-node-add-fm.tpl.php | ||
page-checkout2.tpl.php page-node-add-profile.tpl.php | page-checkout2.tpl.php page-node-add-profile.tpl.php | ||
page-checkout3.tpl.php page-user-profile-profile.tpl.php | page-checkout3.tpl.php page-user-profile-profile.tpl.php | ||
page-checkout.tpl.php page-user-register.tpl.php | page-checkout.tpl.php page-user-register.tpl.php | ||
==Workflow== | ==Workflow== |
Revision as of 12:20, 25 April 2011
A placeholder for eventually completing the documentation on the Documentator station at ProtoSpace (Fablab Utrecht, NL)
Files
Various bits and pieces
- templatetweaks.txt
- css.txt
- view_fabmoments_checkin.txt
- view_fabmoments_checkin.txt
- content_profile.txt
- content_fm.txt
- checkinout_pages.txt
- rules.txt
- checkin_log.tar
Concept
...
We're using Drupal, so this writeup is about all the nuts and bolts of Drupal 6 configuration needed to pull off the idea. (other platforms for providing something similar might be developed in the future, depending on need/demand. (you can let me know about need / demand, just email anu at fabfolk dot com)
Modules
A number of Drupal contributed modules were used to produce different parts of the functionality required by the "kiosk" stands A custom module for logging user actions (launched by conditions set by the Rules module) was created. Complete list of modules used (the number may seem large, but many of them are commonly used in any regular Drupal installation)
Core
- PHP filter - needed for some of the processing in the checkin/checkout pages
- Path - needed for setting paths for the checkin & checkout pages
Contrib
- Workflow - for catching system events that can launch actions (such as publishing a FabMoment or logging lab visit)
- Rules - for managing the documentation (FabMoment) states - things should not be published
- Rules Admin UI
- CCK
- Content Copy
- Text field
- Option Widgets
- Content Profile
- Content Profile User Registration
- Node export - useful for importing checkin / checkout page content)
- Token - for replacing tokens in redirection paths
- Views
- Views UI
Custom
- checkin_log - provides actions that can be launched via rules for logging user activity and display logs in a block
Imports
Checkin & checkout pages
- at admin/content/import, import pages.txt (Node Export needs to be enabled for imports and PHP filter for being able to save these pages that contain a little bit of PHP properly)
- text is in Dutch, translations upon request (anu at fabfolk dot com)
- Reset the paths (Path module needs to be enabled)
- (node title) Inchecken -> (path) checkin
- Wat ga je vandaag maken? -> checkin2
- Welkom -> checkin3
- Uitchecken -> checkout
- Mijn recente FabMoments -> checkout2
- Bedankt! -> checkout3
Content profile
Content profile module enables user profile to be created as nodes. This was during prototyping as I thought viewing user activity would have been possible by constructing a view showing node revisions combined with user information - turns out it was not possible (in a re-do, I'd probably go for just using the user profile)
- at ... import content.txt
- Permissions: at (user permissions table) set (anon&auth users can create content profile)
- The import should have taken care of this content type acting as user profile
- at admin/content/node-type/profile
- Checked: Use this content type as a content profile for users
- Checked: Use on Registration
- Hide form fields: Title
- some additional steps might be needed to hide Title & Body fields from users, more information here
Views
- Views - we're using Views 3 alpha due to some past site management choices, Views 2 should work just as well. For importing my views however you need Views 3 alpha.
Add views at admin/build/views/ admin/content/node-type/profile
Machine readable name for the block: checkout_fabmoments
Machine readable name for the block: checkin_fabmoments
- Add the view blocks to be displayed on checkin and checkout pages at admin/build/block/list
- Show Checkin & Checkout block on content area
- Only show them on specific pages
- checkin block -> checkin2
- checkout block -> checkout2
Rules
- At /admin/rules/ie/import import rules.txt
Theme
- Copy page templates to your theme folder (e.g. sites/all/themes/my_fablab/)
page-checkin2.tpl.php page-fabmoments.php page-checkin3.tpl.php page-fm.tpl.php page-checkin.tpl.php page-node-add-fm.tpl.php page-checkout2.tpl.php page-node-add-profile.tpl.php page-checkout3.tpl.php page-user-profile-profile.tpl.php page-checkout.tpl.php page-user-register.tpl.php
Workflow
- Unfortunately workflows are not exportable, so creating a workflow through the admin interface is needed
- Add workflow: http://localhost/clean/admin/build/workflow/add
FabMoment editing
- Add state 1: http://localhost/clean/admin/build/workflow/state/2
checkin - FabMoment draft started
- Add state 2: http://localhost/clean/admin/build/workflow/state/2
checkin - Fabmoment being edited today
- Add state 3: http://localhost/clean/admin/build/workflow/state/2
Gepubliceerd
- Set "fm" content type to have FabMoment editing workflow
- go to workflow editing (on top of the page) to add permissions for users to transfer content between states http://localhost/clean/admin/build/workflow/edit/2
(creation) → checkin - FabMoment draft started checkin - Fabmoment being edited today → checkin - FabMoment draft started checkin - FabMoment draft started → checkin - Fabmoment being edited today checkin - FabMoment draft started → Gepubliceerd Gepubliceerd → checkin - Fabmoment being edited today Gepubliceerd → checkin - FabMoment draft started
Other
- Import FabMoment content type (our temporary one is called fm - content_fm.txt
- edit the permissions to enable regular logged-in users to create, view, edit, delete the fm type nodes (only their own)
Configuration
Content
Anatomy of a (ProtoSpace) FabMoment: ...
Configuration
...
Theming
A number of templates were used to "skin" the user interface to be as simple as possible so that users could not fall off the system by clicking the wrong thing at the wrong time
- ...