默认提交
Showing
14 changed files
with
151 additions
and
108 deletions
| ... | @@ -120,7 +120,7 @@ | ... | @@ -120,7 +120,7 @@ | 
| 120 | @media (max-width: 1200px) { | 120 | @media (max-width: 1200px) { | 
| 121 | .container { | 121 | .container { | 
| 122 | display: -webkit-box; | 122 | display: -webkit-box; | 
| 123 | overflow-x: scroll; | 123 | overflow-x: auto; | 
| 124 | -webkit-overflow-scrolling: touch; | 124 | -webkit-overflow-scrolling: touch; | 
| 125 | width: 92vw; | 125 | width: 92vw; | 
| 126 | } | 126 | } | ... | ... | 
| ... | @@ -175,7 +175,7 @@ | ... | @@ -175,7 +175,7 @@ | 
| 175 | .container { | 175 | .container { | 
| 176 | width: 1200px; | 176 | width: 1200px; | 
| 177 | display: -webkit-box; | 177 | display: -webkit-box; | 
| 178 | overflow-x: scroll; | 178 | overflow-x: auto; | 
| 179 | -webkit-overflow-scrolling: touch; | 179 | -webkit-overflow-scrolling: touch; | 
| 180 | width: 92vw; | 180 | width: 92vw; | 
| 181 | } | 181 | } | ... | ... | 
| ... | @@ -83,7 +83,7 @@ | ... | @@ -83,7 +83,7 @@ | 
| 83 | .payment { | 83 | .payment { | 
| 84 | &-nav { | 84 | &-nav { | 
| 85 | display: -webkit-box; | 85 | display: -webkit-box; | 
| 86 | overflow-x: scroll; | 86 | overflow-x: auto; | 
| 87 | -webkit-overflow-scrolling: touch; | 87 | -webkit-overflow-scrolling: touch; | 
| 88 | width: 92vw; | 88 | width: 92vw; | 
| 89 | } | 89 | } | ... | ... | 
| ... | @@ -113,7 +113,7 @@ | ... | @@ -113,7 +113,7 @@ | 
| 113 | .submit-btn { | 113 | .submit-btn { | 
| 114 | width: 13.583333rem; | 114 | width: 13.583333rem; | 
| 115 | height: 4.083333rem; | 115 | height: 4.083333rem; | 
| 116 | margin: 2.5rem auto 0; | 116 | margin: 0 auto 0; | 
| 117 | line-height: 4.083333rem; | 117 | line-height: 4.083333rem; | 
| 118 | box-shadow: 0px 10px 13px 0 rgba(236, 100, 41, 0.2); | 118 | box-shadow: 0px 10px 13px 0 rgba(236, 100, 41, 0.2); | 
| 119 | background-blend-mode: soft-light, ; | 119 | background-blend-mode: soft-light, ; | 
| ... | @@ -135,7 +135,7 @@ | ... | @@ -135,7 +135,7 @@ | 
| 135 | @media (max-width: 1200px) { | 135 | @media (max-width: 1200px) { | 
| 136 | .container { | 136 | .container { | 
| 137 | display: -webkit-box; | 137 | display: -webkit-box; | 
| 138 | overflow-x: scroll; | 138 | overflow-x: auto; | 
| 139 | -webkit-overflow-scrolling: touch; | 139 | -webkit-overflow-scrolling: touch; | 
| 140 | width: 92vw; | 140 | width: 92vw; | 
| 141 | 141 | ... | ... | 
| ... | @@ -2,7 +2,7 @@ | ... | @@ -2,7 +2,7 @@ | 
| 2 | <template> | 2 | <template> | 
| 3 | <div> | 3 | <div> | 
| 4 | <auth @onLogin="userLogin" @onLogout="userLogout" :checkProfile="true" ref="auth" :tipModel="'m2'"></auth> | 4 | <auth @onLogin="userLogin" @onLogout="userLogout" :checkProfile="true" ref="auth" :tipModel="'m2'"></auth> | 
| 5 | <modal-comp :visible="modalVisiable" :show-confirm="false" :icon="modalIcon" :content="modalContent" :confirm="modalCallback" :overlay="modalCallback"></modal-comp> | 5 | <modal-comp :visible="modalVisiable" :show-confirm="false" :icon="modalIcon" :content="modalContent" :confirm="modalCallback" :overlay="modalCallback"></modal-comp> | 
| 6 | <template v-if="showForm"> | 6 | <template v-if="showForm"> | 
| 7 | <policy-head-list :multiSelectable="true" @onSelect="handlePolicySelect"></policy-head-list> | 7 | <policy-head-list :multiSelectable="true" @onSelect="handlePolicySelect"></policy-head-list> | 
| 8 | <div class="container border" v-if="selectedPolicies.length > 0 && data"> | 8 | <div class="container border" v-if="selectedPolicies.length > 0 && data"> | 
| ... | @@ -57,11 +57,12 @@ | ... | @@ -57,11 +57,12 @@ | 
| 57 | <img src="@/assets/images/common/icon-notice.png" alt="">{{errorTips.e3}} | 57 | <img src="@/assets/images/common/icon-notice.png" alt="">{{errorTips.e3}} | 
| 58 | </div> | 58 | </div> | 
| 59 | </div> | 59 | </div> | 
| 60 | <div class="submit-btn flex-center" @click="updateContactsHandler" :class="{disabled: submitBtnDisabled}"> | ||
| 61 | <van-loading v-if="loading" /> | ||
| 62 | <span>{{$t('policyChangeContact.submit')}}</span> | ||
| 63 | </div> | ||
| 60 | </div> | 64 | </div> | 
| 61 | <div class="submit-btn flex-center" @click="updateContactsHandler" :class="{disabled: submitBtnDisabled}"> | 65 | |
| 62 | <van-loading v-if="loading" /> | ||
| 63 | <span>{{$t('policyChangeContact.submit')}}</span> | ||
| 64 | </div> | ||
| 65 | </div> | 66 | </div> | 
| 66 | <!-- <div v-else style="height:400px"></div> --> | 67 | <!-- <div v-else style="height:400px"></div> --> | 
| 67 | </template> | 68 | </template> | ... | ... | 
| ... | @@ -155,7 +155,7 @@ | ... | @@ -155,7 +155,7 @@ | 
| 155 | @media (max-width: 1200px) { | 155 | @media (max-width: 1200px) { | 
| 156 | .container { | 156 | .container { | 
| 157 | display: -webkit-box; | 157 | display: -webkit-box; | 
| 158 | overflow-x: scroll; | 158 | overflow-x: auto; | 
| 159 | -webkit-overflow-scrolling: touch; | 159 | -webkit-overflow-scrolling: touch; | 
| 160 | width: 92vw; | 160 | width: 92vw; | 
| 161 | 161 | ... | ... | 
| ... | @@ -171,10 +171,9 @@ | ... | @@ -171,10 +171,9 @@ | 
| 171 | @media (max-width: 1200px) { | 171 | @media (max-width: 1200px) { | 
| 172 | .container { | 172 | .container { | 
| 173 | display: -webkit-box; | 173 | display: -webkit-box; | 
| 174 | overflow-x: scroll; | 174 | overflow-x: auto; | 
| 175 | -webkit-overflow-scrolling: touch; | 175 | -webkit-overflow-scrolling: touch; | 
| 176 | width: 92vw; | 176 | width: 92vw; | 
| 177 | |||
| 178 | } | 177 | } | 
| 179 | } | 178 | } | 
| 180 | 179 | ... | ... | 
| ... | @@ -14,7 +14,7 @@ | ... | @@ -14,7 +14,7 @@ | 
| 14 | <div class="boo-btn pointer" :class="{active:isOwner}" @click="switchPolicyRole(1)">{{$t('policyChangeInformation.owner')}}</div> | 14 | <div class="boo-btn pointer" :class="{active:isOwner}" @click="switchPolicyRole(1)">{{$t('policyChangeInformation.owner')}}</div> | 
| 15 | <div class="boo-btn pointer" :class="{active:!isOwner}" @click="switchPolicyRole(2)">{{$t('policyChangeInformation.insured')}}</div> | 15 | <div class="boo-btn pointer" :class="{active:!isOwner}" @click="switchPolicyRole(2)">{{$t('policyChangeInformation.insured')}}</div> | 
| 16 | </div> | 16 | </div> | 
| 17 | </div> | 17 | </div> | 
| 18 | 18 | ||
| 19 | <policy-head-list :multiSelectable="isOwner" @onSelect="handlePolicySelect" :model="'checkbox'"></policy-head-list> | 19 | <policy-head-list :multiSelectable="isOwner" @onSelect="handlePolicySelect" :model="'checkbox'"></policy-head-list> | 
| 20 | <div class="container border" v-if="selectedPolicies.length > 0 && data"> | 20 | <div class="container border" v-if="selectedPolicies.length > 0 && data"> | ... | ... | 
| 1 | @import '@/styles/_support'; | 1 | @import '@/styles/_support'; | 
| 2 | .list-container { | 2 | .list-container { | 
| 3 | overflow-x: auto; | 3 | overflow-x: auto; | 
| 4 | padding-bottom: 2rem; | 4 | margin-bottom: 2rem; | 
| 5 | } | 5 | } | 
| 6 | 6 | ||
| 7 | .hide { | 7 | .hide { | 
| ... | @@ -215,3 +215,17 @@ | ... | @@ -215,3 +215,17 @@ | 
| 215 | } | 215 | } | 
| 216 | } | 216 | } | 
| 217 | } | 217 | } | 
| 218 | |||
| 219 | @media (max-width: 1200px) { | ||
| 220 | .list-container { | ||
| 221 | display: -webkit-box; | ||
| 222 | overflow-x: auto; | ||
| 223 | -webkit-overflow-scrolling: touch; | ||
| 224 | width: 92vw; | ||
| 225 | |||
| 226 | } | ||
| 227 | } | ||
| 228 | |||
| 229 | .list-container::-webkit-scrollbar { | ||
| 230 | display: none; | ||
| 231 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... | 
| ... | @@ -71,4 +71,4 @@ | ... | @@ -71,4 +71,4 @@ | 
| 71 | <script src="./policy-head-list.js"></script> | 71 | <script src="./policy-head-list.js"></script> | 
| 72 | <style lang="scss" scoped> | 72 | <style lang="scss" scoped> | 
| 73 | @import "./policy-head-list.scss"; | 73 | @import "./policy-head-list.scss"; | 
| 74 | </style> | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | 
| 74 | </style> | ... | ... | 
| 1 | import { mapState } from "vuex"; | 1 | import { | 
| 2 | mapState | ||
| 3 | } from "vuex"; | ||
| 2 | import api from '@/api/api' | 4 | import api from '@/api/api' | 
| 3 | import { httpPost } from '@/api/fetch-api.js' | 5 | import { | 
| 6 | httpPost | ||
| 7 | } from '@/api/fetch-api.js' | ||
| 4 | 8 | ||
| 5 | import Auth from '@components/auth/auth.vue'; | 9 | import Auth from '@components/auth/auth.vue'; | 
| 6 | import JsEncrypt from "jsencrypt"; | 10 | import JsEncrypt from "jsencrypt"; | 
| ... | @@ -10,96 +14,109 @@ let rsa = new JsEncrypt(); | ... | @@ -10,96 +14,109 @@ let rsa = new JsEncrypt(); | 
| 10 | rsa.setPublicKey(key); | 14 | rsa.setPublicKey(key); | 
| 11 | 15 | ||
| 12 | function encryptContent(obj) { | 16 | function encryptContent(obj) { | 
| 13 | let str = JSON.stringify(obj); | 17 | let str = JSON.stringify(obj); | 
| 14 | let securityContent = rsa.encrypt(str); | 18 | let securityContent = rsa.encrypt(str); | 
| 15 | return securityContent; | 19 | return securityContent; | 
| 16 | }; | 20 | }; | 
| 17 | 21 | ||
| 18 | 22 | ||
| 19 | export default { | 23 | export default { | 
| 20 | data() { | 24 | data() { | 
| 21 | return { | 25 | return { | 
| 22 | key: 'value', | 26 | key: 'value', | 
| 23 | outsideUrl: "", | 27 | outsideUrl: "", | 
| 24 | information: {}, | 28 | information: {}, | 
| 25 | } | 29 | } | 
| 26 | }, | 30 | }, | 
| 27 | components: { | 31 | components: { | 
| 28 | Auth | 32 | Auth | 
| 29 | }, | 33 | }, | 
| 30 | computed: { | 34 | computed: { | 
| 31 | ...mapState({ | 35 | ...mapState({ | 
| 32 | userInfo: state => state.userInfo | 36 | userInfo: state => state.userInfo | 
| 33 | }), | 37 | }), | 
| 34 | }, | 38 | }, | 
| 35 | methods: { | 39 | methods: { | 
| 36 | init() { | 40 | init() { | 
| 37 | if (this.isLogin()) { | 41 | if (this.isLogin()) { | 
| 38 | httpPost({ url: api.profile, sid: true }).then(content => { | 42 | httpPost({ | 
| 39 | if (content) { | 43 | url: api.profile, | 
| 40 | this.information = content; | 44 | sid: true | 
| 41 | this.gotoVhis(); | 45 | }).then(content => { | 
| 42 | } | 46 | if (content) { | 
| 43 | }) | 47 | this.information = content; | 
| 44 | } else { | 48 | this.gotoVhis(); | 
| 45 | this.gotoVhis(); | 49 | } | 
| 46 | } | 50 | }) | 
| 47 | }, | 51 | } else { | 
| 48 | userLogout(){ | 52 | this.gotoVhis(); | 
| 49 | this.gotoVhis(); | 53 | } | 
| 50 | }, | 54 | }, | 
| 51 | isLogin() { | 55 | userLogout() { | 
| 52 | return this.userInfo && this.userInfo.sid; | 56 | this.gotoVhis(); | 
| 53 | }, | 57 | }, | 
| 54 | gotoVhis() { | 58 | isLogin() { | 
| 55 | let url = process.env.VUE_APP_VHIS_INDEX; | 59 | return this.userInfo && this.userInfo.sid; | 
| 56 | let lan = this.$i18n.locale; | 60 | }, | 
| 57 | switch (lan) { | 61 | gotoVhis() { | 
| 58 | case 'zh': | 62 | let url = process.env.VUE_APP_VHIS_INDEX; | 
| 59 | url += "?language=zh-cn"; | 63 | let lan = this.$i18n.locale; | 
| 60 | break; | 64 | switch (lan) { | 
| 61 | case 'en': | 65 | case 'zh': | 
| 62 | url += "?language=en"; | 66 | url += "?language=zh-cn"; | 
| 63 | break; | 67 | break; | 
| 64 | default: | 68 | case 'en': | 
| 65 | url += "?language=zh-hk"; | 69 | url += "?language=en"; | 
| 66 | break; | 70 | break; | 
| 67 | } | 71 | default: | 
| 68 | url += "&partnerId=PA001&productCode=VHIS001"; | 72 | url += "?language=zh-hk"; | 
| 69 | if (this.information && this.information.idType && this.information.idNo) { | 73 | break; | 
| 70 | let data = { | 74 | } | 
| 71 | name: this.information.fullName, | 75 | url += "&partnerId=PA001&productCode=VHIS001"; | 
| 72 | gender: this.information.sex, | 76 | if (this.information && this.information.idType && this.information.idNo) { | 
| 73 | birthday: this.information.birthDate, | 77 | let data = { | 
| 74 | certiType: this.information.policyIdType ? this.information.policyIdType : this.information.idType, | 78 | name: this.information.fullName, | 
| 75 | certiNo: this.information.idNo | 79 | gender: this.information.sex, | 
| 76 | }; | 80 | birthday: this.information.birthDate, | 
| 77 | url += "&data=" + encryptContent(data); | 81 | certiType: this.information.policyIdType ? this.information.policyIdType : this.information.idType, | 
| 78 | } | 82 | certiNo: this.information.idNo | 
| 79 | // url = "http://www.baidu.com" | 83 | }; | 
| 80 | // console.log("vhis:", url); | 84 | url += "&data=" + encryptContent(data); | 
| 81 | this.outsideUrl = url; | 85 | } | 
| 82 | } | 86 | // url = "http://www.baidu.com" | 
| 83 | }, | 87 | // console.log("vhis:", url); | 
| 84 | watch: { | 88 | this.outsideUrl = url; | 
| 85 | }, | 89 | } | 
| 86 | mounted() { | 90 | }, | 
| 87 | this.init(); | 91 | watch: {}, | 
| 88 | // let url = this.$route.query.p; | 92 | mounted() { | 
| 89 | // if (url) { | 93 | this.init(); | 
| 90 | // this.outsideUrl = url; | 94 | // let url = this.$route.query.p; | 
| 91 | // setTimeout(() => { | 95 | // if (url) { | 
| 92 | // var iframe = document.getElementById("myiframe"); | 96 | // this.outsideUrl = url; | 
| 93 | // try { | 97 | // setTimeout(() => { | 
| 94 | // var bHeight = iframe.contentWindow.document.body.scrollHeight; | 98 | // var iframe = document.getElementById("myiframe"); | 
| 95 | // var dHeight = iframe.contentWindow.document.documentElement.scrollHeight; | 99 | // try { | 
| 96 | // var height = Math.min(bHeight, dHeight); | 100 | // var bHeight = iframe.contentWindow.document.body.scrollHeight; | 
| 97 | // iframe.height = height + 50; | 101 | // var dHeight = iframe.contentWindow.document.documentElement.scrollHeight; | 
| 98 | // } catch (ex) { | 102 | // var height = Math.min(bHeight, dHeight); | 
| 99 | // } | 103 | // iframe.height = height + 50; | 
| 100 | // }, 500); | 104 | // } catch (ex) { | 
| 101 | // } | 105 | // } | 
| 102 | }, | 106 | // }, 500); | 
| 103 | created() { | 107 | // } | 
| 104 | } | 108 | |
| 109 | window.removeEventListener("message"); | ||
| 110 | window.addEventListener('message', function (e) { | ||
| 111 | let height = e.data ? e.data.height : null; | ||
| 112 | if (height) { | ||
| 113 | var iframe = document.getElementById("myiframe"); | ||
| 114 | try { | ||
| 115 | iframe.height = height; | ||
| 116 | iframe.style.height = height + "px"; | ||
| 117 | } catch (ex) {} | ||
| 118 | } | ||
| 119 | }); | ||
| 120 | }, | ||
| 121 | created() {} | ||
| 105 | } | 122 | } | ... | ... | 
| ... | @@ -3,4 +3,10 @@ | ... | @@ -3,4 +3,10 @@ | 
| 3 | .content iframe{ | 3 | .content iframe{ | 
| 4 | height: 100%; | 4 | height: 100%; | 
| 5 | min-height: 800px; | 5 | min-height: 800px; | 
| 6 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | 
| 6 | overflow-x: hidden; | ||
| 7 | overflow-y: auto; | ||
| 8 | } | ||
| 9 | |||
| 10 | // .content::-webkit-scrollbar { | ||
| 11 | // display: none; | ||
| 12 | // } | ... | ... | 
| ... | @@ -3,7 +3,8 @@ | ... | @@ -3,7 +3,8 @@ | 
| 3 | <div class="content"> | 3 | <div class="content"> | 
| 4 | 4 | ||
| 5 | <auth @onLogout="userLogout" v-show="false"></auth> | 5 | <auth @onLogout="userLogout" v-show="false"></auth> | 
| 6 | <iframe v-if="outsideUrl" id="myiframe" width="100%" height="100%" scrolling="yes" frameborder="0" :src="outsideUrl"></iframe> | 6 | |
| 7 | <iframe v-if="outsideUrl" id="myiframe" width="100%" height="100%" scrolling="yes" frameborder="0" :src="outsideUrl"></iframe> | ||
| 7 | </div> | 8 | </div> | 
| 8 | </template> | 9 | </template> | 
| 9 | 10 | ... | ... | 
- 
Please register or sign in to post a comment