T3DD12 community extension
-
Upload
aoe -
Category
Technology
-
view
2.082 -
download
0
Transcript of T3DD12 community extension
![Page 1: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/1.jpg)
Tymoteusz Motylewski T3DD12
EXT:
Community
![Page 3: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/3.jpg)
• Have you played around with Community?
• What are you interested in?
• Do you have Extbase experience?
You?!
![Page 4: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/4.jpg)
• Started around 2008 as pibase extension
• Rewritten during GSoC 2010
• Currently based on Extbase
• Finally stable beta
EXT:Community
![Page 5: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/5.jpg)
• Forge:
http://forge.typo3.org/projects/show/extension-community
• Mailing list
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-community
or news://lists.typo3.org/typo3.projects.community
• Git repository
git://git.typo3.org/TYPO3v4/Extensions/community.git
• Gerrit
Where to find it?
![Page 6: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/6.jpg)
http://www.flickr.com/photos/dieselbug2007/414348333/
Websites running Community
• Caremaid.net
• Ambasadapiekna.pl
![Page 7: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/7.jpg)
• Friends
• Messages
• Wall
• Gallery
• Simple search
• Notification service
• Access control configurable in TS
• Easy to extend
• Documentation!!!
Features
![Page 8: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/8.jpg)
• Registration
• Access on a page level
• Groups (but planned)
Not covered by Community
![Page 9: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/9.jpg)
• View
• Edit
• Delete
• Report bad profile
Features - Profile
![Page 10: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/10.jpg)
• Classic view
– Inbox
– Unread
– Sent
• Threaded view
– List of conversations
– Whole conversation with one user on one
page
Features - Messages
![Page 11: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/11.jpg)
• Requesting, canceling, confirming
friendship
• List of friends
• Possible states of the relationship:
– New
– Confirmed
– Rejected
Features – Relation management
![Page 12: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/12.jpg)
• Posting messages
• Smiles (requires ext. „smile”)
• Deleting messages
Features - Wall
![Page 13: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/13.jpg)
• Gallery
– Albums list
– Photos list of one album
• Album
– Title
– Cover image
– Privacy settings
• Special album with profile pictures
Features - Gallery
![Page 14: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/14.jpg)
• Mail, private message, wall message….
• Multiple notifications per event
• Easy to use API $notification = new Tx_Community_Service_Notification_Notification(
'relationRequest',
$this->requestingUser,
$this->requestedUser
);
$notification->setFoo(„BAR”);
$this->notificationService->notify($notification);
• Configurable in TS relationRequest {
10 {
template = RelationRequest
handler = Tx_Community_Service_Notification_MailHandler
serverEmail = {$plugin.tx_community.serverEmail}
} }
Features – Notification service
![Page 15: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/15.jpg)
Want to notify by SMS after receiving private message?
1. Create own notification handler which implements Tx_Community_Service_Notification_HandlerInterface
- send() method is required
e.g. Tx_CommunityLocal_Service_Notification_SmsHandler
2. Add typoscript configuration
plugin.tx_community.settings.notification.rules {
messageSend {
20 {
handler = Tx_CommunityLocal_Service_Notification_SmsHandler
}
}
}
Features – Notification service
![Page 16: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/16.jpg)
Architecture
Architecture
![Page 17: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/17.jpg)
• Base class for all controllers
• Resolves requested and requesting user
• Access control in initializeAction()
– Return nothing if user has no access
Architecture – Base controller
![Page 18: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/18.jpg)
Requesting (logged in) user
Requested user
Are friends
Access type Notes
NULL NULL - ACCESS_PUBLIC Public, guest access. No logged in user, no requested (target) user. Used e.g. for “list of 10 newest users”.
NULL John - ACCESS_NOBODY Public, guest access, no logged in user. Public, but user specific plugins.
Bill John NO ACCESS_OTHER Bill is logged in, but he is not a friend with John
Bill John YES ACCESS_FRIEND
John John | NULL - Access granted by default.
If requested user is not set, and we are logged in, then requestedUser = requestingUser – e.g. we are seeing our own profile
Architecture – Access control
Types of access for different requests:
![Page 19: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/19.jpg)
• On action level
• Configured in TS
– Actions are mapped to „resource names” accessActionResourceMap {
User {
image = profile.image //image action from UserController
edit = profile.edit
}
– Access rules are set for resource names accessRules.friend {
profile.image.access = 1
profile.relation.access = 1
}
Architecture – Access control
![Page 20: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/20.jpg)
• Use Ajax wherever possible
• Privacy settings for user properties
• Groups
• Performance tuning
• Notification queue
• Advanced search
• Standard image sizes defined in TS
• Commenting on wall posts
Roadmap
![Page 21: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/21.jpg)
• Installing community
• Features/roadmap brainstorming
• Discussion
– groups handling
– privacy settings
• ???
Workshop tasks
![Page 22: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/22.jpg)
• Levels
– Action level (MessageController->sendAction)
– Record level e.g. user/ album
– Record property level – $user->email,
$user->name
• Defaults
– Global defaults: deny or allow
– Defaults for table/record/property
Privacy/access control challenges
![Page 23: T3DD12 community extension](https://reader033.fdocuments.net/reader033/viewer/2022052901/5568f75bd8b42aff2e8b4c3a/html5/thumbnails/23.jpg)
• Allow user to change his privacy settings
• Easy to extend (new models, new
controllers)
• Fast
• Transparent
• Configured in single place
• …
Privacy/access control challenges