When displaying media items that are listed using umbraco.library.GetMedia, the createDate and updateDate properties are always identical. Always the same as the original createDate. So if i go into the media and update the media item (eg upload a different file on the same item), the updateDate does not get changed.
I am having the same issue on 4.6.1. Is there another way I can determine whether or not the media node has been updated? I tried 'version' but this does not work as well.
Hmm calling sender.Save() in a save event might cause an infinite loop :p. Since it's in the before save event the xml will probably get updated automatically. I guess you can forget what I said :).
Media updateDate not being updated
When displaying media items that are listed using umbraco.library.GetMedia, the createDate and updateDate properties are always identical. Always the same as the original createDate. So if i go into the media and update the media item (eg upload a different file on the same item), the updateDate does not get changed.
I am using umbraco 4.5.2
Is this a bug or my lack of understanding?
Paul
Try the last modified date (i.e. lastModifiedDate)
This isn't in the GetMedia() xml though...
for each <file> I only have
id,version,parentid,level,writerid,nodetype,template,sortorder,createdate,updatedate,nodename,urlname,writername,nodetypealias,path
hmm.. guess it's only part of a content node... odd.
I'll have to think about.. late here..
Anyone got any ideas about this?
I'd see if i could debug this myself but as i'm so new to umbraco i wouldnt know where to start...
I am having the same issue on 4.6.1. Is there another way I can determine whether or not the media node has been updated? I tried 'version' but this does not work as well.
Having same prob on 4.7.
I've added a bug to codeplex http://umbraco.codeplex.com/workitem/30467
Here's a work around, add this event handler to update the date.
If you update the media with this workaround you should also add this code:
That way the xml also get's updated if you use library.GetMedia.
Jeroen
Hmm calling sender.Save() in a save event might cause an infinite loop :p. Since it's in the before save event the xml will probably get updated automatically. I guess you can forget what I said :).
Jeroen
is working on a reply...