|
@@ -0,0 +1,266 @@
|
|
1
|
+<template>
|
|
2
|
+ <div class="page_home">
|
|
3
|
+ <!-- <iframe :src = this.customUrl width="100%" height="100%" marginwidth="0" frameborder="no" scrolling="no"></iframe> -->
|
|
4
|
+ <div v-for="item in this.ordmodel" :key="item.id">
|
|
5
|
+ <div class="focusImg" v-if="item.mode_type == 1">
|
|
6
|
+ <div class="swiper-container">
|
|
7
|
+ <div class="swiper-wrapper">
|
|
8
|
+ <div class="swiper-slide" v-for="it in item.Conrotation" :key="it.id">
|
|
9
|
+ <img class="imgtwo" :src="it.images" />
|
|
10
|
+ </div>
|
|
11
|
+ </div>
|
|
12
|
+ <!-- 如果需要分页器 -->
|
|
13
|
+ <div class="swiper-pagination"></div>
|
|
14
|
+ </div>
|
|
15
|
+ </div>
|
|
16
|
+ <!-- <div class="detail"> -->
|
|
17
|
+ <div class="row one detail" v-if="item.mode_type == 2">
|
|
18
|
+ <p class="title">{{item.title}}:</p>
|
|
19
|
+ <p class="msg">{{item.Hosaddress.address}}</p>
|
|
20
|
+ </div>
|
|
21
|
+ <div class="row" v-if="item.mode_type == 3">
|
|
22
|
+ <div v-for="it in Connectways" :key="it.id">
|
|
23
|
+ <p class="title">{{it.title}}:</p>
|
|
24
|
+ <p class="msg">{{it.content}}</p>
|
|
25
|
+ <br />
|
|
26
|
+ </div>
|
|
27
|
+ </div>
|
|
28
|
+ <div class="row" v-if="item.mode_type == 4">
|
|
29
|
+ <p class="title">{{item.title}}:</p>
|
|
30
|
+ <p class="msg">{{item.Worktime.worktime}}</p>
|
|
31
|
+ </div>
|
|
32
|
+ <div class="row one" v-if="item.mode_type == 5">
|
|
33
|
+ <p class="title">{{item.title}}:</p>
|
|
34
|
+ <p class="msg">{{item.Rideway.ride_way}}</p>
|
|
35
|
+ </div>
|
|
36
|
+ </div>
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+ <!-- tab切换 -->
|
|
40
|
+ <div class="tabs">
|
|
41
|
+ <ul class="tabList">
|
|
42
|
+ <li
|
|
43
|
+ class="tabOne"
|
|
44
|
+ v-for="item in this.navigationdata"
|
|
45
|
+ :key="item.id"
|
|
46
|
+ @click="CallPhone(item.linktype,item.navaddress,item.user_org_id)">
|
|
47
|
+ <img :src="item.nonavimages" alt />
|
|
48
|
+ <span>{{item.navtitle}}</span>
|
|
49
|
+ </li>
|
|
50
|
+ </ul>
|
|
51
|
+ </div>
|
|
52
|
+ </div>
|
|
53
|
+</template>
|
|
54
|
+
|
|
55
|
+<script>
|
|
56
|
+import Swiper from "swiper";
|
|
57
|
+import Vue from "vue";
|
|
58
|
+import { Swipe, SwipeItem} from "mint-ui";
|
|
59
|
+import "mint-ui/lib/style.css";
|
|
60
|
+import { getDefalutNavigationData,getOrderModel, getAllConnecWay } from "@/api/micro/micro";
|
|
61
|
+export default {
|
|
62
|
+ data() {
|
|
63
|
+ return {
|
|
64
|
+ navigationdata: [],
|
|
65
|
+ ordmodel: [],
|
|
66
|
+ Connectways: [],
|
|
67
|
+ };
|
|
68
|
+ },
|
|
69
|
+ methods: {
|
|
70
|
+ getDefalutNavigationData(orgid) {
|
|
71
|
+ getDefalutNavigationData(orgid).then(response => {
|
|
72
|
+ if (response.data.state == 1) {
|
|
73
|
+ var navigation = response.data.data.navigation;
|
|
74
|
+ for (let index = 0; index < navigation.length; index++) {
|
|
75
|
+ navigation[1].nonavimages = "https://images.shengws.com/2124_o_1571990749565.png";
|
|
76
|
+
|
|
77
|
+ }
|
|
78
|
+ console.log("navigation是什么", navigation);
|
|
79
|
+ this.navigationdata = navigation;
|
|
80
|
+ }
|
|
81
|
+ });
|
|
82
|
+ },
|
|
83
|
+ initSwiper() {
|
|
84
|
+ var mySwiper1 = new Swiper(".swiper-container", {
|
|
85
|
+ loop: true, // 循环模式选项
|
|
86
|
+ pagination: {
|
|
87
|
+ el: ".swiper-pagination"
|
|
88
|
+ },
|
|
89
|
+ // autoplay: {
|
|
90
|
+ // disableOnInteraction: false
|
|
91
|
+ // }
|
|
92
|
+ autoplay: true
|
|
93
|
+ });
|
|
94
|
+ },
|
|
95
|
+ getOrderModel(orgid) {
|
|
96
|
+ getOrderModel(orgid).then(response => {
|
|
97
|
+ if (response.data.state == 1) {
|
|
98
|
+ var ordmodel = response.data.data.ordmodel;
|
|
99
|
+ console.log("ordmodel是什么", ordmodel);
|
|
100
|
+ this.ordmodel = response.data.data.ordmodel;
|
|
101
|
+ }
|
|
102
|
+ });
|
|
103
|
+ },
|
|
104
|
+ getAllConnecWay(orgid) {
|
|
105
|
+ getAllConnecWay(orgid).then(response => {
|
|
106
|
+ if (response.data.state == 1) {
|
|
107
|
+ var connect = response.data.data.connect;
|
|
108
|
+ this.Connectways = connect;
|
|
109
|
+ }
|
|
110
|
+ });
|
|
111
|
+ },
|
|
112
|
+ CallPhone(linktype, address,orgid) {
|
|
113
|
+ console.log("orgid是什么啊",orgid)
|
|
114
|
+ console.log("linktype",linktype)
|
|
115
|
+ if(linktype == "1"){
|
|
116
|
+ this.$router.push({
|
|
117
|
+ path:"/microHome",
|
|
118
|
+ query:{
|
|
119
|
+ orgid:orgid,
|
|
120
|
+ }
|
|
121
|
+ })
|
|
122
|
+ }
|
|
123
|
+ if (linktype == "2") {
|
|
124
|
+ // window.location.href = address;
|
|
125
|
+ this.$router.push({
|
|
126
|
+ path: "/contactus",
|
|
127
|
+ query: {
|
|
128
|
+ orgid: orgid
|
|
129
|
+ }
|
|
130
|
+ });
|
|
131
|
+ }
|
|
132
|
+ if (linktype == "3") {
|
|
133
|
+ window.location.href = "tel://" + address + "";
|
|
134
|
+ }
|
|
135
|
+ if (linktype == "4") {
|
|
136
|
+ // window.location.href = address;
|
|
137
|
+ this.$router.push({
|
|
138
|
+ path:"/custom",
|
|
139
|
+ query:{
|
|
140
|
+ orgid:orgid
|
|
141
|
+ }
|
|
142
|
+ })
|
|
143
|
+ }
|
|
144
|
+ },
|
|
145
|
+ },
|
|
146
|
+ created(){
|
|
147
|
+ const orgid = this.$route.query.orgid;
|
|
148
|
+ console.log("我的", orgid);
|
|
149
|
+ this.url = orgid;
|
|
150
|
+ this.getDefalutNavigationData(orgid);
|
|
151
|
+ this.getOrderModel(orgid);
|
|
152
|
+ this.getAllConnecWay(orgid);
|
|
153
|
+ this.initSwiper();
|
|
154
|
+ },
|
|
155
|
+updated() {
|
|
156
|
+ this.initSwiper();
|
|
157
|
+ }
|
|
158
|
+ };
|
|
159
|
+</script>
|
|
160
|
+
|
|
161
|
+<style lang="scss" scoped>
|
|
162
|
+@import "../../assets/styles/mixin.scss";
|
|
163
|
+
|
|
164
|
+.page_home {
|
|
165
|
+ overflow: hidden;
|
|
166
|
+ display: flex;
|
|
167
|
+ flex-direction: column;
|
|
168
|
+ height: 100%;
|
|
169
|
+ > div:first-child {
|
|
170
|
+ flex: 1;
|
|
171
|
+ overflow: auto;
|
|
172
|
+ }
|
|
173
|
+ > div:first-child::-webkit-scrollbar {
|
|
174
|
+ width: 0;
|
|
175
|
+ }
|
|
176
|
+ // border:solid 1px red;
|
|
177
|
+}
|
|
178
|
+// .bugone{
|
|
179
|
+// border: solid 1px red;
|
|
180
|
+// }
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+.tabs {
|
|
184
|
+ @include border-top;
|
|
185
|
+ width: 100%;
|
|
186
|
+ height: 3.125rem;
|
|
187
|
+ box-sizing: border-box;
|
|
188
|
+}
|
|
189
|
+.tabList {
|
|
190
|
+ display: flex;
|
|
191
|
+ justify-content: space-around;
|
|
192
|
+ height: 100%;
|
|
193
|
+ .tabOne {
|
|
194
|
+ display: flex;
|
|
195
|
+ flex-direction: column;
|
|
196
|
+ justify-content: center;
|
|
197
|
+ align-items: center;
|
|
198
|
+ img {
|
|
199
|
+ // margin-top: 0.5rem;
|
|
200
|
+ width: 1.875rem;
|
|
201
|
+ height: 1.875rem;
|
|
202
|
+ }
|
|
203
|
+ span {
|
|
204
|
+ font-size: 0.75rem;
|
|
205
|
+ color: #999;
|
|
206
|
+ // line-height: 1.3125rem;
|
|
207
|
+ }
|
|
208
|
+ }
|
|
209
|
+}
|
|
210
|
+
|
|
211
|
+.page_home {
|
|
212
|
+ overflow: hidden;
|
|
213
|
+ height: 100%;
|
|
214
|
+ > div:nth-of-type(2) {
|
|
215
|
+ min-height: 5.125rem;
|
|
216
|
+ }
|
|
217
|
+ .focusImg {
|
|
218
|
+ width: 23.4375rem;
|
|
219
|
+ height: 11.5625rem;
|
|
220
|
+ img {
|
|
221
|
+ width: 100%;
|
|
222
|
+ height: 100%;
|
|
223
|
+ }
|
|
224
|
+ .swiper-container {
|
|
225
|
+ height: 100%;
|
|
226
|
+ }
|
|
227
|
+ }
|
|
228
|
+
|
|
229
|
+ .space {
|
|
230
|
+ margin: 0 1.25rem;
|
|
231
|
+ }
|
|
232
|
+ .row {
|
|
233
|
+ font-size: 1rem;
|
|
234
|
+ font-weight: 600;
|
|
235
|
+ color: rgba(7, 18, 40, 1);
|
|
236
|
+ line-height: 2.375rem;
|
|
237
|
+ min-height: 2.375rem;
|
|
238
|
+ width: 21.125rem;
|
|
239
|
+ margin: 0 1.25rem;
|
|
240
|
+ // border: 1px solid #000;
|
|
241
|
+
|
|
242
|
+ .title {
|
|
243
|
+ float: left;
|
|
244
|
+ width: 5rem;
|
|
245
|
+ }
|
|
246
|
+ .msg {
|
|
247
|
+ float: left;
|
|
248
|
+ width: 16rem;
|
|
249
|
+ line-height: 2.375rem;
|
|
250
|
+ min-height: 2.375rem;
|
|
251
|
+ word-wrap: break-word;
|
|
252
|
+ word-break: break-all;
|
|
253
|
+ // overflow-x: hidden;
|
|
254
|
+ }
|
|
255
|
+ }
|
|
256
|
+ .one {
|
|
257
|
+ min-height: 2.375rem;
|
|
258
|
+ // line-height: 3rem;
|
|
259
|
+ }
|
|
260
|
+ .detail {
|
|
261
|
+ width: 21.125rem;
|
|
262
|
+ margin: 1.1875rem 1.25rem 0 1.25rem;
|
|
263
|
+ }
|
|
264
|
+}
|
|
265
|
+</style>
|
|
266
|
+
|