سلام وقت همه دوستان بخیر
من برای اینکه دیتای یکی از جدول های دیتابیس رو بگیرم از این کد توی کنترلرم استفاده کردم البته که مدلم رو هم use کردم
public function educations()
{
$educations = education::all();
return view('admin.all-edu', ['educations' => $educations]);
}
و در view هم از این کد استفاده کردم
<tbody>
@foreach ($educations as $education)
<tr>
<td>{{ $education->titel }}</td>
<td>
<div class="btn-group" style="margin-left: -70px; margin-right: -70px;" role="group" aria-label="Second group">
<button type="button" class="btn btn-outline-secondary">
<i class="tf-icons bx bx-edit"></i>
</button>
<button type="button" class="btn btn-outline-secondary">
<i class="tf-icons bx bx-hide"></i>
</button>
<button type="button" class="btn btn-outline-secondary">
<i class="tf-icons bx bx-trash"></i>
</button>
</div>
</td>
</tr>
@endforeach
</tbody>
با این کار میخوام title رو از دیتابیس بکیرم در این خونه از جدول نشون بدم اما الان به یه مشکلی خوردم که ارور میگیرم از دیتابیس عکسشو میزارم

migretion هارو هم یکبار ریست کردم و دوباره migrate کردم بدون مشکل ران شد حتی استاتوس گرفتم ازmigration ها همشون yes هستش و مشکلی نداره میشه راح حل این ارور رو به من بگید
ببینید من کلا یه بار دیگه مدل ساختم از اول کدهامو اینجا میزارم ببینید کجا اشتباه کردم چون من نام گذاری هارو اشتباهی توش ندیدم
این کد مدلم
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class education extends Model
{
use HasFactory;
}
اینم کنترلر
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Models\education;
class dashboardcontroller extends Controller
{
public function educations()
{
$educations = education::all();
return view('admin.all-edu', ['educations'. $educations]);
}
}
اینم کد ویو
<tbody>
@foreach ($educations as $education)
<tr>
<td>{{ $education->titel }}</td>
<td>test</td>
<td>test</td>
<td>test</td>
<td>
<div class="btn-group" style="margin-left: -70px; margin-right: -70px;" role="group" aria-label="Second group">
<button type="button" class="btn btn-outline-secondary">
<i class="tf-icons bx bx-edit"></i>
</button>
<button type="button" class="btn btn-outline-secondary">
<i class="tf-icons bx bx-hide"></i>
</button>
<button type="button" class="btn btn-outline-secondary">
<i class="tf-icons bx bx-trash"></i>
</button>
</div>
</td>
</tr>
@endforeach
</tbody>
اینم خطایی که میده البه بعد از مایگریت کردن دوباره خطا تغییر کرد

شاید پاسخ شما همینجا باشد