Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Editor Presentation for dropdown list populated from server side query, help!

Are there any samples of a custom editor presentation which is a dropdown list of single selectable elements?
(and also multi-select).. where the data is populated from a server side list (like the found in deliverable list)

I suppose I can go read the existing UI source.. but still need an external packaging structure..

the example in https://jazz.net/wiki/bin/view/Main/ContributingAttributePresentations is an output only thing generated in the code itself. Not data derived.

thanks for any guidance

0 votes



9 answers

Permanent link
You can specify that enumerations are stored in the database (rather than the process spec) and you can use a filtered http value set provider or a script-based value provider (see https://jazz.net/library/article/1003/#value-sets).

Or do you need something beyond what those options offer? Perhaps you could say a bit more about the data and how you want to present it.

0 votes


Permanent link
second time today value provider was brought up.

the 'found in' list of deliverable(s) from the project process configuration is too restrictive, and way too manual in its administration.

we also need Fixed in and Delivered Release,  all of which overlap, but are not symmetrical.

I have a new workitem type (delivery) to encapsulate the deliverable concept, and it has lots more data
but how to use it..  I have new link types as well, but they are too opaque, and hard to manage, (and the current UI shares workitem types with every project on the server.. ugh, see  restricted links)

so, I want a multi-select dropdown, which holds the object/handle/uuid/oid/?? of the workitem(s)  which match a workitem query of the subset of the delivery workitems in this project. (text string of the thing isn't enough)
 
it would ROCK to make the list of urls as OSLC links with a hover each.

the value provider could provide something, but I don't know what the use would be.  I could  get the workitem ids, or the summary text, but not present both, and finding your way back from there is hard.   I would need a multi select list of url types to combine some data, but still hard to report thru.

notice that Iteration planned is the coding phase, not the delivery phase.  some of our products do quarterly fixpack releases.. so they are accumulations of ready fixes ..We know in the future when we PLAN to release..  and in the PAST when we DID release.  there is a whole workflow around release, with approvals, etc.. and for fixes on the individual level was have some teams that cannot close a defect out until the customer signs their approval as well.  and there is a need to automation of all these movements. I just can't get all that from the release table in the project.

and yes, you can get really agile about it and say you can't release if you don't have an iteration, and .... etc..
but that is WAY too hard for everyone to execute.

0 votes


Permanent link
anybody?  this is starting to heat up again

0 votes


Permanent link
I really want to add my own datatype to the repository and then add my own presentations of that.. (which I think is documented).. lacking a datatype, looks like I would have to do something similar to the old multi-select string values..  define an attriute as "String', and hold some list of artifact identifier(s) there. (oid maybe)

0 votes


Permanent link
maybe making progress.. with custom attribute & presentation..

where do I find the definition of the classes in the WorkItemEditorToolkit..


0 votes

Comments

Sam, I typically use Plugin-Spy SHIFT-ALT-F1 to spy into the Eclipse UI to find things I know is being used in the Eclipse client.

thanks.. unfortunately, that doesn't display all the elements on the page.  Found In is not identified.

I have the deliverable class
com.ibm.team.workitem.ide.ui.internal.editor.presentations.Deliverable.

and I see the list built for the Releases page.. but not for the workitem.. (least its unclear to me)

and its still unclear to me the relationship between all the parts..
plugin for an attribute type, (what gets installed on client & server), such that there is a view in the process config editor, create attribute of type,
add to workitem, create workitem, which invokes the UI component of the attribute type for that instance.. (I think).
and the class hierarchy chain of the AttributePart makes the operation almost unintelligible. (to me)


Permanent link
Does anyone know the plugin layout here? it 'looks' like I need three plugins.  one for the registry, one for the server plugin (which handles the web UI presentation), and one for eclipse (which handles the eclipse UI presentation)
and later if this attribute has special handling for queries (query thru), I made need a query handler too (which appears to need two plugins, eclipse and web) 

I don't see how to create/install the 'attribute registry' plugin.

and secondarily, kind is a string, got it.. what attribute of what element does it need to match?



i've got these two sections of the plugin.xml
<code>
   <extension
         id="a.b.c.d"
         name="com.xx.delivery.workitem.presentation"
         point="com.ibm.team.workitem.ide.ui.editorPresentations">
      <editorPresentation
            class="com.xx.extensions.DeliverableFromWorkitem"
            id="com.xx.deliverablefromworkitem"
            needsAttribute="true">
                 <attributeType
                       deprecated="false"
                       id="string">
                 </attributeType>
      </editorPresentation>
   </extension>
   <extension
         point="com.ibm.team.workitem.common.attributeTypePresentationIdBinding">
      <attributeTypePresentationIdBinding
            attributeType="deliverablefromworkitemlist"
            presentationId="com.xx.deliverablefromworkitem">
      </attributeTypePresentationIdBinding>
   </extension>
</code>

I think  this stmt means I should remove the attributeTypePresentationIdBinding binding
 
The com.ibm.team.workitem.common.attributeTypePresentationIdBinding extension point
allows to bind a presentation id to an attribute type. Presentations configured with an attribute but without a
kind will use the presentation specified in this extension point. As our example is an additional presentation,
we will not register it to be default for boolean.


0 votes


Permanent link
Ok, finally got my class to be called..

net.. on the
<code>
<plugin>
   <extension point="com.ibm.team.workitem.ide.ui.editorPresentations">
      <editorpresentation <br="">             class="com.xx.extensions.DeliverableFromWorkitem"
            displayName="deliverablefromworkitem"
            id="com.xx.deliverablefromworkitem"
            needsAttribute="true">
                <attributetype id="smallString"/>
      </editorpresentation>
   </extension>   
</plugin>
</code>

the custom attribute must be of the type specified in the XML.
the system must SUPPORT that type, ie , you cannot 'invent' a new datatype
(that I have found yet!).

then in the PRESENTATION definition for that attribute, when the plugin is installed in Eclipse runtime you are using for the process configuration editing, the KIND

            displayName="deliverablefromworkitem"
should display in the Kind dropdown.

NOW, when u create a workitem of that type AND the tab with that presentation on it is brought to the foreground, the supporting class will be called
           
class="com.xx.extensions.DeliverableFromWorkitem"




0 votes


Permanent link
Hey Sam,
sorry, we don't really support adding new data types, nor adding custom presentations. All these extension points and APIs are internal APIs which can change any time. We also can not help you on how to use those.
Millard already summarized the supported options we have: Enumerations and http value sets.

0 votes

Comments

I am confused.. here is the documented way to add custom attribute presentations
https://jazz.net/wiki/bin/view/Main/ContributingAttributePresentations

I am thus using that model with defined extension points..
I understand that currently there is no support for adding new data types, but I can create a new presentation over an existing data type.

after working on this for a few days now, I see that combo will never really be a usable UI choice... so, like other type, I'll have to present a dialog to select things..I can use the combo to SHOW the already selected..


Permanent link
Information on supported APIs can only be found in Tech notes and the product documentation including the Javadocs of the SDK.
Wikis are used many things, including internal documentation, unreleased features and so on. Note that the header of the wiki page (the yellow box) states that. I understand that with all that information floating around it's not always easy to figure out what is internal and what is officially supported. Don't hesitate to contact us if in doubt.

0 votes

Your answer

Register or log in 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,936

Question asked: Feb 09 '13, 3:42 p.m.

Question was seen: 6,867 times

Last updated: May 07 '13, 8:40 a.m.

Confirmation Cancel Confirm