I suspect that your question has been left unanswered because your
suggested solution sounds pretty solid. I can't think of a really
simple way to achieve what you want without having to change quite a
few views.
Personally, I wouldn't bother creating a new model for friendship
type. Do you need to be able to manage (e.g. Add, rename) friendship
types from the front end? I doubt that they are very dynamic. What I
would do would be to define in your locale resource file (e.g. en.yml)
a friendship_type collection:
e.g.
en:
friendship_type:
ft_0: Family
ft_1: Good Friend
ft_2: Acquaintance
You can then access these as a collection using something like:
I18n::t("friendship_type.ft_#{user.friendship.friendship_type}")
Anyway, this looks not to difficult, unless you want to allow people
to have multiple friendship types, then it starts getting interesting.
Goodluck!
On Nov 15, 9:06 pm, David Barnes <[email protected]> wrote:
> I would like to build a social network where members can be more
> specific (than just "friend") about their relationship to other
> members. For example, instead of "Request friendship", you can:
>
> "Request relative"
> "Request good friend"
> "Request acquaintance"
>
> Either via multiple links, or by a link and drop-down menu.
>
> Any suggestions on the best way to do this with CE? Would adding a
> new model like "friendship_type", and then keying into that with a new
> enumerated e.g. "friendship_type_id" be the way to go? I guess there
> would then be a bunch of views to change.
>
> Comments? Any obvious reason why my approach might fail?
>
> thanks - David.
--
You received this message because you are subscribed to the Google Groups
"CommunityEngine" 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/communityengine?hl=en.