<%@ page import="dbnp.studycapturing.Study" %> <g:message code="default.list.label" args="[entityName]" /> <% studyList = dbnp.studycapturing.Study.list() %> <% def att_list = ['template','startDate','events','samplingEvents','lastUpdated','readers','code','editors','ecCode','researchQuestion','title','description','owner','dateCreated'] %> <% def selectedStudies = [] %> <% def tmpList = [] %>

Studies Comparison

${flash.message}
<% params.each{key,values-> %> <% if (values=="on"){ %> <% tmpList.add(key) %> <% } }%> <% for (i in studyList) {%> <% if (tmpList.contains(i.getTitle())) { %> <% selectedStudies.add(i) %> <% }} %> <% /* Determine all template fields that are available in one or more templates used */ def allTemplateFields = [] selectedStudies.each { println it.giveFields(); allTemplateFields += it.giveFields() } allTemplateFields = allTemplateFields.unique(); %>

${studyIns.title}
Id ${fieldValue(bean: studyIns, field: "id")}
Template ${studyInse?.template?.encodeAsHTML()}
Title ${fieldValue(bean: studyIns, field: "title")}
Start
Date Created
Last updated
Events - ${studyIns.giveEventTemplates().name}
Sampling Events - ${studyIns.giveSamplingEventTemplates().name}
Owner ${studyIns?.owner?.encodeAsHTML()}
Readers -
  • ${r?.encodeAsHTML()}
  • Editors -
  • ${r?.encodeAsHTML()}
  • ${field.name} ${studyIns.getFieldValue(field.name)} -
    ${study.title}
    Id Species Name ${g}
    ${s.id} ${s.species} ${s.name} <% print s.getFieldValue(g.toString()) %>
    ${study.title}
    No events in this study
    Id Start time Duration Type Sampling event Parameters
    ${event.id} ${event.getPrettyDuration(study.startDate,event.startTime)} ${event.getPrettyDuration()} ${event.template.name} , ${field.name} = ${event.getFieldValue( field.name )}
    No event groups in this study
    ${study.title}
    Name Events Subjects
    ${eventTemplate.name}
    ${eventGroup.name} , ${field.name} = ${event.getFieldValue( field.name )} ${eventGroup.subjects.name.join( ', ' )}
    ${study.title}
    No assays in this study
    Assay Name Module Type Platform Url Samples
    ${assay.name} ${assay.module.name} ${assay.module.type} ${assay.module.platform} ${assay.module.url} ${assaySample.name}
    ${study.title}
    No persons involved in this study
    Name Affiliations Role Phone Email
    ${studyperson.person.firstName} ${studyperson.person.prefix} ${studyperson.person.lastName} ${studyperson.person.affiliations.name.join(', ')} ${studyperson.role.name} ${studyperson.person.phone} ${studyperson.person.email}
    Please select studies to compare.