Documentation for nowAttachmentHandler

xiaix
Tera Guru

One thing that I find extremely frustrating with Helsinki release on upward is the severe lack of adequate documentation in the new docs.servicenow.com area.   The old Wiki is far superior (granted it much more mature), but even then there's a lot of "secret / hidden" functionality that's not documented.

*rant over*

I'm looking for documentation on the nowAttachmentHandler method, used in widget client scripts and used as a parameter in the main function().

I know of the following, however only vaguely:

ng-click="attachmentHandler.viewAttachment($event, attachment)"

ng-click="attachmentHandler.downloadAttachment(attachment)"

ng-blur="attachmentHandler.updateAttachment($event, attachment)"

ng-click="attachmentHandler.editAttachment($event, attachment)"

ng-file-select="attachmentHandler.onFileSelect($files)"

ng-click="attachmentHandler.openSelector($event)"

But where's the in-depth documentation explaining all the methods/properties/functions for nowAttachmentHandler ??

If it's posted somewhere and I just haven't found it yet, I'll eat crow.

5 REPLIES 5

xiaix
Tera Guru

I guess we can do stuff like this:


find_real_file.png


To see this:


find_real_file.png



Which led me to this: (your_instance_url) /scripts/angularjs-1.4/sn/common/attachments/factory.nowAttachmentHandler.js



So I'm forced to 'guess' how to use each nowAttachmentHandler() function.  



Oh well, it's a start.


xiaix
Tera Guru

Oh yeah, if you also pass in snAttachmentHandler:


find_real_file.png


and do this:


find_real_file.png



You get these lovelies:


find_real_file.png



which leads to this:   (your_instance_url) /scripts/angularjs-1.4/sn/common/attachments/factory.snAttachmentHandler.js



Again, how I wish this stuff was documented.


Kalaiarasan Pus
Giga Sage

I am of not much use on the topic of Service portal but the rant is valid.


Nilesh16
Tera Contributor

Being new to this topic I have checked this documentation as well as tried using this Directory but till now not been able to apply it to my Use Case, my use case is to upload the file and read data from that file your help will be greatly appreciated. Thanks!!