[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] property/inc/import/Import_fra_Service_xml, 1.10.2.1
From: |
nomail |
Subject: |
[Phpgroupware-cvs] property/inc/import/Import_fra_Service_xml, 1.10.2.1 |
Date: |
Thu, 18 Nov 2004 12:41:01 +0100 |
Update of /property/inc/import
Modified Files:
Branch: proposed-0_9_18-branch
Import_fra_Service_xml
date: 2004/11/18 11:41:01; author: sigurdne; state: Exp; lines: +21 -4
Log Message:
no message
=====================================================================
Index: property/inc/import/Import_fra_Service_xml
diff -u property/inc/import/Import_fra_Service_xml:1.10
property/inc/import/Import_fra_Service_xml:1.10.2.1
--- property/inc/import/Import_fra_Service_xml:1.10 Thu Sep 30 12:25:41 2004
+++ property/inc/import/Import_fra_Service_xml Thu Nov 18 11:41:01 2004
@@ -26,6 +26,7 @@
function import_conv()
{
+ $this->db = $GLOBALS['phpgw']->db;
$this->currentapp =
$GLOBALS['phpgw_info']['flags']['currentapp'];
$this->soXport =
CreateObject($this->currentapp.'.soXport');
$this->invoice =
CreateObject($this->currentapp.'.boinvoice');
@@ -166,10 +167,7 @@
}
if($name=='spbudact_code')
{
-
if(!$this->soXport->check_spbudact_code(intval($value)))
- {
- $value='';
- }
+ $value =
$this->check_spbudact_code($value);
}
if($name=='fakturanr')
@@ -218,6 +216,25 @@
return $buffer;
}
+ function check_spbudact_code($id)
+ {
+ $b_account='';
+ $this->db->query("select id from fm_b_account where
id='$id'");
+ $this->db->next_record();
+ if ($this->db->f('id'))
+ {
+ $b_account = $this->db->f('id');
+ }
+ else
+ {
+ $this->db->query("select id from
fm_b_account_convert where old_id='$id'");
+ $this->db->next_record();
+ $b_account = $this->db->f('id');
+ }
+
+ return $b_account;
+ }
+
function import_end_file($buffer,$bilagsnr)
{
$num = $this->soXport->add($buffer);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] property/inc/import/Import_fra_Service_xml, 1.10.2.1,
nomail <=