|
@@ -38,7 +38,7 @@ class Zzququeu9 extends Start_Controller {
|
|
$this->_xs_two($arg_array);
|
|
$this->_xs_two($arg_array);
|
|
}
|
|
}
|
|
elseif($arg == 'add'){
|
|
elseif($arg == 'add'){
|
|
- $this->_add($arg_array);
|
|
|
|
|
|
+ $this->_add();
|
|
}
|
|
}
|
|
else
|
|
else
|
|
{
|
|
{
|
|
@@ -51,7 +51,6 @@ class Zzququeu9 extends Start_Controller {
|
|
|
|
|
|
if(isset($post['page']))
|
|
if(isset($post['page']))
|
|
{
|
|
{
|
|
- $where='1=1';
|
|
|
|
$page = $this->input->post('page',true);
|
|
$page = $this->input->post('page',true);
|
|
$perpage = $this->input->post('perpage',true);
|
|
$perpage = $this->input->post('perpage',true);
|
|
|
|
|
|
@@ -61,10 +60,14 @@ class Zzququeu9 extends Start_Controller {
|
|
$timetj = strtotime($timetj);
|
|
$timetj = strtotime($timetj);
|
|
|
|
|
|
$order_no = $this->input->post('order_no',true);
|
|
$order_no = $this->input->post('order_no',true);
|
|
|
|
+ $where='type = 10 ';
|
|
if($order_no){
|
|
if($order_no){
|
|
$where .= " and order_no = '".$order_no."' ";
|
|
$where .= " and order_no = '".$order_no."' ";
|
|
}
|
|
}
|
|
- if(empty($page))
|
|
|
|
|
|
+ if($timetk && $timetj){
|
|
|
|
+ $where .= " and create_time > ".$timetk." and create_time < ".$timetj." ";
|
|
|
|
+ }
|
|
|
|
+ if(empty($page))
|
|
{
|
|
{
|
|
$start = 0;
|
|
$start = 0;
|
|
$perpage = 1;
|
|
$perpage = 1;
|
|
@@ -154,17 +157,17 @@ class Zzququeu9 extends Start_Controller {
|
|
|
|
|
|
$dr_no = empty($v['dr_no'])?"":$v['dr_no'];
|
|
$dr_no = empty($v['dr_no'])?"":$v['dr_no'];
|
|
if($v['dr_status'] == 0){
|
|
if($v['dr_status'] == 0){
|
|
- $dr_no .= "<br>"."<span data-action='bzch' data-process='1' data-id='".$v['id']."' onclick='doAction(this)'>创建调入单</span>";
|
|
|
|
|
|
+ $dr_no .= "<br>"."<span data-action='dr' data-process='1' data-id='".$v['id']."' onclick='doAction(this)'>创建调入单</span>";
|
|
}elseif($v['dr_status'] == 1){
|
|
}elseif($v['dr_status'] == 1){
|
|
- $dr_no .= "<br>"."<span data-action='bzch' data-process='2' data-id='".$v['id']."' onclick='doAction(this)'>提交调入单</span>";
|
|
|
|
|
|
+ $dr_no .= "<br>"."<span data-action='dr' data-process='2' data-id='".$v['id']."' onclick='doAction(this)'>提交调入单</span>";
|
|
}elseif($v['dr_status'] == -1){
|
|
}elseif($v['dr_status'] == -1){
|
|
- $dr_no .= "<br>"."<span data-action='bzch' data-process='1' data-id='".$v['id']."' onclick='doAction(this)'>创建调入单</span>";
|
|
|
|
|
|
+ $dr_no .= "<br>"."<span data-action='dr' data-process='1' data-id='".$v['id']."' onclick='doAction(this)'>创建调入单</span>";
|
|
}elseif($v['dr_status'] == 2){
|
|
}elseif($v['dr_status'] == 2){
|
|
- $dr_no .= "<br>"."<span data-action='bzch' data-process='3' data-id='".$v['id']."' onclick='doAction(this)'>审核调入单</span>";
|
|
|
|
|
|
+ $dr_no .= "<br>"."<span data-action='dr' data-process='3' data-id='".$v['id']."' onclick='doAction(this)'>审核调入单</span>";
|
|
}elseif($v['dr_status'] == -2){
|
|
}elseif($v['dr_status'] == -2){
|
|
- $dr_no .= "<br>"."<span data-action='bzch' data-process='2' data-id='".$v['id']."' onclick='doAction(this)'>提交调入单</span>";
|
|
|
|
|
|
+ $dr_no .= "<br>"."<span data-action='dr' data-process='2' data-id='".$v['id']."' onclick='doAction(this)'>提交调入单</span>";
|
|
}elseif($v['dr_status'] == -3){
|
|
}elseif($v['dr_status'] == -3){
|
|
- $dr_no .= "<br>"."<span data-action='bzch' data-process='3' data-id='".$v['id']."' onclick='doAction(this)'>审核调入单</span>";
|
|
|
|
|
|
+ $dr_no .= "<br>"."<span data-action='dr' data-process='3' data-id='".$v['id']."' onclick='doAction(this)'>审核调入单</span>";
|
|
}
|
|
}
|
|
|
|
|
|
$list[] = [
|
|
$list[] = [
|
|
@@ -174,10 +177,11 @@ class Zzququeu9 extends Start_Controller {
|
|
'dc_no'=> $dc_no,
|
|
'dc_no'=> $dc_no,
|
|
'cg_no'=>$cg_no,
|
|
'cg_no'=>$cg_no,
|
|
'xs_no'=>$xs_no,
|
|
'xs_no'=>$xs_no,
|
|
|
|
+ 'dr_no'=>$dr_no,
|
|
'xs_two_no'=>$xs_two_no,
|
|
'xs_two_no'=>$xs_two_no,
|
|
'bzch_no'=>$bzch_no,
|
|
'bzch_no'=>$bzch_no,
|
|
//'bzsh_no'=>$bzsh_no,
|
|
//'bzsh_no'=>$bzsh_no,
|
|
- 'dr_no'=>$dr_no,
|
|
|
|
|
|
+
|
|
'create_time'=>date("Y-m-d H:i:s",$v['create_time']),
|
|
'create_time'=>date("Y-m-d H:i:s",$v['create_time']),
|
|
'update_time'=>date("Y-m-d H:i:s",$v['update_time'])
|
|
'update_time'=>date("Y-m-d H:i:s",$v['update_time'])
|
|
];
|
|
];
|
|
@@ -219,15 +223,14 @@ class Zzququeu9 extends Start_Controller {
|
|
public function _xs_two($arg_array){
|
|
public function _xs_two($arg_array){
|
|
|
|
|
|
}
|
|
}
|
|
- public function _add($arg_array){
|
|
|
|
- $order_no = $arg_array[0];
|
|
|
|
- if(empty($order_no)){
|
|
|
|
- exit("订单编码不存在");
|
|
|
|
- }
|
|
|
|
|
|
+ public function _add(){
|
|
|
|
+ $order_no = $this->input->post('order_no',true);
|
|
|
|
+ if(empty($order_no)){
|
|
|
|
+ echo json_encode(['msg'=>'请输入要添加的订单编码!','success'=>false]);exit;
|
|
|
|
+ }
|
|
$info = $this->logic_order->getInfo("number = '" .$order_no."'");
|
|
$info = $this->logic_order->getInfo("number = '" .$order_no."'");
|
|
if(empty($info)){
|
|
if(empty($info)){
|
|
- exit("订单不存在");
|
|
|
|
-
|
|
|
|
|
|
+ echo json_encode(['msg'=>'订单不存在!请仔细核对单号','success'=>false]);exit;
|
|
}
|
|
}
|
|
$num = $this->zzquque_u9->find_all("order_no = '".$info['number']."'");
|
|
$num = $this->zzquque_u9->find_all("order_no = '".$info['number']."'");
|
|
if(empty($num)){
|
|
if(empty($num)){
|
|
@@ -239,9 +242,9 @@ class Zzququeu9 extends Start_Controller {
|
|
'create_time'=>time(),
|
|
'create_time'=>time(),
|
|
'update_time'=>time(),
|
|
'update_time'=>time(),
|
|
]);
|
|
]);
|
|
- exit("ok".$info['number']);
|
|
|
|
|
|
+ echo json_encode(['msg'=>'添加成功','success'=>true]);exit;
|
|
}else{
|
|
}else{
|
|
- exit("error");
|
|
|
|
|
|
+ echo json_encode(['msg'=>'添加失败','success'=>false]);exit;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|