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


PHP Grid::formatRow方法代碼示例

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


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

示例1: formatRow

 function formatRow()
 {
     parent::formatRow();
     $v = $this->add('View', 'v' . $this->current_row['id'], 'content')->set($this->current_row['name']);
     $v->js('click', array($this->map->js()->rvadym_gmap()->polygonsArray(null), $this->map->js()->rvadym_gmap()->polygonsCoords(null), $this->map->js()->rvadym_gmap()->drawPolygons($this->current_row['draw'])));
     $this->current_row_html['name'] = $v->getHTML();
 }
開發者ID:rvadym,項目名稱:gmap,代碼行數:7,代碼來源:Draw.php

示例2: formatRow

 function formatRow()
 {
     /* -------------------------------------
        |
        |   get additional data from DB
        |
        */
     // Get data about sender
     if ($from_model = $this->config->getTypeModelClassName($this->current_row['from_type'])) {
         $from = $this->add($from_model)->tryLoad($this->current_row['from_id']);
     } else {
         $from['name'] = Model_Message::getFromTypes($this->current_row['from_type']);
     }
     // get data about receiver
     if ($to_model = $this->config->getTypeModelClassName($this->current_row['to_type'])) {
         $to = $this->add($to_model)->tryLoad($this->current_row['to_id']);
     } else {
         $to['name'] = Model_Message::getToTypes($this->current_row['to_type']);
     }
     /* -------------------------------------
        |
        |           compile HTML
        |
        */
     $mixed_html = '';
     $message_model = $this->config->getMessageModelClassName();
     $mixed_html = $mixed_html . '<div class="' . $this->config->get('message-from-class') . '"><strong>From:</strong> ' . $from['name'] . ' (' . $message_model::getFromTypes($this->current_row['from_type']) . ') ' . ($this->current_row['from_is_deleted'] ? '*deleted*' : '') . '</div>';
     $mixed_html = $mixed_html . '<div class="' . $this->config->get('message-to-class') . '"><strong>To:</strong> ' . $to['name'] . ' (' . $message_model::getToTypes($this->current_row['to_type']) . ') ' . ($this->current_row['to_is_deleted'] ? '*deleted*' : '') . '</div>';
     $mixed_html = $mixed_html . '<div class="' . $this->config->get('message-text-class') . '">' . $this->current_row['text'] . '</div>';
     $this->current_row_html['message'] = $mixed_html;
     parent::formatRow();
 }
開發者ID:atk4,項目名稱:messages,代碼行數:32,代碼來源:Messages.php

示例3: formatRow

 function formatRow()
 {
     parent::formatRow();
     if ($this->owner instanceof \CRUD) {
         if (!$this->current_row_html['edit']) {
             if ($this->row_edit) {
                 $this->current_row_html['edit'] = '<a class="table-link pb_edit" href="#" data-id="' . $this->model->id . '"><span class="fa-stack"><i class="fa fa-square fa-stack-2x"></i><i class="fa fa-pencil fa-stack-1x fa-inverse"></i></span></a>';
             } else {
                 $this->current_row_html['edit'] = '<span class="fa-stack table-link"><i class="fa fa-square fa-stack-2x"></i><i class="fa fa-pencil fa-stack-1x fa-inverse"></i></span>';
             }
         }
         if (!$this->current_row_html['delete']) {
             if ($this->row_delete) {
                 $this->current_row_html['delete'] = '<a class="table-link danger do-delete" href="#" data-id="' . $this->model->id . '"><span class="fa-stack"><i class="fa fa-square fa-stack-2x"></i><i class="fa fa-trash-o fa-stack-1x fa-inverse"></i></span></a>';
             } else {
                 $this->current_row_html['delete'] = '<span class="table-link fa-stack"><i class="fa fa-square fa-stack-2x"></i><i class="fa fa-trash-o fa-stack-1x fa-inverse"></i></span>';
             }
         }
     }
 }
開發者ID:xepan,項目名稱:base,代碼行數:20,代碼來源:Grid.php


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