商户 各接口
This commit is contained in:
parent
91935ddb7c
commit
7bec493ac7
@ -138,7 +138,7 @@ class Merchant extends BaseController
|
||||
->field(\think\facade\Db::raw('sum(A.product_num) as total,A.product_id,cart_info'))
|
||||
->whereBetweenTime('B.pay_time', $startDate, $endDate)
|
||||
->where('B.mer_id', $merId)
|
||||
->where('B.paid', 1)->group('A.product_id')->limit(30)->order('total DESC')->select();
|
||||
->where('B.paid', 1)->group('A.product_id')->limit(30)->order('total DESC')->fetchSql()->select();
|
||||
$totalCount = 0;
|
||||
foreach ($list as $item) {
|
||||
$totalCount += $item['total'];
|
||||
@ -168,7 +168,7 @@ class Merchant extends BaseController
|
||||
->join('Merchant C', 'C.mer_id = B.mer_id')
|
||||
->field(\think\facade\Db::raw('count(A.type_id) as total,B.image,B.store_name'))
|
||||
->whereBetweenTime('A.create_time', $startDate, $endDate)
|
||||
->where('A.type', 'product')->where('B.mer_id', $merId)->group('A.type_id')->order('total DESC')
|
||||
->where('A.type', 'product')->where('B.mer_id', $merId)->group('A.type_id')->order('total DESC')->fetchSql()
|
||||
->limit(30)->select();
|
||||
$totalCount = 0;
|
||||
foreach ($list as $item) {
|
||||
@ -200,7 +200,7 @@ class Merchant extends BaseController
|
||||
->whereBetweenTime('B.create_time', $startDate, $endDate)
|
||||
->where('A.mer_id', $merId)
|
||||
->where('B.product_type', 0)->where('B.is_pay', 0)->where('B.is_del', 0)
|
||||
->where('B.is_new', 0)->where('B.is_fail', 0)->group('A.product_id')->limit(30)->order('total DESC')->select();
|
||||
->where('B.is_new', 0)->where('B.is_fail', 0)->group('A.product_id')->limit(30)->order('total DESC')->fetchSql()->select();
|
||||
$totalCount = 0;
|
||||
foreach ($list as $item) {
|
||||
$totalCount += $item['total'];
|
||||
|
Loading…
x
Reference in New Issue
Block a user