<th><?php echo $property["pages"]["security/accounts_admin"]["SEGURIDAD_ADMIN_CUENTAS_TBL_HDR_CREATION_DATE"]; ?> </th> <th><?php echo $property["pages"]["security/accounts_admin"]["OPCIONES"]; ?> </th> </tr> </thead> <tbody> <?php foreach ($list as $item) { $rolString = ''; $roles = $user->getListUserRoles($item['pk_id_user']); foreach ($roles as $rol) { $rolString .= ',' . $rol['role']; } ?> <tr class="odd gradeX"> <td><?php echo $item['user']; ?> </td> <td><?php echo $rolString; ?> </td> <td><?php
<?php Forms::printLabel($property["pages"]["security/new_user"]["ROL_LBL"]); ?> </td> <td class="col2"> <?php $rol = new Rol($db); $listRol = $rol->getListRol(); $itemsSelect = array(); $rolArray = array(); $optionData = array(); $optionData['LIST_VALUES'] = array(); if ($action == 'EDIT' || $action == 'PREVIEW') { $roles = $user->getListUserRoles($data['pk_id_user']); foreach ($roles as $rol) { $optionData['LIST_VALUES'][] = $rol['pk_id_role']; } } $optionData['LIST_OPTIONS'] = array(); foreach ($listRol as $rolItem) { $itemsSelect[$rolItem['pk_id_role']] = $rolItem['role']; $NAME = "ROL_" . $rolItem['pk_id_role']; $VALUE = $rolItem['pk_id_role']; $LABEL = $rolItem['role'] . "<br>"; $optionData['LIST_OPTIONS'][] = array('NAME' => $NAME, 'VALUE' => $VALUE, 'LABEL' => $LABEL); } Forms::printInput('MULTI_CHECKBOX', 'ROL', $rolArray, '', array(), $optionData); ?>