[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [8626] property: tweak
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [8626] property: tweak |
Date: |
Fri, 20 Jan 2012 15:26:18 +0000 |
Revision: 8626
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=8626
Author: sigurdne
Date: 2012-01-20 15:26:17 +0000 (Fri, 20 Jan 2012)
Log Message:
-----------
property: tweak
Modified Paths:
--------------
trunk/property/inc/class.soinvoice.inc.php
trunk/property/inc/class.uiinvoice.inc.php
trunk/property/inc/class.uiproject.inc.php
trunk/property/js/yahoo/invoice.index.js
trunk/property/js/yahoo/invoice.paid.index.js
Modified: trunk/property/inc/class.soinvoice.inc.php
===================================================================
--- trunk/property/inc/class.soinvoice.inc.php 2012-01-20 13:38:35 UTC (rev
8625)
+++ trunk/property/inc/class.soinvoice.inc.php 2012-01-20 15:26:17 UTC (rev
8626)
@@ -185,13 +185,13 @@
$querymethod = " $where ( spvend_code =
{$query} OR bilagsnr = {$query})";
}
- $sql = "SELECT bilagsnr, bilagsnr_ut, count(bilagsnr)
as invoice_count, sum(belop) as belop,spvend_code,fakturadato FROM $table
$join_tables $filtermethod $querymethod GROUP BY periode,
bilagsnr,bilagsnr_ut,spvend_code,fakturadato,oppsynsigndato,saksigndato,budsjettsigndato";
+ $sql = "SELECT bilagsnr, bilagsnr_ut, count(bilagsnr)
as invoice_count, sum(belop) as belop, sum(godkjentbelop) as
godkjentbelop,spvend_code,fakturadato FROM $table $join_tables $filtermethod
$querymethod GROUP BY periode,
bilagsnr,bilagsnr_ut,spvend_code,fakturadato,oppsynsigndato,saksigndato,budsjettsigndato";
$sql2 = "SELECT DISTINCT bilagsnr FROM $table
$join_tables $filtermethod $querymethod";
$this->db->query($sql2,__LINE__,__FILE__);
$this->total_records = $this->db->num_rows();
- $sql3 = "SELECT sum(belop) as sum_amount FROM $table
$join_tables $filtermethod $querymethod";
+ $sql3 = "SELECT sum(godkjentbelop) as sum_amount FROM
$table $join_tables $filtermethod $querymethod";
$this->db->query($sql3,__LINE__,__FILE__);
$this->db->next_record();
$this->sum_amount =
$this->db->f('sum_amount');
@@ -214,7 +214,8 @@
'voucher_id' =>
$this->db->f('bilagsnr'),
'voucher_out_id' =>
$this->db->f('bilagsnr_ut'),
'invoice_count' =>
$this->db->f('invoice_count'),
- 'amount'
=> $this->db->f('belop')
+ 'amount'
=> $this->db->f('belop'),
+ 'approved_amount' =>
$this->db->f('godkjentbelop')
);
}
@@ -305,6 +306,7 @@
$invoice[$i]['currency']
= $this->db->f('currency');
$invoice[$i]['order_id']
= $this->db->f('pmwrkord_code');
$invoice[$i]['amount']
= $invoice_temp['amount'];
+ $invoice[$i]['approved_amount']
= $invoice_temp['approved_amount'];
$invoice[$i]['num_days']
=
intval(($timestamp_payment_date-$timestamp_voucher_date)/(24*3600));
$invoice[$i]['timestamp_voucher_date']
= $timestamp_voucher_date;
Modified: trunk/property/inc/class.uiinvoice.inc.php
===================================================================
--- trunk/property/inc/class.uiinvoice.inc.php 2012-01-20 13:38:35 UTC (rev
8625)
+++ trunk/property/inc/class.uiinvoice.inc.php 2012-01-20 15:26:17 UTC (rev
8626)
@@ -826,7 +826,7 @@
'num_days',
'timestamp_voucher_date',
'num_days',
-
'amount',
+
'approved_amount',
'currency',
'vendor',
'invoice_count',
@@ -894,7 +894,7 @@
'dummy',
'dummy',
lang('Days'),
-
lang('Sum'),
+
lang('approved amount'),
lang('currency'),
lang('Vendor'),
'dummy',
Modified: trunk/property/inc/class.uiproject.inc.php
===================================================================
--- trunk/property/inc/class.uiproject.inc.php 2012-01-20 13:38:35 UTC (rev
8625)
+++ trunk/property/inc/class.uiproject.inc.php 2012-01-20 15:26:17 UTC (rev
8626)
@@ -1102,13 +1102,8 @@
$error_id=true;
}
- if(!isset($values['b_account_id']) ||
!$values['b_account_id'])
+ if(isset($values['b_account_id']) &&
$values['b_account_id'])
{
-
$receipt['error'][]=array('msg'=>lang('Please select an account group!'));
- $error_id=true;
- }
- else
- {
$sogeneric =
CreateObject('property.sogeneric');
$sogeneric->get_location_info('b_account_category',false);
$status_data =
$sogeneric->read_single(array('id' => (int)$values['b_account_id']),array());
Modified: trunk/property/js/yahoo/invoice.index.js
===================================================================
--- trunk/property/js/yahoo/invoice.index.js 2012-01-20 13:38:35 UTC (rev
8625)
+++ trunk/property/js/yahoo/invoice.index.js 2012-01-20 15:26:17 UTC (rev
8626)
@@ -30,6 +30,7 @@
var toolTips = [
{name:'voucher_id_lnk',title:'Voucher ID', description:'click
this link to enter the list of sub-invoices',ColumnDescription:''},
{name:'voucher_date_lnk', title:'Payment Date',
description:'',ColumnDescription:'payment_date'},
+ {name:'approved_amount_lnk', title:'Sum',
description:'',ColumnDescription:'amount'},
{name:'btn_export', title:'download', description:'Download
table to your browser',ColumnDescription:''}
]
Modified: trunk/property/js/yahoo/invoice.paid.index.js
===================================================================
--- trunk/property/js/yahoo/invoice.paid.index.js 2012-01-20 13:38:35 UTC
(rev 8625)
+++ trunk/property/js/yahoo/invoice.paid.index.js 2012-01-20 15:26:17 UTC
(rev 8626)
@@ -37,7 +37,8 @@
var toolTips = [
{name:'voucher_id_lnk',title:'Voucher ID',
description:'click this link to enter the list of
sub-invoices',ColumnDescription:''},
{name:'vendor_id_lnk', title:'',
description:'',ColumnDescription: 'vendor_name'},
- {name:'voucher_date_lnk', title:'Payment Date',
description:'',ColumnDescription:'voucher_date_lnk'}
+ {name:'voucher_date_lnk', title:'Payment Date',
description:'',ColumnDescription:'voucher_date_lnk'},
+ {name:'approved_amount', title:'Sum',
description:'',ColumnDescription:'amount'}
]
// define the hidden column in datatable
@@ -100,7 +101,7 @@
td_empty(14);
td_sum('Total');
td_sum(tmp_sum);
- td_empty(12);
+ td_empty(14);
//Add to Table
myfoot = tableYUI.createTFoot();
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [8626] property: tweak,
Sigurd Nes <=