123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>大卫博士-代理商授权查询</title>
- <script src="./js/vue@2.6.12.js"></script>
- <script src="./js/axios.min.js"></script>
- <script src="./js/pxtorem.js"></script>
- <style>
- * {
- margin: 0;
- padding: 0;
- }
- html, body, .container{
- width: 100%;
- height: 100%;
- user-select: none;
- overflow: hidden;
- }
- .container {
- background-image: url(./img/bg.png);
- background-repeat: no-repeat;
- background-size: cover;
- background-position: center;
- display: flex;
- align-items: center;
- justify-content: space-between;
- position: relative;
- }
- .LoginContainer {
- position: absolute;
- top: 50%;
- right: -5.36rem;
- width: 15.08rem;
- height: 15.08rem;
- border-radius: 50%;
- background: #ffffff;
- transform: translateY(-50%);
- }
- .Login-show {
- position: absolute;
- left: 0;
- top: 50%;
- transform: translateY(-50%);
- width: 9.72rem;
- }
- .Login-brand {
- width: calc(100% + 1.2rem);
- }
- .Login-brand> p:nth-of-type(1) {
- text-align: right;
- color: #333333;
- font-size: 0.46rem;
- margin-bottom: 0.05rem;
- font-weight: 500;
- }
- .Login-brand> p:nth-of-type(2) {
- color: #F5321D;
- font-size: 0.32rem;
- text-align: right;
- opacity: 0.3;
- }
- .Login-body {
- position: absolute;
- top: 50%;
- left: 0;
- transform: translateY(-50%);
- padding: 0.50rem 0.50rem 0.50rem 2.15rem;
- box-sizing: border-box;
- height: 100%;
- width: max-content;
- display: flex;
- flex-direction: column;
- justify-content: space-between;
- }
- .Login-title {
- width: 5.84rem;
- text-align: center;
- color: #333333;
- font-size: 0.68rem;
- font-weight: 500;
- text-align: center;
- margin-bottom: 0.05rem;
- }
- .Login-desc {
- width: 5.84rem;
- text-align: center;
- color: #333333;
- font-size: 0.34rem;
- font-weight: 400;
- text-align: center;
- margin-bottom: 0.60rem;
- }
- .login-input {
- width: 5.84rem;
- height: 0.90rem;
- line-height: 0.90rem;
- text-align: center;
- font-size: 0.28rem;
- border: 2px solid #F53C1E !important;
- border-radius: 4px;
- outline-color: #F53C1E !important;
- box-sizing: border-box;
- margin-bottom: 0.33rem;
- }
- .Login-btn {
- width: 5.84rem;
- height: 0.90rem;
- line-height: 0.90rem;
- text-align: center;
- color: #FFFFFF;
- font-size: 0.27rem;
- background: #F53C1E;
- border-radius: 4px;
- cursor: pointer;
- margin-bottom: 0.36rem;
- }
- .Login-tip {
- width: 5.84rem;
- text-align: center;
- color: #EA4A41;
- font-size: 0.20rem;
- text-align: center;
- }
- .Login-info {
- display: flex;
- align-items: flex-start;
- justify-content: flex-start;
- flex-direction: column;
- margin-top: 1.00rem;
- }
- .BrandContainer {
- padding-top: 1.40rem;
- padding-left: 0.80rem;
- padding-bottom: 0.30rem;
- height: 100%;
- box-sizing: border-box;
- display: flex;
- align-items: flex-start;
- justify-content: space-between;
- flex-direction: column;
- }
- .Brand-logo {
- display: block;
- height: 2.12rem;
- }
- .Brand-chengnuo {
- display: block;
- height: 3.73rem;
- margin-left: 0.50rem;
- }
- .Brand-start {
- width: calc(100% + 0.80rem);
- color: #ffffff;
- font-size: 0.18rem;
- text-align: right;
- margin-right: -0.20rem;
- }
- .Search-info {
- width: 5.52rem;
- margin-top: 0.67rem;
- }
- .Search-account {
- color: #333333;
- font-size: 0.24rem;
- margin-bottom: 0.20rem;
- text-align: center;
- width: 100%;
- }
- .Search-fixed-title {
- color: #F53C1E;
- font-size: 0.46rem;
- margin-bottom: 0.27rem;
- text-align: center;
- width: 100%;
- }
- .Search-fixed-desc {
- color: #333333;
- width: 80%;
- text-align: center;
- height: 0.25rem;
- font-size: 0.24rem;
- line-height: 0.25rem;
- background-image: url(./img/fixed_bg.png);
- background-size: 100% auto;
- background-position: center;
- background-repeat: no-repeat;
- margin: 0 auto;
- margin-bottom: 0.4rem;
- }
- .Member-info {
- width: 100%;
- list-style: none;
- margin-bottom: 0.50rem;
- }
- .Member-info>li {
- width: 100%;
- height: 0.70rem;
- display: flex;
- align-items: center;
- justify-content: space-between;
- border-bottom: 1px solid #EEEEEE;
- color: #333333;
- font-size: 0.28rem;
- }
- .Member-info>li .spec {
- color: #F53C1E;
- }
- .Secrch-see {
- width: 100%;
- height: 0.85rem;
- border-radius: 4px;
- color: #FFFFFF;
- font-size: 0.28rem;
- cursor: pointer;
- line-height: 0.85rem;
- text-align: center;
- background: #F53C1E;
- letter-spacing: 3px;
- }
- </style>
- </head>
- <body>
- <div id="app" class="container">
- <div class="BrandContainer">
- <img src="./img/logo.png" alt="" class="Brand-logo">
- <img src="./img/chengnuo.png" alt="" class="Brand-chengnuo">
- <p class="Brand-start">不变的承诺始于2014:90天——366天穿了不满意全额退款</p>
- </div>
- <div
- class="LoginContainer"
- ref="login"
- >
- <!-- :style="`height: %{ 1508 }`" -->
- <div class="Login-show" :style="`height:${screenH}px`">
- <div class="Login-body">
- <!-- <div class="Login-brand">
- <p>大卫博士</p>
- <p>Dr. David</p>
- </div> -->
- <div v-if="!status" class="Login-info">
- <p class="Login-title">代理商授权查询</p>
- <p class="Login-desc">Authorization query</p>
- <input v-model="phone" type="text" placeholder="请输入代理商手机号" class="login-input">
- <p class="Login-btn" @click="toSearch">立即查询</p>
- <p class="Login-tip">未查询到代理商信息,请勿轻易转款,谨防受骗受骗</p>
- </div>
- <div v-else class="Login-info Search-info">
- <p class="Search-account">账户{{ phone }}是</p>
- <p class="Search-fixed-title">大卫博士授权代理商</p>
- <p class="Search-fixed-desc">代理信息</p>
- <ul class="Member-info">
- <li>
- <p>级 别:</p>
- <p>{{ memberInfo.level }}</p>
- </li>
- <li>
- <p>昵 称:</p>
- <p>{{ memberInfo.wechat }}</p>
- </li>
- <li>
- <p>姓 名:</p>
- <p>{{ memberInfo.realname }}</p>
- </li>
- <li>
- <p>身份证号:</p>
- <p>{{ memberInfo.num | showCradNum }}</p>
- </li>
- <li>
- <p>授权状态</p>
- <p :class="memberInfo.status === 1 ? 'spec' : ''">{{ memberInfo.status === 1 ? '已授权' : '已过期' }}</p>
- </li>
- </ul>
- <p class="Secrch-see" @click="toSeeAuth">查看授权书</p>
- </div>
- <p style="opacity: 0">1</p>
- </div>
- </div>
- </div>
- </div>
- </body>
- <script>
- var app = new Vue({
- el: '#app',
- data() {
- return {
- screenH: 0,
- phone: '',
- status: false,
- memberInfo: {}
- }
- },
- filters: {
- showCradNum(str) {
- if (!str) {
- return ''
- }
- let arr = str.split('')
- if (arr.length === 18) {
- arr.splice(6, 8, 'xxxx')
- return arr.join('')
- } else if (arr.length === 15) {
- arr.splice(6, 6, 'xxxx')
- return arr.join('')
- } else {
- return str
- }
- },
- },
- mounted() {
- this.getScreenH()
- let _this = this
- window.onresize = function() {
- _this.getScreenH()
- }
- },
- methods:{
- getScreenH() {
- this.screenH = document.body.clientHeight
- let _W = document.body.clientWidth
- ratio = (1920 / _W).toFixed(2)
- this.$refs.login.setAttribute('style', `width: ${15 * ratio}rem; height: ${15 * ratio}rem; right: -${570 * ratio}px`)
- },
- toSearch() {
- if(!this.phone) {
- alert('请输入要查询的手机号')
- return false
- }
- axios.get("http://api.app.jiuweiyun.cn/api/user/auth_sel", {
- params: {
- phone: this.phone
- }
- }).then(res => {
- if(res.code === 200) {
- const { status } = res.data;
- if (status !== 3) {
- this.status = true
- this.memberInfo = res.data
- } else {
- alert(res.msg || '手机号未授权')
- }
- } else {
- alert('查询失败')
- }
- }).catch(() => {
- alert('服务器发生错误,查询失败')
- })
- },
- toSeeAuth() {
- axios.get("http://api.app.jiuweiyun.cn/api/user/auth_show", {
- params: {
- phone: this.phone
- }
- }).then(res => {
- if(res.code === 200){
- const { url } = res.data
- window.open(url, '_target')
- } else {
- alert(res.msg || '查看授权书失败')
- }
- }).catch(() => {
- alert('服务器发生错误,查看授权书失败')
- })
- }
- }
- })
- </script>
- </html>
|