[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] property/inc/export GABNr,1.6
From: |
sigurdne |
Subject: |
[Phpgroupware-cvs] property/inc/export GABNr,1.6 |
Date: |
Mon, 14 Feb 2005 14:35:00 +0100 |
Update of property/inc/export
Modified Files:
Branch: MAIN
GABNr lines: +16 -7
Log Message:
no message
====================================================
Index: property/inc/export/GABNr
diff -u property/inc/export/GABNr:1.5 property/inc/export/GABNr:1.6
--- property/inc/export/GABNr:1.5 Mon Feb 14 10:39:06 2005
+++ property/inc/export/GABNr Mon Feb 14 13:35:28 2005
@@ -84,7 +84,7 @@
//Velg ut alle GABNr som skal overføres
- $sql = "SELECT gab_id,fm_gab_location.loc1 FROM
fm_gab_location $this->join fm_location1 on fm_gab_location.loc1 =
fm_location1.loc1 WHERE owner = 'yes' AND ((fm_location1.category <> 99) OR
(fm_location1.category IS NULL)) GROUP BY gab_id,fm_gab_location.loc1 order by
gab_id asc";
+ $sql = "SELECT
loc1_name,gab_id,fm_gab_location.loc1,fm_gab_location.address FROM
fm_gab_location $this->join fm_location1 on fm_gab_location.loc1 =
fm_location1.loc1 WHERE owner = 'yes' AND ((fm_location1.category <> 99) OR
(fm_location1.category IS NULL)) GROUP BY
gab_id,fm_gab_location.loc1,loc1_name, fm_gab_location.address ORDER by gab_id
asc";
$this->db->query($sql,__LINE__,__FILE__);
@@ -93,7 +93,9 @@
$gab_list[] = array
(
'gab_id' => $this->db->f('gab_id'),
- 'location_code' => $this->db->f('loc1')
+ 'location_code' => $this->db->f('loc1'),
+ 'address' => $this->db->f('address'),
+ 'loc1_name' =>
$this->db->f('loc1_name'),
);
}
@@ -101,7 +103,7 @@
$gab_count = count($gab_list);
- for ($i=0;$i<$gab_count;$i++)
+/* for ($i=0;$i<$gab_count;$i++)
{
$location_data=$this->solocation->read_single($gab_list[$i]['location_code']);
for ($j=0;$j<count($cols_extra);$j++)
@@ -110,14 +112,21 @@
}
}
+*/
+ $buffer = 'GABNr'. ' ' .'Objekt'.' '.'Adresse' .
"\r\n";
- $buffer = 'GABNr'. ' ' .'Objekt'. ' '
.'Objektnavn'."\r\n";
-
+ $check_gab_id=array();
+
for ($k=0;$k<$gab_count;$k++)
{
- $buffer .=substr($gab_list[$k]['gab_id'],-20).
' ' .$gab_list[$k]['location_code']. ' '
.$gab_list[$k]['loc1_name']."\r\n";
+ if (!$check_gab_id[$gab_list[$k]['gab_id']])
+ {
+
$check_gab_id[$gab_list[$k]['gab_id']]=True;
- $antall = $antall + 1;
+ $buffer
.=substr($gab_list[$k]['gab_id'],-20). ' '
.$gab_list[$k]['location_code']. ' ' .$gab_list[$k]['address']."\r\n";
+
+ $antall = $antall + 1;
+ }
}
// $buffer .= 'antall:'.' '.$antall;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] property/inc/export GABNr,1.6,
sigurdne <=