[solved] Automatic detouch attachments from mail
PostPosted:Fri Aug 22, 2014 11:03 am
by Fohnbit
Hello!
I have a scan mail address. All mails from this account has one ore more attachments.
Is it possible, that any attachment will be copy in a special folder after download?
I´m new in OKM and the search doesn´t bring a result for me.
Thank you!
Re: Automatic detouch attachments from mail
PostPosted:Sun Aug 24, 2014 8:13 am
by jllort
Yes it's possible the idea should be :
1- Import mail to openkm ( here you got several options, automatic, manual etc.. )
2- Create automation task to process mail creation ( post event ). Into automation you'll receive UUID, with it you can get Mail object OKMMail.getInstance().getProperties() (
http://doxygen.openkm.com/openkm/d3/d19 ... _mail.html) and iterate across the attachments (
http://doxygen.openkm.com/openkm/d9/d79 ... _mail.html ) if you got it ( each attachment is a document ). Then as a document you can move etc...
http://doxygen.openkm.com/openkm/de/de7 ... ument.html
The classes you should get under control are under com.openkm.api
http://doxygen.openkm.com/openkm/d9/d6d ... _1api.html
You could do it as a scripting but I suggest do your own java class ( you'll be able to debug while you build it etc... ), take a look here
http://wiki.openkm.com/index.php/Extend_automation_6.0 and also will be good idea configure development IDE
http://wiki.openkm.com/index.php/Developer_Guide
Re: Automatic detouch attachments from mail
PostPosted:Sun Aug 24, 2014 1:43 pm
by Fohnbit
Hello!
Wow, thank you for this details!
But I´m afraid I´m not so familiar with code and Java.
Thank you!
Re: Automatic detouch attachments from mail
PostPosted:Mon Aug 25, 2014 4:42 pm
by jllort
To get 100% power of application is good idea have got some java skills, because building java classes you can easilly extend some features, like automation and get application working on way you need.
Re: Automatic detouch attachments from mail
PostPosted:Mon Aug 25, 2014 5:44 pm
by Fohnbit
Ok, I will learn the next month
Thanks for your help(!)