Hi,
I need to make a report for all changed models in the last 6 months.
It is easily possible to do it with a simple search with "Last change: Within the last 6 months".
But, what I am missing:
I would like to see when a model was initially created and who was the creater and the last user.
Also it would be nice to query for "free attributes".
Any ideas?
thx
Hi John,
you should get such a list by utilizing the report wizard. All fields, including custom fields, are in the report wizard available.
Regarding your wish to see only models that have been updated within the previous 30 days, you need to code some JavaScript lines.
Let me quickly explain how to do it:
You have a JavaScript behind your report (right mouse click > Edit Code). Within this code you may have some loops whereas the loop around your models is important:
this usually starts with
// repetition of queried data:
for(var i=0; i<p_aModel1.length; i++) {
right behind you see some lines like
p_output.TableRow()
....
....
and below a closing
}
What you need to do is now the following:
Add these lines right after the for loop:
// get today's date
var date = new Date();
// substitute the number of days you want
date.setDate(date.getDate() - 30);
// get the last change date
var lastChangeDate = new Date(p_aModel1[i].Attribute(Constants.AT_LAST_CHNG_2, nLocale).GetValue(false));
// validate if greater, and only then print it
if ( lastChangeDate > date ) {
now keep the code liks:
p_output.TableRow()
....
....
and add one more
}
for the "if", right in front of the existing }.
Just run your report now and you should have only models in it listed that have been changed within the previous 30 days.
Hope this covers your question. Let me know if it works for you!
Best Regards
Volker
by reporting wizard you mean this report?
This report is for Aris 7.1 and we are using Aris 7.02...
Hi,
The report wizard pops up automatically when you choose "New > Report" in one of the report groups, within the scripting area.
This wizard guides you along the main information about the report (name, level, criteria etc.).
The ouput is a WYSIWYG representation of your report, and you can add more objects as you require.
Hope this helps.
Regards, Volker