Hi everyone.
In the action "Get File / Folder date", would it be possible to add the option to choose the wanted date?
In example : Created Date, Modified Date, Last Access Date.
Also, can we get a "Compare date" action. Basically it would enables us to compare if X date is equal, higher or lower than Y date. X date would be wither plugged or a variable. Y date would be plugged date, variable or a "forged date" like "3 months earlier". The action would need to fail if the date doesn't match the comparison. For functionnality, also add the option to not fail and save result in variable.
Why ?
I made an "Archiver" that will automatically archive 3 months old custom archives and logs we generate over other FB projects. I also made a weird but funtionnal step that auto-archive it's own archives and logs. It also archives FBServer's logs that are older than 3 months. (I had to create a delayed Scheduled Task since we have to restart FB's services).
My problems?
1) For now, it only verify the "modified date". So any frequently used projects will never get archived.
2) I had to compare the date in javascript for FBServer's log and in TSQL for the custom logs we've made. JS code bellow. Feel free to steal . "OlderThanMonths" is an integer variable and reprensents the "3" months. This is done in the "BeforeAction".
var fileDate = new Date(CurrentFBServerLogFileDate);
var oldestFileAllowedDate = new Date();
oldestFileAllowedDate = new Date(oldestFileAllowedDate.setMonth(oldestFileAllowedDate.getMonth() - OlderThanMonths));
// Do not archive if file is younger than the past X months. X = OlderThanMonths.
if (fileDate > oldestFileAllowedDate)
{
SkipAction = "True";
}
Thank you.
Hi everyone.
I just want a quick update on this, would it be feasible?
Thank you !