@@ -60,61 +60,79 @@ |
||
60 | 60 | |
61 | 61 | protected function initializeMappings() |
62 | 62 | { |
63 | - $this->mappings['break'] = function ($value) { |
|
63 | + $this->mappings['break'] = function ($value) |
|
64 | + { |
|
64 | 65 | $this->sheetWrapper->getObject()->setBreak($this->object->getCoordinate(), $value); |
65 | 66 | }; |
66 | - $this->mappings['dataType'] = function ($value) { |
|
67 | + $this->mappings['dataType'] = function ($value) |
|
68 | + { |
|
67 | 69 | $this->object->setDataType($value); |
68 | 70 | }; |
69 | - $this->mappings['dataValidation']['allowBlank'] = function ($value) { |
|
71 | + $this->mappings['dataValidation']['allowBlank'] = function ($value) |
|
72 | + { |
|
70 | 73 | $this->object->getDataValidation()->setAllowBlank($value); |
71 | 74 | }; |
72 | - $this->mappings['dataValidation']['error'] = function ($value) { |
|
75 | + $this->mappings['dataValidation']['error'] = function ($value) |
|
76 | + { |
|
73 | 77 | $this->object->getDataValidation()->setError($value); |
74 | 78 | }; |
75 | - $this->mappings['dataValidation']['errorStyle'] = function ($value) { |
|
79 | + $this->mappings['dataValidation']['errorStyle'] = function ($value) |
|
80 | + { |
|
76 | 81 | $this->object->getDataValidation()->setErrorStyle($value); |
77 | 82 | }; |
78 | - $this->mappings['dataValidation']['errorTitle'] = function ($value) { |
|
83 | + $this->mappings['dataValidation']['errorTitle'] = function ($value) |
|
84 | + { |
|
79 | 85 | $this->object->getDataValidation()->setErrorTitle($value); |
80 | 86 | }; |
81 | - $this->mappings['dataValidation']['formula1'] = function ($value) { |
|
87 | + $this->mappings['dataValidation']['formula1'] = function ($value) |
|
88 | + { |
|
82 | 89 | $this->object->getDataValidation()->setFormula1($value); |
83 | 90 | }; |
84 | - $this->mappings['dataValidation']['formula2'] = function ($value) { |
|
91 | + $this->mappings['dataValidation']['formula2'] = function ($value) |
|
92 | + { |
|
85 | 93 | $this->object->getDataValidation()->setFormula2($value); |
86 | 94 | }; |
87 | - $this->mappings['dataValidation']['operator'] = function ($value) { |
|
95 | + $this->mappings['dataValidation']['operator'] = function ($value) |
|
96 | + { |
|
88 | 97 | $this->object->getDataValidation()->setOperator($value); |
89 | 98 | }; |
90 | - $this->mappings['dataValidation']['prompt'] = function ($value) { |
|
99 | + $this->mappings['dataValidation']['prompt'] = function ($value) |
|
100 | + { |
|
91 | 101 | $this->object->getDataValidation()->setPrompt($value); |
92 | 102 | }; |
93 | - $this->mappings['dataValidation']['promptTitle'] = function ($value) { |
|
103 | + $this->mappings['dataValidation']['promptTitle'] = function ($value) |
|
104 | + { |
|
94 | 105 | $this->object->getDataValidation()->setPromptTitle($value); |
95 | 106 | }; |
96 | - $this->mappings['dataValidation']['showDropDown'] = function ($value) { |
|
107 | + $this->mappings['dataValidation']['showDropDown'] = function ($value) |
|
108 | + { |
|
97 | 109 | $this->object->getDataValidation()->setShowDropDown($value); |
98 | 110 | }; |
99 | - $this->mappings['dataValidation']['showErrorMessage'] = function ($value) { |
|
111 | + $this->mappings['dataValidation']['showErrorMessage'] = function ($value) |
|
112 | + { |
|
100 | 113 | $this->object->getDataValidation()->setShowErrorMessage($value); |
101 | 114 | }; |
102 | - $this->mappings['dataValidation']['showInputMessage'] = function ($value) { |
|
115 | + $this->mappings['dataValidation']['showInputMessage'] = function ($value) |
|
116 | + { |
|
103 | 117 | $this->object->getDataValidation()->setShowInputMessage($value); |
104 | 118 | }; |
105 | - $this->mappings['dataValidation']['type'] = function ($value) { |
|
119 | + $this->mappings['dataValidation']['type'] = function ($value) |
|
120 | + { |
|
106 | 121 | $this->object->getDataValidation()->setType($value); |
107 | 122 | }; |
108 | - $this->mappings['merge'] = function ($value) { |
|
123 | + $this->mappings['merge'] = function ($value) |
|
124 | + { |
|
109 | 125 | if (is_int($value)) { |
110 | 126 | $value = PHPExcel_Cell::stringFromColumnIndex($value) . $this->sheetWrapper->getRow(); |
111 | 127 | } |
112 | 128 | $this->sheetWrapper->getObject()->mergeCells(sprintf('%s:%s', $this->object->getCoordinate(), $value)); |
113 | 129 | }; |
114 | - $this->mappings['style'] = function ($value) { |
|
130 | + $this->mappings['style'] = function ($value) |
|
131 | + { |
|
115 | 132 | $this->sheetWrapper->getObject()->getStyle($this->object->getCoordinate())->applyFromArray($value); |
116 | 133 | }; |
117 | - $this->mappings['url'] = function ($value) { |
|
134 | + $this->mappings['url'] = function ($value) |
|
135 | + { |
|
118 | 136 | $this->object->getHyperlink()->setUrl($value); |
119 | 137 | }; |
120 | 138 | } |