删除商户同时删除store_service

This commit is contained in:
luofei 2023-05-31 10:22:10 +08:00
parent f8b060c1e7
commit 7ed8a2ea48

View File

@ -171,7 +171,7 @@ class Auth extends BaseController
$data['mer_info'] = [];
// 判断是否是商户,并且有没有完善信息
//这里有点小问题以后要修改
$store_service = Db::name('store_service')->where('uid', $data['uid'])->find();
$store_service = Db::name('store_service')->where('uid', $data['uid'])->where('is_del', 0)->find();
if ($store_service) {
$mer_arr = Db::name('merchant')->where('mer_id', $store_service['mer_id'])->where('is_del', 0)->where('status', 1)->field('type_id,mer_avatar,mer_banner,mer_info,category_id,service_phone,mer_address,uid,mer_name')->find();
if ($mer_arr && $mer_arr['mer_avatar'] != '' && $mer_arr['mer_banner'] != '' && $mer_arr['mer_info'] && $mer_arr['service_phone'] != '' && $mer_arr['mer_address'] != '') {