-
{{item.name}}
-
-
{{tagItem.name}}-
+
+
+
![]()
+
+
+
{{item.name}}
+
+
{{item.points.length}}个景点
+
{{item.date}}
+
+
+
+
-
{{item.points.length}}个景点
-
{{item.date}}
-
-
-
-
+
+
暂无行程
@@ -53,7 +57,26 @@
},
// 添加线路
addLine() {
+ sessionStorage.setItem('addUserLine', 1)
this.$router.push('/')
+ },
+ // 删除线路
+ delLine(item) {
+ this.$dialog.confirm({
+ title: '',
+ message: '是否删除当前行程?'
+ }).then(() => {
+ this.post({
+ line_id: item.id
+ },'/api/emap/updateUserLine').then(res => {
+ if(res.code == 1) {
+ this.$toast('删除成功')
+ this.getList()
+ }
+ })
+ }).catch(() => {
+
+ })
}
}
}
@@ -136,4 +159,11 @@
}
}
}
+
+ .noLine {
+ text-align: center;
+ color: #ccc;
+ font-size: 26px;
+ margin-top: 20px;
+ }
\ No newline at end of file
diff --git a/src/views/compoents/lineRoute.vue b/src/views/compoents/lineRoute.vue
index 1c01775..bac44b0 100644
--- a/src/views/compoents/lineRoute.vue
+++ b/src/views/compoents/lineRoute.vue
@@ -110,6 +110,7 @@
if(res.code == 1) {
this.$toast('添加成功')
setTimeout(() => {
+ this.$parent.$parent.isMyLine = true
this.$parent.$parent.addlineRoute(0)
},800)
setTimeout(() => {