Last change
on this file since 7 was
7,
checked in by robert@…, 12 years ago
|
- Created tests for the synchronization and trash
- Improved synchronizationservice and trash
- Put authorization checks in several pages
|
File size:
574 bytes
|
Line | |
---|
1 | package nl.tno.metagenomics |
---|
2 | |
---|
3 | class AssaySampleController { |
---|
4 | |
---|
5 | /** |
---|
6 | * Shows information about this assaySample in dialog style |
---|
7 | */ |
---|
8 | def show = { |
---|
9 | AssaySample assaySample = AssaySample.get( params.id as long ); |
---|
10 | |
---|
11 | if( !assaySample ) { |
---|
12 | render "Sample not found"; |
---|
13 | return |
---|
14 | } |
---|
15 | |
---|
16 | if (!assaySample.assay.study.canRead( session.user ) ) { |
---|
17 | flash.error = "You don't have the right authorizaton to access sample " + assaySample.sample.name |
---|
18 | redirect(controller: 'study') |
---|
19 | return null |
---|
20 | } |
---|
21 | |
---|
22 | |
---|
23 | [assaySample: assaySample, entityType: params.entityType] |
---|
24 | } |
---|
25 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.