diff --git a/backend/modules/goods/controllers/GoodsController.php b/backend/modules/goods/controllers/GoodsController.php index 9284c30..ee91963 100755 --- a/backend/modules/goods/controllers/GoodsController.php +++ b/backend/modules/goods/controllers/GoodsController.php @@ -99,7 +99,7 @@ class GoodsController extends Controller $model->stock = -1; $model->is_taking = Goods::IS_TAKING_NO; $model->is_express = Goods::IS_EXPRESS_YES; - $model->express_type = Goods::EXPRESS_TYPE_EXPRESS_TEMPLAGE; + $model->express_type = Goods::EXPRESS_TYPE_EXPRESS_TEMPLATE; if ($model->load(Yii::$app->request->post()) && $model->validate()) { if ($model->uniform_postage) { $model->uniform_postage *= 100; diff --git a/backend/modules/goods/models/ars/Goods.php b/backend/modules/goods/models/ars/Goods.php index 7a6f23e..390587e 100755 --- a/backend/modules/goods/models/ars/Goods.php +++ b/backend/modules/goods/models/ars/Goods.php @@ -77,7 +77,7 @@ class Goods extends \yii\db\ActiveRecord const IS_EXPRESS_YES = 1; //是 //快递运费计算方式express_type const EXPRESS_TYPE_UNIFORM_POSTAGE = 1; //统一邮费 - const EXPRESS_TYPE_EXPRESS_TEMPLAGE = 2; //运费模板 + const EXPRESS_TYPE_EXPRESS_TEMPLATE = 2; //运费模板 public static $isTaking = [ self::IS_TAKING_NO => '否', @@ -89,7 +89,7 @@ class Goods extends \yii\db\ActiveRecord ]; public static $expressType = [ self::EXPRESS_TYPE_UNIFORM_POSTAGE => '统一邮费', - self::EXPRESS_TYPE_EXPRESS_TEMPLAGE => '运费模板' + self::EXPRESS_TYPE_EXPRESS_TEMPLATE => '运费模板' ]; public static $isSale = [ self::IS_SALE_NO => '不在售', diff --git a/backend/modules/goods/views/goods/express.php b/backend/modules/goods/views/goods/express.php index 5900968..df9ecb9 100755 --- a/backend/modules/goods/views/goods/express.php +++ b/backend/modules/goods/views/goods/express.php @@ -21,7 +21,7 @@ use backend\modules\shop\models\ars\ExpressTemplate; field($model, 'uniform_postage')->textInput() ?> -
+
field($model, 'express_template')->widget(Select2::className(), ["items" => ExpressTemplate::modelColumn()]) ?>