You've already forked lubo_comment_query
119 lines
9.9 KiB
PHP
119 lines
9.9 KiB
PHP
<html lang="zh">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>关联视频修改 - 录播查询</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
<link href="{{ mix('/css/app.css') }}" rel="stylesheet"/>
|
|
</head>
|
|
<body class="bg-gray-50 dark:bg-gray-900 min-h-screen flex flex-col text-gray-900 dark:text-gray-100">
|
|
@include("common.header")
|
|
|
|
<main class="flex-grow container mx-auto px-4 sm:px-6 lg:px-8 py-8">
|
|
<div class="max-w-3xl mx-auto">
|
|
<div class="md:flex md:items-center md:justify-between mb-8">
|
|
<h1 class="text-2xl font-bold text-gray-900 dark:text-white">
|
|
关联视频修改
|
|
</h1>
|
|
<a href="{{ route("program.construct.video.list", ["program" => $program_video->program_id]) }}" class="mt-4 md:mt-0 inline-flex items-center text-sm text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200">
|
|
<svg class="h-4 w-4 mr-1" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M10 19l-7-7m0 0l7-7m-7 7h18"></path></svg>
|
|
返回列表
|
|
</a>
|
|
</div>
|
|
|
|
<div class="bg-white dark:bg-gray-800 shadow rounded-lg overflow-hidden">
|
|
<form class="p-6 space-y-6" action="" method="post" enctype="multipart/form-data">
|
|
@csrf
|
|
<input type="hidden" name="id" value="{{$program_video->id}}">
|
|
|
|
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
|
|
<div class="col-span-1 md:col-span-2">
|
|
<label for="video_bvid" class="block text-sm font-medium text-gray-700 dark:text-gray-300">BVID</label>
|
|
<div class="mt-1 flex rounded-md shadow-sm">
|
|
<input type="text" name="video_bvid" id="video_bvid" @if($program_video->video_bvid) disabled @endif value="{{ old("video_bvid", $program_video->video_bvid) }}"
|
|
class="flex-1 min-w-0 block w-full px-3 py-2 rounded-md border-gray-300 dark:border-gray-600 dark:bg-gray-700 dark:text-white focus:ring-indigo-500 focus:border-indigo-500 sm:text-sm">
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Start Section -->
|
|
<div class="col-span-1 space-y-4 p-4 bg-gray-50 dark:bg-gray-700/30 rounded-lg border border-gray-200 dark:border-gray-600">
|
|
<h3 class="text-sm font-semibold text-gray-900 dark:text-white uppercase tracking-wider">开始节点</h3>
|
|
<div>
|
|
<label for="start_part" class="block text-sm font-medium text-gray-700 dark:text-gray-300">P数</label>
|
|
<input type="number" name="start_part" id="start_part" value="{{ old("start_part", $program_video->start_part) }}"
|
|
class="mt-1 block w-full rounded-md border-gray-300 dark:border-gray-600 dark:bg-gray-700 shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm py-2">
|
|
</div>
|
|
<div>
|
|
<label for="start_time" class="block text-sm font-medium text-gray-700 dark:text-gray-300">时间点</label>
|
|
<input type="time" step="1" name="start_time" id="start_time" value="{{ old("start_time", $program_video->start_time) }}"
|
|
class="mt-1 block w-full rounded-md border-gray-300 dark:border-gray-600 dark:bg-gray-700 shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm py-2">
|
|
</div>
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300">预览图</label>
|
|
@if($program_video->start_image)
|
|
<img src="{{$program_video->start_image}}" alt="Start" class="mt-2 h-32 w-full object-cover rounded-md border border-gray-300 dark:border-gray-600">
|
|
@endif
|
|
<input type="file" name="start_image" class="mt-2 block w-full text-sm text-gray-500 file:mr-4 file:py-2 file:px-4 file:rounded-full file:border-0 file:text-sm file:font-semibold file:bg-indigo-50 file:text-indigo-700 hover:file:bg-indigo-100 dark:file:bg-indigo-900 dark:file:text-indigo-300">
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Stop Section -->
|
|
<div class="col-span-1 space-y-4 p-4 bg-gray-50 dark:bg-gray-700/30 rounded-lg border border-gray-200 dark:border-gray-600">
|
|
<h3 class="text-sm font-semibold text-gray-900 dark:text-white uppercase tracking-wider">结束节点</h3>
|
|
<div>
|
|
<label for="stop_part" class="block text-sm font-medium text-gray-700 dark:text-gray-300">P数</label>
|
|
<input type="number" name="stop_part" id="stop_part" value="{{ old("stop_part", $program_video->stop_part) }}"
|
|
class="mt-1 block w-full rounded-md border-gray-300 dark:border-gray-600 dark:bg-gray-700 shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm py-2">
|
|
</div>
|
|
<div>
|
|
<label for="stop_time" class="block text-sm font-medium text-gray-700 dark:text-gray-300">时间点</label>
|
|
<input type="time" step="1" name="stop_time" id="stop_time" value="{{ old("stop_time", $program_video->stop_time) }}"
|
|
class="mt-1 block w-full rounded-md border-gray-300 dark:border-gray-600 dark:bg-gray-700 shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm py-2">
|
|
</div>
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300">预览图</label>
|
|
@if($program_video->stop_image)
|
|
<img src="{{$program_video->stop_image}}" alt="Stop" class="mt-2 h-32 w-full object-cover rounded-md border border-gray-300 dark:border-gray-600">
|
|
@endif
|
|
<input type="file" name="stop_image" class="mt-2 block w-full text-sm text-gray-500 file:mr-4 file:py-2 file:px-4 file:rounded-full file:border-0 file:text-sm file:font-semibold file:bg-indigo-50 file:text-indigo-700 hover:file:bg-indigo-100 dark:file:bg-indigo-900 dark:file:text-indigo-300">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
@include("common.form_error")
|
|
|
|
<div class="flex items-center justify-end pt-4 border-t border-gray-200 dark:border-gray-700">
|
|
<button type="submit" class="inline-flex justify-center py-2 px-6 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500">
|
|
保存修改
|
|
</button>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
@if($program_video->video)
|
|
<div class="mt-6 flex flex-wrap gap-4 justify-center md:justify-start">
|
|
<a class="inline-flex items-center px-4 py-2 border border-gray-300 dark:border-gray-600 shadow-sm text-sm font-medium rounded-md text-gray-700 dark:text-gray-200 bg-white dark:bg-gray-800 hover:bg-gray-50 dark:hover:bg-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
|
|
target="_blank"
|
|
href="https://www.bilibili.com/video/{{$program_video->video_bvid}}?p={{$program_video->start_part}}&t={{$program_video->start_sec}}">
|
|
<svg class="h-4 w-4 mr-2" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14.752 11.168l-3.197-2.132A1 1 0 0010 9.87v4.263a1 1 0 001.555.832l3.197-2.132a1 1 0 000-1.664z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>
|
|
预览开始位置
|
|
</a>
|
|
<a class="inline-flex items-center px-4 py-2 border border-gray-300 dark:border-gray-600 shadow-sm text-sm font-medium rounded-md text-gray-700 dark:text-gray-200 bg-white dark:bg-gray-800 hover:bg-gray-50 dark:hover:bg-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
|
|
target="_blank"
|
|
href="https://www.bilibili.com/video/{{$program_video->video_bvid}}?p={{$program_video->stop_part}}&t={{$program_video->stop_sec}}">
|
|
<svg class="h-4 w-4 mr-2" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 10a1 1 0 011-1h4a1 1 0 011 1v4a1 1 0 01-1 1h-4a1 1 0 01-1-1v-4z"></path></svg>
|
|
预览结束位置
|
|
</a>
|
|
@if($program_video->video->parts()->count() > 0)
|
|
<a class="inline-flex items-center px-4 py-2 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-green-600 hover:bg-green-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-green-500"
|
|
href="{{ url(route("program.construct.video.auto_fix_created_at", ["bvid" => $program_video->video_bvid])) }}">
|
|
<svg class="h-4 w-4 mr-2" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>
|
|
自动修复时间
|
|
</a>
|
|
@endif
|
|
</div>
|
|
@endif
|
|
</div>
|
|
</main>
|
|
@include("common.footer")
|
|
</body>
|
|
</html> |