Commit 586cff84703f64f52a9f6a67473165be935dc32a
1 parent
8c73c7b410
Exists in
master
and in
1 other branch
Модели и миграции! Аддон
Showing 35 changed files with 876 additions and 3 deletions Side-by-side Diff
- app/Models/SEO.php
- app/Models/ad_response.php
- app/Models/employers_main.php
- app/Models/header_footer.php
- app/Models/infobloks.php
- app/Models/job_titles_main.php
- app/Models/pages.php
- app/Models/place_works.php
- app/Models/reclame.php
- app/Models/sertification.php
- database/migrations/2023_05_16_081308_create_static_workers_table.php
- database/migrations/2023_05_16_081330_create_static_ads_table.php
- database/migrations/2023_09_01_115021_alter_users_table3.php
- database/migrations/2023_09_01_115802_alter_employers_table2.php
- database/migrations/2023_09_01_121152_alter_ad_employers_table.php
- database/migrations/2023_09_01_121950_alter_workers_table.php
- database/migrations/2023_09_01_122417_alter_categories_table.php
- database/migrations/2023_09_01_123056_alter_job_titles_table.php
- database/migrations/2023_09_01_123338_alter_group_works_table.php
- database/migrations/2023_09_01_123950_create_sertifications_table.php
- database/migrations/2023_09_01_131509_alter_static_workers_table.php
- database/migrations/2023_09_01_131903_alter_static_ads_table.php
- database/migrations/2023_09_01_132059_alter_companies_table.php
- database/migrations/2023_09_01_132618_create_ad_responses_table.php
- database/migrations/2023_09_01_134821_create_reclames_table.php
- database/migrations/2023_09_01_135450_create_header_footers_table.php
- database/migrations/2023_09_01_135606_create_infobloks_table.php
- database/migrations/2023_09_01_135734_create_dop_info_table.php
- database/migrations/2023_09_01_135910_create_job_titles_mains_table.php
- database/migrations/2023_09_01_135944_create_employers_mains_table.php
- database/migrations/2023_09_01_140100_create_place_works_table.php
- database/migrations/2023_09_01_140122_create_pages_table.php
- database/migrations/2023_09_04_123922_alter_job_titles2_table.php
- database/migrations/2023_09_04_124712_create_s_e_o_s_table.php
- resources/views/admin/index.blade.php
app/Models/SEO.php
app/Models/ad_response.php
app/Models/employers_main.php
app/Models/header_footer.php
app/Models/infobloks.php
app/Models/job_titles_main.php
app/Models/pages.php
app/Models/place_works.php
app/Models/reclame.php
app/Models/sertification.php
database/migrations/2023_05_16_081308_create_static_workers_table.php
... | ... | @@ -17,7 +17,6 @@ return new class extends Migration |
17 | 17 | $table->id(); |
18 | 18 | $table->bigInteger('user_id')->nullable(false); |
19 | 19 | $table->integer('lookin')->default(0); |
20 | - $table->string('month_year', 255)->nullable(); | |
21 | 20 | $table->integer('message')->default(0); |
22 | 21 | $table->timestamps(); |
23 | 22 | }); |
database/migrations/2023_05_16_081330_create_static_ads_table.php
... | ... | @@ -17,7 +17,6 @@ return new class extends Migration |
17 | 17 | $table->id(); |
18 | 18 | $table->bigInteger('ad_employer_id')->nullable(false); |
19 | 19 | $table->integer('lookin')->default(0); |
20 | - $table->string('month_year', 255)->nullable(); | |
21 | 20 | $table->integer('message')->default(0); |
22 | 21 | $table->timestamps(); |
23 | 22 | }); |
database/migrations/2023_09_01_115021_alter_users_table3.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('users', function (Blueprint $table) { | |
17 | + $table->timestamp('birthday')->nullable(); | |
18 | + $table->boolean('is_bd')->default(false); | |
19 | + }); | |
20 | + } | |
21 | + | |
22 | + /** | |
23 | + * Reverse the migrations. | |
24 | + * | |
25 | + * @return void | |
26 | + */ | |
27 | + public function down() | |
28 | + { | |
29 | + Schema::table('users', function (Blueprint $table) { | |
30 | + $table->dropColumn('birthday'); | |
31 | + $table->dropColumn('is_bd'); | |
32 | + }); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_115802_alter_employers_table2.php
... | ... | @@ -0,0 +1,42 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('employers', function (Blueprint $table) { | |
17 | + $table->string('coord', 255)->nullable(); | |
18 | + $table->boolean('is_remove')->default(false); | |
19 | + $table->boolean('status_hidden')->default(false); | |
20 | + $table->boolean('oficial_status')->default(false); | |
21 | + $table->boolean('social_is')->default(false); | |
22 | + $table->boolean('sending_is')->default(false); | |
23 | + }); | |
24 | + } | |
25 | + | |
26 | + /** | |
27 | + * Reverse the migrations. | |
28 | + * | |
29 | + * @return void | |
30 | + */ | |
31 | + public function down() | |
32 | + { | |
33 | + Schema::table('employers', function (Blueprint $table) { | |
34 | + $table->dropColumn('coord'); | |
35 | + $table->dropColumn('is_remove'); | |
36 | + $table->dropColumn('status_hidden'); | |
37 | + $table->dropColumn('oficial_status'); | |
38 | + $table->dropColumn('social_is'); | |
39 | + $table->dropColumn('sending_is'); | |
40 | + }); | |
41 | + } | |
42 | +}; |
database/migrations/2023_09_01_121152_alter_ad_employers_table.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('ad_employers', function (Blueprint $table) { | |
17 | + $table->boolean('is_remove')->default(false); | |
18 | + $table->boolean('active_is')->default(true); | |
19 | + }); | |
20 | + } | |
21 | + | |
22 | + /** | |
23 | + * Reverse the migrations. | |
24 | + * | |
25 | + * @return void | |
26 | + */ | |
27 | + public function down() | |
28 | + { | |
29 | + Schema::table('ad_employers', function (Blueprint $table) { | |
30 | + $table->dropColumn('is_remove'); | |
31 | + $table->dropColumn('active_is'); | |
32 | + }); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_121950_alter_workers_table.php
... | ... | @@ -0,0 +1,36 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('workers', function (Blueprint $table) { | |
17 | + $table->string('coord', 255)->nullable(); | |
18 | + $table->string('file', 255)->nullable(); | |
19 | + $table->boolean('is_remove')->default(false); | |
20 | + }); | |
21 | + } | |
22 | + | |
23 | + /** | |
24 | + * Reverse the migrations. | |
25 | + * | |
26 | + * @return void | |
27 | + */ | |
28 | + public function down() | |
29 | + { | |
30 | + Schema::table('workers', function (Blueprint $table) { | |
31 | + $table->dropColumn('coord'); | |
32 | + $table->dropColumn('file'); | |
33 | + $table->dropColumn('is_remove'); | |
34 | + }); | |
35 | + } | |
36 | +}; |
database/migrations/2023_09_01_122417_alter_categories_table.php
... | ... | @@ -0,0 +1,32 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('categories', function (Blueprint $table) { | |
17 | + $table->boolean('is_remove')->default(false); | |
18 | + }); | |
19 | + } | |
20 | + | |
21 | + /** | |
22 | + * Reverse the migrations. | |
23 | + * | |
24 | + * @return void | |
25 | + */ | |
26 | + public function down() | |
27 | + { | |
28 | + Schema::table('categories', function (Blueprint $table) { | |
29 | + $table->dropColumn('is_remove'); | |
30 | + }); | |
31 | + } | |
32 | +}; |
database/migrations/2023_09_01_123056_alter_job_titles_table.php
... | ... | @@ -0,0 +1,32 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('job_titles', function (Blueprint $table) { | |
17 | + $table->boolean('is_remove')->default(false); | |
18 | + }); | |
19 | + } | |
20 | + | |
21 | + /** | |
22 | + * Reverse the migrations. | |
23 | + * | |
24 | + * @return void | |
25 | + */ | |
26 | + public function down() | |
27 | + { | |
28 | + Schema::table('job_titles', function (Blueprint $table) { | |
29 | + $table->dropColumn('is_remove'); | |
30 | + }); | |
31 | + } | |
32 | +}; |
database/migrations/2023_09_01_123338_alter_group_works_table.php
... | ... | @@ -0,0 +1,32 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('group_works', function (Blueprint $table) { | |
17 | + $table->boolean('is_remove')->default(false); | |
18 | + }); | |
19 | + } | |
20 | + | |
21 | + /** | |
22 | + * Reverse the migrations. | |
23 | + * | |
24 | + * @return void | |
25 | + */ | |
26 | + public function down() | |
27 | + { | |
28 | + Schema::table('group_works', function (Blueprint $table) { | |
29 | + $table->dropColumn('is_remove'); | |
30 | + }); | |
31 | + } | |
32 | +}; |
database/migrations/2023_09_01_123950_create_sertifications_table.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('sertifications', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->timestamp('date_begin')->nullable(); | |
19 | + $table->timestamp('end_begin')->nullable(); | |
20 | + $table->bigInteger('worker_id')->nullable(false); | |
21 | + $table->timestamps(); | |
22 | + }); | |
23 | + } | |
24 | + | |
25 | + /** | |
26 | + * Reverse the migrations. | |
27 | + * | |
28 | + * @return void | |
29 | + */ | |
30 | + public function down() | |
31 | + { | |
32 | + Schema::dropIfExists('sertifications'); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_131509_alter_static_workers_table.php
... | ... | @@ -0,0 +1,32 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('static_workers', function (Blueprint $table) { | |
17 | + $table->string('year_month', 255)->nullable(); | |
18 | + }); | |
19 | + } | |
20 | + | |
21 | + /** | |
22 | + * Reverse the migrations. | |
23 | + * | |
24 | + * @return void | |
25 | + */ | |
26 | + public function down() | |
27 | + { | |
28 | + Schema::table('static_workers', function (Blueprint $table) { | |
29 | + $table->dropColumn('year_month'); | |
30 | + }); | |
31 | + } | |
32 | +}; |
database/migrations/2023_09_01_131903_alter_static_ads_table.php
... | ... | @@ -0,0 +1,32 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('static_ads', function (Blueprint $table) { | |
17 | + $table->string('year_month', 255)->nullable(); | |
18 | + }); | |
19 | + } | |
20 | + | |
21 | + /** | |
22 | + * Reverse the migrations. | |
23 | + * | |
24 | + * @return void | |
25 | + */ | |
26 | + public function down() | |
27 | + { | |
28 | + Schema::table('static_ads', function (Blueprint $table) { | |
29 | + $table->dropColumn('year_month'); | |
30 | + }); | |
31 | + } | |
32 | +}; |
database/migrations/2023_09_01_132059_alter_companies_table.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('companies', function (Blueprint $table) { | |
17 | + $table->integer('time_mess')->default(5); | |
18 | + $table->integer('time_resume')->default(30); | |
19 | + }); | |
20 | + } | |
21 | + | |
22 | + /** | |
23 | + * Reverse the migrations. | |
24 | + * | |
25 | + * @return void | |
26 | + */ | |
27 | + public function down() | |
28 | + { | |
29 | + Schema::table('companies', function (Blueprint $table) { | |
30 | + $table->dropColumn('time_mess'); | |
31 | + $table->dropColumn('time_resume'); | |
32 | + }); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_132618_create_ad_responses_table.php
... | ... | @@ -0,0 +1,35 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('ad_responses', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->bigInteger('message_id')->nullable(false); | |
19 | + $table->bigInteger('ad_employer_id')->nullable(false); | |
20 | + $table->bigInteger('job_title_id')->nullable(false); | |
21 | + $table->boolean('flag')->default(true); | |
22 | + $table->timestamps(); | |
23 | + }); | |
24 | + } | |
25 | + | |
26 | + /** | |
27 | + * Reverse the migrations. | |
28 | + * | |
29 | + * @return void | |
30 | + */ | |
31 | + public function down() | |
32 | + { | |
33 | + Schema::dropIfExists('ad_responses'); | |
34 | + } | |
35 | +}; |
database/migrations/2023_09_01_134821_create_reclames_table.php
... | ... | @@ -0,0 +1,39 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('reclames', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('title', 255)->nullable(); | |
19 | + $table->string('image', 255)->nullable(); | |
20 | + $table->string('link', 255)->nullable(); | |
21 | + $table->text('text')->nullable(); | |
22 | + $table->integer('position')->default(0); | |
23 | + $table->boolean('is_hidden')->default(false); | |
24 | + $table->integer('col_vo_click')->default(0); | |
25 | + $table->boolean('is_remove')->default(false); | |
26 | + $table->timestamps(); | |
27 | + }); | |
28 | + } | |
29 | + | |
30 | + /** | |
31 | + * Reverse the migrations. | |
32 | + * | |
33 | + * @return void | |
34 | + */ | |
35 | + public function down() | |
36 | + { | |
37 | + Schema::dropIfExists('reclames'); | |
38 | + } | |
39 | +}; |
database/migrations/2023_09_01_135450_create_header_footers_table.php
... | ... | @@ -0,0 +1,37 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('header_footers', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('name', 255)->nullable(); | |
19 | + $table->string('link', 255)->nullable(); | |
20 | + $table->bigInteger('code_id')->nullable(false); | |
21 | + $table->string('category', 255)->nullable(); | |
22 | + $table->boolean('header')->default(true); | |
23 | + $table->integer('sort')->default(100); | |
24 | + $table->timestamps(); | |
25 | + }); | |
26 | + } | |
27 | + | |
28 | + /** | |
29 | + * Reverse the migrations. | |
30 | + * | |
31 | + * @return void | |
32 | + */ | |
33 | + public function down() | |
34 | + { | |
35 | + Schema::dropIfExists('header_footers'); | |
36 | + } | |
37 | +}; |
database/migrations/2023_09_01_135606_create_infobloks_table.php
... | ... | @@ -0,0 +1,33 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('infobloks', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('name', 255)->nullable(); | |
19 | + $table->boolean('is_remove')->default(false); | |
20 | + $table->timestamps(); | |
21 | + }); | |
22 | + } | |
23 | + | |
24 | + /** | |
25 | + * Reverse the migrations. | |
26 | + * | |
27 | + * @return void | |
28 | + */ | |
29 | + public function down() | |
30 | + { | |
31 | + Schema::dropIfExists('infobloks'); | |
32 | + } | |
33 | +}; |
database/migrations/2023_09_01_135734_create_dop_info_table.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('dop_info', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->bigInteger('worker_id')->nullable(false); | |
19 | + $table->bigInteger('infoblok_id')->nullable(false); | |
20 | + $table->text('text')->nullable(); | |
21 | + $table->timestamps(); | |
22 | + }); | |
23 | + } | |
24 | + | |
25 | + /** | |
26 | + * Reverse the migrations. | |
27 | + * | |
28 | + * @return void | |
29 | + */ | |
30 | + public function down() | |
31 | + { | |
32 | + Schema::dropIfExists('dop_info'); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_135910_create_job_titles_mains_table.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('job_titles_mains', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('name', 255)->nullable(); | |
19 | + $table->bigInteger('job_title_id')->nullable(false); | |
20 | + $table->integer('sort')->default(100); | |
21 | + $table->timestamps(); | |
22 | + }); | |
23 | + } | |
24 | + | |
25 | + /** | |
26 | + * Reverse the migrations. | |
27 | + * | |
28 | + * @return void | |
29 | + */ | |
30 | + public function down() | |
31 | + { | |
32 | + Schema::dropIfExists('job_titles_mains'); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_135944_create_employers_mains_table.php
... | ... | @@ -0,0 +1,34 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('employers_mains', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('name', 255)->nullable(); | |
19 | + $table->bigInteger('employer_id')->nullable(false); | |
20 | + $table->integer('sort')->default(100); | |
21 | + $table->timestamps(); | |
22 | + }); | |
23 | + } | |
24 | + | |
25 | + /** | |
26 | + * Reverse the migrations. | |
27 | + * | |
28 | + * @return void | |
29 | + */ | |
30 | + public function down() | |
31 | + { | |
32 | + Schema::dropIfExists('employers_mains'); | |
33 | + } | |
34 | +}; |
database/migrations/2023_09_01_140100_create_place_works_table.php
... | ... | @@ -0,0 +1,40 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('place_works', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('job_title', 255)->nullable(); | |
19 | + $table->boolean('tanker')->default(false); | |
20 | + $table->string('teplohod', 255)->nullable(); | |
21 | + $table->string('GWT', 255)->nullable(); | |
22 | + $table->string('KBT', 255)->nullable(); | |
23 | + $table->string('begin_work', 255)->nullable(); | |
24 | + $table->string('end_work', 255)->nullable(); | |
25 | + $table->string('name_company')->nullable(); | |
26 | + $table->bigInteger('worker_id')->nullable(false); | |
27 | + $table->timestamps(); | |
28 | + }); | |
29 | + } | |
30 | + | |
31 | + /** | |
32 | + * Reverse the migrations. | |
33 | + * | |
34 | + * @return void | |
35 | + */ | |
36 | + public function down() | |
37 | + { | |
38 | + Schema::dropIfExists('place_works'); | |
39 | + } | |
40 | +}; |
database/migrations/2023_09_01_140122_create_pages_table.php
... | ... | @@ -0,0 +1,37 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('pages', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('name', 255)->nullable(); | |
19 | + $table->string('slug', 255)->nullable(false); | |
20 | + $table->text('text')->nullable(); | |
21 | + $table->text('anons')->nullable(); | |
22 | + $table->string('author', 255)->nullable(); | |
23 | + $table->string('image', 255)->nullable(); | |
24 | + $table->timestamps(); | |
25 | + }); | |
26 | + } | |
27 | + | |
28 | + /** | |
29 | + * Reverse the migrations. | |
30 | + * | |
31 | + * @return void | |
32 | + */ | |
33 | + public function down() | |
34 | + { | |
35 | + Schema::dropIfExists('pages'); | |
36 | + } | |
37 | +}; |
database/migrations/2023_09_04_123922_alter_job_titles2_table.php
... | ... | @@ -0,0 +1,32 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::table('job_titles', function (Blueprint $table) { | |
17 | + $table->integer('parent_id')->default(0); | |
18 | + }); | |
19 | + } | |
20 | + | |
21 | + /** | |
22 | + * Reverse the migrations. | |
23 | + * | |
24 | + * @return void | |
25 | + */ | |
26 | + public function down() | |
27 | + { | |
28 | + Schema::table('job_titles', function (Blueprint $table) { | |
29 | + $table->dropColumn('parent_id'); | |
30 | + }); | |
31 | + } | |
32 | +}; |
database/migrations/2023_09_04_124712_create_s_e_o_s_table.php
... | ... | @@ -0,0 +1,36 @@ |
1 | +<?php | |
2 | + | |
3 | +use Illuminate\Database\Migrations\Migration; | |
4 | +use Illuminate\Database\Schema\Blueprint; | |
5 | +use Illuminate\Support\Facades\Schema; | |
6 | + | |
7 | +return new class extends Migration | |
8 | +{ | |
9 | + /** | |
10 | + * Run the migrations. | |
11 | + * | |
12 | + * @return void | |
13 | + */ | |
14 | + public function up() | |
15 | + { | |
16 | + Schema::create('s_e_o_s', function (Blueprint $table) { | |
17 | + $table->id(); | |
18 | + $table->string('url', 255)->nullable(false); | |
19 | + $table->string('title', 255)->nullable(); | |
20 | + $table->text('description')->nullable(); | |
21 | + $table->text('keywords')->nullable(); | |
22 | + $table->string('name', 255)->nullable(); | |
23 | + $table->timestamps(); | |
24 | + }); | |
25 | + } | |
26 | + | |
27 | + /** | |
28 | + * Reverse the migrations. | |
29 | + * | |
30 | + * @return void | |
31 | + */ | |
32 | + public function down() | |
33 | + { | |
34 | + Schema::dropIfExists('s_e_o_s'); | |
35 | + } | |
36 | +}; |
resources/views/admin/index.blade.php
... | ... | @@ -214,7 +214,7 @@ |
214 | 214 | <div class="absolute inset-0 rounded-full shadow-inner" aria-hidden="true"></div> |
215 | 215 | </div> |
216 | 216 | <div> |
217 | - <p class="font-semibold"><a href="{{ route('admin.categories') }}">Категории</a></p> | |
217 | + <p class="font-semibold"><a href="{{ route('admin.categories.index') }}">Категории</a></p> | |
218 | 218 | <p class="text-xs text-gray-600 dark:text-gray-400"> |
219 | 219 | Справочник категории (по умолчанию: река, море, река-море) |
220 | 220 | </p> |