Completed
Push — master ( 2f0dc6...f53cc0 )
by Jan
05:37
created
src/DataTables/AttachmentDataTable.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     {
83 83
         $dataTable->add('picture', TextColumn::class, [
84 84
             'label' => '',
85
-            'render' => function ($value, Attachment $context) {
85
+            'render' => function($value, Attachment $context) {
86 86
                 if ($context->isPicture()
87 87
                     && !$context->isExternal()
88 88
                     && $this->attachmentHelper->isFileExisting($context)) {
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
 
101 101
         $dataTable->add('name', TextColumn::class, [
102 102
             'label' => $this->translator->trans('attachment.edit.name'),
103
-            'render' => function ($value, Attachment $context) {
103
+            'render' => function($value, Attachment $context) {
104 104
                 //Link to external source
105 105
                 if ($context->isExternal()) {
106 106
                     return sprintf(
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
 
125 125
         $dataTable->add('attachment_type', TextColumn::class, [
126 126
             'field' => 'attachment_type.name',
127
-            'render' => function ($value, Attachment $context) {
127
+            'render' => function($value, Attachment $context) {
128 128
                 return sprintf(
129 129
                     '<a href="%s">%s</a>',
130 130
                     $this->entityURLGenerator->editURL($context->getAttachmentType()),
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
         $dataTable->add('element', TextColumn::class, [
137 137
             'label' => $this->translator->trans('attachment.table.element'),
138 138
             //'propertyPath' => 'element.name',
139
-            'render' => function ($value, Attachment $context) {
139
+            'render' => function($value, Attachment $context) {
140 140
                 return sprintf(
141 141
                     '<a href="%s">%s</a>',
142 142
                     $this->entityURLGenerator->infoURL($context->getElement()),
@@ -150,12 +150,12 @@  discard block
 block discarded – undo
150 150
         ]);
151 151
 
152 152
         $dataTable->add('filesize', TextColumn::class, [
153
-            'render' => function ($value, Attachment $context) {
153
+            'render' => function($value, Attachment $context) {
154 154
                 if ($this->attachmentHelper->isFileExisting($context)) {
155 155
                     return $this->attachmentHelper->getHumanFileSize($context);
156 156
                 }
157 157
                 if ($context->isExternal()) {
158
-                    return '<i>' . $this->translator->trans('attachment.external') . '</i>';
158
+                    return '<i>'.$this->translator->trans('attachment.external').'</i>';
159 159
                 }
160 160
 
161 161
                 return sprintf(
@@ -214,7 +214,7 @@  discard block
 block discarded – undo
214 214
 
215 215
         $dataTable->createAdapter(ORMAdapter::class, [
216 216
             'entity' => Attachment::class,
217
-            'query' => function (QueryBuilder $builder) {
217
+            'query' => function(QueryBuilder $builder) {
218 218
                 $this->getQuery($builder);
219 219
             },
220 220
         ]);
Please login to merge, or discard this patch.
src/Services/ElementTypeNameGenerator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -125,8 +125,8 @@
 block discarded – undo
125 125
     {
126 126
         $type = $this->getLocalizedTypeLabel($entity);
127 127
         if ($use_html) {
128
-            return '<i>' . $type . ':</i> ' . $entity->getName();
128
+            return '<i>'.$type.':</i> '.$entity->getName();
129 129
         }
130
-        return $type . ": " . htmlspecialchars($entity->getName());
130
+        return $type.": ".htmlspecialchars($entity->getName());
131 131
     }
132 132
 }
133 133
\ No newline at end of file
Please login to merge, or discard this patch.