|
@@ -29,11 +29,11 @@ public function list()
|
|
|
$where = ['a.is_del' => 0,'b.is_del'=>0];
|
|
|
$start= isset($this->post['start']) && $this->post['start'] !== "" ? $this->post['start']:"";
|
|
|
if ($start !="") {
|
|
|
- $where = ["a.addtime"=>Db::raw(">= '{$start}'")];
|
|
|
+ $where['"a.addtime"']=Db::raw(">= '{$start}'");
|
|
|
}
|
|
|
$end = isset($this->post['end']) && $this->post['end'] !== "" ? $this->post['end'] :"";
|
|
|
if($end !=""){
|
|
|
- $where = ["a.addtime"=>Db::raw("<= '{$end}'")];
|
|
|
+ $where['"a.addtime"'] = Db::raw("<= '{$end}'");
|
|
|
}
|
|
|
$check_code = isset($this->post['check_code']) && $this->post['check_code'] !== "" ? trim($this->post['check_code']) : "";
|
|
|
if ($check_code !== "") {
|
|
@@ -41,7 +41,7 @@ public function list()
|
|
|
}
|
|
|
$wsm_code = isset($this->post['wsm_code']) && $this->post['wsm_code'] !== "" ? trim($this->post['wsm_code']) : "";
|
|
|
if ($wsm_code !== "") {
|
|
|
- $where['a.wsm_code'] = $wsm_code;
|
|
|
+ $where['a.wsm_code'] = Db::raw("like '%$wsm_code%'");
|
|
|
}
|
|
|
$apply_name = isset($this->post['apply_name']) && $this->post['apply_name'] !== "" ? trim($this->post['apply_name']) : "";
|
|
|
if ($apply_name !== "") {
|
|
@@ -49,7 +49,7 @@ public function list()
|
|
|
}
|
|
|
$type = isset($this->post['type']) && $this->post['type'] !== "" ? trim($this->post['type']) : "";
|
|
|
if ($type !== "") {
|
|
|
- $where['a.type'] = $apply_name;
|
|
|
+ $where['a.type'] = $type;
|
|
|
}
|
|
|
$apply_id = isset($this->post['apply_id']) && $this->post['apply_id'] !== "" ? intval($this->post['apply_id']) : "";
|
|
|
if ($apply_id!== "") {
|
|
@@ -72,6 +72,8 @@ public function list()
|
|
|
->join("supplier v","v.code=b.supplierNo","left")
|
|
|
->field("a.status,a.apply_id,a.apply_name,a.type,a.addtime,a.wsm_code,a.check_code,b.name,c.itemid,d.name as 'rename',a.id,v.name as 'caname',v.code")
|
|
|
->where($where)->order("addtime desc")->page($page,$size)->select();
|
|
|
+
|
|
|
+
|
|
|
return app_show(0,"获取成功",['count'=>$count,'list'=>$list]);
|
|
|
}
|
|
|
public function goodlist(){
|