Se cargan las modificaciones para pasarela stripe
This commit is contained in:
@@ -17,6 +17,11 @@ class Nivel extends Model
|
||||
return $this->belongsToMany(Plantel::class)->withPivot('plantel_id');
|
||||
}
|
||||
|
||||
public function nivelPlane() : BelongsToMany
|
||||
{
|
||||
return $this->belongsToMany(Plane::class);
|
||||
}
|
||||
|
||||
public function existe($plantelId = null)
|
||||
{
|
||||
if (!$plantelId) {
|
||||
|
||||
@@ -16,6 +16,11 @@ class Plane extends Model
|
||||
return $this->belongsToMany(Plantel::class)->withPivot('plantel_id');
|
||||
}
|
||||
|
||||
public function nivelPlane() : BelongsToMany
|
||||
{
|
||||
return $this->belongsToMany(Nivel::class);
|
||||
}
|
||||
|
||||
public function existe($plantelId = null)
|
||||
{
|
||||
if (!$plantelId) {
|
||||
@@ -27,6 +32,17 @@ class Plane extends Model
|
||||
->exists();
|
||||
}
|
||||
|
||||
public function nivel($nivelId = null)
|
||||
{
|
||||
if (!$nivelId) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return $this->nivelPlane()
|
||||
->wherePivot('nivel_id', $nivelId)
|
||||
->exists();
|
||||
}
|
||||
|
||||
public function conceptos(): BelongsToMany
|
||||
{
|
||||
return $this->belongsToMany(Concepto::class)
|
||||
|
||||
Reference in New Issue
Block a user