Changeset View
Changeset View
Standalone View
Standalone View
src/infrastructure/export/PhabricatorExportField.php
| Show All 26 Lines | abstract class PhabricatorExportField | ||||
| public function getTextValue($value) { | public function getTextValue($value) { | ||||
| return (string)$this->getNaturalValue($value); | return (string)$this->getNaturalValue($value); | ||||
| } | } | ||||
| public function getNaturalValue($value) { | public function getNaturalValue($value) { | ||||
| return $value; | return $value; | ||||
| } | } | ||||
| public function getPHPExcelValue($value) { | |||||
| return $this->getTextValue($value); | |||||
| } | |||||
| /** | |||||
| * @phutil-external-symbol class PHPExcel_Cell_DataType | |||||
| */ | |||||
| public function formatPHPExcelCell($cell, $style) { | |||||
| $cell->setDataType(PHPExcel_Cell_DataType::TYPE_STRING); | |||||
| } | |||||
| public function getCharacterWidth() { | |||||
| return 24; | |||||
amckinley: Magic constant? | |||||
Not Done Inline ActionsThis is "roughly a reasonable width for most types of data that we export". I can put it in a constant or something, but nothing else should ever refer to it and it's still inherently kind of magical. epriestley: This is "roughly a reasonable width for most types of data that we export". I can put it in a… | |||||
| } | |||||
| } | } | ||||
Magic constant?