Closed (works as designed)
Project:
Organic Groups
Version:
6.x-2.x-dev
Component:
og.module
Priority:
Normal
Category:
Feature request
Assigned:
Issue tags:
Reporter:
Created:
22 Feb 2008 at 11:24 UTC
Updated:
30 Aug 2010 at 09:19 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
nath commentedSubscribing.
Comment #2
marvil07 commentedHi all.
I needed that too at the web I'm developing. So lastent and I created a little module for that.
I doubt if it's big enought to be a contributed module, but I submit it here for you to test it.
I wait for your comments.
Comment #3
gustav commentedmarvil07: that is exactly what I was looking for. Thank you very much for posting this. It works like a charm.
Would you be happy to have this integrated into og.module in case Moshe is interested? I think that would be more convenient than having it as a separate module. I can see no drawback with having this gadget enabled by default for all users.
Comment #4
nath commentedIt's still complicated with the current version. Would be nice if this could be integrated.
Comment #5
dugh commentedsubscribe
Comment #6
marvil07 commentedI think Moshe it's not interested on this inside OG, but some people may need it, and it's not so relevant. So I'll make a project after waiting some time for suggestions.
Comment #7
moshe weitzman commentedI actually do want this in core OG. I'd love a patch for 6.x as well.
Comment #8
marvil07 commentedExcellent news!
I've made a patch against 5.x-7.3.
I'll do a patch against 6.x now :D
Comment #9
marvil07 commentedHere is:
- a new version of the patch for OG 5.x-7.3 because of a line remove.
- the patch for OG 6.x-HEAD :D
Comment #10
moshe weitzman commentedI reviewed the 'add members' form on D6:
* Can we just reuse user_autocomplete() instead of doing our own?
* The 'add' link is appearing all the way to the right, far from the textfield. I'd like to see a real button, just after the textfield that does what the link does. I know that multiple buttons on forms is a bit dicey, but you can probably make it so that this button does not actually submit the form when js is enabled.
* I don't think the 'username helper fieldset is needed. Also, the textfield description should be "Lookup a username and add it to the list below". The title should be 'Add user'.
Ideally, patches are made from the root of the contrib module. i had to hunt a bit to find b/og_username_helper.js. Not a big deal. Like the git patch :). Maybe i will learn it one day soon.
Comment #11
marvil07 commentedThis version of the patch for OG 7.3 implements moshe suggestions and change form id names for better understanding.
I hope I could make a patch for 6.x tomorrow.
If someone else want to test this patch he wants to:
Comment #12
marvil07 commentedHere is the patch for 6.x with the same modifications on my last comment, and a new version of 5.x removing an unused line.
Waiting for revision :D
Comment #13
marvil07 commentedI reviewed the patch against new HEAD updated to August 14, 2008, and it's still applying well.
Comment #14
gustav commentedI have re-rolled the patch so it applies against HEAD. This feature is working really well. I would vote for adding it to og.
Comment #15
develcuy commentedI have rebuild the patch against 7.3 in git, so it is now in CVS. I have also updated the patch against 8.x-dev(DRUPAL-5--3 o_O!)
Blessings!
Comment #16
alb commentedhttp://drupal.org/node/310264
here there is a patch for to have visible all the users that one want insert in a group;
I think this is the solution better;
but at me not work.
I think pheraphs is necessary some small change.
Comment #17
tborrome commentedHi, is this available in the latest OG 5.x-8.0 release?
Comment #18
tborrome commentedI would really want to have this functionality. There are several patches in this thread. What patch works with 5.x.7.3? I tried integrate-og_username_helper-inside-OG-7.3-v5.patch in post #15 but had problems patching:
patch < integrate-og_username_helper-inside-OG-7.3-v5.patch
patching file og.css
Hunk #1 FAILED at 50.
1 out of 1 hunk FAILED -- saving rejects to file og.css.rej
patching file og.module
Hunk #1 FAILED at 24.
Hunk #2 FAILED at 76.
Hunk #3 FAILED at 204.
Hunk #4 FAILED at 1565.
4 out of 4 hunks FAILED -- saving rejects to file og.module.rej
patching file og_username_helper.js
what's the right patch for 5.x-7.3 release?
Is there a patch available for 5.x-8.0? Or is this already included in 5.x-8.0?
Comment #19
develcuy commentedI have tested the patch in 5.x-8.0 and works fine :)
In order to make this stuff work:
1. Go to administer->site building->menus (just open it will rebuild menu cache)
2. grant roles the permission: "access og username helper"
And in answer to #16, this is a core like feature, since we should consider having a combobox with about 1000+ users is not a good idea.
Blessings!
Comment #20
moshe weitzman commentedNo time to review now but this would be committed to HEAD first, and then 5. I don't see a current patch for HEAD (compatible with d6)
Comment #21
Anonymous (not verified) commentedHi,
here is a patch to og and also a rewritten module if you don't wanna patch your og module. And all these are for HEAD compatible with d6.
In the javascript i solve improve a bit the codes :
- don't add a username if already in the textarea
- don't add if no input in autocomplete textbox
- trim all usernames before adding them to the textarea
In the form_alter hook
i improve these:
- check if user has permissions before even creating form elements
Comment #22
moshe weitzman commentedIndentation is all over the place. See coding standards. Still not sure this is clean enough.
Comment #23
Anonymous (not verified) commentedI cleaned the codes following the coding standards. remember to clean ur cache.
Thanks
Comment #24
Anonymous (not verified) commentedmore cleaning using coder :)
Comment #25
GregoryHeller commentedWondering if this patch is on its way to being committed to og for drupal 6?
Comment #26
moshe weitzman commentedComment #27
marcvangendThanks for the patch, this is a valuable addition to the UI of the add members page.
Unfortunately, it doesn't work for me in IE, only in Firefox. When I click the add-button, IE starts reloading the page, as if the form is posted at the click of the button. I wasn't able to find the cause (yet).
Comment #28
zdean commentedsubscribe
Comment #29
marvil07 commentedSo, it's been a long time since I review this issue :-p
I see you were contributing to improve it, thanks!
After reviewing all patches here and fixing some, I had:
I'm only providing the patch, but the module should be straightforward now.
Hope it was clean now,
Comment #30
marvil07 commentedis there something more needed here?
Comment #31
Jackinloadup commentedsubscribe
Comment #32
Anonymous (not verified) commentedHere is attached the module version if you don't wanna patch your og core module. It includes the latest modification from marvil07.
This is for drupal 6.x
Thanks
Comment #33
jianingy commentedThanks, salimane. It's a handy module. It helps alot.
Comment #34
landry commentedUsing the module here, works fine, and it's a really nice addition. Looking forward for integration into OG.
My only concern : if you start typing a letter and no user match, no propositions are made, and clicking on 'add' will append the letter to the 'to-be-added userlist'. Dunno if that can be considered as a bug.
Comment #35
pheraph commentedHad problems with the latest patch, but the module in #32 works great! Thx Salimane!
Comment #36
marvil07 commentedI had verified the patch in #29 and it actually still works(against branch
DRUPAL-6--2) todayComment #37
merilainen commentedThis is a really big improvement on the usability.
Using the module version, I get the same problem which is mentioned in #34. Also if I just type partial user name, and try to choose the name with arrow keys, the partial username is added to the list, and to the adding form, which is a bug.
Maybe somebody could add some AJAX magic here so that the list wouldn't be a text area, but some elements which could be also removed if added by mistake? My skills are very limited in this area.
Update: It doesn't seem to work with Google Chrome.
Comment #38
bricef commentedGreat work, i think you should publish it as a standalone module in order to improve the work around it.
Comment #39
develcuy commented+1, as standlone it will have more visibility and will make our life easier as site maintainers, no more patching!
Comment #40
marvil07 commented@bricef: thanks for the suggestion!
After thinking about it, add button is not really necessary, so I updated the patch and the module to use the enter with keyup event(not keypress because of some conflicts with autocomplete IIRC).
this patch is against actual DRUPAL-6--2 branch
@moshe: I think this is the cleanest version of the patch until now, do you still want to integrate it in OG? I believe if not now it's time to make an independent module.
Thanks for all the feedback!
BTW: you can see a little video with the module working on http://blip.tv/file/2921743
Comment #41
marcp commentedI also think this would be great as a standalone module.
Great video -- it's helpful to see it in action before trying the module out.
The standalone has an unused
global $user;inog_username_helper_form_alter().Comment #42
merilainen commentedI'm trying to use the standalone version, but it doesn't work as expected.
I'm choosing a name from the list with a mouse, but it gets added to the auto-complete field, not the actual list field as in the video. If I press enter, the whole form gets submitted and then I get a message "0 users added to the group."
Now the auto-complete form works for Chrome, but behaves as described above.
Why this module has it's own permission rule? I think it should respect OG's permissions.
Comment #43
amitaibuI think this should live in contrib. Also in OG7, Og itself allows adding a user one by one. The contrib module can replace (hook_menu_alter()) Og's impementation with its own
Comment #44
jvieille commentedWorks great.
I don't know how OG administrators have survived without this capability. How the hell one had to know user's names by heart in order to subscribe them? The existing OG feature to add user is not much better than filling up the MySQL tables directly.
Can we expect an official module soon?
Now, waiting for a picking list...
Thanks a lot.
Comment #45
marvil07 commentedok, I'll work on this to get it as a separate module in the next days.
Comment #46
amitaibuMuchas gracias marvil07 :)
Comment #47
marvil07 commentedIt's on og_username_helper.
BTW: I made a change to let it also use the click event :-)
Comment #48
marcushenningsen commentedThe new module works great. Thanks a lot, a huge usability improvement.
Comment #49
alesr commentedIs there a way (module/patch) to see all users that you just click to join into a group?
Something like this http://drupal.org/files/issues/add_users_form.png