|
@@ -22,11 +22,14 @@ const visible = ref(false)
|
|
|
const menuItems = [
|
|
const menuItems = [
|
|
|
{ id: 1, name: '视频学习', icon: 'https://oss.xiaoxiongcode.com/static/home/6419.png', x: 0, y: 21 },
|
|
{ id: 1, name: '视频学习', icon: 'https://oss.xiaoxiongcode.com/static/home/6419.png', x: 0, y: 21 },
|
|
|
// { id: 2, name: '实战指导', icon: 'https://oss.xiaoxiongcode.com/static/home/6418.png', x: 27, y: 19 },
|
|
// { id: 2, name: '实战指导', icon: 'https://oss.xiaoxiongcode.com/static/home/6418.png', x: 27, y: 19 },
|
|
|
- { id: 3, name: '参考答案', icon: 'https://oss.xiaoxiongcode.com/static/home/6416.png', x: 80, y: 16 },
|
|
|
|
|
- { id: 4, name: '开始编程', icon: 'https://oss.xiaoxiongcode.com/static/home/6417.png', x: 38, y: 18 },
|
|
|
|
|
|
|
+ { id: 4, name: '开始编程', icon: 'https://oss.xiaoxiongcode.com/static/home/6417.png', x: 27, y: 19 },
|
|
|
|
|
+ { id: 3, name: '参考答案', icon: 'https://oss.xiaoxiongcode.com/static/home/6416.png', x: 55, y: 7 },
|
|
|
|
|
+
|
|
|
|
|
+ { id: 5, name: '效果展示', icon: 'https://oss.xiaoxiongcode.com/static/home/6417.png', x: 80, y: 16 },
|
|
|
]
|
|
]
|
|
|
//点击事件
|
|
//点击事件
|
|
|
function handleClick(id: number) {
|
|
function handleClick(id: number) {
|
|
|
|
|
+ const res = isTabletDevice()
|
|
|
switch (id) {
|
|
switch (id) {
|
|
|
case 1:
|
|
case 1:
|
|
|
router.push({
|
|
router.push({
|
|
@@ -55,7 +58,6 @@ function handleClick(id: number) {
|
|
|
});
|
|
});
|
|
|
break
|
|
break
|
|
|
case 4:
|
|
case 4:
|
|
|
- const res = isTabletDevice()
|
|
|
|
|
if (res) {
|
|
if (res) {
|
|
|
router.push({
|
|
router.push({
|
|
|
path: "/pages/programming/web-view",
|
|
path: "/pages/programming/web-view",
|
|
@@ -67,6 +69,20 @@ function handleClick(id: number) {
|
|
|
visible.value = true
|
|
visible.value = true
|
|
|
}
|
|
}
|
|
|
break
|
|
break
|
|
|
|
|
+ case 5:
|
|
|
|
|
+ if (res) {
|
|
|
|
|
+ router.push({
|
|
|
|
|
+ path: "/pages/programming/web-view",
|
|
|
|
|
+ query: {
|
|
|
|
|
+ id: router.query().id,
|
|
|
|
|
+ url: course.value?.sbFilePath,
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+ });
|
|
|
|
|
+ } else {
|
|
|
|
|
+ visible.value = true
|
|
|
|
|
+ }
|
|
|
|
|
+ break
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|