Hi community, I am trying to call a image from a contact form, that's already working, at least when I put manually the image on the folder that I using for; well I want to charge the images from the CA SDM attachment functionality, here is the problem, when I upload the image just lost the name because it put a persid_name.png.gz. something like "9E56F44C42D27B479CCA46B5CA9C06DC_default_profile.png.gz"... and from the form I call it like "default_profile.png", of course are thousands of images with a name like id and from the cnt form is imposible know that attach name.
conclusion: I want to know if I can upload a image in CA SDM without lost the original name, I want to save it in the repository with the same name that was loaded.
I really appreciate your help,
Thanks in advance
I think there is no need to change generated file name, you can fetch it via PDM_LIST.
Generally Service Desk attachments have followed attribtes:
Code will look like:
<PDM_LIST PREFIX=list WHERE="file_name like '$args.userid'" FACTORY=attmnt>if (Number($list.id) > 0) alert('$list.attmnt_name');</PDM_LIST>
<PDM_LIST PREFIX=list WHERE="file_name like '$args.userid'" FACTORY=attmnt>
if (Number($list.id) > 0) alert('$list.attmnt_name');
BTW: If you plan to call that data frequently, I think that better to perform some actions to link data via SREL, because fetching data from huge factories can cause system lags.
Thanks for reply the topic, at the end I think I will do it with PAM, because are so many images and it will take a long time to load the form.
I will post when I solve it.