similar to: has_many :through updates on delete.

Displaying 20 results from an estimated 600 matches similar to: "has_many :through updates on delete."

2012 Jun 18
0
Creating an object with a nested has_many :through relationship
I have 3 models that define members, groups and the subscriptions: Member, Group, and GroupMember. class Member < ActiveRecord::Base > has_many :group_subscriptions, class_name: "GroupMember" > has_many :groups, through: :group_subscriptions > attr_accessible :email, :password > end > class Group < ActiveRecord::Base > has_many :member_subscriptions,
2006 Jan 28
6
Check if user is in right group
What is the best way of checking this? I have 3 tables: groups users group_members class GroupMember < ActiveRecord::Base belongs_to :group belongs_to :user validates_uniqueness_of :user_id, :scope => "group_id" Then I want a method here that checks if a given user is a member of a given group. What is the right way of doing that? def
2006 Apr 20
8
Whats the best way to do this?
I have an archive that can have 0 or more extra files associated with it. I would like to be able to edit the associated files info on the same page as the archive info. Listing the extra files info to the edit form is simple enough, but How do I form the text input fields for easy (or automatic) pick-up in the update? Or am I barking up the wrong tree here? -- Posted via
2006 Aug 08
3
problem inserting parameters in link_to_remote
I want a page that lets users add members to a group from a longer list, or remove members from that group. I can use Ajax to transfer a name from the long list to the group, or drop an existing name from the group. But. If I add a person to the group, and try to remove without refresh, it doesn''t work. My link is formed by <%= link_to_remote ''add'', :url => {
2006 Aug 09
1
Clarification on error_messages_for
Just learning Rails.. So this is probably a noob question. My apologies. Could anyone please give me a quick summary/example on the usage of error_messages_for? I have two tables/models, Group and GroupMembers. Obviously, a Group has_many GroupMembers. I have a customized view which shows a list of GroupMembers followed by a field and a button which facilitates adding a member to the group by
2010 Apr 13
2
transpose but different
Hi all, I want to make extra columns in my datafile where the id of every groupmember is mentioned in separate columns. To explain it better see the example: id<-c(1,2,3,4,5,6,7,8,9,10,11,12) group<-c(1,1,1,1,2,2,3,3,3,3,3,3) a<-as.data.frame(cbind(id,group)) a id group 1 1 1 2 2 1 3 3 1 4 4 1 5 5
2003 Jul 31
1
Réf. : groupmember list fails with 3.0.0b3 and LDAP
Hi, Same problem for me, any clue ? Gana?l. owen@isrl.uiuc.edu@lists.samba.org on 07/31/2003 01:42:21 AM Envoy? par : samba-bounces+ganael.laplanche=edf.fr@lists.samba.org Pour : samba@lists.samba.org cc : Objet : [Samba] groupmember list fails with 3.0.0b3 and LDAP Hi all, I've been working on a PDC with group mapping with Samba-3.0.0Beta3 with OpenLDAP-2.1.22. Things
2003 Oct 30
1
samba3 backend ldap max groups..
Hello, I'm testing samba3 with the backend ldap on Linux to replace our NT 4 Domain. OS: Linux UL1 Samba3 OpenLdap 2.1 Samba3 works as PDC with the backend ldapsam. There a problem I'm still hanging. If a user is member of more then 32 groups I just can work with my defaultGroup (atrribute: sambaPrimaryGroupSID), all other authorisation will be denied although the user is member of all
2006 Jan 16
0
belongs_to with has_and_belongs_to_many
I''m having a problem with belongs_to and has_and_belongs_to_many. Here''s a brief summary of the models involved: class Member < ActiveRecord::Base set_primary_key ''member_id'' has_and_belongs_to_many :projects, :join_table => ''projects__members'' has_many :projects, :foreign_key => ''created_by'' end class
2006 Mar 28
2
ACL on groups working half
Hi all Samba users, For some I've got a Samba server running with the following config: Debian Sarge 2.6.8 kernel Samba 3.0.21 with winbind and LDAP as ADS member server A W2K003 PDC Samba's data partition is ext3 + ACL I've migrated my users homedirs and profiledirs from W2K003 to Samba. These each user owns his own homedir and has rwx------ permissions This seems to be working
2018 Jul 25
3
Unable to contact active directory or verify claim types
I am running several Solaris 11 file servers with samba 4.7.6. This is an AD domain but the domain controllers are Win 2008 R2 and Windows 2012 R2. All users and groups in AD have unix uidNumbers and gidNumbers assigned. On one file server, I am having problems where some users can not access files , via windows, to which they should have access as the group member. For example,
2006 Jun 09
0
Sortable list with non ajax submission
I am trying to create a sortable list that is submitted not with an AJAX call but by a standard form submit button. Right now I have def reorder_group_members @group = Group.find(params[:id]) @group.group_members.each do |member| member.position = params[:memberlist].index(member.id.to_s) + 1 #I get a nil error for this line. It would seem that params[:memberlist] is not
2006 Jul 24
0
Mongrel + BackgrounDRb + File Column = Upload Progress Bar?
Hi there, I''ve been digging around trying to find some information (mostly examples) on how one would handle a progress bar upload using BackgrounDRb and File Column. I did read http://backgroundrb.rubyforge.org/ and Ezra''s blog of course, but I still have a few questions. I made a simple upload form (as a test) that is submitted to the "upload_song" action. def
2007 Nov 05
0
Authentication: is a guest a user or an "exception"?
Hi all I''m currently implementing authentication/authorization in my app. Now I''m wondering what''s the common way to handle a guest... In fact, many of the visitors of my app will be anonymous users that just want to read articles etc., but one can register as a member to have some further possibilities. So far one can login as a member and from this point on one has
2004 Aug 12
2
Group management
I'm trying to add a user to the domain admins group in vain. I've tried using the windows usrgrp tool. I've tried doing 'pdbedit -u username -G S-1-5-21-2351621536-730267382-1598341932-512' I've tried 'net groupmember ADD 'Domain Admins' username. The user I'm trying to add is already in the unixgroup that's mapped to the NTgroup. Does any one know
2005 Nov 22
11
Building a conditions clause (for find) of multiple optional params?
I want to be able to find items according to various params - category_id, member_id, type_id, rating, etc. What I have now is something like: if(@params[''category_id'']) @items=Item.find(:all, :conditions=>["category_id=?", @params[''category_id'']) elsif(@params[''category_id''] and @params[''member_id''])
2008 Feb 27
0
Listing users from a group (net rap groupmember list)
Hello list! I've been trying to list the users from a group of my samba server (running on an OpenBSD 4.2 box) by using "net rap groupmember list GROUPNAME -S PDC -U administrator%password -w DOMAIN", but I get nothing in return. By running the command with a -d for debug purposes, I get the messages above:
2006 Feb 17
0
How do I use machine password for groupmember list?
I have successfully set up squid with ntlm_auth as per the Squid FAQ http://www.squid-cache.org/Doc/FAQ/FAQ-23.html#ss23.5 using a Win 2003 AD for NTLM2 authentication. The winbindd and nmbd servers are 3.0.20b, installed from Suse SLES 9 SP3. There is a requirement to manage web surfing by groups, and a cron job needs to obtain a list of members of groups. net rap -S AD groupmember list -U
2003 Nov 18
0
groupmember and local groups
I see the message "Not supported by server" when trying the net groupmember command with my Samba server. Samba 3.0.0pre3 on RedHat 9 Member Server connecting to NT4 PDC Is there another way to add users to local groups? I can't get wbinfo -C to work either. Here is what happens... [root@silvery dl]# net groupmember add "CVS Operations Users" mydomain+janderson -U
2004 Jul 07
2
Net rpc user add and the "-F" flag.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello, all ! I'm trying to add users to my NT domain from my samba servers (This to create all my accounts with only a single script, I do not want to create them on the PDC, then create their folders on the samba file server with another...) I managed to create account with "net rpc user add", then put them in the right domain