70 if(value instanceof WorkOrderClone) {
71 WorkOrder wo = ((WorkOrderClone) value).getEntity();
72 nameLayout.appendChild(
new Image(Images.getImage(
"workorder")));
73 nameLayout.appendChild(
new Label(wo.getDescription()));
74 }
else if(value instanceof OrderReferenceClone) {
75 OrderReference or = ((OrderReferenceClone) value).getEntity();
76 nameLayout.appendChild(
new Image(Images.getImage(
"reference")));
77 nameLayout.appendChild(
new Label(or.getSomeDescription()));
78 }
else if(value instanceof TaskClone) {
79 Task t = ((TaskClone) value).getEntity();
80 nameLayout.appendChild(
new Image(Images.getImage(
"task")));
81 nameLayout.appendChild(
new Label(t.getName()));
82 }
else if(value instanceof RequiredUsageClone) {
83 RequiredUsage ru = ((RequiredUsageClone) value).getEntity();
84 nameLayout.appendChild(
new Image(Images.getImage(ru.getType())));
85 nameLayout.appendChild(
new Label(ru.isHumanResourceType() ? ru.getHumanResourceAptitude().getName() : ru.getName()));
86 if(ru.hasResource()) {
87 nameLayout.appendChild(
new Space());
88 nameLayout.appendChild(
new Image(Images.getImage(
"resource")));
89 nameLayout.appendChild(
new Label(ru.getResource().getName()));
91 }
else if(value instanceof PredecessorClone) {
92 Predecessor p = ((PredecessorClone) value).getEntity();
93 nameLayout.appendChild(
new Image(Images.getImage(p.getType().toString())));
94 nameLayout.appendChild(LabelTypes.getSoftLabel(Application.getString(p.getType().toString())));
95 nameLayout.appendChild(
new Label(p.getPredecessor().getName()));
97 row.appendChild(nameLayout);
Hlayout getNameLayout(final Hierarchical value)