Hey, I know you were trying to help - and help you did :) It just made
laugh when you said "Hmmm, familiar with Ruby you are not… " I'm not
offended - I have thick skin working in IT for so many years ;)

It's easy to mis-read an email after all! I really do appreciate your
help - without willing people like yourself, I'd be stuck!!

Your suggestions were vital and couldn't have started without your
assistance. I realise we veered off-tack here and was slightly
embarrassed by having to ask. You're right, I've only been using rails
for 4 months and datamapper is even newer to me.

I've been over and over your email but am still stuck. As per your
advice, I went to the console which confuses me usually but I realise
just how important it is. I think I have my associations set up
incorrectly still though and was actually just about to write to you.

You're correct - I am trying to associate groups with users. Users
(radcheck) are members of many groups and groups have many users. In
my view, I'm trying to edit the user and add the groups they belong to
via the checkboxes.

I already have a few set up in my db:

   +-------------+------------+----------+
    | username    | groupname  | priority |
    +-------------+------------+----------+
    | silverxxxx  | silverxxxx |        1 |
    | shushxx     | 30-minutes |        0 |
    | jennybluntx | silverxxxx |        1 |
    +-------------+------------+----------+

Ok, in the console if I run this:

p = Radcheck.find(23)

I get this:

<Radcheck @id=23 @username="silverxxxx" @attribute="User-Password"
@value="xxx" @op=":=">

That's fine. But if I run this:

p.group_groupnames

I get => nil

So, not only is it not saving, but it's not reading the db. That's why
I figure my relationships / names are screwed?

Thanks again, J
On Nov 8, 6:12 pm, Emmanuel Gomez <[email protected]> wrote:
> On Nov 8, 2011, at 2:08 AM, [email protected] wrote:
>
> > Thanks yoda.
>
> > The suggestion's not working with group_ids either
>
> Which suggestion? What did you do with group_ids?
>
> > I'll ask the same elsewhere. Thanks
>
> I know my tone was flippant, perhaps even condescending, but despite 
> appearances, I am trying to help :). I you gave me a bit more information, 
> I'd be in a better position to help.
>
> Or you can ask elsewhere,
> Emmanuel

-- 
You received this message because you are subscribed to the Google Groups 
"DataMapper" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/datamapper?hl=en.

Reply via email to