@@ -195,7 +195,7 @@ |
||
| 195 | 195 | |
| 196 | 196 | public static function register(?string $searchFormat = null, ?\DateTime $startTime = null, ?\DateTime $endTime = null) |
| 197 | 197 | { |
| 198 | - Container::extensionMethod('addDateTimeRangeButton', function ($container, $name, $label = null, $maxLength = null, $searchFormat = null, \DateTime $startTime = null, \DateTime $endTime = null) { |
|
| 198 | + Container::extensionMethod('addDateTimeRangeButton', function($container, $name, $label = null, $maxLength = null, $searchFormat = null, \DateTime $startTime = null, \DateTime $endTime = null) { |
|
| 199 | 199 | $picker = $container[$name] = new DateTimeRangeButton($name, $label, $maxLength, $searchFormat, $startTime, $endTime); |
| 200 | 200 | return $picker; |
| 201 | 201 | }); |
@@ -64,7 +64,7 @@ |
||
| 64 | 64 | |
| 65 | 65 | public static function register(?string $inputFormat = null, ?string $searchFormat = null) |
| 66 | 66 | { |
| 67 | - Container::extensionMethod('addBootstrapDateRange', function ($container, $name, $label = null, $maxLength = null) use ($inputFormat, $searchFormat) { |
|
| 67 | + Container::extensionMethod('addBootstrapDateRange', function($container, $name, $label = null, $maxLength = null) use ($inputFormat, $searchFormat) { |
|
| 68 | 68 | $picker = $container[$name] = new BootstrapDateRange($name, $label, $maxLength); |
| 69 | 69 | |
| 70 | 70 | if (null !== $inputFormat) { |
@@ -61,7 +61,7 @@ |
||
| 61 | 61 | |
| 62 | 62 | public static function register(?string $inputFormat = null, ?string $searchFormat = null) |
| 63 | 63 | { |
| 64 | - Container::extensionMethod('addBootstrapRange', function ($container, $name, $label = null, $maxLength = null) use ($inputFormat, $searchFormat) { |
|
| 64 | + Container::extensionMethod('addBootstrapRange', function($container, $name, $label = null, $maxLength = null) use ($inputFormat, $searchFormat) { |
|
| 65 | 65 | $picker = $container[$name] = new BootstrapRange($name, $label, $maxLength); |
| 66 | 66 | |
| 67 | 67 | if (null !== $inputFormat) |
@@ -64,10 +64,12 @@ |
||
| 64 | 64 | Container::extensionMethod('addBootstrapRange', function ($container, $name, $label = null, $maxLength = null) use ($inputFormat, $searchFormat) { |
| 65 | 65 | $picker = $container[$name] = new BootstrapRange($name, $label, $maxLength); |
| 66 | 66 | |
| 67 | - if (null !== $inputFormat) |
|
| 68 | - $picker->setInputFormat($inputFormat); |
|
| 69 | - if (null !== $searchFormat) |
|
| 70 | - $picker->setSearchFormat($searchFormat); |
|
| 67 | + if (null !== $inputFormat) { |
|
| 68 | + $picker->setInputFormat($inputFormat); |
|
| 69 | + } |
|
| 70 | + if (null !== $searchFormat) { |
|
| 71 | + $picker->setSearchFormat($searchFormat); |
|
| 72 | + } |
|
| 71 | 73 | |
| 72 | 74 | return $picker; |
| 73 | 75 | }); |