Changeset 878


Ignore:
Timestamp:
Sep 8, 2010, 2:48:26 PM (8 years ago)
Author:
keesvb
Message:

finally found that nasty nasty persistance bug which was also leading to the serialUID difference bugs. There was a redundant getSamples method in SamplingEvent?!!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/domain/dbnp/studycapturing/SamplingEvent.groovy

    r874 r878  
    8080                groups.each { eventgroup ->
    8181                        if (!eventFound) {
    82                                 eventFound = (that.id in eventgroup.events.id);
     82                                eventFound = (that.id in eventgroup.samplingEvents.id);
    8383                        }
    8484                }
    8585
    8686                return eventFound;
    87         }       
    88 
    89         /**
    90          * Get all samples that have this sampling event as a parent
    91          * @return Map
    92          */
    93         def getSamples() {
    94                 def samples = Sample.findAll("from Sample as s where s.parentEvent.id = ${this.id}")
    95                 samples.collect { it.class == SamplingEvent.class }
    96                 samples.collect { it != null }
    97                 return samples == null ? [] : samples
    9887        }
    9988
Note: See TracChangeset for help on using the changeset viewer.