123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165 |
- <?php
- /**
- * Created by PhpStorm.
- * User: Administrator
- * Date: 2020-09-10
- * Time: 9:05
- */
-
- namespace app\back\controller;
-
-
- use cmf\controller\AdminBaseController;
- class CogController extends AdminBaseController
- {
- /**
- * @return mixed
- * 微信支付
- */
- public function wx()
- {
- $info = cmf_get_option('wxpay');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('wxpay',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
- /**
- * 技师端
- */
-
-
- /**
- * @return mixed
- * 支付宝支付配置
- */
- public function aly()
- {
- $info = cmf_get_option('alipay');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('alipay',$data,false);
- $this->success('保存成功');
- }
-
-
- $this->assign($info);
- return $this->fetch();
- }
-
- /**
- * @return mixed
- * 阿里云短信配置
- */
- public function alysms()
- {
- $info = cmf_get_option('alisms');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('alisms',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
-
- /**
- * 极光推送配置
- */
- public function jspus()
- {
- $info = cmf_get_option('jspus');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('jspus',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
-
- public function xiadan()
- {
- $info = cmf_get_option('xiadan');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('xiadan',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
-
- public function jiedan()
- {
- $info = cmf_get_option('jiedan');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('jiedan',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
-
- /**
- * @return mixed
- * @throws \think\Exception
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\ModelNotFoundException
- * @throws \think\exception\DbException
- * @throws \think\exception\PDOException
- * 接单距离设置
- */
- public function distance()
- {
- $info = cmf_get_option('distance');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('distance',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
-
- /**
- * @return mixed
- * @throws \think\Exception
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\ModelNotFoundException
- * @throws \think\exception\DbException
- * @throws \think\exception\PDOException
- * 下载设置
- */
- public function dow()
- {
- $info = cmf_get_option('dow');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('dow',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
-
- /**
- * 订单自动取消时长
- */
- public function duration()
- {
- $info = cmf_get_option('duration');
- if($this->request->isPost()){
- $data = $this->request->param();
- cmf_set_option('duration',$data,false);
- $this->success('保存成功');
- }
- $this->assign($info);
- return $this->fetch();
- }
- }
|