Commits

Nikola Trifunović  committed 7b102a5

Fix for bug #1 (Does not work if date field in that row is set to 0). Thanks to ReekrScream for reporting ;)

  • Participants
  • Parent commits ac0fddd

Comments (0)

Files changed (2)

File SwitchAction.php

             $model = $this->controller->loadModel($id);
             $model->updateAll(array($attribute=>0));
             $model->$attribute = 1;
-            $model->save();
+            $model->save(false);
             
             // if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser
             if(!isset($_GET['ajax']))

File ToggleAction.php

             // we only allow deletion via POST request
             $model = $this->controller->loadModel($id);
             $model->$attribute = ($model->$attribute==0)?1:0;
-            $model->save();
+            $model->save(false);
             
             // if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser
             if(!isset($_GET['ajax']))