<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://greggsmith.net/wiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Zjz</id>
		<title>SDU - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="http://greggsmith.net/wiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Zjz"/>
		<link rel="alternate" type="text/html" href="http://greggsmith.net/wiki/index.php?title=Special:Contributions/Zjz"/>
		<updated>2026-07-29T13:54:16Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.26.1</generator>

	<entry>
		<id>http://greggsmith.net/wiki/index.php?title=Methods_handling&amp;diff=3269</id>
		<title>Methods handling</title>
		<link rel="alternate" type="text/html" href="http://greggsmith.net/wiki/index.php?title=Methods_handling&amp;diff=3269"/>
				<updated>2008-09-19T07:29:02Z</updated>
		
		<summary type="html">&lt;p&gt;Zjz: /* Parameters handling */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__&lt;br /&gt;
[[Category:Customizations]]&lt;br /&gt;
[[Category:r6]]&lt;br /&gt;
[[Category:r11]]&lt;br /&gt;
[[Category:Spel Code]]&lt;br /&gt;
{{Global Header}}&lt;br /&gt;
{{Global Announcement}}&lt;br /&gt;
== Method calling ==&lt;br /&gt;
Methods can be called from [[Object_Triggers|triggers]] or using [[Send_wait]] function.&lt;br /&gt;
&lt;br /&gt;
Here is an example of trigger (call method ''convert_request'' with one parameter):&lt;br /&gt;
&amp;lt;source lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
POST_VALIDATE convert_request( persistent_id ) 96 FILTER(EVENT(&amp;quot;INSERT&amp;quot;));&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Method definition ==&lt;br /&gt;
You can define new methods on every object. This definition must be in file with SPL extension in [[$NX_ROOT]]/site/mods/majic folder. In one file you can define more than one method and even for more than one class.&lt;br /&gt;
&lt;br /&gt;
Here is the base structure of new method called '''newMethod''' on object '''cr''' with variable number of parameters:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
void cr::newMethod (...)&lt;br /&gt;
{&lt;br /&gt;
    &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
Use method definition with ''(...)'' even if no parameters are expected.&lt;br /&gt;
&lt;br /&gt;
=== Parameters handling ===&lt;br /&gt;
Parameters are passed into the method in '''argv''' array. Each parameters are in triplets. Here is the explanation of argv values:&lt;br /&gt;
*argv[0] - number of parameters&lt;br /&gt;
*argv[1] - name of the first parameter&lt;br /&gt;
*argv[2] - previous value of the first parameter&lt;br /&gt;
*argv[3] - actual value of the first parameter&lt;br /&gt;
*argv[4] - name of the second parameter&lt;br /&gt;
*argv[5] - previous value of the second parameter&lt;br /&gt;
*argv[6] - actual value of the second parameter&lt;br /&gt;
and so on&lt;br /&gt;
&lt;br /&gt;
== Overriding methods ==&lt;br /&gt;
If you want to override some built-in method, simply define method with the same name (object::methodName) and write your new body.&lt;/div&gt;</summary>
		<author><name>Zjz</name></author>	</entry>

	<entry>
		<id>http://greggsmith.net/wiki/index.php?title=Attachments_Library&amp;diff=2374</id>
		<title>Attachments Library</title>
		<link rel="alternate" type="text/html" href="http://greggsmith.net/wiki/index.php?title=Attachments_Library&amp;diff=2374"/>
				<updated>2008-07-18T15:52:40Z</updated>
		
		<summary type="html">&lt;p&gt;Zjz: /* Tips */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Configuration]]&lt;br /&gt;
On a fresh install of r11, the attachment repositories of Knowledge and Service Desk are already configured and operational. Additional work is required when performing a migration. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Facts == &lt;br /&gt;
[[Image:r11_default_repositories.jpg|thumb|r11 Default Repositories Screenshot]]&lt;br /&gt;
&lt;br /&gt;
The attachment functionality uses Tomcat exclusively.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The attachment functionality resides on the Primary Server exclusively, even though the Repositories can exist anywhere.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Knowledge Tools and Service Desk utilize the same attachment mechanism, but have their own distinct requirements. In particular, every  Knowledge Repository ''must'' contain a folder, while the Service Desk Repository does not. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Tips ==&lt;br /&gt;
&lt;br /&gt;
Ensure your default Tomcat port (usually 8080) has firewall access for users outside of the firewall. Just because they have Service Desk access, which is usually the default port 80 used by IIS and Apache, do not assume they have access to attachments.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If directing users outside the firewall to a Secondary Server, ensure they have access to the Primary Server tomcat port&lt;br /&gt;
or&lt;br /&gt;
Add a repository deamon to your secondary server using pdm_edit and change your repositories to point to the secondary server (recommanded solution for external users as no additional port need to be open on the firewall).&lt;br /&gt;
Note that the physical folders for the repositories need to located on the secondary server too.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
[[Configure Java Client to Use Web Client for Uploading Attachments]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&amp;lt;div align='center'&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;To make corrections or additions to this article, select the ''edit'' tab above.&amp;lt;br&amp;gt;&lt;br /&gt;
To discuss or ask questions about this article, select the ''discussion'' tab above.&amp;lt;/font&amp;gt;&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Zjz</name></author>	</entry>

	</feed>