diff --git a/app/Http/Controllers/RatingController.php b/app/Http/Controllers/RatingController.php
new file mode 100644
index 0000000..779961a
--- /dev/null
+++ b/app/Http/Controllers/RatingController.php
@@ -0,0 +1,19 @@
+rate = $request->rate;
+ $rating->comment = $request->comment;
+ $rating->save();
+ return ['code' => $rating->save() ? 200 : 500];
+ }
+}
diff --git a/app/Models/Rating.php b/app/Models/Rating.php
new file mode 100644
index 0000000..1bd5cf1
--- /dev/null
+++ b/app/Models/Rating.php
@@ -0,0 +1,19 @@
+id();
+ $table->integer('rate')->nullable();
+ $table->text('comment')->nullable();
+ $table->timestamps();
+ });
+ }
+
+ /**
+ * Reverse the migrations.
+ */
+ public function down(): void
+ {
+ Schema::dropIfExists('rating');
+ }
+};
diff --git a/resources/css/app.css b/resources/css/app.css
index e69de29..4846a2a 100644
--- a/resources/css/app.css
+++ b/resources/css/app.css
@@ -0,0 +1,10 @@
+.box-gradient {
+ border: 10px solid transparent;
+ background: linear-gradient(
+ #ffffff,
+ #ffffff) padding-box,
+ linear-gradient(45deg,
+ #FF52E5,
+ #F6D242) border-box;
+ border-radius: 14px;
+}
diff --git a/resources/views/Schedule.vue b/resources/views/Schedule.vue
index 2105671..a5d15af 100644
--- a/resources/views/Schedule.vue
+++ b/resources/views/Schedule.vue
@@ -3,37 +3,52 @@
Расписание стримов
{{ parseDate(dates[0].current_date) }} - {{ parseDate(dates[1].current_date) }}
-
+
Ссылочки
-
+
+
diff --git a/resources/views/Schedule/AdditionalButtons.vue b/resources/views/Schedule/AdditionalButtons.vue
new file mode 100644
index 0000000..0c132fc
--- /dev/null
+++ b/resources/views/Schedule/AdditionalButtons.vue
@@ -0,0 +1,101 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ Оцените канал:
+
+ sss
+
+ Оставьте отзыв:
+
+
+ Отправить
+
+
+
+
+
+
+
+
+ {{afterModalText}}
+
+
+
+
+
diff --git a/resources/views/Schedule/Links.vue b/resources/views/Schedule/Links.vue
index e36f97b..a9616e2 100644
--- a/resources/views/Schedule/Links.vue
+++ b/resources/views/Schedule/Links.vue
@@ -7,28 +7,16 @@
data: () => ({
links: ref(),
fetching: true,
- scheduleStore: useScheduleStore(),
- windowHeight: document.documentElement.clientHeight,
- windowWidth: document.documentElement.clientWidth,
- isWide: window.innerWidth >= 460
+ scheduleStore: useScheduleStore()
}),
+ props: {
+ isWide: Boolean
+ },
mounted() {
this.scheduleStore.getLinks().then(()=>{
this.links = this.scheduleStore.links;
this.fetching = false;
});
- this.myEventHandler();
- window.addEventListener("resize", this.myEventHandler, { passive: true });
- },
- created() {
- window.addEventListener("resize", this.myEventHandler);
- },
- methods: {
- myEventHandler(e) {
- this.windowHeight = document.documentElement.clientHeight;
- this.windowWidth = document.documentElement.clientWidth;
- this.isWide = this.windowWidth >= 460;
- }
}
}
@@ -48,20 +36,5 @@
diff --git a/resources/views/Schedule/ScheduleTable.vue b/resources/views/Schedule/ScheduleTable.vue
index 8799b09..d458a64 100644
--- a/resources/views/Schedule/ScheduleTable.vue
+++ b/resources/views/Schedule/ScheduleTable.vue
@@ -9,6 +9,9 @@
scheduleStore: useScheduleStore(),
fetching: true
}),
+ props: {
+ isWide: Boolean
+ },
methods: {
parseDate(date){
let dateArr = date.split("-");
@@ -27,7 +30,7 @@
-
+
{{ parseDate(schedule.current_date) }} {{ schedule.weekday_name }} {{ schedule.stream_time }} |
diff --git a/routes/api_v1.php b/routes/api_v1.php
index a55173a..c521186 100644
--- a/routes/api_v1.php
+++ b/routes/api_v1.php
@@ -19,3 +19,4 @@ Route::get('/links', 'App\Http\Controllers\LinksController@index')->name('links'
Route::get('/schedules', 'App\Http\Controllers\SchedulesController@index')->name('schedules');
Route::get('/dates', 'App\Http\Controllers\SchedulesController@mmDate')->name('dates');
Route::get('/phrases', 'App\Http\Controllers\BasyaPhrasesController@index')->name('phrases');
+Route::post('/rating', 'App\Http\Controllers\RatingController@index')->name('rating');