Merge pull request 'Added hasMany relationship on model files' (#482) from ranjith-dev into master
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Has been cancelled
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Has been cancelled
Reviewed-on: #482
This commit was merged in pull request #482.
This commit is contained in:
@@ -64,6 +64,11 @@ class Item extends Model
|
||||
return $this->hasMany(CharacteristicValue::class);
|
||||
}
|
||||
|
||||
public function ClassCharacteristics()
|
||||
{
|
||||
return $this->hasMany(ClassCharacteristic::class, 'item_id', 'id');
|
||||
}
|
||||
|
||||
public function weightValidations()
|
||||
{
|
||||
return $this->hasMany(WeightValidation::class);
|
||||
|
||||
@@ -43,6 +43,11 @@ class Machine extends Model
|
||||
return $this->hasMany(CharacteristicValue::class);
|
||||
}
|
||||
|
||||
public function ClassCharacteristics()
|
||||
{
|
||||
return $this->hasMany(ClassCharacteristic::class, 'machine_id', 'id');
|
||||
}
|
||||
|
||||
public function testingPanelReadings()
|
||||
{
|
||||
return $this->hasMany(TestingPanelReading::class);
|
||||
|
||||
@@ -113,6 +113,11 @@ class Plant extends Model
|
||||
return $this->hasMany(EquipmentMaster::class, 'plant_id', 'id');
|
||||
}
|
||||
|
||||
public function ClassCharacteristics()
|
||||
{
|
||||
return $this->hasMany(ClassCharacteristic::class, 'plant_id', 'id');
|
||||
}
|
||||
|
||||
// public function rejectReasons()
|
||||
// {
|
||||
// return $this->hasMany(RejectReason::class, 'plant_id', 'id');
|
||||
|
||||
Reference in New Issue
Block a user