Create Object (document) based on the last instance of a report - not a template

Good morning,
We are using M-Files more and more for our Reporting.

We have a Request from a user that they want to use the previous weeks document as the basis for the following week (the actual report document not the template).

How can this be done?


We already have a situation where we have a report template generated automatically every week once the report is sent out it will generate the following weeks template ready for adding information. This is a simple scenario because the following weeks report is based on a static (empty) template that is triggered once the previous weeks is circulated.

But in this instance, the user wants the next weeks report based on the previous weeks with content etc. included so they can just update the previous weeks report with changes.

The report is based on a workflow.

Thank you.

Patrick.

Parents
  • A simple approach could be to create a view that displays the recent reports, using for instance the Created or Last modified date in the view filter. The view filter could be for instance Class = Report AND Workflow state = Approved AND DaysFrom(Created) < 10. This should make it easy to locate the previous report and make a copy of it.

  • Thanks Joonas, but can M-Files then automatically "Create Object" that is Last report - this here sounds like a manual action required by the user?

  • Yes, this would require the user to use the Make Copy option to create a copy of the previous report. That's the easy approach that doesn't require wider customizations. 

    If that's not acceptable, we would need to understand in detail how they would like this to work. For instance, when should the copy be created automatically, which parts of the previous report's metadata should be copied to the new report, which workflow state should the new report go to and so on.

  • OK now I understand.
    Yes I guess that we will have to do this with customisations.


    We already have one class of report where the next weeks instance is automatically generated once the the current report is approved. We use the 'Count Date' functionalities to calculate the following weeks report start and end period based on the End Date of the previous weeks report. So we already have all of this implemented via Property Calculator - but the difficult part with this new class of report is having the following weeks report generated from the previous document (with all the report content - not metadata) - since the 'Create Object' functionality is based on a static document not a dynamic one.

Reply
  • OK now I understand.
    Yes I guess that we will have to do this with customisations.


    We already have one class of report where the next weeks instance is automatically generated once the the current report is approved. We use the 'Count Date' functionalities to calculate the following weeks report start and end period based on the End Date of the previous weeks report. So we already have all of this implemented via Property Calculator - but the difficult part with this new class of report is having the following weeks report generated from the previous document (with all the report content - not metadata) - since the 'Create Object' functionality is based on a static document not a dynamic one.

Children