Explorar el Código

Update ProfileMigration model, add target relation

Daniel Supernault hace 1 año
padre
commit
3f0539978e
Se han modificado 1 ficheros con 5 adiciones y 0 borrados
  1. 5 0
      app/Models/ProfileMigration.php

+ 5 - 0
app/Models/ProfileMigration.php

@@ -16,4 +16,9 @@ class ProfileMigration extends Model
     {
         return $this->belongsTo(Profile::class, 'profile_id');
     }
+
+    public function target()
+    {
+        return $this->belongsTo(Profile::class, 'target_profile_id');
+    }
 }