MantisBT - ATutor
View Issue Details
0002707ATutor- no cat -public2006-08-10 09:432006-08-31 11:51
user2 
user2 
normalmajoralways
closedfixed 
 
1.5.3.3 
SVN
0002707: assignment cut off
entering a cut off date doesn't save if the due date is not set.
No tags attached.
Issue History
2006-08-10 09:43user2New Issue
2006-08-10 09:43user2Affects version => SVN
2006-08-30 07:31user2Note Added: 0002164
2006-08-30 08:53user2Statusnew => resolved
2006-08-30 08:53user2Fixed in Version => 1.5.4
2006-08-30 08:53user2Resolutionopen => fixed
2006-08-30 08:53user2Assigned To => user2
2006-08-31 11:51user2Statusresolved => closed

Notes
(0002164)
user2   
2006-08-30 07:31   
eek there is a better way of doing this:
if (($has_due_date == 'true') && ($late_submit == '2')){
    if ($cutoffyear < $dueyear){
        $msg->addError('CUTOFF_DATE_WRONG');
    } else if ($cutoffyear == $dueyear){
        if ($cutoffmonth < $duemonth){
            $msg->addError('CUTOFF_DATE_WRONG');
        } else if ($cutoffmonth == $duemonth){
            if ($cutoffday < $dueday){
                $msg->addError('CUTOFF_DATE_WRONG');
            } else if ($cutoffday == $dueday){
                if ($cutoffhour < $duehour){
                    $msg->addError('CUTOFF_DATE_WRONG');
                } else if ($cutoffhour == $duehour) {
                    if ($cutoffminute < $dueminute){
                        $msg->addError('CUTOFF_DATE_WRONG');
                    }
                }
            }
        }
    }
}