审查视图

html/index/care_f.html 9.4 KB
dl authored
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86
<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <script src="../../assets/js/fontsize.js"></script>
    <link rel="stylesheet" href="../../assets/css/api.css"/>
    <link rel="stylesheet" href="../../assets/css/index.css">
    <link rel="stylesheet" href="../../assets/css/doc.css">
    <link rel="stylesheet" href="../../assets/icon/iconfont.css">
    <style>
        body {
            background-color: #f5f5f5;
            /*padding-bottom: 1rem;*/
        }

        .care_title {
            /*display: flex;*/
            /*align-items: center;*/
            /*justify-content: space-between;*/
            font-size: 19px;
            color: #424242;
            padding: 0.25rem 0.6rem;
            border-bottom: 1px solid #ebebeb;
            text-align: center;
            /*font-weight: bold;*/
            position: relative;
        }

        .care_title .icon-ziyuan {
            position: absolute;
            right: 0.6rem;
            font-size: 15px;
            top: 19%;
            transform: rotate(-90deg);
        }

        .care_title .icon-shangla {
            position: absolute;
            right: 0.8rem;
            font-size: 15px;
            top: 34%;
            transform: rotate(180deg);
        }

        .img_p p {
            display: flex;
            align-items: center;
            justify-content: center;
            background-color: #fff;
        }

        .img_p {
            margin: 0 0 0.1rem 0;
            background-color: #fff;
            box-shadow: 0 0.05rem 0.05rem rgba(249, 249, 249, 0.75);
        }

        .img_p img {
            width: 100%;
        }

        .care_faq {
            display: flex;
            align-items: center;
            justify-content: space-between;
            font-size: 15px;
            color: #424242;
            padding: 0.25rem 0.4rem;
            background-color: #fff;
            box-shadow: 0 0.05rem 0.05rem RGBA(249, 249, 249, 0.75);
            margin: 0 0 1.15rem 0;
        }

        .care_faq .icon-xiangyou {
            color: #BCBCBC;
            font-size: 15px;
        }

    </style>
</head>
<body>
<div id="loadStart"></div>
朱振飞 authored
87
dl authored
88
<div id="app" v-cloak>
朱振飞 authored
89 90 91 92 93 94 95
    <!--<header id="header">-->
        <!--<div class="index_header">-->
            <!--<div class="close_left" onclick="closeWindow()"><span class="iconfont icon-fanhui"></span></div>-->
            <!--<span>{{post_title}}</span>-->
            <!--<span class="iconfont icon-fenxiang-tianchong" ></span>-->
        <!--</div>-->
    <!--</header>-->
朱振飞 authored
96 97 98
    <div class="warp">
        <div class="nurse_banner" :style="{backgroundImage:'url(' + banner + ')'}">
            <!--<div class="nurse_text">{{post_title}}</div>-->
dl authored
99 100
        </div>
        <div class="img_p">
朱振飞 authored
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129
            <div v-html="price_table"></div>
        </div>
        <div class="img_p">
            <div v-html="problems"></div>
        </div>
        <div class="img_p">
            <div class="care_title" @click="imgshow=!imgshow"><span>— 服务详情 —</span><span class="iconfont "
                                                                                         :class="{'icon-ziyuan':imgshow,'icon-shangla':!imgshow}"></span>
            </div>
            <div v-html="service_info" v-show="imgshow"></div>
        </div>
        <div class="img_p">
            <div class="care_title" @click="img_show=!img_show"><span>— 服务须知 —</span>
                <span class="iconfont" :class="{'icon-ziyuan':img_show,'icon-shangla':!img_show}"></span>
            </div>
        </div>
        <div v-show="!img_show">
            <div class="img_p">
                <div v-html="service_notice"></div>
            </div>
        </div>
        <div class="img_p">
            <div v-html="advantage"></div>
        </div>
        <div class="img_p">
            <div v-html="service_step"></div>
        </div>
        <div class="care_faq" @click="question">
            <span>常见问题</span><span class="iconfont icon-xiangyou"></span>
dl authored
130 131
        </div>
    </div>
朱振飞 authored
132
dl authored
133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153
    <footer class="doc_footer" id="footer">
        <div class="doc_left"><span class="rmb"></span><span class="doc_price">{{price?price:0}}</span><span
                class="doc_qi"></span>
        </div>
        <div class="doc_right"><span class="iconfont icon-kefu" @click="openSever"></span><span class="doc_appointment"
                                                                                                @click="appointment()">去 预 约</span>
        </div>
    </footer>
</div>
</body>
</html>
<script type="text/javascript" src="../../assets/js/api.js"></script>
<script type="text/javascript" src="../../assets/js/public.js"></script>
<script type="text/javascript" src="../../assets/js/fastclick.js"></script>
<script>
    new FastClick(document.body);
</script>
<script type="text/javascript" src="../../assets/js/vue.min.js"></script>
<script type="text/javascript" src="../../assets/js/axios.min.js"></script>
<script type="text/javascript" src="../../assets/icon/iconfont.js"></script>
<script>
朱振飞 authored
154 155
    var title = document.getElementsByTagName("title")[0]
dl authored
156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178
    var app = new Vue({
        el: '#app',
        data: {
            img_show: false,
            imgshow: false,
            id: '',
            cid: '',
            proCareInfoInfo_data: [],
            banner: '',//商品头图
            price_table: '',//价格表单
            service_info: '',//服务详情
            service_notice: '',//服务须知
            advantage: '',//我们的优势
            service_step: '',//服务流程
            price: 0,
            cityname: '',
            post_title: '',
            problems: '',
            rongYunToken: '',
            userId: '',
        },
        created: function () {
                // alert('预约' + api.pageParam.id)
朱振飞 authored
179 180 181 182 183 184
            this.cid = localStorage.getItem('cid');
            this.id = localStorage.getItem('id');
            this.care_name = localStorage.getItem('care_name');
            this.cityname = localStorage.getItem('cityname');
            this.proCareInfoInfo();
            this.getUserIndexInfo();
dl authored
185 186 187 188
        },
        methods: {
            // 去预约
            appointment: function () {
朱振飞 authored
189
                var app = this
dl authored
190
                if (app.cid == 5 || app.cid == 7 || app.cid == 8 || app.cid == 10) {
朱振飞 authored
191
                    openView('doc_package_f', '../index/doc_package_f', app.care_name, 'doc_package_f', false, {
dl authored
192 193 194 195 196
                        id: app.id,
                        cid: app.cid,
                        cityname: app.cityname
                    })
                } else {
朱振飞 authored
197
                    openView('pay_form_f', '../index/pay_form_f', app.care_name, 'pay_form_f', false, {
dl authored
198 199
                        id: app.id,
                        cityname: app.cityname,
朱振飞 authored
200
                        cid: app.cid
dl authored
201 202 203 204 205
                    })
                }
            },
            // 去常见问题
            question: function () {
朱振飞 authored
206
                var app = this
dl authored
207 208 209 210 211 212
                openView('my_que', 'my/my_que', '常见问题', 'my_que', false, {
                    id: app.id
                })
            },
            // 获取详情
            proCareInfoInfo: function () {
朱振飞 authored
213
                var app = this;
dl authored
214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231
                var post = {
                    id: app.id
                };
                getRequest('post', 'portal/Goods/proCareInfo', post, null).then(function (res) {
                    if (res.data.code == 1) {
                        app.banner = res.data.data.banner;
                        app.post_title = res.data.data.post_title;
                        app.price_table = res.data.data.price_table;
                        app.problems = res.data.data.problems;
                        app.service_info = res.data.data.service_info;
                        app.service_notice = res.data.data.service_notice;
                        app.advantage = res.data.data.advantage;
                        app.service_step = res.data.data.service_step;
                        app.price = res.data.data.price ? res.data.data.price : 0;
                        loadEnd();
                        // app.banner = app.proCareInfoInfo_data.banner
                    }
                })
朱振飞 authored
232
dl authored
233 234 235
            },
            // 获取个人的基本信息
            getUserIndexInfo: function () {
朱振飞 authored
236
                var app = this
dl authored
237 238 239 240 241 242 243 244 245 246 247 248 249 250
                var header = {
                    "XX-Device-Type": getDevice(),
                    'XX-Token': getToken()
                };
                getRequest('post', 'user/index/getUserIndexInfo', null, header).then(function (res) {
                    if (res.data.code == 1) {
                        app.user_info = res.data.data;
                    } else {
                        toastMsg(res.data.msg)
                    }
                })
            },
            // 打开客服
            openSever: function () {
朱振飞 authored
251
                var app = this
dl authored
252 253
                api.openWin({
                    name: 'cs_win',
朱振飞 authored
254
                    url: '../common/cs_win.html'
dl authored
255
                });
朱振飞 authored
256 257 258 259 260 261 262
            }
        },
        watch:{
            post_title(curVal,oldVal){
                // title.innerText = this.post_title;
                document.title = this.post_title;
            }
dl authored
263 264 265
        }
    })
</script>