List Info

Thread: RE: Deleting links when expiring stories




RE: Deleting links when expiring stories
user name
2007-06-07 08:37:23
>> Do we just need to use the second method and return
the template?
>> Or are we barking completely up the wrong tree?


>I'm not sure you're even in the right forest. ;)
>I'm kind of lost what's going on in the thread, though,
>so this is just a generic explanation, as far as I
understand things
>(might be wrong, I guess):
>
>Expiring is (unfortunately) not a time when templates
>get evaluated. It basically just runs backwards through
>the Actions you put in your Destination; usually
there's
>just the Move action, so when you Expire it'll just do
>the "undo_it" method of
lib/Bric/Dist/Action/Move.pm ,
>which deletes the file. No template burning going on.

>You could make your own Action if you wanted,
>though that's non-trivial (but easy).
>
>I don't think Bricolage handles this well,
>where you expire a story and want to update
>links to it. I think you basically have to have a
cronjob
>running that periodically republishes things. (no?)

I have coded this hack so that templates are re-executed
when a story
expires, but the code is not even committed to subversion
yet in Trunk
-- hopefully by mid-summer it will be.  Of course that
doesn't help you
now.

Are you sure you mean "expire" in the Bricolage
sense?  Could you just
remove the "expired" links when you republish the
story containing the
links?  That should be fairly straightforward using the
Story API.



Re: Deleting links when expiring stories
user name
2007-06-07 09:02:59
On Jun 7, 2007, at 9:37 AM, Beaudet, David P. wrote:

> I have coded this hack so that templates are
re-executed when a story
> expires, but the code is not even committed to
subversion yet in Trunk
> -- hopefully by mid-summer it will be.  Of course that
doesn't help  
> you
> now.

Can you go into more detail about how you went about this?

> Are you sure you mean "expire" in the
Bricolage sense?  Could you just
> remove the "expired" links when you republish
the story containing the
> links?  That should be fairly straightforward using the
Story API.

We could do this, but from  a usability standpoint, I think
it would  
be much much better to have the stories updated when the
story is  
expired for the reasons I outlined in my response to Scott.

Thanks,

Matt

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )