Browse Source

Correction : impossible de supprimer la date de fin d'une commande récurrente

master
keun 7 years ago
parent
commit
e03708f75e
1 changed files with 10 additions and 2 deletions
  1. +10
    -2
      backend/controllers/CommandeautoController.php

+ 10
- 2
backend/controllers/CommandeautoController.php View File

->orderBy('order ASC') ->orderBy('order ASC')
->all(); ->all();


if($model->load(Yii::$app->request->post()) && $model->validate() && $model->save())
if($model->load(Yii::$app->request->post()) && $model->validate())
{ {
$this->redirect(['commandeauto/index']) ;
if(!strlen($model->date_fin)){
$model->date_fin = null ;
}
if($model->save())
{
$this->redirect(['commandeauto/index']) ;
}
} }
return $this->render('update',[ return $this->render('update',[

Loading…
Cancel
Save