Skip to content

Commit

Permalink
Merge pull request #88 from frontChapter/develop
Browse files Browse the repository at this point in the history
add image
  • Loading branch information
lokiwich authored Feb 29, 2024
2 parents 6bf9aed + 9315ae9 commit ea14464
Show file tree
Hide file tree
Showing 8 changed files with 77 additions and 7 deletions.
13 changes: 13 additions & 0 deletions app/Livewire/Reserved.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

namespace App\Livewire;

use Livewire\Component;

class Reserved extends Component
{
public function render()
{
return view('livewire.reserved');
}
}
11 changes: 11 additions & 0 deletions app/Models/Gift.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class Gift extends Model
{
use HasFactory;
}
27 changes: 27 additions & 0 deletions database/migrations/2024_02_28_192212_create_gifts_table.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class () extends Migration {
/**
* Run the migrations.
*/
public function up(): void
{
Schema::create('gifts', function (Blueprint $table) {
$table->id();
$table->string('code');
$table->timestamps();
});
}

/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('gifts');
}
};
8 changes: 4 additions & 4 deletions resources/views/components/gift-card.blade.php
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<div class="flex items-center p-4 rounded {{ $bgColor }}">
<div>
<h3 class="text-xl font-semibold leading-tight text-secondary-800 dark:text-secondary-200">
<div class="flex flex-col gap-3 lg:flex-row items-center p-4 rounded {{ $bgColor }}">
<div class="w-full">
<h3 class="mb-1 text-xl font-semibold leading-tight text-secondary-800 dark:text-secondary-200">
{{ $title }}
</h3>
<p>{{ $description }}</p>
</div>

<div class="flex items-center gap-1 ms-auto">
<div class="flex items-center justify-between w-full gap-2 lg:justify-end ms-auto">
<p>
{{ __('Discount code') }}:
</p>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/layouts/profile.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
@endisset

<div class="container px-4 py-10 mx-auto sm:px-2 md:px-00">
<div class="grid grid-cols-12 gap-x-8">
<div class="grid grid-cols-12 gap-8">
<div class="col-span-12 md:col-span-4 lg:col-span-3">
<livewire:user.menu />
</div>
Expand Down
15 changes: 15 additions & 0 deletions resources/views/livewire/reserved.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<x-slot name="header">
<h2 class="text-lg font-semibold leading-tight sm:text-xl text-secondary-800 dark:text-secondary-200">
{{ __('تصاویر همایش ۱۴۰۲') }}
</h2>
</x-slot>

<div class="container mx-auto my-8 md:h-[45rem] max-h-full">
<x-card cardClasses="h-full" class="flex flex-col items-center justify-center gap-8">
<img class="mx-auto rounded-xl" src="{{ asset('images/happy-carrot.jpg') }}">
<div class="flex flex-col gap-2 text-center">
<h2 class="text-3xl font-bold">محل الصاق تصاویر امسال</h2>
<p class="">بزودی در این مکان تصاویر همایش ثبت می‌گردد</p>
</div>
</x-card>
</div>
4 changes: 2 additions & 2 deletions resources/views/livewire/user/menu.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
<x-profile-menu-link icon="heroicon-o-ticket" :title="__('Tickets')" :url="route('ticket')"
:isActive="request()->routeIs('ticket')" :badge="auth()->user()->tickets()->count()" />

{{-- <x-profile-menu-link icon="heroicon-o-gift" :title="__('Gifts')" :url="route('gift')"
:isActive="request()->routeIs('gift')" /> --}}
<x-profile-menu-link icon="heroicon-o-gift" :title="__('Gifts')" :url="route('gift')"
:isActive="request()->routeIs('gift')" />
</div>
</x-card>
</div>
4 changes: 4 additions & 0 deletions routes/web.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
use App\Livewire\Festival\SingleSite;
use App\Livewire\Home\ShowHome;
use App\Livewire\Profile\ShowProfile;
use App\Livewire\Reserved;
use App\Livewire\User\EditAdditionalData;
use App\Livewire\User\Gift\ListGifts;
use App\Livewire\User\Ticket\ListTickets;
Expand Down Expand Up @@ -49,6 +50,9 @@
Route::get('/conf1402', ShowHome::class)->name('conf1402')
->middleware('utm.store');

Route::get('/reserved', Reserved::class)->name('reserved')
->middleware('utm.store');

Route::middleware('auth')->group(function () {
Route::prefix('user')->group(function () {
Route::get('/tickets', ListTickets::class)->name('ticket')->middleware('verified');
Expand Down

0 comments on commit ea14464

Please sign in to comment.