Skip to content

Commit caf320a

Browse files
committed
Disable picker when field is readonly or disabled
1 parent cce84a6 commit caf320a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Extensions/FormFieldExtension.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,10 @@ public function updateAttributes(&$attributes)
139139
*/
140140
public function getCalendarEnabled()
141141
{
142+
if ($this->owner->isReadonly() || $this->owner->isDisabled()) {
143+
return 'false';
144+
}
145+
142146
return ($this->calendarDisabled || $this->owner->config()->calendar_disabled) ? 'false' : 'true';
143147
}
144148

0 commit comments

Comments
 (0)