Kaynağa Gözat

注册:提交时的报错类型问题

zweizhao 7 yıl önce
ebeveyn
işleme
42f87d9d5a

+ 3 - 0
assets/css/special.css

@@ -26,4 +26,7 @@
 }
 .el-form-item__label {
   line-height: 30px;
+}
+.cash-input input {
+  padding-left: 36px;
 }

+ 24 - 0
components/inner_header.vue

@@ -0,0 +1,24 @@
+<template>
+  <div class="inner-header">
+    <h1 class="title">{{title}}</h1>
+    <div class="line"></div>
+  </div>
+</template>
+
+<script>
+export default {
+  props: ['title'],
+}
+</script>
+
+<style scoped>
+h1 {
+  text-align: center;
+  margin: 20px 0 18px;
+}
+.line {
+  width: 960px;
+  height: 1px;
+  background: rgba(0, 0, 0, 0.2);
+}
+</style>

+ 1 - 0
layouts/default.vue

@@ -54,6 +54,7 @@ export default {
   align-items: center;
 }
 .main {
+  min-width: 1000px;
   min-height: calc(100vh - 376px);
   margin: 20px 0 30px;
 }

+ 1 - 1
pages/user/register.vue

@@ -213,7 +213,7 @@ export default {
           }
         })
       } else {
-        this.$refs.rulesEmail.validate((valid) => {
+        this.$refs.ruleFormEmail.validate((valid) => {
           if(valid) {
             let body = {
               captcha: this.ruleFormEmail.ver,

+ 136 - 0
pages/wo/cash.vue

@@ -0,0 +1,136 @@
+<template>
+  <div class="cash">
+    <inner-header title="资金提现"></inner-header>
+    <section class="content">
+      <h2>提现到支付宝({{userinfo.alipay}})</h2>
+      <div class="input-box">
+        <el-input class="cash-input" placeholder="最少提现1元,每日上限3万元"></el-input>
+        <span class="input-icon">¥</span>
+        <el-button type="text" class="get-all" @click="doGetAll">全部提现</el-button>
+      </div>
+      <div class="balance">
+        可用余额
+        <span>¥{{coinInfo.balance}}</span>元
+      </div>
+      <el-button class="get-btn" type="primary">提现</el-button>
+      <p class="remind-time">预计1~3个工作日到账</p>
+      <p>提现说明</p>
+      <div class="reminds">
+        <div>1.提现非客栈转入的资金需要收取0.6%的手续费</div>
+        <div>2.提现成功后,会在1-3个工作日内到账,节假日可能会稍有延时,请耐心等待</div>
+        <div>
+          3.请确认支付宝账号和实名认证信息保持一致,如需修改支付宝账号,请前往
+          <a href="/setting/user">实名个人信息</a>
+        </div>
+        <div>
+          4.如提现失败,或长时间未到账( 超过3个工作日),可联系
+          <a href="#">在线客服</a>
+        </div>
+      </div>
+    </section>
+    <!-- <script>
+      var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1261469621'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s11.cnzz.com/z_stat.php%3Fid%3D1261469621' type='text/javascript'%3E%3C/script%3E"));
+    </script>-->
+  </div>
+</template>
+
+<script>
+import InnerHeader from '@/components/inner_header.vue'
+
+export default {
+  components: {
+    InnerHeader,
+  },
+  data() {
+    return {
+      alipayInfo: {}
+    }
+  },
+  computed: {
+    coinInfo() {
+      return this.alipayInfo.coinInfo || {}
+    },
+    userInfo() {
+      return this.alipayInfo.userInfo || {}
+    }
+  },
+  mounted() {
+    // document.write(unescape("%3Cspan id='cnzz_stat_icon_1261469621'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s11.cnzz.com/z_stat.php%3Fid%3D1261469621' type='text/javascript'%3E%3C/script%3E"))
+    this.getAlipayInfo()
+  },
+  methods: {
+    /**
+     * 全部提现
+     */
+    doGetAll() {
+
+    },
+    /**
+     * 获取支付宝信息
+     */
+    async getAlipayInfo() {
+      let res = await this.$post('/api/user/get_cash_info')
+      console.log(res)
+      if(res) {
+        this.alipayInfo = res.data
+      }
+    }
+  }
+}
+</script>
+
+<style scoped>
+.cash {
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  height: 590px;
+  background: white;
+}
+h2 {
+  margin: 64px 0 8px;
+  font-size: 14px;
+}
+.input-box {
+  position: relative;
+  width: 396px;
+}
+.cash-input {
+  width: 396px;
+}
+.input-icon,
+.get-all {
+  position: absolute;
+}
+.input-icon {
+  top: 10px;
+  left: 16px;
+  font-size: 20px;
+}
+.get-all {
+  top: 0;
+  right: 20px;
+}
+.balance {
+  color: #999;
+  font-size: 13px;
+  margin: 6px 0 24px;
+}
+.balance span {
+  color: #ffa81a;
+}
+.get-btn {
+  width: 244px;
+}
+.remind-time {
+  color: #999;
+  font-size: 12px;
+  margin: 8px 0 28px;
+}
+.reminds {
+  width: 396px;
+  color: #919aa7;
+  margin-top: 6px;
+  line-height: 32px;
+}
+</style>