What I would like with the Combinews feature is group images by their publish date rather than the creation date.
For example I shot some pictures about 2 months ago with the images dates set 2 months back and the publish date set to today, but I can't get the "x new items in album y" news article on top of my previous ones
I have the combinews feature enabled with the "Latest images by album: thumbnail" option.
Tried changing the CombiNews Sort order, but none of the 3 options (id, date, mtime) give the result I want.
I thought mtime would group in the order uploaded but they are still grouped by image creation date, with the `getNewsDate()` function inside the `next_news` loop displaying the published date from last image, today??
Comments
You could open a ticket and then this probably can go into 1.4.3.
(As noted id and mime don't and can't really work directly as articles by definition are sorted by date only (maybe this sort orders should even be removed with 1.4.3...).)
Yeah publish dates are needed. I would like to set these automaticly on the date I upload the images (I'll FTP them to the server)
I guess I need to write a plugin with filter that sets the publish date?
Any tips welcome. Especially as in to about where I can change the creation date to publish date..
Yes for setting the publish date you need to create a filter. You need to read and understand the object model of Zenphoto first. (the publish date is actually meant to be used for scheduled publishing).
Sidenote, generally the ID is the order of discovery from the filesystem. So that roughly equals the publish order (unless you unpublished new items by default naturally).
Cheers acrylian for the hints!
`DATE_FORMAT(images.date,'%Y-%m-%d')`
to
`DATE_FORMAT(images.publishdate,'%Y-%m-%d')`
The resulting array from `getCombiNews()` looks good.
The `next_news()` loop groups the right articles by publishdate but I get
"0 new images in album X" and no thumbnails.
I am kinda stuck here..
I find the `getCombiNews()` function in use in
zp-extensions/zenpage/zenpage-template-functions.php
getNumNews()
next_news()
getLatestNews()
Sorry, I don't know that offhand and have also no time right now to dig into this in-between. Please create ticket and I will look into it for 1.4.3.
I needed to mod the `getNewsTitle()` and `getNewsContent()` queries from date -> publishdate
`... AS images WHERE publishdate LIKE ...`