소스 검색

'id' => 'string'

visuddhinanda 3 년 전
부모
커밋
48d1489ec0
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6 0
      app/Models/Course.php

+ 6 - 0
app/Models/Course.php

@@ -8,4 +8,10 @@ use Illuminate\Database\Eloquent\Model;
 class Course extends Model
 {
     use HasFactory;
+    protected $primaryKey = 'id';
+    protected $casts = [
+        'id' => 'string'
+    ];
+    public  $incrementing = false;
+
 }