Ignore:
Timestamp:
Jan 21, 2015, 1:30:52 PM (8 years ago)
Author:
Nicklas Nordborg
Message:

References #1906: Display inherited annotations in list views

Implemented for bioassays in experiment.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/www/views/experiments/bioassays/list_bioassays.jsp

    r6604 r6691  
    103103try
    104104{
    105   final ItemQuery<AnnotationType> annotationTypeQuery = Base.getAnnotationTypesQuery(itemType);
     105  ItemQuery<AnnotationType> annotationTypeQuery = Base.getAnnotationTypesQuery(itemType);
    106106  SnapshotManager manager = new SnapshotManager();
    107107  for (AnnotationType at : annotationTypeQuery.list(dc))
    108108  {
    109109    annotationLoaders.add(new AnnotationLoaderUtil(dc, manager, at));
     110  }
     111  annotationTypeQuery = Base.getInheritedAnnotationColumns(cc.getSetting("columns"));
     112  for (AnnotationType at : annotationTypeQuery.list(dc))
     113  {
     114    annotationLoaders.add(new AnnotationLoaderUtil(dc, manager, at, false, true));
    110115  }
    111116  final BioAssaySet bioAssaySet = BioAssaySet.getById(dc, bioAssaySetId);
     
    192197      item="<%=itemType%>"
    193198      subclass="fulltable"
     199      data-inherited-annotations="true"
    194200      >
    195201      <tbl:hidden
     
    280286        %>
    281287        <tbl:columndef
    282           id="<%="at"+at.getId()%>"
    283           title="<%=HTML.encodeTags(at.getName())+" [A]"%>"
    284           property="<%="#"+at.getId()%>"
     288          id="<%=(loader.isSearchingInheritedAnnotations() ? "ia" : "at")+at.getId()%>"
     289          title="<%=HTML.encodeTags(at.getName())+(loader.isSearchingInheritedAnnotations() ? " [I]" : " [A]")%>"
     290          property="<%=(loader.isSearchingInheritedAnnotations() ? "##" : "#")+at.getId()%>"
    285291          annotation="true"
    286292          datatype="<%=at.getValueType().getStringValue()%>"
    287293          enumeration="<%=annotationEnum%>"
    288294          smartenum="<%=at.getDisplayAsList() %>"
    289           sortable="<%=at.getMultiplicity() == 1%>"
     295          sortable="<%=at.getMultiplicity() == 1 && !loader.isSearchingInheritedAnnotations()%>"
    290296          filterable="true"
    291297          exportable="true"
     
    528534                      %>
    529535                      <tbl:cell
    530                         column="<%="at"+loader.getId()%>"
     536                        column="<%=(loader.isSearchingInheritedAnnotations() ? "ia" : "at")+loader.getId()%>"
    531537                        ><tbl:cellvalue
    532538                          list="<%=loader.getValues()%>"
Note: See TracChangeset for help on using the changeset viewer.