diff --git a/infolog/inc/class.boinfolog.inc.php b/infolog/inc/class.boinfolog.inc.php index 2f453c79fd..f44da85b0d 100644 --- a/infolog/inc/class.boinfolog.inc.php +++ b/infolog/inc/class.boinfolog.inc.php @@ -54,6 +54,19 @@ /* 'confirm' => 'confirm','reject' => 'reject','email' => 'email', 'fax' => 'fax' no implemented so far */ ) ); + $this->status = array( + 'defaults' => array( + 'task' => 'ongoing', 'phone' => 'call', 'note' => 'done'), + 'task' => array( + 'offer' => 'offer','ongoing' => 'ongoing', + 'done' => 'done', 'billed' => 'billed' ), + 'phone' => array( + 'call' => 'call','will-call' => 'will-call', + 'done' => 'done', 'billed' => 'billed' ), + 'note' => array( + 'ongoing' => 'ongoing', 'done' => 'done' + )); + $this->so = CreateObject('infolog.soinfolog'); $this->data = &$this->so->data; $this->grants = &$this->so->grants; diff --git a/infolog/inc/class.uiinfolog.inc.php b/infolog/inc/class.uiinfolog.inc.php index f8444561ab..7ffde9d79c 100644 --- a/infolog/inc/class.uiinfolog.inc.php +++ b/infolog/inc/class.uiinfolog.inc.php @@ -738,8 +738,9 @@ $t->set_var('lang_type',lang('Type')); if (!isset($type)) $type = $this->data['info_type']; - $t->set_var('type_list',$sb->getArrayItem('type',$type, - $this->enums['type'])); + if (!$type) $type = 'note'; + $t->set_var('type_list',$html->sbox_submit($sb->getArrayItem( + 'type',$type,$this->enums['type']),True)); $t->set_var('lang_prfrom', lang('From')); if (!isset($from)) $from =$phpgw->strip_html($this->data['info_from']); @@ -782,8 +783,9 @@ $t->set_var('lang_status',lang('Status')); if (!isset($status)) $status = $this->data['info_status']; + if (!$status) $status = $this->bo->status['defaults'][$type]; $t->set_var('status_list',$sb->getArrayItem('status',$status, - $this->enums['status'])); + $this->bo->status[$type])); $t->set_var('lang_priority',lang('Priority')); if (!isset($pri)) $pri = $this->data['info_pri'];