X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=profile_edit.php;h=ce20f4a5299ab97090d8b5074a07a93d70bf86fb;hb=d5d78055d87535ec75bcde0c10260882b9839b8c;hp=d4036ec5c44ef5ebfafe4cdbc34ae56a2efe1d1c;hpb=eb14c12d3be2cd31e20988b6abf7585f6af0b34d;p=timetracker.git diff --git a/profile_edit.php b/profile_edit.php index d4036ec5..ce20f4a5 100644 --- a/profile_edit.php +++ b/profile_edit.php @@ -50,7 +50,6 @@ if ($request->isPost()) { if ($user->canManageTeam()) { $cl_team = trim($request->getParameter('team_name')); - $cl_address = trim($request->getParameter('address')); $cl_currency = trim($request->getParameter('currency')); if (!$cl_currency) $cl_currency = CURRENCY_DEFAULT; $cl_lang = $request->getParameter('lang'); @@ -67,6 +66,7 @@ if ($request->isPost()) { $cl_clients = $request->getParameter('clients'); $cl_client_required = $request->getParameter('client_required'); $cl_invoices = $request->getParameter('invoices'); + $cl_paid_status = $request->getParameter('paid_status'); $cl_custom_fields = $request->getParameter('custom_fields'); $cl_expenses = $request->getParameter('expenses'); $cl_tax_expenses = $request->getParameter('tax_expenses'); @@ -81,7 +81,6 @@ if ($request->isPost()) { $cl_email = $user->email; if ($user->canManageTeam()) { $cl_team = $user->team; - $cl_address = $user->address; $cl_currency = ($user->currency == ''? CURRENCY_DEFAULT : $user->currency); $cl_lang = $user->lang; $cl_decimal_mark = $user->decimal_mark; @@ -101,6 +100,7 @@ if ($request->isPost()) { $cl_clients = in_array('cl', $plugins); $cl_client_required = in_array('cm', $plugins); $cl_invoices = in_array('iv', $plugins); + $cl_paid_status = in_array('ps', $plugins); $cl_custom_fields = in_array('cf', $plugins); $cl_expenses = in_array('ex', $plugins); $cl_tax_expenses = in_array('et', $plugins); @@ -120,7 +120,6 @@ if (!$auth->isPasswordExternal()) { $form->addInput(array('type'=>'text','maxlength'=>'100','name'=>'email','value'=>$cl_email,'enable'=>$can_change_login)); if ($user->canManageTeam()) { $form->addInput(array('type'=>'text','maxlength'=>'200','name'=>'team_name','value'=>$cl_team)); - $form->addInput(array('type'=>'textarea','name'=>'address','maxlength'=>'255','style'=>'width: 350px;','cols'=>'55','rows'=>'4','value'=>$cl_address)); $form->addInput(array('type'=>'text','maxlength'=>'7','name'=>'currency','value'=>$cl_currency)); $DECIMAL_MARK_OPTIONS = array(array('id'=>'.','name'=>'.'),array('id'=>',','name'=>',')); $form->addInput(array('type'=>'combobox','name'=>'decimal_mark','style'=>'width: 150px','data'=>$DECIMAL_MARK_OPTIONS,'datakeys'=>array('id','name'),'value'=>$cl_decimal_mark, @@ -194,6 +193,7 @@ if ($user->canManageTeam()) { $form->addInput(array('type'=>'checkbox','name'=>'client_required','value'=>$cl_client_required)); $form->addInput(array('type'=>'checkbox','name'=>'invoices','value'=>$cl_invoices)); + $form->addInput(array('type'=>'checkbox','name'=>'paid_status','value'=>$cl_paid_status)); $form->addInput(array('type'=>'checkbox','name'=>'custom_fields','value'=>$cl_custom_fields,'onchange'=>'handlePluginCheckboxes()')); $form->addInput(array('type'=>'checkbox','name'=>'expenses','value'=>$cl_expenses,'onchange'=>'handlePluginCheckboxes()')); $form->addInput(array('type'=>'checkbox','name'=>'tax_expenses','value'=>$cl_tax_expenses)); @@ -222,7 +222,6 @@ if ($request->isPost()) { if (!ttValidEmail($cl_email, true)) $err->add($i18n->getKey('error.field'), $i18n->getKey('label.email')); if ($user->canManageTeam()) { if (!ttValidString($cl_team, true)) $err->add($i18n->getKey('error.field'), $i18n->getKey('label.team_name')); - if (!ttValidString($cl_address, true)) $err->add($i18n->getKey('error.field'), $i18n->getKey('label.address')); if (!ttValidString($cl_currency, true)) $err->add($i18n->getKey('error.field'), $i18n->getKey('label.currency')); if ($user->isManager()) { if (!ttValidEmail($cl_bcc_email, true)) $err->add($i18n->getKey('error.field'), $i18n->getKey('label.bcc')); @@ -243,6 +242,8 @@ if ($request->isPost()) { $plugins .= ',cm'; if ($cl_invoices) $plugins .= ',iv'; + if ($cl_paid_status) + $plugins .= ',ps'; if ($cl_custom_fields) $plugins .= ',cf'; if ($cl_expenses) @@ -259,7 +260,6 @@ if ($request->isPost()) { $update_result = ttTeamHelper::update($user->team_id, array( 'name' => $cl_team, - 'address' => $cl_address, 'currency' => $cl_currency, 'lang' => $cl_lang, 'decimal_mark' => $cl_decimal_mark,