Skip to content

Commit cab116a

Browse files
committed
fix cs
1 parent d4558fe commit cab116a

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

demos/form-control/multiline-crud.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44

55
namespace Atk4\Ui\Demos;
66

7-
/** @var \Atk4\Ui\App $app */
7+
use Atk4\Ui\App;
8+
9+
/** @var App $app */
810
require_once __DIR__ . '/../init-app.php';
911

1012
// TODO

mastercrud-develop/src/MasterCRUD.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ public function initTabs(array $defs, View $view = null)
184184
// $sub_crud->addDecorator($m->title_field, [Table\Column\Link::class, [$t => false, 'path' => $this->getPath($ref)], [$m->table . '_id' => 'id']]);
185185

186186
// Creating url template in order to produce proper url.
187-
$sub_crud->addDecorator($m->title_field, [Table\Column\Link::class, 'url' => $this->getApp()->url(['path' => $this->getPath($ref)]) . '&' . $m->table . '_id=' . '{$id}']);
187+
$sub_crud->addDecorator($m->title_field, [Table\Column\Link::class, 'url' => $this->getApp()->url(['path' => $this->getPath($ref)]) . '&' . $m->table . '_id={$id}']);
188188
}
189189

190190
$this->addActions($sub_crud, $subdef);
@@ -266,7 +266,7 @@ public function addActions(View $crud, array $defs)
266266
if (is_string($action)) {
267267
$crud->menu->addItem($key)->on(
268268
'click',
269-
new JsModal('Executing ' . $key, $this->add([VirtualPage::class])->set(function ($p) use ($key, $crud) {
269+
new JsModal('Executing ' . $key, $this->add([VirtualPage::class])->set(static function ($p) use ($key, $crud) {
270270
// TODO: this does ont work within a tab :(
271271
$p->add(new MethodExecutor($crud->model, $key));
272272
}))
@@ -304,11 +304,11 @@ public function addActions(View $crud, array $defs)
304304
}
305305

306306
if (isset($action[0]) && $action[0] instanceof \Closure) {
307-
$crud->addModalAction($label ?: $key, $key, function ($p, $id) use ($action, $crud) {
307+
$crud->addModalAction($label ?: $key, $key, static function ($p, $id) use ($action, $crud) {
308308
call_user_func($action[0], $p, $crud->model->load($id));
309309
});
310310
} else {
311-
$crud->addModalAction($label ?: $key, $key, function ($p, $id) use ($action, $key, $crud) {
311+
$crud->addModalAction($label ?: $key, $key, static function ($p, $id) use ($action, $key, $crud) {
312312
$p->add(new MethodExecutor($crud->model->load($id), $key, $action));
313313
});
314314
}

mastercrud-develop/src/MethodExecutor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ protected function init(): void
5555
{
5656
parent::init();
5757

58-
$this->console = $this->add([Console::class, 'event' => false]); //->addStyle('display', 'none');
58+
$this->console = $this->add([Console::class, 'event' => false]); // ->addStyle('display', 'none');
5959
$this->console->addStyle('max-height', '50em')->addStyle('overflow', 'scroll');
6060

6161
$this->form = $this->add([Form::class]);

0 commit comments

Comments
 (0)