Loading...
 
[edu.t.o] Development

[edu.t.o] Development


How a user joins the workspace

posts: 52
I tried the subscribegroup wikiplugin
http://doc.tikiwiki.org/PluginSubscribeGroup-PluginSubscribeGroups
and here are a few gotchas to use it for allowing joining a workspace.

activate the subscribegroup wikiplugin

this is done through the plugin tab on the textarea admin page
/tiki-admin.php?page=textarea

In Groups Administration

  • All the group you wanna people to be able to join (eg DemoGuests) must be marked as
    +User can assign to the group himself
  • As you want already Registered users to be able to join another specific group:
    +Registered group must have tiki_p_subscribe_groups permission set

1.1.3. If you want people to be able to choose the DemoGuests group at registration time

in the Login admin page
tiki-admin.php?page=login
you must mark both 'Registered' and ''DemoGuests' as
Users can select a group to join at registration
(note that if you mark only DemoGuests, users can't select anything, just become members of DemoGuests. So mark at least two, otherwise there will be no selection choice)

1.1.4. prepare a wiki-parsed user module like 'join_workspace_module', or a wiki_page, with the following code

{SUBSCRIBEGROUP(group=DemoGuests, subscribe="Subscribe to %s", unsubscribe="Leave %s", subscribe_action=OK, unsubscribe_action=OK) /}

this wikiplugin is smart, so by himself will display Subscribe... if the user is not subscribed, Leave... if he's already in that group

you can make it so that it will be shown to anyone except to members of FOO group :

{GROUP(notgroups="FOO")}{SUBSCRIBEGROUP(group=DemoGuests, subscribe="Subscribe to %s", unsubscribe="Leave %s", subscribe_action=OK, unsubscribe_action=OK) /} {GROUP}

You can then make a link to the page, or assign the module to all 'registered' group.
posts: 158
Hi pingus:

If joining a workspace right now is no more allowed through the workspace module "user & group managament" (like explained in the homepage of this edu.tw.o site), I wish this trick through plugin subscribe group could be somehow added by default to the content of the default homepage to each workspace, provided that the workspace is tagged somehow as open enrollment.

However, I wonder if it wouldn't be easier to allow users join a workspace as they could in previous versions of AulaWiki mod...

posts: 52
I could make the subscribegroup plugin appear both on the sidebar and in the ws desktop of the DocTest ws desktop (min:
My steps:
  • created a custom module, workspaces_subscribegroup_WSDOC, wiki-parsed, with the static code in it:
{SUBSCRIBEGROUP(group=WSGRPWSDOC, subscribe="Subscribe to %s", unsubscribe="Leave %s", subscribe_action=OK, unsubscribe_action=OK) /}

(a first problem is that the group name (WSGRPWSDOC) is static. Not adaptable to get a variable ws group name)
  • added tiki_p_subscribe_groups permission to Registered: this module doesn't work without this permission!
  • assigned the module to Registered
  • to show it in a ws desktop, I defined a own desktop for the Doc-Test workspace (not defaulting to the ws_type one, a specific destop for this ws), added both that module and the workspace_resources module, also to verify that resource creation from module inside own ws desktop works
  • now looking at the Doc-Test desktop while being a Registered user, you'll see Subscribe to WSGRPWSDOC. While being a member of WSGRGWSDOC you'll se Unsubscribe from WSGRWSDOC
  • I also noted that you can create new resources from the workspace_resources module when the workspace has its own destop definition (doesn't default to inheriting the ws_type desktop model). I hardly hope that the latest commit would solve this anyway, before anything else

For now the module is in the Doc-Test ws desktop. If this is OK, you can place that module in the WSDOC destop, I already placed it on left sidebar, after the workspaces_my module, for Registered. See if you wanna keep it there too.

My next steps in this direction will be to try the other, SubscribeGroups, plugin.
in the doc page it is stated (for tw>4.0 though)
including stringoptional will give all the groups including this group tw>4.0

wonder what it means... If it consider inclusion the reverse way it is for tw...
as all ws role groups are created including the ROLEGRP-rolename group.
Also this is not the case here, because you are using the WSGRPWSDOC father group, not the WSGRGWSDOC-Student (or WSGRGWSDOC-Owner) onew. And their ROLEGRP-xxx, although they belong to, does not exist...http://edu.tikiwiki.org/tiki-admingroups.php


BTW also noticed that Users can't register at this site.
posts: 52
> My next steps in this direction will be to try the other, SubscribeGroups, plugin.
> in the doc page it is stated (for tw>4.0 though)
>
including stringoptional will give all the groups including this group tw>4.0

> wonder what it means... If it consider inclusion the reverse way it is for tw...
> as all ws role groups are created including the ROLEGRP-rolename group.
> Also this is not the case here, because you are using the WSGRPWSDOC father group, not the WSGRGWSDOC-Student (or WSGRGWSDOC-Owner) onew. And their ROLEGRP-xxx, although they belong to, does not exist...http://edu.tikiwiki.org/tiki-admingroups.php

I succeded in installing the latest version of
wikiplugin-subscribegroupss frim trunk in the tikiwiki 3.3 distribution, which has the including= parameter, and it works.
I substituted
templates/wiki-plugins/wikiplugin_subscribegroups.tpl
lib/wiki-plugins/wikiplugin_subscribegroups.php

Now, if the workspace is set up properly (with all the -Student groups included in the ROLEGRP-Student group), by inserting this wikiplugin:

{SUBSCRIBEGROUPS(including=ROLEGRPStudent, subscribe="Subscribe to a group") /}

we get an automated drop-down list of:
only the allow-join groups of type Student(=included in the ROLEGRPStudent group)

that we can join

posts: 158
Oh well, I tried today at the former WSDOC, and something didn't work for me.
While in the ws desktop, were I was already a member of, and seen in the member list of the ws desktop module, I saw in the left column module as if I was not a member yet. So that I clicked on the ok from "join the workspace", and then, clicked "leave the workspace", and I was still listed as a member of the workspace.

http://edu.tikiwiki.org/tiki-workspaces_desktop.php?workspaceId=2

That's another reason why I would suggest that we start with a new workspace from scratch to hold the documentation pages...
so that everything is well designed from scratch.
posts: 52
> Oh well, I tried today at the former WSDOC, and something didn't work for me.

Don't worry.That's because I made WSGRPWSDOC-Admin@DOCGROUP include group EDUTwoEditors anyway:
http://edu.tikiwiki.org/tiki-workspaces_view_module.php?module=workspaces_user_groups&workspaceId=2
So we are anyway always member of WSDOC, but admin it.

What other 'Registered' users join now is the
WSGRPWSDOC-Member@DOCGROUP group, via the subscribegroup plugin, and we can join it or leave it too, but we'll be always admins of the workspace.
That doesn't happen to normal Registered that are not EDUTwoEditors members
If you prefer I take EDUTwoEditors away, we will have admin perms anyay because we have tiki_p_admin_workspace + tiki_p_admin

The new group Registered join is not WSDOC anymore, but WSGRPWSDOC-Member@DOCGROUP (the MEmber Role group).
I'd empty users in WSDOC, as they've been already imported into the -Member@DOCGROUP role group

> That's another reason why I would suggest that we start with a new workspace from scratch to hold the documentation pages...
> so that everything is well designed from scratch.

Fine for me. Then we must export/import the users from WSGRPWSDOC-Member@DOCGROUP to WSGRPWSDOCx-Member@DOCGROUP

I also find a bug when trying to remove sheets (couldn't remove then), but I find it also with removing sheets created outside the workspace, so it must be 3.3 related..
posts: 52
In practice, if you want to see what a 'Registered that joins the ws' sees, you have to login with an userid that is not member of admins, nor EDUTwoEditors nor EDUTwoAdmins.
Someone whose group doesn't have tiki_p_admin nor global tiki_p_admin_workspace nor objectperm tiki_p_admin_workspace on that workspace.

I use the pingus2 login for this. The Admin tab of the workspace shows a lot less buttons. No 'perms change', no 'admin users', no 'admin workspace' etc

> Don't worry.That's because I made WSGRPWSDOC-Admin@DOCGROUP include group EDUTwoEditors anyway:
> http://edu.tikiwiki.org/tiki-workspaces_view_module.php?module=workspaces_user_groups&workspaceId=2
> So we are anyway always member of WSDOC, but admin it.
> What other 'Registered' users join now is the
> WSGRPWSDOC-Member@DOCGROUP group, via the subscribegroup plugin, and we can join it or leave it too, but we'll be always admins of the workspace.
> That doesn't happen to normal Registered that are not EDUTwoEditors members

Switch Language