更新转售商品查询条件

This commit is contained in:
yaooo 2023-08-24 09:47:36 +08:00
parent 0399c32f99
commit 494ba309d5

View File

@ -31,8 +31,8 @@ class CommunityDao extends BaseDao
{
$query = Community::hasWhere('author', function($query) use ($where){
$query->when(isset($where['username']) && $where['username'] !== '', function ($query) use($where) {
$merId = Db::name('merchant')->where('mer_name', $where['username'])->value('mer_id', -1);
$query->where('uid', $merId);
$uid = Db::name('merchant')->where('mer_name', $where['username'])->value('uid', -1);
$query->where('uid', $uid);
});
$query->where(true);
});