fix(category): remove uncategorized option to enforce users in choosing a category
Apple podcasts requires a category to submit a valid podcast RSS feed. The "uncategorized" category is not a valid category.
This commit is contained in:
parent
433745f194
commit
8c64f25a0e
|
@ -24,6 +24,7 @@ class AddCategories extends Migration
|
||||||
'parent_id' => [
|
'parent_id' => [
|
||||||
'type' => 'INT',
|
'type' => 'INT',
|
||||||
'unsigned' => true,
|
'unsigned' => true,
|
||||||
|
'null' => true,
|
||||||
],
|
],
|
||||||
'code' => [
|
'code' => [
|
||||||
'type' => 'VARCHAR',
|
'type' => 'VARCHAR',
|
||||||
|
|
|
@ -18,778 +18,771 @@ class CategorySeeder extends Seeder
|
||||||
{
|
{
|
||||||
$data = [
|
$data = [
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 0,
|
|
||||||
'code' => 'uncategorized',
|
|
||||||
'apple_category' => 'uncategorized',
|
|
||||||
'google_category' => 'uncategorized',
|
|
||||||
],
|
|
||||||
[
|
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 1,
|
'id' => 1,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'arts',
|
'code' => 'arts',
|
||||||
'apple_category' => 'Arts',
|
'apple_category' => 'Arts',
|
||||||
'google_category' => 'Arts',
|
'google_category' => 'Arts',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 2,
|
'id' => 2,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'business',
|
'code' => 'business',
|
||||||
'apple_category' => 'Business',
|
'apple_category' => 'Business',
|
||||||
'google_category' => 'Business',
|
'google_category' => 'Business',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 3,
|
'id' => 3,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'comedy',
|
'code' => 'comedy',
|
||||||
'apple_category' => 'Comedy',
|
'apple_category' => 'Comedy',
|
||||||
'google_category' => 'Comedy',
|
'google_category' => 'Comedy',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 4,
|
'id' => 4,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'education',
|
'code' => 'education',
|
||||||
'apple_category' => 'Education',
|
'apple_category' => 'Education',
|
||||||
'google_category' => 'Education',
|
'google_category' => 'Education',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 5,
|
'id' => 5,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'fiction',
|
'code' => 'fiction',
|
||||||
'apple_category' => 'Fiction',
|
'apple_category' => 'Fiction',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 6,
|
'id' => 6,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'government',
|
'code' => 'government',
|
||||||
'apple_category' => 'Government',
|
'apple_category' => 'Government',
|
||||||
'google_category' => 'Government & Organizations',
|
'google_category' => 'Government & Organizations',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 7,
|
'id' => 7,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'health_and_fitness',
|
'code' => 'health_and_fitness',
|
||||||
'apple_category' => 'Health & Fitness',
|
'apple_category' => 'Health & Fitness',
|
||||||
'google_category' => 'Health',
|
'google_category' => 'Health',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 8,
|
'id' => 8,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'history',
|
'code' => 'history',
|
||||||
'apple_category' => 'History',
|
'apple_category' => 'History',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 9,
|
'id' => 9,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'kids_and_family',
|
'code' => 'kids_and_family',
|
||||||
'apple_category' => 'Kids & Family',
|
'apple_category' => 'Kids & Family',
|
||||||
'google_category' => 'Kids & Family',
|
'google_category' => 'Kids & Family',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 10,
|
'id' => 10,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'leisure',
|
'code' => 'leisure',
|
||||||
'apple_category' => 'Leisure',
|
'apple_category' => 'Leisure',
|
||||||
'google_category' => 'Games & Hobbies',
|
'google_category' => 'Games & Hobbies',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 11,
|
'id' => 11,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'music',
|
'code' => 'music',
|
||||||
'apple_category' => 'Music',
|
'apple_category' => 'Music',
|
||||||
'google_category' => 'Music',
|
'google_category' => 'Music',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 12,
|
'id' => 12,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'news',
|
'code' => 'news',
|
||||||
'apple_category' => 'News',
|
'apple_category' => 'News',
|
||||||
'google_category' => 'News & Politics',
|
'google_category' => 'News & Politics',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 13,
|
'id' => 13,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'religion_and_spirituality',
|
'code' => 'religion_and_spirituality',
|
||||||
'apple_category' => 'Religion & Spirituality',
|
'apple_category' => 'Religion & Spirituality',
|
||||||
'google_category' => 'Religion & Spirituality',
|
'google_category' => 'Religion & Spirituality',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 14,
|
'id' => 14,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'science',
|
'code' => 'science',
|
||||||
'apple_category' => 'Science',
|
'apple_category' => 'Science',
|
||||||
'google_category' => 'Science & Medicine',
|
'google_category' => 'Science & Medicine',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 15,
|
'id' => 15,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'society_and_culture',
|
'code' => 'society_and_culture',
|
||||||
'apple_category' => 'Society & Culture',
|
'apple_category' => 'Society & Culture',
|
||||||
'google_category' => 'Society & Culture',
|
'google_category' => 'Society & Culture',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 16,
|
'id' => 16,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'sports',
|
'code' => 'sports',
|
||||||
'apple_category' => 'Sports',
|
'apple_category' => 'Sports',
|
||||||
'google_category' => 'Sports & Recreation',
|
'google_category' => 'Sports & Recreation',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 17,
|
'id' => 17,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'technology',
|
'code' => 'technology',
|
||||||
'apple_category' => 'Technology',
|
'apple_category' => 'Technology',
|
||||||
'google_category' => 'Technology',
|
'google_category' => 'Technology',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 18,
|
'id' => 18,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'true_crime',
|
'code' => 'true_crime',
|
||||||
'apple_category' => 'True Crime',
|
'apple_category' => 'True Crime',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 0,
|
|
||||||
'id' => 19,
|
'id' => 19,
|
||||||
|
'parent_id' => null,
|
||||||
'code' => 'tv_and_film',
|
'code' => 'tv_and_film',
|
||||||
'apple_category' => 'TV & Film',
|
'apple_category' => 'TV & Film',
|
||||||
'google_category' => 'TV & Film',
|
'google_category' => 'TV & Film',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 1,
|
|
||||||
'id' => 20,
|
'id' => 20,
|
||||||
|
'parent_id' => 1,
|
||||||
'code' => 'books',
|
'code' => 'books',
|
||||||
'apple_category' => 'Books',
|
'apple_category' => 'Books',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 1,
|
|
||||||
'id' => 21,
|
'id' => 21,
|
||||||
|
'parent_id' => 1,
|
||||||
'code' => 'design',
|
'code' => 'design',
|
||||||
'apple_category' => 'Design',
|
'apple_category' => 'Design',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 1,
|
|
||||||
'id' => 22,
|
'id' => 22,
|
||||||
|
'parent_id' => 1,
|
||||||
'code' => 'fashion_and_beauty',
|
'code' => 'fashion_and_beauty',
|
||||||
'apple_category' => 'Fashion & Beauty',
|
'apple_category' => 'Fashion & Beauty',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 1,
|
|
||||||
'id' => 23,
|
'id' => 23,
|
||||||
|
'parent_id' => 1,
|
||||||
'code' => 'food',
|
'code' => 'food',
|
||||||
'apple_category' => 'Food',
|
'apple_category' => 'Food',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 1,
|
|
||||||
'id' => 24,
|
'id' => 24,
|
||||||
|
'parent_id' => 1,
|
||||||
'code' => 'performing_arts',
|
'code' => 'performing_arts',
|
||||||
'apple_category' => 'Performing Arts',
|
'apple_category' => 'Performing Arts',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 1,
|
|
||||||
'id' => 25,
|
'id' => 25,
|
||||||
|
'parent_id' => 1,
|
||||||
'code' => 'visual_arts',
|
'code' => 'visual_arts',
|
||||||
'apple_category' => 'Visual Arts',
|
'apple_category' => 'Visual Arts',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 2,
|
|
||||||
'id' => 26,
|
'id' => 26,
|
||||||
|
'parent_id' => 2,
|
||||||
'code' => 'careers',
|
'code' => 'careers',
|
||||||
'apple_category' => 'Careers',
|
'apple_category' => 'Careers',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 2,
|
|
||||||
'id' => 27,
|
'id' => 27,
|
||||||
|
'parent_id' => 2,
|
||||||
'code' => 'entrepreneurship',
|
'code' => 'entrepreneurship',
|
||||||
'apple_category' => 'Entrepreneurship',
|
'apple_category' => 'Entrepreneurship',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 2,
|
|
||||||
'id' => 28,
|
'id' => 28,
|
||||||
|
'parent_id' => 2,
|
||||||
'code' => 'investing',
|
'code' => 'investing',
|
||||||
'apple_category' => 'Investing',
|
'apple_category' => 'Investing',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 2,
|
|
||||||
'id' => 29,
|
'id' => 29,
|
||||||
|
'parent_id' => 2,
|
||||||
'code' => 'management',
|
'code' => 'management',
|
||||||
'apple_category' => 'Management',
|
'apple_category' => 'Management',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 2,
|
|
||||||
'id' => 30,
|
'id' => 30,
|
||||||
|
'parent_id' => 2,
|
||||||
'code' => 'marketing',
|
'code' => 'marketing',
|
||||||
'apple_category' => 'Marketing',
|
'apple_category' => 'Marketing',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 2,
|
|
||||||
'id' => 31,
|
'id' => 31,
|
||||||
|
'parent_id' => 2,
|
||||||
'code' => 'non_profit',
|
'code' => 'non_profit',
|
||||||
'apple_category' => 'Non-Profit',
|
'apple_category' => 'Non-Profit',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 3,
|
|
||||||
'id' => 32,
|
'id' => 32,
|
||||||
|
'parent_id' => 3,
|
||||||
'code' => 'comedy_interviews',
|
'code' => 'comedy_interviews',
|
||||||
'apple_category' => 'Comedy Interviews',
|
'apple_category' => 'Comedy Interviews',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 3,
|
|
||||||
'id' => 33,
|
'id' => 33,
|
||||||
|
'parent_id' => 3,
|
||||||
'code' => 'improv',
|
'code' => 'improv',
|
||||||
'apple_category' => 'Improv',
|
'apple_category' => 'Improv',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 3,
|
|
||||||
'id' => 34,
|
'id' => 34,
|
||||||
|
'parent_id' => 3,
|
||||||
'code' => 'stand_up',
|
'code' => 'stand_up',
|
||||||
'apple_category' => 'Stand-Up',
|
'apple_category' => 'Stand-Up',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 4,
|
|
||||||
'id' => 35,
|
'id' => 35,
|
||||||
|
'parent_id' => 4,
|
||||||
'code' => 'courses',
|
'code' => 'courses',
|
||||||
'apple_category' => 'Courses',
|
'apple_category' => 'Courses',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 4,
|
|
||||||
'id' => 36,
|
'id' => 36,
|
||||||
|
'parent_id' => 4,
|
||||||
'code' => 'how_to',
|
'code' => 'how_to',
|
||||||
'apple_category' => 'How To',
|
'apple_category' => 'How To',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 4,
|
|
||||||
'id' => 37,
|
'id' => 37,
|
||||||
|
'parent_id' => 4,
|
||||||
'code' => 'language_learning',
|
'code' => 'language_learning',
|
||||||
'apple_category' => 'Language Learning',
|
'apple_category' => 'Language Learning',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 4,
|
|
||||||
'id' => 38,
|
'id' => 38,
|
||||||
|
'parent_id' => 4,
|
||||||
'code' => 'self_improvement',
|
'code' => 'self_improvement',
|
||||||
'apple_category' => 'Self-Improvement',
|
'apple_category' => 'Self-Improvement',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 5,
|
|
||||||
'id' => 39,
|
'id' => 39,
|
||||||
|
'parent_id' => 5,
|
||||||
'code' => 'comedy_fiction',
|
'code' => 'comedy_fiction',
|
||||||
'apple_category' => 'Comedy Fiction',
|
'apple_category' => 'Comedy Fiction',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 5,
|
|
||||||
'id' => 40,
|
'id' => 40,
|
||||||
|
'parent_id' => 5,
|
||||||
'code' => 'drama',
|
'code' => 'drama',
|
||||||
'apple_category' => 'Drama',
|
'apple_category' => 'Drama',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 5,
|
|
||||||
'id' => 41,
|
'id' => 41,
|
||||||
|
'parent_id' => 5,
|
||||||
'code' => 'science_fiction',
|
'code' => 'science_fiction',
|
||||||
'apple_category' => 'Science Fiction',
|
'apple_category' => 'Science Fiction',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 7,
|
|
||||||
'id' => 42,
|
'id' => 42,
|
||||||
|
'parent_id' => 7,
|
||||||
'code' => 'alternative_health',
|
'code' => 'alternative_health',
|
||||||
'apple_category' => 'Alternative Health',
|
'apple_category' => 'Alternative Health',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 7,
|
|
||||||
'id' => 43,
|
'id' => 43,
|
||||||
|
'parent_id' => 7,
|
||||||
'code' => 'fitness',
|
'code' => 'fitness',
|
||||||
'apple_category' => 'Fitness',
|
'apple_category' => 'Fitness',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 7,
|
|
||||||
'id' => 44,
|
'id' => 44,
|
||||||
|
'parent_id' => 7,
|
||||||
'code' => 'medicine',
|
'code' => 'medicine',
|
||||||
'apple_category' => 'Medicine',
|
'apple_category' => 'Medicine',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 7,
|
|
||||||
'id' => 45,
|
'id' => 45,
|
||||||
|
'parent_id' => 7,
|
||||||
'code' => 'mental_health',
|
'code' => 'mental_health',
|
||||||
'apple_category' => 'Mental Health',
|
'apple_category' => 'Mental Health',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 7,
|
|
||||||
'id' => 46,
|
'id' => 46,
|
||||||
|
'parent_id' => 7,
|
||||||
'code' => 'nutrition',
|
'code' => 'nutrition',
|
||||||
'apple_category' => 'Nutrition',
|
'apple_category' => 'Nutrition',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 7,
|
|
||||||
'id' => 47,
|
'id' => 47,
|
||||||
|
'parent_id' => 7,
|
||||||
'code' => 'sexuality',
|
'code' => 'sexuality',
|
||||||
'apple_category' => 'Sexuality',
|
'apple_category' => 'Sexuality',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 9,
|
|
||||||
'id' => 48,
|
'id' => 48,
|
||||||
|
'parent_id' => 9,
|
||||||
'code' => 'education_for_kids',
|
'code' => 'education_for_kids',
|
||||||
'apple_category' => 'Education for Kids',
|
'apple_category' => 'Education for Kids',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 9,
|
|
||||||
'id' => 49,
|
'id' => 49,
|
||||||
|
'parent_id' => 9,
|
||||||
'code' => 'parenting',
|
'code' => 'parenting',
|
||||||
'apple_category' => 'Parenting',
|
'apple_category' => 'Parenting',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 9,
|
|
||||||
'id' => 50,
|
'id' => 50,
|
||||||
|
'parent_id' => 9,
|
||||||
'code' => 'pets_and_animals',
|
'code' => 'pets_and_animals',
|
||||||
'apple_category' => 'Pets & Animals',
|
'apple_category' => 'Pets & Animals',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 9,
|
|
||||||
'id' => 51,
|
'id' => 51,
|
||||||
|
'parent_id' => 9,
|
||||||
'code' => 'stories_for_kids',
|
'code' => 'stories_for_kids',
|
||||||
'apple_category' => 'Stories for Kids',
|
'apple_category' => 'Stories for Kids',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 52,
|
'id' => 52,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'animation_and_manga',
|
'code' => 'animation_and_manga',
|
||||||
'apple_category' => 'Animation & Manga',
|
'apple_category' => 'Animation & Manga',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 53,
|
'id' => 53,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'automotive',
|
'code' => 'automotive',
|
||||||
'apple_category' => 'Automotive',
|
'apple_category' => 'Automotive',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 54,
|
'id' => 54,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'aviation',
|
'code' => 'aviation',
|
||||||
'apple_category' => 'Aviation',
|
'apple_category' => 'Aviation',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 55,
|
'id' => 55,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'crafts',
|
'code' => 'crafts',
|
||||||
'apple_category' => 'Crafts',
|
'apple_category' => 'Crafts',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 56,
|
'id' => 56,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'games',
|
'code' => 'games',
|
||||||
'apple_category' => 'Games',
|
'apple_category' => 'Games',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 57,
|
'id' => 57,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'hobbies',
|
'code' => 'hobbies',
|
||||||
'apple_category' => 'Hobbies',
|
'apple_category' => 'Hobbies',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 58,
|
'id' => 58,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'home_and_garden',
|
'code' => 'home_and_garden',
|
||||||
'apple_category' => 'Home & Garden',
|
'apple_category' => 'Home & Garden',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 10,
|
|
||||||
'id' => 59,
|
'id' => 59,
|
||||||
|
'parent_id' => 10,
|
||||||
'code' => 'video_games',
|
'code' => 'video_games',
|
||||||
'apple_category' => 'Video Games',
|
'apple_category' => 'Video Games',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 11,
|
|
||||||
'id' => 60,
|
'id' => 60,
|
||||||
|
'parent_id' => 11,
|
||||||
'code' => 'music_commentary',
|
'code' => 'music_commentary',
|
||||||
'apple_category' => 'Music Commentary',
|
'apple_category' => 'Music Commentary',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 11,
|
|
||||||
'id' => 61,
|
'id' => 61,
|
||||||
|
'parent_id' => 11,
|
||||||
'code' => 'music_history',
|
'code' => 'music_history',
|
||||||
'apple_category' => 'Music History',
|
'apple_category' => 'Music History',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 11,
|
|
||||||
'id' => 62,
|
'id' => 62,
|
||||||
|
'parent_id' => 11,
|
||||||
'code' => 'music_interviews',
|
'code' => 'music_interviews',
|
||||||
'apple_category' => 'Music Interviews',
|
'apple_category' => 'Music Interviews',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 63,
|
'id' => 63,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'business_news',
|
'code' => 'business_news',
|
||||||
'apple_category' => 'Business News',
|
'apple_category' => 'Business News',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 64,
|
'id' => 64,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'daily_news',
|
'code' => 'daily_news',
|
||||||
'apple_category' => 'Daily News',
|
'apple_category' => 'Daily News',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 65,
|
'id' => 65,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'entertainment_news',
|
'code' => 'entertainment_news',
|
||||||
'apple_category' => 'Entertainment News',
|
'apple_category' => 'Entertainment News',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 66,
|
'id' => 66,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'news_commentary',
|
'code' => 'news_commentary',
|
||||||
'apple_category' => 'News Commentary',
|
'apple_category' => 'News Commentary',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 67,
|
'id' => 67,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'politics',
|
'code' => 'politics',
|
||||||
'apple_category' => 'Politics',
|
'apple_category' => 'Politics',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 68,
|
'id' => 68,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'sports_news',
|
'code' => 'sports_news',
|
||||||
'apple_category' => 'Sports News',
|
'apple_category' => 'Sports News',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 12,
|
|
||||||
'id' => 69,
|
'id' => 69,
|
||||||
|
'parent_id' => 12,
|
||||||
'code' => 'tech_news',
|
'code' => 'tech_news',
|
||||||
'apple_category' => 'Tech News',
|
'apple_category' => 'Tech News',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 70,
|
'id' => 70,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'buddhism',
|
'code' => 'buddhism',
|
||||||
'apple_category' => 'Buddhism',
|
'apple_category' => 'Buddhism',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 71,
|
'id' => 71,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'christianity',
|
'code' => 'christianity',
|
||||||
'apple_category' => 'Christianity',
|
'apple_category' => 'Christianity',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 72,
|
'id' => 72,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'hinduism',
|
'code' => 'hinduism',
|
||||||
'apple_category' => 'Hinduism',
|
'apple_category' => 'Hinduism',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 73,
|
'id' => 73,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'islam',
|
'code' => 'islam',
|
||||||
'apple_category' => 'Islam',
|
'apple_category' => 'Islam',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 74,
|
'id' => 74,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'judaism',
|
'code' => 'judaism',
|
||||||
'apple_category' => 'Judaism',
|
'apple_category' => 'Judaism',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 75,
|
'id' => 75,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'religion',
|
'code' => 'religion',
|
||||||
'apple_category' => 'Religion',
|
'apple_category' => 'Religion',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 13,
|
|
||||||
'id' => 76,
|
'id' => 76,
|
||||||
|
'parent_id' => 13,
|
||||||
'code' => 'spirituality',
|
'code' => 'spirituality',
|
||||||
'apple_category' => 'Spirituality',
|
'apple_category' => 'Spirituality',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 77,
|
'id' => 77,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'astronomy',
|
'code' => 'astronomy',
|
||||||
'apple_category' => 'Astronomy',
|
'apple_category' => 'Astronomy',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 78,
|
'id' => 78,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'chemistry',
|
'code' => 'chemistry',
|
||||||
'apple_category' => 'Chemistry',
|
'apple_category' => 'Chemistry',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 79,
|
'id' => 79,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'earth_sciences',
|
'code' => 'earth_sciences',
|
||||||
'apple_category' => 'Earth Sciences',
|
'apple_category' => 'Earth Sciences',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 80,
|
'id' => 80,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'life_sciences',
|
'code' => 'life_sciences',
|
||||||
'apple_category' => 'Life Sciences',
|
'apple_category' => 'Life Sciences',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 81,
|
'id' => 81,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'mathematics',
|
'code' => 'mathematics',
|
||||||
'apple_category' => 'Mathematics',
|
'apple_category' => 'Mathematics',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 82,
|
'id' => 82,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'natural_sciences',
|
'code' => 'natural_sciences',
|
||||||
'apple_category' => 'Natural Sciences',
|
'apple_category' => 'Natural Sciences',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 83,
|
'id' => 83,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'nature',
|
'code' => 'nature',
|
||||||
'apple_category' => 'Nature',
|
'apple_category' => 'Nature',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 84,
|
'id' => 84,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'physics',
|
'code' => 'physics',
|
||||||
'apple_category' => 'Physics',
|
'apple_category' => 'Physics',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 14,
|
|
||||||
'id' => 85,
|
'id' => 85,
|
||||||
|
'parent_id' => 14,
|
||||||
'code' => 'social_sciences',
|
'code' => 'social_sciences',
|
||||||
'apple_category' => 'Social Sciences',
|
'apple_category' => 'Social Sciences',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 15,
|
|
||||||
'id' => 86,
|
'id' => 86,
|
||||||
|
'parent_id' => 15,
|
||||||
'code' => 'documentary',
|
'code' => 'documentary',
|
||||||
'apple_category' => 'Documentary',
|
'apple_category' => 'Documentary',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 15,
|
|
||||||
'id' => 87,
|
'id' => 87,
|
||||||
|
'parent_id' => 15,
|
||||||
'code' => 'personal_journals',
|
'code' => 'personal_journals',
|
||||||
'apple_category' => 'Personal Journals',
|
'apple_category' => 'Personal Journals',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 15,
|
|
||||||
'id' => 88,
|
'id' => 88,
|
||||||
|
'parent_id' => 15,
|
||||||
'code' => 'philosophy',
|
'code' => 'philosophy',
|
||||||
'apple_category' => 'Philosophy',
|
'apple_category' => 'Philosophy',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 15,
|
|
||||||
'id' => 89,
|
'id' => 89,
|
||||||
|
'parent_id' => 15,
|
||||||
'code' => 'places_and_travel',
|
'code' => 'places_and_travel',
|
||||||
'apple_category' => 'Places & Travel',
|
'apple_category' => 'Places & Travel',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 15,
|
|
||||||
'id' => 90,
|
'id' => 90,
|
||||||
|
'parent_id' => 15,
|
||||||
'code' => 'relationships',
|
'code' => 'relationships',
|
||||||
'apple_category' => 'Relationships',
|
'apple_category' => 'Relationships',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 91,
|
'id' => 91,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'baseball',
|
'code' => 'baseball',
|
||||||
'apple_category' => 'Baseball',
|
'apple_category' => 'Baseball',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 92,
|
'id' => 92,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'basketball',
|
'code' => 'basketball',
|
||||||
'apple_category' => 'Basketball',
|
'apple_category' => 'Basketball',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 93,
|
'id' => 93,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'cricket',
|
'code' => 'cricket',
|
||||||
'apple_category' => 'Cricket',
|
'apple_category' => 'Cricket',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 94,
|
'id' => 94,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'fantasy_sports',
|
'code' => 'fantasy_sports',
|
||||||
'apple_category' => 'Fantasy Sports',
|
'apple_category' => 'Fantasy Sports',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 95,
|
'id' => 95,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'football',
|
'code' => 'football',
|
||||||
'apple_category' => 'Football',
|
'apple_category' => 'Football',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 96,
|
'id' => 96,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'golf',
|
'code' => 'golf',
|
||||||
'apple_category' => 'Golf',
|
'apple_category' => 'Golf',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 97,
|
'id' => 97,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'hockey',
|
'code' => 'hockey',
|
||||||
'apple_category' => 'Hockey',
|
'apple_category' => 'Hockey',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 98,
|
'id' => 98,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'rugby',
|
'code' => 'rugby',
|
||||||
'apple_category' => 'Rugby',
|
'apple_category' => 'Rugby',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 99,
|
'id' => 99,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'running',
|
'code' => 'running',
|
||||||
'apple_category' => 'Running',
|
'apple_category' => 'Running',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 100,
|
'id' => 100,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'soccer',
|
'code' => 'soccer',
|
||||||
'apple_category' => 'Soccer',
|
'apple_category' => 'Soccer',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 101,
|
'id' => 101,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'swimming',
|
'code' => 'swimming',
|
||||||
'apple_category' => 'Swimming',
|
'apple_category' => 'Swimming',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 102,
|
'id' => 102,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'tennis',
|
'code' => 'tennis',
|
||||||
'apple_category' => 'Tennis',
|
'apple_category' => 'Tennis',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 103,
|
'id' => 103,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'volleyball',
|
'code' => 'volleyball',
|
||||||
'apple_category' => 'Volleyball',
|
'apple_category' => 'Volleyball',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 104,
|
'id' => 104,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'wilderness',
|
'code' => 'wilderness',
|
||||||
'apple_category' => 'Wilderness',
|
'apple_category' => 'Wilderness',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 16,
|
|
||||||
'id' => 105,
|
'id' => 105,
|
||||||
|
'parent_id' => 16,
|
||||||
'code' => 'wrestling',
|
'code' => 'wrestling',
|
||||||
'apple_category' => 'Wrestling',
|
'apple_category' => 'Wrestling',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 19,
|
|
||||||
'id' => 106,
|
'id' => 106,
|
||||||
|
'parent_id' => 19,
|
||||||
'code' => 'after_shows',
|
'code' => 'after_shows',
|
||||||
'apple_category' => 'After Shows',
|
'apple_category' => 'After Shows',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 19,
|
|
||||||
'id' => 107,
|
'id' => 107,
|
||||||
|
'parent_id' => 19,
|
||||||
'code' => 'film_history',
|
'code' => 'film_history',
|
||||||
'apple_category' => 'Film History',
|
'apple_category' => 'Film History',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 19,
|
|
||||||
'id' => 108,
|
'id' => 108,
|
||||||
|
'parent_id' => 19,
|
||||||
'code' => 'film_interviews',
|
'code' => 'film_interviews',
|
||||||
'apple_category' => 'Film Interviews',
|
'apple_category' => 'Film Interviews',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 19,
|
|
||||||
'id' => 109,
|
'id' => 109,
|
||||||
|
'parent_id' => 19,
|
||||||
'code' => 'film_reviews',
|
'code' => 'film_reviews',
|
||||||
'apple_category' => 'Film Reviews',
|
'apple_category' => 'Film Reviews',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'parent_id' => 19,
|
|
||||||
'id' => 110,
|
'id' => 110,
|
||||||
|
'parent_id' => 19,
|
||||||
'code' => 'tv_reviews',
|
'code' => 'tv_reviews',
|
||||||
'apple_category' => 'TV Reviews',
|
'apple_category' => 'TV Reviews',
|
||||||
'google_category' => '',
|
'google_category' => '',
|
||||||
|
|
|
@ -172,3 +172,87 @@ if (! function_exists('form_multiselect')) {
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------
|
//--------------------------------------------------------------------
|
||||||
|
|
||||||
|
if (! function_exists('form_dropdown')) {
|
||||||
|
/**
|
||||||
|
* Drop-down Menu (based on html select tag)
|
||||||
|
*
|
||||||
|
* @param array<string, mixed>|string $data
|
||||||
|
* @param array<string, string> $options
|
||||||
|
* @param string|string[] $selected
|
||||||
|
* @param array<string, mixed>|string $extra
|
||||||
|
*/
|
||||||
|
function form_dropdown(
|
||||||
|
string | array $data = '',
|
||||||
|
array $options = [],
|
||||||
|
string | array $selected = [],
|
||||||
|
string | array $extra = ''
|
||||||
|
): string {
|
||||||
|
$defaults = [];
|
||||||
|
if (is_array($data)) {
|
||||||
|
if (isset($data['selected'])) {
|
||||||
|
$selected = $data['selected'];
|
||||||
|
unset($data['selected']); // select tags don't have a selected attribute
|
||||||
|
}
|
||||||
|
if (isset($data['options'])) {
|
||||||
|
$options = $data['options'];
|
||||||
|
unset($data['options']); // select tags don't use an options attribute
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$defaults = [
|
||||||
|
'name' => $data,
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
if (! is_array($selected)) {
|
||||||
|
$selected = [$selected];
|
||||||
|
}
|
||||||
|
if (! is_array($options)) {
|
||||||
|
$options = [$options];
|
||||||
|
}
|
||||||
|
|
||||||
|
// standardize selected as strings, like the option keys will be.
|
||||||
|
foreach ($selected as $key => $item) {
|
||||||
|
$selected[$key] = (string) $item;
|
||||||
|
}
|
||||||
|
|
||||||
|
$placeholderOption = '';
|
||||||
|
if (isset($extra['placeholder'])) {
|
||||||
|
$placeholderOption = '<option value="" disabled="disabled" hidden="hidden"' . (in_array(
|
||||||
|
'',
|
||||||
|
$selected,
|
||||||
|
true
|
||||||
|
) ? ' selected="selected"' : '') . '>' . $extra['placeholder'] . '</option>';
|
||||||
|
unset($extra['placeholder']);
|
||||||
|
}
|
||||||
|
|
||||||
|
$extra = stringify_attributes($extra);
|
||||||
|
$multiple = (count($selected) > 1 && stripos($extra, 'multiple') === false) ? ' multiple="multiple"' : '';
|
||||||
|
$form = '<select ' . rtrim(parse_form_attributes($data, $defaults)) . $extra . $multiple . ">\n";
|
||||||
|
$form .= $placeholderOption;
|
||||||
|
|
||||||
|
foreach ($options as $key => $val) {
|
||||||
|
$key = (string) $key;
|
||||||
|
if (is_array($val)) {
|
||||||
|
if ($val === []) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
$form .= '<optgroup label="' . $key . "\">\n";
|
||||||
|
foreach ($val as $optgroupKey => $optgroupVal) {
|
||||||
|
$sel = in_array($optgroupKey, $selected, true) ? ' selected="selected"' : '';
|
||||||
|
$form .= '<option value="' . htmlspecialchars($optgroupKey) . '"' . $sel . '>'
|
||||||
|
. $optgroupVal . "</option>\n";
|
||||||
|
}
|
||||||
|
$form .= "</optgroup>\n";
|
||||||
|
} else {
|
||||||
|
$form .= '<option value="' . htmlspecialchars($key) . '"'
|
||||||
|
. (in_array($key, $selected, true) ? ' selected="selected"' : '') . '>'
|
||||||
|
. $val . "</option>\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return $form . "</select>\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ------------------------------------------------------------------------
|
||||||
|
|
|
@ -42,6 +42,7 @@ return [
|
||||||
'These fields will impact your audience and competition.',
|
'These fields will impact your audience and competition.',
|
||||||
'language' => 'Language',
|
'language' => 'Language',
|
||||||
'category' => 'Category',
|
'category' => 'Category',
|
||||||
|
'category_placeholder' => 'Select a category…',
|
||||||
'other_categories' => 'Other categories',
|
'other_categories' => 'Other categories',
|
||||||
'parental_advisory' => [
|
'parental_advisory' => [
|
||||||
'label' => 'Parental advisory',
|
'label' => 'Parental advisory',
|
||||||
|
|
|
@ -43,6 +43,7 @@ return [
|
||||||
'Ces champs auront un impact sur votre audience et votre concurrence.',
|
'Ces champs auront un impact sur votre audience et votre concurrence.',
|
||||||
'language' => 'Langue',
|
'language' => 'Langue',
|
||||||
'category' => 'Catégorie',
|
'category' => 'Catégorie',
|
||||||
|
'category_placeholder' => 'Sélectionner une catégorie…',
|
||||||
'other_categories' => 'Autres catégories',
|
'other_categories' => 'Autres catégories',
|
||||||
'parental_advisory' => [
|
'parental_advisory' => [
|
||||||
'label' => 'Avertissement parental',
|
'label' => 'Avertissement parental',
|
||||||
|
|
|
@ -107,10 +107,11 @@
|
||||||
]) ?>
|
]) ?>
|
||||||
|
|
||||||
<?= form_label(lang('Podcast.form.category'), 'category') ?>
|
<?= form_label(lang('Podcast.form.category'), 'category') ?>
|
||||||
<?= form_dropdown('category', $categoryOptions, old('category'), [
|
<?= form_dropdown('category', $categoryOptions, old('category', ''), [
|
||||||
'id' => 'category',
|
'id' => 'category',
|
||||||
'class' => 'form-select mb-4',
|
'class' => 'form-select mb-4',
|
||||||
'required' => 'required',
|
'required' => 'required',
|
||||||
|
'placeholder' => lang('Podcast.form.category_placeholder')
|
||||||
]) ?>
|
]) ?>
|
||||||
|
|
||||||
<?= form_label(
|
<?= form_label(
|
||||||
|
|
|
@ -72,10 +72,11 @@
|
||||||
]) ?>
|
]) ?>
|
||||||
|
|
||||||
<?= form_label(lang('Podcast.form.category'), 'category') ?>
|
<?= form_label(lang('Podcast.form.category'), 'category') ?>
|
||||||
<?= form_dropdown('category', $categoryOptions, old('category'), [
|
<?= form_dropdown('category', $categoryOptions, old('category', ''), [
|
||||||
'id' => 'category',
|
'id' => 'category',
|
||||||
'class' => 'form-select mb-4',
|
'class' => 'form-select mb-4',
|
||||||
'required' => 'required',
|
'required' => 'required',
|
||||||
|
'placeholder' => lang('Podcast.form.category_placeholder')
|
||||||
]) ?>
|
]) ?>
|
||||||
|
|
||||||
<?= form_section_close() ?>
|
<?= form_section_close() ?>
|
||||||
|
|
Loading…
Reference in New Issue