From: Honza M. <hon...@ec...> - 2003-04-02 21:56:33
|
The best approach is to allways set the expiry date. If you are administrator of the slice, you shoud display the expiry date on the inputform or specify default value in Fields setting. On the other hand, we must count with such misconfigured slices, so YES, we should change the code to accept the NULL values as well. Your solution is good. Honza On =C8t, 2003-03-27 at 10:09, Mitra wrote: > A bug in something I did with RSS feeds has shown up a different bug=20 > that I think needs fixing - but I'm not sure ..... >=20 > If expiry_date is NOT set, for example because its not made required=20 > in the fields, then various things break, > specifically the Item_Manager wont display any item where expiry_date i= s null, >=20 > This is because it does a select .... where expiry_date > '$now' >=20 > This fails if there is no expiry_date, or no publish_date with=20 > Active count showing a number, but nothing appear in Item Manager >=20 > Unfortunately , the reverse is not true, so ..... NOT (expiry_date <=20 > '$now') also fails. >=20 > I've changed it in item_manager to expiry_date > $now OR=20 > expiry_date IS NULL which works fine, but haven't committed to CVS. >=20 > There are other places where expiry_date is tested against now=20 > specifically for example ... >=20 > getxml (and I can't figure out what its doing here) > searchlib - I think i can figure this out > util.php3:GetItemHeadlines > mailman , not clear whats happening here >=20 > and lots more .... >=20 > Any comments - does this need changing, ideally people could change=20 > it in their own code to save me breaking code I'm not familiar with. >=20 > - Mitra >=20 |