|
@@ 77-81 (lines=5) @@
|
| 74 |
|
$string .= "<label for='{$lang}[{$name}]'>"; |
| 75 |
|
$string .= "<input id='{$lang}[{$name}]' name='{$lang}[{$name}]' type='checkbox' class='flat-blue'"; |
| 76 |
|
|
| 77 |
|
if (is_object($object)) { |
| 78 |
|
$currentData = $object->hasTranslation($lang) ? (bool) $object->translate($lang)->{$name} : ''; |
| 79 |
|
} else { |
| 80 |
|
$currentData = false; |
| 81 |
|
} |
| 82 |
|
|
| 83 |
|
$oldInput = Input::old("{$lang}.$name", $currentData) ? 'checked' : ''; |
| 84 |
|
$string .= "value='1' {$oldInput}>"; |
|
@@ 156-160 (lines=5) @@
|
| 153 |
|
$string .= "<label for='$name'>"; |
| 154 |
|
$string .= "<input id='$name' name='$name' type='checkbox' class='flat-blue'"; |
| 155 |
|
|
| 156 |
|
if (is_object($object)) { |
| 157 |
|
$currentData = isset($object->$name) && (bool) $object->$name ? 'checked' : ''; |
| 158 |
|
} else { |
| 159 |
|
$currentData = false; |
| 160 |
|
} |
| 161 |
|
|
| 162 |
|
$oldInput = Input::old($name, $currentData) ? 'checked' : ''; |
| 163 |
|
$string .= "value='1' {$oldInput}>"; |