-
{{ stop.stationNm }}
-
{{ stop.direction }}행
+
+
+
+
+
{{ title }}
+
+
+
+
+
{{ stop.stationNm }}
+
{{ stop.direction }}행
+
+
+
-
-
+
승차 예약
+
승차 예약
-
승차 예약
-
승차 예약
@@ -23,9 +27,11 @@
import axios from 'axios';
import {useRoute} from 'vue-router';
import router from '@/router';
+ import NavComp from '@/components/NavComp.vue';
export default {
name: 'testView',
+ components: {NavComp},
data() {
return {
bus_active: [false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false],
@@ -40,6 +46,9 @@
const stops = ref({});
const title = ref({});
+ // 읽을 전체 text
+ const wholeText = ref('');
+
// 사용자 위치 확인 및 버스 경유하는 정류장 출력
const locationSuccess = pos => {
userLat.value = pos.coords.latitude;
@@ -56,6 +65,7 @@
stops.value = res.data.msgBody.itemList;
console.log('stops: ', stops.value);
title.value = stops.value[0].busRouteNm;
+ wholeText.value = `노선 ${title.value}의 탑승 가능 정류장 목록. 승차 예약 버튼`;
})
.catch(err => console.log(err));
};
@@ -74,6 +84,7 @@
};
return {
+ wholeText,
title,
stops,
ridingReserve,
@@ -100,22 +111,36 @@
#ridingBtn {
font-weight: 900;
font-size: 32px;
- padding: 58px 94px;
background-color: #fff;
border-radius: 20px;
- margin-top: 5px;
color: $primary;
+ height: 140px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ position: absolute;
+ bottom: 40px;
+ left: 50%;
+ width: calc(100% - 32px);
+ transform: translate(-50%, -40px);
}
#ridingActiveBtn {
font-weight: 900;
font-size: 32px;
- padding: 58px 94px;
background-color: #ff5f63;
border-radius: 20px;
- margin-top: 5px;
color: #fff;
cursor: pointer;
+ height: 140px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ position: absolute;
+ bottom: 40px;
+ left: 50%;
+ width: calc(100% - 32px);
+ transform: translate(-50%, -40px);
}
#route_container {
@@ -139,8 +164,8 @@
h1 {
font-size: 30px;
line-height: 36.6px;
- margin-top: 97px;
- margin-bottom: 35px;
+ margin-top: 40px;
+ margin-bottom: 40px;
font-weight: 700;
color: $secondary;
}
diff --git a/src/views/passenger/StopBusListView.vue b/src/views/passenger/StopBusListView.vue
index 27b79fc..3cdd0c5 100644
--- a/src/views/passenger/StopBusListView.vue
+++ b/src/views/passenger/StopBusListView.vue
@@ -1,26 +1,29 @@
-
-
상왕십리역
-
-
-
-
-
-
{{ bus.busRouteNm }}
+
+
+
+
{{ bus.stEnd }}행
+
{{ bus.msg }}
+
-
{{ bus.stEnd }}행
-
{{ bus.msg }}
-
+
승차 예약
+
승차 예약
-
승차 예약
-
승차 예약
@@ -29,9 +32,11 @@
import {ref} from 'vue';
import {useRoute} from 'vue-router';
import router from '@/router';
+ import NavComp from '@/components/NavComp.vue';
export default {
name: 'StopBusList',
+ components: {NavComp},
data() {
return {
bus_active: [false, false, false, false, false, false, false, false, false, false, false, false, false, false, false],
@@ -54,6 +59,7 @@
0: 'public', // 공용
};
+ const title = ref('');
const arsId = route.params.arsId;
const stId = route.params.stId;
@@ -99,6 +105,9 @@
const getPrevData = async (ord, routeId, idx) => {
const url = `http://ws.bus.go.kr/api/rest/arrive/getArrInfoByRoute?serviceKey=${process.env.VUE_APP_ROUTE_SERVICE_KEY}&busRouteId=${routeId}&ord=${ord}&stId=${stId}&resultType=json`;
const data = await axios.get(url);
+ const res = await data.data;
+ console.log('res', res);
+ title.value = data.data.msgBody.itemList[0].stNm;
return data.data.msgBody.itemList[0].arrmsg1;
};
@@ -109,10 +118,15 @@
});
};
+ // 읽어줄 전체 text
+ const wholeText = `${title.value}에서 탑승 가능한 버스 노선 목록. 승차 예약 버튼`;
+
return {
+ title,
buses,
busType,
ridingReserve,
+ wholeText,
};
},
methods: {
@@ -136,22 +150,36 @@
#ridingBtn {
font-weight: 900;
font-size: 32px;
- padding: 58px 94px;
background-color: #fff;
border-radius: 20px;
- margin-top: 5px;
color: $primary;
+ height: 140px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ position: absolute;
+ bottom: 40px;
+ left: 50%;
+ width: calc(100% - 32px);
+ transform: translate(-50%, -40px);
}
#ridingActiveBtn {
font-weight: 900;
font-size: 32px;
- padding: 58px 94px;
background-color: #ff5f63;
border-radius: 20px;
- margin-top: 5px;
color: #fff;
cursor: pointer;
+ height: 140px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ position: absolute;
+ bottom: 40px;
+ left: 50%;
+ width: calc(100% - 32px);
+ transform: translate(-50%, -40px);
}
#route_container {
@@ -175,8 +203,8 @@
h1 {
font-size: 30px;
line-height: 36.6px;
- margin-top: 97px;
- margin-bottom: 35px;
+ margin-top: 40px;
+ margin-bottom: 40px;
font-weight: 700;
color: $secondary;
}