コード例 #1
0
         define("NO_CSS", true);
         define("NO_JS", true);
     }
     $obj = new $class_type($object["id"]);
     if ($loadedModel->isHiddenField($field)) {
         continue;
     }
     echo "<td class='" . ($loadedModel->isMobileHidden($field) ? "mobileHidden" : "") . "'>";
     $val_col = SystemHelper::applyDataMask($field_value, $loadedModel->getDataTypeForField($field));
     if ($loadedModel->isOpenerLink($field) && isset($obj->getActionOptions()["edit"])) {
         $edit_opt = $obj->getActionOptions()["edit"];
         $data_popup = array('popup_title' => $edit_opt['popup_title']);
         if (isset($edit_opt['popup_width'])) {
             $data_popup['popup_width'] = $edit_opt['popup_width'];
         }
         echo SystemHelper::addPopupActionLink(array('label' => $val_col, 'url' => $edit_opt['url'], 'data' => $data_popup));
     } else {
         echo $val_col;
     }
     echo "</td>";
 }
 echo "<td class='actionColumn'>";
 if (isset($obj->getActionOptions()["actions"])) {
     foreach ($obj->getActionOptions()["actions"] as $index => $action) {
         $perm_name = isset($action['permName']) && !empty($action['permName']) ? $action['permName'] : $obj->getType() . '_action_' . $index;
         if (!Permission::havePermission($perm_name)) {
             unset($obj->getActionOptions["actions"][$index]);
         }
     }
     SystemHelper::addDropdown(array('icon' => 'ls-ico-cog', 'options' => $obj->getActionOptions()["actions"]));
 }