[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [15412] revert to previous
From: |
sigurdne |
Subject: |
[Fmsystem-commits] [15412] revert to previous |
Date: |
Wed, 3 Aug 2016 12:42:30 +0000 (UTC) |
Revision: 15412
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=15412
Author: sigurdne
Date: 2016-08-03 12:42:30 +0000 (Wed, 03 Aug 2016)
Log Message:
-----------
revert to previous
Modified Paths:
--------------
trunk/property/inc/class.uitts.inc.php
Modified: trunk/property/inc/class.uitts.inc.php
===================================================================
--- trunk/property/inc/class.uitts.inc.php 2016-08-03 12:36:58 UTC (rev
15411)
+++ trunk/property/inc/class.uitts.inc.php 2016-08-03 12:42:30 UTC (rev
15412)
@@ -367,7 +367,7 @@
array_push($descr, lang('finnish date'), lang('delay'));
- $custom_cols =
isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ticket_columns'])
? $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ticket_columns']
: array();
+ $custom_cols =
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['ticket_columns'])
? $GLOBALS['phpgw_info']['user']['preferences']['property']['ticket_columns']
: array();
foreach ($custom_cols as $col)
{
@@ -403,7 +403,7 @@
}
$this->bo->update_status(array('status' =>
$new_status), $id);
- if
((isset($this->bo->config->config_data['mailnotification']) &&
$this->bo->config->config_data['mailnotification']) ||
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_notify_me'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_notify_me']
== 1 && $this->bo->fields_updated
+ if
((isset($this->bo->config->config_data['mailnotification']) &&
$this->bo->config->config_data['mailnotification']) ||
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_notify_me'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['tts_notify_me']
== 1 && $this->bo->fields_updated
)
)
{
@@ -433,7 +433,7 @@
// $ticket = $this->bo->read_single($id);
$receipt = $this->bo->update_priority(array('priority'
=> $new_priority), $id);
- if
((isset($this->bo->config->config_data['mailnotification']) &&
$this->bo->config->config_data['mailnotification']) ||
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_notify_me'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_notify_me']
== 1 && $this->bo->fields_updated
+ if
((isset($this->bo->config->config_data['mailnotification']) &&
$this->bo->config->config_data['mailnotification']) ||
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_notify_me'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['tts_notify_me']
== 1 && $this->bo->fields_updated
)
)
{
@@ -535,7 +535,7 @@
$uicols['name'][] = 'entry_date';
$uicols['descr'][] = lang('entry date');
- $custom_cols =
isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ticket_columns'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ticket_columns']
? $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ticket_columns'] :
array();
+ $custom_cols =
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['ticket_columns'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['ticket_columns']
? $GLOBALS['phpgw_info']['user']['preferences']['property']['ticket_columns'] :
array();
$columns = $this->bo->get_columns();
foreach ($custom_cols as $col)
@@ -700,7 +700,7 @@
'list' => $values_combo_box[2]
);
- $filter_tts_assigned_to_me =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_assigned_to_me'];
+ $filter_tts_assigned_to_me =
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_assigned_to_me'];
$values_combo_box[4] =
$this->bocommon->get_user_list_right2('filter', PHPGW_ACL_EDIT, $this->user_id,
$this->acl_location);
array_unshift($values_combo_box[4], array(
@@ -773,7 +773,7 @@
'list' => $buildingpart_list
);
- if
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_branch_list'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_branch_list'] ==
1)
+ if
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_branch_list'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_branch_list'] ==
1)
{
$combos[] = array('type' => 'filter',
'name' => 'branch_id',
@@ -981,7 +981,7 @@
);
}
- if
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_status_link'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_status_link'] ==
'yes' && $this->acl_edit)
+ if
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_status_link'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_status_link'] ==
'yes' && $this->acl_edit)
{
$status['X'] = array
(
@@ -1202,14 +1202,26 @@
}
}
- if (!isset($values['assignedto']))
- {
- $values['assignedto'] =
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['assigntodefault'])
? $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['assigntodefault']
: '');
- }
if (!$values['assignedto'] &&
!$values['group_id'])
{
- $receipt['error'][] = array('msg' =>
lang('Please select a person or a group to handle the ticket !'));
+ $_responsible =
execMethod('property.boresponsible.get_responsible', $values);
+ if (!$_responsible)
+ {
+ $receipt['error'][] =
array('msg' => lang('Please select a person or a group to handle the ticket
!'));
+ }
+ else
+ {
+ if
($GLOBALS['phpgw']->accounts->get($_responsible)->type ==
phpgwapi_account::TYPE_USER)
+ {
+ $values['assignedto'] =
$_responsible;
+ }
+ else
+ {
+ $values['group_id'] =
$_responsible;
+ }
+ }
+ unset($_responsible);
}
if (!isset($values['priority']) ||
!$values['priority'])
@@ -1334,7 +1346,7 @@
'entity_data' => (isset($values['p']) ?
$values['p'] : '')
));
- if
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_me_as_contact'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_me_as_contact']
== 1)
+ if
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_me_as_contact'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_me_as_contact']
== 1)
{
$ticket['contact_id'] =
$GLOBALS['phpgw']->accounts->get($this->account)->person_id;
}
@@ -1350,16 +1362,16 @@
if (!isset($values['assignedto']))
{
- $values['assignedto'] =
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['assigntodefault'])
? $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['assigntodefault']
: '');
+ $values['assignedto'] =
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['assigntodefault'])
? $GLOBALS['phpgw_info']['user']['preferences']['property']['assigntodefault']
: '');
}
if (!isset($values['group_id']))
{
- $values['group_id'] =
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['groupdefault'])
? $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['groupdefault'] :
'');
+ $values['group_id'] =
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['groupdefault'])
? $GLOBALS['phpgw_info']['user']['preferences']['property']['groupdefault'] :
'');
}
if (!isset($values['cat_id']))
{
- $this->cat_id =
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_category'])
? $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_category'] :
'');
+ $this->cat_id =
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_category'])
? $GLOBALS['phpgw_info']['user']['preferences']['property']['tts_category'] :
'');
}
else
{
@@ -1431,7 +1443,7 @@
'lang_no_part_of_town' => lang('No part of
town'),
'cat_select' =>
$this->cats->formatted_xslt_list(array('select_name' => 'values[cat_id]',
'selected' => $this->cat_id, 'use_acl'
=> $this->_category_acl, 'required' => true)),
- 'pref_send_mail' =>
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_user_mailnotification'])
?
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_user_mailnotification']
: ''),
+ 'pref_send_mail' =>
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_user_mailnotification'])
?
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_user_mailnotification']
: ''),
'fileupload' =>
(isset($this->bo->config->config_data['fmttsfileupload']) ?
$this->bo->config->config_data['fmttsfileupload'] : ''),
'tabs' =>
phpgwapi_jquery::tabview_generate($tabs, $active_tab)
);
@@ -1656,7 +1668,7 @@
$receipt = $this->bo->update_ticket($values,
$id, $receipt, $values_attribute);
if ((isset($values['send_mail']) &&
$values['send_mail']) ||
(isset($this->bo->config->config_data['mailnotification']) &&
$this->bo->config->config_data['mailnotification'] && $this->bo->fields_updated
- ) ||
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_notify_me'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_notify_me']
== 1 && $this->bo->fields_updated
+ ) ||
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_notify_me'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['tts_notify_me']
== 1 && $this->bo->fields_updated
)
)
{
@@ -1919,15 +1931,15 @@
// approval
$supervisor_id = 0;
- if
(isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['approval_from'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['approval_from'])
+ if
(isset($GLOBALS['phpgw_info']['user']['preferences']['property']['approval_from'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['approval_from'])
{
- $supervisor_id =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['approval_from'];
+ $supervisor_id =
$GLOBALS['phpgw_info']['user']['preferences']['property']['approval_from'];
}
$need_approval =
isset($this->bo->config->config_data['workorder_approval']) ?
$this->bo->config->config_data['workorder_approval'] : '';
$supervisor_email =
$this->get_supervisor_email($supervisor_id, $need_approval);
- // approval
+ // approval
}
$vendor_email = array();
@@ -1991,7 +2003,7 @@
{
$user_name =
$GLOBALS['phpgw_info']['user']['fullname'];
}
- $ressursnr =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ressursnr'];
+ $ressursnr =
$GLOBALS['phpgw_info']['user']['preferences']['property']['ressursnr'];
$location = lang('Address') . ":
{$ticket['address']}<br>";
$address_element =
$this->bo->get_address_element($ticket['location_code']);
@@ -2020,9 +2032,9 @@
$order_id = $ticket['order_id'];
- $user_phone =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['cellphone'];
- $user_email =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['email'];
- $order_email_template =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['order_email_template'];
+ $user_phone =
$GLOBALS['phpgw_info']['user']['preferences']['property']['cellphone'];
+ $user_email =
$GLOBALS['phpgw_info']['user']['preferences']['property']['email'];
+ $order_email_template =
$GLOBALS['phpgw_info']['user']['preferences']['property']['order_email_template'];
$body = nl2br(str_replace(array
(
@@ -2125,7 +2137,7 @@
}
$coordinator_name =
$GLOBALS['phpgw_info']['user']['fullname'];
- $coordinator_email =
"{$coordinator_name}<{$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['email']}>";
+ $coordinator_email =
"{$coordinator_name}<{$GLOBALS['phpgw_info']['user']['preferences']['property']['email']}>";
$cc = '';
$bcc = $coordinator_email;
if
(isset($contact_data['value_contact_email']) &&
$contact_data['value_contact_email'])
@@ -2169,7 +2181,7 @@
if (isset($values['approval']) && $values['approval']
&& $this->bo->config->config_data['workorder_approval'])
{
$coordinator_name =
$GLOBALS['phpgw_info']['user']['fullname'];
- $coordinator_email =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['email'];
+ $coordinator_email =
$GLOBALS['phpgw_info']['user']['preferences']['property']['email'];
$subject = lang(Approval) . ": " .
$ticket['order_id'];
$message = '<a href ="' .
$GLOBALS['phpgw']->link('/index.php', array('menuaction' =>
'property.uitts.view',
@@ -2659,7 +2671,7 @@
);
$cat_select['disabled'] = true;
$cat_select['hidden_value'] = $ticket['cat_id'];
-//_debug_array($cat_select);die();
+//_debug_array($cat_select);die();
}
@@ -2695,7 +2707,7 @@
$tabs['history'] = array('label' => lang('History'),
'link' => '#history');
$active_tab = 'general';
- $unspsc_code = $ticket['unspsc_code'] ?
$ticket['unspsc_code'] :
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['unspsc_code'];
+ $unspsc_code = $ticket['unspsc_code'] ?
$ticket['unspsc_code'] :
$GLOBALS['phpgw_info']['user']['preferences']['property']['unspsc_code'];
$enable_order_service_id =
isset($config->config_data['enable_order_service_id']) &&
$config->config_data['enable_order_service_id'] ? true : false;
$enable_unspsc =
isset($config->config_data['enable_unspsc']) &&
$config->config_data['enable_unspsc'] ? true : false;
$data = array(
@@ -2778,7 +2790,7 @@
'add_to_project_link' => $add_to_project_link,
// 'lang_name'
=> lang('name'),
'contact_phone' => $ticket['contact_phone'],
- 'pref_send_mail' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_user_mailnotification'])
?
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_user_mailnotification']
: '',
+ 'pref_send_mail' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_user_mailnotification'])
?
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_user_mailnotification']
: '',
'fileupload' =>
isset($this->bo->config->config_data['fmttsfileupload']) ?
$this->bo->config->config_data['fmttsfileupload'] : '',
'multiple_uploader' => true,
'fileuploader_action' =>
"{menuaction:'property.fileuploader.add',"
@@ -2793,8 +2805,8 @@
'lang_file_action_statustext' => lang('Check to
delete file'),
'lang_upload_file' => lang('Upload file'),
'lang_file_statustext' => lang('Select file to
upload'),
- 'textareacols' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['textareacols'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['textareacols'] ?
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['textareacols'] : 60,
- 'textarearows' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['textarearows'])
&& $GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['textarearows'] ?
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['textarearows'] : 6,
+ 'textareacols' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['textareacols'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['textareacols'] ?
$GLOBALS['phpgw_info']['user']['preferences']['property']['textareacols'] : 60,
+ 'textarearows' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['textarearows'])
&& $GLOBALS['phpgw_info']['user']['preferences']['property']['textarearows'] ?
$GLOBALS['phpgw_info']['user']['preferences']['property']['textarearows'] : 6,
// 'order_cat_list'
=> $order_catetory,
'building_part_list' => array('options' =>
$this->bocommon->select_category_list(array(
'type' => 'building_part',
'selected' => $ticket['building_part'], 'order' => 'id',
@@ -2805,7 +2817,7 @@
'tax_code_list' => array('options' =>
$this->bocommon->select_category_list(array(
'type' => 'tax', 'selected' =>
$ticket['tax_code'], 'order' => 'id',
'id_in_name' => 'num'))),
- 'branch_list' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_branch_list'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['tts_branch_list'] ==
1 ? array(
+ 'branch_list' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_branch_list'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_branch_list'] ==
1 ? array(
'options' =>
execMethod('property.boproject.select_branch_list', $values['branch_id'])) : '',
'preview_html' =>
"javascript:preview_html($id)",
'preview_pdf' => "javascript:preview_pdf($id)",
@@ -2913,7 +2925,7 @@
}
else
{
- $supervisor_id =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['approval_from'];
+ $supervisor_id =
$GLOBALS['phpgw_info']['user']['preferences']['property']['approval_from'];
}
return $this->get_supervisor_email($supervisor_id);
@@ -3303,7 +3315,7 @@
$pdf->selectFont(PHPGW_API_INC .
'/pdf/fonts/Helvetica-Bold.afm');
$pdf->ezText(lang('descr') . ':', 20);
$pdf->selectFont(PHPGW_API_INC .
'/pdf/fonts/Helvetica.afm');
- $ressursnr =
$GLOBALS['phpgw_info']['user']['preferences']['helpdesk']['ressursnr'];
+ $ressursnr =
$GLOBALS['phpgw_info']['user']['preferences']['property']['ressursnr'];
$contact_data =
$this->bocommon->initiate_ui_contact_lookup(array(
'contact_id' => $ticket['contact_id'],
@@ -3327,7 +3339,7 @@
$pdf->ezText($ticket['order_descr'], 14);
$pdf->ezSetDy(-20);
$pdf->selectFont(PHPGW_API_INC .
'/pdf/fonts/Helvetica-Bold.afm');
- $pdf->ezText('Kontakt på bygget:', 14);
+ $pdf->ezText('Kontakt på bygget:', 14);
$pdf->selectFont(PHPGW_API_INC .
'/pdf/fonts/Helvetica.afm');
$pdf->ezText($contact_name, 14);
$pdf->ezText($contact_email, 14);
@@ -3335,7 +3347,7 @@
$pdf->ezSetDy(-20);
$pdf->selectFont(PHPGW_API_INC .
'/pdf/fonts/Helvetica-Bold.afm');
- $pdf->ezText("Faktura må merkes med ordrenummer:
{$ticket['order_id']} og ressursnr.:{$ressursnr}", 14);
+ $pdf->ezText("Faktura må merkes med ordrenummer:
{$ticket['order_id']} og ressursnr.:{$ressursnr}", 14);
$pdf->selectFont(PHPGW_API_INC .
'/pdf/fonts/Helvetica.afm');
if ($content)
{
@@ -3410,7 +3422,7 @@
}
/**
- *
+ *
*/
private function _insert_custom_js()
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [15412] revert to previous,
sigurdne <=