editmetadata.php.rej 590 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
*************** function createview1_cancel_submit() {
*** 141,147 ****
  }
  
  function createview1_validate(Pieform $form, $values) {
-     if ($values['startdate'] > $values['stopdate']) {
          $form->set_error('startdate', get_string('startdatemustbebeforestopdate', 'view'));
      }
  }
--- 141,147 ----
  }
  
  function createview1_validate(Pieform $form, $values) {
+     if ($values['startdate'] && $values['stopdate'] && $values['startdate'] > $values['stopdate']) {
          $form->set_error('startdate', get_string('startdatemustbebeforestopdate', 'view'));
      }
  }