| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 18 | public function up(Schema $schema): void |
||
| 19 | { |
||
| 20 | |||
| 21 | $this->addSql('CREATE TABLE stu_location_mining (id INT GENERATED BY DEFAULT AS IDENTITY NOT NULL, location_id INT NOT NULL, commodity_id INT NOT NULL, actual_amount INT NOT NULL, max_amount INT NOT NULL, depleted_at INT DEFAULT NULL, PRIMARY KEY(id))'); |
||
| 22 | $this->addSql('CREATE INDEX IDX_AC85C1AC64D218E ON stu_location_mining (location_id)'); |
||
| 23 | $this->addSql('CREATE INDEX IDX_AC85C1ACB4ACC212 ON stu_location_mining (commodity_id)'); |
||
| 24 | $this->addSql('ALTER TABLE stu_location_mining ADD CONSTRAINT FK_AC85C1AC64D218E FOREIGN KEY (location_id) REFERENCES stu_location (id) NOT DEFERRABLE INITIALLY IMMEDIATE'); |
||
| 25 | $this->addSql('ALTER TABLE stu_location_mining ADD CONSTRAINT FK_AC85C1ACB4ACC212 FOREIGN KEY (commodity_id) REFERENCES stu_commodity (id) NOT DEFERRABLE INITIALLY IMMEDIATE'); |
||
| 26 | } |
||
| 37 |