[Bio] / SubsystemEditor / WebPage / ShowSubsystem.pm Repository:
ViewVC logotype

Diff of /SubsystemEditor/WebPage/ShowSubsystem.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.5, Thu Jan 17 21:43:41 2008 UTC revision 1.6, Fri Feb 15 16:58:13 2008 UTC
# Line 64  Line 64 
64      }      }
65    }    }
66    
67    if ( $user && $user->has_right( $self->application, 'edit', 'subsystem', $name ) ) {    if ( $user ) {
68        if ( $user->has_right( $self->application, 'edit', 'subsystem', $name ) ) {
69      $can_alter = 1;      $can_alter = 1;
70      $fig->set_user( $seeduser );      $fig->set_user( $seeduser );
71    }    }
72        else {
73          # we might have the problem that the user has not yet got the right for editing the
74          # subsystem due to that it was created in the old seed or what do I know where.
75          my $curatorOfSS = $fig->subsystem_curator( $name );
76          if ( $seeduser eq $curatorOfSS ) {
77            # now set the rights...
78            my $right = $dbmaster->Rights->create( { name => 'edit',
79                                                     scope => $user->get_user_scope,
80                                                     data_type => 'subsystem',
81                                                     data_id => $name,
82                                                     granted => 1,
83                                                     delegated => 0 } );
84            if ( $right ) {
85              $can_alter = 1;
86              $fig->set_user( $seeduser );
87            }
88          }
89        }
90      }
91    
92    ######################    ######################
93    # Construct the menu #    # Construct the menu #
94    ######################    ######################

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3