X7ROOT File Manager
Current Path:
/home/gfecatvj/sites/restate/vendor/maatwebsite/excel/src
home
/
gfecatvj
/
sites
/
restate
/
vendor
/
maatwebsite
/
excel
/
src
/
📁
..
📄
Cell.php
(2.18 KB)
📄
ChunkReader.php
(2.67 KB)
📁
Concerns
📁
Console
📄
DefaultValueBinder.php
(574 B)
📄
DelegatedMacroable.php
(730 B)
📁
Events
📄
Excel.php
(4.75 KB)
📄
ExcelServiceProvider.php
(2.8 KB)
📁
Exceptions
📄
Exporter.php
(1.51 KB)
📁
Facades
📁
Factories
📁
Fakes
📁
Files
📁
Filters
📄
HasEventBus.php
(1.25 KB)
📄
HeadingRowImport.php
(955 B)
📁
Helpers
📄
Importer.php
(1.53 KB)
📁
Imports
📁
Jobs
📄
MappedReader.php
(1.26 KB)
📁
Mixins
📄
QueuedWriter.php
(6.01 KB)
📄
Reader.php
(12.03 KB)
📄
RegistersCustomConcerns.php
(1.1 KB)
📄
Row.php
(1.82 KB)
📄
Sheet.php
(18.05 KB)
📁
Transactions
📁
Validators
📄
Writer.php
(4.95 KB)
Editing: Row.php
<?php namespace Maatwebsite\Excel; use Illuminate\Support\Collection; use PhpOffice\PhpSpreadsheet\Worksheet\Row as SpreadsheetRow; class Row { use DelegatedMacroable; /** * @var array */ protected $headingRow = []; /** * @var SpreadsheetRow */ private $row; /** * @param SpreadsheetRow $row * @param array $headingRow */ public function __construct(SpreadsheetRow $row, array $headingRow = []) { $this->row = $row; $this->headingRow = $headingRow; } /** * @return SpreadsheetRow */ public function getDelegate(): SpreadsheetRow { return $this->row; } /** * @param null $nullValue * @param bool $calculateFormulas * @param bool $formatData * * @return Collection */ public function toCollection($nullValue = null, $calculateFormulas = false, $formatData = true): Collection { return new Collection($this->toArray($nullValue, $calculateFormulas, $formatData)); } /** * @param null $nullValue * @param bool $calculateFormulas * @param bool $formatData * * @return array */ public function toArray($nullValue = null, $calculateFormulas = false, $formatData = true) { $cells = []; $i = 0; foreach ($this->row->getCellIterator() as $cell) { $value = (new Cell($cell))->getValue($nullValue, $calculateFormulas, $formatData); if (isset($this->headingRow[$i])) { $cells[$this->headingRow[$i]] = $value; } else { $cells[] = $value; } $i++; } return $cells; } /** * @return int */ public function getIndex(): int { return $this->row->getRowIndex(); } }
Upload File
Create Folder