Mailing List Archive

Category deactive/reactive issues
The business decided to no longer use a category, so I deactivated it.
Then, they decided they wanted it back, so I re-active it.

Everything works fine, except the new stories are not visible to the users. I can see it fine, as an administrator.
I checked group permissions for the category, and find that the reactivated category is not in the list of site categories.

Can someone point me to the SQL query that determines the list of categories displayed for a site group on the Group Permissions UI so that I can track down the missing or incorrect information in the database that is preventing the category from showing, and thereby not allowing non-admins access to the stories therein?

Thank you,
Adam W.
RE: Category deactive/reactive issues [ In reply to ]
Well, I found what I was looking for ultimately, which was the incorrect information in the DB.

SELECT category.id, site.name, directory, uri, category."name", category.description, category.parent_id,
asset_grp_id, category.active,grp.id as "Group ID", grp.parent_id, grp.class__id, grp."name", grp.description, grp.secret, grp.permanent,
grp.active
FROM category
left outer join site on site__id = site.id
inner join grp on asset_grp_id=grp.id and category.active <> grp.active

Can anyone think of an instance when this query should return data?

> -----Original Message-----
> From: users@lists.bricolagecms.org
> [mailto:users@lists.bricolagecms.org] On Behalf Of Adam Wilson
> Sent: Thursday, March 17, 2011 9:22 AM
> To: users@lists.bricolage.cc
> Subject: Category deactive/reactive issues
>
> The business decided to no longer use a category, so I deactivated it.
> Then, they decided they wanted it back, so I re-active it.
>
> Everything works fine, except the new stories are not visible to the
> users. I can see it fine, as an administrator.
> I checked group permissions for the category, and find that the
> reactivated category is not in the list of site categories.
>
> Can someone point me to the SQL query that determines the list of
> categories displayed for a site group on the Group Permissions UI so
> that I can track down the missing or incorrect information in the
> database that is preventing the category from showing, and thereby not
> allowing non-admins access to the stories therein?
>
> Thank you,
> Adam W.
Re: Category deactive/reactive issues [ In reply to ]
On Mar 17, 2011, at 6:55 AM, Adam Wilson wrote:

> Well, I found what I was looking for ultimately, which was the incorrect information in the DB.
>
> SELECT category.id, site.name, directory, uri, category."name", category.description, category.parent_id,
> asset_grp_id, category.active,grp.id as "Group ID", grp.parent_id, grp.class__id, grp."name", grp.description, grp.secret, grp.permanent,
> grp.active
> FROM category
> left outer join site on site__id = site.id
> inner join grp on asset_grp_id=grp.id and category.active <> grp.active
>
> Can anyone think of an instance when this query should return data?

No. How did you re-activate the category?

Best,

David
RE: Category deactive/reactive issues [ In reply to ]
I am unaware of a way to reactivate a category through the UI, so I was going into the category table and changing active to 't'.
It would seem that I also need to go into the grp table and do the same thing.

Is there another way to mark a category active?

> -----Original Message-----
> From: users@lists.bricolagecms.org
> [mailto:users@lists.bricolagecms.org] On Behalf Of David E. Wheeler
> Sent: Thursday, March 17, 2011 1:45 PM
> To: users@lists.bricolagecms.org
> Subject: Re: Category deactive/reactive issues
>
> On Mar 17, 2011, at 6:55 AM, Adam Wilson wrote:
>
> > Well, I found what I was looking for ultimately, which was the
> incorrect information in the DB.
> >
> > SELECT category.id, site.name, directory, uri, category."name",
> category.description, category.parent_id,
> > asset_grp_id, category.active,grp.id as "Group ID",
> grp.parent_id, grp.class__id, grp."name", grp.description, grp.secret,
> grp.permanent,
> > grp.active
> > FROM category
> > left outer join site on site__id = site.id
> > inner join grp on asset_grp_id=grp.id and category.active <>
> grp.active
> >
> > Can anyone think of an instance when this query should return data?
>
> No. How did you re-activate the category?
>
> Best,
>
> David
Re: Category deactive/reactive issues [ In reply to ]
On Mar 18, 2011, at 6:23 AM, Adam Wilson wrote:

> I am unaware of a way to reactivate a category through the UI, so I was going into the category table and changing active to 't'.
> It would seem that I also need to go into the grp table and do the same thing.

Right, that's just the bit you missed.

> Is there another way to mark a category active?

No.

Best,

David