mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
filters updated
This commit is contained in:
@@ -15,6 +15,8 @@ class CreateLibrariesTable extends Migration
|
||||
Schema::create('libraries', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->boolean('is_public')
|
||||
->default(true);
|
||||
$table->json('language_codes')
|
||||
->default('[]');
|
||||
$table->timestamps();
|
||||
|
||||
@@ -24,7 +24,8 @@ class CreateLibraryItemsTable extends Migration
|
||||
$table->string('name');
|
||||
$table->string('type');
|
||||
$table->string('language_code');
|
||||
$table->longText('value');
|
||||
$table->longText('value')
|
||||
->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
|
||||
|
||||
@@ -254,11 +254,28 @@ class DatabaseSeeder extends Seeder
|
||||
]);
|
||||
$libraryItem = LibraryItem::create([
|
||||
'lecturer_id' => 4,
|
||||
'name' => 'Cryptography is Not Enough - Gigi @ Baltic Honeybadger 2022 ️',
|
||||
'name' => 'Cryptography is Not Enough - Gigi @ Baltic Honeybadger 2022 ',
|
||||
'type' => 'youtube_video',
|
||||
'language_code' => 'de',
|
||||
'value' => 'https://www.youtube.com/watch?v=C7ynm0Zkwfk',
|
||||
]);
|
||||
$libraryItem->syncTagsWithType(['Proof of Work'], 'library_item');
|
||||
$library->libraryItems()
|
||||
->attach($libraryItem);
|
||||
$nonPublicLibrary = Library::create([
|
||||
'name' => 'Einundzwanzig Dozenten',
|
||||
'is_public' => false,
|
||||
'language_codes' => ['de', 'en'],
|
||||
]);
|
||||
$libraryItem = LibraryItem::create([
|
||||
'lecturer_id' => 4,
|
||||
'name' => 'Präsentation: Bitcoin VHS Kurs 2022',
|
||||
'type' => 'downloadable_file',
|
||||
'language_code' => 'de',
|
||||
'value' => null,
|
||||
]);
|
||||
$libraryItem->syncTagsWithType(['Präsentationen'], 'library_item');
|
||||
$nonPublicLibrary->libraryItems()
|
||||
->attach($libraryItem);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user