bending open atrium to your will!

Post on 27-Nov-2014

12.740 Views

Category:

Technology

3 Downloads

Preview:

Click to see full reader

DESCRIPTION

 

TRANSCRIPT

Bending Open Atrium to Bending Open Atrium to your will!your will!Jeff Miccolis, Development SeedJeff Miccolis, Development Seed

Bending Open Atrium to Bending Open Atrium to your will!your will!Twitter: @miccolis, @developmentseedTwitter: @miccolis, @developmentseed

Open Atrium Co-Open Atrium Co-maintainermaintainerTwitter: @open_atriumTwitter: @open_atrium

Give you want you need Give you want you need to write your own to write your own feature.feature.My goal.My goal.

There is a lot to know!There is a lot to know!My worry.My worry.

Expose you to the hard Expose you to the hard problemsproblemsMy approach.My approach.

Pretend you’re all *nix Pretend you’re all *nix usersusersMy approach.My approach.

...that you know Drupal...that you know DrupalMy approach.My approach.

...and that you’ve used ...and that you’ve used features and context features and context beforebeforeMy approach.My approach.

1. Quick overview of OA1. Quick overview of OA2. Configuration2. Configuration3. Groups & access 3. Groups & access controlcontrol4. Building a new 4. Building a new featurefeature5. Pitfalls & resources.5. Pitfalls & resources.

Agenda.Agenda.

Quick overviewQuick overviewPart 1.Part 1.

What Open Atrium does What Open Atrium does already.already.

quick demo.quick demo.

30+ languages

Swedish

Hebrew

Portuguese / Portugal

Catalan

Spanish Russian

Brazilian Portuguese

JapaneseItalian

Hungarian

German

French

Danish

Arabic

Time tracking!Time tracking!A “real” wiki!A “real” wiki!Maps!Maps!Gantt Charts!Gantt Charts!Solr powered search!Solr powered search!Alfresco powered DM!Alfresco powered DM!News Aggregation!News Aggregation!

The kinds of features you can add.The kinds of features you can add.

News Aggregation!News Aggregation!

The feature we’ll add today.The feature we’ll add today.

RSS+ATOMRSS+ATOMFeeds per-groupFeeds per-groupThree categoriesThree categories

Atrium Reader Atrium Reader

http://code.developmentseed.org/http://code.developmentseed.org/atrium_readeratrium_reader

quick demo.quick demo.

People organized into People organized into groups.groups.How Open Atrium expects to be used.How Open Atrium expects to be used.

Is your feature useful to Is your feature useful to people organized into people organized into groups?groups?Question.Question.

Yes, we’re twitter Yes, we’re twitter junkies.junkies.Answer.Answer.

ConfigurationConfigurationPart 2.Part 2.

What modules will we What modules will we use?use?Getting technical.Getting technical.

Where does module X Where does module X store its configuration?store its configuration?Features module compatiblity.Features module compatiblity.

I warned you about thisI warned you about thisWhat is the features module?What is the features module?

Your configuration Your configuration needs to be automatic.needs to be automatic.Why exportables?Why exportables?

You cannot trust a You cannot trust a sequential id!sequential id!Exportables are crucial.Exportables are crucial.

The `term_data.tid` The `term_data.tid` problemproblemYou cannot use taxonomy for You cannot use taxonomy for architecture.architecture.

Alex: builds a View with a term Alex: builds a View with a term filterfilter

Tom: sets up Open AtriumTom: sets up Open Atrium

Alex: sets up Open AtriumAlex: sets up Open Atrium

Alex: bundles it into a featureAlex: bundles it into a feature

Tom: posts a blog with a tag, Tom: posts a blog with a tag, “drupal”“drupal”

Tom: downloads Alex’s featureTom: downloads Alex’s feature

Alex: makes a “Important” tagAlex: makes a “Important” tag

Tom: has issues...Tom: has issues...

““Alex! Your feature Alex! Your feature hides anything I tag as hides anything I tag as IMPORTANT! WTF!?!”IMPORTANT! WTF!?!”A term’s creation order determines its A term’s creation order determines its sequential id. You’ve got not control.sequential id. You’ve got not control.

No.No.Is there a good work around?Is there a good work around?

Exportables will guide Exportables will guide what modules you use what modules you use and how you build.and how you build.The short.The short.

Any thing that uses the Any thing that uses the core `variables` system core `variables` system is supported (via is supported (via strongarm)strongarm)The good.The good.

Context module does Context module does thatthatWhat about block visibility?What about block visibility?

I warned you about this I warned you about this tootooWhat is the context module?What is the context module?

What needs to be What needs to be customized per group?customized per group?Spaces module compatiblity.Spaces module compatiblity.

Our aggregator doesn’t Our aggregator doesn’t need anything of this.need anything of this.Spaces has a great readme.txtSpaces has a great readme.txt

Context and Strongarm Context and Strongarm are covered.are covered.Spaces controllers.Spaces controllers.

Groups & Access Groups & Access ControlControlPart 3.Part 3.

OG powers OA’s groupsOG powers OA’s groupsOpen Atrium uses Organic Groups.Open Atrium uses Organic Groups.

OG controls accessOG controls accessOpen Atrium uses Organic Groups to Open Atrium uses Organic Groups to control who can see what.control who can see what.

This is where people get This is where people get confused. confused. Organic Groups implements Drupal’s Organic Groups implements Drupal’s node_access hooks.node_access hooks.

node_access is not node_access is not permissionspermissionsThe node access system let’s you control The node access system let’s you control who can view and edit an individual who can view and edit an individual node.node.

db_rewrite_sql()db_rewrite_sql()The node access system is inforced at The node access system is inforced at the SQL level.the SQL level.

Don’t worryDon’t worryViews does this for you and it wrote the Views does this for you and it wrote the book on exportable configuration.book on exportable configuration.

Build it already!Build it already!Part 4.Part 4.

AggregationAggregationFeedsFeedsFeed itemsFeed itemsDisplaysDisplaysBlock Block visibilityvisibility

feeds (contrib)feeds (contrib)

node (core)node (core)

data (contrib)data (contrib)

views (contrib)views (contrib)

context (contrib)context (contrib)

No surprisesNo surprisesYou knew this already.You knew this already.

Exportable and modularExportable and modularWhat they have in common.What they have in common.

1. Tighten scope1. Tighten scope2. Build in order2. Build in order3. Use features3. Use features

Three steps to a successful feature.Three steps to a successful feature.

Limited functionality Limited functionality that is useful to people that is useful to people in groupsin groupsTighten scopeTighten scope

Start with the content Start with the content types, then fields, then types, then fields, then displays.displays.Build in order.Build in order.

At every stoping point At every stoping point export your changes export your changes into code and commitinto code and commitUse features.Use features.

atrium_reader.info, atrium_reader.info, atrium_reader.module, atrium_reader.module, access pluginsaccess pluginsHightlightsHightlights

Pitfalls & ResourcesPitfalls & ResourcesPart 5.Part 5.

You’ll get burnedYou’ll get burnedSurely I can work around this Surely I can work around this ‘exportables’ requirement.‘exportables’ requirement.

It’s not obvious the first It’s not obvious the first time you see it.time you see it.I didn’t quite get the node access stuff.I didn’t quite get the node access stuff.

Don’t forget about View Don’t forget about View access plugin in Spacesaccess plugin in SpacesWhy does the menu icon show up when Why does the menu icon show up when the feature isn’t enabled?the feature isn’t enabled?

Localization always Localization always comes back to bitecomes back to bite30+ languages, eh?30+ languages, eh?

Yea, you should be Yea, you should be using l() anyhowusing l() anyhowI didn’t use l() and my links don’t work.I didn’t use l() and my links don’t work.

community.openatrium.community.openatrium.comcom#open_atrium#open_atrium

ResourcesResources

Thanks.Thanks.

top related