wang hou sheng 7 months ago
parent 9887082516
commit 4b5df7cbc2
  1. 33
      app/api/controller/Store.php
  2. 2
      app/common/enum/ServerEnum.php

@ -12,18 +12,17 @@ declare (strict_types=1);
namespace app\api\controller;
use app\api\service\Store as StoreService;
use app\api\service\User as UserService;
use app\api\validate\store\Store as StoreValidte;
use app\common\model\PriceSet;
use app\common\model\Store as StoreInfoModel;
use app\store\model\store\Address as AddressModel;
use think\response\Json;
use app\api\service\Store as StoreService;
use think\db\exception\DataNotFoundException;
use think\db\exception\DbException;
use think\db\exception\ModelNotFoundException;
use app\api\validate\store\Store as StoreValidte;
use \app\common\model\Store as StoreInfoModel;
use app\common\model\UploadFile;
use app\common\model\PriceSet;
use think\Db;
use think\response\Json;
/**
* 商城基础信息
* Class Store
@ -110,16 +109,11 @@ class Store extends Controller
StoreInfoModel::where('store_id', $storeid)->update($upData);
return $this->renderSuccess('ok');
}
public function getStoreInfo(): Json
{
$storeid = request()->header()['storeid'];
$info = StoreInfoModel::where('store_id',$storeid)->find()->toArray();
$file = UploadFile::where('file_id', $info['group_share_img_id'])->field('file_path,domain')->find();
$info['group_share_img'] = getUrl($file['file_path'], $file['domain']);
$file1 = UploadFile::where('file_id', $info['logo_image_id'])->field('file_path,domain')->find();
$info['logo_image'] = getUrl($file1['file_path'], $file1['domain']);
$info = StoreInfoModel::detail($storeid);
return $this->renderSuccess($info);
}
@ -172,6 +166,7 @@ class Store extends Controller
$model->addAll($inDatas);
return $this->renderSuccess('ok');
}
//加个设置回显
public function getStorePriceInfo(int $type): Json
{
@ -205,14 +200,4 @@ class Store extends Controller
}
}

@ -4,7 +4,7 @@ namespace app\common\enum;
class ServerEnum extends EnumBasics
{
// 待付款
// 待付款 10待付款20待指派30待上门40已完成50已取消
const APPLYPAY = 10;
// 待派单
const APPLYDISPATCH = 20;

Loading…
Cancel
Save