It's all about the answers!

Ask a question

Attribute customization


De'Shea Bennett (166) | asked Apr 10 '13, 6:16 p.m.
edited Apr 11 '13, 1:14 a.m. by Ralph Schoon (63.3k33646)
How is the class name set in the Attribute customization section for a script?

Comments
Sandy Grewal commented Apr 11 '13, 9:18 a.m.
JAZZ DEVELOPER

I am not sure I understand the scenario, can you please provide details?


De'Shea Bennett commented Apr 11 '13, 11:09 a.m.

In the RTC if you open a project, go to Process Configuration, Configuration Data, Work Items then Attribute Customization and choose a calculated value... you'll see the class name over to the right.

How is the class name set and what does it mean?

3 answers



permanent link
De'Shea Bennett (166) | answered Apr 11 '13, 11:08 a.m.

In the RTC if you open a project, go to Process Configuration, Configuration Data, Work Items then Attribute Customization and choose a calculated value... you'll see the class name over to the right.

How is the class name set and what does it mean?


permanent link
Ralph Schoon (63.3k33646) | answered Apr 11 '13, 11:15 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
As you can see in https://jazz.net/wiki/bin/view/Main/AttributeCustomization#API_Example and as described (I hope) in https://jazz.net/library/article/1093 lab 5 the class name is defined in the dojo.declare() statement and made visible outside using the dojo.provide() statement.



Comments
De'Shea Bennett commented Apr 11 '13, 11:25 a.m.

Ok. How do you know what the dojo.declare statement is suppose to be ?

How do you know when it should be

com.example.ValueProvider or APIExample?


Ralph Schoon commented Apr 11 '13, 11:38 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Well, you should use your own ID schema such as com.mycompany.script.something. You call it as you like. Just make sure provide and declare are the same and the ID is unique across your scripts.

How the rest of the class should look like (which funktion) is described in the links above and you get the right example code if you download it.


permanent link
Sandy Grewal (1.6k1223) | answered Apr 11 '13, 11:17 a.m.
JAZZ DEVELOPER
When seeing calculated value, the class name is only shown for "Script based calculated value" this is the class name that is defined in the attached javascript file. Check the javascript file for details of what the class.

Comments
De'Shea Bennett commented Apr 11 '13, 11:27 a.m.

I'm making the javascript file but I do not know what the Class name should be in the script. How does the developer decide what the class name is?


Sandy Grewal commented Apr 11 '13, 11:32 a.m.
JAZZ DEVELOPER

You can use any name that makes sense for your organization, like com.mycompany.SomeValidator etc.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.