Page 1 of 1

Search , and zip and download.

PostPosted: Mon Mar 01, 2010 1:10 pm
by gmcust3
Any script around ? to

1) Search for Recording with some filter parameters.
2) Get a link to download the zip file , containing all those files , matching the criteria.

PostPosted: Mon Mar 01, 2010 1:27 pm
by williamconley
probably fairly simple to modify the admin backup script to do what you want

PostPosted: Tue Mar 02, 2010 10:02 am
by aouyar
I had worked in the implementation of the functionality you are describing in another project. The ARI application was used for browsing through recordings and the functionality was implemented as an add-on to this application. I think exactly the same logic can be implemented for Vicidial.

The ARI application was used to enter the search criteria like origin, destination. start / end date, etc. and the search results were displayed on a table. Then the user had the option to download a report in ZIP or ISO formats.

The process that generated the ZIP or ISO file was a batch process; the user would be given a link and after 30 seconds the user could download the ZIP or ISO file clicking on the link. The batch process would simply generate a temporary folder and copy in the recordings that comply with the search criteria and generate a nice HTML file with a table that contained one line of information for each recording and a relative link to the recording file. Finally the batch process generated a ZIP or ISO file from the folder.

PostPosted: Tue Mar 02, 2010 10:07 am
by mflorell
There is a CLI program that can do this on a batch process:
AST_VDsales_export.pl

It has many options, including zipping audio files together and FTPing them. We have used this with several clients.

PostPosted: Tue Mar 02, 2010 12:15 pm
by williamconley
Now THAT is cool.

And it will even email the results!

PostPosted: Tue Mar 02, 2010 12:25 pm
by mflorell
It will email a results flat file, but it will not email batch recordings since many email servers choke above 4MB attachments.

PostPosted: Tue Mar 02, 2010 12:30 pm
by williamconley
I liked that guys idea where it is put in a temp folder with an id link that expires in 30 minutes for those large files.

PostPosted: Tue Mar 02, 2010 12:40 pm
by mflorell
We have done that for clients as well, created a temp link to a recording file that was searched for then the file was deleted after 6 hours. It was an ugly hack actually because of the client's network setup, never actually created any distribution-worthy code.

PostPosted: Tue Mar 02, 2010 1:05 pm
by williamconley
I've bumped into this a lot on "third party" servers, but that always makes me nervous if you don't encrypt (and even if you do, really).

So a solution allowing this is something I may have to look into for a couple of our clients if they begin using that Cool Script.