[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] property/inc class.bowo_hour.inc.php class.sowo...
From: |
Sigurd Nes |
Subject: |
[Phpgroupware-cvs] property/inc class.bowo_hour.inc.php class.sowo... |
Date: |
Fri, 10 Mar 2006 09:24:30 +0000 |
CVSROOT: /sources/phpgroupware
Module name: property
Branch:
Changes by: Sigurd Nes <address@hidden> 06/03/10 09:24:30
Modified files:
inc : class.bowo_hour.inc.php class.sowo_hour.inc.php
class.uiwo_hour.inc.php
Log message:
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/property/inc/class.bowo_hour.inc.php.diff?tr1=1.9&tr2=1.10&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/property/inc/class.sowo_hour.inc.php.diff?tr1=1.11&tr2=1.12&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/property/inc/class.uiwo_hour.inc.php.diff?tr1=1.19&tr2=1.20&r1=text&r2=text
Patches:
Index: property/inc/class.bowo_hour.inc.php
diff -u property/inc/class.bowo_hour.inc.php:1.9
property/inc/class.bowo_hour.inc.php:1.10
--- property/inc/class.bowo_hour.inc.php:1.9 Fri Feb 3 12:05:49 2006
+++ property/inc/class.bowo_hour.inc.php Fri Mar 10 09:24:30 2006
@@ -8,7 +8,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package property
* @subpackage project
- * @version $Id: class.bowo_hour.inc.php,v 1.9 2006/02/03 12:05:49
sigurdne Exp $
+ * @version $Id: class.bowo_hour.inc.php,v 1.10 2006/03/10 09:24:30
sigurdne Exp $
*/
/**
@@ -321,6 +321,10 @@
$values['quantity'][$n]=1;
}
+ if ($values['wo_hour_cat'][$n] &&
!$values['cat_per_cent'][$n])
+ {
+ $values['cat_per_cent'][$n] = 100;
+ }
$values['quantity'][$n] =
str_replace(",",".",$values['quantity'][$n]);
$cost=($values['total_cost'][$n]*$values['quantity'][$n]);
@@ -336,9 +340,9 @@
'ns3420_id' =>
$values['ns3420_id'][$n],
'dim_d' =>
$values['dim_d'][$n],
'workorder_id' =>
$workorder_id,
- 'wo_hour_cat' =>
$values['wo_hour_cat'][$n]
+ 'wo_hour_cat' =>
$values['wo_hour_cat'][$n],
+ 'cat_per_cent' =>
$values['cat_per_cent'][$n]
);
-
}
//_debug_array($hour);
@@ -367,6 +371,11 @@
$values['quantity'][$n]=1;
}
+ if ($values['wo_hour_cat'][$n] &&
!$values['cat_per_cent'][$n])
+ {
+ $values['cat_per_cent'][$n] = 100;
+ }
+
$values['quantity'][$n] =
str_replace(",",".",$values['quantity'][$n]);
$cost=($values['billperae'][$n]*$values['quantity'][$n]);
@@ -375,17 +384,19 @@
'activity_id' =>
$values['activity_id'][$n],
'activity_num' =>
$values['activity_num'][$n],
'hours_descr' =>
$values['hours_descr'][$n],
- 'remark' =>
$values['remark'][$n],
- 'unit' =>
$values['unit'][$n],
- 'cost' =>
$cost,
- 'quantity' =>
$values['quantity'][$n],
+ 'remark' =>
$values['remark'][$n],
+ 'unit' =>
$values['unit'][$n],
+ 'cost' => $cost,
+ 'quantity' =>
$values['quantity'][$n],
'new_grouping' =>
$values['grouping_descr'][$n],
- 'billperae' =>
$values['billperae'][$n],
- 'ns3420_id' =>
$values['ns3420_id'][$n],
- 'tolerance' =>
$values['tolerance'][$n],
+ 'billperae' =>
$values['billperae'][$n],
+ 'ns3420_id' =>
$values['ns3420_id'][$n],
+ 'tolerance' =>
$values['tolerance'][$n],
'building_part' =>
$values['building_part'][$n],
- 'dim_d' =>
$values['dim_d'][$n],
+ 'dim_d' =>
$values['dim_d'][$n],
'workorder_id' =>
$workorder_id,
+ 'wo_hour_cat' =>
$values['wo_hour_cat'][$n],
+ 'cat_per_cent' =>
$values['cat_per_cent'][$n]
);
}
Index: property/inc/class.sowo_hour.inc.php
diff -u property/inc/class.sowo_hour.inc.php:1.11
property/inc/class.sowo_hour.inc.php:1.12
--- property/inc/class.sowo_hour.inc.php:1.11 Mon Jan 30 22:14:19 2006
+++ property/inc/class.sowo_hour.inc.php Fri Mar 10 09:24:30 2006
@@ -8,7 +8,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package property
* @subpackage project
- * @version $Id: class.sowo_hour.inc.php,v 1.11 2006/01/30 22:14:19
sigurdne Exp $
+ * @version $Id: class.sowo_hour.inc.php,v 1.12 2006/03/10 09:24:30
sigurdne Exp $
*/
/**
@@ -125,7 +125,8 @@
'remark' =>
$this->db->f('remark'),
'building_part' =>
$this->db->f('building_part'),
'dim_d' =>
$this->db->f('dim_d'),
- 'wo_hour_category' =>
$this->db->f('wo_hour_category')
+ 'wo_hour_category' =>
$this->db->f('wo_hour_category'),
+ 'cat_per_cent' =>
$this->db->f('cat_per_cent')
);
}
@@ -352,11 +353,13 @@
$record,
time(),
$hour[$i]['workorder_id'],
- $hour[$i]['wo_hour_cat']);
+ $hour[$i]['wo_hour_cat'],
+ $hour[$i]['cat_per_cent']
+ );
$values =
$this->bocommon->validate_db_insert($values);
- $this->db->query("insert into fm_wo_hours
(activity_id,activity_num,owner,hours_descr,unit,cost,quantity,billperae,ns3420_id,dim_d,record,entry_date,workorder_id,category)
"
+ $this->db->query("insert into fm_wo_hours
(activity_id,activity_num,owner,hours_descr,unit,cost,quantity,billperae,ns3420_id,dim_d,record,entry_date,workorder_id,category,cat_per_cent)
"
. " values ($values)",__LINE__,__FILE__);
$record++;
@@ -419,13 +422,16 @@
$hour[$i]['tolerance_id'],
$hour[$i]['remark'],
time(),
- $workorder_id );
+ $workorder_id,
+ $hour[$i]['wo_hour_cat'],
+ $hour[$i]['cat_per_cent']
+ );
$values =
$this->bocommon->validate_db_insert($values);
$this->db->query("insert into fm_wo_hours
(owner,activity_id,activity_num,hours_descr,unit,cost,quantity,billperae,ns3420_id,dim_d,"
- . "
grouping_id,grouping_descr,record,building_part,tolerance,remark,entry_date,workorder_id)
"
- . " values ($values )",__LINE__,__FILE__);
+ . "
grouping_id,grouping_descr,record,building_part,tolerance,remark,entry_date,workorder_id,category,cat_per_cent)
"
+ . " values ($values)",__LINE__,__FILE__);
$record++;
}
@@ -490,13 +496,14 @@
$hour['remark'],
time(),
$workorder_id,
- $hour['wo_hour_cat']
+ $hour['wo_hour_cat'],
+ $hour['cat_per_cent']
);
$values = $this->bocommon->validate_db_insert($values);
$this->db->query("insert into fm_wo_hours
(owner,hours_descr,unit,cost,quantity,billperae,ns3420_id,dim_d,"
- . "
grouping_id,grouping_descr,record,building_part,tolerance,remark,entry_date,workorder_id,category)
"
+ . "
grouping_id,grouping_descr,record,building_part,tolerance,remark,entry_date,workorder_id,category,cat_per_cent)
"
. "VALUES ( $values )",__LINE__,__FILE__);
$receipt['hour_id'] =
$this->db->get_last_insert_id('fm_wo_hours','id');
@@ -515,22 +522,23 @@
if ($this->db->next_record())
{
- $hour['hour_id']
= $this->db->f('id');
- $hour['record']
= $this->db->f('record');
+ $hour['hour_id'] =
$this->db->f('id');
+ $hour['record'] =
$this->db->f('record');
$hour['activity_id'] =
$this->db->f('activity_id');
$hour['activity_num'] =
$this->db->f('activity_num');
$hour['grouping_id'] =
$this->db->f('grouping_id');
$hour['hours_descr'] =
$this->db->f('hours_descr');
- $hour['remark']
= $this->db->f('remark');
- $hour['billperae']
= $this->db->f('billperae');
- $hour['unit']
= $this->db->f('unit');
- $hour['ns3420_id']
= $this->db->f('ns3420_id');
+ $hour['remark'] =
$this->db->f('remark');
+ $hour['billperae'] =
$this->db->f('billperae');
+ $hour['unit'] =
$this->db->f('unit');
+ $hour['ns3420_id'] =
$this->db->f('ns3420_id');
$hour['tolerance_id'] =
(int)$this->db->f('tolerance');
$hour['building_part_id'] =
(int)$this->db->f('building_part');
- $hour['quantity']
= $this->db->f('quantity');
- $hour['cost']
= $this->db->f('cost');
- $hour['dim_d']
= $this->db->f('dim_d');
- $hour['wo_hour_cat']
= $this->db->f('category');
+ $hour['quantity'] =
$this->db->f('quantity');
+ $hour['cost'] =
$this->db->f('cost');
+ $hour['dim_d'] =
$this->db->f('dim_d');
+ $hour['wo_hour_cat'] =
$this->db->f('category');
+ $hour['cat_per_cent'] =
$this->db->f('cat_per_cent');
}
return $hour;
@@ -615,18 +623,19 @@
$value_set=array(
'hours_descr' => $hour['descr'],
- 'remark' =>
$hour['remark'],
- 'billperae' =>
$hour['billperae'],
- 'unit' =>
$hour['unit'],
- 'quantity' =>
$hour['quantity'],
- 'cost' =>
$hour['cost'],
- 'ns3420_id' =>
$hour['ns3420_id'],
- 'tolerance' =>
$hour['tolerance_id'],
+ 'remark' => $hour['remark'],
+ 'billperae' => $hour['billperae'],
+ 'unit' => $hour['unit'],
+ 'quantity' => $hour['quantity'],
+ 'cost' => $hour['cost'],
+ 'ns3420_id' => $hour['ns3420_id'],
+ 'tolerance' =>
$hour['tolerance_id'],
'building_part' =>
$hour['building_part_id'],
- 'dim_d' =>
$hour['dim_d'],
+ 'dim_d' => $hour['dim_d'],
'grouping_id' => $hour['grouping_id'],
'grouping_descr' =>
$hour['grouping_descr'],
- 'category' => $hour['wo_hour_cat']
+ 'category' => $hour['wo_hour_cat'],
+ 'cat_per_cent' => $hour['cat_per_cent']
);
$value_set =
$this->bocommon->validate_db_update($value_set);
Index: property/inc/class.uiwo_hour.inc.php
diff -u property/inc/class.uiwo_hour.inc.php:1.19
property/inc/class.uiwo_hour.inc.php:1.20
--- property/inc/class.uiwo_hour.inc.php:1.19 Thu Mar 9 22:05:09 2006
+++ property/inc/class.uiwo_hour.inc.php Fri Mar 10 09:24:30 2006
@@ -8,7 +8,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package property
* @subpackage project
- * @version $Id: class.uiwo_hour.inc.php,v 1.19 2006/03/09 22:05:09
sigurdne Exp $
+ * @version $Id: class.uiwo_hour.inc.php,v 1.20 2006/03/10 09:24:30
sigurdne Exp $
*/
/**
@@ -345,6 +345,7 @@
'deviation'
=> $deviation,
'result'
=> ($hour['deviation']+$hour['cost']),
'wo_hour_category'
=> $hour['wo_hour_category'],
+ 'cat_per_cent'
=> $hour['cat_per_cent'],
'link_deviation'
=>
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uiwo_hour.deviation&workorder_id='
. $workorder_id . '&hour_id=' . $hour['hour_id']),
'link_edit'
=>
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uiwo_hour.edit&workorder_id='
. $workorder_id . '&hour_id=' . $hour['hour_id']),
'lang_edit_statustext'
=> lang('edit/customise this hour'),
@@ -826,21 +827,21 @@
$data = array
(
'msgbox_data'
=> $GLOBALS['phpgw']->common->msgbox($msgbox_data),
- 'lang_mail'
=> lang('E-Mail'),
- 'lang_update_email'
=> lang('Update email'),
- 'lang_update_email_statustext' =>
lang('Check to update the email-address for this vendor'),
- 'lang_to_email_address_statustext' =>
lang('The address to which this order will be sendt'),
- 'to_email'
=> $to_email,
+ 'lang_mail'
=> lang('E-Mail'),
+ 'lang_update_email'
=> lang('Update email'),
+ 'lang_update_email_statustext'
=> lang('Check to update the email-address for this vendor'),
+ 'lang_to_email_address_statustext'
=> lang('The address to which this order will be sendt'),
+ 'to_email'
=> $to_email,
'email_list'
=> $email_list,
'lang_select_email'
=> lang('Select email'),
'send_order_action'
=>
$GLOBALS['phpgw']->link('/index.php','menuaction='.$this->currentapp.'.uiwo_hour.view&send=true&workorder_id='
. $workorder_id . '&show_details=' . $show_details),
- 'lang_no_history'
=> lang('No history'),
- 'lang_history'
=> lang('History'),
+ 'lang_no_history'
=> lang('No history'),
+ 'lang_history'
=> lang('History'),
'workorder_history'
=> $workorder_history,
- 'table_header_history' =>
$table_header_history,
+ 'table_header_history'
=> $table_header_history,
'email_data'
=> $email_data,
- 'no_email'
=> $no_email,
+ 'no_email'
=> $no_email,
'table_send'
=> $table_send,
'table_done'
=> $table_done
);
@@ -1378,42 +1379,48 @@
$data = array
(
- 'msgbox_data'
=> $GLOBALS['phpgw']->common->msgbox($msgbox_data),
- 'lang_select_all'
=> lang('Select All'),
- 'img_check'
=>
$GLOBALS['phpgw']->common->get_image_path($this->currentapp).'/check.gif',
- 'check_source'
=> './'.$this->currentapp.'/inc/check.js',
+ 'msgbox_data' =>
$GLOBALS['phpgw']->common->msgbox($msgbox_data),
+ 'lang_select_all' =>
lang('Select All'),
+ 'img_check' =>
$GLOBALS['phpgw']->common->get_image_path($this->currentapp).'/check.gif',
+ 'check_source' =>
'./'.$this->currentapp.'/inc/check.js',
- 'template_id'
=> $template_id,
- 'form_action'
=> $GLOBALS['phpgw']->link('/index.php',$link_data),
+ 'template_id' =>
$template_id,
+ 'form_action' =>
$GLOBALS['phpgw']->link('/index.php',$link_data),
'lang_add_statustext' =>
lang('Add the selected items'),
- 'lang_add'
=> lang('Add'),
- 'link_delete'
=> $GLOBALS['phpgw']->link('/index.php',$link_data_delete),
+ 'lang_add' =>
lang('Add'),
+ 'link_delete' =>
$GLOBALS['phpgw']->link('/index.php',$link_data_delete),
- 'function'
=> 'template',
- 'links'
=> $links,
- 'allrows'
=> $this->allrows,
- 'allow_allrows'
=> true,
- 'start_record'
=> $this->start,
- 'record_limit'
=> $record_limit,
- 'num_records'
=> count($template_list),
- 'all_records'
=> $this->bo->total_records,
- 'link_url'
=> $GLOBALS['phpgw']->link('/index.php',$link_data_nextmatch),
- 'img_path'
=> $GLOBALS['phpgw']->common->get_image_path('phpgwapi','default'),
- 'select_action'
=> $GLOBALS['phpgw']->link('/index.php',$link_data),
-
- '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'),
- 'workorder_data'
=> $common_data['workorder_data'],
+ 'function' =>
'template',
+ 'links' =>
$links,
+ 'allrows' =>
$this->allrows,
+ 'allow_allrows' => true,
+ 'start_record' =>
$this->start,
+ 'record_limit' =>
$record_limit,
+ 'num_records' =>
count($template_list),
+ 'all_records' =>
$this->bo->total_records,
+ 'link_url' =>
$GLOBALS['phpgw']->link('/index.php',$link_data_nextmatch),
+ 'img_path' =>
$GLOBALS['phpgw']->common->get_image_path('phpgwapi','default'),
+ 'select_action' =>
$GLOBALS['phpgw']->link('/index.php',$link_data),
+
+ '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'),
+ 'workorder_data' =>
$common_data['workorder_data'],
'table_header_template_hour' =>
$table_header_template_hour,
- 'values_template_hour'
=> $content_template_hour,
+ 'values_template_hour' =>
$content_template_hour,
'total_hours_records' =>
$common_data['total_hours_records'],
'lang_total_records' =>
lang('Total records'),
- 'table_header_hour'
=> $common_data['table_header'],
- 'values_hour'
=> $common_data['content'],
- 'table_sum'
=> $common_data['table_sum'],
- 'table_done'
=> $table_done
+ 'table_header_hour' =>
$common_data['table_header'],
+ 'values_hour' =>
$common_data['content'],
+ 'table_sum' =>
$common_data['table_sum'],
+ 'table_done' =>
$table_done,
+ 'lang_wo_hour_category' =>
lang('category'),
+ 'lang_select_wo_hour_category' =>
lang('no category'),
+ 'wo_hour_cat_list' =>
$this->bocommon->select_wo_hours_category_list($values['wo_hour_cat']),
+ 'lang_cat_per_cent_statustext' =>
lang('the percentage of the category'),
+ 'value_cat_per_cent' =>
$values['cat_per_cent'],
+ 'lang_per_cent' =>
lang('Per Cent')
);
//_debug_array($data);
@@ -1592,6 +1599,9 @@
'lang_wo_hour_category' =>
lang('category'),
'lang_select_wo_hour_category' =>
lang('no category'),
'wo_hour_cat_list' =>
$this->bocommon->select_wo_hours_category_list($values['wo_hour_cat']),
+ 'lang_cat_per_cent_statustext' =>
lang('the percentage of the category'),
+ 'value_cat_per_cent' =>
$values['cat_per_cent'],
+ 'lang_per_cent' =>
lang('Per Cent')
);
$appname
= lang('Workorder');
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] property/inc class.bowo_hour.inc.php class.sowo...,
Sigurd Nes <=