Open Atrium Workflow Enhancements
Okay welcome everybody! Thanks for attending the webinar today, my name is Mike Potter and we're going to be doing a demonstration today of some really exciting new features in open atrium 2 for handling workflow. So this is going to be more of a hands-on demo.
Introduction to Open Atrium
So basically for people who aren't familiar with Open Atrium, it's an open source collaboration framework built on Drupal. It's used for building intranets and web portals of any kind collaboration platform that you might need for your organization. Whether it's public facing or internally private facing or a combination of both. As I mentioned, it's built on Drupal. This is the cake picture of how it's put together. On top of Drupal, we have a core layer that open atrium provides, and this is for things like data privacy, Some of the new workflow features, customizing layouts, any notifications out, supporting all sorts of multimedia, whether its attachments or embedding activity streams all those things are part of core and are provided as pieces of functionality for any application to use, and then out-of-the-box, we ship with four applications in atrium, we've got the discussion application for doing discussion forums, We've got documents application for doing both wiki-like sites, CMS documentation sites, knowledge sites, as well as being able to wrap around external files like pdfs or Word documents, those kinds of things. We have events with event calendars, and event locations. Then we also have tasks, which are, issue tracking or to do lists, that kind of basic functionality. So all four of those apps sit on top of the CORE layer, all the notification methods are the same across all the moral of the layout methods are the same as all the workflows that they show you today is available across all four of those applications plus any other additional applications that other people might write to add into Atrium. It's a distribution of Drupal, so you can go to Drupal.org and get it from the project page there, download the latest release, which is currently 2.18, you can also go get it from pantheon, if you want to really quick spin up, go to getpantheon.com/openatrium, as of 2.18, last month, the installer for atrium now only takes about two minutes so you don't have to sit through that long twenty minute install process. It literally takes two to three minutes from start to finish, and you'll be up and running with atrium and you can start building content. So we're really excited about this new installer, it should really help people get up quickly and also reduces common resource problems, some people were having trouble installing the memory or various other things like that. All that's been taken care of now. The install should be super painless, so go play with it.
Introduction to Open Atrium’s workflow
Now the workflow stuff I’m showing you today, is not part of the at the core installer there that you're going to get on pantheon, you're going to have to add some modules, but we'll talk about that in more detail in a minute. Just a really quick overview of some of the terminology we're going to be using so we're on the same page and you don't get confused. When we talk about building collaboration spaces in Atrium, what we're doing is creating a structure in your website and this structure is kind of analogous to a filing cabinet. So think of one of the old fashioned filing cabinets, one of those big giant things with all the drawers in it. Think of that entire filing cabinet as being what we call a space; it's just a collection of content and within that filing cabinet you have subspaces which are like the drawers of the cabinet, and within those drawers, you have the sections, which are like the folders actually containing your content. And then your content, which are things like your documents, and your events, or your discussion forums or your work tracker issues all of those exist like pieces of paper within those section folders. And then your people on your site, your Drupal users, can be grouped in a number of ways. You can assign membership of users to those spaces, so it's kind of like giving out keys to the filing cabinet. You can create groups of people outside of spaces, the groups span across spaces, so it might be a group of faculty members of a university, or the executive management team of an organization, those kind of groups span across multiple spaces. Then you can also have teams, which are collections of users within a single space. These are going to be really important concepts today. In terms of conditioning and data privacy, data privacy is one of the really key features of atrium. It’s what most of the custom code in that core layer is set up to provide, and what it's doing is allowing you to lock your section folders. So, imagine that you want to have a discussion forum and you want to control and make that discussion forum private to only the executive management team. You'd put the discussion in a section folder, and mark it with the executive management group, and then anyone in that group can access that discussion section. Within a space, you can mix and match. You can have some private discussions as well as some public discussions. It's very important where the content lives, very much like paper in the real world. If you have a "top secret" marked paper and you put it in a public room, that paper is no longer protected. It’s no longer private. Everybody can see it. You have to put it in a locked area to truly be protected. Atrium works the same way. The documents aren't protected; it's the section that enables the security.
Workflow in Atrium: What is Workflow?
A "workflow profile" is a collection of states and transitions. Content on your website is going to be tagged with a state. You start in a draft state, then you move them to a for review state. You have a set of people who either approve your content, or reject your content. Once the content is ready to publish, you can publish it to your website. Basically anyone who has proper access in a space, they have the ability to publish content. There’s no workflow there, there's no approval chain. Approval chains require states and transitions. They are not just for publishing documents, however. When tracking issues, or issue tickets, states and transitions will differ. You want different states to match the situation, such as tickets being open, resolved, or closed. Your workflow is really dependent on the kind of work you're doing, as well as the kind of space you're in. Workflow that your HR department goes through might be different than the kind of workflow that your research department goes through. So, there’s a module in Drupal called workbench moderation. The problem with workbench moderation is it does that globally for your entire website. You can enable and disable different content types on your site, so you can say one content type has workflow and one doesn't, but it's the same kind of workflow across all content types, it's not very flexible. When we put workflow in Atrium 2, we really wanted to fix that and do a better job, and that’s really what we've done. If you want to go get this, you can get the module "Open Atrium Workbench (oa_workbench) by dsnopek. "Workbench Moderation Profiles" (sandbox) by srjosh allow you to have multiple "workflow profiles" across your site. This is the key part in allowing space specific and content specific workflow. There are other optional modules, but we'll discuss those later. Here is the workflow profile that we're going to implement today. We're going to implement a really basic publishing review workflow. So instead of just the normal "draft" and "publish" state, we're going to insert this new state called needs review. You're going to be able to mark your drafts as "needs review", but only the administrators can actually publish the content. So the content creator cannot directly publish content. This is your really basic common step one workflow that people want. Sometimes you'll get more complicated and have multiple approval chains, but this is the simplest one to make. So let's go and actually do it. As we go through this, really pay attention to this user badge on the upper right of the page, because whom we're logged in as makes a huge difference. On this page, I'm the admin, and this is actually the Drupal admin for the whole site. One window, I have the "student" user. Our student is the content creator, but students aren't allowed to publish anything. Then we have a third user, the physics professor. And our physics professor is the administrator of the physics space. That administrator has permission to publish content. Before we get in to this, let's go in to admin and see how you set all of this stuff up. So you install all the modules, and once you've installed all the modules, what you'll get in your Drupal configuration page, is a workbench section for workbench moderation. This is the normal Drupal model that allows you to define states and transitions, And you'll see the normal states and transitions tab here, and there’s this new tab called "profiles", which is added by that sandbox: "workbench moderation profiles". Now these are our three states, and these are actually the states that atrium defines out of the box when you install oaf workbench. This is the basic review workflow that it creates for you. I haven't actually added anything, but if you have other states, you just add them here in the new state box, just give them a name and description, and just add them. These states are site-wide, you have to be the site administrator to ineptly set-up these profiles and define the states. It's important for the states to be site-wide, even though you'll have different workflows between spaces, the concept, for example, of the published state, that needs to stay consistent across your website, the website needs to know what you mean by published, or draft. You can create as many states as you want, but you don't have to use all of those states in your workflow. But if you need a new state, it needs to be created at the site level like this. Once you've created your states, you go to the transitions tab, and now you set up the different transitions. So now you can see these two columns, the from and the to. So, the transitions send to review is going to take your documents from the draft state, and move it to the needs review state. And if you want to approve it, you can publish it to needs review to publish. So these are the four states that we had back on our diagram. We had four blue lines here-- those four blue lines are the transitions we have within our workflow. So, normally with workbench moderation you can go ahead and do this, and this would set up a site wide workflow. And now with profiles, you can create a new profile. We come with a default profile in Atrium, and I've made my own here, if we edit this, my workflow, what we'll see is that a workflow profile is super simple. It has a name, and it has which transitions make up this profile. Inherent in these transitions are the states themselves. But you don't have to add the states themselves. They're implied. Basically, you just list what transitions you want to bundle together to a workflow. You don't have to use all the transitions on the site, but if you hit the drop-down, you'll see all the transitions on the site that you can select for your workflow. So these are the ones we want, so now we have a profile. So now how do we activate that profile? The first thing we need to do is activate it for the content type itself, this is again a normal process of using workbench moderation, you need to go to your structure and content types, and you need to decide which content types on your site you want to allow workflow on. For example, we're going to do document pages in our demo here, so you go to your document page content type, and down here in publishing options, you'll see these new options. Enable moderation, create new revision. So the first thing you have to do is turn on create new revision. This should be on by default with Atrium, this just allows Drupal to track multiple revisions of documents, and let you revert things if you don't like the changes and so forth. What workbench moderation adds is this check box that says enable moderation of revisions. So again, this has nothing to do with Open Atrium, this is just part of workbench moderation. It's really up to you to go set up which kinds of content types you want to allow for workflow. Now doing this in Atrium is not going to turn on workflow for you. This is just going to be an underlying enabler. Go ahead and enable it for all of your content types, that’s fine, but it would just give you the option to actually use workflow for all of those. But you actually have to enable it on your content-type before you go any further. Once you have the content type set up, you go into your space, and you go to the configuration page for the space, (Click the gear icon-->Config) and you'll see that there's a new option added to the bottom called workbench moderation profile. When you select that, it now asks you: "what profile do you want to use within the space?" You typically want your default state to be the draft state. Once you do this, now whatever content types you enabled are going to be enabled for the physics space as enabled for workflow. So, the next thing we need to talk about really quickly is permissions. This is a little complicated and I'm going to revisit some slides later to summarize this, but workbench moderation also has some permissions you need to set at a global level. Here I've gone to my people permissions page, and we've got anonymous users, authenticated users and administrative users, you can see what workbench does, it adds a global permission for every one of your transitions, and what we want to do here is enable all of those permissions for all the users on the site. Now this is going to seem a little odd, but this is just the way that workbench moderation works right now, but I think we're going to see josh try and find a way to change it so it works more normally. Normally in Drupal you add permissions to things, you'll notice in normal atrium, the permission to do anything is turned off for users if it's only enabled for administrators. So, to create content, to edit content, is normally all turned off. And atrium adds or grants permissions to do things. But, for the case for workbench moderation, the way that module was built, you can only revoke permissions, you can only take away permissions. So what you have to do at the Drupal level, is essentially grant everyone permission. Then, Atrium and the workbench profiles are going to restrict permissions from users who don't have them. So it's kind of backwards from what we're used to, but it's just the way that this module was written. We'll try to take care of that in the future, if we can. So that’s the global Drupal permissions to let everybody do this. Now, of course in Atrium you've got your space level permissions, this is coming in from the organic groups modules, this is going to your organic groups configuration and this is setting the default space permissions for your whole site. Now, in Atrium you can set space permissions on a per space basis. So, you can turn this stuff on and off, on and off, in different spaces, but here I’m showing you the global default setting. And if I go to moderate, and there we go, so again, you see that each transition is given permissions. And in this case, the columns are not members, and members, and then the space administrator or the group administrator. So here, what we're doing is saying that all space administrators are allowed to do everything, but in our example, we only wanted the group administrator or the space administrator to publish content, right? That was that admin tag that I showed you here. So we only want admins to be able to control these states. So all the published states can be returned for revision. Those three states should only be allowed for the space admin. Only the space admins can publish or reject content, but all members can create drafts and view unpublished, this view unpublished is also a default permission you need to grant, so people are allowed to see these unpublished revisions of content. Go ahead and save those options, and those set up your permissions. That is all the set up we need. It's a little complicated the first time you've got to set up your states, transitions and profiles, enable for content type and set up permissions. Once that's done, we can start the content creation process. Lets go to our student profile. I just created a new document section here in the physics space just for our demo. Let's go ahead and create anew document page. Let's call it "workflow test". You'll notice the first new thing here, is that there's a new widget on this page. Atrium knows that this is a content type, which is enabled for workflow. So it's giving us this little workflow messages widget. Which tells us what the current profile being used, and says, "When you create this new content, your draft is going to be placed in moderation. You'll notice we no longer have a publish button. So we save this as a draft, So now we're still student, we're looking at this draft, and so now we can play with this draft, we can edit it, and you'll notice here is that same messages widget that we saw before, it's telling us what our profile is, and it's telling us that the current state is the draft state, it's the current draft, and now it's going to let us set a new state for the moderation. Now, this is going to be based on what you're allowed to do. Students are only allowed to do one thing, which is move them to needs review, and again going back to our diagram, the only transition that a student can do from the draft state is to send it for review. They cannot publish it because only admins can publish it. Se this is letting you do that. Again, this is default workbench moderation stuff if you use workbench moderation you've seen this as a common process. The user interface really stays the same. Now, as the student, let's say, "ok, I’ve edited this, I'm happy with it, and I now want to get it review." So I’m going to hit apply, and it's going to update the state, so the state is needs review. You'll notice that now my widget has disappeared. I can't do anything now as the student. I can go back and edit a new draft, but as it's in the review state, I'm not allowed to review it. Let's go back to our professor login. This new documents section only shows published content, so where do you go find things marked for review? There are two places: the first, under your user badge, you'll see a new option called my workbench. We've placed it in the normal menu. If you go to "my workbench", you've got different tabs. You can see all the content, you can see your own drafts, and particularly, you can see what needs review. So if we go to the needs review tab, we can say "Oh look, there’s this document. It was created by the student, and it's called workflow test, and it needs review." Now, you can change it's state right here, but lets go ahead and click on it to go right to the document. I want to read this and make sure it looks okay. I can now set the moderation state. I can either reject it, by sending it back to draft, or I can go ahead and publish it. If we publish it, and go back to our section, you can see that there’s the workflow test and it's been published. If the student goes to their document section, they can see that it's been published. As a student, if I go back to it, I can see that it's in the publish state, and it's the current draft. You can see, I can't edit this directly, as it's a published version, because you have to go through the workflow process. The process now is that I can create a new draft. If the student says "hey, I want to update this." Then you must submit a new draft so it can go through the revision process once again. The key thing to realize is that the workflow in Atrium allows you to have a separate published version from your current draft. And to look at this thing more holistically, if we go here to the gear icon, there’s a new option here called moderate, and if we go to moderate, what we can see is all the revisions of this content. And you'll see here's the published revision in green, when it was published, who reviewed it, and you can see every step of the process. But then you can also see that the student created a new draft, and it's waiting for review. The whole process works the same from here. You have a button that says "view draft" with the updated works. You can again publish the draft or return it to draft form. Now, if we go back to our document section and look at the public version, it now shows that this is an update. We just went through a second workflow cycle where we took a previously published piece of content, went through a whole draft process which was completely hidden from the public content of the site. It only took place between professor and student. You can compare revisions, so you can see exactly what changed, you can go back, and mark which one of these you want to unpublish, or revert back to previous versions. So all in all, very rich control over your whole workflow process. So that's the simplest case where we let the space admins be the people who approve content. But let's say you don't want it to be the space admins, they already have enough work, and you want to give it more granular control. That's where we get to the group and team access. Let's go to our site administrator, and lets go to some new tabs here. So if you turn on OA Access, which is an optional module, it allows you to use groups and teams almost like roles. It provides a mechanism to do that for modules, and it gives us in the group section some permissions. To get here, you go to Open Atrium, groups, and then there’s a new button here called group permissions. This details the available group permissions. So if I go over here to my physics space, I have a team I've created within physics. Remember that teams are a collection of users that I can create within my own space. In this case, as the physics professor, I can create this team of people. When I go to my space page, and the way you get here is by going to your space, and going to configure, and on of the configurations now in your space is your team permissions. So this is the analogous screen for teams. So we have group permissions and we have team permissions. So let's look at the default. Remember that the permission rule for workflow is you revoke permissions. So, right now, I've got my permissions set so that only space administrators can publish stuff. So if I want other people to be allowed to publish stuff, I need to open this up and check these boxes to allow anybody potentially to publish content. So let's save those permissions. So, now I just opened it up, if I was to go to my student account, and I create a little draft, let's create a new page called "Group test", we're going to save as draft, and since I just opened up permission, you can see that the student is now allowed to publish because we've opened it up. So we're no longer revoking access. So now, we can go to our site level to the groups and say "ok, within my site I don't want all users to be able to publish, I only want faculty members to be able to publish." So this is very similar to setting roles, but this is more of then Open Atrium way of doing it. So you open up the role-based stuff, then you're going to lock it down using groups. If you save these group permissions, and we go back to our student, and refresh the page, the student can no longer publish content because the student is not in the faculty group. If I add students to this, because you can add more than one group and save the permissions, the student can now publish again. This gives you much easier control over the permissions over the default Drupal system.
Using this access stuff is usually the way most people are going to use it within Open Atrium. Lets set all of these permissions to faculty and go back to our defaults. So now instead of admins being the approvers, anybody in the faculty group can be the approver. So now, we're disconnected from the space administrators and are now using faculty as our approvers here. Let's say that within my space, I'm in my physics space, and that's really too much for me. I really want to let a certain team of users publish content. So I've got this project team here with both a specific student and a specific professor. Let's say I want this project team to be able to publish content. So within my own space, I can override my group permissions, I can say all space members or I can say project team. Before I save this, let’s just verify that the student is not a member of the faculty group, so the student cannot publish, only mark as review. However, as soon as I change my project team permissions here, this student is on the project team, so we'll save this, and so now when I go to my student window, I refresh and now that student CAN publish the content. This is because the student is in the project team. Now this is even more granular; I've given a specific user the ability to publish content by putting them in a team within my space, I didn't have to contact the site administrator to set up the new group, or add them to the faculty or any of that kind of stuff. Just through my ADHOC permissions as a space administrator, I'm able to create a team and give those team members permissions in my workflow. Again, remember that these transitions, you can have multiple workflows, these transitions might be different transitions for document pages versus events or discussion posts. So, a huge amount of flexibility and power within the permission system here. Scheduled revisions are fairly simple too, If we go back to the professor profile, one of those options added by the Sandbox srjosh did adds this option called schedule, and when you click on schedule, you can add a new scheduled transition, and can say "I want this to go from "needs review" to "published" on this date at this time. You save your changes, and when this date and time occurs, it's automatically going to make this transition. You can use this to automatically publishing content at a future date, you can use it to automatically mark things as review overdue, you can take published content and unpublished it, for example, you might archive content after six months automatically, all those kinds of things can be done here. Right now, it's pretty basic, you need to do it on a per-content type basis, but it does let you set up this kind of schedule. You can also do workflow per section by activating a sub module within OA workbench called OA workbench section profile, this adds a field to your section page that allows you to select a workflow profile for that section. So now, instead of turning it on for all documents in your physics space, you can turn it on only for the document pages within a specific private section. So again, much more granular control. This is disabled by default, but you can turn that on if you need that kind of granularity. We've provided more widgets for the workflow and workbench stuff. For the demo here, we've been going to the "my workbench" part here which is the page that comes with workbench moderation, they kind of give you basic stuff, and you might not like what's on here. We tried to make it a little easier. In this case as the physics professor, I've customized my dashboard. I've got a widget on here that shows documents needing review. It's kind of like what's in the workbench, but you've got a little bit more control here. And this is the widget provided by atrium. So if you customize the page and take a look at this widget, this widget has a ton of customization on it. You can give it a title, you can select what types of content you're looking for, you can select what states you want to show, and here, we're showing all of the documents that have the needs review state, but you can select other states in the settings if you want. You can limit what space it's in, what section it's in, and then down here, there's a whole bunch of fields you can turn on and off. For example, if we wanted to be able to show those links for the moderation, we can click that, and then now up here in the preview you'll see these links for set to draft and set to publish. So, lots of things you can turn on and off, provided by this widget. You can make the widget as complicated or as simple as you want. So that widget makes it very easy. So you can have a bunch of these widgets for each state, such as one for needs review, one for draft, one for publish,etc.
You can create really complex workflows to match your business rules. Those workflows can exist across spaces and even sections, there’s really rich access controls for these, you can use Drupal rules like you're used to, or you can use groups and teams within Atrium, there’s advanced features such as scheduled transitions, you've got intuitive user dashboard both through my workbench and through custom widgets, works across all Atrium content types, or any other custom content types you might've added to your system.
If you've ever done workflow in Drupal you know how hard this stuff is.
"Is there a way to analyze permissions to determine why a user was blocked or has the ability to publish"
"That would be a great addition in terms of administrator controls, and there is something similar for kind of "debugging" permissions, when you go in to the configuration for the workbench moderation module, there’s this little tab called check permissions, and you can basically say from a Drupal role perspective, I want authenticated users to be able to edit moderated content, and say, check these permissions, and then we'll go check to see if those permissions are set, it's really kind of basic and it doesn't work all the time because it doesn't know anything about Atrium in this sense. Remember that this model is that you have to open it all up and then Atrium is going to close it down. So, this is probably going to tell you that they have permission even if they don't from an Atrium perspective, so I think that would be a great addition to do an administration panel that let's administrators look at that.
"With Atrium, can group level persons control access to individual fields?"
right now, we don't have field level access, but there’s a module in Drupal that allows field-level access that you can install, I've done that on a site and it works fine with Atrium. It's set up for role based stuff, so if you want it tied in Atrium groups and teams, again, if you have a developer resource, or you could talk to us about doing some work for that, there's this OA access sub module in Atrium that allows groups and teams to kind of act as roles, but it does require creating some custom code for specific modules, so we've done the custom code for workbench moderation, we've also done a custom code for the profile two module, for controlling who can access user profiles, to control the field permissions, would require that same level of development work.
"Is email notification of state change possible?"
I'm sorry I neglected to mention that. Yes, the notification systems are there, and you can set up notifications to each transition to determine who gets those notifications. So when somebody puts something in a needs review state and you're in the moderation list, you can get an email that says "hey, this thing needs to be reviewed".
"Can content be just an object?"
Content can be anything you want as in a Drupal content type.
All right great! Thanks very much for asking all your questions and attending! I hope you're just as excited about this as I am. Go tell your friends about it, I think this is a very key feature in Atrium now, and from a Drupal perspective, is going to help people do workflow in Drupal a lot more than they were able to before. See you at the next webinar! Take care.