31 lines
931 B
PHP
31 lines
931 B
PHP
<?php
|
|
/**
|
|
* SaaSMall商城系统 - 团队十年电商经验汇集巨献!
|
|
* =========================================================
|
|
* Copy right 2019-2029 上海牛之云网络科技有限公司, 保留所有权利。
|
|
* ----------------------------------------------
|
|
* 官方网址: https://www.gobuysaas.com
|
|
* =========================================================
|
|
*/
|
|
|
|
namespace addon\store\shopapi\controller;
|
|
|
|
use app\shopapi\controller\BaseApi;
|
|
|
|
class BaseStoreApi extends BaseApi
|
|
{
|
|
protected $store_id;
|
|
|
|
public function __construct()
|
|
{
|
|
//执行父类构造函数
|
|
parent::__construct();
|
|
|
|
$token = $this->checkToken();
|
|
if ($token['code'] != 0) exit($this->response($token));
|
|
if (!($this->app_module == 'shop' || $this->app_module == 'store')) exit($this->response($this->error([], 'NO_PERMISSION')));
|
|
|
|
$this->store_id = $this->user_info['site_id'];
|
|
}
|
|
}
|