[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] property/inc/import/Import_fra_Service, 1.10.2.2
From: |
nomail |
Subject: |
[Phpgroupware-cvs] property/inc/import/Import_fra_Service, 1.10.2.2 |
Date: |
Tue, 30 Nov 2004 10:18:45 +0100 |
Update of /property/inc/import
Modified Files:
Branch: proposed-0_9_18-branch
Import_fra_Service
date: 2004/11/30 09:18:45; author: sigurdne; state: Exp; lines: +27 -4
Log Message:
no message
=====================================================================
Index: property/inc/import/Import_fra_Service
diff -u property/inc/import/Import_fra_Service:1.10.2.1
property/inc/import/Import_fra_Service:1.10.2.2
--- property/inc/import/Import_fra_Service:1.10.2.1 Thu Nov 18 11:41:01 2004
+++ property/inc/import/Import_fra_Service Tue Nov 30 09:18:45 2004
@@ -164,15 +164,15 @@
}
}
-//_debug_array($name);
if($name=='mvakode' &&
$invoice_common['auto_tax'])
{
$value =
$this->soXport->auto_tax($buffer[$this->id]['dima']);
}
- if($buffer[$this->id]['dima'])
+ if($name=='dima')
{
- $buffer[$this->id]['loc1'] =
$loc1=substr($buffer[$this->id]['dima'],0,4);
+ $value = $this->check_dima($value);
+ $buffer[$this->id]['loc1'] =
$loc1=substr($value,0,4);
}
$buffer[$this->id][$name] = $value;
@@ -202,7 +202,6 @@
}
return $buffer;
}
-
function check_spbudact_code($id)
{
@@ -223,6 +222,30 @@
return $b_account;
}
+ function check_dima($id)
+ {
+ $loc1=substr($id,0,4);
+ $loc2=substr($id,4,2);
+
+ $this->db->query("select loc1 from fm_location1 where
loc1='$loc1'");
+ $this->db->next_record();
+ if ($this->db->f('loc1'))
+ {
+ $dima = $this->db->f('loc1');
+
+ if ($loc2)
+ {
+ $this->db->query("select location_code
from fm_location2 where loc1='$loc1' AND loc2='$loc2'");
+ $this->db->next_record();
+ if ($this->db->f('location_code'))
+ {
+ $dima =
str_replace('-','',$this->db->f('location_code'));
+ }
+ }
+ }
+
+ return $dima;
+ }
function import_end_file($buffer,$bilagsnr)
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] property/inc/import/Import_fra_Service, 1.10.2.2,
nomail <=