src/relationships/HasManyRelationship.php 1 location
|
@@ 54-56 (lines=3) @@
|
| 51 |
|
if($this->options['foreign_key'] == null) { |
| 52 |
|
$this->options['foreign_key'] = Text::singularize($this->setupTable) . '_id'; |
| 53 |
|
} |
| 54 |
|
if($this->options['local_key'] == null) { |
| 55 |
|
$this->options['local_key'] = $this->setupPrimaryKey[0]; |
| 56 |
|
} |
| 57 |
|
} |
| 58 |
|
} |
| 59 |
|
|
src/relationships/ManyHaveManyRelationship.php 1 location
|
@@ 75-77 (lines=3) @@
|
| 72 |
|
$foreignModel->getDescription()->getPrimaryKey()[0]; |
| 73 |
|
} |
| 74 |
|
|
| 75 |
|
if ($this->options['local_key'] == null) { |
| 76 |
|
$this->options['local_key'] = $this->setupPrimaryKey[0]; |
| 77 |
|
} |
| 78 |
|
|
| 79 |
|
if (!isset($this->options['junction_local_key'])) { |
| 80 |
|
$this->options['junction_local_key'] = |