當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Reports::getRequiredFieldForReport方法代碼示例

本文整理匯總了PHP中Reports::getRequiredFieldForReport方法的典型用法代碼示例。如果您正苦於以下問題:PHP Reports::getRequiredFieldForReport方法的具體用法?PHP Reports::getRequiredFieldForReport怎麽用?PHP Reports::getRequiredFieldForReport使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Reports的用法示例。


在下文中一共展示了Reports::getRequiredFieldForReport方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: setWidgetsOptions

 /**
  * Sets the different variables in charge of storing the different dynamic
  * fields to be rendered on the report builder page
  * @param string $name the report name
  */
 private function setWidgetsOptions($name)
 {
     // Get the list of dynamicaly rendered fields depending the report targeted
     $this->widgets = Reports::getRequiredFieldForReport($name);
     // Get the list of options for these dynamicaly rendered fields
     $this->widgets_options = Reports::getRequiredFieldForReportOptions($name);
     // Count the ones that are dedicated to be set on a second line
     $this->widgets_second_line_count = 0;
     foreach (array_keys($this->widgets) as $widget_name) {
         if (isset($this->widgets_options[$widget_name]) && !empty($this->widgets_options[$widget_name]['second_line']) && $this->widgets_options[$widget_name]['second_line']) {
             $this->widgets_second_line_count += 1;
         }
     }
 }
開發者ID:naturalsciences,項目名稱:Darwin,代碼行數:19,代碼來源:actions.class.php

示例2: foreach

        <th></th>
      </tr>
    </thead>
    <tbody>
    <?php 
    foreach ($reports as $report) {
        ?>
      <tr>
        <td><?php 
        echo Reports::getReportName($report->getName(), $sf_user->getCulture());
        ?>
        <?php 
        echo image_tag('info.png', 'class=more_trk');
        ?>
        <?php 
        $widget = Reports::getRequiredFieldForReport($report->getName());
        ?>
          <ul class="field_change">            
            <?php 
        foreach ($report->getDiffAsArray() as $field => $value) {
            ?>
              <li><strong><?php 
            echo __($widget[$field]);
            ?>
</strong> <?php 
            echo $value;
            ?>
</li>
          <?php 
        }
        ?>
開發者ID:naturalsciences,項目名稱:Darwin,代碼行數:31,代碼來源:_user_report_list.php


注:本文中的Reports::getRequiredFieldForReport方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。