123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135 |
- import React, { Component } from 'react';
- import { connect } from "react-redux";
- import './downloadCaigong2.css'
- const mapStateToProps = (state) => ({
- });
- const mapDispatchToProps = (dispatch) => ({
- });
- class LoginViews extends Component {
- /*
- * 构造函数
- *
- * */
- constructor() {
- super();
- this.state = {
- };
- }
- is_weixin() {
- var ua = navigator.userAgent.toLowerCase();
- if (ua.match(/MicroMessenger/i) === "micromessenger") {
- return true;
- } else {
- return false;
- }
- }
- openWxDownloadTip() {
- document.getElementById('tip').style.display = 'block'
- }
- /*
- *
- * 生命周期一
- *
- * */
- componentWillMount() {
-
- /*
- *
- * 如果是ios设备默认第一次不是播放状态,android没事
- *
- * */
- /*
- *
- * 请求数据
- *
- *
- * */
- }
- /*
- *
- * 生命周期二
- *
- * */
- componentDidMount() {
- if (this.is_weixin()) {
- document.querySelectorAll('#app a')[0].style.display = 'none'
- document.querySelectorAll('#app a')[1].style.display = 'none'
- }
- else {
- document.querySelectorAll('#app a')[2].style.display = 'none'
- document.querySelectorAll('#app a')[3].style.display = 'none'
- }
- }
- /*
- * 渲染
- * */
- render() {
- return (
- <div id="app">
- <div id="tip">
- <img class="tip" src="./assets/tip.png" alt='' />
- </div>
- <div class="title">
- <img style={{ width: '72vw' }} src="./assets/财仝驾考APP2.png" alt='' />
- </div>
- <div class="subtitle">
- <span style={{ color: '#656565' }}>一款为驾考学员打造的专业软件</span>
- </div>
- <img class="bg" src="./assets/bg2.png" alt='' />
- <a href="https://ys.zzxcx.net/apk/sdjkAndroid1.2.2.apk">
- <div class="download1">
- 点击下载1
- </div>
- </a>
- <a href="https://ys.zzxcx.net/apk/sdjkAndroid1.2.2.apk">
- <div class="download2">
- 点击下载(备用)
- </div>
- </a>
- <a onclick={this.openWxDownloadTip().bind(this)}>
- <div class="download1">
- 点击下载1
- </div>
- </a>
- <a onclick={this.openWxDownloadTip().bind(this)}>
- <div class="download2">
- 点击下载(备用)
- </div>
- </a>
- </div>
- )
- }
- componentWillUnmount() {
- }
- }
- export default connect(mapStateToProps, mapDispatchToProps)(LoginViews);
|