Changeset 351 for trunk


Ignore:
Timestamp:
Apr 19, 2010, 3:56:17 PM (10 years ago)
Author:
keesvb
Message:

removed EventDescription? and Protocol references from EventController?. Clean build should now work again.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/controllers/dbnp/studycapturing/EventController.groovy

    r288 r351  
    1818
    1919
    20     def createForEventDescription = {
     20    /*def createForEventDescription = {
    2121        if( params["id"]==null)
    2222        {
     
    3636            return [testo:params.clone(), sDate:eventInstance.startTime, eDate:eventInstance.endTime, description:eventInstance.eventDescription]
    3737        }
    38     }
     38    }*/
    3939
    4040
     
    204204        if( !(params['id']=~/^[\d]+$/) ) {
    205205
     206            /* Not needed anymore: replace by template check?
     207
    206208            def description = new EventDescription()
    207209            description.name = (params['name']==null || params['name'].replaceAll(/\S/,'').size()==0 ) ? '[no Name]' : params['name']
     
    215217            else {
    216218                description.errors.each{ println it }
    217             }
     219            }*/
    218220
    219221            def event = description.isSamplingEvent ? new SamplingEvent() : new Event();
     
    259261            // save basic changes in event and event description
    260262
     263            /* Not needed anymore: replace by template check?
     264
    261265            def description = event.eventDescription
    262266            def oldProtocol = description.protocol
     
    266270            description.description = (params['description']==null || params['description'].replaceAll(/\w/,'').size()==0 ) ? '[no description]' : params['description']
    267271            description.isSamplingEvent = params['isSamplingEvent']=='on' ? true : false
     272
     273            */
     274
    268275            event.startTime = new Date(params["startTime"])
    269276            event.endTime   = new Date(params["endTime"])
     277
     278
     279            /* Not needed anymore: replace by template check?
    270280
    271281
     
    290300                // add all new parameter values
    291301                parseParamsForParameterValues( params, event )
    292             }
     302
     303
     304            }
     305
     306            */
    293307
    294308
     
    316330            }
    317331
    318             ((Event)event).eventDescription=description
     332            //((Event)event).eventDescription=description
    319333
    320334
     
    391405            def sDate = new Date()
    392406            def eDate = new Date()
    393             def description = new EventDescription()
    394             return [eventInstance:eventInstance, testo:params.clone(), sDate:sDate, eDate:eDate, description:description, showSample:false, samples:null, createNew:true ]
     407            //def description = new EventDescription()
     408            return [eventInstance:eventInstance, testo:params.clone(), sDate:sDate, eDate:eDate,
     409                    //description:description,
     410            showSample:false, samples:null, createNew:true ]
    395411        }
    396412
     
    413429            }
    414430
    415             return [eventInstance:eventInstance, testo:params.clone(), sDate:eventInstance.startTime, eDate:eventInstance.endTime, description:eventInstance.eventDescription, showSample:showSample, samples:samples, createNew:false ]
     431            return [eventInstance:eventInstance, testo:params.clone(), sDate:eventInstance.startTime, eDate:eventInstance.endTime,
     432                    // description:eventInstance.eventDescription,
     433            showSample:showSample, samples:samples, createNew:false ]
    416434        }
    417435
Note: See TracChangeset for help on using the changeset viewer.