aboutsummaryrefslogtreecommitdiff
path: root/db/migrations/1.61_remove_studygroupdozent.php
blob: 1b5ef43382295d0a17fc94240c58acac5efd5982 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<?php
class RemoveStudygroupdozent extends Migration
{
    function description () 
    {
        return 'removes the studygroup_dozent as a founder of all studygroups as well as the according entry in auth_user_md5 ';
    }

    function up ()
    {
        $db = DBManager::get();
        
        $db->exec("DELETE FROM seminar_user WHERE status = 'dozent' AND user_id = MD5('studygroup_dozent')");
        $db->exec("DELETE FROM auth_user_md5 WHERE user_id = MD5('studygroup_dozent')");
        
    }
}
?>