|
@@ -100,12 +100,13 @@ class InvoiceController extends DooController {
|
|
|
Doo::loadClass ( 'XDeode' );
|
|
|
$XDeode = new XDeode ( 5 );
|
|
|
$sid = $XDeode->decode ( $_COOKIE ["staff"] );
|
|
|
- $expressList = $express->getExpressByAll ();
|
|
|
+ //$expressList = $express->getExpressByAll ();
|
|
|
$invoiceList = $invoice->getMyInvoice ( $sid );
|
|
|
|
|
|
// $list = $invoiceReceivables->getInvoiceReceivablesByClaim ( $this->staff [0] ['cid'], $this->staff [0] ['sid'] );
|
|
|
|
|
|
- $sql = 'status=2 and untreadStatus=3 and sid=' . $sid;
|
|
|
+
|
|
|
+ $sql = 'status=2 and printStatus=1 and irid!="" and sid=' . $sid;
|
|
|
$list = $invoice->getInvoiceByUntreadStatusPage ( 4, $sql );
|
|
|
|
|
|
// print_r($list);
|
|
@@ -113,7 +114,7 @@ class InvoiceController extends DooController {
|
|
|
$this->data ['isMonth'] = $isMonth;
|
|
|
$this->data ['htm'] = $htm;
|
|
|
|
|
|
- $this->data ['expressList'] = $expressList;
|
|
|
+ //$this->data ['expressList'] = $expressList;
|
|
|
$this->data ['invoiceList'] = $invoiceList;
|
|
|
|
|
|
$this->data ['receivablesList'] = $list;
|
|
@@ -599,8 +600,8 @@ class InvoiceController extends DooController {
|
|
|
return "/invoice";
|
|
|
}
|
|
|
/**
|
|
|
+ * @deprecated
|
|
|
* 申请退票 --需求变更 废弃
|
|
|
- */
|
|
|
function invoiceUntreadDo() {
|
|
|
$untreadIidKey = $this->get_args ( 'untreadIidKey' ) ? $this->get_args ( 'untreadIidKey' ) : '';
|
|
|
$untreadReason = $this->get_args ( 'untreadReason' ) ? $this->get_args ( 'untreadReason' ) : "";
|
|
@@ -656,7 +657,8 @@ class InvoiceController extends DooController {
|
|
|
|
|
|
return "/invoice";
|
|
|
}
|
|
|
-
|
|
|
+ */
|
|
|
+
|
|
|
/**
|
|
|
* 删除已终止的开票
|
|
|
*/
|
|
@@ -1164,7 +1166,10 @@ class InvoiceController extends DooController {
|
|
|
$category = $lCategory->getCategory ();
|
|
|
$staffList = $staff->getStaffByCid ( $this->staff [0] ['cid'] );
|
|
|
|
|
|
- $receivablesList = $invoiceReceivables->getInvoiceReceivablesByNew ();
|
|
|
+ $sql = 'bindStatus=1 and iid!=0';
|
|
|
+ $receivablesList = $invoiceReceivables->getInvoiceReceivablesByNew (4,$sql);
|
|
|
+
|
|
|
+
|
|
|
// 获取未入账发票
|
|
|
$invoiceUnAccount = $invoice->getInvoiceByUnAccount ( $invoiceTC );
|
|
|
|
|
@@ -1619,8 +1624,8 @@ class InvoiceController extends DooController {
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
- * 收款绑定发票 ,一个收款只能绑定一个发票
|
|
|
- */
|
|
|
+ * @deprecated
|
|
|
+ * 收款绑定发票 ,一个收款只能绑定一个发票 --废弃
|
|
|
function invoiceBindReceivables() {
|
|
|
$claimKey = $this->get_args ( 'key' ) ? $this->get_args ( 'key' ) : "";
|
|
|
$invoiceKey = $this->get_args ( 'invoiceKey' ) ? $this->get_args ( 'invoiceKey' ) : "";
|
|
@@ -1682,10 +1687,11 @@ class InvoiceController extends DooController {
|
|
|
|
|
|
return "/invoiceReceivables";
|
|
|
}
|
|
|
+ */
|
|
|
|
|
|
/**
|
|
|
+ * @deprecated
|
|
|
* 发票收款完成--需求更变 废弃
|
|
|
- */
|
|
|
function invoiceEnterReceivables() {
|
|
|
$invoiceKey = $this->get_args ( 'key' ) ? $this->get_args ( 'key' ) : "";
|
|
|
// $invoiceClaim = $this->get_args ( 'invoiceClaim' ) ? $this->get_args ( 'invoiceClaim' ) : "";
|
|
@@ -1744,6 +1750,8 @@ class InvoiceController extends DooController {
|
|
|
|
|
|
return "/invoice";
|
|
|
}
|
|
|
+ */
|
|
|
+
|
|
|
function invoiceAggregate() {
|
|
|
$year = $this->get_args ( 'year' ) ? $this->get_args ( 'year' ) : date ( "Y" );
|
|
|
|
|
@@ -2365,8 +2373,8 @@ class InvoiceController extends DooController {
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
- * 获得与我有关可收款的发票
|
|
|
- */
|
|
|
+ * @deprecated
|
|
|
+ * 获得与我有关可收款的发票 废弃
|
|
|
function ajaxGetInvoiceByStaff() {
|
|
|
$irid = $this->get_args ( 'key' ) ? $this->get_args ( 'key' ) : "";
|
|
|
Doo::loadModel ( 'invoice' );
|
|
@@ -2429,6 +2437,7 @@ class InvoiceController extends DooController {
|
|
|
'html' => $html
|
|
|
) );
|
|
|
}
|
|
|
+ */
|
|
|
|
|
|
/**
|
|
|
* 获取一条收款信息
|
|
@@ -2523,8 +2532,8 @@ class InvoiceController extends DooController {
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
+ * @deprecated
|
|
|
* --需求变更 废弃
|
|
|
- */
|
|
|
function ajaxCompareClaimPrice() {
|
|
|
$irid = $this->get_args ( 'irid' ) ? $this->get_args ( 'irid' ) : "";
|
|
|
$invoiceKey = $this->get_args ( 'invoiceKey' ) ? $this->get_args ( 'invoiceKey' ) : "";
|
|
@@ -2654,10 +2663,11 @@ class InvoiceController extends DooController {
|
|
|
'isReceivables' => $isReceivables
|
|
|
) );
|
|
|
}
|
|
|
+ */
|
|
|
|
|
|
/**
|
|
|
+ * @deprecated
|
|
|
* 从发票中移除已经入账的收款 --需求变更 废弃
|
|
|
- */
|
|
|
function ajaxReceivablesRemove() {
|
|
|
$iridKey = $this->get_args ( 'key' ) ? $this->get_args ( 'key' ) : "";
|
|
|
$invoiceKey = $this->get_args ( 'invoiceKey' ) ? $this->get_args ( 'invoiceKey' ) : "";
|
|
@@ -2786,7 +2796,8 @@ class InvoiceController extends DooController {
|
|
|
'isReceivables' => $isReceivables
|
|
|
) );
|
|
|
}
|
|
|
-
|
|
|
+ */
|
|
|
+
|
|
|
/**
|
|
|
* 我的收款中 选择哪个发票入账,进行金额判断
|
|
|
*/
|
|
@@ -2820,9 +2831,9 @@ class InvoiceController extends DooController {
|
|
|
) );
|
|
|
}
|
|
|
|
|
|
- /*
|
|
|
+ /**
|
|
|
+ * @deprecated
|
|
|
* 获得与我有关收款数据 --需求变更 废弃
|
|
|
- */
|
|
|
function ajaxGetReceivalblesByStaff() {
|
|
|
$iid = $this->get_args ( 'key' ) ? $this->get_args ( 'key' ) : "";
|
|
|
Doo::loadModel ( 'invoiceReceivables' );
|
|
@@ -2975,6 +2986,8 @@ class InvoiceController extends DooController {
|
|
|
'isReceivables' => $isReceivables
|
|
|
) );
|
|
|
}
|
|
|
+ */
|
|
|
+
|
|
|
function ajaxGetInvoiceInfoByType() {
|
|
|
$type = $this->get_args ( 'type' ) ? $this->get_args ( 'type' ) : "";
|
|
|
$serial = $this->get_args ( 'serial' ) ? $this->get_args ( 'serial' ) : "";
|
|
@@ -3615,11 +3628,13 @@ class InvoiceController extends DooController {
|
|
|
'asArray' => TRUE
|
|
|
) );
|
|
|
// 我的收款待入账
|
|
|
+ /*
|
|
|
$myClaim = $invoiceReceivables->getOne ( array (
|
|
|
'where' => " receivablesStaff like '" . $st [0] ['sid'] . "-%' and receivablesCategory like '" . $st [0] ['cid'] . ":%' and bindStatus=0",
|
|
|
'desc' => 'irid',
|
|
|
'asArray' => TRUE
|
|
|
) );
|
|
|
+ */
|
|
|
// 发票审批
|
|
|
$approval = $invoice->getOne ( array (
|
|
|
'where' => 'status=1 and pendingApprovals=' . $st [0] ['sid'],
|
|
@@ -3646,19 +3661,19 @@ class InvoiceController extends DooController {
|
|
|
$new = array (
|
|
|
'GLOBAL' => FALSE,
|
|
|
'pendingInvoice' => FALSE,
|
|
|
- 'myClaim' => FALSE,
|
|
|
+// 'myClaim' => FALSE,
|
|
|
'approval' => FALSE,
|
|
|
'post' => FALSE,
|
|
|
'print' => FALSE,
|
|
|
'untread' => FALSE
|
|
|
);
|
|
|
-
|
|
|
- if (! empty ( $pendingInvoice ) || ! empty ( $myClaim ) || ! empty ( $approval ) || ! empty ( $post ) || ! empty ( $print ) || ! empty ( $untread ))
|
|
|
+ //|| ! empty ( $myClaim )
|
|
|
+ if (! empty ( $pendingInvoice ) || ! empty ( $approval ) || ! empty ( $post ) || ! empty ( $print ) || ! empty ( $untread ))
|
|
|
$new ['GLOBAL'] = TRUE;
|
|
|
if (! empty ( $pendingInvoice ))
|
|
|
$new ['pendingInvoice'] = TRUE;
|
|
|
- if (! empty ( $myClaim ))
|
|
|
- $new ['myClaim'] = TRUE;
|
|
|
+// if (! empty ( $myClaim ))
|
|
|
+// $new ['myClaim'] = TRUE;
|
|
|
if (! empty ( $approval ))
|
|
|
$new ['approval'] = TRUE;
|
|
|
if (! empty ( $post ))
|