It's all about the answers!

Ask a question

Using Attribute From One Task and Display as Read-Only Under Another Task

Rob Olsen (3512153) | asked Jan 04 '18, 4:50 p.m.

I have configured Tasks that I have created in RTC.  One we'll call "Kinds of Plants" and another one we'll call "Flowering" and another "Non-Flowering".  (I know pretty weird but it's the point I need to get across, not my use of examples!  ;)  )

Anyway, you select the "Kinds of Plants" Task and I have multiple attributes, two being "Num of Fowering" and "Num of Non-Flowering".  You enter an integer value under each and "Save".  Then you select the "Flowering" task.  When that pops up, I want to display the "Num of Flowering" value from the other task in "read-only".  I have tried using "Reuse Existing Attribute" assuming that it would be set in one task and displayed in another, but it does not.  I tried using "Reuse Exisiting Sections" and therefore "shared content" and only display the one attribute, but that fails too.

I know this can be done, but I am missing something.  What am I doing wrong?

2 answers

permanent link
Ralph Schoon (63.3k33646) | answered Jan 04 '18, 5:30 p.m.
edited Jan 05 '18, 2:38 a.m.

No, Rob,

that can not be done OOTB and I seriously don't get why this should be possible. It is not in any of the compareable tools I am aware of that ever existed. "Reuse existing" in RTC Work Item Attribute Customization only ever allowed to configure to show the same data of the one work item (attribute) more often. Typing a number somewhere does not mean anything to software, unless you code up something.

Ralph Schoon commented Jan 04 '18, 5:40 p.m. | edited Jan 04 '18, 5:41 p.m.

You can potantially use very complex extensions to make this work. See for an example. You would need custom editor presentations and/or follow up actions to make that work and I would suggest to not go down that path.

Ralph Schoon commented Jan 05 '18, 2:27 a.m.

Another also likely expensive solution is a custom editor presentation. It would have to calculate the information to display automatically. So you would not really have an attribute, but the data would get displayed. This would be better, because you would not have to save any data when the numbers change. But because you don't have attributes, you could not use the data in queries and reports either.

Rob Olsen commented Jan 05 '18, 11:03 a.m.

Thanks Ralph.  I believe I got confused when I was thinking how I had done something similar before.  In a previous modified RTC Project I had attributes that were modifiable under a certain Task type.  I provided the customer the capability to then change that Task "type" to a different task in which those attributes were then displayed as "read-only".  This would be similar to "Task" and "Defect" types where you can set attributes in one (i.e. Task) and then switch the task type (i.e. Defect) and those attributes would now be displayed there.  That's not what I am looking to do in this case, I am not trying to take one record of one task type and switch it to task type. 

Ralph Schoon commented Jan 05 '18, 11:17 a.m. | edited Jan 05 '18, 11:18 a.m.

I can see how that would work Rob. That would just keep the data and just make the attribute or the presentation read only.

The new request is not so simple and there are no simple solutions for it, I would be aware of.

permanent link
Donald Nong (14.5k614) | answered Jan 04 '18, 7:44 p.m.

Rob, I think you have got confused with attributes and editor presentations, and also where the number comes from.

If I'm not mistaken, you want to display the number of "siblings" in the "Flowering" family as read-only when you view a "Flowering" task. The "Kinds of Plants" is the parent, or god, of the family.

If "Kinds of Plants" and "Flowering" are of different work item types, you can set the number presentation in the "Flowering" editor to read-only, always. But if they are of the same type (Task), you will need two attributes to hold the same number (not at the same time), say, "number of Flowering children" for "Kinds of Plants" and "number of siblings" for "Flowering".

In both cases, the number in the "Flowering" task has to be updated programmatically, as you cannot update it directly in the editor. You can consider the method Ralph suggested, but it will be a very expensive practice if you want to keep the number accurate all the time.

Rob Olsen commented Jan 05 '18, 11:18 a.m.

Thanks Donald.  Sounds like what I want to do is not as easy as I had thought.  I think I made this too complicated by using "Flowers"!  ;)

You have the right idea though.  I was assuming that I could just use an attribute set in the "parent" task and display that same attribute as "read-only" in the "child" task.  Apparently its not that easy.  

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.