DESKTOP-CVS3R96\我恁爹
2022-11-06 4cf29de231ee3503c48e0c1d098dab795091ff46
11.6
17 files modified
1 files deleted
23 files added
18961 ■■■■■ changed files
config/index.js 2 ●●● patch | view | raw | blame | history
index.html 84 ●●●● patch | view | raw | blame | history
package-lock.json 17387 ●●●●● patch | view | raw | blame | history
src/App.vue 109 ●●●●● patch | view | raw | blame | history
src/assets/css/black.css patch | view | raw | blame | history
src/assets/foot/ic_mine_history.webp patch | view | raw | blame | history
src/assets/foot/tab_main_home_default.png patch | view | raw | blame | history
src/assets/foot/tab_main_mine_default.png patch | view | raw | blame | history
src/assets/foot/tab_main_positions_default.png patch | view | raw | blame | history
src/assets/foot/tab_main_trade_default.png patch | view | raw | blame | history
src/assets/foot/新建文件夹/tab_main_mine_default(1).png patch | view | raw | blame | history
src/assets/foot/新建文件夹/tab_main_mine_default.png patch | view | raw | blame | history
src/assets/home/1.png patch | view | raw | blame | history
src/assets/home/2.png patch | view | raw | blame | history
src/assets/home/3.png patch | view | raw | blame | history
src/assets/home/4.png patch | view | raw | blame | history
src/assets/home/close.png patch | view | raw | blame | history
src/assets/home/desktop.ini 2 ●●●●● patch | view | raw | blame | history
src/assets/home/huo.png patch | view | raw | blame | history
src/assets/home/icon_talk.png patch | view | raw | blame | history
src/assets/home/search.png patch | view | raw | blame | history
src/assets/img/apple.png patch | view | raw | blame | history
src/assets/img/back.png patch | view | raw | blame | history
src/assets/img/black_laba.png patch | view | raw | blame | history
src/assets/img/huo.png patch | view | raw | blame | history
src/assets/img/icon_home_logo.png patch | view | raw | blame | history
src/assets/img/src - 快捷方式.lnk patch | view | raw | blame | history
src/assets/img/tops.png patch | view | raw | blame | history
src/axios/api.js 5 ●●●●● patch | view | raw | blame | history
src/axios/api.url.js 6 ●●●● patch | view | raw | blame | history
src/components/foot.vue 10 ●●●● patch | view | raw | blame | history
src/page/home/components/GoLogin.vue 18 ●●●● patch | view | raw | blame | history
src/page/home/futures-buy.vue 1 ●●●● patch | view | raw | blame | history
src/page/home/home.vue 378 ●●●● patch | view | raw | blame | history
src/page/home/newGg.vue 112 ●●●●● patch | view | raw | blame | history
src/page/home/newPage.vue 72 ●●●● patch | view | raw | blame | history
src/page/login/components/header.vue 51 ●●●●● patch | view | raw | blame | history
src/page/login/login.vue 261 ●●●● patch | view | raw | blame | history
src/page/login/register.vue 403 ●●●● patch | view | raw | blame | history
src/router/index.js 59 ●●●●● patch | view | raw | blame | history
src/store/index.js 1 ●●●● patch | view | raw | blame | history
config/index.js
@@ -14,7 +14,7 @@
      '/': {
        // target: 'https://pc.zsycyy.com',
        // target: 'http://www.shehua56.com',
        target:'http://192.168.10.12:8091/',
        target:'http://156.226.16.4:8091/',
        secure: false,
        changeOrigin: true,
        pathRewrite: {
index.html
@@ -6,68 +6,34 @@
  <title>首页</title>
  <link rel="shortcut icon" href=./favicon.ico type=image/x-icon>
  <link href="static/css/public1.css" rel="stylesheet">
  <script type="text/javascript">
    // 设置跟元素字体
    document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + 'px'
    // var styleName = window.localStorage.getItem('styleName')
    // if(styleName == 'black'){
    //   document.getElementsByTagName('body')[0].className = 'black-bg'
    // }else{
    //   document.getElementsByTagName('body')[0].className = 'red-bg'
    // }
    //步骤一:创建异步对象
    var ajax = new XMLHttpRequest()
    //步骤二:设置请求的url参数,参数一是请求的类型,参数二是请求的url,可以带参数,动态的传递参数starName到服务端
    ajax.open('get', 'http://192.168.10.12:8091/api/site/getInfo.do')
    //步骤三:发送请求
    ajax.send()
    //步骤四:注册事件 onreadystatechange 状态改变就会调用
    ajax.onreadystatechange = function () {
      if (ajax.readyState == 4 && ajax.status == 200) {
        //步骤五 如果能够进到这个判断 说明 数据 完美的回来了,并且请求的页面是存在的
        //     console.log(JSON.parse(ajax.responseText).data);//输入相应的内容
        var styleName = JSON.parse(ajax.responseText).data.siteColor
        // var styleName = window.localStorage.getItem('styleName')
        if (styleName == 'black') {
          window.localStorage.setItem('styleName', 'black')
          document.getElementsByTagName('body')[0].className = 'black-bg'
        } else if (styleName == 'yellow') {
          window.localStorage.setItem('styleName', 'red')
          document.getElementsByTagName('body')[0].className = 'yellow-bg'
        } else {
          window.localStorage.setItem('styleName', 'red')
          document.getElementsByTagName('body')[0].className = 'red-bg'
        }
      }
    }
  </script>
  <script>
      // // 禁用缩放
      // function addMeta() {
      //     $('head').append('<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />');
      // }
      // setTimeout(addMeta, 3000);
      // 禁用缩放
      function addMeta() {
          $('head').append('<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />');
      }
      setTimeout(addMeta, 3000);
      // // 禁用双指放大
      // document.documentElement.addEventListener('touchstart', function (event) {
      //     if (event.touches.length > 1) {
      //         event.preventDefault();
      //     }
      // }, {
      //     passive: false
      // });
      // 禁用双指放大
      document.documentElement.addEventListener('touchstart', function (event) {
          if (event.touches.length > 1) {
              event.preventDefault();
          }
      }, {
          passive: false
      });
      // // 禁用双击放大
      // var lastTouchEnd = 0;
      // document.documentElement.addEventListener('touchend', function (event) {
      //     var now = Date.now();
      //     if (now - lastTouchEnd <= 300) {
      //         event.preventDefault();
      //     }
      //     lastTouchEnd = now;
      // }, {
      //     passive: false
      // });
      // 禁用双击放大
      var lastTouchEnd = 0;
      document.documentElement.addEventListener('touchend', function (event) {
          var now = Date.now();
          if (now - lastTouchEnd <= 300) {
              event.preventDefault();
          }
          lastTouchEnd = now;
      }, {
          passive: false
      });
    </script>
</head>
<body style="height: 100%; position: absolute; width: 100%;">
package-lock.json
Diff too large
src/App.vue
@@ -1,14 +1,18 @@
<template>
  <div id="app" :class="`${$state.theme === 'red' ? 'red-theme' : 'black-theme'}`">
    <div :class="`header-box`" v-if="hasHeader && title !== '新登录'">
    <div :class="`header-box`" v-if="hasHeader && title !== '用户登录'">
      <mt-header :title="title">
        <mt-button icon="back" slot="left" @click="$router.go(-1)"></mt-button>
        <div v-if="!is_Show">
        <template v-if="iconRight == 'search'">
          <img slot="right" class="search-right" src="./assets/ico/fangdajing.png" alt />
        </template>
        <template v-else>
          <mt-button icon="more" slot="right"></mt-button>
        </template>
        </div>
      </mt-header>
    </div>
    <div class="body-box">
@@ -18,7 +22,7 @@
        <router-view></router-view>
      </transition>
    </div>
    <foot></foot>
    <foot v-if="$store.state.select!='/login'&&$store.state.select!='/register'"></foot>
  </div>
</template>
@@ -30,9 +34,15 @@
    },
  name: "App",
  created() {
      this.$state.theme="red";
      console.log(this.$state.theme,"asdasdasd")
    let title = this.$route.meta.title || "首页";
    this.title = title;
    if(this.$route.meta.is_Show){
      this.is_Show = this.$route.meta.is_Show;
    }else{
      this.is_Show = true;
    }
    if (this.$route.meta.hasHeader) {
      this.hasHeader = true;
    } else {
@@ -47,6 +57,7 @@
  },
  watch: {
    $route(to, from) {
      let title = to.meta.title || "首页";
      this.title = title;
      if (to.meta.iconRight) {
@@ -59,6 +70,7 @@
      } else {
        this.hasHeader = false;
      }
      if (to.meta.index > from.meta.index) {
        console.log("slide-left");
        //设置动画名称
@@ -74,7 +86,9 @@
      title: "首页",
      hasHeader: false,
      iconRight: "default",
      transitionName: ''
      transitionName: '',
      is_Show:true,
      is_foot:true,
    };
  }
};
@@ -88,7 +102,7 @@
  font-family: "rubik";
  .header-box {
    width: 100%;
    height: 1rem;
    height: 1.4rem;
    /deep/.mint-header {
      height: 100%;
      background-color: #16171d;
@@ -109,27 +123,103 @@
  }
  .body-box {
    width: 100%;
    height: calc(100% - 1rem);
    height: 100%;
    // height: calc(100% - 1rem);
    box-sizing: border-box;
    overflow-y: auto;
  }
  &.red-theme {
    background: #e9e9e9;
    background: rgb(241,242,246);
    color:#000;
    /deep/.mint-header {
      background: none;
      .mint-header-title {
        font-size: 0.36rem;
        font-size: 0.42rem;
        color: #212121;
      }
      .mintui {
        color: #212121;
      }
    }
    /deep/.van-swipe-item {
    color: #000;
    }
    /deep/.navs_content {
        background: #fff!important;
    }
    /deep/.fo_content {
        background: #fff;
    }
    /deep/.news-tab{
        background: #fff;
    }
    /deep/.mint-tab-item-label {
      color: #000;
      font-size: .26rem;
    }
    /deep/.top_title{
        color: #000;
    }
    /deep/.titContent{
        color:#000;
    }
    /deep/.mint-navbar {
      background: #fff;
    }
    /deep/.mint-tab-item {
      background: #fff;
      border: none;
    }
    /deep/.footCss{
         background: #fff;
    }
  /deep/.newDetail-tits{
    color: #aaa;
  }
  /deep/.van-skeleton__row, .van-skeleton__title{
    background-color: #fff!important;
  }
  }
  &.black-theme {
    // background: #16171d;
    // background: rgb(14, 14, 15);
    background: rgb(33, 33, 43);
    /deep/.navs_content {
        background: #272733;
    }
    /deep/.fo_content {
        background: #272733;
    }
    /deep/.news-tab{
        background: #272733;
    }
    /deep/.mint-navbar {
      background: #272733;
    }
    /deep/.mint-tab-item-label {
      color: #fff;
      font-size: .26rem;
    }
    /deep/.titContent{
        color:#000;
    }
    /deep/.mint-tab-container {}
    /deep/.mint-tab-item {
      background: #272733;
    }
    /deep/.van-swipe-item {
    color: #000;
    }
    /deep/.footCss{
         background: rgb(33, 33, 43);
    }
    /deep/.newDetail-tits{
    color: #999;
  }
  }
}
.search-right {
@@ -139,4 +229,7 @@
.mint-search-list {
  position: relative !important;
}
.topLeft{
}
</style>
src/assets/css/black.css
src/assets/foot/ic_mine_history.webp
Binary files differ
src/assets/foot/tab_main_home_default.png
src/assets/foot/tab_main_mine_default.png
src/assets/foot/tab_main_positions_default.png
src/assets/foot/tab_main_trade_default.png
src/assets/foot/新建文件夹/tab_main_mine_default(1).png
src/assets/foot/新建文件夹/tab_main_mine_default.png
src/assets/home/1.png
src/assets/home/2.png
src/assets/home/3.png
src/assets/home/4.png
src/assets/home/close.png
src/assets/home/desktop.ini
New file
@@ -0,0 +1,2 @@
[LocalizedFileNames]
ic_close_float.webp=@ic_close_float.webp,0
src/assets/home/huo.png
src/assets/home/icon_talk.png
src/assets/home/search.png
src/assets/img/apple.png
src/assets/img/back.png
src/assets/img/black_laba.png
src/assets/img/huo.png
Binary files differ
src/assets/img/icon_home_logo.png
src/assets/img/src - 快捷方式.lnk
Binary files differ
src/assets/img/tops.png

src/axios/api.js
@@ -389,6 +389,11 @@
  return get(`/api/news/getNewsList.do?pageNum=1&pageSize=15&type=${type}`, {})
}
// 查询新闻详情
export function queryNewsDetail (type) {
  return get(`/api/news/getDetail.do?id=${type}`, {})
}
// 配资申请-用户配资列表
export function getUserApplyList (options) {
  return post('/user/funds/getUserApplyList.do', options)
src/axios/api.url.js
@@ -1,11 +1,11 @@
const ENV = process.env.NODE_ENV
export default {
  DOMAIN: 'http://192.168.10.12:8091/',
  baseURL: ENV == 'development'?'http://192.168.10.12:8091/':'http://192.168.10.12:8091/',
  DOMAIN: 'http://156.226.16.4:8091/',
  baseURL: ENV == 'development'?'http://156.226.16.4:8091/':'http://156.226.16.4:8091/',
  // baseURL: 'http://localhost:8070',
  /* Util API */
  baseURL: 'http://192.168.10.12:8091/',
  baseURL: 'http://156.226.16.4:8091/',
  util: {
    image: '/util/image.html' // 图片上传
  }
src/components/foot.vue
@@ -7,7 +7,7 @@
        </div>
      </div>
      <div v-show="$store.state.select != '/home'" class="footImgDeft">
        <img src="~@/assets/foot/home_default.png" />
        <img src="~@/assets/foot/tab_main_home_default.png" />
      </div>
      <div v-show="$store.state.select != '/home'">首页</div>
    </div>
@@ -15,21 +15,21 @@
      <div class="footImgDeft">
        <img v-show="$store.state.select == '/list'" src="~@/assets/foot/trade_selected.png" />
        <img v-show="$store.state.select != '/list'" src="~@/assets/foot/trade_default.png" />
        <img v-show="$store.state.select != '/list'" src="~@/assets/foot/tab_main_trade_default.png" />
      </div>
      <div :class="$store.state.select == '/list'?'blueFont':''">交易</div>
    </div>
    <div :class="touch==3?'footDemos':'footDemo'" @click="goRouter('/orderlist',3)">
      <div class="footImgDeft">
        <img v-show="$store.state.select == '/orderlist'" src="~@/assets/foot/positions_selected.png" />
        <img v-show="$store.state.select != '/orderlist'" src="~@/assets/foot/positions_default.png" />
        <img v-show="$store.state.select != '/orderlist'" src="~@/assets/foot/tab_main_positions_default.png" />
      </div>
      <div :class="$store.state.select == '/orderlist'?'blueFont':''">仓位</div>
    </div>
    <div :class="touch==4?'footDemos':'footDemo'" @click="goRouter('/user',4)">
      <div class="footImgDeft">
        <img v-show="$store.state.select == '/user'" src="~@/assets/foot/mine_selected.png" />
        <img v-show="$store.state.select != '/user'" src="~@/assets/foot/mine_default.png" />
        <img v-show="$store.state.select != '/user'" src="~@/assets/foot/tab_main_mine_default.png" />
      </div>
      <div :class="$store.state.select == '/user'?'blueFont':''">我的</div>
    </div>
@@ -66,7 +66,7 @@
<style>
  .footCss {
    border-top: 0.01rem solid rgba(192, 192, 192, 0.1);
    background: rgb(33, 33, 43);
    position: fixed;
    bottom: 0;
    width: 100%;
src/page/home/components/GoLogin.vue
@@ -1,5 +1,5 @@
<template>
    <div class="go_to_login">
    <div class="go_to_login animated bounce">
        <div>
            <div class="left_mess"><span>{{ '登录后即可开启真实/模拟交易' }}</span></div>
            <div class="right_button">
@@ -19,7 +19,7 @@
    },
    methods: {
        goToLogin() {
            this.$router.push('/newLogin')
            this.$router.push('/login')
        }
    }
}
@@ -34,6 +34,8 @@
    display: flex;
    align-items: center;
    justify-content: center;
    > div {
        width: 90%;
        height: 100%;
@@ -72,5 +74,17 @@
        }
    }
}
//淡入动画
@keyframes show {
    0% {
        buttom:0rem;
    }
    100% {
        buttom:2rem;
    }
}
</style>
src/page/home/futures-buy.vue
@@ -293,6 +293,7 @@
      // 价钱 * 汇率 转为 人民币
      return (this.total * this.exchangeNumber).toFixed(2)
    },
    price () {
      if (this.autoNumber) {
        return (this.detail.eachPoint * this.autoNumber * 100).toFixed(2)
src/page/home/home.vue
@@ -12,7 +12,7 @@
            <div class="search_con" @click="handleSearchClick()">
              <img :src="Searchs" alt />
            </div>
            <div class="service_con">
            <div class="service_con" @click="goOnline()">
              <img :src="Service" alt />
            </div>
          </div>
@@ -21,30 +21,38 @@
      <div class="center_tabs">
        <!-- 顶部轮播图 -->
        <div class="banner_top">
          <van-skeleton title :row="1" :loading="loading" />
          <van-skeleton title :row="3" :loading="loading" />
          <van-swipe class="my-swipe" :autoplay="5000" indicator-color="white" v-if="!loading">
            <van-swipe-item v-for="(item, index) in bannerImgsArr" @click="handleBannerClick(index)" :key="index">
              <img :src="item.img" alt />
            <van-swipe-item v-for="(item, index) in bannerList" @click="handleBannerClick(index)" :key="index">
              <img :src="item.bannerUrl" alt />
            </van-swipe-item>
          </van-swipe>
        </div>
        <!-- 公告 -->
        <div class="announcement">
          <div class="an_content">
        <van-skeleton title :row="1" :loading="loading" />
        <div class="announcement" v-if="!loading&&close">
          <div class="an_content" @click="$router.push('/newGg')">
            <div class="an_left_icon">
              <img :src="Announcement" alt />
            </div>
            <div class="an_right_message">
              <span>{{ announcementMess }}</span>
              {{ artList.artTitle }}
            </div>
          </div>
        </div>
        <!-- 排行入门 -->
        <van-skeleton title :row="2" :loading="loading" />
        <div class="navs" v-if="!loading">
        <div class="navs" v-if="!loading&&close">
          <div class="navs_content">
            <div v-for="(item, index) in navsArr" :key="index">
            <div class="chacha" @click="close=false">
              <div>
                <img :src="clear" />
              </div>
            </div>
            <div v-for="(item, index) in navsArr" :key="index" @click="goJy(index)">
              <div>
                <div class="top_img">
                  <div>
@@ -63,11 +71,11 @@
        <div class="focus_on" v-if="!loading">
          <div class="fo_content">
            <div class="top_title">
              <span>{{ '最多关注' }}</span>
              {{ '最多关注' }}
            </div>
            <div class="fo_banner">
              <van-swipe class="fo_my-swipe" :autoplay="0" indicator-color="white" @change="onChange">
                <van-swipe-item v-for="(item, index)  in proData" :key="index" style="margin-top: 20px;">
                <!-- <van-swipe-item v-for="(item, index)  in proData" :key="index">
                  <div class="item_cont" v-for="(item2, idx) in proData[currentIndex]" :key="idx">
                    <div class="top_fo" style="width: 80%;">
                      <div class="title" style="width: 30%;">
@@ -78,22 +86,56 @@
                        <span>{{ item2.f3 > 0 ? `+${item2.f3}%` : `${item2.f3}%` }}</span>
                      </div>
                      <div class="percentage"></div>
                      <div class="percentage" style="width: 38%;position: absolute;right: 0;" :class="item2.f3 > 0 ? 'gree' : 'redd'">
                      <div class="percentage" style="width: 38%;position: absolute;right: 0;top: 5%;height: 80%;" :class="item2.f3 > 0 ? 'gree' : 'redd'">
                        <echart :colorType="item2.f3" :ids="idx+'1'+index"></echart>
                      </div>
                    </div>
                    <div class="bottom_fo" style="width: 80%;">
                      <div class="title"style="width: 30%;">
                        <span>{{ item2.f12 }}</span>
                        <img :src="Huo" alt style="margin-left: 0.12rem;" />
                        <span style="margin-right: 0.12rem;">{{ item2.f12 }}</span>
                        <img v-for="item in getHuo()" :src="Huo" alt style="width: 0.4rem;height: 0.4rem;" />
                      </div>
                      <div  class="percentage" >
                      <!-- class="numbers" -->
                        <!-- <span>{{ '04:59:57' }}</span> -->
                        <span>{{ item2.f2 }}</span>
                      </div>
                      <div class="percentage">
                        <span></span>
                      </div>
                    </div>
                  </div>
                </van-swipe-item> -->
                <van-swipe-item v-for="(item, index)  in proData" :key="index">
                  <div class="item_cont" :class="idx!=2?'item_conts':''" v-for="(item2, idx) in proData[currentIndex]" :key="idx">
                    <div class="top_fo">
                      <div class="title">
                        {{ item2.indexName }}
                      </div>
                      <div class="numbers">
                        {{ item2.currentPoint }}
                      </div>
                      <div class="percentage" :class="item2.floatRate > 0 ? 'gree' : 'redd'">
                        <span style="font-weight: 500;">{{ item2.floatRate > 0 ? `+${item2.floatRate}%` :
                            `${item2.floatRate}%`
                        }}</span>
                      </div>
                    </div>
                    <div class="bottom_fo">
                      <div class="title">
                        <span class="numberid" style="margin-right: 0.12rem;">{{ item2.indexCode }}</span>
                        <img v-for="items in item2.random" :src="Huo" alt style="width: 0.4rem;height: 0.4rem;" />
                      </div>
                      <div class="numbers" :class="item2.floatPoint > 0 ? 'gree' : 'redd'">
                        <span class="point">{{ item2.floatPoint > 0 ? `+${item2.floatPoint}%` : `${item2.floatPoint}%`
                        }}</span>
                      </div>
                      <div class="percentage">
                        <!-- <span class="aikesi">100X</span> -->
                        <el-tag key="100X"
                          style="width: 80%;text-align: center;height: 0.45rem!important;line-height: 0.45rem!important;">
                          {{ getNum1(item2.random) + 'X' }}
                        </el-tag>
                      </div>
                    </div>
                  </div>
@@ -110,18 +152,20 @@
            <span class="tab-name">新闻</span>
          </mt-tab-item>
          <mt-tab-item id="tab_1">
            <span class="tab-name">7×24</span>
            <span class="tab-name">经济</span>
          </mt-tab-item>
          <mt-tab-item id="tab_2">
            <span class="tab-name">经济</span>
            <span class="tab-name">7×24</span>
          </mt-tab-item>
        </mt-navbar>
        <mt-tab-container v-model="news" :swipeable="true" style="padding-top: 0.5rem;">
          <mt-tab-container-item id="tab_0">
            <div class="news-content">
              <div class="" v-for="(item,inde) in newsContent1" :key="inde" @click="$router.push({path:'/newPage',query:{
              <div class="" v-for="(item, inde) in newsContent1" :key="inde" @click="$router.push({
                path: '/newPage', query: {
                listid:item.id
              }})">
                }
              })">
                <div class="item-times">{{item.addTime | gettime}}</div>
                <div class="titContent" style="-webkit-box-orient: vertical;font-size: 0.38rem;margin-top: 0.2rem;">
                  {{item.title}}
@@ -135,7 +179,11 @@
          </mt-tab-container-item>
          <mt-tab-container-item id="tab_1">
            <div class="news-content">
              <div class="item-out" v-for="(item,inde) in newsContent4" :key="inde" @click="$router.push('/newPage')">
              <div class="item-out" v-for="(item, inde) in newsContent4" :key="inde" @click="$router.push({
                path: '/newPage', query: {
                  listid: item.id
                }
              })" >
                <div class="item-times">{{item.addTime | gettime}}</div>
                <div class="titContent" style="-webkit-box-orient: vertical;">{{item.title}}</div>
              </div>
@@ -143,7 +191,11 @@
          </mt-tab-container-item>
          <mt-tab-container-item id="tab_2">
            <div class="news-content">
              <div class="item-out" v-for="(item,inde) in newsContent2" :key="inde">
              <div class="item-out" v-for="(item, inde) in newsContent2" :key="inde" @click="$router.push({
                path: '/newPage', query: {
                  listid: item.id
                }
              })">
                <div class="item-times">{{item.addTime | gettime}}</div>
                <div class="titContent" style="-webkit-box-orient: vertical;">{{item.title}}</div>
              </div>
@@ -154,7 +206,7 @@
    </div>
    <!-- tab -->
    <GoToLogin />
    <GoToLogin v-show="isGoTo" />
  </div>
</template>
@@ -167,19 +219,20 @@
    Toast
  } from "mint-ui";
  import * as api from "@/axios/api";
  import Logo from "@/assets/img/logo.png";
  import Searchs from "@/assets/img/search.png";
  import Service from "@/assets/img/service.png";
  import Announcement from "@/assets/img/announcement.png";
  import Tops from "@/assets/img/tops.png";
  import Rumen from "@/assets/img/rumen.png";
  import Xuexi from "@/assets/img/xuexi.png";
  import Guanyu from "@/assets/img/guanyu.png";
  import Huo from "@/assets/img/huo.png";
import Logo from "@/assets/img/icon_home_logo.png";
import Searchs from "@/assets/home/search.png";
import Service from "@/assets/home/icon_talk.png";
import clear from "@/assets/home/close.png";
import Announcement from "@/assets/img/black_laba.png";
import Tops from "@/assets/home/1.png";
import Rumen from "@/assets/home/2.png";
import Xuexi from "@/assets/home/3.png";
import Guanyu from "@/assets/home/4.png";
import Huo from "@/assets/home/huo.png";
  import banner1 from "@/assets/img/b1.png";
  import banner2 from "@/assets/img/b2.png";
  import banner3 from "@/assets/img/b3.png";
  import indexData from "./data.json";
// import indexData from "./data.json";
  import GoToLogin from '@/page/home/components/GoLogin.vue';
  export default {
@@ -195,11 +248,13 @@
        Logo,
        Searchs,
        Service,
      clear,
        Announcement,
        indexData,
      indexData: [],
        Huo,
        is_login: false,
        loading: true,
      close:true,
        proData: [], // 分割好的数据
        currentIndex: 0,
        bannerImgsArr: [{
@@ -212,29 +267,106 @@
        announcementMess: "20202/10 - 交易时间安排",
        navsArr: [{
            img: Tops,
            title: "涨跌排行"
        title: "行情"
          },
          {
            img: Rumen,
            title: "快速入门"
        title: "持仓"
          },
          {
            img: Xuexi,
            title: "进阶学习"
        title: "新股"
          },
          {
            img: Guanyu,
            title: "关于 Mitrade"
        title: "我的"
          }
        ],
      artList:[],
        news: "tab_0",
        newsContent1: [],
        newsContent2: [],
        newsContent3: [],
        newsContent4: [],
      onlineService: "",
      isGoTo: false,
      bannerList:[]
      };
    },
    methods: {
    getHuo() {
      //123随机
      var num = Math.floor(Math.random() * 3 + 1);
      return num;
    },
    //构造随机数列表  50 100 200
    getNum1(num) {
      if (num == 1) {
        return 50;
      } else if (num == 2) {
        return 100;
      } else if (num == 3) {
        return 200;
      }
    },
    goJy(index){
      switch (index) {
        case 0:
          this.$router.push('/list');
          break;
          case 1:
          this.$router.push('/orderlist');
          break;
          case 2:
          //this.$router.push();
          break;
          case 3:
          this.$router.push('/user');
          break;
        default:
          break;
      }
    },
    async getBanner () {
      // 获取显示的banner
      let result = await api.getBannerByPlat({ platType: 'm' })
      if (result.status === 0) {
        this.bannerList = result.data
      } else {
        Toast(result.msg)
      }
    },
    goOnline() {
      window.location.href = this.onlineService;
    },
    async getArtList(){
      let data = await api.getArtList();
      if(data.status == 0){
        this.artList = data.data.list[0];
      }
    },
    async getInfoSite() {
      let data = await api.getInfoSite()
      if (data.status === 0) {
        this.onlineService = data.data.onlineService
      } else {
        Toast(data.msg)
      }
    },
    async getStock() {
      let data = await api.getIndexMarket();
      for (var i = 0; i < data.data.length; i += 3) {
        this.proData.push(data.data.slice(i, i + 3));
      }
    },
      async getNewsList(type) {
        let data = await api.queryNewsList(type);
        
@@ -261,15 +393,16 @@
      },
      ProcessData() {
        // 把数据分割成三等份
        for (var i = 0; i < this.indexData.data.diff.length; i += 3) {
          this.proData.push(this.indexData.data.diff.slice(i, i + 3));
        }
      // for (var i = 0; i < this.indexData.data.diff.length; i += 3) {
      //   this.proData.push(this.indexData.data.diff.slice(i, i + 3));
      // }
      },
      onChange(index) {
        this.currentIndex = index;
        this.proData[index].forEach(item => {
          // console.log(item.f14);
        });
      },
      handleSearchClick() {
        this.loading = !this.loading;
@@ -310,15 +443,22 @@
      this.ProcessData();
    },
    mounted() {
    this.getInfoSite();
      this.getNewsList(1);
      this.getNewsList(2);
      this.getNewsList(4);
    this.getStock();
    this.getArtList();
    this.getBanner()
    setInterval(() => {
      this.isGoTo = !this.isGoTo
    }, 10000);
      setTimeout(() => {
        this.loading = false
      }, 1000)
    }, 2000)
    }
  };
</script>
@@ -326,9 +466,8 @@
  .wrapper {
    width: 100%;
    height: 100%;
    background: rgb(33, 33, 43);
    // background: #010101;
    // overflow: hidden;
    padding-top: .3128rem;
    .page_content {
@@ -364,7 +503,7 @@
      justify-content: flex-end;
      >div {
        width: 1.2821rem;
      width: 1.6221rem;
        height: 0.4615rem;
        display: flex;
        justify-content: space-between;
@@ -385,7 +524,7 @@
  .center_tabs {
    width: 100%;
    height: 14.2308rem;
  height: auto;
    margin-top: 0.2308rem;
    >.banner_top {
@@ -397,33 +536,40 @@
      }
      .van-swipe-item {
        height: 3.4615rem;
      height: 3.0615rem;
        padding: 0 0.264rem;
      border-radius: 0.3rem;
    }
    .van-swipe-item img {
      border-radius: 0.3rem;
      }
    }
    >.announcement {
      width: 100%;
      height: 0.9487rem;
    height: auto;
      display: flex;
      justify-content: center;
      align-items: center;
    padding: 0.2rem 0 0.2rem 0;
      >.an_content {
        width: 95%;
        height: 0.559rem;
        display: flex;
        justify-content: space-between;
      align-items: center;
        .an_left_icon {
          width: 5%;
          height: 100%;
        height: 70%;
          display: flex;
          align-items: center;
          >img {
            width: 80%;
            height: 80%;
          width: 100%;
          height: 100%;
          }
        }
@@ -432,6 +578,8 @@
          height: 100%;
          display: flex;
          align-items: center;
        align-content: center;
        font-size: 0.29rem;
        }
      }
    }
@@ -439,15 +587,44 @@
    .navs {
      width: 100%;
      height: 2.6154rem;
      display: flex;
      justify-content: center;
      >.navs_content {
      position: relative;
      overflow: hidden;
        width: 95%;
        height: 100%;
        background: #272733;
        border-radius: 0.2564rem;
        display: flex;
      >.chacha {
        width: 1rem;
        height: 1rem;
        border-radius: 100%;
        background-color: rgb(210, 210, 212);
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: absolute;
        right: -0.4rem;
        top: -0.4rem;
        >div {
          width: 0.3554rem;
          height: 0.3554rem;
          margin-top: 0.3rem;
          margin-left: 0.15rem;
          >img {
            width: 100%;
            height: 100%;
          }
        }
      }
        >div {
          width: 25%;
@@ -483,6 +660,8 @@
              display: flex;
              justify-content: center;
              align-items: center;
            font-size: 0.33rem;
            margin-top: 0.15rem;
            }
          }
        }
@@ -491,7 +670,7 @@
    .focus_on {
      width: 100%;
      height: 6.9231rem;
    height: 6.4231rem;
      margin-top: 0.2564rem;
      display: flex;
      align-items: center;
@@ -500,35 +679,54 @@
      .fo_content {
        width: 95%;
        height: 100%;
        background: #272733;
        padding: 0 0.2564rem;
        border-radius: 0.2564rem;
      padding-top: 0.2rem;
        .top_title {
          width: 100%;
          height: 1.0821rem;
        height: 0.8821rem;
          display: flex;
          font-size: 0.3846rem;
        font-size: 0.4rem;
        font-weight: 800;
          align-items: center;
        }
      }
    /deep/.van-swipe__indicators {
      bottom: 0.1rem;
    }
    /deep/.van-swipe__indicator {
      background-color: #2d8cf0 !important;
      opacity: 1;
    }
    /deep/.van-swipe__indicator--active {
      width: 0.35rem !important;
      border-radius: 0.23rem;
      background-color:  #aec7ec!important;
    }
      .fo_banner {
        width: 100%;
        height: calc(100% - 1.0821rem - 0.2564rem);
      height: calc(100% - .8821rem - 0.3rem);
      }
    }
    .item_cont {
      width: 100%;
      height: 1.5385rem;
      border-bottom: 1px solid #ccc;
    border-bottom: 0.5px solid #ececec;
      position: relative;
      border: none;
    display: flex;
    flex-wrap: wrap;
    align-content: center;
      >div {
        width: 100%;
        height: 50%;
      height: 30%;
      }
      .top_fo,
@@ -545,6 +743,24 @@
          height: 100%;
          display: flex;
          align-items: center;
        font-weight: 500;
      }
      .aikesi {
        width: auto;
        height: 0.3rem;
        background: #dbe3f0;
        color: #546daf;
        padding-left: 0.2rem;
        padding-right: 0.2rem;
        font-size: 0.15rem;
        line-height: 0.3rem;
        margin-right: 0.1rem;
      }
      .numberid {
        font-size: 0.28rem;
        }
        .numbers {
@@ -552,6 +768,12 @@
          height: 100%;
          display: flex;
          align-items: center;
      }
      .point {
        font-size: 0.28rem;
        }
        .percentage {
@@ -567,25 +789,26 @@
      }
      .bottom_fo {
      margin-top: 0.1rem;
        font-size: 0.1846rem;
        color: #999898;
      }
      .percentage.gree {
        color: green;
      color: green !important;
      }
      .percentage.redd {
        color: red;
      color: red !important;
      }
    }
  }
  .item_cont::after {
.item_conts::after {
    content: "";
    position: absolute;
    bottom: 0;
    background: rgb(59, 59, 59);
  background: #ececec;
    width: 100%;
    height: 1px;
    -webkit-transform: scaleY(0.5);
@@ -595,7 +818,7 @@
  }
  .my-swipe .van-swipe-item {
    color: #fff;
    font-size: 0.5128rem;
    line-height: 3.8462rem;
    text-align: center;
@@ -603,7 +826,7 @@
  }
  .fo_my-swipe .van-swipe-item {
    color: #fff;
    font-size: 0.5128rem;
    line-height: 3.8462rem;
    overflow: hidden;
@@ -630,31 +853,19 @@
    right: 0;
    margin: auto;
    margin-top: 0.2rem;
    background: #272733;
    border-radius: 0.4rem 0.4rem 0 0;
    padding-top: 0.3rem;
    /deep/.mint-navbar {
      background: #272733;
    }
    /deep/.mint-tab-container {}
    /deep/.mint-tab-item {
      background: #272733;
    }
    /deep/.mint-tab-item-label {
      color: #fff;
      font-size: .26rem;
    }
    /deep/.is-selected .tab-name {
      position: relative;
    }
    /deep/.mint-navbar .mint-tab-item.is-selected {
    border: 0 !important;
      border-bottom: none;
    }
@@ -677,7 +888,7 @@
  .item-out {
    position: relative;
    border-left: 0.01rem solid rgba(192, 192, 192, 0.1);
  border-left: 0.01rem solid rgba(192, 192, 192, 0.8);
    padding: 0 0.25rem 1rem 0.25rem;
  }
@@ -685,7 +896,7 @@
    content: "●";
    position: absolute;
    top: -0.1rem;
    left: -0.108rem;
  left: -0.128rem;
    margin: auto;
  }
@@ -697,7 +908,6 @@
  .titContent {
    position: relative;
    width: 100%;
    color: #fff;
    font-size: .35rem;
    line-height: .46rem;
    overflow: hidden;
src/page/home/newGg.vue
New file
@@ -0,0 +1,112 @@
<template>
  <div :class="` ${$state.theme === 'red' ? 'red-theme' : 'black-theme'}`"  class="">
    <div class="newsTop">
      <div class="newsTitle">{{list.artTitle}}</div>
      <div class="newDetail-tits">{{ list.addTime| gettime}}</div>
    </div>
    <div class="newsDetail">
      <div style="white-space: pre-line;">{{list.artCnt}}</div>
      <div class="newsImg" v-if="list.artImg">
        <img :src="list.artImg"/>
      </div>
    </div>
  </div>
</template>
<script>
import * as api from "@/axios/api";
    export default {
    created() {
        if (this.$route.query.listid) {
          this.list_id = this.$route.query.listid;
        }
        this.getqueryNewsList(this.$route.query.listid);
    },
      data () {
          return{
        list_id:"",
        list:[],
          }},
      mounted(){
      },
      methods:{
     async getqueryNewsList(){
        let data = await api.getArtList();
          this.list = data.data.list[0]
      }
      },
    filters:{
      gettime(time) {
        if (!time) {
          return "";
        }
        var nd = new Date(time );
        var y = nd.getFullYear();
        var mm = nd.getMonth() + 1;
        var d = nd.getDate();
        var h = nd.getHours();
        var m = nd.getMinutes();
        var c = nd.getSeconds();
        if (mm < 10) {
          mm = "0" + mm;
        }
        if (d < 10) {
          d = "0" + d;
        }
        if (h < 10) {
          h = "0" + h;
        }
        if (m < 10) {
          m = "0" + m;
        }
        if (c < 10) {
          c = "0" + c;
        }
        //17:35:2922-06-2022
        return y + "-" + mm + "-" + d + " " + h + ":" + m + ":" + c;
      }
    },
      }
</script>
<style scoped lang="less">
  .newDetail-tits{
    margin-top: 0.4rem;
    font-size: 0.4rem;
    margin-bottom: 0.4rem;
  }
  .newsTop{
    border-bottom: 0.01rem solid #cdcdcd;
    padding-top: 0.3rem;
    color: #000;
    width: 96%;
    margin-left: 0;
    margin-right: 0;
    margin: 0 auto;
  }
  .newsTitle{
    font-size: 0.55rem;
    font-weight: 500;
  }
  .newsDetail{
    width: 96%;
    margin-left: 0;
    margin-right: 0;
    margin: 0 auto;
    margin-top: 0.4rem;
    font-size: 0.35rem;
    line-height: 0.6rem;
  }
  .newsImg{
    width: 100%;
    margin-top: 0.4rem;
  }
  .newsImg img{
    width: 100%;
    height: 100%;
  }
</style>
src/page/home/newPage.vue
@@ -1,35 +1,42 @@
<template>
  <div class="">
    <div class="header">
      <mt-header title="新闻">
        <router-link to="/user" slot="left">
          <mt-button icon="back"></mt-button>
        </router-link>
      </mt-header>
  <div :class="` ${$state.theme === 'red' ? 'red-theme' : 'black-theme'}`"  class="">
    <div class="newsTop">
      <div class="newsTitle">{{list.title}}</div>
      <div class="newDetail-tits">{{ list.addTime| gettime}}</div>
    </div>
    <div class="">
      <div>{{list.title}}</div>
      <div class="item-times">{{ | gettime}}</div>
    <div class="newsDetail">
      <div>{{list.content}}</div>
      <div class="newsImg" v-if="list.imgurl">
        <img :src="list.imgurl"/>
      </div>
    </div>
  </div>
</template>
<script>
import * as api from "@/axios/api";
    export default {
    created() {
        if (this.$route.query.id) {
          this.list_id = this.$route.query.id;
        if (this.$route.query.listid) {
          this.list_id = this.$route.query.listid;
        }
        this.getqueryNewsList(this.$route.query.listid);
    },
      data () {
          return{
        list_id:""
        list_id:"",
        list:[],
          }},
      mounted(){
      },
      methods:{
     async getqueryNewsList(id){
        let data = await api.queryNewsDetail(id);
          this.list = data.data
      }
    
      },
    filters:{
@@ -68,8 +75,39 @@
</script>
<style scoped lang="less">
  .item-times{
    color: #999;
    margin-bottom: 0.15rem;
  .newDetail-tits{
    margin-top: 0.4rem;
    font-size: 0.4rem;
    margin-bottom: 0.4rem;
  }
  .newsTop{
    border-bottom: 0.01rem solid #cdcdcd;
    padding-top: 0.3rem;
    color: #000;
    width: 96%;
    margin-left: 0;
    margin-right: 0;
    margin: 0 auto;
  }
  .newsTitle{
    font-size: 0.55rem;
    font-weight: 500;
  }
  .newsDetail{
    width: 96%;
    margin-left: 0;
    margin-right: 0;
    margin: 0 auto;
    margin-top: 0.4rem;
    font-size: 0.35rem;
    line-height: 0.6rem;
  }
  .newsImg{
    width: 100%;
    margin-top: 0.4rem;
  }
  .newsImg img{
    width: 100%;
    height: 100%;
  }
</style>
src/page/login/components/header.vue
@@ -1,53 +1,96 @@
<template>
    <div class="header_history">
        <div class="header_content">
            <div class="left_back" @click="$router.go(-1)"><img src="../../../assets/img/backs.png" alt=""></div>
            <div class="left_back" @click="$router.go(-1)"><img src="../../../assets/img/back.png" alt=""></div>
            <div class="right_mess"><span>{{ '' }}</span></div>
            <div class="right_back" @click="goOnline()">
                <img :src="Service" alt />
            </div>
        </div>
    </div>
</template>
<script>
import Service from "@/assets/home/icon_talk.png";
export default {
    name: 'headers',
    props: ['mess']
    props: ['mess'],
    data() {
        return {
            Service,
            onlineService: "",
        }
    },
    methods: {
        goOnline() {
            window.location.href = this.onlineService;
        },
        async getInfoSite() {
            let data = await api.getInfoSite()
            if (data.status === 0) {
                this.onlineService = data.data.onlineService
            } else {
                Toast(data.msg)
            }
        },
    },
    mounted() {
        this.getInfoSite()
    }
}
</script>
<style scope lang="less">
.header_history {
    width: 100%;
    height: 1.0256rem;
    height: 1.6256rem;
    display: flex;
    align-items: center;
    > div {
        width: 100%;
        height: 80%;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding-left: 0.2rem;
        padding-right: 0.2rem;
    }
    .left_back {
        width: .6513rem;
        height: 1.0513rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .right_back {
        width: 1.0513rem;
        height: 1.0513rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .right_mess {
        width: 60%;
        height: 100%;
        display: flex;
        justify-content: flex-end;
        align-items: center;
        >span {
            margin-right: .5128rem;
        }
    }
    img {
        width: 50%;
        height: 50%;
    }
}
</style>
src/page/login/login.vue
@@ -1,38 +1,61 @@
<template>
  <div class="login_page">
    <headers :mess="loginWay" />
    <div class="img_mess">
    <!-- <div class="img_mess">
      <div class="logo_content animated fadeInRight">
        <img :src="Logo" alt />
      </div>
    </div>
    </div> -->
    <div class="logins_content">
      <div class="login_title animated slideInDown">
        <span>{{ '邮箱登录' }}</span>
        <span>{{ '手机号登录' }}</span>
      </div>
      <div class="login_forms">
        <div class="top_forms">
          <div class="user_name">
          <!-- <div class="user_name">
            <input type="text" :placeholder="placeholder" v-model="userName" />
          </div>
          <div class="password">
            <input type="password"  placeholder="登录密码" v-model="userPassword" @input="handleInput()" />
          </div> -->
          <el-input placeholder="请输入手机号" :size="medium" v-model="userName" clearable>
          </el-input>
          <el-input style="margin-top: 0.46rem;" show-password placeholder="登录密码" :size="medium" v-model="userPassword"   @input="handleInput()">
          </el-input>
          </div>
        </div>
        <div class="bottom_btns">
          <div class="top_btn" @click="loginIN" :class="btnClass ? 'on' : 'off'">
        <div class="bottom_btns" :class="btnClass ? 'on' : 'off'" >
          <div class="top_btn " @click="loginIN" :class="dengl ? 'animated pulse' : ''">
            <span>{{ '安全登录' }}</span>
          </div>
          <div class="mes">
            <span>{{ '没有账户?' }}</span>
            <span @click="$router.push('/NewRegister')" style="color: rgb(54,124,248);">{{ '注册>' }}</span>
          <div class="mes" @click="getApp()">
            <span>{{ '忘记密码?' }}</span>
          </div>
        </div>
      </div>
    </div>
    <div class="login_bom">
        <div class="line">
          <div class="left_line"></div>
          <div class="center_line">
            <span>{{ '其他登录方式' }}</span>
          </div>
          <div class="right_line"></div>
      </div>
      <div class="imgDemo">
        <div class="appImg" @click="getApp()"><img src="@/assets/img/apple.png"/></div>
        <div class="appImg" @click="getApp()"><img src="@/assets/img/google.png"/></div>
        <div class="appImg" @click="getApp()"><img src="@/assets/img/facebook.png"/></div>
      </div>
      <div class="myzh"><span class="mes">没有账户?</span><span @click="$router.push('/register')"  class="mes" style="color: rgb(54,124,248);">{{ '注册' }}</span> </div>
    </div>
    <el-alert
    v-show="alertShow"
    :closable="closable"
    :title="texts"
    type="warning" center></el-alert>
  </div>
</template>
<script>
import { Toast } from 'mint-ui'
import headers from "./components/header.vue";
@@ -49,14 +72,30 @@
      Logo,
      userPassword: "",
      userName: "",
      btnClass: false
      btnClass: false,
      medium: "medium",
      alertShow:false,
      closable:false,
      texts:"",
      dengl:false,
      loginBtn:false,
    };
  },
  components: {
    headers
  },
  methods: {
    getApp(){
     // Toast('您所在的地区暂未开通此服务')
      //Toast 弹窗大小
      this.texts="您所在的地区暂未开通此服务"
      this.alertShow=true
      setTimeout(()=>{
        this.alertShow=false
      },2000)
    },
    handleInput() {
      console.log(this.userPassword !== "" && this.userName !== '');
      if (this.userPassword !== "" && this.userName !== '') {
        this.btnClass = true;
      } else {
@@ -64,11 +103,19 @@
      }
    },
    async loginIN () {
      this.dengl=true
      setTimeout(()=>{
        this.dengl=false
      },1000)
      if(this.loginBtn){
        return;
      }
      this.loginBtn = true;
      let opts = {
        phone: this.userName,
        userPwd: this.userPassword
      }
      let data = await api.login(opts)
      if (data.status === 0) {
        this.$store.state.userInfo.phone = this.userName
@@ -77,8 +124,15 @@
        window.localStorage.clear()
        window.localStorage.setItem("USERTOKEN",data.data.token);
        this.$router.push('/home')
        this.loginBtn = false;
      } else {
        Toast(data.msg)
        this.texts=data.msg
      this.alertShow=true
      this.loginBtn = false;
      setTimeout(()=>{
        this.alertShow=false
      },2000)
        //Toast(data.msg)
      }
    },
@@ -90,40 +144,55 @@
<style scoped lang="less">
.login_page {
  position: relative;
  background-color: #fff !important;
  width: 100%;
  height: 100%;
  overflow: hidden;
  overflow-y: auto;
}
.logins_content {
  width: 100%;
  height: 9.7436rem;
  margin-top: 0.4359rem;
  padding: 0 0.2564rem;
  padding: 0 0.4564rem;
  .login_title {
    width: 100%;
    height: 2.0513rem;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.6923rem;
    color: #fff;
    font-size: 0.7023rem;
    color: #000;
    font-weight: 600 !important;
    >span {
      font-weight: 600 !important;
  }
  }
  .login_forms {
    width: 100%;
    height: 7.9231rem;
    height: auto;
    margin-top: 0.35rem;
    .top_forms {
      width: 100%;
      height: 4.5128rem;
      height: auto;
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      .user_name,
      .password {
        width: 100%;
        height: 35%;
        background: #1e1e1e;
        background: rgb(246, 246, 247);
        // background: #1e1e1e;
        border-radius: 0.3564rem;
        > input {
          width: 100%;
          height: 100%;
@@ -132,29 +201,43 @@
        }
      }
    }
    /deep/.el-input__inner {
      width: 100%;
      height: 1.45rem !important;
      background-color: rgb(246, 246, 247) !important;
      // background: #1e1e1e;
      border-radius: 0.3564rem;
      font-size: 0.45rem !important;
    }
    .bottom_btns {
      width: 100%;
      height: 3.3333rem;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      margin-top: 0.5128rem;
      margin-top: 0.8528rem;
      .top_btn {
        width: 100%;
        height: 40%;
        height: 1.25rem;
        border-radius: 0.3564rem;
        background: rgb(131, 174, 243);
        background: rgb(154,197,250);
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.5128rem;
        margin-top: 0.75rem;
        >span {
          font-weight: 530 !important;
      }
      .top_btn.on {
        background: rgb(0, 71, 187);
      }
      .mes {
        width: 100%;
        height: 40%;
        height: 20%;
        margin-top: 0.4rem;
        display: flex;
        justify-content: flex-end;
        align-items: center;
@@ -163,19 +246,137 @@
    }
  }
}
.login_bom{
  position: absolute;
  bottom: 2.6rem;
  width: 100%;
  height: 4rem;
  padding: 0 2rem;
}
  .line{
    //分割线
    width: 100%;
    height: 0.3846rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0.3846rem;
    .left_line{
      width: 20%;
      height: 0.01rem;
      background: #e5e5e5;
    }
    .center_line{
      width: 50%;
      height: 0.01rem;
      background: #fff;
      display: flex;
      align-items: center;
      justify-content: center;
      >span{
        font-size: 0.3046rem;
        color: #000;
        background-color: #fff;
      }
    }
    .right_line{
      width: 20%;
      height: 0.01rem;
      background: #e5e5e5;
    }
  }
  .myzh{
    width: calc(100% - 4rem);
    position: absolute;
    bottom: 0.01rem;
    text-align: center;
     .mes {
        width: 100%;
        height: 40%;
        font-size: 0.3846rem;
      }
  }
  .imgDemo{
    display: flex;
    justify-content: space-between;
    position: relative;
    transform:translateY(50%);
  }
  .appImg{
    width: 1.4rem;
    height: 1.4rem;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgb(246,246,247);
    border-radius: 100%;
  }
  .appImg img{
    width: 0.8rem;
    height: 0.8rem;
  }
.img_mess {
  width: 100%;
  height: 4.0513rem;
  display: flex;
  justify-content: center;
  align-items: center;
  .logo_content {
    width: 3rem;
    height: 3.5769rem;
    > img {
      width: 100%;
      height: 100%;
    }
  }
}
/deep/.el-alert{
  width: 70%!important;
  height: 1rem!important;
  position: absolute!important;
  top: 0!important;
  bottom: 0!important;
  left: 0!important;
  right: 0!important;
  margin: auto!important;
  font-size: 0.3rem!important;
}
/deep/.el-alert__title{
  font-size: 0.3rem!important;
}
/deep/.el-input__suffix{
  width: 1rem!important;
  display: flex;
    justify-content: center;
    align-items: center;
}
/deep/.el-input__suffix-inner{
  display: flex;
    justify-content: center;
    align-items: center;
}
/deep/.el-input__icon{
  width: 1rem!important;
  display: flex;
    justify-content: center;
    align-items: center;
}
.on .top_btn {
        background: #2d8cf0!important;
      }
  /deep/.el-icon-circle-close::before{
    font-size: 0.5rem!important;
  }
/deep/.el-input__clear{
  font-size: 0.5rem!important;
}
</style>
src/page/login/register.vue
@@ -1,18 +1,18 @@
<template>
  <div class="login_page">
    <headers :mess="loginWay" />
    <div class="img_mess">
    <!-- <div class="img_mess">
      <div class="logo_content animated fadeInRight">
        <img :src="Logo" alt />
      </div>
    </div>
    </div> -->
    <div class="logins_content">
      <div class="login_title animated slideInDown">
        <span>{{ '邮箱注册' }}</span>
        <span>{{ '手机注册' }}</span>
      </div>
      <div class="login_forms">
        <div class="top_forms">
          <div class="user_name">
          <!-- <div class="user_name">
            <input type="text" :placeholder="placeholder" v-model="phone" />
          </div>
          <div class="captcha">
@@ -22,34 +22,48 @@
          </div>
          <div class="password">
            <input type="password"  placeholder="密码为6~12位数字、字母或符号" v-model="userPassword"  />
            <!-- @input="handleInput()" -->
            @input="handleInput()"
          </div>
          <div class="password">
            <input type="password"  placeholder="请再次确认密码" v-model="rePassword"  />
          </div>
          <div class="user_name">
            <input type="text" placeholder="机构代码" v-model="userName" />
          </div> -->
          <el-input :placeholder="placeholder" :size="medium" v-model="phone" clearable @input="handleInput()">
          </el-input>
          <!-- <el-input style="margin-top: 0.46rem;" :placeholder="verification" :size="medium" v-model="code" clearable>
          </el-input> -->
          <el-input style="margin-top: 0.46rem;" show-password placeholder="密码为6~12位数字、字母或符号" :size="medium"
            v-model="userPassword" @input="handleInput()">
          </el-input>
          <el-input style="margin-top: 0.46rem;" show-password placeholder="请再次确认密码" :size="medium" v-model="rePassword"
            @input="handleInput()">
          </el-input>
          <el-input style="margin-top: 0.46rem;" placeholder="邀请码" :size="medium" v-model="userName" clearable
            @input="handleInput()">
          </el-input>
          </div>
        </div>
        <div class="bottom_btns">
          <div class="top_btn" @click="gook" :class="btnClass ? 'on' : 'off'">
        <div class="bottom_btns" :class="btnClass ? 'on' : 'off'">
          <div class="top_btn " @click="gook" :class="dengl ? 'animated pulse' : ''">
            <span>{{ '安全注册' }}</span>
          </div>
          <div
          <!-- <div
           class="register-form-item agree-model"
          >
            <i @click="isAgree"
             :class="agree?'glyphicon glyphicon glyphicon-ok-sign blue':'glyphicon glyphicon-ok-circle'"></i>
          我已阅读并同意
          <a  style="color:#fff">《注册协议》</a>
          </div>
          </div> -->
          <div class="mes">
            <span>{{ '已有账户?' }}</span>
            <span @click="$router.push('/NewLogin')" style="color: rgb(54,124,248);">{{ '登录>' }}</span>
            <span @click="$router.push('/login')" style="color: rgb(54,124,248);">{{ '登录>' }}</span>
          </div>
        </div>
      </div>
    </div>
    <el-alert v-show="alertShow" :closable="closable" :title="texts" :type="elType" center></el-alert>
  </div>
</template>
@@ -75,24 +89,51 @@
        userName: "",
        code:"",
        userPassword: "",
        btnClass: true,
      btnClass: false,
        codeshow: true,
        count: '', // 倒计时
        clickFalg: 0, //  点击次数
        rePassword:"",
        agree:false,
          }},
      dengl: false,
      alertShow: false,
      closable: false,
      texts: "",
      elType: "warning",
    }
  },
      mounted(){
      },
      methods:{
    handleInput() {
      if (this.userPassword !== "" && this.phone !== '' && this.userPassword == this.rePassword && this.userName != "") {
        this.btnClass = true;
      } else {
        this.btnClass = false;
      }
    },
      checkCodeBox () {
        if (isNull(this.phone) || !isPhone(this.phone)) {
          Toast('请输入正确的手机号')
        // Toast('请输入正确的手机号')
        this.texts = "请输入正确的手机号"
        this.alertShow = true
        setTimeout(() => {
          this.alertShow = false
        }, 2000)
        } else {
          this.checkPhone()
        }
      },
    async is_login(){
      //获取localStorage中的token
      let token = localStorage.getItem('USERTOEKN')
      if(token){
        this.$router.push('/home')
      }
    },
      async getcode () {
        // if(!this.checkCode()){
        //     // 验证图形码是否正确
@@ -108,10 +149,18 @@
        //   var reg = 11 && /^((13|14|15|17|18)[0-9]{1}\d{8})$/
        let reg = /^[0-9]{11}$/ // 手机号码验证
        if (isNull(this.phone)) {
          Toast('手机号不可为空')
        this.texts = "手机号不能为空"
        this.alertShow = true
        setTimeout(() => {
          this.alertShow = false
        }, 2000)
        } else {
          if (!reg.test(this.phone)) {
            Toast('请输入正确的手机号码')
          this.texts = "请输入正确的手机号码"
          this.alertShow = true
          setTimeout(() => {
            this.alertShow = false
          }, 2000)
          } else {
            //   var sign  = this.$md5(this.phone+'W&WzL42v').toUpperCase()
            let result = await api.getCode({ phoneNum: this.phone })
@@ -131,48 +180,122 @@
                  }
                }, 1000)
              } else {
                Toast(result.msg)
              // Toast(result.msg)
              this.texts = result.msg
              this.elType = "success"
              this.alertShow = true
              setTimeout(() => {
                this.alertShow = false
                this.elType = "warning"
              }, 2000)
              }
            } else {
              Toast(result.msg)
            this.texts = result.msg
            this.alertShow = true
            setTimeout(() => {
              this.alertShow = false
            }, 2000)
            }
          }
        }
      },
      async gook () {
      this.dengl = true
      setTimeout(() => {
        this.dengl = false
      }, 1000)
      if (this.loginBtn) {
        return;
      }
      this.loginBtn = true;
        // 注册
        if (!this.agree) {
          Toast('需同意注册协议才能注册!')
        } else if (isNull(this.phone) || !isPhone(this.phone)) {
          Toast('请输入正确的手机号码')
      // if (!this.agree) {
      //   Toast('需同意注册协议才能注册!')
      //   this.loginBtn = false;
      // } else
      if (isNull(this.phone) || !isPhone(this.phone)) {
        this.texts = "请输入正确的手机号码"
        this.alertShow = true
        setTimeout(() => {
          this.alertShow = false
        }, 2000)
        this.loginBtn = false;
        } else if (isNull(this.userPassword)) {
          Toast('请输入密码')
        this.texts = "请输入密码"
        this.alertShow = true
        setTimeout(() => {
          this.alertShow = false
        }, 2000)
        this.loginBtn = false;
        } else if (isNull(this.rePassword)) {
          Toast('请确认密码')
        } else if (isNull(this.code)) {
          Toast('请输入验证码')
        } else if (this.userPassword !== this.rePassword) {
          Toast('两次输入的密码不一致')
        this.texts = "请确认密码"
        this.alertShow = true
        setTimeout(() => {
          this.alertShow = false
        }, 2000)
        this.loginBtn = false;
      } else
        //   if (isNull(this.code)) {
        //     this.texts="请输入验证码"
        // this.alertShow=true
        // setTimeout(()=>{
        //   this.alertShow=false
        // },2000)
        //     this.loginBtn = false;
        //   } else
        if (this.userPassword !== this.rePassword) {
          this.texts = "两次输入的密码不一致"
          this.alertShow = true
          setTimeout(() => {
            this.alertShow = false
          }, 2000)
          this.password = 0
          this.password2 = 0
          this.loginBtn = false;
        } else if (!pwdReg(this.userPassword)) {
          Toast('密码为6~12位,数字、字母或符号')
          this.texts = "密码为6~12位,数字、字母或符号"
          this.alertShow = true
          setTimeout(() => {
            this.alertShow = false
          }, 2000)
          this.loginBtn = false;
        } else if (isNull(this.userName)) {
          Toast('请输入机构代码')
          this.texts = "请输入邀请码"
          this.alertShow = true
          setTimeout(() => {
            this.alertShow = false
          }, 2000)
          this.loginBtn = false;
        } else {
          let opts = {
            // agentCode:'4023', // SR330001
            phone: this.phone,
            yzmCode: this.code,
            yzmCode: '6666',
            userPwd: this.userPassword,
            agentCode: this.userName
          }
          let data = await api.register(opts)
          if (data.status === 0) {
            Toast('注册成功,请登录')
            this.$router.push('/NewLogin')
            this.texts = "注册成功,请登录"
            this.elType = "success"
            this.alertShow = true
            setTimeout(() => {
              this.alertShow = false
              this.elType = "warning"
            }, 2000)
            this.loginBtn = false;
            this.$router.push('/login')
          } else {
            Toast(data.msg)
            this.texts = data.msg
            this.alertShow = true
            setTimeout(() => {
              this.alertShow = false
            }, 2000)
            this.loginBtn = false;
          }
        }
      },
@@ -184,7 +307,11 @@
        let data = await api.checkPhone({ phoneNum: this.phone })
        if (data.status === 0) {
          // 如果用户已存在返回 0
          Toast('用户已注册,请登录')
        this.texts = "用户已注册,请登录"
            this.alertShow = true
            setTimeout(() => {
              this.alertShow = false
            }, 2000)
          this.$router.push('/login')
        } else {
          // this.dialogShow = false
@@ -202,36 +329,57 @@
</script>
<style  scoped lang="less">
.login_page {
  position: relative;
  background-color: #fff !important;
  width: 100%;
  height: 100%;
  overflow: hidden;
  overflow-y: auto;
}
  .logins_content {
    width: 100%;
    height: 9.7436rem;
    margin-top: 0.4359rem;
    padding: 0 0.2564rem;
  padding: 0 0.4564rem;
    .login_title {
      width: 100%;
      height: 2.0513rem;
      display: flex;
      justify-content: center;
      align-items: center;
      font-size: 0.6923rem;
      color: #fff;
    font-size: 0.7023rem;
    color: #000;
    font-weight: 600 !important;
    >span {
      font-weight: 600 !important;
    }
  }
    .login_forms {
      width: 100%;
      height: 7.9231rem;
    height: auto;
    margin-top: 0.35rem;
      .top_forms {
        width: 100%;
        height: 4.5128rem;
      height: auto;
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        .user_name,.captcha,
      .user_name,
        .password {
          width: 100%;
          height: 35%;
          background: #1e1e1e;
        background: rgb(246, 246, 247);
        // background: #1e1e1e;
          border-radius: 0.3564rem;
          margin-top: 0.2rem;
          > input {
            width: 100%;
            height: 100%;
@@ -239,38 +387,45 @@
            font-size: 0.4615rem;
          }
        }
        .captcha{
          display: flex;
          align-items: center;
          > input {
            width: 80%!important;
    }
    /deep/.el-input__inner {
      width: 100%;
      height: 1.45rem !important;
      background-color: rgb(246, 246, 247) !important;
      // background: #1e1e1e;
      border-radius: 0.3564rem;
      font-size: 0.45rem !important;
          }
        }
      }
      .bottom_btns {
        width: 100%;
        height: 3.3333rem;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        margin-top: 4.8128rem;
      margin-top: 0.8528rem;
        .top_btn {
          width: 100%;
          height: 40%;
        height: 1.25rem;
          border-radius: 0.3564rem;
          background: rgb(131, 174, 243);
        background: rgb(154, 197, 250);
        color: #fff;
          display: flex;
          align-items: center;
          justify-content: center;
          font-size: 0.5128rem;
        margin-top: 0.75rem;
        >span {
          font-weight: 530 !important;
        }
        .top_btn.on {
          background: rgb(0, 71, 187);
        }
        .mes {
          width: 100%;
          height: 40%;
        height: 20%;
        margin-top: 0.4rem;
          display: flex;
          justify-content: flex-end;
          align-items: center;
@@ -279,21 +434,149 @@
      }
    }
  }
.login_bom {
  position: absolute;
  bottom: 2.6rem;
  width: 100%;
  height: 4rem;
  padding: 0 2rem;
}
.line {
  //分割线
  width: 100%;
  height: 0.3846rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.3846rem;
  .left_line {
    width: 20%;
    height: 0.01rem;
    background: #e5e5e5;
  }
  .center_line {
    width: 50%;
    height: 0.01rem;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    >span {
      font-size: 0.3046rem;
      color: #000;
      background-color: #fff;
    }
  }
  .right_line {
    width: 20%;
    height: 0.01rem;
    background: #e5e5e5;
  }
}
.myzh {
  width: calc(100% - 4rem);
  position: absolute;
  bottom: 0.01rem;
  text-align: center;
  .mes {
    width: 100%;
    height: 40%;
    font-size: 0.3846rem;
  }
}
.imgDemo {
  display: flex;
  justify-content: space-between;
  position: relative;
  transform: translateY(50%);
}
.appImg {
  width: 1.4rem;
  height: 1.4rem;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: rgb(246, 246, 247);
  border-radius: 100%;
}
.appImg img {
  width: 0.8rem;
  height: 0.8rem;
}
  .img_mess {
    width: 100%;
    height: 4.0513rem;
    display: flex;
    justify-content: center;
    align-items: center;
    .logo_content {
      width: 3rem;
      height: 3.5769rem;
      > img {
        width: 100%;
        height: 100%;
      }
    }
  }
/deep/.el-alert {
  width: 70% !important;
  height: 1rem !important;
  position: absolute !important;
  top: 0 !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  margin: auto !important;
  font-size: 0.3rem !important;
}
/deep/.el-alert__title {
  font-size: 0.3rem !important;
}
/deep/el-input__suffix {
  width: 1rem !important;
}
/deep/.el-input__suffix-inner {
  width: 1rem !important;
}
/deep/.el-input__icon {
  width: 1rem !important;
}
/deep/.el-icon-circle-close::before {
  font-size: 0.5rem !important;
}
/deep/.el-input__clear {
  font-size: 0.5rem !important;
}
.on .top_btn {
  background: #2d8cf0 !important;
}
  .agree-model{
    margin-top: 0.2rem;
  }
src/router/index.js
@@ -44,6 +44,7 @@
import newLogin from '@/page/login/login.vue'
import newRegister from '@/page/login/register.vue'
import NewPage from '@/page/home/newPage'
import NewGg from '@/page/home/newGg'
Vue.use(Router)
@@ -80,22 +81,34 @@
      path: '/newPage',
      name: 'newPage',
      meta: {
        title: 'new',
        requireAuth: false,
        hasHeader: false,
        title: '详情',
        hasHeader: true,
        is_Show: true,
        index: 2
      },
      component: NewPage
    },
    {
      path: '/register',
      name: 'register',
      path: '/newGg',
      name: 'newGg',
      meta: {
        title: '注册',
        index: 3
        title: '公告详情',
        hasHeader: true,
        is_Show: true,
        index: 49
      },
      component: Register
    }, {
      component: NewGg
    },
    // {
    //   path: '/register',
    //   name: 'register',
    //   meta: {
    //     title: '注册',
    //     index: 3
    //   },
    //   component: Register
    // },
    {
      path: '/forget',
      name: 'forget',
      meta: {
@@ -103,16 +116,18 @@
        index: 4
      },
      component: Forget
    }, {
      path: '/login',
      name: 'login',
      meta: {
        title: '账户登录',
        hasHeader: true,
        index: 5
      },
      component: Login
    }, {
    // {
    //   path: '/login',
    //   name: 'login',
    //   meta: {
    //     title: '账户登录',
    //     hasHeader: true,
    //     index: 5
    //   },
    //   component: Login
    // },
     {
      path: '/openaccount',
      name: 'openaccount',
      meta: {
@@ -532,10 +547,10 @@
      component: FundsList
    },
    {
      path: '/newLogin',
      path: '/login',
      name: 'newLogin',
      meta: {
        title: '新登录',
        title: '用户登录',
        requireAuth: false,
        hasHeader: true,
        index: 47
@@ -543,10 +558,10 @@
      component: newLogin
    },
    {
      path: '/newRegister',
      path: '/register',
      name: 'newRegister',
      meta: {
        title: '新注册',
        title: '用户注册',
        requireAuth: false,
        hasHeader: false,
        index: 48
src/store/index.js
@@ -8,6 +8,7 @@
const state = {
  className: 'black',
  theme:'red',
  userInfo: { // 用户信息
  },
  user: {},