Content Manager Question

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Content Manager Question

Adrian Crum
I'm trying to debug the forum section of the Content Manager component and I need help.

In the eCommerce forum, Content.ownerContentId contains the contentId of the "parent" message -
which created a nice tree structure.

In the Content Manager forum, Content.ownerContentId always contains the contentId of the forum. The
tree structure is persisted in the ContentAssoc entity.

Which method of building the message tree is the preferred method?

-Adrian
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Adrian Crum
One other thing -

eCommerce forum ContentAssoc.contentIdTo contains the "child" message (or reply to "this" message).

Content Manager forum ContentAssoc.contentIdTo contains the "parent" message (the message "this"
message replied to).

Which method is correct?

Adrian Crum wrote:

> I'm trying to debug the forum section of the Content Manager component
> and I need help.
>
> In the eCommerce forum, Content.ownerContentId contains the contentId of
> the "parent" message - which created a nice tree structure.
>
> In the Content Manager forum, Content.ownerContentId always contains the
> contentId of the forum. The tree structure is persisted in the
> ContentAssoc entity.
>
> Which method of building the message tree is the preferred method?
>
> -Adrian
>
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Adrian Crum
Okay, I found a reply from Al Byers in a July 3, 2007 content management thread (user ml):

"So contentId is for the parent and contentIdTo is for the child."

Unless there are any objections, I will assume that is the correct method.

Adrian Crum wrote:

> One other thing -
>
> eCommerce forum ContentAssoc.contentIdTo contains the "child" message
> (or reply to "this" message).
>
> Content Manager forum ContentAssoc.contentIdTo contains the "parent"
> message (the message "this" message replied to).
>
> Which method is correct?
>
> Adrian Crum wrote:
>
>> I'm trying to debug the forum section of the Content Manager component
>> and I need help.
>>
>> In the eCommerce forum, Content.ownerContentId contains the contentId
>> of the "parent" message - which created a nice tree structure.
>>
>> In the Content Manager forum, Content.ownerContentId always contains
>> the contentId of the forum. The tree structure is persisted in the
>> ContentAssoc entity.
>>
>> Which method of building the message tree is the preferred method?
>>
>> -Adrian
>>
>
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

David E Jones

Yes, the contentIdTo should be the child.

Just think of it in terms of the primary use scenario: find a child content element (or sub-content) by using the contentId and a map-key (sorting and filtering by from/thruDate the same as we always do for effective dates).

-David


Adrian Crum wrote:

> Okay, I found a reply from Al Byers in a July 3, 2007 content management
> thread (user ml):
>
> "So contentId is for the parent and contentIdTo is for the child."
>
> Unless there are any objections, I will assume that is the correct method.
>
> Adrian Crum wrote:
>
>> One other thing -
>>
>> eCommerce forum ContentAssoc.contentIdTo contains the "child" message
>> (or reply to "this" message).
>>
>> Content Manager forum ContentAssoc.contentIdTo contains the "parent"
>> message (the message "this" message replied to).
>>
>> Which method is correct?
>>
>> Adrian Crum wrote:
>>
>>> I'm trying to debug the forum section of the Content Manager
>>> component and I need help.
>>>
>>> In the eCommerce forum, Content.ownerContentId contains the contentId
>>> of the "parent" message - which created a nice tree structure.
>>>
>>> In the Content Manager forum, Content.ownerContentId always contains
>>> the contentId of the forum. The tree structure is persisted in the
>>> ContentAssoc entity.
>>>
>>> Which method of building the message tree is the preferred method?
>>>
>>> -Adrian
>>>
>>
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

David E Jones
In reply to this post by Adrian Crum

If I remember right ownerContentId was used for security purposes, permissions and such. In fact, it should ONLY be used for this purpose.

I'm not sure how the permission checking code is working right now, but if it does a tree walk base on the ownerContentId then it doesn't matter which way is used. They would just be different ways of structuring content for security purposes, probably depending on the application.

-David


Adrian Crum wrote:

> I'm trying to debug the forum section of the Content Manager component
> and I need help.
>
> In the eCommerce forum, Content.ownerContentId contains the contentId of
> the "parent" message - which created a nice tree structure.
>
> In the Content Manager forum, Content.ownerContentId always contains the
> contentId of the forum. The tree structure is persisted in the
> ContentAssoc entity.
>
> Which method of building the message tree is the preferred method?
>
> -Adrian
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Adrian Crum
David,

Thank you for the replies! They are helpful.

-Adrian

David E Jones wrote:

>
> If I remember right ownerContentId was used for security purposes,
> permissions and such. In fact, it should ONLY be used for this purpose.
>
> I'm not sure how the permission checking code is working right now, but
> if it does a tree walk base on the ownerContentId then it doesn't matter
> which way is used. They would just be different ways of structuring
> content for security purposes, probably depending on the application.
>
> -David
>
>
> Adrian Crum wrote:
>
>> I'm trying to debug the forum section of the Content Manager component
>> and I need help.
>>
>> In the eCommerce forum, Content.ownerContentId contains the contentId
>> of the "parent" message - which created a nice tree structure.
>>
>> In the Content Manager forum, Content.ownerContentId always contains
>> the contentId of the forum. The tree structure is persisted in the
>> ContentAssoc entity.
>>
>> Which method of building the message tree is the preferred method?
>>
>> -Adrian
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

byersa
In reply to this post by David E Jones
Yes, the ownerContentId is strictly for security. Andrew did some clean up
and addition of service-based permission granting code, so make sure you see
those.

-Al

On 8/23/07, David E Jones <[hidden email]> wrote:

>
>
> If I remember right ownerContentId was used for security purposes,
> permissions and such. In fact, it should ONLY be used for this purpose.
>
> I'm not sure how the permission checking code is working right now, but if
> it does a tree walk base on the ownerContentId then it doesn't matter which
> way is used. They would just be different ways of structuring content for
> security purposes, probably depending on the application.
>
> -David
>
>
> Adrian Crum wrote:
> > I'm trying to debug the forum section of the Content Manager component
> > and I need help.
> >
> > In the eCommerce forum, Content.ownerContentId contains the contentId of
> > the "parent" message - which created a nice tree structure.
> >
> > In the Content Manager forum, Content.ownerContentId always contains the
> > contentId of the forum. The tree structure is persisted in the
> > ContentAssoc entity.
> >
> > Which method of building the message tree is the preferred method?
> >
> > -Adrian
>
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Ean Schuessler
On Thursday 23 August 2007 12:41:40 pm Al Byers wrote:
> Yes, the ownerContentId is strictly for security. Andrew did some clean up
> and addition of service-based permission granting code, so make sure you
> see those.

I looked at that permission code and it does seem flexible, but I have grave
concerns about normal humans being able to configure it successfully. Do you
see those permissions typically being set-up by an expert admin?

--
Ean Schuessler, CTO
[hidden email]
214-720-0700 x 315
Brainfood, Inc.
http://www.brainfood.com
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Adrian Crum
Ean,

I don't know what the original intention of the forum security scheme was. I posted an RFC a few
days ago about forum permissions:

http://mail-archives.apache.org/mod_mbox/ofbiz-dev/200708.mbox/%3c46D2ED5C.2030600@...%3e

I would like to see the forum permissions evolve into something like this:

Super User (admin)
----------
Create/update/delete Forum Groups, Forums, Forum Threads, Forum Messages
Create/delete Forum Group/Forum members (users and moderators)

User
----
Initially granted view permissions only
Granted Threads/Messages Create permissions when subscribed to a forum (a forum member)

Moderator
---------
Same permisssions as user
Permission to promote a user to a moderator
Granted Forum/Thread/Message delete permissions by Super User or another Moderator
Granted permission to Ban forum members

Do you think "normal human beings" could manage that permission system?

-Adrian

Ean Schuessler wrote:

> On Thursday 23 August 2007 12:41:40 pm Al Byers wrote:
>
>>Yes, the ownerContentId is strictly for security. Andrew did some clean up
>>and addition of service-based permission granting code, so make sure you
>>see those.
>
>
> I looked at that permission code and it does seem flexible, but I have grave
> concerns about normal humans being able to configure it successfully. Do you
> see those permissions typically being set-up by an expert admin?
>
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Ean Schuessler
On Friday 31 August 2007 10:14:31 am Adrian Crum wrote:

> Super User (admin)
> ----------
> Create/update/delete Forum Groups, Forums, Forum Threads, Forum Messages
> Create/delete Forum Group/Forum members (users and moderators)
>
> User
> ----
> Initially granted view permissions only
> Granted Threads/Messages Create permissions when subscribed to a forum (a
> forum member)
>
> Moderator
> ---------
> Same permisssions as user
> Permission to promote a user to a moderator
> Granted Forum/Thread/Message delete permissions by Super User or another
> Moderator Granted permission to Ban forum members

That all seems straightforward enough. I would assume the moderator permission
is on a forum by forum basis?

--
Ean Schuessler, CTO
[hidden email]
214-720-0700 x 315
Brainfood, Inc.
http://www.brainfood.com
Reply | Threaded
Open this post in threaded view
|

Re: Content Manager Question

Adrian Crum
Yes. All but the Super User would be on a forum by forum basis.


Ean Schuessler wrote:

> On Friday 31 August 2007 10:14:31 am Adrian Crum wrote:
>
>>Super User (admin)
>>----------
>>Create/update/delete Forum Groups, Forums, Forum Threads, Forum Messages
>>Create/delete Forum Group/Forum members (users and moderators)
>>
>>User
>>----
>>Initially granted view permissions only
>>Granted Threads/Messages Create permissions when subscribed to a forum (a
>>forum member)
>>
>>Moderator
>>---------
>>Same permisssions as user
>>Permission to promote a user to a moderator
>>Granted Forum/Thread/Message delete permissions by Super User or another
>>Moderator Granted permission to Ban forum members
>
>
> That all seems straightforward enough. I would assume the moderator permission
> is on a forum by forum basis?
>