if ($category != $field->getValue('cat_name') && (strlen($inventory->getValue($field->getValue('inf_name_intern'))) > 0 || $field->getValue('inf_type') === 'CHECKBOX')) { if ($category !== '') { // new category then show last form and close div container $page->addHtml($form->show(false)); $page->addHtml('</div></div>'); } $category = $field->getValue('cat_name'); $page->addHtml(' <div class="panel panel-default" id="' . $field->getValue('cat_name') . '_data_panel"> <div class="panel-heading">' . $field->getValue('cat_name') . '</div> <div class="panel-body">'); // create a static form $form = new HtmlForm('profile_user_data_form', null); } // show html of field, if user has a value for that field or it's a checkbox field if (strlen($inventory->getValue($field->getValue('inf_name_intern'))) > 0 || $field->getValue('inf_type') === 'CHECKBOX') { $field = getFieldCode($field->getValue('inf_name_intern'), $inventory); if (strlen($field['value']) > 0) { $form->addStaticControl('address', $field['label'], $field['value']); } } } } if ($category !== '') { // new category then show last form and close div container $page->addHtml($form->show(false)); $page->addHtml('</div></div>'); } // show information about user who creates the recordset and changed it $page->addHtml(admFuncShowCreateChangeInfoById($inventory->getValue('inv_usr_id_create'), $inventory->getValue('inv_timestamp_create'), $inventory->getValue('inv_usr_id_change'), $inventory->getValue('inv_timestamp_change'))); $page->show();
// new category then show last form and close div container $page->addHtml($form->show(false)); $page->addHtml('</div></div>'); } $category = $field->getValue('cat_name'); // @ptabaden: Added h3 $page->addHtml(' <div class="panel panel-default" id="' . $field->getValue('cat_name_intern') . '_data_panel"> <div class="panel-heading"><h3>' . $field->getValue('cat_name') . '</h3></div> <div class="panel-body">'); // create a static form $form = new HtmlForm('profile_' . $field->getValue('cat_name_intern') . '_form', null); } // show html of field, if user has a value for that field or it's a checkbox field if (strlen($user->getValue($field->getValue('usf_name_intern'))) > 0 || $field->getValue('usf_type') === 'CHECKBOX') { $field = getFieldCode($field->getValue('usf_name_intern'), $user); if (strlen($field['value']) > 0) { $form->addStaticControl('address', $field['label'], $field['value']); } } } } if ($category !== '') { // new category then show last form and close div container $page->addHtml($form->show(false)); $page->addHtml('</div></div>'); } if ($gPreferences['profile_show_roles'] == 1) { // ******************************************************************************* // Authorizations block // *******************************************************************************