-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
iConcept
authored and
iConcept
committed
Mar 6, 2017
1 parent
f9f8737
commit b2d3cf3
Showing
9 changed files
with
74 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,13 @@ | ||
<div class="checkbox"> | ||
<label> | ||
<input name="{{ $name }}" type="checkbox" value="1" {{ $value == 1 ? "checked" : ""}}> | ||
<?php | ||
$attrs = []; | ||
if (isset($attribute)) | ||
{ | ||
$attrs = array_merge($attrs, $attribute); | ||
} | ||
?> | ||
{{ Form::checkbox($name, 1, ($value == 1 ? true : false), $attrs) }} | ||
{{ $title }} | ||
</label> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,20 @@ | ||
<div class="form-group"> | ||
<?php | ||
$attrs = array('class' => 'form-control', 'style' => 'width:100%'); | ||
if (isset($attribute)) | ||
{ | ||
$attrs = array_merge($attrs, $attribute); | ||
} | ||
$options= []; | ||
foreach ($items as $item) | ||
{ | ||
$options+= [$item['value'] => $item['name']]; | ||
} | ||
?> | ||
|
||
@if (isset($title)) | ||
<label class="control-label">{{ $title }}</label> | ||
{{ Form::label($name, $title, array('class' => 'control-label')) }} | ||
@endif | ||
<select style="width:100%" class="form-control" name="{{ $name }}"> | ||
@foreach ($items as $item) | ||
<option value="{{ $item['value'] }}" {{ ($item['value'] == $value) ? "selected" : "" }}>{{ $item['name'] }}</option> | ||
@endforeach | ||
</select> | ||
{{ Form::select($name, $options, $value, $attrs) }} | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,20 @@ | ||
<div class="form-group"> | ||
<?php | ||
$attrs = array('class' => 'form-control select2', 'style' => 'width:100%'); | ||
if (isset($attribute)) | ||
{ | ||
$attrs = array_merge($attrs, $attribute); | ||
} | ||
$options= []; | ||
foreach ($items as $item) | ||
{ | ||
$options+= [$item['value'] => $item['name']]; | ||
} | ||
?> | ||
|
||
@if (isset($title)) | ||
<label class="control-label">{{ $title }}</label> | ||
{{ Form::label($name, $title, array('class' => 'control-label')) }} | ||
@endif | ||
<select style="width:100%" class="form-control select2" name="{{ $name }}"> | ||
@foreach ($items as $item) | ||
<option value="{{ $item['value'] }}" {{ ($item['value'] == $value) ? "selected" : "" }}>{{ $item['name'] }}</option> | ||
@endforeach | ||
</select> | ||
{{ Form::select($name, $options, $value, $attrs) }} | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
<button class="btn btn-primary" onclick="this.disabled = true; this.form.submit();"> | ||
Submit | ||
</button> | ||
<?php | ||
$attrs = array('class' => 'btn btn-primary', 'onclick' => 'this.disabled = true;this.form.submit();'); | ||
if (isset($attribute)) | ||
{ | ||
$attrs = array_merge($attrs, $attribute); | ||
} | ||
?> | ||
{{ Form::submit((isset($title) ? $title : 'Submit'), $attrs) }} |