[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [10255] controller: generalize
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [10255] controller: generalize |
Date: |
Wed, 17 Oct 2012 14:03:30 +0000 |
Revision: 10255
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=10255
Author: sigurdne
Date: 2012-10-17 14:03:30 +0000 (Wed, 17 Oct 2012)
Log Message:
-----------
controller: generalize
Modified Paths:
--------------
trunk/property/inc/class.bolocation.inc.php
trunk/property/inc/class.menu.inc.php
trunk/property/inc/class.solocation.inc.php
Modified: trunk/property/inc/class.bolocation.inc.php
===================================================================
--- trunk/property/inc/class.bolocation.inc.php 2012-10-17 13:57:33 UTC (rev
10254)
+++ trunk/property/inc/class.bolocation.inc.php 2012-10-17 14:03:30 UTC (rev
10255)
@@ -689,7 +689,8 @@
'district_id'=>$this->district_id,'allrows'=>$allrows,
'status'=>$this->status,'part_of_town_id'=>$this->part_of_town_id,'dry_run'=>$data['dry_run'],
'location_code' => $this->location_code,
'filter_role_on_contact' => $data['filter_role_on_contact'], 'role_id' =>
$data['role_id'],
- 'results' => $data['results']));
+ 'results' =>
$data['results'],'control_registered' => $data['control_registered'],
+ 'control_id' => $data['control_id']));
$this->total_records = $this->so->total_records;
$this->uicols = $this->so->uicols;
Modified: trunk/property/inc/class.menu.inc.php
===================================================================
--- trunk/property/inc/class.menu.inc.php 2012-10-17 13:57:33 UTC (rev
10254)
+++ trunk/property/inc/class.menu.inc.php 2012-10-17 14:03:30 UTC (rev
10255)
@@ -373,6 +373,11 @@
'text' =>
lang('Configuration'),
'url' =>
$GLOBALS['phpgw']->link('/index.php', array('menuaction' =>
'admin.uiconfig.index', 'appname' => 'property') )
),
+ 'import' => array
+ (
+ 'text' =>
lang('Generic import'),
+ 'url' =>
$GLOBALS['phpgw']->link('/index.php', array('menuaction' =>
'property.uiimport.index') )
+ ),
'entity' => array
(
'text' => lang('Admin
entity'),
Modified: trunk/property/inc/class.solocation.inc.php
===================================================================
--- trunk/property/inc/class.solocation.inc.php 2012-10-17 13:57:33 UTC (rev
10254)
+++ trunk/property/inc/class.solocation.inc.php 2012-10-17 14:03:30 UTC (rev
10255)
@@ -292,6 +292,8 @@
$filter_role_on_contact =
$data['filter_role_on_contact'] ? (int)$data['filter_role_on_contact'] : 0;
$role_id =
$data['role_id'] ? (int)$data['role_id'] : 0;
$results =
$data['results'] ? (int)$data['results'] : 0;
+ $control_registered =
isset($data['control_registered']) ? $data['control_registered'] : '';
+ $control_id =
isset($data['control_id']) && $data['control_id'] ? $data['control_id'] : 0;
if (!$type_id)
{
@@ -583,6 +585,16 @@
$sub_query_street =
$this->socommon->fm_cache('sub_query_street_'. $type_id . '_' . $lookup_tenant
. '_' . $lookup);
}
+ $filtermethod = '';
+ $where= 'WHERE';
+ if($control_registered)
+ {
+ $sql .= "{$this->join}
controller_control_location_list ON (fm_location{$type_id}.location_code =
controller_control_location_list.location_code )";
+ $filtermethod .= " $where
controller_control_location_list.control_id = $control_id";
+ $where = 'AND';
+ }
+
+
//---------------------start custom user cols
$user_columns =
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['location_columns_'.$type_id
. !!$lookup]) ?
$GLOBALS['phpgw_info']['user']['preferences']['property']['location_columns_'.$type_id
. !!$lookup] : '';
@@ -681,9 +693,7 @@
}
}
- $where= 'WHERE';
- $filtermethod = '';
$GLOBALS['phpgw']->config->read();
if(isset($GLOBALS['phpgw']->config->config_data['acl_at_location']) &&
$GLOBALS['phpgw']->config->config_data['acl_at_location'])
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [10255] controller: generalize,
Sigurd Nes <=