cancel
Showing results for 
Search instead for 
Did you mean: 

Mass deletion of contract documents

Former Member
0 Kudos

Hi,

We have a request wherein a lot of Amendments / Contracts have been created on different Master agreements in error by different users.

Is there a way to mass delete them? Going into each MA and then navigating to Contract documents tab to delete one by one is tedious...

Thank you,

Vikram

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos
Hi Vikram,
the only iAPI which I found and could be of any use would be the one below. This would allow to go into a MA pick all the contract documents and collapse them into i.e. get rid of all the older versions.
Hope this helps.
Armin
voidpurge(ContractDocumentIBeanIfc doc)
          Deletes all Document versions objects prior to the latest one that is in the 'Executed' phase.
Former Member
0 Kudos

Thank you, I believe this is for deleting contract document versions from the contract document UI. We were actually looking to mass delete contract documents from the contract documents tab.

Thanks,

Vikram

Former Member
0 Kudos

Hi Vikram,

Hope you are doing good.

I have a method in mind. You can give this a try.

First step should be marking the documents you want to delete. This can be by creating a check box and then deactivating it from the UI after you have deleted the documents. Next, You will have to write a script that does the following:

  • Using the findAll() method available on Master Agreement class create a collection of all the MAs.
  • Iterate over this collection and use the getContractDocuments() method to get all the Contract Documents in that particular MA as a collection, say Coll2
  • Now iterate over Coll2, find all the Contract Docs which have the checkbox checked.
  • Use the delete(IBean Ifc) method available for all collections to delete these Contract Docs.

Please keep in mind that findAll() is a resource consuming method so this script should be run only when user load on the system is comparatively less.

Hope this helps.

Thanks

Devesh

Answers (0)