Initial import of space_profiles module

This commit is contained in:
Kelin Rescue Hub
2026-04-04 13:11:50 -04:00
commit 87a59e5a0a
35 changed files with 1627 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
<?php
use humhub\components\Migration;
class m260401_141000_add_template_key extends Migration
{
public function safeUp()
{
$schema = $this->db->getSchema()->getTableSchema('rescue_space_profile', true);
if ($schema === null) {
return;
}
if (!isset($schema->columns['template_key'])) {
$this->addColumn('rescue_space_profile', 'template_key', $this->string(64)->defaultValue('rescue_center')->notNull());
}
}
public function safeDown()
{
$schema = $this->db->getSchema()->getTableSchema('rescue_space_profile', true);
if ($schema !== null && isset($schema->columns['template_key'])) {
$this->dropColumn('rescue_space_profile', 'template_key');
}
}
}