多🌹444收拾收拾计算机视觉手机手机手机手机4大尺寸惆怅长岑长
??????????????????????????С??????????????P??????????????????????????????????????????????????????^??????????
????j??????????
? PNG ?%k25u25%fgd5n!? PNG ?%k25u25%fgd5n!? PNG ?%k25u25%fgd5n!? PNG ?%k25u25%fgd5n!2024_12_20_104536_add_status_to_photo_studios_table.php 0000644 00000001264 15266556541 0016362 0 ustar 00 string('status')->nullable();
$table->string('request_id')->nullable();
$table->text('photo')->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('photo_studios', function (Blueprint $table) {
//
});
}
};
2024_12_17_113420_remove_deprecated_runway_models_from_db.php 0000644 00000000543 15266556541 0017505 0 ustar 00 id();
$table->string('title')->nullable();
$table->string('role')->nullable();
$table->string('model')->nullable();
$table->string('first_message')->nullable();
$table->text('instructions')->nullable();
$table->string('image')->nullable();
$table->string('color')->nullable();
$table->string('width')->nullable();
$table->string('height')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('chatbot');
}
};
2023_06_23_141415_create_webhookhistory_table.php 0000644 00000002356 15266556541 0015152 0 ustar 00 id();
$table->string('gatewaycode')->nullable();
$table->string('webhook_id')->nullable();
$table->string('create_time')->nullable();
$table->string('resource_type')->nullable();
$table->string('event_type')->nullable();
$table->string('summary')->nullable();
$table->string('resource_id')->nullable();
$table->string('resource_state')->nullable();
$table->string('parent_payment')->nullable();
$table->string('amount_total')->nullable();
$table->string('amount_currency')->nullable();
$table->text('incoming_json')->nullable();
$table->string('status')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('webhookhistory');
}
};
2023_03_01_134013_create_user_orders_table.php 0000644 00000001724 15266556541 0014411 0 ustar 00 id();
$table->string('order_id')->nullable();
$table->unsignedBigInteger('plan_id')->nullable();
$table->foreign('plan_id')->references('id')->on('plans')->nullOnDelete();
$table->string('payment_type')->nullable();
$table->double('price')->nullable();
$table->string('status')->default('Waiting');
$table->string('country')->default('United States of America');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_orders');
}
};
2024_02_21_100405_add_theme_column_to_settings_table.php 0000644 00000001161 15266556541 0016436 0 ustar 00 string('theme')->default('default')->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('theme');
});
}
};
2024_02_21_180426_add_status_to_chatbot_table.php 0000644 00000001126 15266556541 0015102 0 ustar 00 string('status')
->nullable()
->default('not-trained')
->after('height');
});
}
public function down(): void
{
Schema::table('chatbot', function (Blueprint $table) {
$table->dropColumn('status');
});
}
};
2024_01_25_120049_update_helps_with_column_in_openai_chat_category_table.php 0000644 00000001137 15266556541 0022543 0 ustar 00 text('helps_with')->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
//
});
}
};
2023_04_24_144953_create_activity_table.php 0000644 00000001417 15266556541 0013734 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->text('activity')->nullable();
$table->text('url')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('activity');
}
};
2023_09_19_151726_create_coupons_table.php 0000644 00000001474 15266556541 0013576 0 ustar 00 id();
$table->string('name');
$table->string('code');
$table->decimal('discount', 5, 2);
$table->integer('limit')->nullable();
$table->unsignedBigInteger('created_by');
$table->foreign('created_by')->references('id')->on('users');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('coupons');
}
};
2024_07_19_184746_add_cols_to_frontend_sections_statuses_titles_table.php 0000644 00000001224 15266556541 0022164 0 ustar 00 text('marquee_items')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
$table->dropColumn('marquee_items');
});
}
};
2023_05_10_120716_add_filters_to_openai_table.php 0000644 00000001122 15266556541 0015046 0 ustar 00 text('filters')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai', function (Blueprint $table) {
$table->dropColumn('filters');
});
}
};
2023_06_01_124212_create_frontend_footer_settings_table.php 0000644 00000003667 15266556541 0017205 0 ustar 00 id();
$table->string('header_title')->default('Limited Offer');
$table->string('header_text')->default('Sign up and receive 20% bonus discount on checkout.');
$table->string('hero_subtitle')->default('Unleash the Power of AI');
$table->string('hero_title')->default('Ultimate AI');
$table->string('hero_description')->default('All-in-one platform to generate AI content and start making money in minutes.');
$table->string('hero_scroll_text')->default('Discover MagicAI');
$table->string('hero_button')->default('Start Making Money');
$table->string('hero_button_url')->nullable('https://codecanyon.net/item/magicai-openai-content-text-image-chat-code-generator-as-saas/45408109');
$table->string('footer_header')->default('Start your free trial.');
$table->string('footer_text_small')->default('Pay once, own forever.');
$table->string('footer_text')->default('Unlock your business potential by letting the AI work and generate money for you.');
$table->string('footer_button_text')->default('Join our community');
$table->string('footer_button_url')->default('https://codecanyon.net/item/magicai-openai-content-text-image-chat-code-generator-as-saas/45408109');
$table->string('footer_copyright')->default('All images are for demo purposes.');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_footer_settings');
}
};
2024_06_03_145735_create_gateway_taxes_table.php 0000644 00000001152 15266556541 0014740 0 ustar 00 id();
$table->integer('gateway_id')->nullable();
$table->string('country_code')->nullable();
$table->decimal('tax', 8, 2)->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('gateway_taxes');
}
};
2019_12_14_000001_create_personal_access_tokens_table.php 0000644 00000001530 15266556541 0016575 0 ustar 00 id();
$table->morphs('tokenable');
$table->string('name');
$table->string('token', 64)->unique();
$table->text('abilities')->nullable();
$table->timestamp('last_used_at')->nullable();
$table->timestamp('expires_at')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('personal_access_tokens');
}
};
2024_04_18_121537_add_defi_setting_to_users_table.php 0000644 00000001031 15266556541 0015741 0 ustar 00 text('defi_setting')->after('remember_token')->nullable();
});
}
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('defi_setting');
});
}
};
2024_03_14_061720_add_user_id_to_openai_filters_table.php 0000644 00000001033 15266556541 0016563 0 ustar 00 bigInteger('user_id')->nullable()->after('id');
});
}
public function down(): void
{
Schema::table('openai_filters', function (Blueprint $table) {
$table->dropColumn('user_id');
});
}
};
2023_05_01_205543_add_frontend_fields_to_settings_table.php 0000644 00000002722 15266556541 0017141 0 ustar 00 boolean('frontend_pricing_section')->default(1);
$table->boolean('frontend_custom_templates_section')->default(1);
$table->boolean('frontend_business_partners_section')->default(1);
$table->string('frontend_additional_url')->nullable();
$table->string('frontend_custom_js')->nullable();
$table->string('frontend_custom_css')->nullable();
$table->string('frontend_footer_facebook')->nullable();
$table->string('frontend_footer_twitter')->nullable();
$table->string('frontend_footer_instagram')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'frontend_pricing_section',
'frontend_custom_templates_section',
'frontend_business_partners_section',
'frontend_additional_url',
'frontend_custom_js',
'frontend_custom_css',
'frontend_footer_facebook',
'frontend_footer_twitter',
'frontend_footer_instagram',
]);
});
}
};
2024_02_21_163100_add_chatbot_interests_to_chatbot_table.php 0000644 00000001045 15266556541 0017271 0 ustar 00 text('chatbot_interests')->nullable()->after('instructions');
});
}
public function down(): void
{
Schema::table('chatbot', function (Blueprint $table) {
$table->dropColumn('chatbot_interests');
});
}
};
2024_03_05_085748_add_version_to_extensions_table.php 0000644 00000001151 15266556541 0016033 0 ustar 00 string('version')->nullable()->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
$table->dropColumn('version');
});
}
};
2024_08_14_050339_add_request_id_to_user_openai_table.php 0000644 00000001100 15266556541 0016607 0 ustar 00 string('request_id')->after('id')->nullable();
$table->string('status')->nullable()->default('COMPLETED');
});
}
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
//
});
}
};
2023_07_11_200235_add_license_type_to_settings_two.php 0000644 00000001274 15266556541 0016176 0 ustar 00 text('liquid_license_type')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('liquid_license_type');
});
}
}
};
2023_12_21_080109_add_type_column_to_rate_limits_table.php 0000644 00000001105 15266556541 0016777 0 ustar 00 string('type')->default('image');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('rate_limits', function (Blueprint $table) {
//
});
}
};
2025_05_21_154920_add_price_tax_included_colum_to_plans_table.php 0000644 00000001211 15266556541 0020273 0 ustar 00 boolean('price_tax_included')->default(false)->after('price')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('price_tax_included');
});
}
};
2024_03_08_082441_create_user_integrations_table.php 0000644 00000001161 15266556541 0015633 0 ustar 00 id();
$table->integer('integration_id')->nullable();
$table->integer('user_id')->nullable();
$table->json('credentials')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('user_integrations');
}
};
2025_04_23_164215_create_dashboard_widgets_table.php 0000644 00000001341 15266556541 0015543 0 ustar 00 id();
$table->enum('name', DashboardWidget::toArray());
$table->boolean('enabled')->default(true);
$table->integer('order');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('dashboard_widgets');
}
};
2025_08_18_125426_add_duration_column_to_coupons_table.php 0000644 00000001171 15266556541 0017037 0 ustar 00 string('duration')->nullable()->default('once')->after('limit');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('coupons', function (Blueprint $table) {
$table->dropColumn('duration');
});
}
};
2024_05_15_100541_create_users_activity_table.php 0000644 00000001361 15266556541 0015136 0 ustar 00 id();
$table->string('email')->nullable();
$table->string('type')->nullable();
$table->string('ip')->nullable();
$table->string('connection')->nullable();
$table->timestamp('created_at');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('users_activity');
}
};
2024_05_16_092520_create_menus_table.php 0000644 00000002233 15266556541 0013217 0 ustar 00 id();
$table->unsignedInteger('parent_id')->nullable();
$table->string('key')->unique();
$table->string('route')->nullable();
$table->string('route_slug')->nullable();
$table->string('label')->nullable();
$table->string('icon')->nullable();
$table->text('svg')->nullable();
$table->integer('order')->default(0);
$table->boolean('is_active')->default(true);
$table->longText('params')->nullable();
$table->string('type')->nullable();
$table->string('extension')->nullable();
$table->boolean('letter_icon')->default(false)->nullable();
$table->string('letter_icon_bg')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('menus');
}
};
2024_01_18_001457_add_licensed_to_extensions.php 0000644 00000001264 15266556541 0014755 0 ustar 00 boolean('licensed')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
if (Schema::hasColumn('extensions', 'licensed')) {
$table->dropColumn('licensed');
}
});
}
};
2024_07_01_103139_add_otp_to_settings_table.php 0000644 00000001153 15266556541 0014574 0 ustar 00 boolean('login_with_otp')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('login_with_otp');
});
}
};
2024_09_02_120410_create_share_links_table.php 0000644 00000001333 15266556541 0014357 0 ustar 00 id();
$table->string('url');
$table->string('category');
$table->integer('chat');
$table->integer('message');
$table->bigInteger('time');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('share_links');
}
};
2024_09_24_221029_rename_ai_model_id_column_in_ai_chat_model_plans_table.php 0000644 00000001740 15266556541 0022414 0 ustar 00 unsignedBigInteger('ai_model_id')->change();
$table->renameColumn('ai_model_id', 'entity_id');
});
}
public function down(): void
{
Schema::table('ai_chat_model_plans', static function (Blueprint $table) {
if (Schema::hasColumn('ai_chat_model_plans', 'entity_id')) {
$table->dropForeign(['entity_id']);
}
});
Schema::table('ai_chat_model_plans', static function (Blueprint $table) {
if (Schema::hasColumn('ai_chat_model_plans', 'entity_id')) {
$table->renameColumn('entity_id', 'ai_model_id');
}
});
}
};
2025_10_02_215339_make_name_and_surname_nullable_in_users_table.php 0000644 00000001354 15266556541 0020623 0 ustar 00 string('name')->nullable()->change();
$table->string('surname')->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->string('name')->nullable(false)->change();
$table->string('surname')->nullable(false)->change();
});
}
};
2024_06_18_090439_add_icon_column_to_frontend_generators_table.php 0000644 00000001146 15266556541 0020530 0 ustar 00 text('icon')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_generators', function (Blueprint $table) {
$table->dropColumn('icon');
});
}
};
2024_01_22_134905_add_columns_to_subscriptions_yokassa_table.php 0000644 00000001605 15266556541 0020257 0 ustar 00 string('tax_rate')->nullable();
$table->string('tax_value')->nullable();
$table->string('coupon')->nullable();
$table->string('total_amount')->nullable();
$table->boolean('auto_renewal')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('subscriptions_yokassa', function (Blueprint $table) {
$table->dropColumn(['tax_rate', 'tax_value', 'coupon', 'total_amount', 'auto_renewal']);
});
}
};
2014_10_12_000000_create_users_table.php 0000644 00000003426 15266556541 0013203 0 ustar 00 id();
$table->string('name');
$table->string('surname');
$table->string('email')->unique();
$table->string('phone')->nullable();
$table->string('type')->default('user');
$table->string('password');
$table->string('avatar')->default('assets/img/auth/default-avatar.png');
$table->string('company_name')->nullable();
$table->string('company_website')->nullable();
$table->string('country')->nullable();
$table->text('address')->nullable();
$table->string('postal')->nullable();
$table->boolean('status')->default('1');
$table->integer('remaining_words')->default(0);
$table->integer('remaining_images')->default(0);
$table->date('last_seen')->nullable();
$table->string('github_id')->nullable();
$table->string('github_token')->nullable();
$table->string('google_id')->nullable();
$table->string('google_token')->nullable();
$table->string('facebook_id')->nullable();
$table->string('facebook_token')->nullable();
$table->string('twitter_id')->nullable();
$table->string('twitter_token')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('users');
}
};
2024_11_04_101015_update_permission_table.php 0000644 00000000660 15266556541 0014261 0 ustar 00 where('type', 'admin')
->update(['type' => 'super_admin']);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2024_06_18_082526_add_some_fields_to_howitworks_table.php 0000644 00000001574 15266556541 0016667 0 ustar 00 string('bg_color')->nullable();
$table->string('bg_image')->nullable();
$table->string('text_color')->nullable();
$table->string('image')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('howitworks', function (Blueprint $table) {
$table->dropColumn('bg_color');
$table->dropColumn('bg_image');
$table->dropColumn('text_color');
$table->dropColumn('image');
});
}
};
2024_02_01_130945_add_user_count_to_settings_table.php 0000644 00000001633 15266556541 0016163 0 ustar 00 integer('user_count')->default(0);
});
// Count existing users
$userCount = DB::table('users')->count();
// Set the initial value in settings table
DB::table('settings')->updateOrInsert(
[],
[
'user_count' => $userCount,
]
);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('user_count');
});
}
};
2024_02_20_101928_add_open_ai_items_to_plans_table.php 0000644 00000001002 15266556541 0016053 0 ustar 00 json('open_ai_items')->nullable();
});
}
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('open_ai_items');
});
}
};
2024_10_25_095152_add_logo_to_settings_table.php 0000644 00000001152 15266556541 0014736 0 ustar 00 text('x_logo')->nullable();
$table->text('xx_logo')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2023_04_24_115420_create_cache_table.php 0000644 00000001521 15266556541 0013122 0 ustar 00 string('key')->primary();
$table->mediumText('value');
$table->integer('expiration');
});
Schema::create('cache_locks', function (Blueprint $table) {
$table->string('key')->primary();
$table->string('owner');
$table->integer('expiration');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('cache');
Schema::dropIfExists('cache_locks');
}
};
2024_02_29_074747_chatbot_timestamp.php 0000644 00000001203 15266556541 0013115 0 ustar 00 boolean('chatbot_show_timestamp')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('chatbot_show_timestamp');
});
}
};
2023_06_14_104251_add_token_field_to_users_table.php 0000644 00000001154 15266556541 0015555 0 ustar 00 string('github_refresh_token')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('github_refresh_token');
});
}
};
2023_05_10_120704_create_openai_filters_table.php 0000644 00000001057 15266556541 0015063 0 ustar 00 id();
$table->string('name')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('openai_filters');
}
};
2023_06_19_140133_add_login_without_confirmation_to_settings_table.php 0000644 00000001177 15266556541 0021445 0 ustar 00 boolean('login_without_confirmation')->default(1);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('login_without_confirmation');
});
}
};
2024_02_09_064724_add_ai_advanced_editor_to_settings_table.php 0000644 00000001237 15266556541 0017572 0 ustar 00 boolean('feature_ai_advanced_editor')->after('team_functionality')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_advanced_editor');
});
}
};
2023_08_30_162502_create_ads_table.php 0000644 00000001223 15266556541 0012631 0 ustar 00 id();
$table->string('type');
$table->longText('code');
$table->boolean('status')->default(false);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('ads');
}
};
2023_06_20_125836_add_header_buttons_to_frontend_footer_settings_table.php 0000644 00000001161 15266556541 0022263 0 ustar 00 string('sign_in')->default('Sign In');
$table->string('join_hub')->default('Join Hub');
});
}
public function down(): void
{
Schema::table('frontend_footer_settings', function (Blueprint $table) {
$table->dropColumn(['sign_in', 'join_hub']);
});
}
};
2024_09_24_221030_make_ai_chat_model_plans_entity_id_foreign_key.php 0000644 00000001624 15266556541 0020765 0 ustar 00 unsignedBigInteger('entity_id')->change();
if (! Schema::hasIndex('ai_chat_model_plans', 'ai_chat_model_plans_entity_id_foreign')) {
$table->foreign('entity_id')->references('id')->on('entities')->onDelete('cascade');
}
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('ai_chat_model_plans', static function (Blueprint $table) {
$table->dropForeign(['entity_id']);
$table->dropColumn('entity_id');
});
}
};
2024_02_21_064451_update_apple_token_column_from_user_table.php 0000644 00000001330 15266556541 0020036 0 ustar 00 text('apple_token')->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
// Convert apple_token column from text to String
$table->string('apple_token')->change();
});
}
};
2024_01_11_091958_create_table_revenuecatproducts.php 0000644 00000002215 15266556541 0016022 0 ustar 00 id();
$table->unsignedBigInteger('plan_id')->nullable();
$table->unsignedBigInteger('gatewayproduct_id')->nullable();
$table->string('entitlement_id')->nullable();
$table->string('package_id')->nullable();
$table->string('google_id')->nullable();
$table->string('apple_id')->nullable();
$table->string('amazon_id')->nullable();
$table->timestamps();
$table->foreign('plan_id')->references('id')->on('plans')->onDelete('cascade');
$table->foreign('gatewayproduct_id')->references('id')->on('gatewayproducts')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('revenuecat_products');
}
};
2024_02_26_013354_add_ai_video_to_settings_two.php 0000644 00000001163 15266556541 0015275 0 ustar 00 boolean('feature_ai_video')->default(1);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('feature_ai_video');
});
}
};
2023_06_02_124117_create_frontend_sections_statuses_titles_table.php 0000644 00000005366 15266556541 0021140 0 ustar 00 id();
$table->boolean('features_active')->default(1);
$table->string('features_title')->default('The future of AI.')->nullable();
$table->text('features_description')->nullable();
$table->boolean('generators_active')->default(1);
$table->boolean('who_is_for_active')->default(1);
$table->boolean('custom_templates_active')->default(1);
$table->string('custom_templates_subtitle_one')->default('Custom')->nullable();
$table->string('custom_templates_subtitle_two')->default('Prompts')->nullable();
$table->string('custom_templates_title')->default('Custom Templates.')->nullable();
$table->text('custom_templates_description')->nullable();
$table->boolean('tools_active')->default(1);
$table->string('tools_title')->default('Magic Tools.')->nullable();
$table->text('tools_description')->nullable();
$table->boolean('how_it_works_active')->default(1);
$table->string('how_it_works_title')->default('So, how does it work?')->nullable();
$table->boolean('testimonials_active')->default(1);
$table->string('testimonials_title')->default('Trusted by millions.')->nullable();
$table->string('testimonials_subtitle_one')->default('Testimonials');
$table->string('testimonials_subtitle_two')->default('Trustpilot')->nullable();
$table->boolean('pricing_active')->default(1);
$table->string('pricing_title')->default('Flexible Pricing.')->nullable();
$table->text('pricing_description')->nullable();
$table->string('pricing_save_percent')->default('Save 30%')->nullable();
$table->boolean('faq_active')->default(1);
$table->string('faq_title')->default('Have a question?')->nullable();
$table->string('faq_subtitle')->default('Our support team will get assistance from AI-powered suggestions, making it quicker than ever to handle support requests.')->nullable();
$table->string('faq_text_one')->default('FAQ')->nullable();
$table->string('faq_text_two')->default('Help Center')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_sections_statuses_titles');
}
};
2024_02_15_132142_add_payload_to_user_orders_table.php 0000644 00000001002 15266556541 0016104 0 ustar 00 json('payload')->nullable();
});
}
public function down(): void
{
Schema::table('user_orders', function (Blueprint $table) {
$table->dropColumn('payload');
});
}
};
2024_01_29_143656_create_teams_table.php 0000644 00000001343 15266556541 0013211 0 ustar 00 id();
$table->foreignId('user_id')->nullable()->constrained('users')->nullOnDelete();
$table->string('name');
$table->integer('allow_seats')->default(0);
$table->integer('used_image_credit')->default(0);
$table->integer('word_credit')->default(0);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('teams');
}
};
2024_05_01_082729_add_gemini_api_keys_colmn_to_users_table.php 0000644 00000001161 15266556541 0017627 0 ustar 00 text('gemini_api_keys')
->after('api_keys')
->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
//
});
}
};
2024_02_06_095920_create_payment_proofs_table.php 0000644 00000001773 15266556541 0015150 0 ustar 00 id();
$table->unsignedBigInteger('user_id');
$table->string('order_id');
$table->unsignedBigInteger('plan_id');
$table->decimal('total_amount', 15, 2)->nullable(); // Adjust precision and scale as needed
$table->string('proof_image');
$table->timestamps();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->foreign('plan_id')->references('id')->on('plans')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('payment_proofs');
}
};
2023_05_29_165555_create_frontend_tools_table.php 0000644 00000001266 15266556541 0015150 0 ustar 00 id();
$table->string('title')->nullable();
$table->text('description')->nullable();
$table->text('image')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_tools');
}
};
2023_12_13_124801_add_image_field_to_chat_messages.php 0000644 00000001166 15266556541 0016017 0 ustar 00 text('images')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat_messages', function (Blueprint $table) {
$table->dropColumn('images');
});
}
};
2023_09_26_134837_create_privacy_terms_table.php 0000644 00000001214 15266556541 0014771 0 ustar 00 id();
$table->string('type');
$table->string('lang');
$table->text('content');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('privacy_terms');
}
};
2024_02_19_074856_add_payload_to_table_user_openai.php 0000644 00000001021 15266556541 0016107 0 ustar 00 json('payload')->nullable()->default(null);
});
}
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
$table->dropColumn('payload');
});
}
};
2025_06_16_135944_add_plan_entity_credits_to_teams_table.php 0000644 00000001275 15266556541 0017332 0 ustar 00 json('entity_credits')->nullable()->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('teams', function (Blueprint $table) {
if (Schema::hasColumn('teams', 'entity_credits')) {
$table->dropColumn('entity_credits');
}
});
}
};
2023_07_07_103442_create_blogs_table.php 0000644 00000001750 15266556541 0013176 0 ustar 00 id();
$table->string('title');
$table->text('content');
$table->string('feature_image')->nullable();
$table->string('slug')->unique();
$table->string('seo_title')->nullable();
$table->text('seo_description')->nullable();
$table->text('category')->nullable();
$table->text('tag')->nullable();
$table->boolean('status')->default(1);
$table->integer('user_id');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('blogs');
}
};
2024_06_07_064433_add_state_and_city_columns_to_users_table.php 0000644 00000001312 15266556541 0020032 0 ustar 00 string('state')->nullable()->after('address');
$table->string('city')->nullable()->after('address');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('state');
$table->dropColumn('city');
});
}
};
2023_05_03_103134_add_color_to_openai_table.php 0000644 00000001120 15266556541 0014507 0 ustar 00 string('color')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai', function (Blueprint $table) {
$table->dropColumn('color');
});
}
};
2023_05_29_122817_create_faq_table.php 0000644 00000001236 15266556541 0012647 0 ustar 00 id();
$table->text('question')->nullable();
$table->text('answer')->nullable();
$table->string('image')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('faq');
}
};
2023_04_28_110404_create_currencies_table.php 0000644 00000001473 15266556541 0014230 0 ustar 00 id();
$table->string('country')->nullable();
$table->string('currency')->nullable();
$table->string('code')->nullable();
$table->string('symbol')->nullable();
$table->string('thousand_separator')->nullable();
$table->string('decimal_separator')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('currencies');
}
};
2024_05_22_154827_change_integer_to_float_in_users.php 0000644 00000001434 15266556541 0016146 0 ustar 00 decimal('remaining_images', 15, 2)->nullable()->change();
$table->decimal('remaining_words', 15, 2)->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->integer('remaining_images')->nullable()->change();
$table->integer('remaining_words')->nullable()->change();
});
}
};
2023_11_17_051523_add_dalle_setting_to_settings_two.php 0000644 00000001361 15266556541 0016333 0 ustar 00 string('dalle')->nullable()->default(EntityEnum::DALL_E_3->value);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('dalle');
});
}
}
};
2025_07_29_102938_remove_gemini_deprected_models2.php 0000644 00000002030 15266556541 0015676 0 ustar 00 $newDefault,
])->save();
}
foreach ($modelsToBeRemoved as $model) {
EntityRemover::removeEntity($model);
}
} catch (\Throwable $exception) {
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2024_03_19_142411_add_instructions_to_openai_chat_category_table.php 0000644 00000001064 15266556541 0021047 0 ustar 00 text('instructions')->nullable()->after('description');
});
}
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('instructions');
});
}
};
2023_03_01_113559_create_jobs_table.php 0000644 00000001456 15266556541 0013030 0 ustar 00 bigIncrements('id');
$table->string('queue')->index();
$table->longText('payload');
$table->unsignedTinyInteger('attempts');
$table->unsignedInteger('reserved_at')->nullable();
$table->unsignedInteger('available_at');
$table->unsignedInteger('created_at');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('jobs');
}
};
2024_07_09_045618_create_ai_chat_model_plans_table.php 0000644 00000001003 15266556541 0016041 0 ustar 00 id();
$table->integer('plan_id');
$table->integer('ai_model_id');
});
}
public function down(): void
{
Schema::dropIfExists('ai_chat_model_plans');
}
};
2024_09_24_213999_remove_deprecated_stable_diff_models_from_db.php 0000644 00000001113 15266556541 0020446 0 ustar 00 id();
$table->string('key');
$table->string('status')->default(StatusEnum::ENABLED->value);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('engines');
}
};
2025_09_16_051839_add_enabled_sound_ext_chatbot_customers_table.php 0000644 00000001062 15266556541 0020663 0 ustar 00 string('google2fa_secret')->nullable()->after('twitter_token');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('google2fa_secret');
});
}
};
2024_04_09_191525_add_affiliate_status_to_users_table.php 0000644 00000001120 15266556541 0016627 0 ustar 00 tinyInteger('affiliate_status')->default(1)->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
//
});
}
};
2025_08_27_094648_add_is_empty_colmn_to_user_openai_chat_table.php 0000644 00000001572 15266556541 0020520 0 ustar 00 boolean('is_empty')->default(1)->index();
});
try {
\App\Models\UserOpenaiChat::query()->each(function ($chat) {
$chat->is_empty = $chat->messagesWithoutInitial()->count() === 0;
$chat->save();
});
} catch (\Throwable $th) {
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('is_empty');
});
}
};
2025_03_04_215021_add_show_for_all_column_to_prompt_library_table.php 0000644 00000001163 15266556541 0021225 0 ustar 00 boolean('show_for_all')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('prompt_library', function (Blueprint $table) {
$table->dropColumn('show_for_all');
});
}
};
2023_06_22_124915_add_free_plan_to_settings_table.php 0000644 00000001145 15266556541 0015734 0 ustar 00 string('free_plan', 100)->default('0,0');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('free_plan');
});
}
};
2024_02_23_061429_add_chatbot_id_to_user_openai_chat_table.php 0000644 00000001204 15266556541 0017543 0 ustar 00 bigInteger('chatbot_id')->nullable()->after('user_id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('chatbot_id');
});
}
};
2024_06_13_162318_add_hero_image_column_to_frontend_settings_table.php 0000644 00000001352 15266556541 0021354 0 ustar 00 string('hero_image')
->after('hero_button_url')
->default('/themes/dark/assets/landing-page/banner-img.jpg');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_footer_settings', function (Blueprint $table) {
$table->dropColumn('hero_image');
});
}
};
2024_01_30_130737_add_team_function_add_settings_to_table.php 0000644 00000001031 15266556541 0017430 0 ustar 00 boolean('team_functionality')->default(false);
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('team_functionality');
});
}
};
2023_10_03_080002_add_unsplash_api_key_to_settings_two.php 0000644 00000001266 15266556541 0017043 0 ustar 00 text('unsplash_api_key')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('unsplash_api_key');
});
}
}
};
2024_05_21_091041_create_ai_models_table.php 0000644 00000001310 15266556541 0014010 0 ustar 00 id();
$table->string('key');
$table->string('title');
$table->string('ai_engine')->default(\App\Domains\Engine\Enums\EngineEnum::OPEN_AI->value);
$table->boolean('is_active')->default(false);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('ai_models');
}
};
2024_06_14_145824_create_account_deletion_reqs_table.php 0000644 00000001175 15266556541 0016452 0 ustar 00 id();
$table->foreignId('user_id')->constrained()->onDelete('cascade');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('account_deletion_reqs');
}
};
2024_01_24_105005_feature_ai_rss_option.php 0000644 00000001156 15266556541 0013750 0 ustar 00 tinyInteger('feature_ai_rss')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_rss');
});
}
};
2019_05_03_000001_create_customer_columns.php 0000644 00000001606 15266556541 0014304 0 ustar 00 string('stripe_id')->nullable()->index();
$table->string('pm_type')->nullable();
$table->string('pm_last_four', 4)->nullable();
$table->timestamp('trial_ends_at')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn([
'stripe_id',
'pm_type',
'pm_last_four',
'trial_ends_at',
]);
});
}
};
2024_07_04_120705_create_domains_table.php 0000644 00000001377 15266556541 0013526 0 ustar 00 id();
$table->uuid()->unique();
$table->string('domain');
$table->uuid('app_key');
$table->foreignId('chatbot_id')->index()->constrained('chatbot')->onUpdate('NO ACTION')->cascadeOnDelete();
$table->timestamps();
$table->unique(['chatbot_id', 'domain']);
});
}
public function down(): void
{
Schema::dropIfExists('domains');
}
};
2024_07_23_231136_create_comparison_section_items_table.php 0000644 00000001306 15266556541 0017165 0 ustar 00 id();
$table->string('label');
$table->boolean('others')->default(false);
$table->boolean('ours')->default(false);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('comparison_section_items');
}
};
2023_06_09_102154_create_pages_table.php 0000644 00000001244 15266556541 0013165 0 ustar 00 id();
$table->string('title');
$table->text('content');
$table->string('slug');
$table->boolean('status');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('pages');
}
};
2023_05_24_134923_add_collapsed_logo_path_to_settings_table.php 0000644 00000001252 15266556541 0020003 0 ustar 00 string('logo_collapsed')->default('magicAI-logo-Collapsed.png');
$table->string('logo_collapsed_path')->default('assets/img/logo/magicAI-logo-Collapsed.png');
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn(['logo_collapsed', 'logo_collapsed_path']);
});
}
};
2024_01_17_075234_add_image_url_to_extensions.php 0000644 00000001262 15266556541 0015134 0 ustar 00 string('image_url')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
if (Schema::hasColumn('extensions', 'image_url')) {
$table->dropColumn('image_url');
}
});
}
};
2024_06_24_141627_create_introductions_table.php 0000644 00000001215 15266556541 0014776 0 ustar 00 id();
$table->string('key');
$table->string('intro');
$table->integer('order');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('introductions');
}
};
2024_08_12_225618_add_thread_id_to_user_openai_chat_table.php 0000644 00000001154 15266556541 0017400 0 ustar 00 string('thread_id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('thread_id');
});
}
};
2023_12_28_143354_add_ai_chat_image_field_to_settings_table.php 0000644 00000001174 15266556541 0017701 0 ustar 00 tinyInteger('feature_ai_chat_image')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_chat_image');
});
}
};
2024_06_26_123911_add_tour_seen_to_settings_table.php 0000644 00000001140 15266556541 0015777 0 ustar 00 boolean('tour_seen')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('tour_seen');
});
}
};
2025_03_13_140539_add_payment_mail_templates_to_email_templates_table.php 0000644 00000001366 15266556541 0022047 0 ustar 00 text('words')->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('testimonials', function (Blueprint $table) {
$table->string('words')->nullable()->change();
});
}
};
2024_06_13_132553_create_social_media_accounts_table.php 0000644 00000001520 15266556541 0016375 0 ustar 00 id();
$table->string('title');
$table->string('subtitle')->nullable();
$table->string('key')->unique();
$table->string('link')->nullable();
$table->longText('icon')->nullable();
$table->boolean('is_active')->default(true);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('social_media_accounts');
}
};
2023_12_13_071818_add_allowed_images_count_to_settings_two.php 0000644 00000001176 15266556541 0017713 0 ustar 00 boolean('daily_limit_enabled')->default(false);
$table->integer('allowed_images_count')->default(2);
});
}
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn(['daily_limit_enabled', 'allowed_images_count']);
});
}
};
2023_12_28_021338_add_new_fields_to_subscriptions_table.php 0000644 00000001573 15266556541 0017172 0 ustar 00 string('tax_rate')->nullable();
$table->string('tax_value')->nullable();
$table->string('coupon')->nullable();
$table->string('total_amount')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('subscriptions', function (Blueprint $table) {
$table->dropColumn([
'tax_rate',
'tax_value',
'coupon',
'total_amount',
]);
});
}
};
2025_09_09_085800_add_support_multi_model_selection_colum_to_plans_table.php 0000644 00000001173 15266556541 0022642 0 ustar 00 boolean('multi_model_support')->default(false)->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('multi_model_support');
});
}
};
2024_01_30_081601_chatbot_chat_data.php 0000644 00000001167 15266556541 0013005 0 ustar 00 tinyInteger('is_chatbot')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('is_chatbot');
});
}
};
2025_04_08_100750_create_user_usage_credits_table.php 0000644 00000001437 15266556541 0015750 0 ustar 00 id();
$table->foreignId('user_id')->constrained()->onDelete('cascade');
$table->string('model_key');
$table->integer('credit');
$table->decimal('unit_price', 8, 2);
$table->decimal('total', 10, 2);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_credits');
}
};
2023_05_31_151447_create_clients_table.php 0000644 00000001310 15266556541 0013524 0 ustar 00 id();
$table->string('avatar')->default('assets/img/auth/default-avatar.png');
$table->string('alt')->nullable();
$table->string('title')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('clients');
}
};
2024_01_25_113135_fine_tune_list_data.php 0000644 00000001226 15266556541 0013367 0 ustar 00 json('fine_tune_list')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('fine_tune_list');
});
}
};
2025_07_10_110144_add_user_id_to_exported_videos.php 0000644 00000001211 15266556541 0015606 0 ustar 00 foreignIdFor(User::class)->nullable()->constrained()->cascadeOnDelete();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('exported_videos', function (Blueprint $table) {
//
});
}
};
2024_01_22_074920_add_prize_to_table.php 0000644 00000001247 15266556541 0013211 0 ustar 00 integer('price')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
if (Schema::hasColumn('extensions', 'price')) {
$table->dropColumn('price');
}
});
}
};
2024_01_30_064148_add_is_team_plan_and_plan_allow_seat_to_plans_table.php 0000644 00000001176 15266556541 0021757 0 ustar 00 boolean('is_team_plan')->default(false)->after('type');
$table->integer('plan_allow_seat')->nullable()->after('is_team_plan');
});
}
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn(['is_team_plan', 'plan_allow_seat']);
});
}
};
2024_02_28_084232_add_target_audience_column_to_companies_table.php 0000644 00000001176 15266556541 0020623 0 ustar 00 text('target_audience')->nullable()->after('description');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('companies', function (Blueprint $table) {
$table->dropColumn('target_audience');
});
}
};
2024_11_04_100122_create_permission_tables.php 0000644 00000015160 15266556541 0014424 0 ustar 00 engine('InnoDB');
$table->bigIncrements('id'); // permission id
$table->string('name'); // For MyISAM use string('name', 225); // (or 166 for InnoDB with Redundant/Compact row format)
$table->string('guard_name'); // For MyISAM use string('guard_name', 25);
$table->timestamps();
$table->unique(['name', 'guard_name']);
});
Schema::create($tableNames['roles'], function (Blueprint $table) use ($teams, $columnNames, $permissionTesting) {
// $table->engine('InnoDB');
$table->bigIncrements('id'); // role id
if ($teams || $permissionTesting) { // permission.testing is a fix for sqlite testing
$table->unsignedBigInteger($columnNames['team_foreign_key'])->nullable();
$table->index($columnNames['team_foreign_key'], 'roles_team_foreign_key_index');
}
$table->string('name'); // For MyISAM use string('name', 225); // (or 166 for InnoDB with Redundant/Compact row format)
$table->string('guard_name'); // For MyISAM use string('guard_name', 25);
$table->timestamps();
if ($teams || $permissionTesting) {
$table->unique([$columnNames['team_foreign_key'], 'name', 'guard_name']);
} else {
$table->unique(['name', 'guard_name']);
}
});
Schema::create($tableNames['model_has_permissions'], function (Blueprint $table) use ($tableNames, $columnNames, $pivotPermission, $teams) {
$table->unsignedBigInteger($pivotPermission);
$table->string('model_type');
$table->unsignedBigInteger($columnNames['model_morph_key']);
$table->index([$columnNames['model_morph_key'], 'model_type'], 'model_has_permissions_model_id_model_type_index');
$table->foreign($pivotPermission)
->references('id') // permission id
->on($tableNames['permissions'])
->onDelete('cascade');
if ($teams) {
$table->unsignedBigInteger($columnNames['team_foreign_key']);
$table->index($columnNames['team_foreign_key'], 'model_has_permissions_team_foreign_key_index');
$table->primary([$columnNames['team_foreign_key'], $pivotPermission, $columnNames['model_morph_key'], 'model_type'],
'model_has_permissions_permission_model_type_primary');
} else {
$table->primary([$pivotPermission, $columnNames['model_morph_key'], 'model_type'],
'model_has_permissions_permission_model_type_primary');
}
});
Schema::create($tableNames['model_has_roles'], function (Blueprint $table) use ($tableNames, $columnNames, $pivotRole, $teams) {
$table->unsignedBigInteger($pivotRole);
$table->string('model_type');
$table->unsignedBigInteger($columnNames['model_morph_key']);
$table->index([$columnNames['model_morph_key'], 'model_type'], 'model_has_roles_model_id_model_type_index');
$table->foreign($pivotRole)
->references('id') // role id
->on($tableNames['roles'])
->onDelete('cascade');
if ($teams) {
$table->unsignedBigInteger($columnNames['team_foreign_key']);
$table->index($columnNames['team_foreign_key'], 'model_has_roles_team_foreign_key_index');
$table->primary([$columnNames['team_foreign_key'], $pivotRole, $columnNames['model_morph_key'], 'model_type'],
'model_has_roles_role_model_type_primary');
} else {
$table->primary([$pivotRole, $columnNames['model_morph_key'], 'model_type'],
'model_has_roles_role_model_type_primary');
}
});
Schema::create($tableNames['role_has_permissions'], function (Blueprint $table) use ($tableNames, $pivotRole, $pivotPermission) {
$table->unsignedBigInteger($pivotPermission);
$table->unsignedBigInteger($pivotRole);
$table->foreign($pivotPermission)
->references('id') // permission id
->on($tableNames['permissions'])
->onDelete('cascade');
$table->foreign($pivotRole)
->references('id') // role id
->on($tableNames['roles'])
->onDelete('cascade');
$table->primary([$pivotPermission, $pivotRole], 'role_has_permissions_permission_id_role_id_primary');
});
$permissionCacheStore = $config['cache']['store'];
$permissionCacheKey = $config['cache']['key'];
app('cache')
->store($permissionCacheStore != 'default' ? $permissionCacheStore : null)
->forget($permissionCacheKey);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
$config = App\SpatiePermissionConfig::config();
$tableNames = $config['table_names'];
if (empty($tableNames)) {
throw new \Exception('Error: config/permission.php not found and defaults could not be merged. Please publish the package configuration before proceeding, or drop the tables manually.');
}
Schema::drop($tableNames['role_has_permissions']);
Schema::drop($tableNames['model_has_roles']);
Schema::drop($tableNames['model_has_permissions']);
Schema::drop($tableNames['roles']);
Schema::drop($tableNames['permissions']);
}
};
2023_09_11_130128_change_github_and_google_token_type.php 0000644 00000001460 15266556541 0016600 0 ustar 00 text('facebook_token')->change();
$table->text('github_token')->change();
$table->text('google_token')->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->text('facebook_token')->change();
$table->text('github_token')->change();
$table->text('google_token')->change();
});
}
};
2024_07_25_081052_create_banner_bottom_texts_table.php 0000644 00000001001 15266556541 0016140 0 ustar 00 id();
$table->string('text')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('banner_bottom_texts');
}
};
2024_06_26_074715_add_custom_menu_to_menus_table.php 0000644 00000001245 15266556541 0015636 0 ustar 00 boolean('custom_menu')->default(false);
}
});
}
public function down(): void
{
if (Schema::hasColumn('menus', 'custom_menu')) {
Schema::table('menus', function (Blueprint $table) {
$table->dropColumn('custom_menu');
});
}
}
};
2024_03_28_002018_create_user_docs_favorite_table.php 0000644 00000001521 15266556541 0015746 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->unsignedBigInteger('user_openai_id')->nullable();
$table->foreign('user_openai_id')->references('id')->on('user_openai')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_docs_favorite');
}
};
2024_08_13_095658_remove_is_free_column_in_plans_table.php 0000644 00000001045 15266556541 0017015 0 ustar 00 dropColumn('is_free');
});
}
public function down(): void
{
Schema::table('plans', static function (Blueprint $table) {
$table->boolean('is_free')->default(false);
});
}
};
2023_07_03_082326_add_column_to_frontend_sections_statuses_titles_table.php 0000644 00000001235 15266556541 0022502 0 ustar 00 boolean('preheader_active')->default(1);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
$table->dropColumn('preheader_active');
});
}
};
2024_11_26_094758_add_heygen_secret_key_to_settings_table.php 0000644 00000001104 15266556541 0017504 0 ustar 00 text('heygen_secret_key')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2023_05_15_145853_create_user_openai_chat_messages_table.php 0000644 00000002263 15266556541 0017300 0 ustar 00 id();
$table->unsignedBigInteger('user_openai_chat_id')->nullable();
$table->foreign('user_openai_chat_id')->references('id')->on('user_openai_chat')->onDelete('cascade');
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->text('input')->nullable();
$table->text('response')->nullable();
$table->text('output')->nullable();
$table->text('hash')->nullable();
$table->string('credits')->nullable();
$table->string('words')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_openai_chat_messages');
}
};
2023_06_21_135415_add_additional_option_to_settings_table.php 0000644 00000001345 15266556541 0017477 0 ustar 00 boolean('feature_ai_voiceover')->default(true)->nullable();
$table->text('gcs_file')->nullable();
$table->text('gcs_name')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'feature_ai_voiceover',
'gcs_file',
'gcs_name',
]);
});
}
};
2024_06_24_074201_add_footer_text_color_to_frontend_footer_settings_table.php 0000644 00000001214 15266556541 0023006 0 ustar 00 string('footer_text_color')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_footer_settings', function (Blueprint $table) {
$table->dropColumn('footer_text_color');
});
}
};
2023_12_18_142047_add_pdf_info_to_chat_messages.php 0000644 00000001266 15266556541 0015366 0 ustar 00 text('pdfName')->nullable();
$table->text('pdfPath')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat_messages', function (Blueprint $table) {
$table->dropColumn(['pdfName', 'pdfPath']);
});
}
};
2023_06_12_091546_add_gdpr_option_to_settings_table.php 0000644 00000001344 15266556541 0016330 0 ustar 00 boolean('gdpr_status')->default(0);
$table->string('gdpr_button')->default('Accept');
$table->string('gdpr_content')->nullable()->default('This website uses cookies to improve your web experience.');
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn(['gdpr_status', 'gdpr_button', 'gdpr_content']);
});
}
};
2023_07_08_205833_create_settings_two_table.php 0000644 00000001741 15266556541 0014631 0 ustar 00 id();
$table->string('stable_diffusion_api_key')->nullable();
$table->string('stable_diffusion_default_model')->nullable();
$table->boolean('google_recaptcha_status')->default(false);
$table->string('google_recaptcha_site_key')->nullable();
$table->string('google_recaptcha_secret_key')->nullable();
$table->string('languages')->default('en')->nullable();
$table->string('languages_default')->default('en');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('settings_two');
}
};
2024_07_29_121039_create_pebblely_table.php 0000644 00000001010 15266556541 0013662 0 ustar 00 id();
$table->integer('user_id');
$table->string('image');
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('pebblely');
}
};
2025_06_08_102625_create_exported_videos_table.php 0000644 00000001757 15266556541 0015306 0 ustar 00 id();
$table->string('task_id')->unique()->index();
$table->string('status')->default(VideoStatusEnum::IN_PROGRESS->value);
$table->text('video_url')->nullable();
$table->string('title')->nullable();
$table->string('used_ai_tool')->default('topview');
$table->text('cover_url')->nullable();
$table->integer('video_duration')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('exported_videos');
}
};
2024_06_25_131414_add_tour_seen_to_users_table.php 0000644 00000001133 15266556541 0015276 0 ustar 00 boolean('tour_seen')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('tour_seen');
});
}
};
2024_02_19_175115_add_user_id_to_elevenlab_voices_table.php 0000644 00000001037 15266556541 0017101 0 ustar 00 bigInteger('user_id')->nullable()->after('id');
});
}
public function down(): void
{
Schema::table('elevenlab_voices', function (Blueprint $table) {
$table->dropColumn('user_id');
});
}
};
2024_08_06_050052_add_default_ai_model_to_plans_table.php 0000644 00000000777 15266556541 0016540 0 ustar 00 string('default_ai_model')->default('gpt-3.5-turbo')->nullable();
});
}
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
//
});
}
};
2023_12_22_085010_add_bot_output_image.php 0000644 00000001202 15266556541 0013535 0 ustar 00 string('outputImage')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat_messages', function (Blueprint $table) {
$table->dropColumn('outputImage');
});
}
};
2024_07_05_112203_add_synthesia_secret_key_to_settings_table.php 0000644 00000001107 15266556541 0020211 0 ustar 00 text('synthesia_secret_key')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2023_05_04_190611_add_version_to_settings_table.php 0000644 00000001150 15266556541 0015455 0 ustar 00 double('script_version')->default('9');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('script_version');
});
}
};
2023_06_26_140101_create_bad_words_table.php 0000644 00000001157 15266556541 0014026 0 ustar 00 id();
$table->unsignedBigInteger('user_id');
$table->string('words');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('bad_words');
}
};
2024_07_25_084337_add_generator_text_to_frontend_sections_statuses_titles_table.php 0000644 00000001236 15266556541 0024251 0 ustar 00 string('generators_subtitle')->nullable();
$table->string('generators_title')->nullable();
$table->string('generators_description')->nullable();
});
}
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
//
});
}
};
2023_06_06_094535_add_new_logo_options.php 0000644 00000001633 15266556541 0013604 0 ustar 00 text('logo_sticky')->nullable();
$table->text('logo_sticky_path')->nullable();
$table->text('logo_sticky_2x')->nullable();
$table->text('logo_sticky_2x_path')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'logo_sticky',
'logo_sticky_path',
'logo_sticky_2x',
'logo_sticky_2x_path',
]);
});
}
};
2024_02_15_085457_add_url_to_user_openai_chat.php 0000644 00000001175 15266556541 0015115 0 ustar 00 string('website_url')->default('')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('website_url');
});
}
};
2023_12_21_080333_add_allowed_voice_count_to_settings_two.php 0000644 00000001233 15266556541 0017534 0 ustar 00 boolean('daily_voice_limit_enabled')->default(false);
$table->integer('allowed_voice_count')->default(1);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
//
});
}
};
2024_02_23_111745_add_user_api_option_to_settings_table.php 0000644 00000001111 15266556541 0017164 0 ustar 00 tinyInteger('user_api_option')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2024_02_06_172558_add_system_to_email_templates_table.php 0000644 00000001033 15266556541 0016633 0 ustar 00 boolean('system')->default(true)->after('id');
});
}
public function down(): void
{
Schema::table('email_templates', function (Blueprint $table) {
$table->dropColumn('system');
});
}
};
2024_11_28_061918_add_automate_tax_to_gateways_table.php 0000644 00000001321 15266556541 0016462 0 ustar 00 boolean('automate_tax')->default(false)->after('tax');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('gateways', function (Blueprint $table) {
$table->dropColumn('automate_tax');
});
}
};
2023_03_10_100433_create_openai_table.php 0000644 00000001616 15266556541 0013327 0 ustar 00 id();
$table->string('title');
$table->text('description');
$table->string('slug')->nullable();
$table->boolean('active')->default(1);
$table->text('questions')->nullable();
$table->text('image')->nullable();
$table->boolean('premium')->default(0);
$table->string('type')->default('text');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('openai');
}
};
2024_07_24_111812_create_features_marquees_table.php 0000644 00000001062 15266556541 0015604 0 ustar 00 id();
$table->string('title')->nullable();
$table->string('position')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('features_marquees');
}
};
2018_08_08_100000_create_telescope_entries_table.php 0000644 00000004376 15266556541 0015604 0 ustar 00 getConnection());
// if the APP_ENV is not local, then run the migration
if (app()->environment() !== 'local') {
$schema->create('telescope_entries', function (Blueprint $table) {
$table->bigIncrements('sequence');
$table->uuid('uuid');
$table->uuid('batch_id');
$table->string('family_hash')->nullable();
$table->boolean('should_display_on_index')->default(true);
$table->string('type', 20);
$table->longText('content');
$table->dateTime('created_at')->nullable();
$table->unique('uuid');
$table->index('batch_id');
$table->index('family_hash');
$table->index('created_at');
$table->index(['type', 'should_display_on_index']);
});
$schema->create('telescope_entries_tags', function (Blueprint $table) {
$table->uuid('entry_uuid');
$table->string('tag');
$table->primary(['entry_uuid', 'tag']);
$table->index('tag');
$table->foreign('entry_uuid')
->references('uuid')
->on('telescope_entries')
->onDelete('cascade');
});
$schema->create('telescope_monitoring', function (Blueprint $table) {
$table->string('tag')->primary();
});
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
$schema = Schema::connection($this->getConnection());
$schema->dropIfExists('telescope_entries_tags');
$schema->dropIfExists('telescope_entries');
$schema->dropIfExists('telescope_monitoring');
}
};
2023_05_03_103903_add_additional_fields_to_activity_table.php 0000644 00000001630 15266556541 0017422 0 ustar 00 dropColumn('activity');
$table->string('activity_title')->nullable();
$table->string('activity_type')->nullable();
});
}
public function down(): void
{
Schema::table('activity', function (Blueprint $table) {
if (Schema::hasColumn('activity', 'activity_title')) {
$table->dropColumn('activity_title');
}
});
Schema::table('activity', function (Blueprint $table) {
if (Schema::hasColumn('activity', 'activity_type')) {
$table->dropColumn('activity_type');
}
});
}
};
2025_04_08_110336_add_openai_vector_and_file_id_columns_to_user_openai_chat.php 0000644 00000001346 15266556541 0023173 0 ustar 00 string('openai_vector_id')->nullable();
$table->string('openai_file_id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('openai_vector_id');
$table->dropColumn('openai_file_id');
});
}
};
2023_06_14_113746_add_google_refresh_token_to_users_table.php 0000644 00000001154 15266556541 0017475 0 ustar 00 string('google_refresh_token')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('google_refresh_token');
});
}
};
2023_12_19_085351_add_tax_to_gateways_table.php 0000644 00000001134 15266556541 0014562 0 ustar 00 string('tax')->nullable()->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('gateways', function (Blueprint $table) {
$table->dropColumn('tax');
});
}
};
2024_02_15_111859_add_coingate_subscriber_id_to_users_table.php 0000644 00000001175 15266556541 0017777 0 ustar 00 string('coingate_subscriber_id')->nullable()->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('coingate_subscriber_id');
});
}
};
2024_07_01_103008_add_otp_to_users_table.php 0000644 00000001112 15266556541 0014063 0 ustar 00 string('otp')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('otp');
});
}
};
2023_06_20_084825_add_old_product_id_to_oldgatewayproducts.php 0000644 00000001172 15266556541 0017713 0 ustar 00 string('old_product_id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('oldgatewayproducts', function (Blueprint $table) {
$table->dropColumn('old_product_id');
});
}
};
2024_03_08_112315_add_face_price_to_extensions_table.php 0000644 00000001166 15266556541 0016414 0 ustar 00 float('fake_price')->nullable()->after('price')->default(0);
});
}
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
if (Schema::hasColumn('extensions', 'fake_price')) {
$table->dropColumn('fake_price');
}
});
}
};
2023_06_06_100350_add_paid_with_to_subscriptions.php 0000644 00000001155 15266556541 0015637 0 ustar 00 string('paid_with')->default('stripe');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('subscriptions', function (Blueprint $table) {
$table->dropColumn('paid_with');
});
}
};
2024_01_30_134710_add_team_id_to_user_openai_table.php 0000644 00000001157 15266556541 0016044 0 ustar 00 bigInteger('team_id')->nullable()->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
$table->dropColumn('team_id');
});
}
};
2024_01_15_152651_add_serperapi_colmn_to_settings_two_table.php 0000644 00000001154 15266556541 0020050 0 ustar 00 text('serper_api_key')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('serper_api_key');
});
}
};
2024_02_27_120732_add_is_custom_column_to_pages_table.php 0000644 00000001127 15266556541 0016615 0 ustar 00 boolean('is_custom')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('pages', function (Blueprint $table) {
$table->dropColumn('is_custom');
});
}
};
2023_03_21_123416_add_additional_fields_to_user_support_table.php 0000644 00000001170 15266556541 0020336 0 ustar 00 string('ticket_id');
$table->string('priority')->default('Low');
$table->string('category');
});
}
public function down(): void
{
Schema::table('user_support', function (Blueprint $table) {
$table->dropColumn(['ticket_id', 'priority', 'category']);
});
}
};
2023_06_01_140509_create_frontend_future_table.php 0000644 00000001270 15266556541 0015274 0 ustar 00 id();
$table->string('title')->nullable();
$table->text('description')->nullable();
$table->text('image')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_future');
}
};
2024_09_19_245426_add_entity_credits_to_users_table.php 0000644 00000001177 15266556541 0016353 0 ustar 00 json('entity_credits')->nullable()->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
//
});
}
};
2024_01_30_134807_add_team_id_to_user_openai_chat_table.php 0000644 00000001171 15266556541 0017046 0 ustar 00 bigInteger('team_id')->nullable()->after('id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('team_id');
});
}
};
2024_07_25_114952_add_advanced_features_title_to_frontend_sections_statuses_titles_table.php 0000644 00000001173 15266556541 0026060 0 ustar 00 string('advanced_features_section_title')->nullable();
$table->text('advanced_features_section_description')->nullable();
});
}
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
//
});
}
};
2023_12_07_093902_add_display_to_plans.php 0000644 00000001201 15266556541 0013546 0 ustar 00 boolean('display_imag_count')->default(1);
$table->boolean('display_word_count')->default(1);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
//
});
}
};
2024_02_22_120600_create_chatbot_data_vectors_table.php 0000644 00000001264 15266556541 0016236 0 ustar 00 id();
$table->bigInteger('chatbot_id')->nullable();
$table->bigInteger('chatbot_data_id')->nullable();
$table->longText('content')->nullable();
$table->json('embedding')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('chatbot_data_vectors');
}
};
2024_02_22_150925_add_chatbot_id_to_openai_chat_category_table.php 0000644 00000001055 15266556541 0020405 0 ustar 00 bigInteger('chatbot_id')->nullable()->after('id');
});
}
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('chatbot_id');
});
}
};
2024_06_14_124938_add_plan_description_column_to_plans_table.php 0000644 00000001130 15266556541 0020171 0 ustar 00 text('description')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('description');
});
}
};
2023_06_22_115805_add_customcode_to_settings_table.php 0000644 00000001625 15266556541 0016147 0 ustar 00 text('frontend_code_before_head')->nullable();
$table->text('frontend_code_before_body')->nullable();
$table->text('dashboard_code_before_head')->nullable();
$table->text('dashboard_code_before_body')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'frontend_code_before_head',
'frontend_code_before_body',
'dashboard_code_before_head',
'dashboard_code_before_body',
]);
});
}
};
2024_02_08_192853_create_custom_biling_plans_table.php 0000644 00000001417 15266556541 0016136 0 ustar 00 id();
$table->string('gateway')->nullable();
$table->string('plan_id')->nullable();
$table->string('main_plan_price_id')->nullable();
$table->string('custom_plan_price_id')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('custom_biling_plans');
}
};
2023_06_12_135232_add_menu_option_to_settings_table.php 0000644 00000001140 15266556541 0016321 0 ustar 00 text('menu_options')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('menu_options');
});
}
};
2024_07_24_115747_create_footer_items_table.php 0000644 00000001115 15266556541 0014575 0 ustar 00 id();
$table->string('item')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('footer_items');
}
};
2024_01_18_001456_add_detail_to_extensions.php 0000644 00000001247 15266556541 0014431 0 ustar 00 text('detail')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
if (Schema::hasColumn('extensions', 'detail')) {
$table->dropColumn('detail');
}
});
}
};
2024_09_24_214000_update_plan_credits_temporary_migration.php 0000644 00000021246 15266556541 0017557 0 ustar 00 shouldMigrate()) {
$this->migrateCredits();
$this->migratePlans();
$this->migrateSlugs();
$this->dropRemainingCreditColumn();
}
}
private function shouldMigrate(): bool
{
return User::query()->exists();
}
private function migrateCredits(): void
{
$defaultWordModel = $this->defaultWordModel();
$defaultImageModels = $this->defaultImageModels();
User::query()
->chunk(10, function ($users) use ($defaultWordModel, $defaultImageModels) {
foreach ($users as $user) {
$remainingWords = (int) $user->remaining_words;
$remainingImages = (int) $user->remaining_images;
if ($remainingWords === -1) {
EntityStats::word()->forUser($user)->list()->each(function ($entity) {
$entity->setUnlimited();
});
} else {
$driver = Entity::driver($defaultWordModel)->forUser($user);
$driver->setCredit($remainingWords);
}
if ($remainingImages === -1) {
EntityStats::image()->forUser($user)->list()->each(function ($entity) {
$entity->setUnlimited();
});
} elseif ($defaultImageModels) {
$defaultImageModelCount = count($defaultImageModels);
foreach ($defaultImageModels as $model) {
$driver = Entity::driver($model)->forUser($user);
$driver->setCredit(ceil($remainingImages / $defaultImageModelCount));
}
}
}
});
if ($defaultWordModel === EntityEnum::GPT_4_O) {
Setting::query()
->updateOrCreate([
'openai_default_model' => EntityEnum::GPT_4_O,
]);
}
}
private function migratePlans(): void
{
$plans = Plan::get();
foreach ($plans as $plan) {
$this->updatePlan($plan);
}
}
private function updatePlan($plan): void
{
if ($plan) {
$allFeatures = array_merge($plan->plan_features, $plan->open_ai_items, $plan->plan_ai_tools);
$updatedData = [
'open_ai_items' => $this->getFreshJsonAiItems($allFeatures),
'plan_ai_tools' => $this->getFreshJsonAiTools($allFeatures),
'plan_features' => $this->getFreshJsonFeatures($allFeatures),
'plan_type' => strtolower($plan->plan_type),
'ai_models' => $this->convertPlanCredits($plan),
];
$plan->update($updatedData);
}
}
private function getFreshJsonAiItems($allFeatures): ?array
{
$flattened = [];
foreach (Plan::openAiGeneratorsValues() as $items) {
foreach ($items as $item) {
if (in_array($item['slug'], $allFeatures, true)) {
$flattened[$item['slug']] = true;
} else {
$flattened[$item['slug']] = false;
}
}
}
return $flattened;
}
private function getFreshJsonAiTools($allFeatures): ?array
{
$features = array_column(MenuService::planAiToolsMenu(), 'key');
return array_combine($features, array_map(static fn ($feature) => in_array($feature, $allFeatures, true), $features));
}
private function getFreshJsonFeatures(array $allFeatures): ?array
{
$features = array_column(MenuService::planFeatureMenu(), 'key');
return array_combine($features, array_map(static fn ($feature) => in_array($feature, $allFeatures, true), $features));
}
private function convertPlanCredits($plan): ?array
{
$aiModels = EngineEnum::getNestedPlanLimits();
$defaultWordModel = $this->defaultWordModel();
$defaultImageModels = $this->defaultImageModels();
if ($plan->total_words === -1) {
$aiModels[$defaultWordModel->engine()->slug()][$defaultWordModel->slug()]['isUnlimited'] = true;
} else {
$aiModels[$defaultWordModel->engine()->slug()][$defaultWordModel->slug()]['credit'] = $plan->total_words;
}
$defaultImageModelCount = count($defaultImageModels);
$imageCreditPerModel = $defaultImageModelCount > 0
? ceil($plan->total_images / $defaultImageModelCount)
: 0;
foreach ($defaultImageModels as $model) {
if ($plan->total_images === -1) {
$aiModels[$model->engine()->slug()][$model->slug()]['isUnlimited'] = true;
} else {
$aiModels[$model->engine()->slug()][$model->slug()]['credit'] = $imageCreditPerModel;
}
}
try {
return $aiModels;
} catch (JsonException $e) {
Log::error("Error encoding AI models for plan ID {$plan->id}: " . $e->getMessage());
return null;
}
}
private function migrateSlugs(): void
{
SettingTwo::where('dalle', 'dalle3')->update(['dalle' => 'dall-e-3']);
SettingTwo::where('dalle', 'dalle2')->update(['dalle' => 'dall-e-2']);
}
/**
* not used for now
* Convert a JSON array string to a JSON object string with keys set to true.
*/
private function convertArrayToJsonObject(?string $jsonArrayString): ?string
{
if (is_null($jsonArrayString)) {
return null;
}
$array = json_decode($jsonArrayString, true, 512, JSON_THROW_ON_ERROR);
if (is_array($array) && array_keys($array) !== range(0, count($array) - 1)) {
return $jsonArrayString;
}
$assocArray = [];
foreach ((array) $array as $item) {
$assocArray[$item] = true;
}
return json_encode($assocArray, JSON_THROW_ON_ERROR);
}
public function down(): void
{
if ($this->shouldMigrate()) {
Schema::table('users', static function (Blueprint $table) {
$table->integer('remaining_images')->nullable();
$table->integer('remaining_words')->nullable();
});
}
}
public function dropRemainingCreditColumn(): void
{
Schema::table('users', static function (Blueprint $table) {
if (Schema::hasColumn('users', 'remaining_words')) {
$table->dropColumn(['remaining_words', 'remaining_images']);
}
});
}
public function defaultImageModels(): array
{
$settingsTwo = SettingTwo::query()->first();
$models = [];
$dalleModel = match ($settingsTwo?->dalle) {
'dalle3' => EntityEnum::DALL_E_3->slug(),
'dalle2' => EntityEnum::DALL_E_2->slug(),
default => $settingsTwo?->dalle ?? EntityEnum::DALL_E_2->slug(),
};
if (! setting('dalle_hidden') && $openAIModel = EntityEnum::fromSlug($dalleModel)) {
$models['openai'] = $openAIModel;
}
$stableModel = $settingsTwo?->stablediffusion_default_model ?? $settingTwo?->stablediffusion_default_model ?? EntityEnum::STABLE_DIFFUSION_XL_1024_V_1_0->slug();
if (! setting('stable_hidden') && $stableModel = EntityEnum::fromSlug($stableModel)) {
$models['stable'] = $stableModel;
}
$falModel = setting('fal_ai_default_model', 'flux-realism');
if ($falModel = EntityEnum::fromSlug($falModel)) {
$models['fal'] = $falModel;
}
return $models;
}
/** @noinspection PhpDuplicateMatchArmBodyInspection */
public function defaultWordModel(): EntityEnum
{
$defaultEngine = setting('default_ai_engine');
return match ($defaultEngine) {
'openai' => EntityEnum::GPT_4_O,
'anthropic' => EntityEnum::fromSlug(setting('anthropic_default_model')),
'gemini' => EntityEnum::fromSlug(setting('gemini_default_model')),
default => EntityEnum::GPT_4_O,
};
}
};
2023_04_12_223330_add_affiliate_to_users_table.php 0000644 00000002051 15266556541 0015207 0 ustar 00 string('affiliate_code')->nullable();
$table->string('affiliate_earnings')->default(0);
$table->text('affiliate_bank_account')->nullable();
$table->unsignedBigInteger('affiliate_id')->nullable();
$table->foreign('affiliate_id')->references('id')->on('users')->onDelete('cascade');
});
}
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
if (! isDBDriverSQLite()) {
$table->dropForeign(['affiliate_id']);
}
$table->dropColumn([
'affiliate_code',
'affiliate_bank_account',
'affiliate_earnings',
'affiliate_id',
]);
});
}
};
2023_12_25_212630_add_bank_details_to_gateways_table.php 0000644 00000001304 15266556541 0016372 0 ustar 00 text('bank_account_details')->nullable();
$table->text('bank_account_other')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('gateways', function (Blueprint $table) {
$table->dropColumn(['bank_account_details', 'bank_account_other']);
});
}
};
2023_04_01_235507_add_custom_template_fields_to_openai_table.php 0000644 00000001321 15266556541 0020136 0 ustar 00 text('prompt')->nullable();
$table->boolean('custom_template')->default(0);
$table->boolean('tone_of_voice')->default(0);
});
}
public function down(): void
{
Schema::table('openai', function (Blueprint $table) {
$table->dropColumn([
'prompt',
'custom_template',
'tone_of_voice',
]);
});
}
};
2023_03_22_104952_add_openai_settings_to_settings_table.php 0000644 00000002235 15266556541 0017171 0 ustar 00 string('openai_default_model')->default('gpt-3.5-turbo');
$table->string('openai_default_language')->default('en-US');
$table->string('openai_default_tone_of_voice')->default('professional');
$table->string('openai_default_creativity')->default('0.75');
$table->string('openai_max_input_length')->default('300');
$table->string('openai_max_output_length')->default('200');
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'openai_default_model',
'openai_default_language',
'openai_default_tone_of_voice',
'openai_default_creativity',
'openai_max_input_length',
'openai_max_output_length',
]);
});
}
};
2024_02_15_100430_add_payload_to_gatewayproducts_table.php 0000644 00000001035 15266556541 0016776 0 ustar 00 json('payload')->nullable()->after('price_id');
});
}
public function down(): void
{
Schema::table('gatewayproducts', function (Blueprint $table) {
$table->dropColumn('payload');
});
}
};
2023_07_13_133729_add_stream_server_option_to_settings_two_table.php 0000644 00000001330 15266556541 0021143 0 ustar 00 string('openai_default_stream_server')->default('backend');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('openai_default_stream_server');
});
}
}
};
2024_09_19_070942_add_bolt_menu_to_menus_table.php 0000644 00000001440 15266556541 0015264 0 ustar 00 boolean('bolt_menu')
->default(false)
->nullable()
->after('extension');
$table->string('bolt_background')->nullable()->after('bolt_menu');
$table->string('bolt_foreground')->nullable()->after('bolt_background');
});
}
public function down(): void
{
Schema::table('menus', function (Blueprint $table) {
$table->dropColumn(['bolt_menu', 'bolt_background', 'bolt_foreground']);
});
}
};
2024_09_30_113752_rename_ai_model_id_column_in_token_table.php 0000644 00000003061 15266556541 0017565 0 ustar 00 dropForeign(['ai_model_id']);
}
});
Schema::table('tokens', static function (Blueprint $table) {
if (Schema::hasColumn('tokens', 'ai_model_id')) {
$table->renameColumn('ai_model_id', 'entity_id');
}
});
Schema::table('tokens', static function (Blueprint $table) {
$table->foreign('entity_id')->references('id')->on('entities')->onDelete('cascade');
});
}
public function down(): void
{
Schema::table('tokens', static function (Blueprint $table) {
if (Schema::hasColumn('tokens', 'entity_id')) {
$table->dropForeign(['entity_id']);
}
});
Schema::table('tokens', static function (Blueprint $table) {
if (Schema::hasColumn('tokens', 'entity_id')) {
$table->renameColumn('entity_id', 'ai_model_id');
}
});
Schema::table('tokens', static function (Blueprint $table) {
$table->foreign('ai_model_id')->references('id')->on('entities')->onDelete('cascade');
});
}
};
2023_12_12_063333_add_feature_ai_vision_to_settings_table.php 0000644 00000001164 15266556541 0017465 0 ustar 00 tinyInteger('feature_ai_vision')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_vision');
});
}
};
2019_08_19_000000_create_failed_jobs_table.php 0000644 00000001400 15266556541 0014314 0 ustar 00 id();
$table->string('uuid')->unique();
$table->text('connection');
$table->text('queue');
$table->longText('payload');
$table->longText('exception');
$table->timestamp('failed_at')->useCurrent();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('failed_jobs');
}
};
2024_08_16_105255_rollback_permission_table.php 0000644 00000001353 15266556541 0014613 0 ustar 00 where('type', 'super_admin')
->update(['type' => Roles::ADMIN->value]);
Schema::dropIfExists('role_has_permissions');
Schema::dropIfExists('model_has_roles');
Schema::dropIfExists('model_has_permissions');
Schema::dropIfExists('roles');
Schema::dropIfExists('permissions');
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2024_08_12_141902_add_assistant_to_openai_chat_category_table.php 0000644 00000001164 15266556541 0020317 0 ustar 00 string('assistant')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('assistant');
});
}
};
2024_01_29_081000_chatbot_settings.php 0000644 00000002141 15266556541 0012727 0 ustar 00 string('chatbot_status')->nullable()->default('disabled');
$table->integer('chatbot_template')->nullable();
$table->string('chatbot_position')->nullable()->default('bottom-left');
$table->tinyInteger('chatbot_login_require')->default(true);
$table->integer('chatbot_rate_limit')->nullable()->default(10);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn([
'chatbot_status',
'chatbot_template',
'chatbot_position',
'chatbot_login_require',
'chatbot_rate_limit',
]);
});
}
};
2024_12_19_180117_change_prompt_column_to_user_fall_table.php 0000644 00000001043 15266556541 0017505 0 ustar 00 text('prompt')->nullable()->change();
});
}
}
/**
* Reverse the migrations.
*/
public function down(): void {}
};
2023_09_13_075321_add_stablediffusion_default_model_to_settings_two_table.php 0000644 00000002173 15266556541 0022740 0 ustar 00 string('stablediffusion_default_model')->default(EntityEnum::STABLE_DIFFUSION_XL_1024_V_1_0->slug())->change();
} else {
$table->string('stablediffusion_default_model')->default(EntityEnum::STABLE_DIFFUSION_XL_1024_V_1_0->slug());
}
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->string('stablediffusion_default_model')->default(EntityEnum::STABLE_DIFFUSION_XL_1024_V_1_0->slug())->change();
});
}
}
};
2024_08_09_103631_add_ai_models_to_plans_table.php 0000644 00000000772 15266556541 0015217 0 ustar 00 json('ai_models')->nullable();
});
}
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('ai_models');
});
}
};
2023_09_20_174744_create_coupon_users_table.php 0000644 00000001503 15266556541 0014622 0 ustar 00 id();
$table->unsignedBigInteger('coupon_id');
$table->unsignedBigInteger('user_id');
$table->timestamps();
$table->foreign('coupon_id')->references('id')->on('coupons')->onDelete('cascade');
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('coupon_users');
}
};
2023_11_30_084646_add_user_id_to_prompt_library.php 0000644 00000001131 15266556541 0015465 0 ustar 00 integer('user_id');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('prompt_library', function (Blueprint $table) {
$table->dropColumn('user_id');
});
}
};
2023_12_14_093837_create_pdf_data_table.php 0000644 00000001206 15266556541 0013640 0 ustar 00 id();
$table->integer('chat_id');
$table->text('content');
$table->json('vector');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('pdf_data');
}
};
2024_07_05_122831_add_is_selected_to_ai_models_table.php 0000644 00000001171 15266556541 0016355 0 ustar 00 string('selected_title')->nullable();
$table->boolean('is_selected')->default(false);
});
}
public function down(): void
{
Schema::table('ai_models', function (Blueprint $table) {
$table->dropColumn('is_selected');
$table->dropColumn('selected_title');
});
}
};
2023_11_28_130925_add_favorite_plan_to_openai_chat_category_table.php 0000644 00000001152 15266556541 0021137 0 ustar 00 string('plan')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('plan');
});
}
};
2024_03_07_152339_create_intagrations_table.php 0000644 00000001277 15266556541 0014604 0 ustar 00 id();
$table->string('app')->nullable();
$table->text('description')->nullable();
$table->string('image')->nullable();
$table->string('slug')->nullable();
$table->tinyInteger('status')->default(1);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('integrations');
}
};
2025_07_23_140424_add_specific_instructions_column_to_companies_table.php 0000644 00000001212 15266556541 0022075 0 ustar 00 text('specific_instructions')->nullable()->after('brand_color');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('companies', function (Blueprint $table) {
$table->dropColumn('specific_instructions');
});
}
};
2024_02_21_051626_add_free_open_ai_items_to_settings_table.php 0000644 00000001022 15266556541 0017601 0 ustar 00 json('free_open_ai_items')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('free_open_ai_items');
});
}
};
2024_04_06_014025_change_columns_in_privacy_terms_table.php 0000644 00000001561 15266556541 0017162 0 ustar 00 string('type')->nullable()->change();
$table->string('lang')->nullable()->change();
$table->text('content')->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('privacy_terms', function (Blueprint $table) {
$table->string('type')->nullable(false)->change();
$table->string('lang')->nullable(false)->change();
$table->text('content')->nullable(false)->change();
});
}
};
2023_07_13_143413_add_blog_options_to_frontend_sections_statuses_titles.php 0000644 00000003166 15266556541 0022535 0 ustar 00 boolean('blog_active')->default(0);
$table->string('blog_title')->default('Latest News');
$table->string('blog_subtitle')->default('Stay up-to-date');
$table->integer('blog_posts_per_page')->default(3);
$table->string('blog_button_text')->default('Show more');
$table->string('blog_a_title')->default('Blog Posts');
$table->string('blog_a_subtitle')->default('Latest News');
$table->string('blog_a_description')->default('Welcome to our cozy corner of the internet, where you will find a delightful collection of our heartfelt and thought-provoking blog posts.');
$table->integer('blog_a_posts_per_page')->default(6);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
$table->dropColumn([
'blog_active',
'blog_title',
'blog_subtitle',
'blog_posts_per_page',
'blog_button_text',
'blog_a_title',
'blog_a_subtitle',
'blog_a_description',
'blog_a_posts_per_page',
]);
});
}
};
2024_04_02_063345_add_anthropic_api_keys_to_users_table.php 0000644 00000001273 15266556541 0017153 0 ustar 00 string('anthropic_api_keys')
->after('api_keys')
->nullable()
->default('');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('anthropic_api_keys');
});
}
};
2024_02_14_124404_add_titlebar_status_to_pages_table.php 0000644 00000001147 15266556541 0016442 0 ustar 00 tinyInteger('titlebar_status')->default(1);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('pages', function (Blueprint $table) {
$table->dropColumn('titlebar_status');
});
}
};
2023_06_15_110436_add_privacy_and_terms_column_to_settings_table.php 0000644 00000001513 15266556541 0021061 0 ustar 00 boolean('privacy_enable')->default(0);
$table->boolean('privacy_enable_login')->default(0);
$table->text('privacy_content')->nullable();
$table->text('terms_content')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'privacy_enable',
'privacy_enable_login',
'privacy_content',
'terms_content',
]);
});
}
};
2024_12_10_080148_delete_menu_icon_one_time_migration.php 0000644 00000002037 15266556541 0016621 0 ustar 00 appVersion() == 7.3) {
Menu::query()
->where('parent_id', null)
->whereHas('children')
->get()->map(function ($item) {
$item->children()
->where('parent_id', $item['id'])
->where('custom_menu', false)
->update([
'icon' => null,
]);
});
}
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2014_01_01_000001_convert_db_tables_engines_from_myisam_to_innodb.php 0000644 00000001537 15266556541 0021174 0 ustar 00 convertMyISAMToInnoDB();
}
}
private function convertMyISAMToInnoDB(): void
{
DB::statement('SET FOREIGN_KEY_CHECKS=0');
$tables = DB::select("SHOW TABLE STATUS WHERE Engine = 'MyISAM'");
foreach ($tables as $table) {
try {
DB::statement("ALTER TABLE `{$table->Name}` ENGINE=InnoDB;");
} catch (Exception $e) {
// ignore
}
}
DB::statement('SET FOREIGN_KEY_CHECKS=1');
}
/**
* Reverse the migrations.
*/
public function down(): void {}
};
2023_04_13_180614_add_affiliate_to_user_orders_table.php 0000644 00000001164 15266556541 0016416 0 ustar 00 double('affiliate_earnings')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_orders', function (Blueprint $table) {
$table->dropColumn('affiliate_earnings');
});
}
};
2023_08_14_073857_add_storage_to_user_openai_table.php 0000644 00000001137 15266556541 0016132 0 ustar 00 string('storage')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
$table->dropColumn('storage');
});
}
};
2024_07_09_150801_add_dash_notify_seen_to_users_table.php 0000644 00000001151 15266556541 0016620 0 ustar 00 boolean('dash_notify_seen')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('dash_notify_seen');
});
}
};
2023_09_28_173820_add_hero_button_type_column_to_frontend_footer_settings.php 0000644 00000001337 15266556541 0023070 0 ustar 00 integer('hero_button_type')->default(1)->after('hero_button_url');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_footer_settings', function (Blueprint $table) {
$table->dropColumn('hero_button_type');
});
}
};
2023_05_26_134701_add_stripe_status_for_now_to_settings_table.php 0000644 00000001175 15266556541 0020443 0 ustar 00 string('stripe_status_for_now')->default('disabled');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('stripe_status_for_now');
});
}
};
2025_03_13_140538_add_slug_column_to_email_templates_table.php 0000644 00000001140 15266556541 0017626 0 ustar 00 string('slug')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('email_templates', function (Blueprint $table) {
$table->dropColumn('slug');
});
}
};
2024_06_04_032206_add_country_tax_enabled_to_gateways_table.php 0000644 00000001165 15266556541 0020010 0 ustar 00 boolean('country_tax_enabled')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('gateways', function (Blueprint $table) {
$table->dropColumn('country_tax_enabled');
});
}
};
2024_03_14_062605_add_user_id_to_openai_table.php 0000644 00000001013 15266556541 0015034 0 ustar 00 bigInteger('user_id')->nullable()->after('id');
});
}
public function down(): void
{
Schema::table('openai', function (Blueprint $table) {
$table->dropColumn('user_id');
});
}
};
2023_06_05_131107_add_settings_columns_to_settings_table.php 0000644 00000002225 15266556541 0017371 0 ustar 00 boolean('feature_ai_writer')->default(true);
$table->boolean('feature_ai_image')->default(true);
$table->boolean('feature_ai_chat')->default(true);
$table->boolean('feature_ai_code')->default(true);
$table->boolean('feature_ai_speech_to_text')->default(true);
$table->boolean('feature_affilates')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'feature_ai_writer',
'feature_ai_image',
'feature_ai_chat',
'feature_ai_code',
'feature_ai_speech_to_text',
'feature_affilates',
]);
});
}
};
2024_01_23_052857_add_ai_rewriter_to_table.php 0000644 00000001170 15266556541 0014375 0 ustar 00 tinyInteger('feature_ai_rewriter')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_rewriter');
});
}
};
2024_07_25_120715_add_description_to_howitworks_table.php 0000644 00000001102 15266556541 0016674 0 ustar 00 text('description')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('howitworks', function (Blueprint $table) {
//
});
}
};
2024_09_24_220949_rename_ai_engine_column_in_entities_table.php 0000644 00000000774 15266556541 0020004 0 ustar 00 renameColumn('ai_engine', 'engine');
});
}
public function down(): void
{
Schema::table('entities', static function ($table) {
$table->renameColumn('engine', 'ai_engine');
});
}
};
2025_03_18_053123_create_content_boxes_table.php 0000644 00000003645 15266556541 0014747 0 ustar 00 id();
$table->string('emoji')->nullable();
$table->string('title')->nullable();
$table->text('description')->nullable();
$table->string('background')->nullable();
$table->string('foreground')->nullable();
$table->timestamps();
});
$items = [
[
'emoji' => '😎',
'title' => 'Partner',
'description' => 'Invite your colleagues and collaborators to join a team and maximize the benefits of AI.',
'background' => '#615C5A',
'foreground' => '#fff',
],
[
'emoji' => '🚀',
'title' => 'Collaborate',
'description' => 'Invite your colleagues and collaborators to join a team and maximize the benefits of AI.',
'background' => '#EB6434',
'foreground' => '#fff',
],
[
'emoji' => '👥',
'title' => 'Invite',
'description' => 'Invite your colleagues and collaborators to join a team and maximize the benefits of AI.',
'background' => '#3B4F99',
'foreground' => '#fff',
],
];
foreach ($items as $item) {
ContentBox::query()->create($item);
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_content_boxes');
}
};
2024_02_22_065844_create_chatbot_data_table.php 0000644 00000001372 15266556541 0014513 0 ustar 00 id();
$table->bigInteger('chatbot_id')->nullable();
$table->longText('content')->nullable();
$table->string('type')->nullable();
$table->string('type_value')->nullable();
$table->string('path')->nullable();
$table->string('status')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('chatbot_data');
}
};
2024_03_29_212039_delete_column_from_extensions_table.php 0000644 00000002541 15266556541 0016671 0 ustar 00 'extensions',
'review' => 'extensions',
'description' => 'extensions',
'category' => 'extensions',
'badge' => 'extensions',
'zip_url' => 'extensions',
'price_id' => 'extensions',
'image_url' => 'extensions',
'detail' => 'extensions',
'licensed' => 'extensions',
'theme_type' => 'extensions',
'price' => 'extensions',
'fake_price' => 'extensions',
])->filter(function ($value, $key) {
return Schema::hasColumn($value, $key);
})->keys()->all();
if ($columnsToDrop !== []) {
$table->dropColumn($columnsToDrop);
}
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
//
});
}
};
2023_06_06_133614_add_new_field_for_chat.php 0000644 00000001200 15266556541 0013777 0 ustar 00 text('chat_completions')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('chat_completions');
});
}
};
2023_11_28_160244_add_category_to_openai_chat_category_table.php 0000644 00000001162 15266556541 0020121 0 ustar 00 string('category')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('category');
});
}
};
2023_06_22_133908_add_webhooks_to_gateways.php 0000644 00000001136 15266556541 0014441 0 ustar 00 string('webhook_id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('gateways', function (Blueprint $table) {
$table->dropColumn('webhook_id');
});
}
};
2023_11_29_122715_create_rate_limits_table.php 0000644 00000001270 15266556541 0014404 0 ustar 00 id();
$table->string('ip_address');
$table->integer('attempts')->default(0);
$table->timestamp('last_attempt_at')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('rate_limits');
}
};
2023_12_14_075424_change_content_column_in_pages_table.php 0000644 00000001324 15266556541 0016745 0 ustar 00 longText('content')->change();
});
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('pages')) {
Schema::table('pages', function (Blueprint $table) {
$table->text('content')->change();
});
}
}
};
2025_03_10_221327_remove_cost_per_token_column_from_tokens_table.php 0000644 00000001155 15266556541 0021115 0 ustar 00 dropColumn('cost_per_token');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('tokens', function (Blueprint $table) {
$table->decimal('cost_per_token', 15, 2)->default(1.00);
});
}
};
2024_03_04_070314_create_usage_table.php 0000644 00000010274 15266556541 0013170 0 ustar 00 id();
$table->unsignedInteger('total_user_count')->default(0);
$table->unsignedInteger('this_week_user_count')->default(0);
$table->unsignedInteger('last_week_user_count')->default(0);
$table->unsignedInteger('total_word_count')->default(0);
$table->unsignedInteger('this_week_word_count')->default(0);
$table->unsignedInteger('last_week_word_count')->default(0);
$table->unsignedInteger('total_image_count')->default(0);
$table->unsignedInteger('this_week_image_count')->default(0);
$table->unsignedInteger('last_week_image_count')->default(0);
$table->unsignedInteger('total_sales')->default(0);
$table->unsignedInteger('this_week_sales')->default(0);
$table->unsignedInteger('last_week_sales')->default(0);
$table->timestamps();
});
// Count existing users
$totaluserCount = DB::table('users')->count();
$totalWordCount = DB::table('user_openai')->where('credits', '!=', 1)->sum('credits');
$totalImageCount = DB::table('user_openai')->where('credits', '=', 1)->sum('credits');
$totalSalesCount = DB::table('user_orders')->sum('price');
// Count users created this week
$thisWeekUserCount = DB::table('users')->whereBetween('created_at', [Carbon::now()->startOfWeek(), Carbon::now()->endOfWeek()])->count();
$thisWeekWordCount = DB::table('user_openai')->where('credits', '!=', 1)->whereBetween('created_at', [Carbon::now()->startOfWeek(), Carbon::now()->endOfWeek()])->sum('credits');
$thisWeekImageCount = DB::table('user_openai')->where('credits', '=', 1)->whereBetween('created_at', [Carbon::now()->startOfWeek(), Carbon::now()->endOfWeek()])->sum('credits');
$thisWeekSales = DB::table('user_orders')->whereBetween('created_at', [Carbon::now()->startOfWeek(), Carbon::now()->endOfWeek()])->sum('price');
// Count users created last week
$lastWeekUserCount = DB::table('users')->whereBetween('created_at', [Carbon::now()->startOfWeek()->subWeek(), Carbon::now()->endOfWeek()->subWeek()])->count();
$lastWeekWordCount = DB::table('user_openai')->where('credits', '!=', 1)->whereBetween('created_at', [Carbon::now()->startOfWeek()->subWeek(), Carbon::now()->endOfWeek()->subWeek()])->sum('credits');
$lastWeekImageCount = DB::table('user_openai')->where('credits', '=', 1)->whereBetween('created_at', [Carbon::now()->startOfWeek()->subWeek(), Carbon::now()->endOfWeek()->subWeek()])->sum('credits');
$lastWeekSales = DB::table('user_orders')->whereBetween('created_at', [Carbon::now()->startOfWeek()->subWeek(), Carbon::now()->endOfWeek()->subWeek()])->sum('price');
// Set the initial value in settings table
DB::table('usage')->updateOrInsert(
[],
[
'total_user_count' => $totaluserCount,
'this_week_user_count' => $thisWeekUserCount,
'last_week_user_count' => $lastWeekUserCount,
'total_word_count' => $totalWordCount,
'this_week_word_count' => $thisWeekWordCount,
'last_week_word_count' => $lastWeekWordCount,
'total_image_count' => $totalImageCount,
'this_week_image_count' => $thisWeekImageCount,
'last_week_image_count' => $lastWeekImageCount,
'total_sales' => $totalSalesCount,
'this_week_sales' => $thisWeekSales,
'last_week_sales' => $lastWeekSales,
'created_at' => now(),
'updated_at' => now(),
]
);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('usage');
}
};
2025_08_22_090439_add_access_type_column_to_openai_table.php 0000644 00000002371 15266556541 0017304 0 ustar 00 string('access_type', 20)->default(\App\Enums\AccessType::REGULAR->value)->index();
});
try {
\App\Models\OpenAIGenerator::query()->each(function ($generator) {
$generator->access_type = $generator->premium ? \App\Enums\AccessType::PREMIUM->value : \App\Enums\AccessType::REGULAR->value;
$generator->save();
});
\App\Models\OpenaiGeneratorChatCategory::query()->each(function ($generator) {
if (! $generator->plan) {
$generator->plan = \App\Enums\AccessType::REGULAR->value;
$generator->save();
}
});
} catch (\Throwable $th) {
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai', function (Blueprint $table) {
$table->dropColumn('access_type');
});
}
};
2025_06_26_050421_add_is_demo_to_user_openai_table.php 0000644 00000001174 15266556541 0016067 0 ustar 00 boolean('is_demo')->default(false)->after('id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
$table->dropColumn('is_demo');
});
}
};
2024_02_23_111834_add_api_keys_to_users_table.php 0000644 00000001065 15266556541 0015101 0 ustar 00 text('api_keys')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
//
});
}
};
2024_01_23_143224_feature_ai_youtube_option.php 0000644 00000001166 15266556541 0014642 0 ustar 00 tinyInteger('feature_ai_youtube')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_youtube');
});
}
};
2023_05_31_090418_create_customsettings_table.php 0000644 00000003433 15266556541 0015166 0 ustar 00 id();
$table->string('key'); // Unique key value of setting e.g. : howitworks_link
$table->string('title')->nullable(); // Short description to remember where/what for it is used
$table->string('value_str')->nullable(); // String value
$table->text('value_text')->nullable(); // Text value
$table->longText('value_longtext')->nullable(); // Long Text value
$table->text('value_html')->nullable(); // HTML value (Cleans/Sanitizes in Model)
$table->integer('value_int')->default(0); // Integer value
$table->bigInteger('value_bigint')->nullable(); // Big integer value
$table->unsignedBigInteger('value_ubigint')->nullable(); // Unsigned big integer value
$table->double('value_double')->default(0); // Double value
$table->boolean('value_bool')->default(false); // Boolean value
$table->date('value_date')->nullable(); // Date value
$table->timestamp('value_timestamp')->nullable(); // Timestamp value
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('customsettings');
}
};
2024_02_26_184945_create_companies_table.php 0000644 00000002117 15266556541 0014062 0 ustar 00 id();
$table->string('name')->nullable();
$table->text('industry')->nullable();
$table->text('description')->nullable();
$table->string('website')->nullable();
$table->string('tagline')->nullable();
$table->string('logo')->nullable();
$table->string('brand_color')->nullable();
$table->unsignedBigInteger('user_id')->nullable(); // Add a nullable foreign key to link to the User model
$table->foreign('user_id')->references('id')->on('users')->onDelete('set null');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('companies');
}
};
2024_08_06_115604_update_admin_to_super_admin_in_users_table.php 0000644 00000001103 15266556541 0020172 0 ustar 00 where('type', Roles::ADMIN->value)
->update(['type' => 'super_admin']);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
DB::table('users')
->where('type', 'super_admin')
->update(['type' => Roles::ADMIN->value]);
}
};
2024_11_25_101434_create_health_check_result_history_items_table.php 0000644 00000002176 15266556541 0021050 0 ustar 00 id();
$table->string('check_name');
$table->string('check_label');
$table->string('status');
$table->text('notification_message');
$table->string('short_summary')->nullable();
$table->json('meta');
$table->timestamp('ended_at');
$table->char('batch', 36);
$table->index('created_at');
$table->index('batch');
$table->timestamps();
});
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('health_check_result_history_items');
}
};
2023_05_25_182410_add_email_confirmation_to_users_table.php 0000644 00000001273 15266556541 0017137 0 ustar 00 text('email_confirmation_code')->nullable();
$table->boolean('email_confirmed')->default(0);
$table->text('password_reset_code')->nullable();
});
}
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn(['email_confirmation_code', 'email_confirmed', 'password_reset_code']);
});
}
};
2023_11_27_052529_create_prompt_library_table.php 0000644 00000001152 15266556541 0015137 0 ustar 00 id();
$table->string('title');
$table->text('prompt');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('prompt_library');
}
};
2025_05_21_151911_add_engine_and_model_columns_to_user_openai_table.php 0000644 00000001162 15266556541 0021454 0 ustar 00 string('engine')->nullable();
$table->string('model')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
//
});
}
};
2024_09_19_211829_make_sure_to_remove_deprecated_entities_before_migration.php 0000644 00000002112 15266556541 0023117 0 ustar 00 checkSD();
}
private function checkSD(): void
{
$settingTwo = SettingTwo::query()->first();
if ($settingTwo) {
$deprecatedEntities = ['stable-diffusion-xl-beta-v2-2-2', 'stable-diffusion-xl-1024-v0-9', 'stable-diffusion-512-v2-1'];
$stableDiffusionDefaultModel = $settingTwo->stablediffusion_default_model;
if (in_array($stableDiffusionDefaultModel, $deprecatedEntities, true)) {
$settingTwo->update(['stablediffusion_default_model' => 'stable-diffusion-xl-1024-v1-0']);
}
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('remove_deprecated_entities_before_migration', function (Blueprint $table) {
//
});
}
};
2025_05_05_102938_remove_gemini_deprected_models.php 0000644 00000002004 15266556541 0015605 0 ustar 00 $newDefault,
])->save();
}
} catch (\Throwable $exception) {
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2023_06_07_124125_create_gatewayproducts_table.php 0000644 00000001547 15266556541 0015321 0 ustar 00 id();
$table->integer('plan_id')->default(0);
$table->string('plan_name')->nullable();
$table->string('gateway_code')->nullable();
$table->string('gateway_title')->nullable();
$table->string('product_id')->nullable();
$table->string('price_id')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('gatewayproducts');
}
};
2023_11_29_060800_create_favourite_list_table.php 0000644 00000001225 15266556541 0015123 0 ustar 00 id();
$table->integer('user_id');
$table->string('type');
$table->integer('item_id');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('favourite_list');
}
};
2024_01_16_063552_add_realtime_colmn_to_user_openai_chat_messages_table.php 0000644 00000001175 15266556541 0022333 0 ustar 00 boolean('realtime')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat_messages', function (Blueprint $table) {
$table->dropColumn('realtime');
});
}
};
2024_03_28_134851_add_to_token_to_users_table.php 0000644 00000001102 15266556541 0015121 0 ustar 00 rememberToken();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropRememberToken();
});
}
};
2023_06_15_104503_create_oldgatewayproducts_table.php 0000644 00000001651 15266556541 0016011 0 ustar 00 id();
$table->integer('plan_id')->default(0);
$table->string('plan_name')->nullable();
$table->string('gateway_code')->nullable();
$table->string('product_id')->nullable();
$table->string('old_price_id')->nullable();
$table->string('new_price_id')->nullable();
$table->string('status')->nullable('check');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('oldgatewayproducts');
}
};
2024_12_16_080709_add_hidden_to_plans_table.php 0000644 00000001335 15266556541 0014515 0 ustar 00 string('hidden_url')->nullable();
$table->boolean('hidden')->default(false);
$table->integer('max_subscribe')->nullable();
$table->date('last_date')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
//
});
}
};
2024_02_19_172005_add_voice_clone_settings_table.php 0000644 00000001225 15266556541 0015557 0 ustar 00 boolean('feature_ai_voice_clone')->default(false)->after('feature_ai_code');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_voice_clone');
});
}
};
2024_03_12_143138_add_auth_view_options_column_to_settings_table.php 0000644 00000001152 15266556541 0021115 0 ustar 00 text('auth_view_options')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('auth_view_options');
});
}
};
2024_09_24_213419_rename_ai_models_to_entities_table.php 0000644 00000000532 15266556541 0016443 0 ustar 00 unsignedBigInteger('team_id')->nullable()->after('id');
$table->unsignedBigInteger('team_manager_id')->nullable()->after('team_id');
});
}
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn(['team_id', 'team_manager_id']);
});
}
};
2023_07_11_200310_add_liquid_license_domain_key_to_settings_two.php 0000644 00000001310 15266556541 0020664 0 ustar 00 text('liquid_license_domain_key')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('liquid_license_domain_key');
});
}
}
};
2025_05_02_120212_change_name_in_dashboard_widgets.php 0000644 00000001135 15266556541 0016030 0 ustar 00 where('name', 'api-cost-distrubition')
->update(['name' => 'api-cost-distribution']);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('dashboard_widgets', function (Blueprint $table) {
//
});
}
};
2023_06_23_091003_create_email_templates_table.php 0000644 00000001224 15266556541 0015225 0 ustar 00 id();
$table->string('title');
$table->string('subject');
$table->text('content');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('email_templates');
}
};
2023_08_22_143604_add_iyzico_id_column_to_users.php 0000644 00000001130 15266556541 0015462 0 ustar 00 string('iyzico_id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn(['iyzico_id']);
});
}
};
2023_09_20_140329_add_feature_ai_article_wizard_to_settings_table.php 0000644 00000001204 15266556541 0021162 0 ustar 00 tinyInteger('feature_ai_article_wizard')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_article_wizard');
});
}
};
2023_12_15_003956_update_users_change_avatar_length.php 0000644 00000001276 15266556541 0016314 0 ustar 00 string('avatar', 1055)->default('assets/img/auth/default-avatar.png')->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->string('avatar', 1055)->default('assets/img/auth/default-avatar.png')->change();
});
}
};
2025_06_25_062502_create_recent_search_keys_table.php 0000644 00000001277 15266556541 0015736 0 ustar 00 id();
$table->string('keyword')->index();
$table->foreignIdFor(User::class)->constrained()->cascadeOnDelete();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('recent_search_keys');
}
};
2023_07_21_121324_options_to_settingstwo_table.php 0000644 00000001336 15266556541 0015407 0 ustar 00 string('stablediffusion_default_language')->default('en-US');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('stablediffusion_default_language');
});
}
}
};
2023_04_13_175939_add_affiliate_to_settings_table.php 0000644 00000001232 15266556541 0015734 0 ustar 00 string('affiliate_minimum_withdrawal')->default(10);
$table->string('affiliate_commission_percentage')->default(10);
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn(['affiliate_minimum_withdrawal', 'affiliate_commission_percentage']);
});
}
};
2023_06_02_124908_create_frontend_generators_table.php 0000644 00000002003 15266556541 0016134 0 ustar 00 id();
$table->string('menu_title')->nullable();
$table->string('subtitle_one')->nullable();
$table->string('subtitle_two')->nullable();
$table->string('title')->nullable();
$table->text('text')->nullable();
$table->string('image')->nullable();
$table->string('image_title')->nullable();
$table->string('image_subtitle')->nullable();
$table->string('color')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_generators');
}
};
2024_01_04_073526_add_mobile_payment_active_column_to_settings_table.php 0000644 00000001165 15266556541 0021714 0 ustar 00 boolean('mobile_payment_active')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('mobile_payment_active');
});
}
};
2019_05_03_000002_create_subscriptions_table.php 0000644 00000002174 15266556541 0014763 0 ustar 00 id();
$table->foreignId('user_id');
$table->unsignedBigInteger('plan_id')->nullable();
$table->foreign('plan_id')->references('id')->on('plans')->nullOnDelete();
$table->string('name');
$table->string('stripe_id')->unique();
$table->string('stripe_status');
$table->string('stripe_price')->nullable();
$table->integer('quantity')->nullable();
$table->timestamp('trial_ends_at')->nullable();
$table->timestamp('ends_at')->nullable();
$table->timestamps();
$table->index(['user_id', 'stripe_status']);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('subscriptions');
}
};
2023_11_17_155940_add_folder_id_to_user_openai.php 0000644 00000001425 15266556541 0015235 0 ustar 00 unsignedBigInteger('folder_id')->nullable();
$table->foreign('folder_id')->references('id')->on('folders')->onDelete('cascade');
});
}
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
if (! isDBDriverSQLite()) {
$table->dropForeign(['folder_id']);
}
$table->dropColumn('folder_id');
});
}
};
2024_12_16_074143_add_column_to_scheduled_posts_table.php 0000644 00000001554 15266556541 0016630 0 ustar 00 text('content')->nullable()->after('prompt');
$table->text('media')->nullable()->after('content');
$table->boolean('auto_generate')->default(false)->nullable()->after('media');
});
}
}
public function down(): void
{
if (Schema::hasTable('scheduled_posts')) {
Schema::table('scheduled_posts', function (Blueprint $table) {
$table->dropColumn(['content', 'media', 'auto_generate']);
});
}
}
};
2024_01_29_150757_chatbot_message_data.php 0000644 00000001211 15266556541 0013521 0 ustar 00 tinyInteger('is_chatbot')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat_messages', function (Blueprint $table) {
$table->dropColumn('is_chatbot');
});
}
};
2024_05_21_091043_create_tokens_table.php 0000644 00000001320 15266556541 0013362 0 ustar 00 id();
$table->string('type')->default(\App\Enums\AITokenType::WORD->value);
$table->foreignId('ai_model_id')->constrained('ai_models', 'id')->cascadeOnDelete();
$table->decimal('cost_per_token', 15, 2)->default(1.00);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('tokens');
}
};
2023_03_20_134019_add_type_to_user_orders_table.php 0000644 00000001145 15266556541 0015445 0 ustar 00 string('type')->default('subscription');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_orders', function (Blueprint $table) {
$table->dropColumn('type');
});
}
};
2023_05_30_110811_create_howitworks_table.php 0000644 00000001174 15266556541 0014300 0 ustar 00 id();
$table->integer('order')->default(0);
$table->string('title')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('howitworks');
}
};
2025_03_24_112325_add_is_pinned_to_user_openai_chat_table.php 0000644 00000001161 15266556541 0017410 0 ustar 00 boolean('is_pinned')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn('is_pinned');
});
}
};
2024_12_17_081626_add_index_to_user_openai.php 0000644 00000001321 15266556541 0014411 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->string('subject');
$table->string('status')->default('Waiting for answer');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_support');
}
};
2024_07_19_212020_create_advanced_features_sectoion_table.php 0000644 00000001253 15266556541 0017431 0 ustar 00 id();
$table->string('title');
$table->text('description');
$table->string('image');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('advanced_features_sectoion');
}
};
2023_05_31_153647_add_new_logo_type_options.php 0000644 00000005031 15266556541 0014636 0 ustar 00 string('logo_dark')->default('magicAI-logo-dark.svg');
$table->text('logo_dashboard')->nullable();
$table->text('logo_dashboard_dark')->nullable();
$table->string('logo_collapsed_dark')->default('magicAI-logo-collapsed-dark.svg');
$table->text('logo_2x')->nullable();
$table->text('logo_dark_2x')->nullable();
$table->text('logo_dashboard_2x')->nullable();
$table->text('logo_dashboard_dark_2x')->nullable();
$table->text('logo_collapsed_2x')->nullable();
$table->text('logo_collapsed_dark_2x')->nullable();
$table->string('logo_dark_path')->default('assets/img/logo/magicAI-logo-dark.svg');
$table->text('logo_dashboard_path')->nullable();
$table->text('logo_dashboard_dark_path')->nullable();
$table->string('logo_collapsed_dark_path')->default('assets/img/logo/magicAI-logo-collapsed-dark.svg');
$table->text('logo_2x_path')->nullable();
$table->text('logo_dark_2x_path')->nullable();
$table->text('logo_dashboard_2x_path')->nullable();
$table->text('logo_dashboard_dark_2x_path')->nullable();
$table->text('logo_collapsed_2x_path')->nullable();
$table->text('logo_collapsed_dark_2x_path')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn([
'logo_dark',
'logo_dashboard',
'logo_dashboard_dark',
'logo_collapsed_dark',
'logo_2x',
'logo_dark_2x',
'logo_dashboard_2x',
'logo_dashboard_dark_2x',
'logo_collapsed_2x',
'logo_collapsed_dark_2x',
'logo_dark_path',
'logo_dashboard_path',
'logo_dashboard_dark_path',
'logo_collapsed_dark_path',
'logo_2x_path',
'logo_dark_2x_path',
'logo_dashboard_2x_path',
'logo_dashboard_dark_2x_path',
'logo_collapsed_2x_path',
'logo_collapsed_dark_2x_path',
]);
});
}
};
2023_11_17_155039_create_folders_table.php 0000644 00000001315 15266556541 0013530 0 ustar 00 id();
$table->string('name');
$table->unsignedBigInteger('created_by');
$table->timestamps();
$table->foreign('created_by')->references('id')->on('users')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('folders');
}
};
2023_12_18_145013_add_ai_pdf_to_chat_to_settings_table.php 0000644 00000001156 15266556541 0016720 0 ustar 00 tinyInteger('feature_ai_pdf')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('feature_ai_pdf');
});
}
};
2023_04_13_175439_create_user_affiliates_table.php 0000644 00000001436 15266556541 0015247 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->double('amount');
$table->string('status')->default('Waiting');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_affiliates');
}
};
2024_06_18_080246_add_some_fields_to_frontend_tools_table.php 0000644 00000002104 15266556541 0017471 0 ustar 00 string('buy_link')->default('Start Making Money');
$table->string('buy_link_url')->default('https://codecanyon.net/item/magicai-openai-content-text-image-chat-code-generator-as-saas/45408109');
$table->string('learn_more_link')->default('Discover MagicAI');
$table->string('learn_more_link_url')->default('#templates');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_tools', function (Blueprint $table) {
$table->dropColumn('buy_link');
$table->dropColumn('buy_link_url');
$table->dropColumn('learn_more_link');
$table->dropColumn('learn_more_link_url');
});
}
};
2023_06_01_145426_create_gateways_table.php 0000644 00000003235 15266556541 0013715 0 ustar 00 id();
$table->string('code')->nullable();
$table->string('title')->nullable();
$table->integer('is_active')->default(0);
$table->string('mode')->nullable();
$table->string('sandbox_client_id')->nullable();
$table->string('sandbox_client_secret')->nullable();
$table->string('sandbox_app_id')->nullable();
$table->string('live_client_id')->nullable();
$table->string('live_client_secret')->nullable();
$table->string('live_app_id')->nullable();
$table->string('payment_action')->nullable(); // PAYPAL: Can only be 'Sale', 'Authorization' or 'Order'
$table->string('currency')->nullable();
$table->string('currency_locale')->nullable();
$table->string('notify_url')->nullable();
$table->string('base_url')->nullable();
$table->string('sandbox_url')->nullable();
$table->string('locale')->nullable();
$table->string('validate_ssl')->nullable();
$table->string('webhook_secret')->nullable();
$table->string('logger')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('gateways');
}
};
2023_03_14_073839_create_user_openai_table.php 0000644 00000002164 15266556541 0014413 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->unsignedBigInteger('openai_id')->nullable();
$table->foreign('openai_id')->references('id')->on('openai')->nullOnDelete();
$table->text('input')->nullable();
$table->text('response')->nullable();
$table->text('output')->nullable();
$table->text('hash')->nullable();
$table->string('credits')->nullable();
$table->string('words')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_openai');
}
};
2024_10_22_154324_remove_plan_total_words_and_images_columns.php 0000644 00000001536 15266556541 0020234 0 ustar 00 dropColumn(['total_words', 'total_images', 'display_imag_count', 'display_word_count']);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', static function (Blueprint $table) {
$table->integer('total_words')->default(0);
$table->integer('total_images')->default(0);
$table->boolean('display_imag_count')->default(1);
$table->boolean('display_word_count')->default(1);
});
}
};
2023_05_15_140015_create_user_openai_chat_table.php 0000644 00000002053 15266556541 0015367 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->unsignedBigInteger('openai_chat_category_id')->nullable();
$table->foreign('openai_chat_category_id')->references('id')->on('openai_chat_category')->onDelete('cascade');
$table->string('title')->nullable();
$table->string('total_credits')->nullable();
$table->string('total_words')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_openai_chat');
}
};
2024_05_08_163635_create_photo_studios_table.php 0000644 00000001222 15266556541 0014777 0 ustar 00 id();
$table->bigInteger('user_id')->nullable();
$table->string('photo')->nullable();
$table->text('payload')->nullable();
$table->integer('credits')->default(0);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('photo_studios');
}
};
2023_07_19_105519_add_package_column_to_openai_table.php 0000644 00000001122 15266556541 0016365 0 ustar 00 text('package')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai', function (Blueprint $table) {
$table->dropColumn('package');
});
}
};
2025_03_18_053809_create_curtains_table.php 0000644 00000010204 15266556541 0013725 0 ustar 00 id();
$table->string('title')->nullable();
$table->string('title_icon')->nullable();
$table->json('sliders')->nullable();
$table->timestamps();
});
$items = [
[
'title' => 'Sarah J.',
'title_icon' => '',
'sliders' => [
[
'title' => 'Sarah J.',
'description' => 'Translates Podcasts into different languages.',
'bg_color' => '',
'bg_image' => '',
'bg_video' => '/themes/social-media-front/assets/landing-page/demo-vid-1.webm',
'title_color' => '',
'description_color' => '',
],
[
'title' => 'Sarah J.',
'description' => '',
'bg_color' => '',
'bg_image' => '',
'bg_video' => '/themes/social-media-front/assets/landing-page/demo-vid-1.webm',
'title_color' => '',
'description_color' => '',
],
[
'title' => 'Sarah J.',
'description' => '',
'bg_color' => '',
'bg_image' => '',
'bg_video' => '/themes/social-media-front/assets/landing-page/demo-vid-1.webm',
'title_color' => '',
'description_color' => '',
],
],
],
[
'title' => 'Jason R.',
'title_icon' => '',
'sliders' => [
[
'title' => 'Jason R.',
'description' => '',
'bg_color' => '#aea397',
'bg_image' => '',
'bg_video' => '/themes/social-media-front/assets/landing-page/demo-vid-1.webm',
'title_color' => '',
'description_color' => '',
],
[
'title' => 'Jason R.',
'description' => '',
'bg_color' => '#aea397',
'bg_image' => '/themes/social-media-front/assets/landing-page/banner-img.jpg',
'bg_video' => '',
'title_color' => '',
'description_color' => '',
],
],
],
[
'title' => 'Mary J.',
'title_icon' => '',
'sliders' => [
[
'title' => 'Mary J.',
'description' => '',
'bg_color' => '#496e8f',
'bg_image' => '',
'bg_video' => '/themes/social-media-front/assets/landing-page/demo-vid-1.webm',
'title_color' => '',
'description_color' => '',
],
],
],
];
foreach ($items as $item) {
\App\Models\Frontend\Curtain::create($item);
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_curtains');
}
};
2024_02_27_134353_add_tone_of_voice_to_companies_table.php 0000644 00000001146 15266556541 0016735 0 ustar 00 string('tone_of_voice')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('companies', function (Blueprint $table) {
$table->dropColumn('tone_of_voice');
});
}
};
2025_06_20_214812_add_2checkout_customer_reference_colmn_to_users_table.php 0000644 00000001536 15266556541 0022320 0 ustar 00 string('two_checkout_customer_reference')->nullable()->after('stripe_id');
}
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
if (Schema::hasColumn('users', 'two_checkout_customer_reference')) {
$table->dropColumn('two_checkout_customer_reference');
}
});
}
};
2023_12_28_040900_add_new_fields_to_user_orders_table.php 0000644 00000001244 15266556541 0016606 0 ustar 00 string('tax_rate')->nullable();
$table->string('tax_value')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_orders', function (Blueprint $table) {
$table->dropColumn(['tax_rate', 'tax_value']);
});
}
};
2024_02_26_185155_create_products_table.php 0000644 00000002046 15266556541 0013742 0 ustar 00 id();
$table->string('name')->nullable();
$table->integer('type')->nullable();
$table->text('key_features')->nullable();
$table->unsignedBigInteger('user_id')->nullable(); // Add a nullable foreign key to link to the User model
$table->foreign('user_id')->references('id')->on('users')->onDelete('set null');
$table->unsignedBigInteger('company_id')->nullable();
$table->foreign('company_id')->references('id')->on('companies')->onDelete('set null');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('products');
}
};
2023_05_29_130259_create_testimonials_table.php 0000644 00000001415 15266556541 0014611 0 ustar 00 id();
$table->string('avatar')->default('assets/img/auth/default-avatar.png');
$table->string('full_name')->nullable();
$table->string('job_title')->nullable();
$table->string('words')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('testimonials');
}
};
2024_05_22_154814_change_integer_to_float_in_team_members.php 0000644 00000001452 15266556541 0017441 0 ustar 00 decimal('remaining_images', 15, 2)->nullable()->change();
$table->decimal('remaining_words', 15, 2)->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('team_members', function (Blueprint $table) {
$table->integer('remaining_images')->nullable()->change();
$table->integer('remaining_words')->nullable()->change();
});
}
};
2024_06_25_112300_create_notifications_table.php 0000644 00000001326 15266556541 0014731 0 ustar 00 uuid('id')->primary();
$table->string('type');
$table->morphs('notifiable');
$table->text('data');
$table->timestamp('read_at')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('notifications');
}
};
2019_05_02_122941_create_plans_table.php 0000644 00000002606 15266556541 0013211 0 ustar 00 id();
$table->boolean('active')->default(1);
$table->string('name')->nullable();
$table->double('price')->default(0);
$table->string('currency')->default('USD');
$table->string('frequency')->default('monthly');
$table->boolean('is_featured')->default(0);
$table->boolean('is_free')->default(0);
$table->string('stripe_product_id')->nullable();
$table->string('total_words')->nullable();
$table->string('total_images')->nullable();
$table->string('ai_name')->nullable();
$table->bigInteger('max_tokens')->nullable();
$table->boolean('can_create_ai_images')->nullable();
$table->string('plan_type')->default('all');
$table->text('features')->nullable();
$table->string('type')->default('subscription');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('plans');
}
};
2023_06_08_122900_add_hero_title_text_rotator_to_frontend_footer_settings_table.php 0000644 00000001300 15266556541 0024217 0 ustar 00 string('hero_title_text_rotator')->nullable()->default('Generator,Chatbot,Assistant');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_footer_settings', function (Blueprint $table) {
$table->dropColumn('hero_title_text_rotator');
});
}
};
2023_07_18_222043_add_image_storage_field_to_settings_two_table.php 0000644 00000001277 15266556541 0020646 0 ustar 00 string('ai_image_storage')->default('public');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
if (Schema::hasTable('settings_two')) {
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn('ai_image_storage');
});
}
}
};
2024_02_16_163955_create_elevenlab_voices_table.php 0000644 00000001211 15266556541 0015400 0 ustar 00 id();
$table->string('name');
$table->string('voice_id')->nullable();
$table->string('path')->nullable();
$table->boolean('status')->default(true);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('elevenlab_voices');
}
};
2023_07_24_103747_create_subscriptions_yokassa_table.php 0000644 00000002171 15266556541 0016536 0 ustar 00 id();
$table->foreignId('user_id');
$table->unsignedBigInteger('plan_id')->nullable();
$table->foreign('plan_id')->references('id')->on('plans')->nullOnDelete();
$table->string('name');
$table->string('payment_method_id')->nullabe();
$table->string('subscription_status')->nullabe();
$table->timestamp('trial_ends_at')->nullable();
$table->timestamp('ends_at')->nullable();
$table->timestamp('next_pay_at')->nullable();
$table->timestamps();
$table->index(['user_id', 'subscription_status']);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('subscriptions_yokassa');
}
};
2025_08_13_102938_remove_openai_deprected_models.php 0000644 00000002043 15266556541 0015615 0 ustar 00 openai_default_model;
if (in_array($default, $modelsToBeRemoved, true)) {
$newDefault = 'gpt-4o';
$settings->update(['openai_default_model' => $newDefault]);
Setting::forgetCache();
}
foreach ($modelsToBeRemoved as $model) {
EntityRemover::removeEntity($model);
}
} catch (\Throwable $exception) {
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2014_10_12_100000_create_password_reset_tokens_table.php 0000644 00000001201 15266556541 0016457 0 ustar 00 string('email')->primary();
$table->string('token');
$table->timestamp('created_at')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('password_reset_tokens');
}
};
2024_01_02_071044_add_auto_renewal_colmn_to_plans_table.php 0000644 00000001155 15266556541 0017120 0 ustar 00 boolean('auto_renewal')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('subscriptions', function (Blueprint $table) {
$table->dropColumn('auto_renewal');
});
}
};
2025_03_17_111036_add_social_theme_frontend_setting_migration.php 0000644 00000036260 15266556541 0020350 0 ustar 00 string('no_credit_cart_required', 500)->default('No credit cart required.')->nullable();
}
if (! Schema::hasColumn('frontend_footer_settings', 'faster_content_creation')) {
$table->string('faster_content_creation', 500)->default('10xFaster Content Creation')->nullable();
}
if (! Schema::hasColumn('frontend_footer_settings', 'over_5000_businesses')) {
$table->string('over_5000_businesses', 500)->default('over 5000+ businesses trust us to boost their social media precense')->nullable();
}
if (! Schema::hasColumn('frontend_footer_settings', 'join_the_ranks')) {
$table->longText('join_the_ranks')->nullable();
}
});
if (Schema::hasColumn('frontend_footer_settings', 'join_the_ranks')) {
$find = \App\Models\Frontend\FrontendSetting::query()->first();
if ($find) {
$find->join_the_ranks = 'Join the ranks of renowned
influencers and top-tier social media agencies.';
$find->save();
}
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2024_02_14_085457_add_razorpay_id_column_to_users_table.php 0000644 00000001204 15266556541 0017203 0 ustar 00 string('razorpay_id')->nullable()->index();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn([
'razorpay_id',
]);
});
}
};
2024_06_27_135525_add_recaptcha_to_settings_table.php 0000644 00000001410 15266556541 0015733 0 ustar 00 boolean('recaptcha_login')->default(false);
$table->boolean('recaptcha_register')->default(false);
$table->string('recaptcha_sitekey')->nullable();
$table->string('recaptcha_secretkey')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2025_10_13_212019_add_affiliate_status_column_to_plans_table.php 0000644 00000001150 15266556541 0020144 0 ustar 00 boolean('affiliate_status')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('affiliate_status');
});
}
};
2024_10_14_082619_add_aimlapi_key_to_settings_table.php 0000644 00000001166 15266556541 0016271 0 ustar 00 text('aimlapi_key')->nullable();
$table->text('ai_music_model')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2025_05_06_102938_2remove_gemini_deprected_models.php 0000644 00000001547 15266556541 0015703 0 ustar 00 where('migration', '2025_05_05_102938_remove_gemini_deprected_models')
->delete();
$modelsToBeRemoved = [
'gemini-pro-vision',
'gemini-pro',
'gemini-1.5-pro-latest',
'gemini-1__5-pro-latest',
];
$default = setting('gemini_default_model');
if (in_array($default, $modelsToBeRemoved, true)) {
$newDefault = 'gemini-1.5-flash';
setting([
'gemini_default_model' => $newDefault,
])->save();
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
//
}
};
2024_08_12_050354_create_user_credits_table.php 0000644 00000001053 15266556541 0014560 0 ustar 00 id();
$table->bigInteger('user_id')->nullable();
$table->json('credits')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('user_credits');
}
};
2023_06_09_091144_add_keywords_columns_to_settings_table.php 0000644 00000001161 15266556541 0017410 0 ustar 00 text('meta_keywords')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('meta_keywords');
});
}
};
2024_01_17_072456_create_extensions_table.php 0000644 00000001746 15266556541 0014302 0 ustar 00 id();
$table->string('slug')->nullable();
$table->string('name')->nullable();
$table->float('review')->nullable();
$table->text('description')->nullable();
$table->string('category')->nullable();
$table->string('badge')->nullable();
$table->string('zip_url')->nullable();
$table->string('price_id')->nullable();
$table->boolean('installed')->default(false);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('extensions');
}
};
2024_05_03_094207_add_show_page_on_footer_to_pages_table.php 0000644 00000001102 15266556541 0017256 0 ustar 00 tinyInteger('show_on_footer')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('pages', function (Blueprint $table) {
//
});
}
};
2024_02_28_130323_add_user_id_to_chatbot_table.php 0000644 00000002075 15266556541 0015213 0 ustar 00 bigInteger('user_id')->nullable()->after('id');
});
Schema::table('chatbot', function (Blueprint $table) {
$table->bigInteger('user_id')->nullable()->after('id');
});
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->bigInteger('user_id')->nullable()->after('id');
});
}
public function down(): void
{
Schema::table('chat_category', function (Blueprint $table) {
$table->dropColumn('user_id');
});
Schema::table('chatbot', function (Blueprint $table) {
$table->dropColumn('user_id');
});
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('user_id');
});
}
};
2024_01_29_143721_create_team_members_table.php 0000644 00000002223 15266556541 0014527 0 ustar 00 id();
$table->foreignId('team_id')->constrained('teams')->cascadeOnDelete();
$table->foreignId('user_id')->nullable()->constrained('users')->nullOnDelete();
$table->string('role')->default('member');
$table->string('email')->nullable();
$table->string('status')->default('waiting')->nullable();
$table->boolean('allow_unlimited_credits')->default(true);
$table->integer('remaining_images')->nullable();
$table->integer('remaining_words')->nullable();
$table->integer('used_image_credit')->default(0);
$table->integer('used_word_credit')->default(0);
$table->timestamp('joined_at')->nullable();
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('team_members');
}
};
2023_08_31_135312_change_facebook_token_type.php 0000644 00000001140 15266556541 0014705 0 ustar 00 text('facebook_token')->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->text('facebook_token')->change();
});
}
};
2025_04_10_113919_create_referers_table.php 0000644 00000001246 15266556541 0013710 0 ustar 00 id();
$table->string('session_id');
$table->string('referer');
$table->string('domain', 128)->index();
$table->timestamp('created_at');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('referers');
}
};
2025_02_26_082114_add_xai_api_keys_to_users_table.php 0000644 00000001132 15266556541 0015737 0 ustar 00 text('xai_api_keys')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('xai_api_keys');
});
}
};
2024_09_25_125009_update_sd_values_in_app_settings_table.php 0000644 00000000727 15266556541 0017353 0 ustar 00 where('key', 'default_aw_image_engine')
->where('value', 'sd')
->update(['value' => EngineEnum::STABLE_DIFFUSION->value]);
}
public function down(): void {}
};
2023_06_02_124736_create_frontend_who_is_for_table.php 0000644 00000001215 15266556541 0016124 0 ustar 00 id();
$table->string('title')->nullable();
$table->string('color')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_who_is_for');
}
};
2023_03_22_101116_add_paths_to_settings_table.php 0000644 00000001155 15266556541 0015102 0 ustar 00 string('logo_path')->default('assets/img/logo/magicAI-logo.svg');
$table->string('favicon_path')->nullable();
});
}
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn(['logo_path', 'favicon_path']);
});
}
};
2024_01_29_110158_add_apple_columns_to_user_table.php 0000644 00000001461 15266556541 0015756 0 ustar 00 string('apple_id')->nullable();
$table->string('apple_token')->nullable();
$table->string('apple_refresh_token')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn([
'apple_id',
'apple_token',
'apple_refresh_token',
]);
});
}
};
2023_11_28_141010_create_chat_category_table.php 0000644 00000001103 15266556541 0014663 0 ustar 00 id();
$table->string('name');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('chat_category');
}
};
2024_09_12_185443_add_default_mrrobot_words_to_settings.php 0000644 00000001326 15266556541 0017247 0 ustar 00 text('mrrobot_name')->nullable();
$table->text('mrrobot_search_words')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
$table->dropColumn('mrrobot_name');
$table->dropColumn('mrrobot_search_words');
});
}
};
2024_01_06_123827_add_revenuecat_id_column_to_users.php 0000644 00000001140 15266556541 0016317 0 ustar 00 string('revenuecat_id')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn(['revenuecat_id']);
});
}
};
2025_01_24_145331_add_reset_credits_on_renewal_column_to_plans_table.php 0000644 00000001171 15266556541 0021674 0 ustar 00 boolean('reset_credits_on_renewal')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('reset_credits_on_renewal');
});
}
};
2023_09_19_064148_create_article_wizard_table.php 0000644 00000002754 15266556541 0015116 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->text('keywords');
$table->text('extra_keywords');
$table->text('topic_keywords');
$table->text('title');
$table->text('extra_titles');
$table->text('topic_title');
$table->string('language')->default('');
$table->string('tone')->default('');
$table->string('image_style')->default('');
$table->integer('image_count')->default(0);
$table->text('outline');
$table->text('extra_outlines');
$table->text('topic_outline');
$table->integer('current_step')->default(0);
$table->text('result');
$table->text('image');
$table->text('extra_images');
$table->text('topic_image');
$table->integer('generated_count')->default(0);
$table->float('creativity')->default(0.5);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('article_wizard');
}
};
2024_03_19_151400_add_first_message_to_openai_chat_category_table.php 0000644 00000001221 15266556541 0021127 0 ustar 00 text('first_message')->nullable()->after('instructions');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('openai_chat_category', function (Blueprint $table) {
$table->dropColumn('first_message');
});
}
};
2025_03_18_050755_create_channel_settings_table.php 0000644 00000005654 15266556541 0015437 0 ustar 00 id();
$table->string('title');
$table->string('key');
$table->text('description')->nullable();
$table->string('image')->nullable();
$table->string('logo')->nullable();
$table->timestamps();
});
$data = [
[
'key' => 'facebook',
'title' => 'Facebook',
'description' => "Our AI tool helps you craft compelling content that resonates with your audience Whether it's a status update, promotional post, or a simple interaction.",
'logo' => 'assets/landing-page/logo-fb.png',
'image' => '/themes/social-media-front/assets/landing-page/card-fb.jpg',
],
[
'key' => 'x',
'title' => 'Twitter / X',
'description' => "Create impactful X posts with our AI tool in seconds! Whether it's a quick update, an engaging tweet, or a conversation starter, generate posts that drive conversations and keep your followers engaged on X.",
'logo' => 'assets/landing-page/logo-x.png',
'image' => '/themes/social-media-front/assets/landing-page/card-x.jpg',
],
[
'key' => 'instagram',
'title' => 'Instagram',
'description' => "Design eye-catching Instagram posts in no time with our AI-powered generator. From beautiful visuals to captivating captions, create Instagram content that stands out and grabs your followers' attention.",
'logo' => 'assets/landing-page/logo-ig.png',
'image' => '/themes/social-media-front/assets/landing-page/card-ig.jpg',
],
[
'key' => 'linkedin',
'title' => 'LinkedIn',
'description' => 'Build your professional presence with polished LinkedIn posts. Our AI helps you write insightful articles, thought-provoking updates, and attention-grabbing headlines that engage with your network.',
'logo' => 'assets/landing-page/logo-in.png',
'image' => '/themes/social-media-front/assets/landing-page/card-in.jpg',
],
];
foreach ($data as $item) {
ChannelSetting::query()->create($item);
}
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('frontend_channel_settings');
}
};
2023_08_11_125732_create_paystack_payment_infos_table.php 0000644 00000002467 15266556541 0016652 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->string('email')->nullable();
$table->string('reference')->nullable();
$table->string('trans')->nullable();
$table->string('status')->nullable();
$table->string('message')->nullable();
$table->string('transaction')->nullable();
$table->string('trxref')->nullable();
$table->string('amount')->nullable();
$table->string('currency')->nullable();
$table->string('plan_code')->nullable();
$table->string('customer_code')->nullable();
$table->string('other')->nullable();
$table->timestamps();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('paystack_payment_infos');
}
};
2023_07_01_080909_create_advertis_table.php 0000644 00000001317 15266556541 0013716 0 ustar 00 id();
$table->string('key');
$table->string('title');
$table->longText('tracking_code')->nullable();
$table->boolean('status')->default(false);
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('advertis');
}
};
2025_04_25_094959_add_last_activity_at_to_users_table.php 0000644 00000000770 15266556541 0016671 0 ustar 00 timestamp('last_activity_at')->nullable()->useCurrent()->index();
});
}
/**
* Reverse the migrations.
*/
public function down(): void {}
};
2024_12_10_071444_add_user_api_to_plans_table.php 0000644 00000001131 15266556541 0015051 0 ustar 00 boolean('user_api')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('user_api');
});
}
};
2019_05_03_000003_create_subscription_items_table.php 0000644 00000001537 15266556541 0016004 0 ustar 00 id();
$table->foreignId('subscription_id');
$table->string('stripe_id')->unique();
$table->string('stripe_product');
$table->string('stripe_price');
$table->integer('quantity')->nullable();
$table->timestamps();
$table->unique(['subscription_id', 'stripe_price']);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('subscription_items');
}
};
2025_05_02_115019_fix_typo_in_dashboard_widgets.php 0000644 00000001102 15266556541 0015447 0 ustar 00 string('name', 255)->change()->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('dashboard_widgets', function (Blueprint $table) {});
}
};
2024_03_25_085453_add_theme_columns_to_extension_table.php 0000644 00000001506 15266556541 0017024 0 ustar 00 boolean('is_theme')->default(false)->after('licensed');
$table->enum('theme_type', ['All', 'Frontend', 'Dashboard'])->default('All')->after('is_theme');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('extensions', function (Blueprint $table) {
if (Schema::hasColumn('extensions', 'theme_type')) {
$table->dropColumn(['is_theme', 'theme_type']);
}
});
}
};
2023_03_20_115202_add_user_id_to_user_orders_table.php 0000644 00000001324 15266556541 0016106 0 ustar 00 unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
});
}
public function down(): void
{
Schema::table('user_orders', function (Blueprint $table) {
if (! isDBDriverSQLite()) {
$table->dropForeign(['user_id']);
}
$table->dropColumn('user_id');
});
}
};
2024_11_18_102726_change_amount_col_in_user_affiliates_table.php 0000644 00000001202 15266556541 0020117 0 ustar 00 double('amount')->default(0)->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_affiliates', static function (Blueprint $table) {
$table->double('amount')->change();
});
}
};
2024_06_18_062706_add_tool_subtitle_to_frontend_sections_statuses_titles_table.php 0000644 00000004562 15266556541 0024111 0 ustar 00 string('tools_subtitle')->default('Unleash the Power of AI')->after('tools_title');
$table->string('custom_templates_learn_more_link')->default('Discover MagicAI')->after('custom_templates_title');
$table->string('custom_templates_learn_more_link_url')->default('#templates')->after('custom_templates_title');
$table->string('features_subtitle')->default('Unleash the Power of AI')->after('features_title');
$table->string('how_it_works_subtitle')->default('Unleash the Power of AI')->after('how_it_works_title');
$table->string('how_it_works_description')->default('To create content quickly and effectively, here are the steps you can follow:')->after('how_it_works_title');
$table->string('how_it_works_link')->default('#')->after('how_it_works_title');
$table->string('how_it_works_link_label')->default('Learn More')->after('how_it_works_title');
$table->string('pricing_subtitle')->default('Unleash the Power of AI')->after('pricing_title');
$table->string('testimonials_description')->default('Content and kickstart your earnings in minutes kickstart your earnings in minutes')->after('testimonials_title');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
$table->dropColumn('tools_subtitle');
$table->dropColumn('custom_templates_learn_more_link');
$table->dropColumn('custom_templates_learn_more_link_url');
$table->dropColumn('features_subtitle');
$table->dropColumn('how_it_works_subtitle');
$table->dropColumn('how_it_works_description');
$table->dropColumn('how_it_works_link');
$table->dropColumn('how_it_works_link_label');
$table->dropColumn('pricing_subtitle');
$table->dropColumn('testimonials_description');
});
}
};
2024_01_16_053948_add_tts_settings_to_settings_two_table.php 0000644 00000001731 15266556541 0017433 0 ustar 00 string('elevenlabs_api_key')->nullable();
$table->boolean('feature_tts_google')->default(false);
$table->boolean('feature_tts_openai')->default(true);
$table->boolean('feature_tts_elevenlabs')->default(false);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
$table->dropColumn([
'elevenlabs_api_key',
'feature_tts_google',
'feature_tts_openai',
'feature_tts_elevenlabs',
]);
});
}
};
2024_09_24_095546_update_ai_models_table.php 0000644 00000001552 15266556541 0014064 0 ustar 00 dropColumn('is_active');
});
Schema::table('ai_models', static function (Blueprint $table) {
$table->string('status')->default(StatusEnum::ENABLED->value);
});
}
public function down(): void
{
Schema::table('ai_models', static function (Blueprint $table) {
$table->dropColumn('status');
});
Schema::table('ai_models', static function (Blueprint $table) {
$table->boolean('is_active')->default(false);
});
}
};
2025_08_13_160030_add_effort_col_to_entities_table.php 0000644 00000001126 15266556541 0016076 0 ustar 00 string('effort')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('entities', function (Blueprint $table) {
$table->dropColumn('effort');
});
}
};
2023_09_29_075552_add_floating_button_to_frontend_footer_settings.php 0000644 00000001660 15266556541 0021323 0 ustar 00 string('floating_button_small_text')->nullable();
$table->string('floating_button_bold_text')->nullable();
$table->string('floating_button_link')->nullable();
$table->boolean('floating_button_active')->default(false);
});
}
public function down(): void
{
Schema::table('frontend_footer_settings', function (Blueprint $table) {
$table->dropColumn([
'floating_button_small_text',
'floating_button_bold_text',
'floating_button_link',
'floating_button_active',
]);
});
}
};
2023_03_01_113611_create_settings_table.php 0000644 00000007551 15266556541 0013722 0 ustar 00 id();
// INVOICE
$table->string('invoice_currency')->nullable();
$table->string('invoice_name')->nullable();
$table->string('invoice_website')->nullable();
$table->string('invoice_address')->nullable();
$table->string('invoice_city')->nullable();
$table->string('invoice_state')->nullable();
$table->string('invoice_postal')->nullable();
$table->string('invoice_country')->nullable();
$table->string('invoice_phone')->nullable();
$table->string('invoice_vat')->nullable();
// PAYMENT
$table->string('default_currency')->default('2');
$table->string('tax_rate')->nullable();
$table->string('stripe_active')->default(0);
$table->string('stripe_key')->nullable();
$table->string('stripe_secret')->nullable();
$table->string('stripe_base_url')->default('https://api.stripe.com');
$table->string('bank_transfer_active')->default(0);
$table->string('bank_transfer_instructions')->nullable();
$table->string('bank_transfer_informations')->nullable();
// GLOBAL SETTINGS
$table->string('site_name')->default('MagicAI');
$table->string('site_url')->default('https://liquid-themes.com');
$table->string('site_email')->nullable();
$table->string('google_analytics_active')->default(0);
$table->text('google_analytics_code')->nullable();
$table->string('logo')->default('magicAI-logo.svg');
$table->string('favicon')->nullable();
$table->text('meta_title')->nullable();
$table->text('meta_description')->nullable();
// SOCIAL LOGIN
$table->boolean('facebook_active')->default(0);
$table->text('facebook_api_key')->nullable();
$table->text('facebook_api_secret')->nullable();
$table->text('facebook_redirect_url')->nullable();
$table->boolean('github_active')->default(0);
$table->text('github_api_key')->nullable();
$table->text('github_api_secret')->nullable();
$table->text('github_redirect_url')->nullable();
$table->boolean('google_active')->default(0);
$table->text('google_api_key')->nullable();
$table->text('google_api_secret')->nullable();
$table->text('google_redirect_url')->nullable();
$table->boolean('twitter_active')->default(0);
$table->text('twitter_api_key')->nullable();
$table->text('twitter_api_secret')->nullable();
$table->text('twitter_redirect_url')->nullable();
// REGISTER
$table->boolean('register_active')->default(1);
$table->string('default_country')->default('United States');
// SMTP
$table->string('smtp_host')->nullable();
$table->string('smtp_port')->nullable();
$table->string('smtp_username')->nullable();
$table->string('smtp_password')->nullable();
$table->string('smtp_email')->nullable();
$table->string('smtp_sender_name')->nullable();
$table->string('smtp_encryption')->default('TLS');
// OPENAI
$table->text('openai_api_secret')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('settings');
}
};
2024_10_17_124512_remove_free_plan_column_from_settings_table.php 0000644 00000001163 15266556541 0020370 0 ustar 00 dropColumn('free_plan');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', static function (Blueprint $table) {
$table->string('free_plan', 100)->default('0,0');
});
}
};
2024_01_30_084904_chatbot_history.php 0000644 00000001411 15266556541 0012577 0 ustar 00 id();
$table->integer('user_id')->nullable();
$table->string('ip')->nullable();
$table->integer('user_openai_chat_id')->nullable();
$table->integer('openai_chat_category_id')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('chatbot_history');
}
};
2023_05_03_105011_create_user_favorites_table.php 0000644 00000001472 15266556541 0015115 0 ustar 00 id();
$table->unsignedBigInteger('user_id')->nullable();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
$table->unsignedBigInteger('openai_id')->nullable();
$table->foreign('openai_id')->references('id')->on('openai')->onDelete('cascade');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_favorites');
}
};
2017_08_24_000000_create_app_settings_table.php 0000644 00000000777 15266556541 0014565 0 ustar 00 increments('id');
$table->string('key')->index();
$table->text('value');
});
}
public function down(): void
{
Schema::drop('app_settings');
}
}
2023_03_01_134254_create_user_support_messages_table.php 0000644 00000001562 15266556541 0016525 0 ustar 00 id();
$table->unsignedBigInteger('user_support_id')->nullable();
$table->foreign('user_support_id')->references('id')->on('user_support')->onDelete('cascade');
$table->string('sender')->default('user');
$table->text('message');
$table->text('attachment')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('user_support_messages');
}
};
2025_01_08_132515_add_parent_id_to_introduction_table.php 0000644 00000001201 15266556541 0016614 0 ustar 00 integer('parent_id')->nullable();
$table->text('intro')->nullable()->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('introduction', function (Blueprint $table) {
//
});
}
};
2023_06_14_114054_add_trial_days_field_to_plans_table.php 0000644 00000001131 15266556541 0016541 0 ustar 00 integer('trial_days')->default(0);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn('trial_days');
});
}
};
2024_07_31_051243_add_plan_columns_to_plans_table.php 0000644 00000001064 15266556541 0015743 0 ustar 00 json('plan_ai_tools');
$table->json('plan_features');
});
}
public function down(): void
{
Schema::table('plans', function (Blueprint $table) {
$table->dropColumn(['plan_ai_tools', 'plan_features']);
});
}
};
2023_03_30_000547_add_workbook_items_to_user_openai_table.php 0000644 00000001072 15266556541 0017475 0 ustar 00 string('title')->nullable();
$table->string('slug')->nullable();
});
}
public function down(): void
{
Schema::table('user_openai', function (Blueprint $table) {
$table->dropColumn(['title', 'slug']);
});
}
};
2024_07_25_131428_add_pebblely_key_to_settings_table.php 0000644 00000001077 15266556541 0016455 0 ustar 00 text('pebblely_key')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings', function (Blueprint $table) {
//
});
}
};
2025_01_02_123507_add_file_to_introductions_table.php 0000644 00000001257 15266556541 0015757 0 ustar 00 text('title')->nullable();
$table->string('file_path')->nullable();
$table->string('file_url')->nullable();
$table->string('file_type')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('introductions');
}
};
2025_08_05_151726_add_is_offer_column_to_coupons_table.php 0000644 00000001400 15266556541 0016777 0 ustar 00 boolean('is_offer')->default(false)->after('discount');
$table->boolean('is_offer_fixed_price')->default(false)->after('is_offer');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('coupons', function (Blueprint $table) {
$table->dropColumn('is_offer');
$table->dropColumn('is_offer_fixed_price');
});
}
};
2024_07_18_121143_add_stablediffusion_bedrock_model_to_settings_two_table.php 0000644 00000001173 15266556541 0022722 0 ustar 00 string('stablediffusion_bedrock_model')->default('stability.stable-diffusion-xl-v1');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('settings_two', function (Blueprint $table) {
//
});
}
};
2024_02_27_080913_add_reference_url_to_user_openai_chat.php 0000644 00000001270 15266556541 0017122 0 ustar 00 string('reference_url')->default('');
$table->string('doc_name')->default('');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('user_openai_chat', function (Blueprint $table) {
$table->dropColumn(['reference_url', 'doc_name']);
});
}
};
2023_05_15_133018_create_openai_chat_category_table.php 0000644 00000002057 15266556541 0016237 0 ustar 00 id();
$table->string('name')->nullable();
$table->string('short_name')->nullable();
$table->string('slug')->nullable();
$table->text('description')->nullable();
$table->string('role')->nullable();
$table->string('human_name')->nullable();
$table->string('helps_with')->nullable();
$table->string('prompt_prefix')->nullable();
$table->string('image')->nullable();
$table->string('color')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('openai_chat_category');
}
};
2024_07_25_100909_add_plan_footer_text_to_frontend_sections_statuses_titles.php 0000644 00000001165 15266556541 0023417 0 ustar 00 text('plan_footer_text')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('frontend_sections_statuses_titles', function (Blueprint $table) {
//
});
}
};
2024_12_03_145649_add_status_to_introductions_table.php 0000644 00000001144 15266556541 0016373 0 ustar 00 boolean('status')->default(true);
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('introductions', function (Blueprint $table) {
$table->dropColumn('status');
});
}
};
2024_01_30_135358_add_team_id_to_user_folders_table.php 0000644 00000001015 15266556541 0016231 0 ustar 00 bigInteger('team_id')->nullable()->after('id');
});
}
public function down(): void
{
Schema::table('folders', function (Blueprint $table) {
$table->dropColumn('team_id');
});
}
};