You've already forked Atomcms-edit
5476dce882
- New 5-step RadioWizardController with session-based wizard flow - Enhanced RadioStreamService with Shoutcast/Icecast/ AzureCast auto-detection - Connection test functionality for stream, now-playing, and listeners - Wizard views for all 5 steps with step indicator navigation - All 21 language files updated with wizard translation keys (NL/EN + placeholders) - Wizard link added to existing radio setup page - Routes registered under /admin/radio/wizard/*
370 lines
12 KiB
PHP
Executable File
370 lines
12 KiB
PHP
Executable File
@extends('layouts.app')
|
|
|
|
@section('title', __('radio.setup_page_title') . ' - ' . config('app.name'))
|
|
|
|
@push('styles')
|
|
<style>
|
|
.setup-container {
|
|
max-width: 1200px;
|
|
margin: 0 auto;
|
|
padding: 2rem;
|
|
}
|
|
|
|
.setup-card {
|
|
background: white;
|
|
border-radius: 12px;
|
|
padding: 2rem;
|
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
|
margin-bottom: 2rem;
|
|
}
|
|
|
|
.setup-header {
|
|
text-align: center;
|
|
margin-bottom: 3rem;
|
|
}
|
|
|
|
.setup-title {
|
|
font-size: 2.5rem;
|
|
font-weight: 800;
|
|
color: #1a202c;
|
|
margin-bottom: 1rem;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
gap: 1rem;
|
|
}
|
|
|
|
.setup-subtitle {
|
|
font-size: 1.125rem;
|
|
color: #4a5568;
|
|
max-width: 600px;
|
|
margin: 0 auto;
|
|
}
|
|
|
|
.feature-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
|
|
gap: 2rem;
|
|
margin-bottom: 3rem;
|
|
}
|
|
|
|
.feature-card {
|
|
background: #f7fafc;
|
|
border-radius: 8px;
|
|
padding: 1.5rem;
|
|
border-left: 4px solid #eeb425;
|
|
}
|
|
|
|
.feature-icon {
|
|
width: 48px;
|
|
height: 48px;
|
|
background: #eeb425;
|
|
border-radius: 12px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
margin-bottom: 1rem;
|
|
font-size: 1.5rem;
|
|
}
|
|
|
|
.feature-title {
|
|
font-size: 1.25rem;
|
|
font-weight: 700;
|
|
color: #2d3748;
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
.feature-description {
|
|
color: #4a5568;
|
|
line-height: 1.6;
|
|
}
|
|
|
|
.action-buttons {
|
|
display: flex;
|
|
justify-content: center;
|
|
gap: 1rem;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.btn-primary {
|
|
background: linear-gradient(135deg, #eeb425, #d4a52a);
|
|
color: #1a202c;
|
|
padding: 1rem 2rem;
|
|
border: none;
|
|
border-radius: 8px;
|
|
font-weight: 700;
|
|
font-size: 1.125rem;
|
|
cursor: pointer;
|
|
transition: all 0.3s ease;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 0.5rem;
|
|
box-shadow: 0 4px 12px rgba(238, 180, 37, 0.3);
|
|
}
|
|
|
|
.btn-primary:hover {
|
|
transform: translateY(-2px);
|
|
box-shadow: 0 8px 24px rgba(238, 180, 37, 0.4);
|
|
}
|
|
|
|
.btn-secondary {
|
|
background: #e2e8f0;
|
|
color: #4a5568;
|
|
padding: 1rem 2rem;
|
|
border: none;
|
|
border-radius: 8px;
|
|
font-weight: 600;
|
|
font-size: 1rem;
|
|
cursor: pointer;
|
|
transition: all 0.3s ease;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 0.5rem;
|
|
}
|
|
|
|
.btn-secondary:hover {
|
|
background: #cbd5e0;
|
|
transform: translateY(-1px);
|
|
}
|
|
|
|
.status-check {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 1rem;
|
|
padding: 1rem;
|
|
background: #f0fff4;
|
|
border-radius: 8px;
|
|
margin-bottom: 2rem;
|
|
}
|
|
|
|
.status-check.missing {
|
|
background: #fff5f5;
|
|
}
|
|
|
|
.status-icon {
|
|
width: 24px;
|
|
height: 24px;
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-weight: bold;
|
|
color: white;
|
|
}
|
|
|
|
.status-icon.configured {
|
|
background: #38a169;
|
|
}
|
|
|
|
.status-icon.missing {
|
|
background: #e53e3e;
|
|
}
|
|
|
|
.settings-preview {
|
|
background: #edf2f7;
|
|
border-radius: 8px;
|
|
padding: 1.5rem;
|
|
margin-bottom: 2rem;
|
|
}
|
|
|
|
.settings-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
|
|
gap: 1rem;
|
|
}
|
|
|
|
.setting-item {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.5rem;
|
|
padding: 0.5rem;
|
|
background: white;
|
|
border-radius: 4px;
|
|
font-size: 0.875rem;
|
|
}
|
|
|
|
.setting-value {
|
|
font-weight: 600;
|
|
color: #eeb425;
|
|
}
|
|
|
|
@media (max-width: 768px) {
|
|
.setup-container {
|
|
padding: 1rem;
|
|
}
|
|
|
|
.setup-card {
|
|
padding: 1.5rem;
|
|
}
|
|
|
|
.setup-title {
|
|
font-size: 2rem;
|
|
}
|
|
|
|
.feature-grid {
|
|
grid-template-columns: 1fr;
|
|
gap: 1rem;
|
|
}
|
|
}
|
|
</style>
|
|
@endpush
|
|
|
|
@section('content')
|
|
<div class="setup-container">
|
|
<!-- Header -->
|
|
<div class="setup-header">
|
|
<h1 class="setup-title">
|
|
<span>🎵</span>
|
|
{{ __('radio.setup_page_title') }}
|
|
<span>🚀</span>
|
|
</h1>
|
|
<p class="setup-subtitle">
|
|
{{ __('radio.setup_page_subtitle') }}
|
|
</p>
|
|
</div>
|
|
|
|
@if(session('success'))
|
|
<div class="status-check configured">
|
|
<div class="status-icon configured">✓</div>
|
|
<div>
|
|
<strong>{{ __('radio.setup_complete') }}</strong><br>
|
|
{{ session('success') }}
|
|
</div>
|
|
</div>
|
|
@endif
|
|
|
|
<!-- Features Overview -->
|
|
<div class="setup-card">
|
|
<h2 class="text-2xl font-bold mb-6 text-center">{{ __('radio.what_gets_configured') }}</h2>
|
|
|
|
<div class="feature-grid">
|
|
<div class="feature-card">
|
|
<div class="feature-icon">📻</div>
|
|
<h3 class="feature-title">{{ __('radio.radio_stream') }}</h3>
|
|
<p class="feature-description">
|
|
{{ __('radio.radio_stream_desc') }}
|
|
</p>
|
|
</div>
|
|
|
|
<div class="feature-card">
|
|
<div class="feature-icon">🏆</div>
|
|
<h3 class="feature-title">{{ __('radio.points_system') }}</h3>
|
|
<p class="feature-description">
|
|
{{ __('radio.points_system_desc') }}
|
|
</p>
|
|
</div>
|
|
|
|
<div class="feature-card">
|
|
<div class="feature-icon">💬</div>
|
|
<h3 class="feature-title">{{ __('radio.community_features') }}</h3>
|
|
<p class="feature-description">
|
|
{{ __('radio.community_features_desc') }}
|
|
</p>
|
|
</div>
|
|
|
|
<div class="feature-card">
|
|
<div class="feature-icon">👨🎤</div>
|
|
<h3 class="feature-title">{{ __('radio.dj_management') }}</h3>
|
|
<p class="feature-description">
|
|
{{ __('radio.dj_management_desc') }}
|
|
</p>
|
|
</div>
|
|
|
|
<div class="feature-card">
|
|
<div class="feature-icon">📊</div>
|
|
<h3 class="feature-title">{{ __('radio.monitoring') }}</h3>
|
|
<p class="feature-description">
|
|
{{ __('radio.monitoring_desc') }}
|
|
</p>
|
|
</div>
|
|
|
|
<div class="feature-card">
|
|
<div class="feature-icon">🎨</div>
|
|
<h3 class="feature-title">{{ __('radio.display_options') }}</h3>
|
|
<p class="feature-description">
|
|
{{ __('radio.display_options_desc') }}
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Settings Preview -->
|
|
<div class="setup-card">
|
|
<h2 class="text-2xl font-bold mb-6 text-center">{{ __('radio.default_settings') }}</h2>
|
|
|
|
<div class="settings-preview">
|
|
<div class="settings-grid">
|
|
<div class="setting-item">
|
|
<span>📻</span>
|
|
<span>{{ __('radio.radio_label') }}</span>
|
|
<span class="setting-value">{{ __('radio.enabled') }}</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>🏆</span>
|
|
<span>{{ __('radio.points_label') }}</span>
|
|
<span class="setting-value">2{{ __('radio.per_min') }}</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>📊</span>
|
|
<span>{{ __('radio.daily_limit') }}</span>
|
|
<span class="setting-value">100</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>💬</span>
|
|
<span>{{ __('radio.shouts_label') }}</span>
|
|
<span class="setting-value">{{ __('radio.on') }}</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>📻</span>
|
|
<span>{{ __('radio.widget') }}</span>
|
|
<span class="setting-value">{{ __('radio.global') }}</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>👨🎤</span>
|
|
<span>{{ __('radio.dj_apps') }}</span>
|
|
<span class="setting-value">{{ __('radio.open') }}</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>📊</span>
|
|
<span>{{ __('radio.monitoring_label') }}</span>
|
|
<span class="setting-value">{{ __('radio.on') }}</span>
|
|
</div>
|
|
<div class="setting-item">
|
|
<span>🎯</span>
|
|
<span>{{ __('radio.contests_label') }}</span>
|
|
<span class="setting-value">{{ __('radio.on') }}</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Action Buttons -->
|
|
<div class="action-buttons">
|
|
<form action="{{ route('admin.radio.setup.do') }}" method="POST">
|
|
@csrf
|
|
<button type="submit" class="btn-primary">
|
|
<span>🚀</span>
|
|
{{ __('radio.install_radio_system') }}
|
|
</button>
|
|
</form>
|
|
|
|
<form action="{{ route('admin.radio.setup.reset') }}" method="POST">
|
|
@csrf
|
|
<button type="submit" class="btn-secondary" onclick="return confirm('{{ __('radio.reset_confirm') }}')">
|
|
<span>🔄</span>
|
|
{{ __('radio.reset_settings') }}
|
|
</button>
|
|
</form>
|
|
|
|
<a href="{{ route('admin.radio.wizard') }}" class="btn-primary" style="text-decoration: none;">
|
|
<span>🎯</span>
|
|
{{ __('radio.open_wizard') }}
|
|
</a>
|
|
|
|
<a href="/housekeeping/radio-settings" class="btn-secondary">
|
|
<span>⚙️</span>
|
|
{{ __('radio.go_to_radio_settings') }}
|
|
</a>
|
|
</div>
|
|
</div>
|
|
@endsection |