@@ -68,6 +68,13 @@ use common\models\Producer ; | |||
.$addHintCredit); | |||
?> | |||
<?= $form->field($model, 'credit_functioning') | |||
->dropDownList([ | |||
'' => 'Paramètres globaux ('.Producer::$creditFunctioningArray[Producer::getConfig('credit_functioning')].')', | |||
Producer::CREDIT_FUNCTIONING_OPTIONAL => 'Optionnelle', | |||
Producer::CREDIT_FUNCTIONING_MANDATORY => 'Obligatoire', | |||
], []) ; ?> | |||
<div id="delivery-days"> | |||
<h2>Jours de livraison</h2> |
@@ -80,7 +80,7 @@ class PointSale extends ActiveRecordCommon | |||
[['name', 'code'], 'string', 'max' => 255], | |||
[['address', 'locality', 'infos_monday', 'infos_tuesday', | |||
'infos_wednesday', 'infos_thursday', 'infos_friday', | |||
'infos_saturday', 'infos_sunday'], 'string'], | |||
'infos_saturday', 'infos_sunday','credit_functioning'], 'string'], | |||
[['point_production', 'credit', 'delivery_monday', 'delivery_tuesday', | |||
'delivery_wednesday', 'delivery_thursday', 'delivery_friday', | |||
'delivery_saturday', 'delivery_sunday'], 'boolean'], | |||
@@ -119,6 +119,7 @@ class PointSale extends ActiveRecordCommon | |||
'delivery_saturday' => 'Samedi', | |||
'delivery_sunday' => 'Dimanche', | |||
'code' => 'Code', | |||
'credit_functioning' => 'Utilisation du Crédit par l\'utilisateur' | |||
]; | |||
} | |||
@@ -66,6 +66,11 @@ class Producer extends ActiveRecordCommon | |||
const CREDIT_FUNCTIONING_MANDATORY = 'mandatory' ; | |||
const CREDIT_FUNCTIONING_OPTIONAL = 'optional' ; | |||
public static $creditFunctioningArray = [ | |||
self::CREDIT_FUNCTIONING_MANDATORY => 'Obligatoire', | |||
self::CREDIT_FUNCTIONING_OPTIONAL => 'Optionnelle', | |||
]; | |||
var $secret_key_payplug ; | |||
/** |