| 12345678910111213141516171819202122232425262728 |
- <?php
- namespace mall\controllers;
- use bizMall\goods\services\CategoryService;
- use bizMall\goods\services\GoodsCategoryService;
- use bizMall\goods\services\GoodsService;
- use bizMall\goods\services\GoodsSettingService;
- use Yii;
- use yii\web\Controller;
- use common\components\util;
- class GoodsController extends BaseController
- {
-
- //获取商品详情 shish 2019.12.3
- public function actionDetail()
- {
- $id = Yii::$app->request->get('id', 0);
- $info = GoodsService::getGoodsInfo($id);
- GoodsService::valid($info, $this->sjId);
- $setting = GoodsSettingService::getByCondition(['merchantId' => $this->sjId]);
- $commonIntro = isset($setting['goodsIntroduce']) ? $setting['goodsIntroduce'] : '';
- $info['commonIntro'] = $commonIntro;
- util::success($info);
- }
- }
|