add frontend ticket translations
This commit is contained in:
@@ -31,6 +31,19 @@ class CustomerController extends Controller
|
||||
'delete' => ['post'],
|
||||
],
|
||||
],
|
||||
'access' => [
|
||||
'class' => \yii\filters\AccessControl::className(),
|
||||
'only' => ['create', 'update','reception'],
|
||||
'rules' => [
|
||||
// allow authenticated users
|
||||
[
|
||||
'allow' => true,
|
||||
'roles' => ['@'],
|
||||
],
|
||||
// everything else is denied
|
||||
],
|
||||
],
|
||||
|
||||
];
|
||||
}
|
||||
|
||||
@@ -51,6 +64,7 @@ class CustomerController extends Controller
|
||||
* Lists all Customer models.
|
||||
* @return mixed
|
||||
*/
|
||||
/*
|
||||
public function actionIndex()
|
||||
{
|
||||
$searchModel = new CustomerSearch();
|
||||
@@ -61,19 +75,20 @@ class CustomerController extends Controller
|
||||
'dataProvider' => $dataProvider,
|
||||
]);
|
||||
}
|
||||
|
||||
*/
|
||||
/**
|
||||
* Displays a single Customer model.
|
||||
* @param integer $id
|
||||
* @return mixed
|
||||
*/
|
||||
/*
|
||||
public function actionView($id)
|
||||
{
|
||||
return $this->render('view', [
|
||||
'model' => $this->findModel($id),
|
||||
]);
|
||||
}
|
||||
|
||||
*/
|
||||
/**
|
||||
* Creates a new Customer model.
|
||||
* If creation is successful, the browser will be redirected to the 'view' page.
|
||||
@@ -147,13 +162,14 @@ class CustomerController extends Controller
|
||||
* @param integer $id
|
||||
* @return mixed
|
||||
*/
|
||||
/*
|
||||
public function actionDelete($id)
|
||||
{
|
||||
$this->findModel($id)->delete();
|
||||
|
||||
return $this->redirect(['index']);
|
||||
}
|
||||
|
||||
*/
|
||||
/**
|
||||
* Finds the Customer model based on its primary key value.
|
||||
* If the model is not found, a 404 HTTP exception will be thrown.
|
||||
|
||||
@@ -107,7 +107,7 @@ class TicketController extends Controller
|
||||
|
||||
if ($model->load(Yii::$app->request->post()) && $model->save()) {
|
||||
Yii::$app->session->setFlash('success', Yii::t('frontend/ticket', 'Ticket added to customer') );
|
||||
return $this->redirect(['index', 'number' => $receptionForm->card->number]);
|
||||
return $this->redirect(['product/sale', 'number' => $receptionForm->card->number]);
|
||||
} else {
|
||||
|
||||
$userTransfers = Transfer::modelsToArray( Transfer::readUserSoldTransfers($user) );
|
||||
|
||||
Reference in New Issue
Block a user