Browse Source

Correction : probleme id_etablissement

prodstable
keun 7 years ago
parent
commit
3ec47e2995
1 changed files with 4 additions and 1 deletions
  1. +4
    -1
      backend/controllers/CommandeController.php

+ 4
- 1
backend/controllers/CommandeController.php View File

@@ -977,7 +977,10 @@ class CommandeController extends BackendController {
{
$produits = json_decode($produits) ;
$point_vente = PointVente::findOne($id_pv) ;
$production = Production::findOne(['date' => $date]) ;
$production = Production::findOne([
'date' => $date,
'id_etablissement' => Yii::$app->user->identity->id_etablissement
]) ;
if(preg_match("/^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$/",$date) &&
($id_user || strlen($username)) &&

Loading…
Cancel
Save