宝体数据调用接口
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

33 lines
818 B

<?php
namespace app\store\controller\apps\sharing;
use app\store\controller\Controller;
use app\store\model\sharing\Setting as SettingModel;
/**
* 拼团设置
* Class Setting
* @package app\store\controller\apps\dealer
*/
class Setting extends Controller
{
/**
* 拼团设置
* @return array|mixed
* @throws \think\exception\DbException
*/
public function index()
{
if (!$this->request->isAjax()) {
$values = SettingModel::getItem('basic');
return $this->fetch('index', compact('values'));
}
$model = new SettingModel;
if ($model->edit('basic', $this->postData('basic'))) {
return $this->renderSuccess('更新成功');
}
return $this->renderError($model->getError() ?: '更新失败');
}
}