作者 刘朕
1 个管道 的构建 通过 耗费 15 秒

数据导出调试

... ... @@ -15,7 +15,7 @@ use think\Db;
class TestController extends HomeBaseController
{
protected $uid = 309; //451
protected $uid = 267; //451
protected $complete = [83];
public function prob()
... ... @@ -33,9 +33,11 @@ class TestController extends HomeBaseController
5 => '已发货',
6 => '待取货'
];
$else_ids = [];
$indent_ids = Db::name('money_income')->where('uid',$uid)->group('indent_id')->column('indent_id');
foreach ($indent_ids as &$id) {
$v = Db::name('indent')->where('id',$id)->find();
// if(!$v) $else_ids[] = $id;
if($v['state'] == 3 || $v['state'] == 5) {
$money = Db::name('money_income')->where('uid',$uid)->where('indent_id',$v['id'])->value('money');
$fact_money = Db::name('money_income')->where('uid',$uid)->where('indent_id',$v['id'])->sum('money');
... ... @@ -59,6 +61,7 @@ class TestController extends HomeBaseController
];
}
}
// print_r($else_ids);exit;
// $indent = Db::name('indent')->where('salesman_uid',$uid)->order('create_time','desc')->select();
// $arr = collection($indent)->toArray();
// foreach ($arr as &$v) {
... ...