Skip to main content
Topic: [Request]: Systemdate plugin (Read 2414 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

[Request]: Systemdate plugin

Hi,

I think that the possibility of calling via strings the systemdate with fb2k will make playlist generation based on dates really dynamic. i.e. let's take that you have a file added (tag %added%) today to fb2k, what would be the easy way to keep track of this file as fresh/new, and when it'll be rated as non-fresh?

If you find that 1 month (starting today) is the time a file should be tracked as new, then via extended playlist generator you can make a 'fresh' query that looks like this:

added GREATER 20041120 [today being 20041220]

the problem is that with this system you have to manually change the date everyday to keep an up-to-date query based on today systemdate.

If you can have a string that would call the systemdate, you wouldn't have to change this 'today' value anymore. You could just do something like this (i'm obviouly inventing here, I'll have to figure out the real strign query):

(%_systemdate% - 30) GREATER than added

[in fact it means that a file is tracked as new if systemdate minus 30 days is greater than the added tag]

It's also very useful to do stuff like autorating based on 'not played in XX days' or 'played int he last XX days' blablabla....

BTW, if someone is interested in my other useless request

[Request]: Systemdate plugin

Reply #1
i'm sure that we could request that from cwbowron and his great plugin

for the future - it would be really great it third party plugins could register as services extending foobar's formatting functions, so that you could for example store some data in external database or compute them on the fly and have them available in all places that use formatting ...

for start: give us dynamic variables, which would get substituted with data returned from their plugin when called with metadb handle.

there are some things that could be done to optimize this too ...

peter, please

[Request]: Systemdate plugin

Reply #2
Quote
i'm sure that we could request that from cwbowron and his great plugin [a href="index.php?act=findpost&pid=260824"][{POST_SNAPBACK}][/a]

Maybe, but I've requested so many things to him (and he did implemented it) that I prefer if another developper is interested  Anyway, I think that it should be available to any UI and by any plugin, so implementing it into a specific component and not having it available in other queries/formatting strings isn't the ebst way to implement it I guess...

[Request]: Systemdate plugin

Reply #3
yeah, but:

1/ it could be implemented by 3rd party plugin, but any other part of foobar would have to use that for its formatting parts to make use of it

2/ or you could make that part of the core, in which case other parts wouldn't have to support it explicitly

[Request]: Systemdate plugin

Reply #4
Quote
Quote
i'm sure that we could request that from cwbowron and his great plugin [a href="index.php?act=findpost&pid=260824"][{POST_SNAPBACK}][/a]

Maybe, but I've requested so many things to him (and he did implemented it) that I prefer if another developper is interested  Anyway, I think that it should be available to any UI and by any plugin, so implementing it into a specific component and not having it available in other queries/formatting strings isn't the ebst way to implement it I guess...
[a href="index.php?act=findpost&pid=260844"][{POST_SNAPBACK}][/a]


I just uploaded a new version of playlist tree that supports %sytemdate% function in queries...

Don't think just because you won't post in the foo_playlist_tree thread that I can't find you...

From the readme.txt:

%systemdate%
this tag in a query should get replaced by the current date in the form YYYYMMDD i.e. 20041220

You're right though, adding to a specific component isnt the best way to do it, its best if it was supported in the base functionality, but this is the best I can do...

I just do a very simple textual replace of the string %systemdate% with the current date in queries... hopefully that will work for what you want...
There used to be a link to my website here.

[Request]: Systemdate plugin

Reply #5
Quote
I just uploaded a new version of playlist tree that supports %sytemdate% function in queries...

Wow!  [no words]. 

Thanks

I'll play with it asap. Weeee! A new toy!

Quote
Don't think just because you won't post in the foo_playlist_tree thread that I can't find you...

Damn, I can't hide anywhere....

 
SimplePortal 1.0.0 RC1 © 2008-2019