|
@@ -60,12 +60,26 @@ public function waitlist(){
|
|
|
if($action_uid!=""){
|
|
|
$where[]=["a.action_uid","=",$action_uid];
|
|
|
}
|
|
|
- $count = Db::name('process_wait')->alias("a")->leftJoin("workflow b","a.order_type=b.order_type and a.order_code=b.order_code")->where($comd)->where($where)->count();
|
|
|
+ $count = Db::name('process_wait')
|
|
|
+ ->alias("a")
|
|
|
+ ->leftJoin("workflow b","a.order_type=b.order_type and a.order_code=b.order_code")
|
|
|
+ ->where($comd)
|
|
|
+ ->where($where)
|
|
|
+ ->count();
|
|
|
+
|
|
|
$total = ceil("$count/$size");
|
|
|
$page = $page>$total ? $total:$page;
|
|
|
- $list = Db::name('process_wait')->alias("a")->leftJoin("workflow b","a.order_type=b.order_type and a.order_code=b.order_code")
|
|
|
+ $list = Db::name('process_wait')
|
|
|
+ ->alias("a")
|
|
|
->field("b.apply_id,b.apply_name,a.addtime,a.action_uid,a.action_name,a.order_status,a.order_type,a.order_process,a.order_code,a.order_id,a.id")
|
|
|
- ->where($where)->where($comd)->page($page,$size)->order("a.addtime desc")->select();
|
|
|
+ ->leftJoin("workflow b","a.order_type=b.order_type and a.order_code=b.order_code")
|
|
|
+ ->where($where)
|
|
|
+ ->where($comd)
|
|
|
+ ->page($page,$size)
|
|
|
+ ->fetchSql()
|
|
|
+ ->order("a.addtime desc")
|
|
|
+ ->select();
|
|
|
+
|
|
|
$data=[];//->field("status,order_name,process_name")
|
|
|
foreach ($list as $value) {
|
|
|
$str = Db::name("process")->where(['process_type' => $value['order_type']])->field("process_name,status")->find();
|