@extends('mommy.layouts.contentLayoutMaster') @section('title','活動領取') @section('vendor-styles') @endsection @section('page-styles') @endsection @section('content') 搜尋 關鍵字 活動狀態 @if (!empty(config('activity.activity_status'))) @foreach (config('activity.activity_status') as $key => $value) input('activity_status') == (string)$key ? 'selected' : '' }} >{{ $value }} @endforeach @endif 開團時間 結團時間 年月搜尋 @php $now = \Carbon\Carbon::now(); $last_year = $now->copy()->subYears(1)->format('Y'); $now_year = $now->format('Y'); $next_year = $now->copy()->addYears(1)->format('Y'); @endphp input('publish_year') == (string)$last_year ? 'selected' : '' }} >{{ $last_year }} input('publish_year') == (string)$now_year ? 'selected' : '' }} >{{ $now_year }} input('publish_year') == (string)$next_year ? 'selected' : '' }} >{{ $next_year }} / @for ($month = 1; $month <= 12; $month++) input('publish_month') == (string)$month ? 'selected' : '' }}>{{ $month }} @endfor 列表 {{-- --}} 活動名稱 試吃時間 開團時間 結團時間 領取狀態 活動狀態 操作 @if ($activities->isNotEmpty()) @foreach ($activities as $activity) {{ $activity->name }} {{ $activity->try_out_at->format('Y-m-d H:i') }} {{ $activity->publish_start_at->format('Y-m-d H:i') }} {{ $activity->publish_end_at->format('Y-m-d H:i') }} @if (isset($matched[$activity->id])) 已領取 @else 未領取 @endif {{ config('activity.activity_status')[$activity->activity_status] }} {{-- 預覽 --}} 活動頁預覽 @if (in_array($activity->activity_status, config('activity.activity_status_options.can_match')) && !isset($matched[$activity->id])) {{-- 可領取 --}} 我要領取 @elseif (isset($matched[$activity->id])) {{-- 已領取,複製連結--}} {{-- --}} {{-- 我要領取--}} {{-- --}} {{-- --}} @endif @endforeach @else @include('mommy.panels.list-no-data') @endif @endsection @section('vendor-scripts') @endsection @section('page-scripts') @if ($activities->isNotEmpty()) @endif @endsection