Ahora el Batch se pueden añadir tags
This commit is contained in:
@@ -6,7 +6,6 @@ import 'package:energy_media/models/media/media_models.dart';
|
||||
import 'package:energy_media/theme/theme.dart';
|
||||
import 'package:energy_media/helpers/globals.dart';
|
||||
import 'package:energy_media/widgets/premium_button.dart';
|
||||
import 'package:energy_media/pages/videos/widgets/premium_upload_dialog.dart';
|
||||
import 'package:energy_media/pages/videos/widgets/premium_batch_upload_dialog.dart';
|
||||
import 'package:energy_media/pages/videos/widgets/video_player_dialog.dart';
|
||||
import 'package:energy_media/pages/videos/widgets/gestor_videos_widgets/empty_state_widget.dart';
|
||||
@@ -132,7 +131,7 @@ class _GestorVideosPageState extends State<GestorVideosPage> {
|
||||
Expanded(
|
||||
child: provider.mediaFiles.isEmpty
|
||||
? EmptyStateWidget(
|
||||
onUploadPressed: () => _showUploadDialog(provider),
|
||||
onUploadPressed: () => _showBatchUploadDialog(provider),
|
||||
)
|
||||
: ListView.builder(
|
||||
padding: const EdgeInsets.all(16),
|
||||
@@ -177,7 +176,7 @@ class _GestorVideosPageState extends State<GestorVideosPage> {
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (isMobile) ...[
|
||||
// Vista móvil: solo botón centrado con diseño mejorado
|
||||
// Vista móvil: botón único para subir videos
|
||||
Center(
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
@@ -200,64 +199,6 @@ class _GestorVideosPageState extends State<GestorVideosPage> {
|
||||
),
|
||||
],
|
||||
),
|
||||
child: Material(
|
||||
color: Colors.transparent,
|
||||
child: InkWell(
|
||||
onTap: () => _showUploadDialog(provider),
|
||||
borderRadius: BorderRadius.circular(16),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: 24, vertical: 16),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const Icon(
|
||||
Icons.cloud_upload_rounded,
|
||||
color: Color(0xFF0B0B0D),
|
||||
size: 24,
|
||||
),
|
||||
const Gap(12),
|
||||
Text(
|
||||
'Subir Video',
|
||||
style: const TextStyle(
|
||||
color: Color(0xFF0B0B0D),
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w700,
|
||||
fontFamily: 'Poppins',
|
||||
letterSpacing: 0.5,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
const Gap(12),
|
||||
// Botón subida masiva móvil
|
||||
Center(
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
constraints: const BoxConstraints(maxWidth: 300),
|
||||
decoration: BoxDecoration(
|
||||
gradient: const LinearGradient(
|
||||
begin: Alignment.topLeft,
|
||||
end: Alignment.bottomRight,
|
||||
colors: [
|
||||
Color(0xFF6B2F8A),
|
||||
Color(0xFF4EC9F5),
|
||||
],
|
||||
),
|
||||
borderRadius: BorderRadius.circular(16),
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: const Color(0xFF6B2F8A).withOpacity(0.4),
|
||||
blurRadius: 12,
|
||||
offset: const Offset(0, 4),
|
||||
),
|
||||
],
|
||||
),
|
||||
child: Material(
|
||||
color: Colors.transparent,
|
||||
child: InkWell(
|
||||
@@ -270,15 +211,15 @@ class _GestorVideosPageState extends State<GestorVideosPage> {
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Icon(
|
||||
Icons.cloud_upload_outlined,
|
||||
color: Colors.white,
|
||||
Icons.cloud_upload_rounded,
|
||||
color: Color(0xFF0B0B0D),
|
||||
size: 24,
|
||||
),
|
||||
Gap(12),
|
||||
Text(
|
||||
'Subida Masiva',
|
||||
'Subir Videos',
|
||||
style: TextStyle(
|
||||
color: Colors.white,
|
||||
color: Color(0xFF0B0B0D),
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w700,
|
||||
fontFamily: 'Poppins',
|
||||
@@ -337,16 +278,9 @@ class _GestorVideosPageState extends State<GestorVideosPage> {
|
||||
),
|
||||
),
|
||||
PremiumButton(
|
||||
text: 'Subir Video',
|
||||
icon: Icons.cloud_upload,
|
||||
onPressed: () => _showUploadDialog(provider),
|
||||
),
|
||||
const Gap(12),
|
||||
PremiumButton(
|
||||
text: 'Subida Masiva',
|
||||
icon: Icons.cloud_upload_outlined,
|
||||
text: 'Subir Videos',
|
||||
icon: Icons.cloud_upload_rounded,
|
||||
onPressed: () => _showBatchUploadDialog(provider),
|
||||
backgroundColor: const Color(0xFF6B2F8A),
|
||||
),
|
||||
],
|
||||
),
|
||||
@@ -1325,19 +1259,6 @@ class _GestorVideosPageState extends State<GestorVideosPage> {
|
||||
);
|
||||
}
|
||||
|
||||
Future<void> _showUploadDialog(VideosProvider provider) async {
|
||||
await showDialog(
|
||||
context: context,
|
||||
barrierDismissible: false,
|
||||
builder: (context) => PremiumUploadDialog(
|
||||
provider: provider,
|
||||
onSuccess: () {
|
||||
_loadData();
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Future<void> _showBatchUploadDialog(VideosProvider provider) async {
|
||||
await showDialog(
|
||||
context: context,
|
||||
|
||||
Reference in New Issue
Block a user