Files
hanjie_backend/sql/teaching_video_20260331.sql
trezeman 2b8d5cc126 1.设置设备查看权限(每个公司只能查看自己购买的设备,未完善)
2.添加设备信息模块,可以选择设备查看详情(未添加实时数据部分)
3.添加教学视频模块,拉取b站系列中的视频
4.初步调整ui
2026-03-31 17:46:40 +08:00

48 lines
4.4 KiB
SQL
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
-- ----------------------------
-- 教学视频表按产品原型分类Tab + 列表卡片)
-- Tab: 全部视频 / 基础教学 / 常见问题 / 故障排除
-- 列表展示: 封面、时长、标题、播放量、发布日期
-- ----------------------------
drop table if exists teaching_video;
create table teaching_video (
video_id bigint(20) not null auto_increment comment '视频ID',
category_code varchar(32) not null comment '分类编码(ALL/BASIC/FAQ/TROUBLE)',
title varchar(120) not null comment '视频标题',
summary varchar(255) default '' comment '视频简介(列表摘要)',
cover_url varchar(512) default '' comment '封面URL',
video_url varchar(512) default '' comment '视频URL',
duration_seconds int(11) default 0 comment '时长(秒)',
view_count bigint(20) default 0 comment '播放量',
publish_date date default null comment '发布日期',
sort_num int(11) default 0 comment '排序(越大越靠前)',
status char(1) default '0' comment '状态(0上架 1下架)',
del_flag char(1) default '0' comment '删除标志(0存在 2删除)',
create_by varchar(64) default '' comment '创建者',
create_time datetime comment '创建时间',
update_by varchar(64) default '' comment '更新者',
update_time datetime comment '更新时间',
remark varchar(500) default null comment '备注',
primary key (video_id),
key idx_teaching_video_category (category_code),
key idx_teaching_video_status (status),
key idx_teaching_video_publish (publish_date),
key idx_teaching_video_sort (sort_num)
) engine=innodb auto_increment=10001 comment = '教学视频表';
-- ----------------------------
-- 示例数据(用于测试列表/分类筛选/详情)
-- 说明cover_url/video_url 先用占位字符串,前端可替换为真实地址或通过文件上传生成
-- ----------------------------
insert into teaching_video
(video_id, category_code, title, summary, cover_url, video_url, duration_seconds, view_count, publish_date, sort_num, status, del_flag, create_by, create_time, update_by, update_time, remark)
values
(10001, 'BASIC', '焊接机器人基础操作教程', '从开机自检到基础示教,快速掌握焊接机器人上手流程。', '/profile/teaching/cover/basic_01.jpg', 'https://example.com/video/basic_01.mp4', 755, 1200, '2022-10-12', 90, '0', '0', 'admin', sysdate(), '', null, '原型同款:基础教学'),
(10002, 'BASIC', '焊接电流电压与工艺参数设置', '讲解电流/电压/送丝速度等关键参数对焊缝成形的影响。', '/profile/teaching/cover/basic_02.jpg', 'https://example.com/video/basic_02.mp4', 1005, 980, '2022-11-06', 80, '0', '0', 'admin', sysdate(), '', null, null),
(10003, 'FAQ', '高级编程技巧与路径优化', '常见焊接路径规划思路与示教编程技巧,提升效率与一致性。', '/profile/teaching/cover/faq_01.jpg', 'https://example.com/video/faq_01.mp4', 1531, 860, '2022-07-28', 70, '0', '0', 'admin', sysdate(), '', null, '原型同款25:31'),
(10004, 'BASIC', '焊接机器人日常维护全面指南', '保养点检、易损件更换、维护周期建议,减少停机风险。', '/profile/teaching/cover/basic_03.jpg', '/profile/teaching/video/basic_03.mp4', 1127, 540, '2022-06-15', 60, '0', '0', 'admin', sysdate(), '', null, '原型同款18:47'),
(10005, 'TROUBLE','常见故障快速诊断与解决方案', '焊接异常、报警代码、通信中断等问题的排查路径与处理建议。', '/profile/teaching/cover/trouble_01.jpg', '/profile/teaching/video/trouble_01.mp4', 1270, 760, '2022-05-03', 50, '0', '0', 'admin', sysdate(), '', null, '原型同款21:10'),
(10006, 'FAQ', '焊接质量评估与参数调优', '从外观到强度,介绍常用评估指标与参数调优策略。', '/profile/teaching/cover/faq_02.jpg', '/profile/teaching/video/faq_02.mp4', 1005, 420, '2022-03-13', 40, '0', '0', 'admin', sysdate(), '', null, '原型同款16:45');