[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [7491] Merge 7488:7490 from trunk
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [7491] Merge 7488:7490 from trunk |
Date: |
Thu, 11 Aug 2011 11:33:09 +0000 |
Revision: 7491
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=7491
Author: sigurdne
Date: 2011-08-11 11:33:09 +0000 (Thu, 11 Aug 2011)
Log Message:
-----------
Merge 7488:7490 from trunk
Modified Paths:
--------------
branches/Version-1_0-branch/property/inc/class.boagreement.inc.php
branches/Version-1_0-branch/property/inc/class.soagreement.inc.php
branches/Version-1_0-branch/property/inc/class.uiadmin_entity.inc.php
branches/Version-1_0-branch/property/inc/class.uiadmin_location.inc.php
branches/Version-1_0-branch/property/inc/class.uiagreement.inc.php
branches/Version-1_0-branch/property/js/yahoo/agreement.index.js
branches/Version-1_0-branch/property/templates/base/admin_entity.xsl
branches/Version-1_0-branch/property/templates/base/admin_location.xsl
Property Changed:
----------------
branches/Version-1_0-branch/
Property changes on: branches/Version-1_0-branch
___________________________________________________________________
Modified: svn:mergeinfo
-
/trunk:6439-6441,6443,6445-6447,6449-6464,6466-6468,6470-6474,6476-6477,6479-6480,6483-6488,6490-6491,6493-6494,6496-6501,6503-6504,6506,6508,6510-6511,6513,6515-6516,6518,6520-6524,6526-6528,6533-6534,6536-6541,6543-6565,6567,6569,6571-6576,6578,6580-6586,6588-6596,6598-6600,6602-6604,6606-6607,6609-6611,6613-6625,6629-6639,6641-6643,6645-6646,6648,6650-6654,6656-6659,6661-6663,6665-6666,6668-6669,6672-6673,6675,6677-6678,6680,6682-6686,6688-6717,6719,6721-6722,6724-6728,6730,6732-6734,6736-6739,6741,6743,6745-6746,6748-6756,6758-6762,6764,6766-6788,6790,6792-6798,6800-6814,6816-6819,6821-6822,6824-6826,6828-6837,6839,6841,6843-6849,6851,6853-6869,6871-6874,6876-6877,6879,6881,6883,6885-6886,6888-6893,6895-6897,6899-6901,6903,6905-6907,6909,6911-6929,6931-6936,6938-6947,6949,6951,6953,6955-6956,6958-6959,6961-6968,6970-6971,6973-6974,6976-6978,6980,6982-7017,7019-7025,7027-7035,7037-7039,7041-7045,7047-7055,7057,7059-7065,7067-7069,7071,7073,7075-7076,7078,7080-7081,7083,7085,7087,7089-7097,7099-7102,7104-7105,7107-7111,7113-7120,7122-7124,7126-7129,7131,7133-7141,7143,7145-7146,7148-7150,7152-7153,7155-7158,7160-7164,7166-7167,7169-7170,7172,7174,7176,7178,7180-7181,7183,7185,7187-7188,7190,7192-7196,7198-7199,7201-7203,7205,7207,7209-7210,7212,7214,7216-7217,7219-7222,7224-7226,7228-7229,7231,7233-7234,7236-7238,7240-7241,7243-7244,7246,7248,7250,7252-7256,7258-7259,7261-7264,7266-7273,7275-7279,7281-7332,7334-7338,7340-7348,7350,7352-7353,7355-7361,7363-7366,7368-7370,7372,7374,7376,7378,7380-7386,7388-7400,7402,7404-7433,7435-7439,7441-7446,7448-7458,7460-7469,7471-7483,7485-7487
+
/trunk:6439-6441,6443,6445-6447,6449-6464,6466-6468,6470-6474,6476-6477,6479-6480,6483-6488,6490-6491,6493-6494,6496-6501,6503-6504,6506,6508,6510-6511,6513,6515-6516,6518,6520-6524,6526-6528,6533-6534,6536-6541,6543-6565,6567,6569,6571-6576,6578,6580-6586,6588-6596,6598-6600,6602-6604,6606-6607,6609-6611,6613-6625,6629-6639,6641-6643,6645-6646,6648,6650-6654,6656-6659,6661-6663,6665-6666,6668-6669,6672-6673,6675,6677-6678,6680,6682-6686,6688-6717,6719,6721-6722,6724-6728,6730,6732-6734,6736-6739,6741,6743,6745-6746,6748-6756,6758-6762,6764,6766-6788,6790,6792-6798,6800-6814,6816-6819,6821-6822,6824-6826,6828-6837,6839,6841,6843-6849,6851,6853-6869,6871-6874,6876-6877,6879,6881,6883,6885-6886,6888-6893,6895-6897,6899-6901,6903,6905-6907,6909,6911-6929,6931-6936,6938-6947,6949,6951,6953,6955-6956,6958-6959,6961-6968,6970-6971,6973-6974,6976-6978,6980,6982-7017,7019-7025,7027-7035,7037-7039,7041-7045,7047-7055,7057,7059-7065,7067-7069,7071,7073,7075-7076,7078,7080-7081,7083,7085,7087,7089-7097,7099-7102,7104-7105,7107-7111,7113-7120,7122-7124,7126-7129,7131,7133-7141,7143,7145-7146,7148-7150,7152-7153,7155-7158,7160-7164,7166-7167,7169-7170,7172,7174,7176,7178,7180-7181,7183,7185,7187-7188,7190,7192-7196,7198-7199,7201-7203,7205,7207,7209-7210,7212,7214,7216-7217,7219-7222,7224-7226,7228-7229,7231,7233-7234,7236-7238,7240-7241,7243-7244,7246,7248,7250,7252-7256,7258-7259,7261-7264,7266-7273,7275-7279,7281-7332,7334-7338,7340-7348,7350,7352-7353,7355-7361,7363-7366,7368-7370,7372,7374,7376,7378,7380-7386,7388-7400,7402,7404-7433,7435-7439,7441-7446,7448-7458,7460-7469,7471-7483,7485-7487,7489-7490
Modified: branches/Version-1_0-branch/property/inc/class.boagreement.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.boagreement.inc.php
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/inc/class.boagreement.inc.php
2011-08-11 11:33:09 UTC (rev 7491)
@@ -69,62 +69,39 @@
$this->use_session = true;
}
- $start = phpgw::get_var('start', 'int', 'REQUEST', 0);
- $query = phpgw::get_var('query');
- $sort = phpgw::get_var('sort');
- $order = phpgw::get_var('order');
- $filter = phpgw::get_var('filter', 'int');
- $cat_id = phpgw::get_var('cat_id', 'int');
+ $start = phpgw::get_var('start', 'int',
'REQUEST', 0);
+ $query = phpgw::get_var('query');
+ $sort = phpgw::get_var('sort');
+ $order = phpgw::get_var('order');
+ $filter = phpgw::get_var('filter', 'int');
+ $cat_id = phpgw::get_var('cat_id', 'int');
$vendor_id = phpgw::get_var('vendor_id', 'int');
$allrows = phpgw::get_var('allrows', 'bool');
- $role = phpgw::get_var('role');
+ $role = phpgw::get_var('role');
$member_id = phpgw::get_var('member_id', 'int');
+ $status_id = phpgw::get_var('status_id');
-
$this->role = $role;
$this->so->role = $role;
- if ($start)
- {
- $this->start=$start;
- }
- else
- {
- $this->start=0;
- }
+ $this->status_id =
isset($_REQUEST['status_id']) ? $status_id : $this->status_id;
+ $this->start =
isset($_REQUEST['start']) ? $start : $this->start;
+ $this->order =
isset($_REQUEST['order']) ? $order : $this->order;
+ $this->sort =
isset($_REQUEST['sort']) ? $sort : $this->sort;
+ $this->query =
isset($_REQUEST['query']) ? $query : $this->query;
+ $this->vendor_id =
isset($_REQUEST['vendor_id']) ? $vendor_id : $this->vendor_id;
+ $this->member_id =
isset($_REQUEST['member_id']) ? $member_id : $this->member_id;
+ $this->cat_id =
isset($_REQUEST['cat_id']) ? $cat_id : $this->cat_id;
- if(isset($query))
- {
- $this->query = $query;
- }
if(!empty($filter))
{
$this->filter = $filter;
}
- if(isset($sort))
- {
- $this->sort = $sort;
- }
- $this->order = isset($order) && $order ? $order : '';
-
- if(isset($cat_id))
+ if($allrows)
{
- $this->cat_id = $cat_id;
- }
-
- if(isset($allrows))
- {
$this->allrows = $allrows;
}
- if(isset($member_id))
- {
- $this->member_id = $member_id;
- }
- if(isset($vendor_id))
- {
- $this->vendor_id = $vendor_id;
- }
}
function save_sessiondata($data)
@@ -139,7 +116,7 @@
{
$data =
$GLOBALS['phpgw']->session->appsession('session_data','agreement');
- //_debug_array($data);
+// _debug_array($data);die();
$this->start = $data['start'];
$this->query = $data['query'];
@@ -149,7 +126,7 @@
$this->cat_id = $data['cat_id'];
$this->vendor_id= $data['vendor_id'];
$this->member_id= $data['member_id'];
- $this->allrows = $data['allrows'];
+ $this->status_id= $data['status_id'];
}
function check_perms($has, $needed)
@@ -177,28 +154,25 @@
function read()
{
- $agreement = $this->so->read(array('start' =>
$this->start,'query' => $this->query,'sort' => $this->sort,'order' =>
$this->order,
+ $agreements = $this->so->read(array('start' =>
$this->start,'query' => $this->query,'sort' => $this->sort,'order' =>
$this->order,
'filter' => $this->filter,'cat_id' =>
$this->cat_id,'allrows'=>$this->allrows,'member_id'=>$this->member_id,
- 'vendor_id'=>$this->vendor_id));
+ 'vendor_id'=>$this->vendor_id,
'status_id'=>$this->status_id));
$this->total_records = $this->so->total_records;
$this->uicols = $this->so->uicols;
- for ($i=0; $i<count($agreement); $i++)
+ foreach ($agreements as &$agreement)
{
- if($agreement[$i]['start_date'])
+ if($agreement['start_date'])
{
- $agreement[$i]['start_date'] =
$GLOBALS['phpgw']->common->show_date($agreement[$i]['start_date'],$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
+ $agreement['start_date'] =
$GLOBALS['phpgw']->common->show_date($agreement['start_date'],$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
}
- if($agreement[$i]['end_date'])
+ if($agreement['end_date'])
{
- $agreement[$i]['end_date'] =
$GLOBALS['phpgw']->common->show_date($agreement[$i]['end_date'],$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
+ $agreement['end_date'] =
$GLOBALS['phpgw']->common->show_date($agreement['end_date'],$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
}
-
- $agreement[$i]['status'] =
lang($agreement[$i]['status']);
-
}
- return $agreement;
+ return $agreements;
}
function read_details($id)
Modified: branches/Version-1_0-branch/property/inc/class.soagreement.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.soagreement.inc.php
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/inc/class.soagreement.inc.php
2011-08-11 11:33:09 UTC (rev 7491)
@@ -65,20 +65,18 @@
function read($data)
{
- if(is_array($data))
- {
- $start =
(isset($data['start'])?$data['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']:'');
- $vendor_id =
(isset($data['vendor_id'])?$data['vendor_id']:'');
- $allrows =
(isset($data['allrows'])?$data['allrows']:'');
- $member_id =
(isset($data['member_id'])?$data['member_id']:0);
- $agreement_id =
(isset($data['agreement_id'])?$data['agreement_id']:'');
- $status =
(isset($data['status'])?$data['status']:'');
- }
+//_debug_array($data);die();
+ $start = isset($data['start']) &&
$data['start'] ? (int)$data['start'] : 0;
+ $filter = isset($data['filter']) &&
$data['filter'] ? $data['filter'] : 'none';
+ $query = isset($data['query']) ?
$data['query'] : '';
+ $sort = isset($data['sort']) &&
$data['sort'] ? $data['sort'] : 'DESC';
+ $order = isset($data['order']) ?
$data['order'] : '';
+ $cat_id = isset($data['cat_id']) ?
(int) $data['cat_id'] : '';
+ $vendor_id = isset($data['vendor_id']) ?
(int)$data['vendor_id']:'';
+ $allrows = isset($data['allrows']) ?
$data['allrows']:'';
+ $member_id = isset($data['member_id']) ?
(int)$data['member_id']:0;
+ $agreement_id = isset($data['agreement_id'])? (int)
$data['agreement_id']:'';
+ $status_id = isset($data['status_id']) ?
$data['status_id'] : '';
$filtermethod = '';
$querymethod = '';
@@ -91,10 +89,11 @@
$location_id =
$GLOBALS['phpgw']->locations->get_id('property', '.agreement');
$attribute_filter = " location_id = {$location_id}";
$paranthesis ='(';
- $joinmethod = " $this->join $category_table ON (
$entity_table.category =$category_table.id)";
- $joinmethod .= " $this->join fm_vendor ON (
$entity_table.vendor_id =fm_vendor.id ))";
+ $joinmethod = " {$this->join} {$category_table} ON (
{$entity_table}.category = {$category_table}.id)";
+ $joinmethod .= " {$this->join} fm_vendor ON (
{$entity_table}.vendor_id =fm_vendor.id )";
+ $joinmethod .= " {$this->join} fm_agreement_status ON (
{$entity_table}.status = fm_agreement_status.id))";
- $cols = $entity_table . ".*,$category_table.descr as
category, org_name";
+ $cols = "{$entity_table}.*,{$category_table}.descr as
category, org_name, fm_agreement_status.descr as status";
$cols_return[] = 'id';
$uicols['input_type'][] = 'text';
@@ -147,25 +146,26 @@
if ($order)
{
- if ($order=='id')
+ switch ($order)
{
- $ordermethod = " order by
$entity_table.$order $sort";
+ case 'id':
+ case 'status':
+ $ordermethod = " ORDER BY
{$entity_table}.{$order} {$sort}";
+ break;
+ case 'category':
+ $ordermethod = " ORDER BY
{$category_table}.descr {$sort}";
+ break;
+ default:
+ $ordermethod = " ORDER BY
{$order} {$sort}";
}
- else
- {
- $ordermethod = " order by $order $sort";
- }
}
else
{
- $ordermethod = " order by $entity_table.id
DESC";
+ $ordermethod = " ORDER BY {$entity_table}.id
DESC";
}
+//_debug_array($ordermethod);
+ $sql = "SELECT {$cols} FROM {$paranthesis}
{$entity_table} {$joinmethod}";
-
- $from = " FROM $paranthesis $entity_table ";
-
- $sql = "SELECT $cols $from $joinmethod";
-
$i = count($uicols['name']);
$user_columns =
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['agreement_columns'
.
!!$agreement_id])?$GLOBALS['phpgw_info']['user']['preferences']['property']['agreement_columns'
. !!$agreement_id]:'';
@@ -244,9 +244,9 @@
$where= 'AND';
}
- if ($status)
+ if ($status_id)
{
- $filtermethod .= " $where
$entity_table.status='$status' ";
+ $filtermethod .= " {$where}
{$entity_table}.status='{$status_id}' ";
$where= 'AND';
}
Modified: branches/Version-1_0-branch/property/inc/class.uiadmin_entity.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.uiadmin_entity.inc.php
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/inc/class.uiadmin_entity.inc.php
2011-08-11 11:33:09 UTC (rev 7491)
@@ -2414,35 +2414,18 @@
'lang_done_attribtext'
=> lang('Back to the list'),
'lang_save_attribtext'
=> lang('Save the attribute'),
- 'lang_datatype'
=> lang('Datatype'),
- 'lang_datatype_statustext'
=> lang('Select a datatype'),
- 'lang_no_datatype'
=> lang('No datatype'),
'datatype_list'
=>
$this->bocommon->select_datatype($values['column_info']['type']),
- 'lang_group'
=> lang('group'),
- 'lang_group_statustext'
=> lang('Select a group'),
- 'lang_no_group'
=> lang('no group'),
'attrib_group_list'
=> $this->bo->get_attrib_group_list($entity_id,$cat_id,
$values['group_id']),
- 'lang_precision'
=> lang('Precision'),
- 'lang_precision_statustext'
=> lang('enter the record length'),
'value_precision'
=> $values['column_info']['precision'],
- 'lang_scale'
=> lang('scale'),
- 'lang_scale_statustext'
=> lang('enter the scale if type is decimal'),
'value_scale'
=> $values['column_info']['scale'],
- 'lang_default'
=> lang('default'),
- 'lang_default_statustext'
=> lang('enter the default value'),
'value_default'
=> $values['column_info']['default'],
- 'lang_nullable'
=> lang('Nullable'),
- 'lang_nullable_statustext'
=> lang('Chose if this column is nullable'),
- 'lang_select_nullable'
=> lang('Select nullable'),
'nullable_list'
=>
$this->bocommon->select_nullable($values['column_info']['nullable']),
'value_lookup_form'
=> $values['lookup_form'],
- 'lang_lookup_form'
=> lang('show in lookup forms'),
- 'lang_lookup_form_statustext'
=> lang('check to show this attribue in lookup forms'),
'value_list'
=> $values['list'],
'value_search'
=> $values['search'],
'value_history'
=> $values['history'],
Modified:
branches/Version-1_0-branch/property/inc/class.uiadmin_location.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.uiadmin_location.inc.php
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/inc/class.uiadmin_location.inc.php
2011-08-11 11:33:09 UTC (rev 7491)
@@ -1611,39 +1611,18 @@
'type_id'
=> $values['type_id'],
'entity_list'
=> $this->bo->select_location_type($type_id),
'select_location_type'
=> 'values[type_id]',
- 'lang_datatype'
=> lang('Datatype'),
- 'lang_datatype_statustext'
=> lang('Select a datatype'),
- 'lang_no_datatype'
=> lang('No datatype'),
+
'datatype_list'
=> $this->bocommon->select_datatype($values['column_info']['type']),
'value_search'
=> $values['search'],
- 'lang_group'
=> lang('group'),
- 'lang_group_statustext'
=> lang('Select a group'),
- 'lang_no_group'
=> lang('no group'),
'attrib_group_list'
=> $this->bo->get_attrib_group_list($type_id, $values['group_id']),
- 'lang_precision'
=> lang('Precision'),
- 'lang_precision_statustext'
=> lang('enter the record length'),
'value_precision'
=> $values['column_info']['precision'],
-
- 'lang_scale'
=> lang('scale'),
- 'lang_scale_statustext'
=> lang('enter the scale if type is decimal'),
'value_scale'
=> $values['column_info']['scale'],
-
- 'lang_default'
=> lang('default'),
- 'lang_default_statustext'
=> lang('enter the default value'),
'value_default'
=> $values['column_info']['default'],
-
- 'lang_nullable'
=> lang('Nullable'),
- 'lang_nullable_statustext'
=> lang('Chose if this column is nullable'),
- 'lang_select_nullable'
=> lang('Select nullable'),
'nullable_list'
=> $this->bocommon->select_nullable($values['column_info']['nullable']),
'value_lookup_form'
=> $values['lookup_form'],
- 'lang_lookup_form'
=> lang('show in lookup forms'),
- 'lang_lookup_form_statustext' =>
lang('check to show this attribue in lookup forms'),
'value_list'
=> $values['list'],
- 'lang_list'
=> lang('show in list'),
- 'lang_list_statustext'
=> lang('check to show this attribute in location list')
);
//_debug_array($data);
Modified: branches/Version-1_0-branch/property/inc/class.uiagreement.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.uiagreement.inc.php
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/inc/class.uiagreement.inc.php
2011-08-11 11:33:09 UTC (rev 7491)
@@ -52,8 +52,8 @@
'edit_item' => true,
'view_item' => true,
'view_file' => true,
- 'download' => true,
- 'add_activity' => true
+ 'download' => true,
+ 'add_activity' => true
);
function property_uiagreement()
@@ -87,6 +87,7 @@
$this->vendor_id = $this->bo->vendor_id;
$this->allrows = $this->bo->allrows;
$this->member_id = $this->bo->member_id;
+ $this->status_id = $this->bo->status_id;
}
function save_sessiondata()
@@ -101,7 +102,8 @@
'cat_id' => $this->cat_id,
'vendor_id' => $this->vendor_id,
'allrows' => $this->allrows,
- 'member_id' => $this->member_id
+ 'member_id' => $this->member_id,
+ 'status_id' => $this->status_id
);
$this->bo->save_sessiondata($data);
}
@@ -177,30 +179,26 @@
$GLOBALS['phpgw_info']['flags']['menu_selection'] =
'property::agreement::pricebook::agreement';
$datatable = array();
+ $this->save_sessiondata();
if( phpgw::get_var('phpgw_return_as') != 'json' )
{
$datatable['menu']
= $this->bocommon->get_menu();
$datatable['config']['base_url'] =
$GLOBALS['phpgw']->link('/index.php', array
- (
- 'menuaction' =>
'property.uiagreement.index',
- 'sort'
=>$this->sort,
- 'order'
=>$this->order,
- 'cat_id'
=>$this->cat_id,
- 'filter'
=>$this->filter,
- 'query'
=>$this->query,
- 'role' =>
$this->role,
- 'member_id' =>
$this->member_id
- ));
+ (
+ 'menuaction' =>
'property.uiagreement.index',
+ 'sort' =>$this->sort,
+ 'order' =>$this->order,
+ 'cat_id' =>$this->cat_id,
+ 'filter' =>$this->filter,
+ 'query' =>$this->query,
+ 'role' => $this->role,
+ 'member_id' =>
$this->member_id,
+ 'status_id' =>
$this->status_id
+ ));
$datatable['config']['base_java_url'] =
"menuaction:'property.uiagreement.index',"
- ."sort:'{$this->sort}',"
- ."order:'{$this->order}',"
- ."cat_id: '{$this->cat_id}',"
- ."filter:'{$this->filter}',"
- ."query:'{$this->query}',"
- ."role:'{$this->role}',"
- ."member_id:'{$this->member_id}'";
+ ."status_id:'{$this->status_id}'";
$datatable['config']['allow_allrows'] = true;
@@ -213,7 +211,8 @@
'filter' =>$this->filter,
'query' =>$this->query,
'role' => $this->role,
- 'member_id' =>
$this->member_id
+ 'member_id' =>
$this->member_id,
+ 'status_id' =>
$this->status_id
);
$values_combo_box[0] =
$this->cats->formatted_xslt_list(array('selected' => $this->member_id,'globals'
=> true,'link_data' =>$link_data));
@@ -228,6 +227,10 @@
$default_value = array
('id'=>'','name'=>lang('no vendor'));
array_unshift
($values_combo_box[2],$default_value);
+ $values_combo_box[3] =
$this->bo->select_status_list('filter',$this->status_id);
+ $default_value = array
('id'=>'','name'=>lang('no status'));
+ array_unshift
($values_combo_box[3],$default_value);
+
//_debug_array($values_combo_box[0]);die;
$datatable['actions']['form'] = array(
@@ -241,12 +244,13 @@
'filter'
=> $this->filter,
'query'
=> $this->query,
'role'
=> $this->role,
- 'member_id'
=> $this->member_id
+ 'member_id'
=> $this->member_id,
+ 'status_id'
=> $this->status_id
)
),
'fields' => array(
'field' => array(
- array( //boton CATEGORY
+ array( //boton member
'id' =>
'btn_member_id',
'name' =>
'member_id',
'value' =>
lang('Member'),
@@ -254,7 +258,7 @@
'style' =>
'filter',
'tab_index' => 1
),
- array( //boton STATUS
+ array( //boton CATEGORY
'id' =>
'btn_cat_id',
'name' =>
'category_id',
'value' =>
lang('Category'),
@@ -262,7 +266,7 @@
'style' =>
'filter',
'tab_index' => 2
),
- array( //boton HOUR
CATEGORY
+ array( //boton vendor
'id' =>
'btn_vendor_id',
'name' =>
'vendor_id',
'value' =>
lang('Vendor'),
@@ -270,18 +274,26 @@
'style' =>
'filter',
'tab_index' => 3
),
+ array( //boton STATUS
+ 'id' =>
'btn_status_id',
+ 'name' =>
'status_id',
+ 'value' =>
lang('status'),
+ 'type' =>
'button',
+ 'style' =>
'filter',
+ 'tab_index' => 4
+ ),
array(
'type' =>
'button',
'id' =>
'btn_new',
'value' =>
lang('add'),
- 'tab_index' => 8
+ 'tab_index' => 7
),
array( //boton
SEARCH
'id' =>
'btn_search',
'name' =>
'search',
'value' =>
lang('search'),
'type' =>
'button',
- 'tab_index' => 7
+ 'tab_index' => 6
),
array( // TEXT INPUT
'name' =>
'query',
@@ -290,7 +302,7 @@
'type' =>
'text',
'onkeypress' =>
'return pulsar(event)',
'size' => 28,
- 'tab_index' => 6
+ 'tab_index' => 5
),
array(
'type' =>
'link',
@@ -302,7 +314,14 @@
'role'
=> $this->role
))."','','width=300,height=600,scrollbars=1')",
'value' =>
lang('columns'),
- 'tab_index' => 9
+ 'tab_index' => 8
+ ),
+ array
+ (
+ 'type' =>
'button',
+ 'id' =>
'btn_export',
+ 'value' =>
lang('download'),
+ 'tab_index' =>
10
)
),
'hidden_value' => array(
@@ -317,6 +336,10 @@
array( //div values
combo_box_2
'id' =>
'values_combo_box_2',
'value' =>
$this->bocommon->select2String($values_combo_box[2])
+ ),
+ array( //div values
combo_box_3
+ 'id' =>
'values_combo_box_3',
+ 'value' =>
$this->bocommon->select2String($values_combo_box[3])
)
)
)
@@ -467,12 +490,13 @@
$datatable['headers']['header'][$i]['sortable'] = true;
$datatable['headers']['header'][$i]['sort_field'] = $uicols['name'][$i];
}
-
+/*
if($uicols['name'][$i]=='category')
{
$datatable['headers']['header'][$i]['sortable'] = true;
$datatable['headers']['header'][$i]['sort_field'] = 'org_name';
}
+*/
}
}
@@ -1498,7 +1522,14 @@
function download()
{
$id = phpgw::get_var('id', 'int');
- $list = $this->bo->read_details($id);
+ if($id)
+ {
+ $list = $this->bo->read_details($id);
+ }
+ else
+ {
+ $list = $this->bo->read($id);
+ }
$uicols = $this->bo->uicols;
$this->bocommon->download($list,$uicols['name'],$uicols['descr'],$uicols['input_type']);
}
Modified: branches/Version-1_0-branch/property/js/yahoo/agreement.index.js
===================================================================
--- branches/Version-1_0-branch/property/js/yahoo/agreement.index.js
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/js/yahoo/agreement.index.js
2011-08-11 11:33:09 UTC (rev 7491)
@@ -2,18 +2,20 @@
// Declaration of location.index vars
//--------------------------------------------------------
//define SelectButton
- var oMenuButton_0, oMenuButton_1, oMenuButton_2;
+ var oMenuButton_0, oMenuButton_1, oMenuButton_2, oMenuButton_3;
var selectsButtons = [
{order:0,
var_URL:'member_id',name:'btn_member_id',style:'categorybutton',dependiente:''},
{order:1,
var_URL:'cat_id',name:'btn_cat_id',style:'districtbutton',dependiente:''},
- {order:2,
var_URL:'vendor_id',name:'btn_vendor_id',style:'partOFTownbutton',dependiente:''}
+ {order:2,
var_URL:'vendor_id',name:'btn_vendor_id',style:'partOFTownbutton',dependiente:''},
+ {order:3,
var_URL:'status_id',name:'btn_status_id',style:'partOFTownbutton',dependiente:''}
];
// define buttons
- var oNormalButton_0, oNormalButton_1;
+ var oNormalButton_0, oNormalButton_1, oNormalButton_2;
var normalButtons = [
{order:0, name:'btn_search', funct:"onSearchClick"},
- {order:1, name:'btn_new', funct:"onNewClick"}
+ {order:1, name:'btn_new', funct:"onNewClick"},
+ {order:2, name:'btn_export', funct:"onDownloadClick"}
];
// define Text buttons
Modified: branches/Version-1_0-branch/property/templates/base/admin_entity.xsl
===================================================================
--- branches/Version-1_0-branch/property/templates/base/admin_entity.xsl
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/templates/base/admin_entity.xsl
2011-08-11 11:33:09 UTC (rev 7491)
@@ -1216,11 +1216,9 @@
<xsl:value-of
select="lang_column_name"/>
</td>
<td>
- <input type="text"
name="values[column_name]" value="{value_column_name}" maxlength="50"
onMouseout="window.status='';return true;">
- <xsl:attribute
name="onMouseover">
-
<xsl:text>window.status='</xsl:text>
+ <input type="text"
name="values[column_name]" value="{value_column_name}" maxlength="50">
+ <xsl:attribute
name="title">
<xsl:value-of select="lang_column_name_statustext"/>
-
<xsl:text>'; return true;</xsl:text>
</xsl:attribute>
</input>
</td>
@@ -1230,11 +1228,9 @@
<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>
+ <input type="text"
name="values[input_text]" value="{value_input_text}" size ="60" maxlength="50">
+ <xsl:attribute
name="title">
<xsl:value-of select="lang_input_text_statustext"/>
-
<xsl:text>'; return true;</xsl:text>
</xsl:attribute>
</input>
</td>
@@ -1244,11 +1240,9 @@
<xsl:value-of
select="lang_statustext"/>
</td>
<td>
- <textarea cols="60"
rows="10" name="values[statustext]" onMouseout="window.status='';return true;">
- <xsl:attribute
name="onMouseover">
-
<xsl:text>window.status='</xsl:text>
+ <textarea cols="60"
rows="10" name="values[statustext]">
+ <xsl:attribute
name="title">
<xsl:value-of select="lang_statustext_attribtext"/>
-
<xsl:text>'; return true;</xsl:text>
</xsl:attribute>
<xsl:value-of
select="value_statustext"/>
</textarea>
@@ -1256,78 +1250,86 @@
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_group"/>
+ <xsl:value-of
select="php:function('lang', 'group')" />
</td>
<td valign="top">
- <xsl:variable
name="lang_group_statustext"><xsl:value-of
select="lang_group_statustext"/></xsl:variable>
- <select
name="values[group_id]" class="forms"
onMouseover="window.status='{$lang_group_statustext}'; return true;"
onMouseout="window.status='';return true;">
- <option
value=""><xsl:value-of select="lang_no_group"/></option>
+ <select
name="values[group_id]" class="forms">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'select a group')" />
+ </xsl:attribute>
+
+ <option
value="">
+
<xsl:value-of select="php:function('lang', 'no group')" />
+ </option>
<xsl:apply-templates select="attrib_group_list"/>
</select>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_datatype"/>
+ <xsl:value-of
select="php:function('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>
+ <select
name="values[column_info][type]" class="forms">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'select a datatype')" />
+ </xsl:attribute>
+ <option
value="">
+
<xsl:value-of select="php:function('lang', 'no datatype')" />
+ </option>
<xsl:apply-templates select="datatype_list"/>
</select>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_precision"/>
+ <xsl:value-of
select="php:function('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>
+ <input type="text"
name="values[column_info][precision]" value="{value_precision}">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'enter the record length')" />
</xsl:attribute>
</input>
</td>
</tr>
+
<tr>
<td valign="top">
- <xsl:value-of
select="lang_scale"/>
+ <xsl:value-of
select="php:function('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>
+ <input type="text"
name="values[column_info][scale]" value="{value_scale}">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'enter the scale if type is
decimal')" />
</xsl:attribute>
</input>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_default"/>
+ <xsl:value-of
select="php:function('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>
+ <input type="text"
name="values[column_info][default]" value="{value_default}">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'enter the default value')" />
</xsl:attribute>
</input>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_nullable"/>
+ <xsl:value-of
select="php:function('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>
+ <select
name="values[column_info][nullable]">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'chose if this column is nullable')"
/>
+ </xsl:attribute>
+ <option
value="">
+
<xsl:value-of select="php:function('lang', 'select nullable')" />
+ </option>
<xsl:apply-templates select="nullable_list"/>
</select>
</td>
Modified: branches/Version-1_0-branch/property/templates/base/admin_location.xsl
===================================================================
--- branches/Version-1_0-branch/property/templates/base/admin_location.xsl
2011-08-11 11:30:49 UTC (rev 7490)
+++ branches/Version-1_0-branch/property/templates/base/admin_location.xsl
2011-08-11 11:33:09 UTC (rev 7491)
@@ -618,11 +618,9 @@
<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>
+ <input type="text"
name="values[column_name]" value="{value_column_name}" maxlength="20">
+ <xsl:attribute
name="title">
<xsl:value-of select="lang_column_name_statustext"/>
-
<xsl:text>'; return true;</xsl:text>
</xsl:attribute>
</input>
</td>
@@ -632,11 +630,9 @@
<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>
+ <input type="text"
name="values[input_text]" value="{value_input_text}" size ="60" maxlength="50">
+ <xsl:attribute
name="title">
<xsl:value-of select="lang_input_text_statustext"/>
-
<xsl:text>'; return true;</xsl:text>
</xsl:attribute>
</input>
</td>
@@ -646,11 +642,9 @@
<xsl:value-of
select="lang_statustext"/>
</td>
<td>
- <textarea cols="60"
rows="10" name="values[statustext]" onMouseout="window.status='';return true;">
- <xsl:attribute
name="onMouseover">
-
<xsl:text>window.status='</xsl:text>
+ <textarea cols="60"
rows="10" name="values[statustext]" >
+ <xsl:attribute
name="title">
<xsl:value-of select="lang_statustext_attribtext"/>
-
<xsl:text>'; return true;</xsl:text>
</xsl:attribute>
<xsl:value-of
select="value_statustext"/>
</textarea>
@@ -665,7 +659,7 @@
<td valign="top">
<xsl:variable
name="lang_entity_statustext"><xsl:value-of
select="lang_entity_statustext"/></xsl:variable>
<xsl:variable
name="select_location_type"><xsl:value-of
select="select_location_type"/></xsl:variable>
- <select
name="{$select_location_type}" class="forms"
onMouseover="window.status='{$lang_entity_statustext}'; return true;"
onMouseout="window.status='';return true;">
+ <select
name="{$select_location_type}" class="forms" title="{$lang_entity_statustext}">
<option
value=""><xsl:value-of select="lang_no_location_type"/></option>
<xsl:apply-templates select="entity_list"/>
</select>
@@ -673,12 +667,17 @@
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_group"/>
+ <xsl:value-of
select="php:function('lang', 'group')" />
</td>
<td valign="top">
- <xsl:variable
name="lang_group_statustext"><xsl:value-of
select="lang_group_statustext"/></xsl:variable>
- <select
name="values[group_id]" class="forms"
onMouseover="window.status='{$lang_group_statustext}'; return true;"
onMouseout="window.status='';return true;">
- <option
value=""><xsl:value-of select="lang_no_group"/></option>
+ <select
name="values[group_id]" class="forms">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'select a group')" />
+ </xsl:attribute>
+
+ <option
value="">
+
<xsl:value-of select="php:function('lang', 'no group')" />
+ </option>
<xsl:apply-templates select="attrib_group_list"/>
</select>
</td>
@@ -686,122 +685,105 @@
<tr>
<td valign="top">
- <xsl:value-of
select="lang_datatype"/>
+ <xsl:value-of
select="php:function('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>
+ <select
name="values[column_info][type]" class="forms">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'select a datatype')" />
+ </xsl:attribute>
+ <option
value="">
+
<xsl:value-of select="php:function('lang', 'no datatype')" />
+ </option>
<xsl:apply-templates select="datatype_list"/>
</select>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_precision"/>
+ <xsl:value-of
select="php:function('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>
+ <input type="text"
name="values[column_info][precision]" value="{value_precision}">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'enter the record length')" />
</xsl:attribute>
</input>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_scale"/>
+ <xsl:value-of
select="php:function('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>
+ <input type="text"
name="values[column_info][scale]" value="{value_scale}">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'enter the scale if type is
decimal')" />
</xsl:attribute>
</input>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_default"/>
+ <xsl:value-of
select="php:function('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>
+ <input type="text"
name="values[column_info][default]" value="{value_default}">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'enter the default value')" />
</xsl:attribute>
</input>
</td>
</tr>
<tr>
<td valign="top">
- <xsl:value-of
select="lang_nullable"/>
+ <xsl:value-of
select="php:function('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>
+ <select
name="values[column_info][nullable]">
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'chose if this column is nullable')"
/>
+ </xsl:attribute>
+ <option
value="">
+
<xsl:value-of select="php:function('lang', 'select nullable')" />
+ </option>
<xsl:apply-templates select="nullable_list"/>
</select>
</td>
</tr>
<tr>
<td>
- <xsl:value-of
select="lang_lookup_form"/>
+ <xsl:value-of
select="php:function('lang', 'show in lookup forms')" />
</td>
<td>
- <xsl:choose>
- <xsl:when
test="value_lookup_form = 1">
- <input
type="checkbox" name="values[lookup_form]" value="1" checked="checked"
onMouseout="window.status='';return true;">
-
<xsl:attribute name="onMouseover">
-
<xsl:text>window.status='</xsl:text>
-
<xsl:value-of select="lang_lookup_form_statustext"/>
-
<xsl:text>'; return true;</xsl:text>
-
</xsl:attribute>
- </input>
- </xsl:when>
- <xsl:otherwise>
- <input
type="checkbox" name="values[lookup_form]" value="1"
onMouseout="window.status='';return true;">
-
<xsl:attribute name="onMouseover">
-
<xsl:text>window.status='</xsl:text>
-
<xsl:value-of select="lang_lookup_form_statustext"/>
-
<xsl:text>'; return true;</xsl:text>
-
</xsl:attribute>
- </input>
- </xsl:otherwise>
- </xsl:choose>
+ <input type="checkbox"
name="values[lookup_form]" value="1">
+ <xsl:if
test="value_lookup_form = 1">
+
<xsl:attribute name="checked">
+
<xsl:text>checked</xsl:text>
+
</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'check to show this attribue in
lookup forms')" />
+ </xsl:attribute>
+ </input>
</td>
</tr>
+
<tr>
<td>
- <xsl:value-of
select="lang_list"/>
+ <xsl:value-of
select="php:function('lang', 'show in 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>
+ <input type="checkbox"
name="values[list]" value="1">
+ <xsl:if
test="value_list = 1">
+
<xsl:attribute name="checked">
+
<xsl:text>checked</xsl:text>
+
</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute
name="title">
+
<xsl:value-of select="php:function('lang', 'check to show this attribute in
entity list')" />
+ </xsl:attribute>
+ </input>
</td>
</tr>
<tr>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [7491] Merge 7488:7490 from trunk,
Sigurd Nes <=