修复:商户进入营销 - 积分 - 积分配置页面未显示任何内容
This commit is contained in:
parent
d180de0a70
commit
946f0f55ec
|
|
@ -81,7 +81,7 @@ class SystemConfigClassifyDao extends BaseDao
|
|||
* @author xaboy
|
||||
* @day 2020-03-31
|
||||
*/
|
||||
public function count()
|
||||
public function count(array $where = []): int
|
||||
{
|
||||
return SystemConfigClassify::getDB()->count();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ class GroupDao extends BaseDao
|
|||
* @author xaboy
|
||||
* @day 2020-04-01
|
||||
*/
|
||||
public function count()
|
||||
public function count(array $where = []): int
|
||||
{
|
||||
return SystemGroup::getDB()->count();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ class SmsRecordDao extends BaseDao
|
|||
* @author xaboy
|
||||
* @day 2020-05-18
|
||||
*/
|
||||
public function count()
|
||||
public function count(array $where = []): int
|
||||
{
|
||||
return SmsRecord::count($this->getPk());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -182,25 +182,13 @@ class Config extends BaseController
|
|||
return app('json')->success('删除成功');
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $key
|
||||
* @param ConfigClassifyRepository $configClassifyRepository
|
||||
* @return mixed
|
||||
* @throws DataNotFoundException
|
||||
* @throws DbException
|
||||
* @throws FormBuilderException
|
||||
* @throws ModelNotFoundException
|
||||
* @author xaboy
|
||||
* @day 2020-04-22
|
||||
*/
|
||||
|
||||
public function form($key, ConfigClassifyRepository $configClassifyRepository)
|
||||
{
|
||||
if (!$configClassifyRepository->keyExists($key) || !($configClassfiy = $configClassifyRepository->keyByData($key)))
|
||||
return app('json')->fail('配置分类不存在');
|
||||
if ($configClassifyRepository->existsWhere(['pid' => $configClassfiy->config_classify_id]))
|
||||
$form = $this->repository->tabForm($configClassfiy, $this->request->merId());
|
||||
else
|
||||
$form = $this->repository->cidByFormRule($configClassfiy, $this->request->merId());
|
||||
if (!$configClassifyRepository->keyExists($key) || !($configClassfiy = $configClassifyRepository->keyByData($key))) return app('json')->fail('配置分类不存在');
|
||||
if ($configClassifyRepository->existsWhere(['pid' => $configClassfiy->config_classify_id])) $form = $this->repository->tabForm($configClassfiy, $this->request->merId());
|
||||
else $form = $this->repository->cidByFormRule($configClassfiy, $this->request->merId());
|
||||
|
||||
return app('json')->success(formToData($form));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -36,8 +36,10 @@ Route::group(function () {
|
|||
]);
|
||||
|
||||
|
||||
})->middleware(AllowOriginMiddleware::class)
|
||||
})
|
||||
->middleware(AllowOriginMiddleware::class)
|
||||
->middleware(MerchantTokenMiddleware::class, true)
|
||||
->middleware(MerchantAuthMiddleware::class)
|
||||
->middleware(MerchantCheckBaseInfoMiddleware::class)
|
||||
->middleware(LogMiddleware::class);
|
||||
->middleware(LogMiddleware::class)
|
||||
;
|
||||
|
|
|
|||
Loading…
Reference in New Issue