[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] property/inc class.soinvoice.inc.php
From: |
Sigurd Nes |
Subject: |
[Phpgroupware-cvs] property/inc class.soinvoice.inc.php |
Date: |
Wed, 10 May 2006 11:55:34 +0000 |
CVSROOT: /sources/phpgroupware
Module name: property
Branch:
Changes by: Sigurd Nes <address@hidden> 06/05/10 11:55:33
Modified files:
inc : class.soinvoice.inc.php
Log message:
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/property/inc/class.soinvoice.inc.php.diff?tr1=1.23&tr2=1.24&r1=text&r2=text
Patches:
Index: property/inc/class.soinvoice.inc.php
diff -u property/inc/class.soinvoice.inc.php:1.23
property/inc/class.soinvoice.inc.php:1.24
--- property/inc/class.soinvoice.inc.php:1.23 Wed May 10 11:10:20 2006
+++ property/inc/class.soinvoice.inc.php Wed May 10 11:55:33 2006
@@ -8,7 +8,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package property
* @subpackage eco
- * @version $Id: class.soinvoice.inc.php,v 1.23 2006/05/10 11:10:20
sigurdne Exp $
+ * @version $Id: class.soinvoice.inc.php,v 1.24 2006/05/10 11:55:33
sigurdne Exp $
*/
/**
@@ -155,20 +155,18 @@
$end_date =
date($this->bocommon->dateformat,mktime(2,0,0,$emonth,$eday,$eyear));
- $start_date2 =
date($this->bocommon->dateformat,mktime(2,0,0,$smonth,$sday,$syear));
+ $start_date =
date($this->bocommon->dateformat,mktime(2,0,0,$smonth,$sday,$syear));
+ $filtermethod .= " $where (fakturadato
>'$start_date' AND fakturadato < '$end_date'";
+
if($smonth < 3)
{
- $start_date =
date($this->bocommon->dateformat,mktime(2,0,0,3,1,$syear));
- $filtermethod .= " $where
(fakturadato >'$start_date' AND fakturadato < '$end_date')";
- $filtermethod .= " OR
(fakturadato >'$start_date2' AND fakturadato < '$end_date' AND periode < 3)";
+ $filtermethod .= " AND periode
< 3)";
}
else
{
- $filtermethod .= " $where
(fakturadato >'$start_date2' AND fakturadato < '$end_date')";
- }
-
- // $filtermethod .= " $where overftid
>'$start_date' and overftid < '$end_date'";
+ $filtermethod .= ")";
+ }
}
}
else
@@ -189,7 +187,7 @@
$sql = "SELECT DISTINCT bilagsnr, count(bilagsnr) as
invoice_count, sum(belop) as belop,spvend_code,fakturadato FROM $table
$join_account $filtermethod $querymethod group by
bilagsnr,spvend_code,fakturadato ";
$sql2 = "SELECT DISTINCT bilagsnr FROM $table
$join_account $filtermethod $querymethod";
-//echo $sql;
+//echo $sql2;
$this->db2->query($sql2,__LINE__,__FILE__);
$this->total_records = $this->db2->num_rows();
@@ -208,7 +206,7 @@
(
'voucher_id' =>
$this->db->f('bilagsnr'),
'invoice_count' =>
$this->db->f('invoice_count'),
- 'amount' =>
$this->db->f('belop')
+ 'amount' =>
$this->db->f('belop')
);
}