Skip to content

Commit

Permalink
remove: Purge ip_checking in models and views of poll.
Browse files Browse the repository at this point in the history
  • Loading branch information
gyakkun committed Feb 14, 2020
1 parent c6207c3 commit 957ac57
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 27 deletions.
6 changes: 0 additions & 6 deletions app/Http/Controllers/Staff/PollController.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,12 +127,6 @@ public function update(StorePoll $request, $id)

$poll->title = $request->input('title');

if ($request->input('ip_checking')) {
$poll->ip_checking = true;
} else {
$poll->ip_checking = false;
}

if ($request->input('multiple_choice')) {
$poll->multiple_choice = true;
} else {
Expand Down
3 changes: 0 additions & 3 deletions app/Models/Poll.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
* @property int $user_id
* @property string $title
* @property string $slug
* @property int $ip_checking
* @property int $multiple_choice
* @property \Illuminate\Support\Carbon|null $created_at
* @property \Illuminate\Support\Carbon|null $updated_at
Expand All @@ -37,7 +36,6 @@
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll query()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll whereCreatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll whereIpChecking($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll whereMultipleChoice($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll whereSlug($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Poll whereTitle($value)
Expand All @@ -60,7 +58,6 @@ class Poll extends Model
protected $fillable = [
'title',
'slug',
'ip_checking',
'multiple_choice',
];

Expand Down
7 changes: 0 additions & 7 deletions resources/views/Staff/poll/forms/make.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,6 @@

<hr>

<div class="checkbox">
<label>
<input type="checkbox" name="ip_checking" value="1">@lang('poll.ip-checking') <span
class="text-red">({{ strtoupper(trans('poll.ip-checking-warrning')) }})</span>
</label>
</div>

<div class="checkbox">
<label>
<input type="checkbox" name="multiple_choice" value="1">@lang('poll.multiple-choice')
Expand Down
8 changes: 0 additions & 8 deletions resources/views/Staff/poll/forms/update.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,6 @@

<hr>

<div class="checkbox">
<label>
<input type="checkbox" name="ip_checking" @if ($poll->ip_checking) checked @endif >
@lang('poll.ip-checking')
<span class="text-red">({{ strtoupper(trans('poll.ip-checking-warrning')) }})</span>
</label>
</div>

<div class="checkbox">
<label>
<input type="checkbox" name="multiple_choice" @if ($poll->multiple_choice) checked @endif >
Expand Down
3 changes: 0 additions & 3 deletions resources/views/poll/show.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,6 @@
@if ($poll->multiple_choice)
<span class="badge-user text-bold text-red">@lang('poll.multiple-choice')</span>
@endif
@if ($poll->ip_checking)
<span class="badge-user text-bold text-red">@lang('poll.ip-checking')</span>
@endif
</div>
</div>
</div>
Expand Down

0 comments on commit 957ac57

Please sign in to comment.