phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] property inc/class.bocommon.inc.php inc/class.b...


From: Sigurd Nes
Subject: [Phpgroupware-cvs] property inc/class.bocommon.inc.php inc/class.b...
Date: Thu, 04 Jan 2007 12:21:03 +0000

CVSROOT:        /sources/phpgroupware
Module name:    property
Changes by:     Sigurd Nes <sigurdne>   07/01/04 12:21:03

Modified files:
        inc            : class.bocommon.inc.php 
Removed files:
        inc            : class.bometer.inc.php 
                         class.bostandard_entity.inc.php 
                         class.someter.inc.php 
                         class.sostandard_entity.inc.php 
                         class.uimeter.inc.php 
                         class.uistandard_entity.inc.php 
        templates/base : meter.xsl owner.xsl standard_entity.xsl 
                         tenant.xsl 

Log message:
        remove obsolete code

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.bocommon.inc.php?cvsroot=phpgroupware&r1=1.56&r2=1.57
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.bometer.inc.php?cvsroot=phpgroupware&r1=1.9&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.bostandard_entity.inc.php?cvsroot=phpgroupware&r1=1.9&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.someter.inc.php?cvsroot=phpgroupware&r1=1.8&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.sostandard_entity.inc.php?cvsroot=phpgroupware&r1=1.9&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.uimeter.inc.php?cvsroot=phpgroupware&r1=1.13&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/inc/class.uistandard_entity.inc.php?cvsroot=phpgroupware&r1=1.13&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/templates/base/meter.xsl?cvsroot=phpgroupware&r1=1.1&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/templates/base/owner.xsl?cvsroot=phpgroupware&r1=1.1&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/templates/base/standard_entity.xsl?cvsroot=phpgroupware&r1=1.1&r2=0
http://cvs.savannah.gnu.org/viewcvs/property/templates/base/tenant.xsl?cvsroot=phpgroupware&r1=1.4&r2=0

Patches:
Index: inc/class.bocommon.inc.php
===================================================================
RCS file: /sources/phpgroupware/property/inc/class.bocommon.inc.php,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -b -r1.56 -r1.57
--- inc/class.bocommon.inc.php  4 Jan 2007 12:04:02 -0000       1.56
+++ inc/class.bocommon.inc.php  4 Jan 2007 12:21:02 -0000       1.57
@@ -8,7 +8,7 @@
        * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
        * @package property
        * @subpackage core
-       * @version $Id: class.bocommon.inc.php,v 1.56 2007/01/04 12:04:02 
sigurdne Exp $
+       * @version $Id: class.bocommon.inc.php,v 1.57 2007/01/04 12:21:02 
sigurdne Exp $
        */
 
        /**
@@ -239,25 +239,6 @@
                        return $date;
                }
 
-
-               function 
column_list($selected='',$entity_type='',$cat_id,$allrows='')
-               {
-                       $bostandard_entity      = 
CreateObject($this->currentapp.'.bostandard_entity',True);
-
-                       if(!$selected)
-                       {
-                               
$selected=$GLOBALS['phpgw_info']['user']['preferences'][$this->currentapp][$entity_type.'_columns_'.$cat_id];
-                       }
-
-                       $columns = 
$bostandard_entity->read_attrib($entity_type,$cat_id,$allrows);
-//_debug_array($columns);
-
-                       
$column_list=$this->select_multi_list($selected,$columns);
-
-                       return $column_list;
-
-               }
-
                function select_multi_list($selected='',$input_list)
                {
                        $j=0;

Index: inc/class.bometer.inc.php
===================================================================
RCS file: inc/class.bometer.inc.php
diff -N inc/class.bometer.inc.php
--- inc/class.bometer.inc.php   27 Dec 2006 10:37:59 -0000      1.9
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,236 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - property: a Facilities Management System.
-       *
-       * @author Sigurd Nes <address@hidden>
-       * @copyright Copyright (C) 2003-2005 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
-       * @package property
-       * @subpackage entity
-       * @version $Id: class.bometer.inc.php,v 1.9 2006/12/27 10:37:59 
sigurdne Exp $
-       */
-
-       /**
-        * Description
-        * @package property
-        */
-
-       class property_bometer
-       {
-               var $start;
-               var $query;
-               var $filter;
-               var $sort;
-               var $order;
-               var $cat_id;
-
-               var $public_functions = array
-               (
-                       'read'                          => True,
-                       'read_single'           => True,
-                       'save'                          => True,
-                       'delete'                        => True,
-                       'check_perms'           => True
-               );
-
-               var $soap_functions = array(
-                       'list' => array(
-                               'in'  => 
array('int','int','struct','string','int'),
-                               'out' => array('array')
-                       ),
-                       'read' => array(
-                               'in'  => array('int','struct'),
-                               'out' => array('array')
-                       ),
-                       'save' => array(
-                               'in'  => array('int','struct'),
-                               'out' => array()
-                       ),
-                       'delete' => array(
-                               'in'  => array('int','struct'),
-                               'out' => array()
-                       )
-               );
-
-               function property_bometer($session=False)
-               {
-                       $this->currentapp       = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
-                       $this->so               = 
CreateObject($this->currentapp.'.someter');
-                       $this->bocommon = 
CreateObject($this->currentapp.'.bocommon');
-
-                       if ($session)
-                       {
-                               $this->read_sessiondata();
-                               $this->use_session = True;
-                       }
-
-                       $start  = get_var('start',array('POST','GET'));
-                       $query  = get_var('query',array('POST','GET'));
-                       $sort   = get_var('sort',array('POST','GET'));
-                       $order  = get_var('order',array('POST','GET'));
-                       $filter = get_var('filter',array('POST','GET'));
-                       $cat_id = get_var('cat_id',array('POST','GET'));
-
-                       if ($start)
-                       {
-                               $this->start=$start;
-                       }
-                       else
-                       {
-                               $this->start=0;
-                       }
-
-                       if(isset($query))
-                       {
-                               $this->query = $query;
-                       }
-                       if(!empty($filter))
-                       {
-                               $this->filter = $filter;
-                       }
-                       if(isset($sort))
-                       {
-                               $this->sort = $sort;
-                       }
-                       if(isset($order))
-                       {
-                               $this->order = $order;
-                       }
-                       if(isset($cat_id))
-                       {
-                               $this->cat_id = $cat_id;
-                       }
-               }
-
-               function save_sessiondata($data)
-               {
-                       if ($this->use_session)
-                       {
-                               
$GLOBALS['phpgw']->session->appsession('session_data','meter',$data);
-                       }
-               }
-
-               function read_sessiondata()
-               {
-                       $data = 
$GLOBALS['phpgw']->session->appsession('session_data','meter');
-
-                       $this->start    = $data['start'];
-                       $this->query    = $data['query'];
-                       $this->filter   = $data['filter'];
-                       $this->sort             = $data['sort'];
-                       $this->order    = $data['order'];
-                       $this->cat_id   = $data['cat_id'];
-               }
-
-               function get_category_list($format='',$selected='')
-               {
-                       switch($format)
-                       {
-                               case 'select':
-                                       
$GLOBALS['phpgw']->xslttpl->add_file(array('cat_select'));
-                                       break;
-                               case 'filter':
-                                       
$GLOBALS['phpgw']->xslttpl->add_file(array('cat_filter'));
-                                       break;
-                       }
-
-                       $categories= $this->so->get_category_list();
-
-                       return 
$this->bocommon->select_list($selected,$categories);
-               }
-
-               function read()
-               {
-                       $meter = $this->so->read(array('start' => 
$this->start,'query' => $this->query,'sort' => $this->sort,'order' => 
$this->order,
-                                                                               
        'filter' => $this->filter,'cat_id' => $this->cat_id));
-                       $this->total_records = $this->so->total_records;
-
-                       $this->uicols   = $this->so->uicols;
-/*                     $cols_extra             = $this->so->cols_extra;
-                       $dateformat = 
$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat'];
-                       $solocation = 
CreateObject($this->currentapp.'.solocation');
-
-                       for ($i=0; $i<count($meter); $i++)
-                       {
-                               $meter[$i]['user']              = 
$GLOBALS['phpgw']->accounts->id2name($meter[$i]['user_id']);
-                               $meter[$i]['entry_date'] = 
$GLOBALS['phpgw']->common->show_date($meter[$i]['entry_date'],$dateformat);
-                               
$location_data=$solocation->read_single($meter[$i]['location_code']);
-
-                               for ($j=0;$j<count($cols_extra);$j++)
-                               {
-                                       $meter[$i][$cols_extra[$j]] = 
$location_data[$cols_extra[$j]];
-                               }
-
-                       }
-*/
-                       return $meter;
-               }
-
-               function read_single($meter_id)
-               {
-                       $meter= $this->so->read_single($meter_id);
-
-                       if($meter['location_code'])
-                       {
-                               $solocation = 
CreateObject($this->currentapp.'.solocation');
-
-                               $meter['location_data'] 
=$solocation->read_single($meter['location_code']);
-                       }
-
-                       if($meter['p_num'])
-                       {
-                               $soadmin_entity = 
CreateObject($this->currentapp.'.soadmin_entity');
-                               $category = 
$soadmin_entity->read_single_category($meter['p_entity_id'],$meter['p_cat_id']);
-
-                               
$meter['p'][$meter['p_entity_id']]['p_num']=$meter['p_num'];
-                               
$meter['p'][$meter['p_entity_id']]['p_entity_id']=$meter['p_entity_id'];
-                               
$meter['p'][$meter['p_entity_id']]['p_cat_id']=$meter['p_cat_id'];
-                               
$meter['p'][$meter['p_entity_id']]['p_cat_name'] = $category['name'];
-                       }
-
-                       return $meter;
-               }
-
-               function check_meter_num($num)
-               {
-                       return $this->so->check_meter_num($num);
-               }
-
-               function save($values,$action='')
-               {
-                       while (is_array($values['location']) && list(,$value) = 
each($values['location']))
-                       {
-                               if($value)
-                               {
-                                       $location[] = $value;
-                               }
-                       }
-
-                       $values['location_code']=implode("-", $location);
-
-                       if ($action=='edit')
-                       {
-                               $receipt = $this->so->edit($values);
-                       }
-                       else
-                       {
-                               $receipt = $this->so->add($values);
-                       }
-                       return $receipt;
-               }
-
-               function delete($params)
-               {
-                       if (is_array($params))
-                       {
-                               $this->so->delete($params[0]);
-                       }
-                       else
-                       {
-                               $this->so->delete($params);
-                       }
-               }
-
-       }
-?>

Index: inc/class.bostandard_entity.inc.php
===================================================================
RCS file: inc/class.bostandard_entity.inc.php
diff -N inc/class.bostandard_entity.inc.php
--- inc/class.bostandard_entity.inc.php 27 Dec 2006 10:37:59 -0000      1.9
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,259 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - property: a Facilities Management System.
-       *
-       * @author Sigurd Nes <address@hidden>
-       * @copyright Copyright (C) 2003-2005 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
-       * @package property
-       * @subpackage admin
-       * @version $Id: class.bostandard_entity.inc.php,v 1.9 2006/12/27 
10:37:59 sigurdne Exp $
-       */
-
-       /**
-        * Description
-        * @package property
-        */
-
-       class property_bostandard_entity
-       {
-               var $start;
-               var $query;
-               var $filter;
-               var $sort;
-               var $order;
-               var $cat_id;
-
-               var $public_functions = array
-               (
-                       'read'                          => True,
-                       'read_single'           => True,
-                       'save'                          => True,
-                       'delete'                        => True,
-                       'check_perms'           => True
-               );
-
-               var $soap_functions = array(
-                       'list' => array(
-                               'in'  => 
array('int','int','struct','string','int'),
-                               'out' => array('array')
-                       ),
-                       'read' => array(
-                               'in'  => array('int','struct'),
-                               'out' => array('array')
-                       ),
-                       'save' => array(
-                               'in'  => array('int','struct'),
-                               'out' => array()
-                       ),
-                       'delete' => array(
-                               'in'  => array('int','struct'),
-                               'out' => array()
-                       )
-               );
-
-               function property_bostandard_entity($session=False)
-               {
-                       $this->currentapp       = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
-                       $this->so               = 
CreateObject($this->currentapp.'.sostandard_entity');
-                       $this->socommon = 
CreateObject($this->currentapp.'.socommon');
-                       $this->bocommon = 
CreateObject($this->currentapp.'.bocommon');
-
-                       if ($session)
-                       {
-                               $this->read_sessiondata();
-                               $this->use_session = True;
-                       }
-
-                       $start  = get_var('start',array('POST','GET'));
-                       $query  = get_var('query',array('POST','GET'));
-                       $sort   = get_var('sort',array('POST','GET'));
-                       $order  = get_var('order',array('POST','GET'));
-                       $filter = get_var('filter',array('POST','GET'));
-                       $cat_id = get_var('cat_id',array('POST','GET'));
-
-                       if ($start)
-                       {
-                               $this->start=$start;
-                       }
-                       else
-                       {
-                               $this->start=0;
-                       }
-
-                       if(isset($query))
-                       {
-                               $this->query = $query;
-                       }
-                       if(!empty($filter))
-                       {
-                               $this->filter = $filter;
-                       }
-                       if(isset($sort))
-                       {
-                               $this->sort = $sort;
-                       }
-                       if(isset($order))
-                       {
-                               $this->order = $order;
-                       }
-                       if(isset($cat_id))
-                       {
-                               $this->cat_id = $cat_id;
-                       }
-               }
-
-
-               function save_sessiondata($data)
-               {
-                       if ($this->use_session)
-                       {
-                               
$GLOBALS['phpgw']->session->appsession('session_data','standard_e',$data);
-                       }
-               }
-
-               function read_sessiondata()
-               {
-                       $data = 
$GLOBALS['phpgw']->session->appsession('session_data','standard_e');
-
-
-                       $this->start    = $data['start'];
-                       $this->query    = $data['query'];
-                       $this->filter   = $data['filter'];
-                       $this->sort             = $data['sort'];
-                       $this->order    = $data['order'];
-                       $this->cat_id   = $data['cat_id'];
-               }
-
-
-               function read($type='')
-               {
-                       $standard = $this->so->read(array('start' => 
$this->start,'query' => $this->query,'sort' => $this->sort,'order' => 
$this->order,
-                                                                               
        'type' => $type));
-
-                       $this->total_records = $this->so->total_records;
-
-
-                       return $standard;
-               }
-
-               function read_single($id,$type)
-               {
-                       return $this->so->read_single($id,$type);
-               }
-
-               function save($standard,$action='',$type ='')
-               {
-                       if ($action=='edit')
-                       {
-                               if ($standard['id'] != '')
-                               {
-
-                                       $receipt = 
$this->so->edit($standard,$type);
-                               }
-                       }
-                       else
-                       {
-                               $receipt = $this->so->add($standard,$type);
-                       }
-                       return $receipt;
-
-               }
-
-               function delete($id,$type,$attrib)
-               {
-                       $this->so->delete($id,$type,$attrib);
-               }
-
-               function read_attrib($type='',$type_id='',$allrows='')
-               {
-                       $attrib = $this->so->read_attrib(array('start' => 
$this->start,'query' => $this->query,'sort' => $this->sort,'order' => 
$this->order,
-                                                                               
        'type' => $type,'type_id' => $type_id,'allrows' => $allrows));
-
-                       $this->total_records = $this->so->total_records;
-
-                       for ($i=0; $i<count($attrib); $i++)
-                       {
-                               $attrib[$i]['datatype'] = 
$this->bocommon->translate_datatype($attrib[$i]['datatype']);
-                       }
-
-                       return $attrib;
-               }
-
-               function read_single_attrib($id,$type)
-               {
-                       return $this->so->read_single_attrib($id,$type);
-               }
-
-               function save_attrib($attrib,$action='',$type ='')
-               {
-                       if ($action=='edit')
-                       {
-                               if ($attrib['id'] != '')
-                               {
-
-                                       $receipt = 
$this->so->edit_attrib($attrib,$type);
-                               }
-                       }
-                       else
-                       {
-                               $receipt = $this->so->add_attrib($attrib,$type);
-                       }
-                       return $receipt;
-               }
-
-
-               function select_entity_type($type='',$selected='')
-               {
-                       $entity_types= $this->so->select_entity_type($type);
-                       return 
$this->bocommon->select_list($selected,$entity_types);
-               }
-
-               function select_datatype($selected='')
-               {
-                       $datatypes[0]['id']= 'C';
-                       $datatypes[0]['name']= lang('Character');
-                       $datatypes[1]['id']= 'I';
-                       $datatypes[1]['name']= lang('Integer');
-                       $datatypes[2]['id']= 'N';
-                       $datatypes[2]['name']= lang('Decimal');
-                       $datatypes[3]['id']= 'D';
-                       $datatypes[3]['name']= lang('Date');
-                       $datatypes[4]['id']= 'T';
-                       $datatypes[4]['name']= lang('Memo');
-                       $datatypes[5]['id']= 'R';
-                       $datatypes[5]['name']= lang('Multiple radio');
-                       $datatypes[6]['id']= 'CH';
-                       $datatypes[6]['name']= lang('Multiple Checkbox');
-
-                       while (is_array($datatypes) && list(,$type) = 
each($datatypes))
-                       {
-                               $sel_type = '';
-                               if ($type['id']==$selected)
-                               {
-                                       $sel_type = 'selected';
-                               }
-
-                               $datatype_list[] = array
-                               (
-                                       'id'    => $type['id'],
-                                       'name'          => $type['name'],
-                                       'selected'      => $sel_type
-                               );
-                       }
-
-                       for ($i=0;$i<count($datatype_list);$i++)
-                       {
-                               if ($datatype_list[$i]['selected'] != 
'selected')
-                               {
-                                       unset($datatype_list[$i]['selected']);
-                               }
-                       }
-
-                       return $datatype_list;
-               }
-
-
-       }
-?>

Index: inc/class.someter.inc.php
===================================================================
RCS file: inc/class.someter.inc.php
diff -N inc/class.someter.inc.php
--- inc/class.someter.inc.php   27 Dec 2006 10:37:59 -0000      1.8
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,283 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - property: a Facilities Management System.
-       *
-       * @author Sigurd Nes <address@hidden>
-       * @copyright Copyright (C) 2003-2005 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
-       * @package property
-       * @subpackage entity
-       * @version $Id: class.someter.inc.php,v 1.8 2006/12/27 10:37:59 
sigurdne Exp $
-       */
-
-       /**
-        * Description
-        * @package property
-        */
-
-       class property_someter
-       {
-
-               function property_someter()
-               {
-                       $this->currentapp       = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
-                       $this->account  = 
$GLOBALS['phpgw_info']['user']['account_id'];
-                       $this->bocommon         = 
CreateObject($this->currentapp.'.bocommon');
-                       $this->db               = $this->bocommon->new_db();
-                       $this->db2              = $this->bocommon->new_db();
-                       $this->join                     = $this->bocommon->join;
-                       $this->like                     = $this->bocommon->like;
-               }
-
-               function get_category_list()
-               {
-
-                       $this->db->query("SELECT id, descr FROM 
fm_meter_category ORDER BY descr ");
-
-                       $i = 0;
-                       while ($this->db->next_record())
-                       {
-                               $categories[$i]['id']                           
= $this->db->f('id');
-                               $categories[$i]['name']                         
= stripslashes($this->db->f('descr'));
-                               $i++;
-                       }
-                       return $categories;
-               }
-
-               function check_meter_num($num='')
-               {
-                       $this->db->query("SELECT count(*) FROM fm_meter where 
num='$num'");
-
-                       $this->db->next_record();
-
-                       if ( $this->db->f(0))
-                       {
-                               return True;
-                       }
-               }
-
-               function read($data)
-               {
-                       if(is_array($data))
-                       {
-                               if ($data['start'])
-                               {
-                                       $start=$data['start'];
-                               }
-                               else
-                               {
-                                       $start=0;
-                               }
-                               $filter = 
(isset($data['filter'])?$data['filter']:'none');
-                               $query = 
(isset($data['query'])?$data['query']:'');
-                               $sort = 
(isset($data['sort'])?$data['sort']:'DESC');
-                               $order = 
(isset($data['order'])?$data['order']:'');
-                               $cat_id = 
(isset($data['cat_id'])?$data['cat_id']:0);
-                       }
-
-
-                       $entity_table = 'fm_meter';
-
-                       $cols .= $entity_table . '.location_code';
-                       $cols_return[] = 'location_code';
-
-                       $cols .= ",$entity_table.id as meter_id";
-                       $cols_return[] = 'meter_id';
-
-                       $cols .= ",$entity_table.num as num";
-                       $cols_return[]                          = 'num';
-                       $uicols['input_type'][]         = 'text';
-                       $uicols['name'][]                       = 'num';
-                       $uicols['descr'][]                      = lang('Meter 
ID');
-                       $uicols['statustext'][]         = lang('Meter ID');
-
-                       $cols .= ",$entity_table.name ";
-                       $cols_return[]                          = 'name';
-                       $uicols['input_type'][]         = 'text';
-                       $uicols['name'][]                       = 'name';
-                       $uicols['descr'][]                      = lang('Name');
-                       $uicols['statustext'][]         = lang('Name');
-
-                       $cols .= ",fm_meter_category.descr as meter_type";
-                       $cols_return[]                          = 'meter_type';
-                       $uicols['input_type'][]         = 'text';
-                       $uicols['name'][]                       = 'meter_type';
-                       $uicols['descr'][]                      = lang('Meter 
Type');
-                       $uicols['statustext'][]         = lang('Meter Type');
-
-
-                       $joinmethod .= " $this->join  fm_meter_category ON 
($entity_table.category = fm_meter_category.id))";
-                       $paranthesis .='(';
-
-
-                       $sql    = 
$this->bocommon->generate_sql(array('entity_table'=>$entity_table,'cols'=>$cols,'cols_return'=>$cols_return,
-                                                                               
                                        
'uicols'=>$uicols,'joinmethod'=>$joinmethod,'paranthesis'=>$paranthesis,'query'=>$query));
-
-
-                       if ($order)
-                       {
-                               $ordermethod = " order by $entity_table.$order 
$sort";
-                       }
-                       else
-                       {
-                               $ordermethod = " order by 
$entity_table.location_code asc";
-                       }
-
-
-                       $where = 'WHERE';
-                       if ($cat_id)
-                       {
-                               $filtermethod .= " $where 
fm_meter.category='$cat_id' ";
-                               $where = 'AND';
-                       }
-
-                       if($query)
-                       {
-                               $query = ereg_replace("'",'',$query);
-                               $query = ereg_replace('"','',$query);
-
-                               $querymethod = " $where (fm_meter.name 
$this->like '%$query%' OR fm_meter.num $this->like '%$query%' OR 
fm_meter.location_code $this->like '%$query%' OR fm_meter.address $this->like 
'%$query%')";
-                       }
-
-                       $sql .= " $filtermethod $querymethod";
-//echo $sql;
-                       $this->uicols           = $this->bocommon->uicols;
-                       $cols_return            = $this->bocommon->cols_return;
-                       $type_id                        = 
$this->bocommon->type_id;
-                       $this->cols_extra       = $this->bocommon->cols_extra;
-
-                       $this->db2->query($sql,__LINE__,__FILE__);
-                       $this->total_records = $this->db2->num_rows();
-                       $this->db->limit_query($sql . 
$ordermethod,$start,__LINE__,__FILE__);
-
-
-                       $j=0;
-                       while ($this->db->next_record())
-                       {
-                               for ($i=0;$i<count($cols_return);$i++)
-                               {
-                                       $meter[$j][$cols_return[$i]] = 
$this->db->f($cols_return[$i]);
-                               }
-
-                               $location_code= $this->db->f('location_code');
-                               $location = split('-',$location_code);
-                               for ($m=0;$m<count($location);$m++)
-                               {
-                                       $meter[$j]['loc' . ($m+1)] = 
$location[$m];
-                                       $meter[$j]['query_location']['loc' . 
($m+1)]=implode("-", array_slice($location, 0, ($m+1)));
-                               }
-
-                               $j++;
-                       }
-
-                       return $meter;
-               }
-
-               function read_single($meter_id)
-               {
-                       $sql = "SELECT * FROM fm_meter where id='$meter_id'";
-
-                       $this->db->query($sql,__LINE__,__FILE__);
-
-                       if ($this->db->next_record())
-                       {
-                               $meter['meter_id']                      = 
$this->db->f('id');
-                               $meter['num']                           = 
$this->db->f('num');
-                               $meter['name']                          = 
stripslashes($this->db->f('name'));
-                               $meter['remark']                        = 
stripslashes($this->db->f('remark'));
-                               $meter['cat_id']                        = 
$this->db->f('category');
-                               $meter['location_code']         = 
$this->db->f('location_code');
-                               $meter['p_num']                         = 
$this->db->f('p_num');
-                               $meter['p_entity_id']           = 
$this->db->f('p_entity_id');
-                               $meter['p_cat_id']                      = 
$this->db->f('p_cat_id');
-                       }
-                       return $meter;
-               }
-
-               function add($meter)
-               {
-
-                       while (is_array($meter['location']) && 
list($input_name,$value) = each($meter['location']))
-                       {
-                               if($value)
-                               {
-                                       $cols[] = $input_name;
-                                       $vals[] = $value;
-                               }
-                       }
-
-                       if($cols)
-                       {
-                               $cols   = "," . implode(",", $cols);
-                               $vals   = ",'" . implode("','", $vals) . "'";
-                       }
-
-                       if($meter['street_name'])
-                       {
-                               $address[]= $meter['street_name'];
-                               $address[]= $meter['street_number'];
-                               $address        = implode(" ", $address);
-                       }
-
-                       if(!$address)
-                       {
-                               $address = $meter['location_name'];
-                       }
-
-                       $meter['remark'] = 
$this->db->db_addslashes($meter['remark']);
-
-                       $this->db->query("INSERT INTO fm_meter (location_code, 
num,user_id,entry_date,name,address,category,remark $cols ) "
-                               . "VALUES ('" . $meter['location_code'] . "','" 
. $meter['num'] . "','" . $this->account . "','" . time() . "','" . 
$meter['name']
-                               . "','" . $address ."','" . $meter['cat_id'] 
."','" . $meter['remark']. "' $vals )",__LINE__,__FILE__);
-
-
-                       $meter_id = 
$this->db->get_last_insert_id('fm_meter','id');
-
-                       $receipt['meter_id'] = $meter_id;
-                       $receipt['message'][]=array('msg'=>lang('Meter %1 has 
been saved',$meter['num']));
-                       return $receipt;
-               }
-
-               function edit($meter)
-               {
-                       while (is_array($meter['location']) && 
list($input_name,$value) = each($meter['location']))
-                       {
-                               $vals[] = "$input_name = '$value'";
-                       }
-
-                       if($vals)
-                       {
-                               $vals   = "," . implode(",",$vals);
-                       }
-
-                       if($meter['street_name'])
-                       {
-                               $address[]= $meter['street_name'];
-                               $address[]= $meter['street_number'];
-                               $address        = implode(" ", $address);
-                       }
-
-                       if(!$address)
-                       {
-                               $address = $meter['location_name'];
-                       }
-
-                       $meter['remark'] = 
$this->db->db_addslashes($meter['remark']);
-
-
-                       $this->db->query("UPDATE fm_meter set name='" . 
$meter['name'] . "', entry_date='" . time() . "', category='"
-                                                       . $meter['cat_id'] . 
"', location_code='" . $meter['location_code'] . "', address='" . $address . 
"', remark='" . $meter['remark']
-                                                       . "' $vals WHERE id='" 
. $meter['meter_id'] . "'",__LINE__,__FILE__);
-
-                       $receipt['message'][]=array('msg'=>lang('Meter %1 has 
been edited',$meter['num']));
-                       return $receipt;
-               }
-
-               function delete($meter_id)
-               {
-                       $this->db->query("DELETE FROM fm_meter WHERE id='" . 
$meter_id ."'",__LINE__,__FILE__);
-               }
-
-       }
-?>

Index: inc/class.sostandard_entity.inc.php
===================================================================
RCS file: inc/class.sostandard_entity.inc.php
diff -N inc/class.sostandard_entity.inc.php
--- inc/class.sostandard_entity.inc.php 27 Dec 2006 10:37:59 -0000      1.9
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,504 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - property: a Facilities Management System.
-       *
-       * @author Sigurd Nes <address@hidden>
-       * @copyright Copyright (C) 2003-2005 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
-       * @package property
-       * @subpackage admin
-       * @version $Id: class.sostandard_entity.inc.php,v 1.9 2006/12/27 
10:37:59 sigurdne Exp $
-       */
-
-       /**
-        * Description
-        * @package property
-        */
-
-       class property_sostandard_entity
-       {
-
-               function property_sostandard_entity()
-               {
-                       $this->currentapp       = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
-                       $this->account          = 
$GLOBALS['phpgw_info']['user']['account_id'];
-                       $this->bocommon         = 
CreateObject($this->currentapp.'.bocommon');
-                       $this->db               = $this->bocommon->new_db();
-                       $this->db2              = $this->bocommon->new_db();
-
-                       $this->join                     = $this->bocommon->join;
-                       $this->like                     = $this->bocommon->like;
-               }
-
-               function read($data)
-               {
-                       if(is_array($data))
-                       {
-                               if ($data['start'])
-                               {
-                                       $start=$data['start'];
-                               }
-                               else
-                               {
-                                       $start=0;
-                               }
-                               $query = 
(isset($data['query'])?$data['query']:'');
-                               $sort = 
(isset($data['sort'])?$data['sort']:'DESC');
-                               $order = 
(isset($data['order'])?$data['order']:'');
-                               $type = (isset($data['type'])?$data['type']:0);
-                       }
-
-                       if ($order)
-                       {
-                               $ordermethod = " order by $order $sort";
-
-                       }
-                       else
-                       {
-                               $ordermethod = ' order by id asc';
-                       }
-
-                       $table = $this->select_table($type);
-
-                       if($query)
-                       {
-                               $query = ereg_replace("'",'',$query);
-                               $query = ereg_replace('"','',$query);
-
-                               $querymethod = " where name $this->like 
'%$query%' or descr $this->like '%$query%'";
-                       }
-
-                       $sql = "SELECT * FROM $table $querymethod";
-
-                       $this->db2->query($sql,__LINE__,__FILE__);
-                       $this->total_records = $this->db2->num_rows();
-                       $this->db->limit_query($sql . 
$ordermethod,$start,__LINE__,__FILE__);
-
-                       while ($this->db->next_record())
-                       {
-                               $standard[] = array
-                               (
-                                       'id'    => $this->db->f('id'),
-                                       'name'  => $this->db->f('name'),
-                                       'prefix'=> $this->db->f('prefix'),
-                                       'descr' => $this->db->f('descr')
-                               );
-                       }
-                       return $standard;
-               }
-
-
-               function select_table($type)
-               {
-
-                       switch($type)
-                       {
-                               case 'report':
-                                       $table='fm_report_type';
-                                       break;
-                       }
-
-                       return $table;
-               }
-
-               function select_table_attrib($type)
-               {
-
-                       switch($type)
-                       {
-                               case 'report':
-                                       $table='fm_report_type_attrib';
-                                       break;
-                       }
-
-                       return $table;
-               }
-
-               function select_table_choice($type)
-               {
-
-                       switch($type)
-                       {
-                               case 'report':
-                                       $table='fm_report_type_choice';
-                                       break;
-                       }
-
-                       return $table;
-               }
-
-
-               function read_single($id,$type)
-               {
-
-                       $table = $this->select_table($type);
-
-                       $sql = "SELECT * FROM $table  where id='$id'";
-
-                       $this->db->query($sql,__LINE__,__FILE__);
-
-                       if ($this->db->next_record())
-                       {
-                               $standard['id']                 = 
$this->db->f('id');
-                               $standard['name']               = 
$this->db->f('name');
-                               $standard['descr']              = 
$this->db->f('descr');
-                               $standard['prefix']             = 
$this->db->f('prefix');
-
-                               return $standard;
-                       }
-               }
-
-               function add($standard,$type)
-               {
-
-                       if (!$standard['name'])
-                       {
-                               $receipt['error'][] = array('msg'=>lang('Name 
not entered!'));
-                       }
-
-                       if (!$receipt['error'])
-                       {
-                               $table = $this->select_table($type);
-
-                               $standard['id'] = 
$this->bocommon->next_id($table);
-                               $standard['name'] = 
$this->db->db_addslashes($standard['name']);
-                               $standard['descr'] = 
$this->db->db_addslashes($standard['descr']);
-
-                       $values= array(
-                               $standard['id'],
-                               $standard['name'],
-                               $standard['descr'],
-                               $standard['prefix']
-                               );
-
-                       $values = $this->bocommon->validate_db_insert($values);
-
-
-                               $this->db->query("INSERT INTO $table (id, name, 
descr, prefix) VALUES ($values)",__LINE__,__FILE__);
-
-                               $receipt['id']=$standard['id'];
-                               $receipt['message'][] = array('msg'     => 
lang('standard has been saved'));
-                       }
-                       else
-                       {
-                               $receipt['error'][] = array('msg'=> 
lang('Attribute has NOT been saved'));
-                       }
-
-//_debug_array($receipt);
-                       return $receipt;
-               }
-
-               function edit($standard,$type)
-               {
-
-                       if (!$standard['name'])
-                       {
-                               $receipt['error'][] = array('msg'=>lang('Name 
not entered!'));
-                       }
-
-                       if (!$receipt['error'])
-                       {
-                               $table = $this->select_table($type);
-
-                               $standard['name'] = 
$this->db->db_addslashes($standard['name']);
-                               $standard['descr'] = 
$this->db->db_addslashes($standard['descr']);
-
-                               $value_set=array(
-                                       'descr'                 => 
$standard['descr'],
-                                       'name'          => $standard['name'],
-                                       'prefix'        => $standard['prefix']
-                                       );
-
-                               $value_set      = 
$this->bocommon->validate_db_update($value_set);
-
-                               $this->db->query("UPDATE $table set $value_set 
WHERE id=" . $standard['id'],__LINE__,__FILE__);
-
-                               $receipt['message'][] = array('msg'=> 
lang('Standard has been edited'));
-                       }
-                       else
-                       {
-                               $receipt['error'][] = array('msg'       => 
lang('Standard has NOT been edited'));
-                       }
-
-                       return $receipt;
-               }
-
-               function delete($id,$type,$attrib)
-               {
-                       if($attrib)
-                       {
-                               $table = $this->select_table_attrib($type);
-                       }
-                       else
-                       {
-
-                               $table                  = 
$this->select_table($type);
-                               $attrib_table   = 
$this->select_table_attrib($type);
-                               $this->db->query("DELETE_ FROM $attrib_table 
WHERE type_id='" . $id . "'",__LINE__,__FILE__);
-                       }
-                       $this->db->query("DELETE_ FROM $table WHERE id='" . $id 
. "'",__LINE__,__FILE__);
-               }
-
-               function read_attrib($data)
-               {
-
-//_debug_array($data);
-                       if(is_array($data))
-                       {
-                               if ($data['start'])
-                               {
-                                       $start=$data['start'];
-                               }
-                               else
-                               {
-                                       $start=0;
-                               }
-                               $query = 
(isset($data['query'])?$data['query']:'');
-                               $sort = 
(isset($data['sort'])?$data['sort']:'DESC');
-                               $order = 
(isset($data['order'])?$data['order']:'');
-                               $type = (isset($data['type'])?$data['type']:0);
-                               $type_id = 
(isset($data['type_id'])?$data['type_id']:0);
-                               $allrows = 
(isset($data['allrows'])?$data['allrows']:'');
-                       }
-
-                       $table          = $this->select_table_attrib($type);
-                       $type_table = $this->select_table($type);
-
-                       if ($order)
-                       {
-                               $ordermethod = " order by $order $sort";
-
-                       }
-                       else
-                       {
-                               $ordermethod = " order by $table.id asc";
-                       }
-
-
-                       if($query)
-                       {
-                               $query = ereg_replace("'",'',$query);
-                               $query = ereg_replace('"','',$query);
-
-                               $querymethod = " and ($table.name $this->like 
'%$query%' or $table.descr $this->like '%$query%')";
-                       }
-
-                       $sql = "SELECT $table.id ,$table.name ,$table.descr, 
$table.datatype ,$type_table.name as type FROM $type_table $this->join $table 
on $table.type_id = $type_table.id where $table.type_id= '$type_id' 
$querymethod";
-
-                       $this->db2->query($sql,__LINE__,__FILE__);
-                       $this->total_records = $this->db2->num_rows();
-
-                       if(!$allrows)
-                       {
-                               $this->db->limit_query($sql . 
$ordermethod,$start,__LINE__,__FILE__);
-                       }
-                       else
-                       {
-                               $this->db->query($sql . 
$ordermethod,__LINE__,__FILE__);
-                       }
-
-
-                       while ($this->db->next_record())
-                       {
-                               $attrib[] = array
-                               (
-                                       'id'    => $this->db->f('id'),
-                                       'name'  => $this->db->f('name'),
-                                       'descr' => $this->db->f('descr'),
-                                       'type_name'     => $this->db->f('type'),
-                                       'datatype'      => 
$this->db->f('datatype')
-                               );
-                       }
-                       return $attrib;
-               }
-
-               function read_single_attrib($id,$type)
-               {
-
-                       $table          = $this->select_table_attrib($type);
-                       $type_table = $this->select_table($type);
-
-                       $sql = "SELECT $table.id ,$table.name ,$table.descr, 
$table.datatype,$type_table.id as type_id ,$type_table.name as type_name FROM 
$type_table $this->join $table on $table.type_id = $type_table.id where 
$table.id= '$id'  $querymethod";
-
-                       $this->db->query($sql,__LINE__,__FILE__);
-
-                       if ($this->db->next_record())
-                       {
-                               $attrib['id']           = $this->db->f('id');
-                               $attrib['name']         = $this->db->f('name');
-                               $attrib['descr']        = $this->db->f('descr');
-                               $attrib['type_id']      = 
$this->db->f('type_id');
-                               $attrib['type_name']    = 
$this->db->f('type_name');
-                               $attrib['datatype']     = 
$this->db->f('datatype');
-//                             $attrib['list'] = $this->db->f('list');
-                               if($this->db->f('datatype')=='R' || 
$this->db->f('datatype')=='CH')
-                               {
-                                       $attrib['choice'] = 
$this->read_attrib_choice($attrib['id'],$type);
-                               }
-
-//_debug_array($attrib);
-                       }
-                       return $attrib;
-               }
-
-               function read_attrib_choice($attrib_id='',$type='')
-               {
-                       $choice_table = $this->select_table_choice($type);
-                       $sql = "SELECT * FROM $choice_table WHERE 
attrib_id=$attrib_id";
-                       $this->db->query($sql,__LINE__,__FILE__);
-
-                       while ($this->db->next_record())
-                       {
-                               $choice[] = array
-                               (
-                                       'id'    => $this->db->f('id'),
-                                       'value' => $this->db->f('value')
-                               );
-                       }
-                       return $choice;
-               }
-
-               function add_attrib($attrib,$type)
-               {
-
-                       if (!$attrib['type_id'])
-                       {
-                               $receipt['error'][] = array('msg'=>lang('Entity 
type not chosen!'));
-                       }
-
-                       if (!$attrib['datatype'])
-                       {
-                               $receipt['error'][] = 
array('msg'=>lang('Datatype type not chosen!'));
-                       }
-
-                       if (!$attrib['name'])
-                       {
-                               $receipt['error'][] = array('msg'=>lang('Name 
not entered!'));
-                       }
-
-                       if (!$receipt['error'])
-                       {
-
-                               $table = $this->select_table_attrib($type);
-
-                               $attrib['id'] = 
$this->bocommon->next_id($table);
-                               $attrib['name'] = 
$this->db->db_addslashes($attrib['name']);
-                               $attrib['descr'] = 
$this->db->db_addslashes($attrib['descr']);
-
-
-                       $values= array(
-                               $attrib['id'],
-                               $attrib['type_id'],
-                               $attrib['name'],
-                               $attrib['descr'],
-                               $attrib['datatype']
-//                             $attrib['list']
-                               );
-
-                       $values = $this->bocommon->validate_db_insert($values);
-
-                               $this->db->query("INSERT INTO $table (id, 
type_id, name, descr, datatype) "
-                                       . "VALUES ($values)",__LINE__,__FILE__);
-
-                               $receipt['id']=$attrib['id'];
-                               $receipt['message'][] = array('msg'     => 
lang('Attribute has been saved')     );
-
-                       }
-                       else
-                       {
-                               $receipt['error'][] = array('msg'       => 
lang('Attribute has NOT been saved'));
-                       }
-                       return $receipt;
-               }
-
-               function edit_attrib($attrib,$type)
-               {
-
-                       if (!$attrib['type_id'])
-                       {
-                               $receipt['error'][] = array('msg'=>lang('Entity 
type not chosen!'));
-                       }
-
-                       if (!$attrib['datatype'])
-                       {
-                               $receipt['error'][] = 
array('msg'=>lang('Datatype type not chosen!'));
-                       }
-
-                       if (!$attrib['name'])
-                       {
-                               $receipt['error'][] = array('msg'=>lang('Name 
not entered!'));
-                       }
-
-                       if (!$receipt['error'])
-                       {
-                               $table = $this->select_table_attrib($type);
-                               $choice_table = 
$this->select_table_choice($type);
-
-                               $attrib['name'] = 
$this->db->db_addslashes($attrib['name']);
-                               $attrib['descr'] = 
$this->db->db_addslashes($attrib['descr']);
-
-                               $value_set=array(
-                                       'descr'         => $attrib['descr'],
-                                       'name'          => $attrib['name'],
-                                       'type_id'       => $attrib['type_id'],
-                                       'datatype'      => $attrib['datatype']
-//                                     'list'          => $attrib['list']
-                                       );
-
-                               $value_set      = 
$this->bocommon->validate_db_update($value_set);
-
-                               $this->db->query("UPDATE $table set $value_set 
WHERE id=" . $attrib['id'],__LINE__,__FILE__);
-
-                               if($attrib['new_choice'])
-                               {
-                                       $this->db->query("INSERT INTO 
$choice_table (attrib_id, value) "
-                                       . "VALUES ('" . $attrib['id'] . "','" . 
$attrib['new_choice']. "')",__LINE__,__FILE__);
-
-                               }
-
-                               if($attrib['delete_choice'])
-                               {
-                                       for 
($i=0;$i<count($attrib['delete_choice']);$i++)
-                                       {
-
-                                               $this->db->query("DELETE FROM 
$choice_table WHERE id='" . $attrib['delete_choice'][$i] . 
"'",__LINE__,__FILE__);
-                                       }
-                               }
-
-                               if($attrib['datatype']!='R' && 
$attrib['datatype']!='CH')
-                               {
-                                       $this->db->query("DELETE FROM 
$choice_table WHERE attrib_id='" . $attrib['id'] . "'",__LINE__,__FILE__);
-                               }
-
-                               $receipt['message'][] = array('msg'     => 
lang('Attribute has been edited'));
-                       }
-                       else
-                       {
-                               $receipt['error'][] = array('msg'       => 
lang('Attribute has NOT been edited'));
-                       }
-                       return $receipt;
-               }
-
-
-               function select_entity_type($type='')
-               {
-                       $table = $this->select_table($type);
-
-                       $this->db->query("SELECT * FROM $table ORDER BY name ");
-
-                       $i = 0;
-                       while ($this->db->next_record())
-                       {
-                               $entity_type[$i]['id']          = 
$this->db->f('id');
-                               $entity_type[$i]['name']                = 
stripslashes($this->db->f('name'));
-                               $entity_type[$i]['descr']       = 
stripslashes($this->db->f('descr'));
-                               $i++;
-                       }
-//_debug_array($entity_type);
-
-                       return $entity_type;
-               }
-
-       }
-?>

Index: inc/class.uimeter.inc.php
===================================================================
RCS file: inc/class.uimeter.inc.php
diff -N inc/class.uimeter.inc.php
--- inc/class.uimeter.inc.php   27 Dec 2006 10:37:59 -0000      1.13
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,583 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - property: a Facilities Management System.
-       *
-       * @author Sigurd Nes <address@hidden>
-       * @copyright Copyright (C) 2003-2005 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
-       * @package property
-       * @subpackage entity
-       * @version $Id: class.uimeter.inc.php,v 1.13 2006/12/27 10:37:59 
sigurdne Exp $
-       */
-
-       /**
-        * Description
-        * @package property
-        */
-
-       class property_uimeter
-       {
-               var $grants;
-               var $cat_id;
-               var $start;
-               var $query;
-               var $sort;
-               var $order;
-               var $filter;
-               var $part_of_town_id;
-               var $sub;
-               var $currentapp;
-
-               var $public_functions = array
-               (
-                       'index'  => True,
-                       'view'   => True,
-                       'edit'   => True,
-                       'delete' => True,
-               );
-
-               function property_uimeter()
-               {
-                       $GLOBALS['phpgw_info']['flags']['xslt_app'] = True;
-                       $this->currentapp                       = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
-                       $this->nextmatchs                       = 
CreateObject('phpgwapi.nextmatchs');
-                       $this->account                          = 
$GLOBALS['phpgw_info']['user']['account_id'];
-
-                       $this->bo                                       = 
CreateObject($this->currentapp.'.bometer');
-                       $this->bocommon                         = 
CreateObject($this->currentapp.'.bocommon');
-                       $this->menu                                     = 
CreateObject($this->currentapp.'.menu');
-
-                       $this->acl                              = 
CreateObject('phpgwapi.acl');
-                       $this->acl_location             = '.meter';
-                       $this->acl_read                         = 
$this->acl->check('.meter',1);
-                       $this->acl_add                          = 
$this->acl->check('.meter',2);
-                       $this->acl_edit                         = 
$this->acl->check('.meter',4);
-                       $this->acl_delete                       = 
$this->acl->check('.meter',8);
-
-                       $this->start                            = 
$this->bo->start;
-                       $this->query                            = 
$this->bo->query;
-                       $this->sort                                     = 
$this->bo->sort;
-                       $this->order                            = 
$this->bo->order;
-                       $this->filter                           = 
$this->bo->filter;
-                       $this->cat_id                           = 
$this->bo->cat_id;
-
-                       $this->menu->sub                        ='meter';
-               }
-
-               function save_sessiondata()
-               {
-                       $data = array
-                       (
-                               'start'         => $this->start,
-                               'query'         => $this->query,
-                               'sort'          => $this->sort,
-                               'order'         => $this->order,
-                               'filter'        => $this->filter,
-                               'cat_id'        => $this->cat_id
-                       );
-                       $this->bo->save_sessiondata($data);
-               }
-
-               function index()
-               {
-                       if(!$this->acl_read)
-                       {
-                               
$GLOBALS['phpgw']->redirect_link('/index.php','menuaction='.$this->currentapp.'.uilocation.stop&perm=1&acl_location='
 . $this->acl_location);
-                       }
-
-                       
$GLOBALS['phpgw']->xslttpl->add_file(array('meter','values','table_header',
-                                                                               
'menu',
-                                                                               
'nextmatchs',
-                                                                               
'search_field'));
-
-                       $links = $this->menu->links();
-
-                       $meter_list = $this->bo->read();
-
-                       $uicols = $this->bo->uicols;
-//_debug_array($uicols);
-
-                       $m      = count($uicols['name']);
-                       $j=0;
-                       if (isset($meter_list) AND is_array($meter_list))
-                       {
-                               foreach($meter_list as $meter_entry)
-                               {
-                                       for ($k=0;$k<$m;$k++)
-                                       {
-                                               
if($uicols['input_type'][$k]!='hidden')
-                                               {
-
-                                                       
if($meter_entry['query_location'][$uicols['name'][$k]])
-                                                       {
-                                                               
$content[$j]['row'][$k]['statustext']                   = lang('search');
-                                                               
$content[$j]['row'][$k]['text']                                 = 
$meter_entry[$uicols['name'][$k]];
-                                                               
$content[$j]['row'][$k]['link']                         = 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.index&query='
 . $meter_entry['query_location'][$uicols['name'][$k]] . '&lookup=' . $lookup);
-                                                       }
-                                                       else
-                                                       {
-                                                               
$content[$j]['row'][$k]['value']                        = 
$meter_entry[$uicols['name'][$k]];
-                                                               
$content[$j]['row'][$k]['name']                         = $uicols['name'][$k];
-                                                       }
-                                               }
-                                       }
-
-                                       if(!$lookup)
-                                       {
-                                               if($this->acl_read)
-                                               {
-                                                       
$content[$j]['row'][$k]['statustext']                   = lang('view the 
meter');
-                                                       
$content[$j]['row'][$k]['text']                                 = lang('view');
-                                                       
$content[$j]['row'][$k]['link']                                 = 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.view&id='
 . $meter_entry['meter_id']);
-                                                       $k++;
-                                               }
-
-                                               if($this->acl_edit)
-                                               {
-                                                       
$content[$j]['row'][$k]['statustext']                   = lang('edit the 
meter');
-                                                       
$content[$j]['row'][$k]['text']                                 = lang('edit');
-                                                       
$content[$j]['row'][$k]['link']                                 = 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.edit&id='
 . $meter_entry['meter_id']);
-                                                       $k++;
-                                               }
-
-                                               if($this->acl_delete)
-                                               {
-                                                       
$content[$j]['row'][$k]['statustext']                   = lang('delete the 
meter');
-                                                       
$content[$j]['row'][$k]['text']                                 = 
lang('delete');
-                                                       
$content[$j]['row'][$k]['link']                                 = 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.delete&id='
 . $meter_entry['meter_id']);
-                                                       $k++;
-                                               }
-                                       }
-                                       $j++;
-                               }
-                       }
-
-                       $m      = count($uicols['descr']);
-                       for ($i=0;$i<$m;$i++)
-                       {
-                               if($uicols['input_type'][$i]!='hidden')
-                               {
-                                       $table_header[$i]['header']     = 
$uicols['descr'][$i];
-                                       $table_header[$i]['width']              
= '5%';
-                                       $table_header[$i]['align']              
= 'center';
-                                       if($uicols['name'][$i]=='loc1')
-                                       {
-                                               $table_header[$i]['sort_link']  
=true;
-                                               $table_header[$i]['sort']       
        = $this->nextmatchs->show_sort_order(array
-                                                                               
(
-                                                                               
        'sort'  => $this->sort,
-                                                                               
        'var'   =>      'location_code',
-                                                                               
        'order' =>      $this->order,
-                                                                               
        'extra'         => array('menuaction'   => 
$this->currentapp.'.uimeter.index',
-                                                                               
                                                        'type_id'       
=>$type_id,
-                                                                               
                                                        'query'         
=>$this->query,
-                                                                               
                                                        'lookup'        
=>$lookup,
-                                                                               
                                                        'district_id'   => 
$this->district_id,
-                                                                               
                                                        'cat_id'        
=>$this->cat_id)
-                                                                               
));
-                                       }
-                                       if($uicols['name'][$i]=='num')
-                                       {
-                                               $table_header[$i]['sort_link']  
=true;
-                                               $table_header[$i]['sort']       
        = $this->nextmatchs->show_sort_order(array
-                                                                               
(
-                                                                               
        'sort'  => $this->sort,
-                                                                               
        'var'   =>      'num',
-                                                                               
        'order' =>      $this->order,
-                                                                               
        'extra'         => array('menuaction'   => 
$this->currentapp.'.uimeter.index',
-                                                                               
                                                        'type_id'       
=>$type_id,
-                                                                               
                                                        'query'         
=>$this->query,
-                                                                               
                                                        'lookup'        
=>$lookup,
-                                                                               
                                                        'district_id'   => 
$this->district_id,
-                                                                               
                                                        'cat_id'        
=>$this->cat_id)
-                                                                               
));
-                                       }
-                                       if($uicols['name'][$i]=='address')
-                                       {
-                                               $table_header[$i]['sort_link']  
=true;
-                                               $table_header[$i]['sort']       
        = $this->nextmatchs->show_sort_order(array
-                                                                               
(
-                                                                               
        'sort'  => $this->sort,
-                                                                               
        'var'   =>      'address',
-                                                                               
        'order' =>      $this->order,
-                                                                               
        'extra'         => array('menuaction'   => 
$this->currentapp.'.uimeter.index',
-                                                                               
                                                        'type_id'       
=>$type_id,
-                                                                               
                                                        'query'         
=>$this->query,
-                                                                               
                                                        'lookup'        
=>$lookup,
-                                                                               
                                                        'district_id'   => 
$this->district_id,
-                                                                               
                                                        'cat_id'        
=>$this->cat_id)
-                                                                               
));
-                                       }
-                               }
-                       }
-
-                       if(!$lookup)
-                       {
-                               if($this->acl_read)
-                               {
-                                       $table_header[$i]['width']              
        = '5%';
-                                       $table_header[$i]['align']              
        = 'center';
-                                       $table_header[$i]['header']             
        = lang('view');
-                                       $i++;
-                               }
-                               if($this->acl_edit)
-                               {
-                                       $table_header[$i]['width']              
        = '5%';
-                                       $table_header[$i]['align']              
        = 'center';
-                                       $table_header[$i]['header']             
        = lang('edit');
-                                       $i++;
-                               }
-                               if($this->acl_delete)
-                               {
-                                       $table_header[$i]['width']              
        = '5%';
-                                       $table_header[$i]['align']              
        = 'center';
-                                       $table_header[$i]['header']             
        = lang('delete');
-                                       $i++;
-                               }
-                       }
-                       else
-                       {
-                               $table_header[$i]['width']                      
= '5%';
-                               $table_header[$i]['align']                      
= 'center';
-                               $table_header[$i]['header']             = 
lang('select');
-                       }
-
-//_debug_array($content);
-                       if($this->acl_add)
-                       {
-                               $table_add[] = array
-                               (
-                                       'lang_add'                              
=> lang('add'),
-                                       'lang_add_statustext'   => lang('add a 
meter'),
-                                       'add_action'                    => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.edit')
-
-                               );
-                       }
-
-                       $link_data = array
-                       (
-                               'menuaction'    => 
$this->currentapp.'.uimeter.index',
-                                               'start'                 => 
$this->start,
-                                               'sort'                  
=>$this->sort,
-                                               'order'                 
=>$this->order,
-                                               'cat_id'                
=>$this->cat_id,
-                                               'filter'                
=>$this->filter,
-                                               'query'                 
=>$this->query
-                       );
-
-
-                       $data = array
-                       (
-                               'links'                                         
        => $links,
-                               'allow_allrows'                                 
=> False,
-                               'start_record'                                  
=> $this->start,
-                               'record_limit'                                  
=> $GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'],
-                               'num_records'                                   
=> count($meter_list),
-                               'all_records'                                   
=> $this->bo->total_records,
-                               'link_url'                                      
        => $GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'img_path'                                      
        => $GLOBALS['phpgw']->common->get_image_path('phpgwapi','default'),
-                               'lang_no_cat'                                   
=> lang('no category'),
-                               'lang_cat_statustext'                   => 
lang('Select the category the meter belongs to. To do not use a category select 
NO CATEGORY'),
-                               'select_name'                                   
=> 'cat_id',
-                               'cat_list'                                      
        => $this->bo->get_category_list('filter',$this->cat_id),
-                               'select_action'                                 
=> $GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'filter_list'                                   
=> $this->nextmatchs->xslt_filter(array('filter' => $this->filter,'yours' => 
'yes')),
-                               'lang_filter_statustext'                => 
lang('Select the filter. To show all entries select SHOW ALL'),
-                               'lang_searchfield_statustext'   => lang('Enter 
the search string. To show all entries, empty this field and press the SUBMIT 
button again'),
-                               'lang_searchbutton_statustext'  => lang('Submit 
the search string'),
-                               'query'                                         
        => $this->query,
-                               'lang_search'                                   
=> lang('search'),
-                               'table_header'                                  
=> $table_header,
-                               'values'                                        
        => $content,
-                               'table_add'                                     
        => $table_add
-                       );
-
-                       $appname                                                
= lang('meter');
-                       $function_msg                                   = 
lang('list meter');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('list' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-                       $this->save_sessiondata();
-               }
-
-               function edit()
-               {
-                       if(!$this->acl_add && !$this->acl_edit)
-                       {
-                               
$GLOBALS['phpgw']->redirect_link('/index.php','menuaction='.$this->currentapp.'.uilocation.stop&perm=2&acl_location='
 . $this->acl_location);
-                       }
-
-                       $bolocation                     = 
CreateObject($this->currentapp.'.bolocation');
-
-                       $id                                     = 
get_var('id',array('POST','GET'));
-                       $values                         = 
get_var('values',array('POST'));
-
-                       $GLOBALS['phpgw']->xslttpl->add_file(array('meter'));
-
-                       $insert_record = 
$GLOBALS['phpgw']->session->appsession('insert_record',$this->currentapp);
-                       $insert_record_entity = 
$GLOBALS['phpgw']->session->appsession('insert_record_entity',$this->currentapp);
-
-                       for ($j=0;$j<count($insert_record_entity);$j++)
-                       {
-                               
$insert_record['extra'][$insert_record_entity[$j]]      = 
$insert_record_entity[$j];
-                       }
-
-                       if ($values['save'])
-                       {
-                               for ($i=0; 
$i<count($insert_record['location']); $i++)
-                               {
-                                       
if($_POST[$insert_record['location'][$i]])
-                                       {
-                                               
$values['location'][$insert_record['location'][$i]]= 
$_POST[$insert_record['location'][$i]];
-                                       }
-                               }
-
-                               while (is_array($insert_record['extra']) && 
list($key,$column) = each($insert_record['extra']))
-                               {
-                                       if($_POST[$key])
-                                       {
-                                               $values['extra'][$column]       
= $_POST[$key];
-                                       }
-                               }
-
-                               $values['street_name']          = 
$_POST['street_name'];
-                               $values['street_number']        = 
$_POST['street_number'];
-                               $values['location_name']        = $_POST['loc' 
. (count($values['location'])).'_name']; // if not address - get the parent 
name as address
-
-                               if(!$values['num'] && !$id)
-                               {
-                                       
$receipt['error'][]=array('msg'=>lang('Enter a meter ID !'));
-                               }
-
-                               if($id)
-                               {
-                                       $values['meter_id']=$id;
-                                       $action='edit';
-                               }
-                               else
-                               {
-                                       
if($this->bo->check_meter_num($values['num']))
-                                       {
-                                               
$receipt['error'][]=array('msg'=>lang('This meter id is already registered!') . 
'[ '.$values['num'].' ]');
-                                               $error_id=true;
-                                               unset($values['num']);
-                                       }
-                                       else
-                                       {
-                                               $id =   $values['meter_id'];
-                                       }
-                               }
-
-                               if(!$values['location'])
-                               {
-                                       
$receipt['error'][]=array('msg'=>lang('Please select a location !'));
-                               }
-
-                               if(!$values['cat_id'])
-                               {
-                                       
$receipt['error'][]=array('msg'=>lang('Please select a category !'));
-                               }
-
-                               if(!$receipt['error'])
-                               {
-                                       $receipt = 
$this->bo->save($values,$action);
-                                       $id = $receipt['meter_id'];
-                               }
-                               else
-                               {
-                                       if($values['location'])
-                                       {
-                                               $location_code=implode("-", 
$values['location']);
-                                               $values['location_data'] = 
$bolocation->read_single($location_code,$values['extra']);
-                                       }
-                                       if($values['extra']['p_num'])
-                                       {
-                                               
$values['p'][$values['extra']['p_entity_id']]['p_num']=$values['extra']['p_num'];
-                                               
$values['p'][$values['extra']['p_entity_id']]['p_entity_id']=$values['extra']['p_entity_id'];
-                                               
$values['p'][$values['extra']['p_entity_id']]['p_cat_id']=$values['extra']['p_cat_id'];
-                                               
$values['p'][$values['extra']['p_entity_id']]['p_cat_name']=$_POST['entity_cat_name_'.$values['extra']['p_entity_id']];
-                                       }
-                               }
-                       }
-
-                       if ($id)
-                       {
-                               $values = $this->bo->read_single($id);
-//                     _debug_array($meter);
-                               $function_msg = lang('edit meter');
-                               $action='edit';
-                       }
-                       else
-                       {
-                               $function_msg = lang('add meter');
-                               $action='add';
-                       }
-
-                       if ($values['cat_id'])
-                       {
-                               $this->cat_id = $values['cat_id'];
-                       }
-
-                       $link_data = array
-                       (
-                               'menuaction'    => 
$this->currentapp.'.uimeter.edit',
-                               'id'    => $id
-                       );
-
-                       $location_data=$bolocation->initiate_ui_location(array(
-                                               'values'                => 
$values['location_data'],
-                                               'type_id'               => -1, 
// calculated from location_types
-                                               'no_link'               => 
False, // disable lookup links for location type less than type_id
-                                               'tenant'                => 
False,
-                                               'lookup_type'   => 'form',
-                                               'lookup_entity' => 
$this->bocommon->get_lookup_entity('meter'),
-                                               'entity_data'   => $values['p']
-                                               ));
-
-
-                       $msgbox_data = $this->bocommon->msgbox_data($receipt);
-
-                       $data = array
-                       (
-                               'msgbox_data'                                   
=> $GLOBALS['phpgw']->common->msgbox($msgbox_data),
-                               'location_data'                                 
=> $location_data,
-                               'form_action'                                   
=> $GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'done_action'                                   
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.index'),
-                               'lang_meter_id'                                 
=> lang('meter ID'),
-                               'lang_name'                                     
        => lang('name'),
-                               'lang_remark'                                   
=> lang('Remark'),
-                               'lang_category'                                 
=> lang('category'),
-                               'lang_access'                                   
=> lang('private'),
-                               'lang_save'                                     
        => lang('save'),
-                               'lang_done'                                     
        => lang('done'),
-                               'value_meter_id'                                
=> $values['num'],
-                               'value_name'                                    
=> $values['name'],
-                               'value_remark'                                  
=> $values['remark'],
-                               'lang_meter_id_statustext'              => 
lang('Enter the meter ID'),
-                               'lang_name_statustext'                  => 
lang('Enter the name of the meter'),
-                               'lang_remark_statustext'                => 
lang('Enter a remark - if any'),
-                               'lang_done_statustext'                  => 
lang('Back to the list'),
-                               'lang_save_statustext'                  => 
lang('Save the meter'),
-                               'lang_no_cat'                                   
=> lang('no category'),
-                               'lang_cat_statustext'                   => 
lang('Select the category the meter belongs to. To do not use a category select 
NO CATEGORY'),
-                               'select_name'                                   
=> 'values[cat_id]',
-                               'cat_list'                                      
        => $this->bo->get_category_list('select',$this->cat_id)
-                       );
-
-                       $appname                                                
= lang('meter');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('edit' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-               }
-
-               function delete()
-               {
-                       if(!$this->acl_delete)
-                       {
-                               
$GLOBALS['phpgw']->redirect_link('/index.php','menuaction='.$this->currentapp.'.uilocation.stop&perm=8&acl_location='
 . $this->acl_location);
-                       }
-
-                       $id     = get_var('id',array('POST','GET'));
-                       $confirm        = get_var('confirm',array('POST'));
-
-                       $link_data = array
-                       (
-                               'menuaction' => 
$this->currentapp.'.uimeter.index'
-                       );
-
-                       if (get_var('confirm',array('POST')))
-                       {
-                               $this->bo->delete($id);
-                               
$GLOBALS['phpgw']->redirect_link('/index.php',$link_data);
-                       }
-
-                       
$GLOBALS['phpgw']->xslttpl->add_file(array('app_delete'));
-
-                       $data = array
-                       (
-                               'done_action'                   => 
$GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'delete_action'                 => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.delete&id='
 . $id),
-                               'lang_confirm_msg'              => lang('do you 
really want to delete this entry'),
-                               'lang_yes'                              => 
lang('yes'),
-                               'lang_yes_statustext'   => lang('Delete the 
entry'),
-                               'lang_no_statustext'    => lang('Back to the 
list'),
-                               'lang_no'                               => 
lang('no')
-                       );
-
-                       $appname                                                
= lang('meter');
-                       $function_msg                                   = 
lang('delete meter');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('delete' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-               }
-
-               function view()
-               {
-                       if(!$this->acl_read)
-                       {
-                               
$GLOBALS['phpgw']->redirect_link('/index.php','menuaction='.$this->currentapp.'.uilocation.stop&perm=1&acl_location='
 . $this->acl_location);
-                       }
-
-                       $bolocation                     = 
CreateObject($this->currentapp.'.bolocation');
-                       $id                                     = 
get_var('id',array('POST','GET'));
-
-                       $GLOBALS['phpgw']->xslttpl->add_file(array('meter'));
-
-
-                       $values = $this->bo->read_single($id);
-                       $function_msg = lang('View meter');
-
-                       if ($values['cat_id'])
-                       {
-                               $this->cat_id = $values['cat_id'];
-                       }
-
-                       $link_data = array
-                       (
-                               'menuaction'    => 
$this->currentapp.'.uimeter.edit',
-                               'id'    => $id
-                       );
-
-                       $location_data=$bolocation->initiate_ui_location(array(
-                                               'values'                => 
$values['location_data'],
-                                               'type_id'               => 
count(explode('-',$values['location_data']['location_code'])),
-                                               'no_link'               => 
False, // disable lookup links for location type less than type_id
-                                               'tenant'                => 
False,
-                                               'lookup_type'   => 'view',
-                                               'lookup_entity' => 
$this->bocommon->get_lookup_entity('meter'),
-                                               'entity_data'   => $values['p']
-                                               ));
-
-                       $data = array
-                       (
-                               'location_data'                                 
=> $location_data,
-                               'done_action'                                   
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.index'),
-                               'edit_action'                                   
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uimeter.edit&id='
 . $id),
-                               'lang_done_statustext'                  => 
lang('Back to the list'),
-                               'lang_edit_statustext'                  => 
lang('Edit this meter'),
-                               'lang_done'                                     
        => lang('done'),
-                               'lang_edit'                                     
        => lang('edit'),
-                               'lang_meter_id'                                 
=> lang('meter ID'),
-                               'lang_name'                                     
        => lang('name'),
-                               'lang_remark'                                   
=> lang('Remark'),
-                               'lang_category'                                 
=> lang('category'),
-                               'lang_access'                                   
=> lang('private'),
-                               'value_meter_id'                                
=> $id,
-                               'value_name'                                    
=> $values['name'],
-                               'value_remark'                                  
=> $values['remark'],
-                               'cat_list'                                      
        => $this->bo->get_category_list('',$this->cat_id),
-                       );
-
-                       $appname                                                
= lang('meter');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('view' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-               }
-
-       }
-?>

Index: inc/class.uistandard_entity.inc.php
===================================================================
RCS file: inc/class.uistandard_entity.inc.php
diff -N inc/class.uistandard_entity.inc.php
--- inc/class.uistandard_entity.inc.php 27 Dec 2006 10:37:59 -0000      1.13
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,519 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - property: a Facilities Management System.
-       *
-       * @author Sigurd Nes <address@hidden>
-       * @copyright Copyright (C) 2003-2005 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/bbb_/ekstern/
-       * @package property
-       * @subpackage admin
-       * @version $Id: class.uistandard_entity.inc.php,v 1.13 2006/12/27 
10:37:59 sigurdne Exp $
-       */
-
-       /**
-        * Description
-        * @package property
-        */
-
-       class property_uistandard_entity
-       {
-               var $grants;
-               var $start;
-               var $query;
-               var $sort;
-               var $order;
-               var $sub;
-               var $currentapp;
-
-               var $public_functions = array
-               (
-                       'index'                         => True,
-                       'view'                          => True,
-                       'edit'                          => True,
-                       'delete'                        => True,
-                       'list_attribute'        => True,
-                       'edit_attrib'           => True,
-               );
-
-               function property_uistandard_entity()
-               {
-                       $GLOBALS['phpgw_info']['flags']['xslt_app'] = True;
-                       $this->currentapp                       = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
-                       $this->nextmatchs                       = 
CreateObject('phpgwapi.nextmatchs');
-                       $this->account                          = 
$GLOBALS['phpgw_info']['user']['account_id'];
-
-                       $this->bo                                       = 
CreateObject($this->currentapp.'.bostandard_entity',True);
-                       $this->bocommon                         = 
CreateObject($this->currentapp.'.bocommon');
-                       $this->menu                                     = 
CreateObject($this->currentapp.'.menu');
-
-                       $this->start                            = 
$this->bo->start;
-                       $this->query                            = 
$this->bo->query;
-                       $this->sort                                     = 
$this->bo->sort;
-                       $this->order                            = 
$this->bo->order;
-               }
-
-               function save_sessiondata()
-               {
-                       $data = array
-                       (
-                               'start'         => $this->start,
-                               'query'         => $this->query,
-                               'sort'          => $this->sort,
-                               'order'         => $this->order,
-                       );
-                       $this->bo->save_sessiondata($data);
-               }
-
-               function index()
-               {
-                       $type   = get_var('type',array('POST','GET'));
-
-                       $GLOBALS['phpgw']->xslttpl->add_file(array(
-                                                                               
'standard_entity',
-                                                                               
'nextmatchs',
-                                                                               
'menu',
-                                                                               
'search_field'));
-                       $links = $this->menu->links();
-
-                       $standard_list = $this->bo->read($type);
-
-                       while (is_array($standard_list) && list(,$standard) = 
each($standard_list))
-                       {
-                               $words = split(' ',$standard['descr']);
-                               $first = "$words[0] $words[1] $words[2] 
$words[3]";
-
-                               $content[] = array
-                               (
-                                       'id'                                    
        => $standard['id'],
-                                       'name'                                  
        => $standard['name'],
-                                       'prefix'                                
        => $standard['prefix'],
-                                       'first'                                 
        => $first,
-                                       'link_attribute'                        
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.list_attribute&type_id='
 . $standard['id'].'&type='.$type),
-                                       'link_edit'                             
        => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.edit&id='
 . $standard['id'].'&type='.$type),
-                                       'link_delete'                           
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.delete&id='
 . $standard['id'].'&type='.$type),
-                                       'lang_view_standardtext'        => 
lang('view the standard'),
-                                       'lang_attribute_standardtext'   => 
lang('attributes for the standard'). ' ' . lang($type),
-                                       'lang_edit_standardtext'        => 
lang('edit the standard'),
-                                       'lang_delete_standardtext'      => 
lang('delete the standard'),
-                                       'text_attribute'                        
=> lang('Attributes'),
-                                       'text_edit'                             
        => lang('edit'),
-                                       'text_delete'                           
=> lang('delete')
-                               );
-                       }
-
-//_debug_array($content);
-
-                       $table_header[] = array
-                       (
-
-                               'lang_descr'            => lang('Descr'),
-                               'lang_prefix'           => lang('prefix'),
-                               'lang_attribute'        => lang('Attributes'),
-                               'lang_edit'                     => lang('edit'),
-                               'lang_delete'           => lang('delete'),
-                               'sort_id'       => 
$this->nextmatchs->show_sort_order(array
-                                                                               
(
-                                                                               
        'sort'  => $this->sort,
-                                                                               
        'var'   =>      'id',
-                                                                               
        'order' =>      $this->order,
-                                                                               
        'extra'         => array('menuaction'   => 
$this->currentapp.'.uistandard_entity.index',
-                                                                               
                                                        'type'  =>$type)
-                                                                               
)),
-                               'lang_id'       => lang('standard id'),
-                               'sort_name'     => 
$this->nextmatchs->show_sort_order(array
-                                                                               
(
-                                                                               
        'sort'  => $this->sort,
-                                                                               
        'var'   =>      'name',
-                                                                               
        'order' =>      $this->order,
-                                                                               
        'extra'         => array('menuaction'   => 
$this->currentapp.'.uistandard_entity.index',
-                                                                               
                                                        'type'  =>$type)
-                                                                               
)),
-                               'lang_name'     => lang('Name'),
-                       );
-
-                       $table_add[] = array
-                       (
-                               'lang_add'                              => 
lang('add'),
-                               'lang_add_standardtext' => lang('add a 
standard'),
-                               'add_action'                    => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.edit&type='.$type),
-                               'lang_done'                             => 
lang('done'),
-                               'lang_done_standardtext'        => lang('back 
to admin'),
-                               'done_action'                   => 
$GLOBALS['phpgw']->link('/admin/index.php')
-                       );
-
-
-                       $data = array
-                       (
-                               'links'                                         
        => $links,
-                               'allow_allrows'                                 
=> False,
-                               'start_record'                                  
=> $this->start,
-                               'record_limit'                                  
=> $GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'],
-                               'num_records'                                   
=> count($standard_list),
-                               'all_records'                                   
=> $this->bo->total_records,
-                               'link_url'                                      
        => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.index&type='.$type),
-                               'img_path'                                      
        => $GLOBALS['phpgw']->common->get_image_path('phpgwapi','default'),
-                               'lang_searchfield_standardtext' => lang('Enter 
the search string. To show all entries, empty this field and press the SUBMIT 
button again'),
-                               'lang_searchbutton_standardtext'        => 
lang('Submit the search string'),
-                               'query'                                         
        => $this->query,
-                               'lang_search'                                   
=> lang('search'),
-                               'table_header'                                  
=> $table_header,
-                               'values'                                        
        => $content,
-                               'table_add'                                     
        => $table_add
-                       );
-
-                       $appname                                                
= lang($type);
-                       $function_msg                                   = 
lang('list '.$type.' standard');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('list' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-                       $this->save_sessiondata();
-               }
-
-               function edit()
-               {
-                       $type   = get_var('type',array('POST','GET'));
-                       $id     = get_var('id',array('POST','GET'));
-                       $values                 = 
get_var('values',array('POST'));
-
-                       
$GLOBALS['phpgw']->xslttpl->add_file(array('standard_entity'));
-
-                       if ($values['save'])
-                       {
-                               if($id)
-                               {
-                                       $values['id']=$id;
-                                       $action='edit';
-                               }
-                               else
-                               {
-                       //              $id                             = 
$values['id'];
-                                       $standard['name']       = 
$values['name'];
-                                       $standard['descr']      = 
$values['descr'];
-                                       $standard['prefix']     = 
$values['prefix'];
-                               }
-
-
-                               $receipt = 
$this->bo->save($values,$action,$type);
-                               if(!$id)
-                               {
-                                       $id=$receipt['id'];
-                               }
-
-                       }
-
-                       if ($id)
-                       {
-                               $standard = $this->bo->read_single($id,$type);
-                               $function_msg = lang('edit standard');
-                               $action='edit';
-                       }
-                       else
-                       {
-                               $function_msg = lang('add standard');
-                               $action='add';
-                       }
-
-
-                       $link_data = array
-                       (
-                               'menuaction'    => 
$this->currentapp.'.uistandard_entity.edit',
-                               'id'    => $id,
-                               'type' => $type
-                       );
-//_debug_array($link_data);
-
-                       $msgbox_data = $this->bocommon->msgbox_data($receipt);
-
-                       $data = array
-                       (
-                               'msgbox_data'                                   
=> $GLOBALS['phpgw']->common->msgbox($msgbox_data),
-                               'lang_prefix'                                   
=> lang('Standard prefix'),
-                               'lang_prefix_standardtext'              => 
lang('Enter a standard prefix for the id'),
-                               'lang_name_standardtext'                => 
lang('Enter a name of the standard'),
-
-                               'form_action'                                   
=> $GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'done_action'                                   
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.index&type='.$type),
-                               'lang_id'                                       
        => lang('standard ID'),
-                               'lang_name'                                     
        => lang('Name'),
-                               'lang_descr'                                    
=> lang('Descr'),
-                               'lang_save'                                     
        => lang('save'),
-                               'lang_done'                                     
        => lang('done'),
-                               'value_id'                                      
        => $id,
-                               'value_name'                                    
=> $standard['name'],
-                               'value_prefix'                                  
=> $standard['prefix'],
-                               'lang_id_standardtext'                  => 
lang('Enter the standard ID'),
-                               'lang_descr_standardtext'               => 
lang('Enter a description of the standard'),
-                               'lang_done_standardtext'                => 
lang('Back to the list'),
-                               'lang_save_standardtext'                => 
lang('Save the standard'),
-                               'type_id'                                       
        => $standard['type_id'],
-                               'value_descr'                                   
=> $standard['descr']
-
-
-                       );
-
-                       $appname                                                
= lang($type);
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('edit' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-               }
-
-               function delete()
-               {
-                       $attrib         = get_var('attrib',array('POST','GET'));
-                       $type           = get_var('type',array('POST','GET'));
-                       $type_id        = 
get_var('type_id',array('POST','GET'));
-                       $id                     = 
get_var('id',array('POST','GET'));
-                       $confirm        = get_var('confirm',array('POST'));
-
-                       if($attrib)
-                       {
-                               $function='list_attribute';
-                       }
-                       else
-                       {
-                               $function='index';
-                       }
-                       $link_data = array
-                       (
-                               'menuaction' => 
$this->currentapp.'.uistandard_entity.'.$function,
-                               'type' => $type,
-                               'type_id' => $type_id
-                       );
-
-                       if (get_var('confirm',array('POST')))
-                       {
-                               $this->bo->delete($id,$type,$attrib);
-                               
$GLOBALS['phpgw']->redirect_link('/index.php',$link_data);
-                       }
-
-                       
$GLOBALS['phpgw']->xslttpl->add_file(array('app_delete'));
-
-                       $data = array
-                       (
-                               'done_action'                   => 
$GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'delete_action'                 => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.delete&id='
 . $id.'&type='.$type.'&type_id='.$type_id),
-                               'lang_confirm_msg'              => lang('do you 
really want to delete this entry'),
-                               'lang_yes'                              => 
lang('yes'),
-                               'lang_yes_standardtext' => lang('Delete the 
entry'),
-                               'lang_no_standardtext'  => lang('Back to the 
list'),
-                               'lang_no'                               => 
lang('no')
-                       );
-
-                       $appname                                                
= lang($type);
-                       $function_msg                                   = 
lang('delete '.$type.' standard');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('delete' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-               }
-
-
-               function list_attribute()
-               {
-                       $type   = get_var('type',array('POST','GET'));
-                       $type_id        = 
get_var('type_id',array('POST','GET'));
-
-                       $GLOBALS['phpgw']->xslttpl->add_file(array(
-                                                                               
'standard_entity',
-                                                                               
'nextmatchs',
-                                                                               
'search_field'));
-
-                       $attrib_list = $this->bo->read_attrib($type,$type_id);
-
-                       while (is_array($attrib_list) && list(,$attrib) = 
each($attrib_list))
-                       {
-                               $words = split(' ',$attrib['descr']);
-                               $first = "$words[0] $words[1] $words[2] 
$words[3]";
-
-
-                               $content[] = array
-                               (
-                                       'name'                                  
        => $attrib['name'],
-                                       'type_name'                             
        => $attrib['type_name'],
-                                       'datatype'                              
        => $attrib['datatype'],
-                                       'first'                                 
        => $first,
-                                       'link_edit'                             
        => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.edit_attrib&id='
 . $attrib['id'].'&type='.$type.'&type_id='.$type_id),
-                                       'link_delete'                           
=> 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.delete&id='
 . $attrib['id'].'&type='.$type.'&type_id='.$type_id.'&attrib=true'),
-                                       'lang_view_attribtext'          => 
lang('view the attrib'),
-                                       'lang_attribute_attribtext'     => 
lang('attributes for the attrib'). ' ' . lang($type),
-                                       'lang_edit_attribtext'          => 
lang('edit the attrib'),
-                                       'lang_delete_attribtext'        => 
lang('delete the attrib'),
-                                       'text_attribute'                        
=> lang('Attributes'),
-                                       'text_edit'                             
        => lang('edit'),
-                                       'text_delete'                           
=> lang('delete')
-                               );
-                       }
-
-//_debug_array($content);
-
-                       $table_header[] = array
-                       (
-                               'lang_type_name'                => lang('Type'),
-                               'lang_descr'            => lang('Descr'),
-                               'lang_datatype'         => lang('Datatype'),
-                               'lang_edit'                     => lang('edit'),
-                               'lang_delete'           => lang('delete'),
-                               'sort_name'     => 
$this->nextmatchs->show_sort_order(array
-                                                                               
(
-                                                                               
        'sort'  => $this->sort,
-                                                                               
        'var'   =>      'name',
-                                                                               
        'order' =>      $this->order,
-                                                                               
        'extra'         => array('menuaction'   => 
$this->currentapp.'.uistandard_entity.list_attribute',
-                                                                               
                                                        'type'  =>$type,
-                                                                               
                                                        'type_id'       
=>$type_id)
-                                                                               
)),
-                               'lang_name'     => lang('Name'),
-                       );
-
-                       $table_add[] = array
-                       (
-                               'lang_add'                              => 
lang('add'),
-                               'lang_add_attribtext'   => lang('add an 
attrib'),
-                               'add_action'                    => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.edit_attrib&type='.$type.'&type_id='.$type_id),
-                               'lang_done'                             => 
lang('done'),
-                               'lang_done_attribtext'  => lang('back to 
admin'),
-                               'done_action'                   => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.index&type='.$type),
-                       );
-
-
-                       $data = array
-                       (
-                               'allow_allrows'                                 
=> False,
-                               'start_record'                                  
=> $this->start,
-                               'record_limit'                                  
=> $GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'],
-                               'num_records'                                   
=> count($attrib_list),
-                               'all_records'                                   
=> $this->bo->total_records,
-                               'link_url'                                      
        => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.list_attribute&type='.$type
 .'&type_id=' . $type_id),
-                               'img_path'                                      
        => $GLOBALS['phpgw']->common->get_image_path('phpgwapi','default'),
-                               'lang_searchfield_attribtext'   => lang('Enter 
the search string. To show all entries, empty this field and press the SUBMIT 
button again'),
-                               'lang_searchbutton_attribtext'  => lang('Submit 
the search string'),
-                               'query'                                         
        => $this->query,
-                               'lang_search'                                   
=> lang('search'),
-                               'table_header_attrib'                   => 
$table_header,
-                               'values_attrib'                                 
=> $content,
-                               'table_add'                                     
        => $table_add
-                       );
-
-                       $appname                                                
= lang('attribute');
-                       $function_msg                                   = 
lang('list '.$type.' attribute');
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('list_attribute' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-                       $this->save_sessiondata();
-               }
-
-               function edit_attrib()
-               {
-                       $type_id        = 
get_var('type_id',array('POST','GET'));
-                       $type           = get_var('type',array('POST','GET'));
-                       $id                     = 
get_var('id',array('POST','GET'));
-                       $values         = get_var('values',array('POST'));
-
-                       
$GLOBALS['phpgw']->xslttpl->add_file(array('standard_entity'));
-
-                       if ($values['save'])
-                       {
-                               if($id)
-                               {
-                                       $values['id']=$id;
-                                       $action='edit';
-                               }
-                               $attrib['name']         = $values['name'];
-                               $attrib['descr']        = $values['descr'];
-                               $type_id                        = 
$values['type_id'];
-
-                               $receipt = 
$this->bo->save_attrib($values,$action,$type);
-//_debug_array($receipt);
-
-                               if(!$id)
-                               {
-                                       $id=$receipt['id'];
-                               }
-
-                       }
-
-                       if ($id)
-                       {
-                               $attrib = 
$this->bo->read_single_attrib($id,$type);
-                               $type_name=$attrib['type_name'];
-                               $function_msg = lang('edit attribute'). ' ' . 
lang($type_name);
-                               $action='edit';
-                       }
-                       else
-                       {
-                               $function_msg = lang('add attribute');
-                               $action='add';
-                       }
-
-
-                       $link_data = array
-                       (
-                               'menuaction'    => 
$this->currentapp.'.uistandard_entity.edit_attrib',
-                               'id'    => $id,
-                               'type' => $type
-                       );
-//_debug_array($link_data);
-
-                       $msgbox_data = $this->bocommon->msgbox_data($receipt);
-
-                       if($attrib['datatype']=='R' || 
$attrib['datatype']=='CH')
-                       {
-                               $multiple_choice= True;
-                       }
-
-                       $data = array
-                       (
-                               'msgbox_data'                                   
=> $GLOBALS['phpgw']->common->msgbox($msgbox_data),
-                               'form_action'                           => 
$GLOBALS['phpgw']->link('/index.php',$link_data),
-                               'done_action'                           => 
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uistandard_entity.list_attribute&type='.$type.'&type_id='.$type_id),
-                               'lang_id'                                       
=> lang('Attribute ID'),
-                               'lang_name'                                     
=> lang('Name'),
-                               'lang_descr'                            => 
lang('Descr'),
-                               'lang_entity_type'                      => 
lang('Type'),
-                               'lang_no_entity_type'           => lang('No 
entity type'),
-                               'lang_save'                                     
=> lang('save'),
-                               'lang_done'                                     
=> lang('done'),
-                               'lang_choice'                           => 
lang('Choice'),
-                               'lang_new_value'                        => 
lang('New value'),
-                               'lang_new_value_statustext'     => lang('New 
value for multiple choice'),
-                               'multiple_choice'                       => 
$multiple_choice,
-                               'value_choice'                          => 
$attrib['choice'],
-
-                               'lang_delete_value'                     => 
lang('Delete value'),
-                               'lang_value'                            => 
lang('value'),
-                               'lang_delete_choice_statustext'=> lang('Delete 
this value from the list of multiple choice'),
-                               'value_id'                                      
=> $id,
-                               'value_name'                                    
=> $attrib['name'],
-                               'lang_id_attribtext'            => lang('Enter 
the attribute ID'),
-                               'lang_entity_statustext'        => lang('Select 
a entity type'),
-                               'lang_descr_attribtext'         => lang('Enter 
a description the attribute'),
-                               'lang_done_attribtext'          => lang('Back 
to the list'),
-                               'lang_save_attribtext'          => lang('Save 
the attribute'),
-                               'type_id'                                       
=> $attrib['type_id'],
-                               'value_descr'                           => 
$attrib['descr'],
-                               'entity_list'                           => 
$this->bo->select_entity_type($type,$type_id),
-                               'select_entity_type'            => 
'values[type_id]',
-                               'lang_datatype'                         => 
lang('Datatype'),
-                               'lang_datatype_statustext'      => lang('Select 
a datatype'),
-                               'lang_no_datatype'                      => 
lang('No datatype'),
-                               'datatype_list'                         => 
$this->bo->select_datatype($attrib['datatype']),
-                               'select_datatype'                       => 
'values[datatype]',
-//                             'value_list'                            => 
$values['list'],
-//                             'lang_list'                                     
=> lang('show in list'),
-//                             'lang_list_statustext'          => lang('check 
to show this attribute in list')
-                       );
-//_debug_array($data);
-
-                       $appname                                                
= lang($type);
-
-                       $GLOBALS['phpgw_info']['flags']['app_header'] = 
lang($this->currentapp) . ' - ' . $appname . ': ' . $function_msg;
-                       
$GLOBALS['phpgw']->xslttpl->set_var('phpgw',array('edit_attrib' => $data));
-               //      $GLOBALS['phpgw']->xslttpl->pp();
-               }
-
-       }
-?>

Index: templates/base/meter.xsl
===================================================================
RCS file: templates/base/meter.xsl
diff -N templates/base/meter.xsl
--- templates/base/meter.xsl    17 Jan 2005 10:03:18 -0000      1.1
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,258 +0,0 @@
-<!-- $Id: meter.xsl,v 1.1 2005/01/17 10:03:18 sigurdne Exp $ -->
-
-       <xsl:template name="app_data">
-               <xsl:choose>
-                       <xsl:when test="edit">
-                               <xsl:apply-templates select="edit"/>
-                       </xsl:when>
-                       <xsl:when test="view">
-                               <xsl:apply-templates select="view"/>
-                       </xsl:when>
-                       <xsl:when test="update_cat">
-                               <xsl:apply-templates select="update_cat"/>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <xsl:apply-templates select="list"/>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-       
-       <xsl:template match="list">
-               
-               <xsl:call-template name="menu"/> 
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                       <tr>
-                               <td>
-                                       <xsl:call-template name="cat_filter"/>
-                               </td>
-                               <td align="right">  
-                                       <xsl:call-template name="search_field"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="3" width="100%">
-                                       <xsl:call-template name="nextmatchs"/>
-                               </td>
-                       </tr>
-               </table>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                               <xsl:call-template name="table_header"/>
-                               <xsl:choose>
-                                       <xsl:when test="values">
-                                               <xsl:call-template 
name="values"/>
-                                       </xsl:when>
-                               </xsl:choose>
-                               <xsl:choose>
-                                       <xsl:when test="table_add !=''">
-                                               <xsl:apply-templates 
select="table_add"/>
-                                       </xsl:when>
-                               </xsl:choose>   
-               </table>
-       </xsl:template>
-
-
-       <xsl:template match="table_add">
-                       <tr>
-                               <td height="50">
-                                       <xsl:variable 
name="add_action"><xsl:value-of select="add_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_add"><xsl:value-of select="lang_add"/></xsl:variable>
-                                       <form method="post" 
action="{$add_action}">
-                                               <input type="submit" name="add" 
value="{$lang_add}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-<!-- add / edit  -->
-       <xsl:template match="edit">
-               <div align="left">
-               
-               <table cellpadding="2" cellspacing="2" width="80%" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <xsl:variable name="form_action"><xsl:value-of 
select="form_action"/></xsl:variable>
-                       <form method="post" name="form" action="{$form_action}">
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_meter_id"/>
-                               </td>
-                               <td>
-                                       <xsl:choose>
-                                               <xsl:when test="value_meter_id 
!= ''">
-                                                       <xsl:value-of 
select="value_meter_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                                       <input type="text" 
name="values[num]" value="{value_meter_id}" onMouseout="window.status='';return 
true;">
-                                                               <xsl:attribute 
name="onMouseover">
-                                                                       
<xsl:text>window.status='</xsl:text>
-                                                                               
<xsl:value-of select="lang_meter_id_statustext"/>
-                                                                       
<xsl:text>'; return true;</xsl:text>
-                                                               </xsl:attribute>
-                                                       </input>
-                                               </xsl:otherwise>
-                                       </xsl:choose>   
-                               </td>
-                       </tr>
-                       <xsl:call-template name="location_form"/>
-                       <tr>
-                               <td>
-                                       <xsl:value-of select="lang_category"/>
-                               </td>
-                               <td>
-                                       <xsl:call-template name="cat_select"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_name"/>
-                               </td>
-                               <td>
-                                       <input type="text" name="values[name]" 
value="{value_name}" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_name_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_remark"/>
-                               </td>
-                               <td>
-                                       <textarea cols="60" rows="10" 
name="values[remark]" wrap="virtual" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_remark_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                               <xsl:value-of 
select="value_remark"/>           
-                                       </textarea>
-
-                               </td>
-                       </tr>
-                       <tr height="50">
-                               <td>
-                                       <xsl:variable 
name="lang_save"><xsl:value-of select="lang_save"/></xsl:variable>
-                                       <input type="submit" 
name="values[save]" value="{$lang_save}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_save_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       </form>
-                       <tr>
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" 
name="done" value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_done_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-               </div>
-       </xsl:template>
-
-<!-- view -->
-
-       <xsl:template match="view">
-               <div align="left">
-               
-               <table cellpadding="2" cellspacing="2" width="80%" 
align="center">
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_meter_id"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="value_meter_id"/>
-                               </td>
-                       </tr>
-                       <xsl:call-template name="location_view"/>
-                       <tr>
-                               <td>
-                                       <xsl:value-of select="lang_category"/>
-                               </td>
-                               <xsl:for-each select="cat_list" >
-                                       <xsl:choose>
-                                               <xsl:when 
test="selected='selected'">
-                                                       <td>
-                                                               <xsl:value-of 
select="name"/>
-                                                       </td>
-                                               </xsl:when>
-                                       </xsl:choose>
-                               </xsl:for-each>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_name"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="value_name"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_remark"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="value_remark"/>   
        
-                               </td>
-                       </tr>
-                       <tr>
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" 
name="done" value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_done_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td>
-                                       <xsl:variable 
name="edit_action"><xsl:value-of select="edit_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_edit"><xsl:value-of select="lang_edit"/></xsl:variable>
-                                       <form method="post" 
action="{$edit_action}">
-                                               <input type="submit" 
name="edit" value="{$lang_edit}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_edit_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-               </div>
-       </xsl:template>

Index: templates/base/owner.xsl
===================================================================
RCS file: templates/base/owner.xsl
diff -N templates/base/owner.xsl
--- templates/base/owner.xsl    17 Jan 2005 10:03:18 -0000      1.1
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,273 +0,0 @@
-
-       <xsl:template name="app_data">
-               <xsl:choose>
-                       <xsl:when test="edit">
-                               <xsl:apply-templates select="edit"/>
-                       </xsl:when>
-                       <xsl:when test="view">
-                               <xsl:apply-templates select="view"/>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <xsl:apply-templates select="list"/>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-
-       <xsl:template match="list">
-               <xsl:call-template name="menu"/>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <tr>
-                               <td align="left">
-                                       <xsl:call-template name="cat_filter"/>
-                               </td>
-                               <td align="right">
-                                       <xsl:call-template name="search_field"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="3" width="100%">
-                                       <xsl:call-template name="nextmatchs"/>
-                               </td>
-                       </tr>
-               </table>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                               <xsl:apply-templates select="table_header"/>
-                               <xsl:apply-templates select="values"/>
-                               <xsl:apply-templates select="table_add"/>
-               </table>
-       </xsl:template>
-
-       <xsl:template match="table_header">
-               <xsl:variable name="sort_time_created" 
select="sort_time_created"/>
-               <xsl:variable name="sort_owner_id" select="sort_owner_id"/>
-               <xsl:variable name="sort_name" select="sort_name"/>
-               <xsl:variable name="sort_category" select="sort_category"/>
-               
-                       <tr class="th">
-                               <td width="10%" align="right">
-                                       <a href="{$sort_owner_id}" 
class="th_text"><xsl:value-of select="lang_owner_id"/></a>
-                               </td>
-                               <td width="40%">
-                                       <a href="{$sort_name}" 
class="th_text"><xsl:value-of select="lang_name"/></a>
-                               </td>
-                               <td width="20%" align="center">
-                                       <a href="{$sort_time_created}" 
class="th_text"><xsl:value-of select="lang_time_created"/></a>
-                               </td>
-                               <td width="10%" align="center">
-                                       <a href="{$sort_category}" 
class="th_text"><xsl:value-of select="lang_category"/></a>
-                               </td>
-                               <td width="5%" align="center">
-                                       <xsl:value-of select="lang_view"/>
-                               </td>
-                               <td width="5%" align="center">
-                                       <xsl:value-of select="lang_edit"/>
-                               </td>
-                               <td width="5%" align="center">
-                                       <xsl:value-of select="lang_delete"/>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-       <xsl:template match="values">
-               <xsl:variable name="lang_view_statustext"><xsl:value-of 
select="lang_view_statustext"/></xsl:variable>
-               <xsl:variable name="lang_edit_statustext"><xsl:value-of 
select="lang_edit_statustext"/></xsl:variable>
-               <xsl:variable name="lang_delete_statustext"><xsl:value-of 
select="lang_delete_statustext"/></xsl:variable>
-                       <tr>
-                               <xsl:attribute name="class">
-                                       <xsl:choose>
-                                               <xsl:when test="@class">
-                                                       <xsl:value-of 
select="@class"/>
-                                               </xsl:when>
-                                               <xsl:when test="position() mod 
2 = 0">
-                                                       
<xsl:text>row_off</xsl:text>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                                       
<xsl:text>row_on</xsl:text>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </xsl:attribute>
-
-                               <td align="right">
-                                       <xsl:value-of select="owner_id"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="name"/>
-                               </td>
-                               <td align="center">
-                                       <xsl:value-of select="entry_date"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="category"/>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_view"><xsl:value-of select="link_view"/></xsl:variable>
-                                       <a href="{$link_view}" 
onMouseover="window.status='{$lang_view_statustext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_view"/></a>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_edit"><xsl:value-of select="link_edit"/></xsl:variable>
-                                       <a href="{$link_edit}" 
onMouseover="window.status='{$lang_edit_statustext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_edit"/></a>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_delete"><xsl:value-of select="link_delete"/></xsl:variable>
-                                       <a href="{$link_delete}" 
onMouseover="window.status='{$lang_delete_statustext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_delete"/></a>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-       <xsl:template match="table_add">
-                       <tr>
-                               <td height="50">
-                                       <xsl:variable 
name="add_action"><xsl:value-of select="add_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_add"><xsl:value-of select="lang_add"/></xsl:variable>
-                                       <form method="post" 
action="{$add_action}">
-                                               <input type="submit" name="add" 
value="{$lang_add}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-<!-- add / edit -->
-
-       <xsl:template match="edit">
-               <xsl:variable name="edit_url"><xsl:value-of 
select="edit_url"/></xsl:variable>
-               <div align="left">
-               <form name="form" method="post" action="{$edit_url}">
-               <table cellpadding="2" cellspacing="2" width="79%" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <xsl:choose>
-                               <xsl:when test="value_owner_id!=''">
-                                       <tr >
-                                               <td width="25%" align="left">
-                                                       <xsl:value-of 
select="lang_owner_id"/>
-                                               </td>
-                                               <td width="75%" align="left">
-                                                       <xsl:value-of 
select="value_owner_id"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-
-                       <xsl:call-template name="abook_form"/>
-                       <tr >
-                               <td align="left">
-                                       <xsl:value-of select="lang_category"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:call-template name="cat_select"/>
-                               </td>
-                       </tr>
-                       <tr  align="left">
-                               <td valign="top" >
-                                       <xsl:value-of select="lang_remark"/>
-                               </td>
-                               <td align="left">
-
-                                       <textarea cols="60" rows="6" 
name="values[remark]" wrap="virtual" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_remark_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                               <xsl:value-of 
select="value_remark"/>           
-                                       </textarea>
-                               </td>
-                       </tr>
-                       <tr height="50">
-                               <td valign="bottom">
-                                       <xsl:variable 
name="lang_save"><xsl:value-of select="lang_save"/></xsl:variable>
-                                       <input type="submit" 
name="values[save]" value="{$lang_save}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_save_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                               <td valign="bottom">
-                                       <xsl:variable 
name="lang_apply"><xsl:value-of select="lang_apply"/></xsl:variable>
-                                       <input type="submit" 
name="values[apply]" value="{$lang_apply}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_apply_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                               <td align="right" valign="bottom">
-                                       <xsl:variable 
name="lang_cancel"><xsl:value-of select="lang_cancel"/></xsl:variable>
-                                       <input type="submit" 
name="values[cancel]" value="{$lang_cancel}" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_cancel_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-               </table>
-               </form>
-               </div>
-       </xsl:template>
-
-<!-- view -->
-
-       <xsl:template match="view">
-               <table cellpadding="2" cellspacing="2" width="79%" 
align="center">
-                       <tr class="row_off">
-                               <td width="19%">
-                                       <xsl:value-of 
select="lang_time_created"/>
-                               </td>
-                               <td width="81%">
-                                       <xsl:value-of select="value_date"/>
-                               </td>
-                       </tr>
-                       <tr class="row_on">
-                               <td>
-                                       <xsl:value-of select="lang_category"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="value_cat"/>
-                               </td>
-                       </tr>
-                       <tr class="row_off">
-                               <td valign="top">
-                                       <xsl:value-of select="lang_name"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="value_name"/>
-                               </td>
-                       </tr>
-                       <tr height="50">
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                       <input type="submit" class="forms" 
name="done" value="{$lang_done}" onMouseover="window.status='Back to the 
list.';return true;" onMouseout="window.status='';return true;"/>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-       </xsl:template>

Index: templates/base/standard_entity.xsl
===================================================================
RCS file: templates/base/standard_entity.xsl
diff -N templates/base/standard_entity.xsl
--- templates/base/standard_entity.xsl  17 Jan 2005 10:03:18 -0000      1.1
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,612 +0,0 @@
-<!-- $Id: standard_entity.xsl,v 1.1 2005/01/17 10:03:18 sigurdne Exp $ -->
-
-       <xsl:template name="app_data">
-               <xsl:choose>
-                       <xsl:when test="edit">
-                               <xsl:apply-templates select="edit"/>
-                       </xsl:when>
-                       <xsl:when test="list_attribute">
-                               <xsl:apply-templates select="list_attribute"/>
-                       </xsl:when>
-                       <xsl:when test="edit_attrib">
-                               <xsl:apply-templates select="edit_attrib"/>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <xsl:apply-templates select="list"/>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-       
-
-
-       <xsl:template match="list">
-               
-               <xsl:call-template name="menu"/> 
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                       <tr>
-                               <td align="right">
-                                       <xsl:call-template name="search_field"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="3" width="100%">
-                                       <xsl:call-template name="nextmatchs"/>
-                                       <!--    <xsl:with-param 
name="nextmatchs_params"/>
-                                       </xsl:call-template> -->
-                               </td>
-                       </tr>
-               </table>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                               <xsl:apply-templates select="table_header"/>
-                               <xsl:apply-templates select="values"/>
-                               <xsl:apply-templates select="table_add"/>
-               </table>
-       </xsl:template>
-
-       <xsl:template match="table_header">
-               <xsl:variable name="sort_id"><xsl:value-of 
select="sort_id"/></xsl:variable>
-               <xsl:variable name="sort_name"><xsl:value-of 
select="sort_name"/></xsl:variable>
-               <tr class="th">
-                       <td class="th_text" width="10%" align="right">
-                               <a href="{$sort_id}"><xsl:value-of 
select="lang_id"/></a>
-                       </td>
-                       <td class="th_text" width="10%" align="center">
-                               <a href="{$sort_name}"><xsl:value-of 
select="lang_name"/></a>
-                       </td>
-                       <td class="th_text" width="20%" align="center">
-                               <xsl:value-of select="lang_descr"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_prefix"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_attribute"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_edit"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_delete"/>
-                       </td>
-               </tr>
-       </xsl:template>
-
-       <xsl:template match="values"> 
-               <xsl:variable name="lang_attribute_standardtext"><xsl:value-of 
select="lang_delete_standardtext"/></xsl:variable>
-               <xsl:variable name="lang_edit_standardtext"><xsl:value-of 
select="lang_edit_standardtext"/></xsl:variable>
-               <xsl:variable name="lang_delete_standardtext"><xsl:value-of 
select="lang_delete_standardtext"/></xsl:variable>
-                       <tr>
-                               <xsl:attribute name="class">
-                                       <xsl:choose>
-                                               <xsl:when test="@class">
-                                                       <xsl:value-of 
select="@class"/>
-                                               </xsl:when>
-                                               <xsl:when test="position() mod 
2 = 0">
-                                                       
<xsl:text>row_off</xsl:text>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                                       
<xsl:text>row_on</xsl:text>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </xsl:attribute>
-
-                               <td align="right">
-                                       <xsl:value-of select="id"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="name"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="first"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="prefix"/>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_attribute"><xsl:value-of select="link_attribute"/></xsl:variable>
-                                       <a href="{$link_attribute}" 
onMouseover="window.status='{$lang_attribute_standardtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_attribute"/></a>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_edit"><xsl:value-of select="link_edit"/></xsl:variable>
-                                       <a href="{$link_edit}" 
onMouseover="window.status='{$lang_edit_standardtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_edit"/></a>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_delete"><xsl:value-of select="link_delete"/></xsl:variable>
-                                       <a href="{$link_delete}" 
onMouseover="window.status='{$lang_delete_standardtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_delete"/></a>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-       <xsl:template match="table_add">
-                       <tr>
-                               <td height="50">
-                                       <xsl:variable 
name="add_action"><xsl:value-of select="add_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_add"><xsl:value-of select="lang_add"/></xsl:variable>
-                                       <form method="post" 
action="{$add_action}">
-                                               <input type="submit" name="add" 
value="{$lang_add}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_standardtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                               <td height="50">
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" name="add" 
value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_standardtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-<!-- add / edit  -->
-       <xsl:template match="edit">
-               <div align="left">
-               
-               <table cellpadding="2" cellspacing="2" width="80%" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <xsl:variable name="form_action"><xsl:value-of 
select="form_action"/></xsl:variable>
-                       <form method="post" action="{$form_action}">
-                       <tr>
-                               <td valign="top">
-                                       <xsl:choose>
-                                               <xsl:when test="value_id != ''">
-                                                       <xsl:value-of 
select="lang_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </td>
-                               <td>
-                                       <xsl:choose>
-                                               <xsl:when test="value_id != ''">
-                                                       <xsl:value-of 
select="value_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                               </xsl:otherwise>
-                                       </xsl:choose>   
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_name"/>
-                               </td>
-                               <td>
-                                       <input type="text" name="values[name]" 
value="{value_name}" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_name_standardtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_descr"/>
-                               </td>
-                               <td>
-                                       <textarea cols="60" rows="10" 
name="values[descr]" wrap="virtual" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_descr_standardtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                               <xsl:value-of 
select="value_descr"/>            
-                                       </textarea>
-
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_prefix"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[prefix]" value="{value_prefix}" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_prefix_standardtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr height="50">
-                               <td>
-                                       <xsl:variable 
name="lang_save"><xsl:value-of select="lang_save"/></xsl:variable>
-                                       <input type="submit" 
name="values[save]" value="{$lang_save}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_save_standardtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       </form>
-                       <tr>
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" 
name="done" value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_done_standardtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-               </div>
-       </xsl:template>
-
-
-
-<!-- list attribute -->
-
-       <xsl:template match="list_attribute">
-               
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                       <tr>
-                               <td align="right">
-                                       <xsl:call-template name="search_field"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="3" width="100%">
-                                       <xsl:call-template name="nextmatchs"/>
-                               </td>
-                       </tr>
-               </table>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                               <xsl:apply-templates 
select="table_header_attrib"/>
-                               <xsl:apply-templates select="values_attrib"/>
-                               <xsl:apply-templates select="table_add"/>
-               </table>
-       </xsl:template>
-       <xsl:template match="table_header_attrib">
-               <xsl:variable name="sort_id"><xsl:value-of 
select="sort_id"/></xsl:variable>
-               <xsl:variable name="sort_name"><xsl:value-of 
select="sort_name"/></xsl:variable>
-               <tr class="th">
-                       <td class="th_text" width="10%" align="right">
-                               <xsl:value-of select="lang_type_name"/>
-                       </td>
-                       <td class="th_text" width="10%" align="right">
-                               <a href="{$sort_name}"><xsl:value-of 
select="lang_name"/></a>
-                       </td>
-                       <td class="th_text" width="20%" align="center">
-                               <xsl:value-of select="lang_descr"/>
-                       </td>
-                       <td class="th_text" width="1%" align="center">
-                               <xsl:value-of select="lang_datatype"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_edit"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_delete"/>
-                       </td>
-               </tr>
-       </xsl:template>
-
-       <xsl:template match="values_attrib"> 
-               <xsl:variable name="lang_attribute_attribtext"><xsl:value-of 
select="lang_delete_attribtext"/></xsl:variable>
-               <xsl:variable name="lang_edit_attribtext"><xsl:value-of 
select="lang_edit_attribtext"/></xsl:variable>
-               <xsl:variable name="lang_delete_attribtext"><xsl:value-of 
select="lang_delete_attribtext"/></xsl:variable>
-                       <tr>
-                               <xsl:attribute name="class">
-                                       <xsl:choose>
-                                               <xsl:when test="@class">
-                                                       <xsl:value-of 
select="@class"/>
-                                               </xsl:when>
-                                               <xsl:when test="position() mod 
2 = 0">
-                                                       
<xsl:text>row_off</xsl:text>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                                       
<xsl:text>row_on</xsl:text>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </xsl:attribute>
-
-                               <td align="right">
-                                       <xsl:value-of select="type_name"/>
-                               </td>
-                               <td align="right">
-                                       <xsl:value-of select="name"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="first"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="datatype"/>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_edit"><xsl:value-of select="link_edit"/></xsl:variable>
-                                       <a href="{$link_edit}" 
onMouseover="window.status='{$lang_edit_attribtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_edit"/></a>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_delete"><xsl:value-of select="link_delete"/></xsl:variable>
-                                       <a href="{$link_delete}" 
onMouseover="window.status='{$lang_delete_attribtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_delete"/></a>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-       <xsl:template name="choice">
-                       <table cellpadding="2" cellspacing="2" width="80%" 
align="left">
-                       <xsl:choose>
-                               <xsl:when test="value_choice!=''">
-                                       <tr class="th">
-                                               <td class="th_text" width="85%" 
align="left">
-                                                       <xsl:value-of 
select="lang_value"/>
-                                               </td>
-                                               <td class="th_text" width="15%" 
align="center">
-                                                       <xsl:value-of 
select="lang_delete_value"/>
-                                               </td>
-                                       </tr>
-                               <xsl:for-each select="value_choice" >
-                                       <tr>
-                                               <xsl:attribute name="class">
-                                                       <xsl:choose>
-                                                               <xsl:when 
test="@class">
-                                                                       
<xsl:value-of select="@class"/>
-                                                               </xsl:when>
-                                                               <xsl:when 
test="position() mod 2 = 0">
-                                                                       
<xsl:text>row_off</xsl:text>
-                                                               </xsl:when>
-                                                               <xsl:otherwise>
-                                                                       
<xsl:text>row_on</xsl:text>
-                                                               </xsl:otherwise>
-                                                       </xsl:choose>
-                                               </xsl:attribute>
-                                       <td align="left">
-                                               <xsl:value-of select="value"/>
-                                               <xsl:text> </xsl:text>
-                                       </td>
-                                       <td align="center">
-                                               <input type="checkbox" 
name="values[delete_choice][]" value="{id}"  
onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="//lang_delete_choice_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </td>
-                                       </tr>
-                               </xsl:for-each>
-                               </xsl:when>
-                       </xsl:choose>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_new_value"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[new_choice]" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_new_value_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                               
-                               </table>
-
-       </xsl:template>
-
-
-<!-- add attribute / edit attribute -->
-
-       <xsl:template match="edit_attrib">
-               <div align="left">
-               
-               <table cellpadding="2" cellspacing="2" width="80%" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       
-                       <xsl:variable name="form_action"><xsl:value-of 
select="form_action"/></xsl:variable>
-                       <form method="post" action="{$form_action}">
-                       <tr>
-                               <td valign="top">
-                                       <xsl:choose>
-                                               <xsl:when test="value_id != ''">
-                                                       <xsl:value-of 
select="lang_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </td>
-                               <td>
-                                       <xsl:choose>
-                                               <xsl:when test="value_id != ''">
-                                                       <xsl:value-of 
select="value_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                               </xsl:otherwise>
-                                       </xsl:choose>   
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_name"/>
-                               </td>
-                               <td>
-                                       <input type="text" name="values[name]" 
value="{value_name}" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_name_attribtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_descr"/>
-                               </td>
-                               <td>
-                                       <textarea cols="60" rows="10" 
name="values[descr]" wrap="virtual" onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_descr_attribtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                               <xsl:value-of 
select="value_descr"/>            
-                                       </textarea>
-
-                               </td>
-                       </tr>
-
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of 
select="lang_entity_type"/>
-                               </td>
-                               <td valign="top">
-
-                               <!--    <input type="hidden" 
name="values[entity_type_orig]" value="{type_id}"></input> -->
-                                       <xsl:variable 
name="lang_entity_statustext"><xsl:value-of 
select="lang_entity_statustext"/></xsl:variable>
-                                       <xsl:variable 
name="select_entity_type"><xsl:value-of 
select="select_entity_type"/></xsl:variable>
-                                       <select name="{$select_entity_type}" 
class="forms" onMouseover="window.status='{$lang_entity_statustext}'; return 
true;" onMouseout="window.status='';return true;">
-                                               <option value=""><xsl:value-of 
select="lang_no_entity_type"/></option>
-                                               <xsl:apply-templates 
select="entity_list"/>
-                                       </select>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_datatype"/>
-                               </td>
-                               <td valign="top">
-                                       <xsl:variable 
name="lang_datatype_statustext"><xsl:value-of 
select="lang_datatype_statustext"/></xsl:variable>
-                                       <xsl:variable 
name="select_datatype"><xsl:value-of select="select_datatype"/></xsl:variable>
-                                       <select name="{$select_datatype}" 
class="forms" onMouseover="window.status='{$lang_datatype_statustext}'; return 
true;" onMouseout="window.status='';return true;">
-                                               <option value=""><xsl:value-of 
select="lang_no_datatype"/></option>
-                                               <xsl:apply-templates 
select="datatype_list"/>
-                                       </select>
-                               </td>
-                       </tr>
-                       <xsl:choose>
-                               <xsl:when test="multiple_choice != ''">
-                                       <tr>
-                                               <td valign="top">
-                                                       <xsl:value-of 
select="lang_choice"/>
-                                               </td>
-                                               <td align="right">
-                                                       <xsl:call-template 
name="choice"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-<!--                   <tr>
-                               <td>
-                                       <xsl:value-of select="lang_list"/>
-                               </td>
-                               <td>
-                                       <xsl:choose>
-                                                       <xsl:when 
test="value_list = 1">
-                                                               <input 
type="checkbox" name="values[list]" value="1" checked="checked" 
onMouseout="window.status='';return true;">
-                                                                       
<xsl:attribute name="onMouseover">
-                                                                               
<xsl:text>window.status='</xsl:text>
-                                                                               
        <xsl:value-of select="lang_list_statustext"/>
-                                                                               
<xsl:text>'; return true;</xsl:text>
-                                                                       
</xsl:attribute>
-                                                               </input>
-                                                       </xsl:when>
-                                                       <xsl:otherwise>
-                                                               <input 
type="checkbox" name="values[list]" value="1" 
onMouseout="window.status='';return true;">
-                                                                       
<xsl:attribute name="onMouseover">
-                                                                               
<xsl:text>window.status='</xsl:text>
-                                                                               
        <xsl:value-of select="lang_list_statustext"/>
-                                                                               
<xsl:text>'; return true;</xsl:text>
-                                                                       
</xsl:attribute>
-                                                               </input>
-                                                       </xsl:otherwise>
-                                       </xsl:choose>
-                               </td>
-                       </tr>   -->
-                       <tr height="50">
-                               <td>
-                                       <xsl:variable 
name="lang_save"><xsl:value-of select="lang_save"/></xsl:variable>
-                                       <input type="submit" 
name="values[save]" value="{$lang_save}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_save_attribtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       </form>
-                       <tr>
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" 
name="done" value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_done_attribtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-               </div>
-       </xsl:template>
-
-<!-- entity_list -->   
-
-       <xsl:template match="entity_list">
-       <xsl:variable name="id"><xsl:value-of select="id"/></xsl:variable>
-               <xsl:choose>
-                       <xsl:when test="selected">
-                               <option value="{$id}" 
selected="selected"><xsl:value-of disable-output-escaping="yes" 
select="name"/></option>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <option value="{$id}"><xsl:value-of 
disable-output-escaping="yes" select="name"/></option>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-
-<!-- datatype_list --> 
-
-       <xsl:template match="datatype_list">
-       <xsl:variable name="id"><xsl:value-of select="id"/></xsl:variable>
-               <xsl:choose>
-                       <xsl:when test="selected">
-                               <option value="{$id}" 
selected="selected"><xsl:value-of disable-output-escaping="yes" 
select="name"/></option>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <option value="{$id}"><xsl:value-of 
disable-output-escaping="yes" select="name"/></option>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>

Index: templates/base/tenant.xsl
===================================================================
RCS file: templates/base/tenant.xsl
diff -N templates/base/tenant.xsl
--- templates/base/tenant.xsl   22 Dec 2006 15:02:12 -0000      1.4
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,715 +0,0 @@
-
-       <xsl:template name="app_data">
-               <xsl:choose>
-                       <xsl:when test="edit">
-                               <xsl:apply-templates select="edit"/>
-                       </xsl:when>
-                       <xsl:when test="view">
-                               <xsl:apply-templates select="view"/>
-                       </xsl:when>
-                       <xsl:when test="list_attribute">
-                               <xsl:apply-templates select="list_attribute"/>
-                       </xsl:when>
-                       <xsl:when test="edit_attrib">
-                               <xsl:apply-templates select="edit_attrib"/>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <xsl:apply-templates select="list"/>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-
-       <xsl:template match="list">
-               <xsl:variable name="overlib_source"><xsl:value-of 
select="overlib_source"/></xsl:variable>
-               <SCRIPT LANGUAGE="JavaScript" SRC="{$overlib_source}"></SCRIPT>
-
-               <xsl:call-template name="menu"/>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <tr>
-                               <td align="left">
-                                       <xsl:call-template name="cat_filter"/>
-                               </td>
-                               <td align="right">
-                                       <xsl:call-template name="search_field"/>
-                               </td>
-                               <td valign ="top">
-                               <table>
-                               <tr>
-                               <td class="small_text" valign="top" 
align="left">
-                                       <xsl:variable 
name="link_columns"><xsl:value-of select="link_columns"/></xsl:variable>
-                                       <xsl:variable 
name="lang_columns_help"><xsl:value-of 
select="lang_columns_help"/></xsl:variable>
-                                       <xsl:variable 
name="lang_columns"><xsl:value-of select="lang_columns"/></xsl:variable>
-                                       <a href="javascript:var 
w=window.open('{$link_columns}','','width=300,height=600')"
-                                               
onMouseOver="overlib('{$lang_columns_help}', CAPTION, '{$lang_columns}')"
-                                               onMouseOut="nd()">
-                                               <xsl:value-of 
select="lang_columns"/></a>
-                               </td>
-                               </tr>
-                               </table>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="3" width="100%">
-                                       <xsl:call-template name="nextmatchs"/>
-                               </td>
-                       </tr>
-               </table>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                               <xsl:call-template name="table_header"/>
-                               <xsl:call-template name="values"/>
-                               <xsl:apply-templates select="table_add"/>
-               </table>
-       </xsl:template>
-
-       <xsl:template name="table_header">
-                       <tr class="th">
-                               <xsl:for-each select="table_header" >
-                                       <td class="th_text" width="{with}" 
align="{align}">
-                                               <xsl:choose>
-                                                       <xsl:when 
test="sort_link!=''">
-                                                               <a 
href="{sort}" onMouseover="window.status='{header}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of select="header"/></a>
-                                                       </xsl:when>
-                                                       <xsl:otherwise>
-                                                               <xsl:value-of 
select="header"/>                                 
-                                                       </xsl:otherwise>
-                                               </xsl:choose>
-                                       </td>
-                               </xsl:for-each>
-                       </tr>
-       </xsl:template>
-
-
-       <xsl:template name="values">
-               <xsl:for-each select="values" >
-                       <tr>
-                       <xsl:attribute name="class">
-                               <xsl:choose>
-                                       <xsl:when test="@class">
-                                               <xsl:value-of select="@class"/>
-                                       </xsl:when>
-                                       <xsl:when test="position() mod 2 = 0">
-                                               <xsl:text>row_off</xsl:text>
-                                       </xsl:when>
-                                       <xsl:otherwise>
-                                               <xsl:text>row_on</xsl:text>
-                                       </xsl:otherwise>
-                               </xsl:choose>
-                       </xsl:attribute>
-                               <xsl:for-each select="row" >
-                                       <xsl:choose>
-                                               <xsl:when test="link">
-                                                       <td class="small_text" 
align="center">
-                                                               <a 
href="{link}" onMouseover="window.status='{statustext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of select="text"/></a>
-                                                       </td>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                                       <td class="small_text" 
align="left">
-                                                               <xsl:value-of 
select="value"/>                          
-                                                       </td>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </xsl:for-each>
-                       </tr>
-               </xsl:for-each>
-       </xsl:template>
-
-       <xsl:template match="table_add">
-                       <tr>
-                               <td height="50">
-                                       <xsl:variable 
name="add_action"><xsl:value-of select="add_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_add"><xsl:value-of select="lang_add"/></xsl:variable>
-                                       <form method="post" 
action="{$add_action}">
-                                               <input type="submit" name="add" 
value="{$lang_add}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_statustext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-<!-- add / edit -->
-
-       <xsl:template match="edit">
-               <script language="JavaScript">
-                       self.name="first_Window";
-                       <xsl:value-of select="lookup_functions"/>
-               </script>
-               <xsl:variable name="edit_url"><xsl:value-of 
select="edit_url"/></xsl:variable>
-               <div align="left">
-               <form name="form" method="post" action="{$edit_url}">
-               <table cellpadding="2" cellspacing="2" width="79%" 
align="center">
-                       <xsl:choose>
-                               <xsl:when test="msgbox_data != ''">
-                                       <tr>
-                                               <td align="left" colspan="3">
-                                                       <xsl:call-template 
name="msgbox"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <xsl:choose>
-                               <xsl:when test="value_tenant_id!=''">
-                                       <tr >
-                                               <td align="left">
-                                                       <xsl:value-of 
select="lang_tenant_id"/>
-                                               </td>
-                                               <td align="left">
-                                                       <xsl:value-of 
select="value_tenant_id"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-
-                       <tr >
-                               <td align="left">
-                                       <xsl:value-of select="lang_category"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:call-template name="cat_select"/>
-                               </td>
-                       </tr>
-                       <tr  align="left">
-                               <td valign="top">
-                                       <xsl:value-of select="lang_first_name"/>
-                               </td>
-                               <td align="left">
-                                       <input type="text" 
name="values[first_name]" value="{value_first_name}"  
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_first_name_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr  align="left">
-                               <td valign="top">
-                                       <xsl:value-of select="lang_last_name"/>
-                               </td>
-                               <td align="left">
-                                       <input type="text" 
name="values[last_name]" value="{value_last_name}"  
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_last_name_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr  align="left">
-                               <td valign="top">
-                                       <xsl:value-of 
select="lang_contact_phone"/>
-                               </td>
-                               <td align="left">
-                                       <input type="text" 
name="values[contact_phone]" value="{value_contact_phone}"  
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_contact_phone_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="2" width="50%" align="left">       
                        
-                                       <xsl:call-template 
name="attributes_form"/>
-                               </td>
-                       </tr>
-                       <tr height="50">
-                               <td valign="bottom">
-                                       <xsl:variable 
name="lang_save"><xsl:value-of select="lang_save"/></xsl:variable>
-                                       <input type="submit" 
name="values[save]" value="{$lang_save}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_save_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                               <td valign="bottom">
-                                       <xsl:variable 
name="lang_apply"><xsl:value-of select="lang_apply"/></xsl:variable>
-                                       <input type="submit" 
name="values[apply]" value="{$lang_apply}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_apply_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                               <td align="right" valign="bottom">
-                                       <xsl:variable 
name="lang_cancel"><xsl:value-of select="lang_cancel"/></xsl:variable>
-                                       <input type="submit" 
name="values[cancel]" value="{$lang_cancel}" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_cancel_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-               </table>
-               </form>
-               </div>
-       </xsl:template>
-
-<!-- view -->
-
-       <xsl:template match="view">
-               <table cellpadding="2" cellspacing="2" width="79%" 
align="center">
-                       <tr class="row_off">
-                               <td width="19%">
-                                       <xsl:value-of 
select="lang_time_created"/>
-                               </td>
-                               <td width="81%">
-                                       <xsl:value-of select="value_date"/>
-                               </td>
-                       </tr>
-                       <tr class="row_on">
-                               <td>
-                                       <xsl:value-of select="lang_category"/>
-                               </td>
-                               <xsl:for-each select="cat_list" >
-                                       <xsl:choose>
-                                               <xsl:when 
test="selected='selected'">
-                                                       <td>
-                                                               <xsl:value-of 
select="name"/>
-                                                       </td>
-                                               </xsl:when>
-                                       </xsl:choose>
-                               </xsl:for-each>
-                       </tr>
-                       <tr class="row_off">
-                               <td valign="top">
-                                       <xsl:value-of select="lang_first_name"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of 
select="value_first_name"/>
-                               </td>
-                       </tr>
-                       <tr class="row_off">
-                               <td valign="top">
-                                       <xsl:value-of select="lang_last_name"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of select="value_last_name"/>
-                               </td>
-                       </tr>
-                       <tr class="row_off">
-                               <td valign="top">
-                                       <xsl:value-of 
select="lang_contact_phone"/>
-                               </td>
-                               <td>
-                                       <xsl:value-of 
select="value_contact_phone"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="2" width="50%" align="left">
-                                       <xsl:apply-templates 
select="attributes_view"/>
-                               </td>
-                       </tr>
-                       <tr height="50">
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                       <input type="submit" class="forms" 
name="done" value="{$lang_done}" onMouseover="window.status='Back to the 
list.';return true;" onMouseout="window.status='';return true;"/>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-       </xsl:template>
-
-       <xsl:template match="table_add2">
-                       <tr>
-                               <td height="50">
-                                       <xsl:variable 
name="add_action"><xsl:value-of select="add_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_add"><xsl:value-of select="lang_add"/></xsl:variable>
-                                       <form method="post" 
action="{$add_action}">
-                                               <input type="submit" name="add" 
value="{$lang_add}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_standardtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                               <td height="50">
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" name="add" 
value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_add_standardtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-
-
-<!-- list attribute -->
-
-       <xsl:template match="list_attribute">
-               
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                       <tr>
-                               <td align="right">
-                                       <xsl:call-template name="search_field"/>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td colspan="3" width="100%">
-                                       <xsl:call-template name="nextmatchs"/>
-                               </td>
-                       </tr>
-               </table>
-               <table width="100%" cellpadding="2" cellspacing="2" 
align="center">
-                               <xsl:apply-templates 
select="table_header_attrib"/>
-                               <xsl:apply-templates select="values_attrib"/>
-                               <xsl:apply-templates select="table_add2"/>
-               </table>
-       </xsl:template>
-       <xsl:template match="table_header_attrib">
-               <xsl:variable name="sort_sorting"><xsl:value-of 
select="sort_sorting"/></xsl:variable>
-               <xsl:variable name="sort_id"><xsl:value-of 
select="sort_id"/></xsl:variable>
-               <xsl:variable name="sort_name"><xsl:value-of 
select="sort_name"/></xsl:variable>
-               <tr class="th">
-                       <td class="th_text" width="10%" align="left">
-                               <a href="{$sort_name}"><xsl:value-of 
select="lang_name"/></a>
-                       </td>
-                       <td class="th_text" width="10%" align="left">
-                               <xsl:value-of select="lang_descr"/>
-                       </td>
-                       <td class="th_text" width="1%" align="center">
-                               <xsl:value-of select="lang_datatype"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <a href="{$sort_sorting}"><xsl:value-of 
select="lang_sorting"/></a>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_edit"/>
-                       </td>
-                       <td class="th_text" width="5%" align="center">
-                               <xsl:value-of select="lang_delete"/>
-                       </td>
-               </tr>
-       </xsl:template>
-
-       <xsl:template match="values_attrib"> 
-               <xsl:variable name="lang_up_text"><xsl:value-of 
select="lang_up_text"/></xsl:variable>
-               <xsl:variable name="lang_down_text"><xsl:value-of 
select="lang_down_text"/></xsl:variable>
-               <xsl:variable name="lang_attribute_attribtext"><xsl:value-of 
select="lang_delete_attribtext"/></xsl:variable>
-               <xsl:variable name="lang_edit_attribtext"><xsl:value-of 
select="lang_edit_attribtext"/></xsl:variable>
-               <xsl:variable name="lang_delete_attribtext"><xsl:value-of 
select="lang_delete_attribtext"/></xsl:variable>
-                       <tr>
-                               <xsl:attribute name="class">
-                                       <xsl:choose>
-                                               <xsl:when test="@class">
-                                                       <xsl:value-of 
select="@class"/>
-                                               </xsl:when>
-                                               <xsl:when test="position() mod 
2 = 0">
-                                                       
<xsl:text>row_off</xsl:text>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                                       
<xsl:text>row_on</xsl:text>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </xsl:attribute>
-
-                               <td align="left">
-                                       <xsl:value-of select="column_name"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="input_text"/>
-                               </td>
-                               <td align="left">
-                                       <xsl:value-of select="datatype"/>
-                               </td>
-                               <td>
-                                       <table align="left">
-                                               <tr>
-                                                       <td>
-                                                               <xsl:value-of 
select="sorting"/>
-                                                       </td>
-
-                                                       <td align="left">
-                                                               <xsl:variable 
name="link_up"><xsl:value-of select="link_up"/></xsl:variable>
-                                                               <a 
href="{$link_up}" onMouseover="window.status='{$lang_up_text}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of select="text_up"/></a>
-                                                               <xsl:text> | 
</xsl:text>
-                                                               <xsl:variable 
name="link_down"><xsl:value-of select="link_down"/></xsl:variable>
-                                                               <a 
href="{$link_down}" onMouseover="window.status='{$lang_down_text}';return 
true;" onMouseout="window.status='';return true;"><xsl:value-of 
select="text_down"/></a>
-                                                       </td>
-
-                                               </tr>
-                                       </table>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_edit"><xsl:value-of select="link_edit"/></xsl:variable>
-                                       <a href="{$link_edit}" 
onMouseover="window.status='{$lang_edit_attribtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_edit"/></a>
-                               </td>
-                               <td align="center">
-                                       <xsl:variable 
name="link_delete"><xsl:value-of select="link_delete"/></xsl:variable>
-                                       <a href="{$link_delete}" 
onMouseover="window.status='{$lang_delete_attribtext}';return true;" 
onMouseout="window.status='';return true;"><xsl:value-of 
select="text_delete"/></a>
-                               </td>
-                       </tr>
-       </xsl:template>
-
-
-<!-- add attribute / edit attribute -->
-
-       <xsl:template match="edit_attrib">
-               <div align="left">
-               
-               <table cellpadding="2" cellspacing="2" width="80%" 
align="center">
-                       
-                       <xsl:variable name="form_action"><xsl:value-of 
select="form_action"/></xsl:variable>
-                       <form method="post" action="{$form_action}">
-                       <tr>
-                               <td valign="top">
-                                       <xsl:choose>
-                                               <xsl:when test="value_id != ''">
-                                                       <xsl:value-of 
select="lang_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                               </xsl:otherwise>
-                                       </xsl:choose>
-                               </td>
-                               <td>
-                                       <xsl:choose>
-                                               <xsl:when test="value_id != ''">
-                                                       <xsl:value-of 
select="value_id"/>
-                                               </xsl:when>
-                                               <xsl:otherwise>
-                                               </xsl:otherwise>
-                                       </xsl:choose>   
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of 
select="lang_column_name"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[column_name]" value="{value_column_name}" maxlength="20" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_column_name_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_input_text"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[input_text]" value="{value_input_text}" size ="60" maxlength="50" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_input_text_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_statustext"/>
-                               </td>
-                               <td>
-                                       <textarea cols="60" rows="10" 
name="values[statustext]" wrap="virtual" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_statustext_attribtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                               <xsl:value-of 
select="value_statustext"/>               
-                                       </textarea>
-
-                               </td>
-                       </tr>
-
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_datatype"/>
-                               </td>
-                               <td valign="top">
-                                       <xsl:variable 
name="lang_datatype_statustext"><xsl:value-of 
select="lang_datatype_statustext"/></xsl:variable>
-                                       <select 
name="values[column_info][type]" class="forms" 
onMouseover="window.status='{$lang_datatype_statustext}'; return true;" 
onMouseout="window.status='';return true;">
-                                               <option value=""><xsl:value-of 
select="lang_no_datatype"/></option>
-                                               <xsl:apply-templates 
select="datatype_list"/>
-                                       </select>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_precision"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[column_info][precision]" value="{value_precision}" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_precision_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_scale"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[column_info][scale]" value="{value_scale}" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_scale_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_default"/>
-                               </td>
-                               <td>
-                                       <input type="text" 
name="values[column_info][default]" value="{value_default}" 
onMouseout="window.status='';return true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_default_statustext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td valign="top">
-                                       <xsl:value-of select="lang_nullable"/>
-                               </td>
-                               <td valign="top">
-                                       <xsl:variable 
name="lang_nullable_statustext"><xsl:value-of 
select="lang_nullable_statustext"/></xsl:variable>
-                                       <select 
name="values[column_info][nullable]" class="forms" 
onMouseover="window.status='{$lang_nullable_statustext}'; return true;" 
onMouseout="window.status='';return true;">
-                                               <option value=""><xsl:value-of 
select="lang_select_nullable"/></option>
-                                               <xsl:apply-templates 
select="nullable_list"/>
-                                       </select>
-                               </td>
-                       </tr>
-                       <tr>
-                               <td>
-                                       <xsl:value-of select="lang_list"/>
-                               </td>
-                               <td>
-                                       <xsl:choose>
-                                                       <xsl:when 
test="value_list = 1">
-                                                               <input 
type="checkbox" name="values[list]" value="1" checked="checked" 
onMouseout="window.status='';return true;">
-                                                                       
<xsl:attribute name="onMouseover">
-                                                                               
<xsl:text>window.status='</xsl:text>
-                                                                               
        <xsl:value-of select="lang_list_statustext"/>
-                                                                               
<xsl:text>'; return true;</xsl:text>
-                                                                       
</xsl:attribute>
-                                                               </input>
-                                                       </xsl:when>
-                                                       <xsl:otherwise>
-                                                               <input 
type="checkbox" name="values[list]" value="1" 
onMouseout="window.status='';return true;">
-                                                                       
<xsl:attribute name="onMouseover">
-                                                                               
<xsl:text>window.status='</xsl:text>
-                                                                               
        <xsl:value-of select="lang_list_statustext"/>
-                                                                               
<xsl:text>'; return true;</xsl:text>
-                                                                       
</xsl:attribute>
-                                                               </input>
-                                                       </xsl:otherwise>
-                                       </xsl:choose>
-                               </td>
-                       </tr>
-                       <xsl:choose>
-                               <xsl:when test="multiple_choice != ''">
-                                       <tr>
-                                               <td valign="top">
-                                                       <xsl:value-of 
select="lang_choice"/>
-                                               </td>
-                                               <td align="right">
-                                                       <xsl:call-template 
name="choice"/>
-                                               </td>
-                                       </tr>
-                               </xsl:when>
-                       </xsl:choose>
-                       <tr height="50">
-                               <td>
-                                       <xsl:variable 
name="lang_save"><xsl:value-of select="lang_save"/></xsl:variable>
-                                       <input type="submit" 
name="values[save]" value="{$lang_save}" onMouseout="window.status='';return 
true;">
-                                               <xsl:attribute 
name="onMouseover">
-                                                       
<xsl:text>window.status='</xsl:text>
-                                                               <xsl:value-of 
select="lang_save_attribtext"/>
-                                                       <xsl:text>'; return 
true;</xsl:text>
-                                               </xsl:attribute>
-                                       </input>
-                               </td>
-                       </tr>
-
-                       </form>
-                       <tr>
-                               <td>
-                                       <xsl:variable 
name="done_action"><xsl:value-of select="done_action"/></xsl:variable>
-                                       <xsl:variable 
name="lang_done"><xsl:value-of select="lang_done"/></xsl:variable>
-                                       <form method="post" 
action="{$done_action}">
-                                               <input type="submit" 
name="done" value="{$lang_done}" onMouseout="window.status='';return true;">
-                                                       <xsl:attribute 
name="onMouseover">
-                                                               
<xsl:text>window.status='</xsl:text>
-                                                                       
<xsl:value-of select="lang_done_attribtext"/>
-                                                               <xsl:text>'; 
return true;</xsl:text>
-                                                       </xsl:attribute>
-                                               </input>
-                                       </form>
-                               </td>
-                       </tr>
-               </table>
-               </div>
-       </xsl:template>
-
-<!-- datatype_list --> 
-
-       <xsl:template match="datatype_list">
-       <xsl:variable name="id"><xsl:value-of select="id"/></xsl:variable>
-               <xsl:choose>
-                       <xsl:when test="selected">
-                               <option value="{$id}" 
selected="selected"><xsl:value-of disable-output-escaping="yes" 
select="name"/></option>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <option value="{$id}"><xsl:value-of 
disable-output-escaping="yes" select="name"/></option>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-
-<!-- nullable_list --> 
-
-       <xsl:template match="nullable_list">
-       <xsl:variable name="id"><xsl:value-of select="id"/></xsl:variable>
-               <xsl:choose>
-                       <xsl:when test="selected">
-                               <option value="{$id}" 
selected="selected"><xsl:value-of disable-output-escaping="yes" 
select="name"/></option>
-                       </xsl:when>
-                       <xsl:otherwise>
-                               <option value="{$id}"><xsl:value-of 
disable-output-escaping="yes" select="name"/></option>
-                       </xsl:otherwise>
-               </xsl:choose>
-       </xsl:template>
-




reply via email to

[Prev in Thread] Current Thread [Next in Thread]