For a large scripts exist a trick to reduce the complexity of the Script Fields if you use classes that can be “common” and reused between other Script Fields.

For example, imagine we want to create a Script field that show a report HTML inside the tickets with the Lean metrics. Something like this:

Example

And we have a very large script to calculate this, but well-formed/encoded using CLASSES. In this case, if we use classes, we can reuse-it in other Script Fields (because when you save the scripts are compiled and available in the same classpath!)

Captura de pantalla 2019-04-07 a las 15.24.30

Now you can create another Script Field but with only the MAIN class!

(imports of the classes are not necessary)

Captura de pantalla 2019-04-07 a las 15.25.13

By MrAddon

Posted by:.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s