title: Do not update records in the database Laravel
body: <p>I can not understand why, but the records in the database are not updated ... All data reaches, even after the save () method if you dump the object, then the data from the form is stored correctly, and in the database itself there is no change, besides it is not the first method updating the data, making stores with the same method and everything worked, even in this project the category editing method works. Here's the actual method:</p>
  
  <pre><code>public function UpdateCountry(Request $request)
  {
      $Countries = Countries::where('Id', $request-&gt;get('Id'))-&gt;first();
      $Countries-&gt;Country   = $request-&gt;get('Country');
      $Countries-&gt;Continent = $request-&gt;get('Continent');
      $Countries-&gt;Class     = $request-&gt;get('Class');
      $Countries-&gt;save();
  
      return back()-&gt;with('status', 'Updated success!');
  }
  </code></pre>
  
  <p>Model fillable:</p>
  
  <pre><code>protected $fillable = ['Id', 'Country', 'Class', 'Continent'];
  </code></pre>
  
  <p>Routes, which use this method:</p>
  
  <pre><code>Route::get('country/editor/edit/{Id}','AdminController@EditCountry')-&gt;name('EditCountry');
  Route::post('country/editor/save','AdminController@UpdateCountry')-&gt;name('UpdateCountry');
  </code></pre>
  
  <p>A similar method for editing categories that works.</p>
  
  <pre><code>public function UpdateCat(Request $request) {
      $data               = $request-&gt;all();
      $Category           = Categories::find($data['id']);
      $Category-&gt;Category = $data['Category'];
      $Category-&gt;save();
  
      return back()-&gt;with('status', 'Updated success');
  }
  </code></pre>
  
  <p>View:</p>
  
  <pre><code>@extends('layouts.app')
  @section('content')
  &lt;div class="container"&gt;
      &lt;div class="row justify-content-center"&gt;
          &lt;div class="col-md-8"&gt;
              &lt;div class="card card-default"&gt;
                  &lt;div class="card-header"&gt;Dashboard&lt;/div&gt;
                  @if (session('status'))
                      &lt;div class="alert alert-success"&gt;
                          {{ session('status') }}
                      &lt;/div&gt;
                  @endif
   &lt;div class="container"&gt;
                      &lt;form action="{{route('UpdateCountry')}}" method="post"&gt;
                          @foreach($Country as $item)
                          &lt;div class="form-group"&gt;
                              &lt;label for="Country"&gt;Country&lt;/label&gt;
                              &lt;input type="hidden" value="{!! $item-&gt;Id !!}" name="Id" id="Id"&gt;
                              &lt;input type="text" class="form-control" id="Country" name="Country"  value="{{$item-&gt;Country}}" required&gt;
  
                          &lt;/div&gt;
                          &lt;div class="form-group"&gt;
                              &lt;label for="Continent"&gt;Continent&lt;/label&gt;
                              &lt;input type="text" class="form-control" id="Continent" name="Continent" value="{{$item-&gt;Continent}}" required&gt;
                          &lt;/div&gt;
                          @endforeach
                              &lt;input type="hidden" id="Class" name="Class" value="flag flag-default"&gt;
                          &lt;button type="submit" class="btn btn-success"&gt;Save&lt;/button&gt;
                          {{csrf_field()}}
                      &lt;/form&gt;
  
                  &lt;/div&gt;
  
              &lt;/div&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  &lt;/div&gt;
  @endsection
  </code></pre>