|
@@ -18,6 +18,7 @@ class invoice extends DooModel {
|
|
*/
|
|
*/
|
|
public $iid;
|
|
public $iid;
|
|
public $lossIid;
|
|
public $lossIid;
|
|
|
|
+ public $ipSource;
|
|
/**
|
|
/**
|
|
*
|
|
*
|
|
* @var integer $status 审批状态
|
|
* @var integer $status 审批状态
|
|
@@ -193,6 +194,7 @@ class invoice extends DooModel {
|
|
public $_primarykey = 'iid';
|
|
public $_primarykey = 'iid';
|
|
public $_fields = array (
|
|
public $_fields = array (
|
|
'iid',
|
|
'iid',
|
|
|
|
+ 'ipSource',
|
|
'lossIid',
|
|
'lossIid',
|
|
'invoiceManage',
|
|
'invoiceManage',
|
|
'pendingApprovals',
|
|
'pendingApprovals',
|
|
@@ -268,6 +270,8 @@ class invoice extends DooModel {
|
|
if (is_numeric ( $iid ) && ! empty ( $iid ))
|
|
if (is_numeric ( $iid ) && ! empty ( $iid ))
|
|
$Detail = $this->getOne ( $condition );
|
|
$Detail = $this->getOne ( $condition );
|
|
|
|
|
|
|
|
+ if (empty($Detail))
|
|
|
|
+ return $Detail;
|
|
if (isset ( $Detail ['expressCompany'] ) && ! empty ( $Detail ['expressCompany'] )) {
|
|
if (isset ( $Detail ['expressCompany'] ) && ! empty ( $Detail ['expressCompany'] )) {
|
|
$express = explode ( ":", $Detail ['expressCompany'] );
|
|
$express = explode ( ":", $Detail ['expressCompany'] );
|
|
$Detail ['expressCompany'] = $express [0];
|
|
$Detail ['expressCompany'] = $express [0];
|
|
@@ -453,7 +457,7 @@ class invoice extends DooModel {
|
|
$list ['pendingInvoice'] = array ();
|
|
$list ['pendingInvoice'] = array ();
|
|
$list ['handleInvoice'] = array ();
|
|
$list ['handleInvoice'] = array ();
|
|
$list ['pendingInvoice'] = $this->find ( array ( // 加入邮件中也为 处理中 已退票
|
|
$list ['pendingInvoice'] = $this->find ( array ( // 加入邮件中也为 处理中 已退票
|
|
- 'where' => "((status=1 and untreadStatus=0) or (status=2 and printStatus=0 and untreadStatus=0) or ( status=2 and printStatus=1 and untreadStatus=0 ) or
|
|
|
|
|
|
+ 'where' => "((status=1 and untreadStatus=0) or (status=2 and printStatus=0 and untreadStatus=0) or
|
|
( status=2 and printStatus=1 and untreadStatus=1 and untreadPost=0)
|
|
( status=2 and printStatus=1 and untreadStatus=1 and untreadPost=0)
|
|
or (postStatus=0 and doPost=1 and status=2 and untreadStatus=0) ) and isDelete=0 and sid=" . $sid,
|
|
or (postStatus=0 and doPost=1 and status=2 and untreadStatus=0) ) and isDelete=0 and sid=" . $sid,
|
|
'desc' => 'iid',
|
|
'desc' => 'iid',
|
|
@@ -467,7 +471,7 @@ class invoice extends DooModel {
|
|
$list ['handleInvoice'] = $this->find ( array (
|
|
$list ['handleInvoice'] = $this->find ( array (
|
|
// 需求变更 -去除出票状态的数据 or (status=2 and printStatus=1 and untreadStatus=0 ) or (status=2 and printStatus=1 and untreadStatus=2 )
|
|
// 需求变更 -去除出票状态的数据 or (status=2 and printStatus=1 and untreadStatus=0 ) or (status=2 and printStatus=1 and untreadStatus=2 )
|
|
// 新加入退票中 需要邮寄的发票
|
|
// 新加入退票中 需要邮寄的发票
|
|
- 'where' => "(status=3 or status=4 or (status=2 and untreadStatus=2 ) or ( status=2 and untreadStatus=1 ) ) and isDelete=0 and sid=" . $sid,
|
|
|
|
|
|
+ 'where' => "(status=3 or status=4 or (status=2 and untreadStatus=2 ) or ( status=2 and untreadStatus=1 ) ) and isDelete=0 and sid=" . $sid,
|
|
'desc' => 'iid',
|
|
'desc' => 'iid',
|
|
'asArray' => TRUE
|
|
'asArray' => TRUE
|
|
) );
|
|
) );
|