商家提货付款二维码

This commit is contained in:
liu 2024-03-15 16:55:01 +08:00
parent a6a7086df0
commit 3ee31f866a
2 changed files with 10 additions and 8 deletions

View File

@ -144,13 +144,6 @@ class Merchant extends BaseController
public function apply($merId) public function apply($merId)
{ {
// $withdrawal_pwd = $this->request->param('withdrawal_pwd');
// if(empty($withdrawal_pwd)) return \app('json')->fail('请输入提现密码');
// //找到商户的密码
// $userInfo = \app\common\model\system\merchant\Merchant::getDB()->with('user')->where('mer_id',$merId)->find()->toArray();
// if (!password_verify($pwd = (string)$withdrawal_pwd, $userInfo['user']['withdrawal_pwd']))
// return app('json')->fail('提现密码错误');
$merchant = app()->make(MerchantRepository::class)->search(['mer_id' => $merId])->field('uid,mer_id,mer_name,mer_money,financial_bank,financial_wechat,financial_alipay,financial_type,ot_margin')->find(); $merchant = app()->make(MerchantRepository::class)->search(['mer_id' => $merId])->field('uid,mer_id,mer_name,mer_money,financial_bank,financial_wechat,financial_alipay,financial_type,ot_margin')->find();
if (($msg = $this->checkAuth($merchant)) !== true) { if (($msg = $this->checkAuth($merchant)) !== true) {
return app('json')->fail($msg); return app('json')->fail($msg);
@ -182,7 +175,13 @@ class Merchant extends BaseController
public function createApply($merId) public function createApply($merId)
{ {
$data = $this->request->param(['extract_money', 'financial_type', 'financial_bank_name', 'financial_bank_bank', 'financial_bank_code', 'financial_bank_branch']); $data = $this->request->param(['extract_money', 'financial_type', 'financial_bank_name', 'financial_bank_bank', 'financial_bank_code', 'financial_bank_branch,withdrawal_pwd']);
$withdrawal_pwd = $data['withdrawal_pwd'];
if(empty($withdrawal_pwd)) return \app('json')->fail('请输入提现密码');
//找到商户的密码
$userInfo = \app\common\model\system\merchant\Merchant::getDB()->with('user')->where('mer_id',$merId)->find()->toArray();
if (!password_verify($pwd = (string)$withdrawal_pwd, $userInfo['user']['withdrawal_pwd']))
return app('json')->fail('提现密码错误');
$merchant = app()->make(MerchantRepository::class)->search(['mer_id' => $merId])->field('reg_admin_id,uid,mer_id,mer_name,mer_money,financial_bank,financial_wechat,financial_alipay,financial_type')->find(); $merchant = app()->make(MerchantRepository::class)->search(['mer_id' => $merId])->field('reg_admin_id,uid,mer_id,mer_name,mer_money,financial_bank,financial_wechat,financial_alipay,financial_type')->find();
if (($msg = $this->checkAuth($merchant)) !== true) { if (($msg = $this->checkAuth($merchant)) !== true) {
return app('json')->fail($msg); return app('json')->fail($msg);

View File

@ -29,6 +29,9 @@ Route::group('api/', function () {
Route::get('category/list_level', 'api.server.StoreCategory/list_level'); Route::get('category/list_level', 'api.server.StoreCategory/list_level');
//强制登录 //强制登录
Route::group(function () { Route::group(function () {
Route::get('scanPay/qrcode', 'api.store.order.ScanPay/qrcode');//商家二维码
Route::group('v2', function () { Route::group('v2', function () {
//新的下单接口,支持分账 //新的下单接口,支持分账
Route::group('order', function () { Route::group('order', function () {