guhongwei 4 年之前
父节点
当前提交
39b41ce4c1
共有 85 个文件被更改,包括 2220 次插入20 次删除
  1. 15 2
      app.json
  2. 7 1
      app.wxss
  3. 17 0
      pages/about/about.js
  4. 4 0
      pages/about/about.json
  5. 8 0
      pages/about/about.wxml
  6. 22 0
      pages/about/about.wxss
  7. 17 0
      pages/car/car.js
  8. 4 0
      pages/car/car.json
  9. 8 0
      pages/car/car.wxml
  10. 22 0
      pages/car/car.wxss
  11. 28 0
      pages/card/card.js
  12. 4 0
      pages/card/card.json
  13. 61 0
      pages/card/card.wxml
  14. 67 0
      pages/card/card.wxss
  15. 68 0
      pages/editPwd/editPwd.js
  16. 4 0
      pages/editPwd/editPwd.json
  17. 31 0
      pages/editPwd/editPwd.wxml
  18. 68 0
      pages/editPwd/editPwd.wxss
  19. 17 0
      pages/exchange/exchange.js
  20. 4 0
      pages/exchange/exchange.json
  21. 8 0
      pages/exchange/exchange.wxml
  22. 22 0
      pages/exchange/exchange.wxss
  23. 95 3
      pages/home/home.js
  24. 2 4
      pages/home/home.json
  25. 101 2
      pages/home/home.wxml
  26. 149 0
      pages/home/home.wxss
  27. 二进制
      pages/images/about.png
  28. 二进制
      pages/images/banner1.png
  29. 二进制
      pages/images/banner2.png
  30. 二进制
      pages/images/banner3.png
  31. 二进制
      pages/images/bg.png
  32. 二进制
      pages/images/car.png
  33. 二进制
      pages/images/fen.png
  34. 二进制
      pages/images/gd.png
  35. 二进制
      pages/images/grxx.png
  36. 二进制
      pages/images/huan.png
  37. 二进制
      pages/images/ka.png
  38. 二进制
      pages/images/news.png
  39. 二进制
      pages/images/sz.png
  40. 二进制
      pages/images/tc.png
  41. 二进制
      pages/images/team.png
  42. 二进制
      pages/images/team2.png
  43. 二进制
      pages/images/tou.jpg
  44. 二进制
      pages/images/user.png
  45. 二进制
      pages/images/xg.png
  46. 二进制
      pages/images/yue.png
  47. 二进制
      pages/images/zhou.png
  48. 二进制
      pages/images/zr.png
  49. 1 1
      pages/index/index.js
  50. 17 0
      pages/integral/integral.js
  51. 4 0
      pages/integral/integral.json
  52. 8 0
      pages/integral/integral.wxml
  53. 22 0
      pages/integral/integral.wxss
  54. 4 3
      pages/login/login.wxml
  55. 35 3
      pages/login/login.wxss
  56. 45 0
      pages/news/news.js
  57. 4 0
      pages/news/news.json
  58. 57 0
      pages/news/news.wxml
  59. 168 0
      pages/news/news.wxss
  60. 24 0
      pages/newsDetail/newsDetail.js
  61. 4 0
      pages/newsDetail/newsDetail.json
  62. 18 0
      pages/newsDetail/newsDetail.wxml
  63. 72 0
      pages/newsDetail/newsDetail.wxss
  64. 79 0
      pages/perssonal/perssonal.js
  65. 3 0
      pages/perssonal/perssonal.json
  66. 45 0
      pages/perssonal/perssonal.wxml
  67. 49 0
      pages/perssonal/perssonal.wxss
  68. 20 0
      pages/setting/setting.js
  69. 4 0
      pages/setting/setting.json
  70. 24 0
      pages/setting/setting.wxml
  71. 59 0
      pages/setting/setting.wxss
  72. 17 0
      pages/shareholder/shareholder.js
  73. 4 0
      pages/shareholder/shareholder.json
  74. 8 0
      pages/shareholder/shareholder.wxml
  75. 22 0
      pages/shareholder/shareholder.wxss
  76. 17 0
      pages/team/team.js
  77. 4 0
      pages/team/team.json
  78. 8 0
      pages/team/team.wxml
  79. 22 0
      pages/team/team.wxss
  80. 1 1
      pages/test/test.wxml
  81. 17 0
      pages/user/user.js
  82. 4 0
      pages/user/user.json
  83. 8 0
      pages/user/user.wxml
  84. 22 0
      pages/user/user.wxss
  85. 447 0
      utils/wxValidate.js

+ 15 - 2
app.json

@@ -1,7 +1,20 @@
 {
   "pages": [
-    "pages/login/login",
+    "pages/card/card",
     "pages/home/home",
+    "pages/login/login",
+    "pages/perssonal/perssonal",
+    "pages/setting/setting",
+    "pages/editPwd/editPwd",
+    "pages/about/about",
+    "pages/news/news",
+    "pages/newsDetail/newsDetail",
+    "pages/team/team",
+    "pages/integral/integral",
+    "pages/exchange/exchange",
+    "pages/car/car",
+    "pages/shareholder/shareholder",
+    "pages/user/user",
     "pages/index/index",
     "pages/logs/logs",
     "pages/test/test"
@@ -41,7 +54,7 @@
   "window": {
     "backgroundTextStyle": "light",
     "navigationBarBackgroundColor": "#fff",
-    "navigationBarTitleText": "鸿泰跃达小程序",
+    "navigationBarTitleText": "鸿泰跃达",
     "navigationBarTextStyle": "black"
   },
   "sitemapLocation": "sitemap.json"

+ 7 - 1
app.wxss

@@ -7,4 +7,10 @@
   justify-content: space-between;
   padding: 200rpx 0;
   box-sizing: border-box;
-} 
+}
+
+.textOver {
+  overflow: hidden;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}

+ 17 - 0
pages/about/about.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/about/about.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/about/about.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    关于我们
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/about/about.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 17 - 0
pages/car/car.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/car/car.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/car/car.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    车奖明细
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/car/car.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 28 - 0
pages/card/card.js

@@ -0,0 +1,28 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+    form: {
+      phone: '17319450324',
+      password: '17319450324',
+      phone: '17319450324',
+      phone: '17319450324',
+      phone: '17319450324',
+      phone: '17319450324',
+      name: '顾红伟',
+      card: '220182199603257019',
+      zfb: 'zhifubao',
+      create_time: '2020-12-12',
+      tjr: '推荐人',
+      tjrPhone: '17319450324',
+    }
+  },
+  //事件处理函数
+  formSubmit: function (e) {
+    console.log(e);
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/card/card.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 61 - 0
pages/card/card.wxml

@@ -0,0 +1,61 @@
+<view class="main">
+  <view class="one">
+    我要办卡
+  </view>
+  <view class="two">
+    <form bindsubmit="formSubmit" bindreset="formReset">
+      <view class="forminput">
+        <text class="label">新办理号码</text>
+        <input type='number' name="phone" value="{{form.phone}}" placeholder='请输入新办理号码'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">密码</text>
+        <input type='text' name="password" value="{{form.password}}" placeholder='请输入密码' password></input>
+        <text class="tip"> 密码必须是8-16位的数字,字母的组合(不能是纯数字)</text>
+      </view>
+      <view class="forminput">
+        <text class="label">号码归属省</text>
+        <input type='number' name="phone" value="{{form.phone}}" placeholder='请输入新办理号码'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">号码归属市</text>
+        <input type='number' name="phone" value="{{form.phone}}" placeholder='请输入新办理号码'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">套餐</text>
+        <input type='number' name="phone" value="{{form.phone}}" placeholder='请输入新办理号码'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">类型</text>
+        <input type='number' name="phone" value="{{form.phone}}" placeholder='请输入新办理号码'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">姓名</text>
+        <input type='text' name="name" value="{{form.name}}" placeholder='姓名'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">身份证号</text>
+        <input type='number' name="card" value="{{form.card}}" maxlength="18" placeholder='身份证号'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">支付宝账号</text>
+        <input type='text' name="zfb" value="{{form.zfb}}" placeholder='支付宝账号'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">办卡时间</text>
+        <input type='date' name="create_time" value="{{form.create_time}}" placeholder='办卡时间'></input>
+      </view>
+      <view class="forminput">
+        <text class="label">推荐人</text>
+        <input type='text' name="tjr" value="{{form.tjr}}" placeholder='推荐人' disabled></input>
+      </view>
+      <view class="forminput">
+        <text class="label">推荐人电话</text>
+        <input type='number' name="tjrPhone" value="{{form.tjrPhone}}" placeholder='推荐人电话' disabled></input>
+      </view>
+      <view class="save">
+        <button form-type="submit">提交</button>
+      </view>
+    </form>
+  </view>
+</view>

+ 67 - 0
pages/card/card.wxss

@@ -0,0 +1,67 @@
+.main {
+  float: left;
+  width: 100%;
+  height: 100%;
+  background-color: #f6f6f6;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+}
+
+.main .two .forminput {
+  float: left;
+  width: 94%;
+  margin: 0 20rpx;
+  border-bottom: 1px solid #ccc;
+}
+
+.main .two .forminput .label {
+  float: left;
+  width: 30%;
+  font-size: 30rpx;
+  height: 80rpx;
+  line-height: 80rpx;
+}
+
+
+
+.main .two .forminput input {
+  float: left;
+  width: 70%;
+  padding: 18rpx 0;
+  text-align: right;
+}
+
+.main .two .forminput .tip {
+  float: left;
+  width: 100%;
+  padding: 10rpx 0;
+  font-size: 20rpx;
+  color: #ff0000;
+}
+
+.main .two .save {
+  float: left;
+  width: 94%;
+  margin: 40rpx 20rpx 0 20rpx;
+}
+
+.main .two .save button {
+  border-radius: 50rpx;
+  background-color: #ff0000;
+  color: #ffffff;
+}

+ 68 - 0
pages/editPwd/editPwd.js

@@ -0,0 +1,68 @@
+//index.js
+import WxValidate from '../../utils/wxValidate';
+//获取应用实例
+const app = getApp();
+Page({
+  data: {
+    form: {}
+  },
+  initValidate() {
+    const rules = {
+      phone: {
+        required: true,
+      },
+      oldPwd: {
+        required: true,
+      },
+      newPwd: {
+        required: true,
+      },
+      isnewPwd: {
+        required: false,
+      },
+    }
+    // 验证字段的提示信息,若不传则调用默认的信息
+    const messages = {
+      phone: {
+        required: '请输入手机号',
+      },
+      oldPwd: {
+        required: '请输入原密码',
+      },
+      newPwd: {
+        required: '请输入新密码',
+      },
+      isnewPwd: {
+        required: '请输入确认密码'
+      }
+    };
+    this.WxValidate = new WxValidate(rules, messages)
+  },
+  //事件处理函数
+  formSubmit: function (e) {
+    const params = e.detail.value;
+    if (!this.WxValidate.checkForm(params)) {
+      const error = this.WxValidate.errorList[0];
+      wx.showToast({
+        title: error.msg,
+        icon: 'none',
+        duration: 2000
+      })
+      return false
+    } else {
+      // 判断新密码,确认新密码是否一致
+      if (params.newPwd === params.isnewPwd) {
+        console.log(params);
+      } else {
+        wx.showToast({
+          title: '新密码与确认密码不一致,请重新输入',
+          icon: 'none',
+          duration: 2000
+        })
+      }
+    }
+  },
+  onLoad: function (options) {
+    this.initValidate()//验证规则函数
+  },
+})

+ 4 - 0
pages/editPwd/editPwd.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 31 - 0
pages/editPwd/editPwd.wxml

@@ -0,0 +1,31 @@
+<view class="main">
+  <view class="one">
+    修改密码
+  </view>
+  <view class="two">
+    <form bindsubmit="formSubmit" bindreset="formReset">
+      <view class="content">
+        <text>手机号</text>
+        <input type='number' name="phone" value="{{form.phone}}" maxlength="11" placeholder='手机号'></input>
+      </view>
+      <view class="content">
+        <text>原密码</text>
+        <input type='text' name="oldPwd" password value="{{form.oldPwd}}" maxlength="16" placeholder='原密码'></input>
+      </view>
+      <view class="content">
+        <text>新密码</text>
+        <input type='text' name="newPwd" password value="{{form.newPwd}}" maxlength="16" placeholder='新密码'></input>
+      </view>
+      <view class="content">
+        <text>确认新密码</text>
+        <input type='text' name="isnewPwd" password value="{{form.isnewPwd}}" maxlength="16" placeholder='确认新密码'></input>
+      </view>
+      <view class="tip">
+        密码必须是8-16位的数字,字母的组合(不能是纯数字)
+      </view>
+      <view class="save">
+        <button form-type="submit">登录</button>
+      </view>
+    </form>
+  </view>
+</view>

+ 68 - 0
pages/editPwd/editPwd.wxss

@@ -0,0 +1,68 @@
+.main {
+  float: left;
+  width: 100%;
+  height: 100%;
+  /* background-image: linear-gradient(#ff0000, #ffffff); */
+  background-color: #f9fafc;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  margin: 20rpx 0 0 0;
+}
+
+.main .two .content {
+  float: left;
+  width: 94%;
+  height: 80rpx;
+  line-height: 80rpx;
+  margin: 0 20rpx;
+  border-bottom: 1px solid #ccc;
+}
+
+
+.main .two .content text {
+  float: left;
+  width: 30%;
+  font-size: 30rpx;
+}
+
+.main .two .content input {
+  float: left;
+  width: 70%;
+  padding: 18rpx 0;
+  text-align: right;
+}
+
+.main .two .tip {
+  float: left;
+  width: 94%;
+  margin: 20rpx;
+  font-size: 25rpx;
+  color: #ff0000;
+}
+
+.main .two .save {
+  float: left;
+  width: 94%;
+  margin: 60rpx 20rpx 0 20rpx;
+}
+
+.main .two .save button {
+  border-radius: 50rpx;
+  background-color: #ff0000;
+  color: #ffffff;
+}

+ 17 - 0
pages/exchange/exchange.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/exchange/exchange.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/exchange/exchange.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    积分兑换
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/exchange/exchange.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 95 - 3
pages/home/home.js

@@ -4,14 +4,106 @@ const app = getApp()
 
 Page({
   data: {
-
+    // 轮播图
+    backgrounds: [
+      {
+        "pic": "/pages/images/banner1.png",
+      },
+      {
+        "pic": "/pages/images/banner2.png",
+      },
+      {
+        "pic": "/pages/images/banner3.png",
+      }
+    ],
+    indicatorDots: true,
+    vertical: false,
+    autoplay: true,
+    interval: 2000,
+    duration: 500
   },
   //事件处理函数
-  bindViewTap: function () {
+  // 个人信息
+  perssonalBtn: function () {
+    wx.navigateTo({
+      url: '../perssonal/perssonal'
+    })
+  },
+  // 设置账号
+  settingBtn: function () {
+    wx.navigateTo({
+      url: '../setting/setting'
+    })
+  },
+  // 修改密码
+  editpwdBtn: function () {
+    wx.navigateTo({
+      url: '../editPwd/editPwd'
+    })
+  },
+  // 退出登录
+  logouBtn: function () {
+    wx.navigateTo({
+      url: '../login/login'
+    })
+  },
+  // 关于我们
+  aboutBtn: function () {
+    wx.navigateTo({
+      url: '../about/about'
+    })
+  },
+  // 通知新闻
+  newsBtn: function () {
+    wx.navigateTo({
+      url: '../news/news'
+    })
+  },
+  // 我要办卡
+  cardBtn: function () {
+    wx.navigateTo({
+      url: '../card/card'
+    })
+  },
+
+  // 我的团队
+  teamBtn: function () {
+    wx.navigateTo({
+      url: '../team/team'
+    })
+  },
+  // 积分明细
+  fenBtn: function () {
+    wx.navigateTo({
+      url: '../integral/integral'
+    })
+  },
+  // 积分兑换
+  huanBtn: function () {
+    wx.navigateTo({
+      url: '../exchange/exchange'
+    })
+  },
+  // 车奖明细
+  carBtn: function () {
+    wx.navigateTo({
+      url: '../car/car'
+    })
+  },
+
+  // 股东奖池
+  gdBtn: function () {
     wx.navigateTo({
-      url: '../index/index'
+      url: '../shareholder/shareholder'
     })
   },
+  // 用户列表
+  userBtn: function () {
+    wx.navigateTo({
+      url: '../user/user'
+    })
+  },
+
   onLoad: function () {
   },
 })

+ 2 - 4
pages/home/home.json

@@ -1,5 +1,3 @@
 {
-  "usingComponents": {
-    "van-button": "/miniprogram_npm/vant-weapp/button/index"
-  }
-}
+  "usingComponents": {}
+}

+ 101 - 2
pages/home/home.wxml

@@ -1,4 +1,103 @@
 <!--index.wxml-->
-<view class="container">
-  首页
+<view class="main">
+  <van-row>
+    <van-col span="24" class="one">
+      <swiper indicator-dots="{{indicatorDots}}" autoplay="{{autoplay}}" interval="{{interval}}"
+        duration="{{duration}}">
+        <block wx:key="unique" wx:for="{{backgrounds}}" wx:for-item="item">
+          <swiper-item>
+            <image src="{{item.pic}}"></image>
+          </swiper-item>
+        </block>
+      </swiper>
+    </van-col>
+    <van-col span="24" class="two">
+      <text class="comTitle">个人服务</text>
+      <view class="btn" bindtap="perssonalBtn">
+        <image src="/pages/images/grxx.png"></image>
+        <text>个人信息</text>
+      </view>
+      <view class="btn" bindtap="settingBtn">
+        <image src="/pages/images/sz.png"></image>
+        <text>设置账号</text>
+      </view>
+      <view class="btn" bindtap="editpwdBtn">
+        <image src="/pages/images/xg.png"></image>
+        <text>修改密码</text>
+      </view>
+      <view class="btn" bindtap="logouBtn">
+        <image src="/pages/images/tc.png"></image>
+        <text>退出登录</text>
+      </view>
+    </van-col>
+    <van-col span="24" class="three">
+      <view class="num">
+        <view class="numOne">
+          <text>昨日新增</text>
+          <image src="/pages/images/zr.png"></image>
+        </view>
+        <view class="numTwo">0</view>
+      </view>
+      <view class="num">
+        <view class="numOne">
+          <text>本周新增</text>
+          <image src="/pages/images/zhou.png"></image>
+        </view>
+        <view class="numTwo">0</view>
+      </view>
+      <view class="num">
+        <view class="numOne">
+          <text>当月新增</text>
+          <image src="/pages/images/yue.png"></image>
+        </view>
+        <view class="numTwo">0</view>
+      </view>
+      <view class="num">
+        <view class="numOne">
+          <text>团队统计</text>
+          <image src="/pages/images/team.png"></image>
+        </view>
+        <view class="numTwo">0</view>
+      </view>
+    </van-col>
+    <van-col span="24" class="four">
+      <text class="comTitle">办卡服务</text>
+      <view class="num" bindtap="aboutBtn">
+        <image src="/pages/images/about.png"></image>
+        <text>关于我们</text>
+      </view>
+      <view class="num" bindtap="newsBtn">
+        <image src="/pages/images/news.png"></image>
+        <text>通知新闻</text>
+      </view>
+      <view class="num" bindtap="cardBtn">
+        <image src="/pages/images/ka.png"></image>
+        <text>我要办卡</text>
+      </view>
+      <view class="num" bindtap="teamBtn">
+        <image src="/pages/images/team2.png"></image>
+        <text>我的团队</text>
+      </view>
+      <view class="num" bindtap="fenBtn">
+        <image src="/pages/images/fen.png"></image>
+        <text>积分明细</text>
+      </view>
+      <view class="num" bindtap="huanBtn">
+        <image src="/pages/images/huan.png"></image>
+        <text>积分兑换</text>
+      </view>
+      <view class="num" bindtap="carBtn">
+        <image src="/pages/images/car.png"></image>
+        <text>车奖明细</text>
+      </view>
+      <view class="num" bindtap="gdBtn">
+        <image src="/pages/images/gd.png"></image>
+        <text>股东奖池</text>
+      </view>
+      <view class="num" bindtap="userBtn">
+        <image src="/pages/images/user.png"></image>
+        <text>用户列表</text>
+      </view>
+    </van-col>
+  </van-row>
 </view>

+ 149 - 0
pages/home/home.wxss

@@ -0,0 +1,149 @@
+.main {
+  float: left;
+  width: 95%;
+  height: 100%;
+  /* background-image: linear-gradient(#ff0000, #ffffff); */
+  background-color: #f6f6f6;
+  padding: 30rpx 20rpx 0 20rpx;
+}
+
+.one {
+  float: left;
+  width: 100%;
+  height: 150px;
+  margin: 0 0 20rpx 0;
+}
+
+.one image {
+  width: 100%;
+  height: 150px;
+}
+
+.two {
+  float: left;
+  width: 100%;
+  min-height: 200rpx;
+  background-color: #ffffff;
+  border: 1px solid #f1f1f1;
+  border-radius: 10rpx;
+  margin: 0 0 20rpx 0;
+}
+
+.two .btn {
+  float: left;
+  width: 25%;
+  text-align: center;
+  margin: 20rpx 0;
+}
+
+.two .btn image {
+  width: 70rpx;
+  height: 70rpx;
+}
+
+.two .btn text {
+  float: left;
+  width: 100%;
+  text-align: center;
+}
+
+.three {
+  float: left;
+  width: 100%;
+  min-height: 200rpx;
+  margin: 0 0 20rpx 0;
+}
+
+.three .num {
+  float: left;
+  width: 46%;
+  height: 150rpx;
+  background-color: #ffffff;
+  margin: 0 50rpx 20rpx 0;
+  border-radius: 10rpx;
+  box-shadow: 0 0 5rpx #ccc;
+}
+
+.three .num:nth-child(2n) {
+  margin: 0;
+}
+
+.three .num .numOne {
+  float: left;
+  width: 100%;
+}
+
+.three .num .numOne text {
+  float: left;
+  margin: 25rpx 0 0 20rpx;
+  font-family: monospace;
+  font-weight: bold;
+}
+
+.three .num .numOne image {
+  width: 60rpx;
+  height: 60rpx;
+  float: right;
+  margin: 15rpx 20rpx 0 0;
+}
+
+.three .num .numTwo {
+  float: left;
+  width: 100%;
+  text-align: center;
+  padding: 15rpx 0;
+  font-weight: bold;
+}
+
+.three .num:nth-child(1) .numTwo {
+  color: #00FFFF;
+}
+
+.three .num:nth-child(2) .numTwo {
+  color: #00FF00;
+}
+
+.three .num:nth-child(3) .numTwo {
+  color: #FFA500;
+}
+
+.three .num:nth-child(4) .numTwo {
+  color: #ff0000;
+}
+
+.four {
+  float: left;
+  width: 100%;
+  min-height: 200rpx;
+  background-color: #ffffff;
+  border: 1px solid #f1f1f1;
+  border-radius: 10rpx;
+  margin: 0 0 20rpx 0;
+}
+
+.four .num {
+  float: left;
+  width: 25%;
+  text-align: center;
+  margin: 20rpx 0;
+}
+
+.four .num image {
+  width: 70rpx;
+  height: 70rpx;
+}
+
+.four .num text {
+  float: left;
+  width: 100%;
+  text-align: center;
+}
+
+/* 公共标题样式 */
+.comTitle {
+  float: left;
+  width: 96%;
+  font-size: 40rpx;
+  padding: 10rpx 15rpx;
+  font-weight: bold;
+}

二进制
pages/images/about.png


二进制
pages/images/banner1.png


二进制
pages/images/banner2.png


二进制
pages/images/banner3.png


二进制
pages/images/bg.png


二进制
pages/images/car.png


二进制
pages/images/fen.png


二进制
pages/images/gd.png


二进制
pages/images/grxx.png


二进制
pages/images/huan.png


二进制
pages/images/ka.png


二进制
pages/images/news.png


二进制
pages/images/sz.png


二进制
pages/images/tc.png


二进制
pages/images/team.png


二进制
pages/images/team2.png


二进制
pages/images/tou.jpg


二进制
pages/images/user.png


二进制
pages/images/xg.png


二进制
pages/images/yue.png


二进制
pages/images/zhou.png


二进制
pages/images/zr.png


+ 1 - 1
pages/index/index.js

@@ -12,7 +12,7 @@ Page({
   //事件处理函数
   bindViewTap: function() {
     wx.navigateTo({
-      url: '../logs/logs'
+      url: '../home/home'
     })
   },
   onLoad: function () {

+ 17 - 0
pages/integral/integral.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/integral/integral.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/integral/integral.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    积分明细
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/integral/integral.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 4 - 3
pages/login/login.wxml

@@ -1,7 +1,8 @@
-<!--index.wxml-->
+<!--login.wxml-->
 <view class="main">
   <view class="one">
-    <text>鸿泰跃达</text>
+    <text>您好,</text>
+    <text>欢迎来到鸿泰跃达</text>
   </view>
   <view class="two">
     <form bindsubmit="formSubmit" bindreset="formReset">
@@ -10,7 +11,7 @@
           <input type='number' name="phone" placeholder='请输入您本人的手机号码'></input>
         </view>
         <view class='input'>
-          <input type='text' name="password" placeholder='请输入密码' password></input>
+          <input type='text' name="password" placeholder='请输入密码(首次登陆密码为手机号后八位)' password></input>
         </view>
       </view>
       <view class="save">

+ 35 - 3
pages/login/login.wxss

@@ -6,11 +6,43 @@
 .main .one {
   float: left;
   width: 100%;
-  text-align: center;
-  padding: 100rpx 0;
+  padding: 0 40rpx;
+  margin: 40rpx 0 100rpx 0;
 }
 
 .main .one text {
+  float: left;
+  width: 100%;
+  font-weight: bold;
+  padding: 10rpx 0;
+}
+
+.main .two {
+  float: left;
+  width: 90%;
+  padding: 0 40rpx;
+}
+
+.main .two .content .input {
+  border-bottom: 1px solid #ccc;
+}
+
+.main .two .content .input input {
+  height: 92rpx;
+  line-height: 92rpx;
+  font-size: 35rpx;
+}
+
+.main .two .save {
+  margin: 50rpx 0 0 0;
+}
+
+.main .two .save button {
+  background-color: #ff0000;
+  color: #ffffff;
+}
+
+/* .main .one text {
   font-size: 60rpx;
 }
 
@@ -41,4 +73,4 @@
   border-radius: 70rpx;
   height: 90rpx;
   line-height: 90rpx;
-}
+} */

+ 45 - 0
pages/news/news.js

@@ -0,0 +1,45 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+    active: 0,
+    companyList: [
+      {
+        id: '23',
+        title: '公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻公司新闻',
+        create_time: '2020-10-10',
+        brief: '公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介公司新闻信息简介',
+      },
+    ],
+    workNewsList: [
+      {
+        title: '行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态行业动态',
+        orgin: '吉林省',
+        create_time: '2020-10-10',
+      },
+    ],
+    jobsNewsList: [
+      {
+        imgUrl: '../images/banner1.png',
+        type: '商务信息',
+        title: '业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料业务资料'
+      },
+      {
+        imgUrl: '',
+        type: '通知信息',
+        title: '业务资料'
+      },
+    ]
+  },
+  //事件处理函数
+  companyBtn: function (e) {
+    let data = e.currentTarget.dataset.item;
+    wx.navigateTo({
+      url: '/pages/newsDetail/newsDetail?id=' + data.id // 希望跳转过去的页面
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/news/news.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 57 - 0
pages/news/news.wxml

@@ -0,0 +1,57 @@
+<view class="main">
+  <view class="one">
+    新闻列表
+  </view>
+  <view class="two">
+    <van-tabs active="{{ active }}">
+      <van-tab title="公司新闻">
+        <view class="companyNews">
+          <view class="list" wx:key="unique" wx:for="{{companyList}}" wx:for-item="item">
+            <view bindtap="companyBtn" data-item="{{item}}">
+              <view class="title">
+                <text class="textOver">{{item.title}}</text>
+                <text>{{item.create_time}}</text>
+              </view>
+              <view class="brief">
+                简介:{{item.brief||'暂无'}}
+              </view>
+            </view>
+          </view>
+        </view>
+      </van-tab>
+      <van-tab title="行业动态">
+        <view class="workNews">
+          <view class="list" wx:key="unique" wx:for="{{workNewsList}}" wx:for-item="item">
+            <view bindtap="companyBtn" data-item="{{item}}">
+              <view class="title">
+                {{item.title}}
+              </view>
+              <view class="other">
+                <text>{{item.orgin}}</text>
+                <text>{{item.create_time}}</text>
+              </view>
+            </view>
+          </view>
+        </view>
+      </van-tab>
+      <van-tab title="业务资料">
+        <view class="jobsNews">
+          <view class="list" wx:key="unique" wx:for="{{jobsNewsList}}" wx:for-item="item">
+            <view bindtap="companyBtn" data-item="{{item}}">
+              <view class="image">
+                <image src="{{item.imgUrl}}" wx:if="{{item.imgUrl}}"></image>
+                <image src="../images/banner2.png" wx:else></image>
+              </view>
+              <view class="other">
+                <view class="title">{{item.title}}</view>
+                <view class="type">
+                  <text>{{item.type}}</text>
+                </view>
+              </view>
+            </view>
+          </view>
+        </view>
+      </van-tab>
+    </van-tabs>
+  </view>
+</view>

+ 168 - 0
pages/news/news.wxss

@@ -0,0 +1,168 @@
+.main {
+  float: left;
+  width: 100%;
+  height: 100%;
+  background-color: #f6f6f6;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+}
+
+.main .two .companyNews {
+  float: left;
+  width: 94%;
+  margin: 10rpx 20rpx;
+}
+
+.main .two .companyNews .list {
+  float: left;
+  width: 97%;
+  padding: 10rpx;
+  box-shadow: 0 0 8rpx #ccc;
+  border-radius: 10rpx;
+  margin: 0 0 20rpx 0;
+}
+
+.main .two .companyNews .list .title {
+  float: left;
+  width: 100%;
+  padding: 10rpx 0;
+}
+
+.main .two .companyNews .list .title text:nth-child(1) {
+  float: left;
+  width: 70%;
+  font-weight: bold;
+}
+
+.main .two .companyNews .list .title text:nth-child(2) {
+  float: right;
+  width: 30%;
+  text-align: right;
+}
+
+.main .two .companyNews .list .brief {
+  float: left;
+  width: 100%;
+  font-size: 30rpx;
+  color: #666;
+  margin: 10rpx 0 0 0;
+  height: 80rpx;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  -webkit-line-clamp: 2;
+  word-break: break-all;
+  display: -webkit-box;
+  -webkit-box-orient: vertical;
+}
+
+.main .two .workNews {
+  float: left;
+  width: 94%;
+  margin: 10rpx 20rpx;
+}
+
+.main .two .workNews .list {
+  float: left;
+  width: 97%;
+  padding: 10rpx;
+  box-shadow: 0 0 8rpx #ccc;
+  border-radius: 10rpx;
+  margin: 0 0 20rpx 0;
+}
+
+.main .two .workNews .list .title {
+  font-size: 30rpx;
+}
+
+.main .two .workNews .list .other {
+  float: left;
+  width: 100%;
+}
+
+.main .two .workNews .list .other text {
+  float: left;
+  width: 49%;
+  font-size: 25rpx;
+  color: #666;
+  padding: 10rpx 0rpx;
+}
+
+.main .two .workNews .list .other text:last-child {
+  text-align: right;
+}
+
+.main .two .jobsNews {
+  float: left;
+  width: 94%;
+  margin: 10rpx 20rpx;
+}
+
+.main .two .jobsNews .list {
+  float: left;
+  width: 97%;
+  padding: 10rpx;
+  box-shadow: 0 0 8rpx #ccc;
+  border-radius: 10rpx;
+  margin: 0 0 20rpx 0;
+}
+
+.main .two .jobsNews .list .image {
+  float: left;
+  width: 25%;
+}
+
+.main .two .jobsNews .list .image image {
+  width: 150rpx;
+  height: 150rpx;
+  border-radius: 10rpx;
+}
+
+.main .two .jobsNews .list .other {
+  float: left;
+  width: 75%;
+}
+
+.main .two .jobsNews .list .other .title {
+  float: left;
+  width: 100%;
+  font-size: 28rpx;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  -webkit-line-clamp: 3;
+  word-break: break-all;
+  display: -webkit-box;
+  -webkit-box-orient: vertical;
+  margin: 0 0 8rpx 0;
+}
+
+.main .two .jobsNews .list .other .type {
+  float: left;
+  width: 100%;
+  font-size: 25rpx;
+  color: #666;
+}
+
+/* .main .two .jobsNews .list .title {
+  float: left;
+  width: 75%;
+}
+
+.main .two .jobsNews .list .title text {
+  float: left;
+  width: 100%;
+} */

文件差异内容过多而无法显示
+ 24 - 0
pages/newsDetail/newsDetail.js


+ 4 - 0
pages/newsDetail/newsDetail.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 18 - 0
pages/newsDetail/newsDetail.wxml

@@ -0,0 +1,18 @@
+<view class="main">
+  <view class="top">
+    <view class="title">{{detailInfo.title}}</view>
+    <view class="orgin">
+      <text>信息来源:{{detailInfo.orgin||'系统管理员'}}</text>
+      <text>发布时间:{{detailInfo.create_time||'暂无'}}</text>
+    </view>
+    <view class="type">
+      <text>信息类型:{{detailInfo.type||'暂无'}}</text>
+    </view>
+    <view class="image" wx:if="{{detailInfo.imgUrl}}">
+      <image src="{{detailInfo.imgUrl}}"></image>
+    </view>
+  </view>
+  <view class="down">
+    <text class="content">{{detailInfo.content}}</text>
+  </view>
+</view>

+ 72 - 0
pages/newsDetail/newsDetail.wxss

@@ -0,0 +1,72 @@
+.main {
+  float: left;
+  width: 100%;
+  height: 100%;
+}
+
+.main .top {
+  float: left;
+  width: 94%;
+  margin: 0 0 20rpx 0;
+  padding: 0 20rpx;
+}
+
+.main .top .title {
+  float: left;
+  width: 100%;
+  text-align: center;
+  font-size: 35rpx;
+  padding: 15rpx 0;
+}
+
+.main .top .orgin {
+  float: left;
+  width: 100%;
+}
+
+.main .top .orgin text {
+  float: left;
+  width: 50%;
+  text-align: center;
+  padding: 15rpx 0;
+  color: #666;
+  font-size: 30rpx;
+  font-weight: bold;
+}
+
+.main .top .type {
+  float: left;
+  width: 100%;
+  text-align: center;
+}
+
+.main .top .type text {
+  padding: 15rpx 0;
+  color: #666;
+  font-size: 30rpx;
+  font-weight: bold;
+}
+
+.main .top .image {
+  float: left;
+  width: 100%;
+  text-align: center;
+  margin: 30rpx 0 0 0;
+}
+
+.main .top .image image {
+  width: 100%;
+  height: 400rpx;
+}
+
+.main .down {
+  float: left;
+  width: 94%;
+  padding: 0 20rpx 20rpx 20rpx;
+}
+
+.main .down .content {
+  float: left;
+  width: 100%;
+  font-size: 30rpx;
+}

+ 79 - 0
pages/perssonal/perssonal.js

@@ -0,0 +1,79 @@
+// pages/perssonal/perssonal.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+    personalInfo: {
+      grade: '业务员',
+      name: '顾红伟',
+      phone: '17319450324',
+      card: '220182199603257019',
+      zfb: '17319450324',
+      type: '支付宝',
+      province: '吉林省',
+      city: '长春市',
+      meal: '169套餐',
+      card_date: '2020-10-10',
+      tjr: '你猜呢',
+      tjrPhone: '17543727325',
+    }
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad: function (options) {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面初次渲染完成
+   */
+  onReady: function () {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面显示
+   */
+  onShow: function () {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面隐藏
+   */
+  onHide: function () {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面卸载
+   */
+  onUnload: function () {
+
+  },
+
+  /**
+   * 页面相关事件处理函数--监听用户下拉动作
+   */
+  onPullDownRefresh: function () {
+
+  },
+
+  /**
+   * 页面上拉触底事件的处理函数
+   */
+  onReachBottom: function () {
+
+  },
+
+  /**
+   * 用户点击右上角分享
+   */
+  onShareAppMessage: function () {
+
+  }
+})

+ 3 - 0
pages/perssonal/perssonal.json

@@ -0,0 +1,3 @@
+{
+  "usingComponents": {}
+}

+ 45 - 0
pages/perssonal/perssonal.wxml

@@ -0,0 +1,45 @@
+<view class="main">
+  <view class="one">
+    个人信息
+  </view>
+  <view class="two">
+    <view class="twoTop">
+      <text>{{personalInfo.grade}}</text>
+    </view>
+    <view class="twoDown">
+      <van-cell-group>
+        <van-field value="{{ personalInfo.name }}" label="姓名" placeholder="姓名" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.phone }}" label="手机号" placeholder="手机号" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.card }}" label="身份证号" placeholder="身份证号" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.zfb }}" label="支付宝账号" placeholder="支付宝账号" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.type }}" label="类型" placeholder="类型" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.province }}" label="省份" placeholder="省份" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.city }}" label="市区" placeholder="市区" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.meal }}" label="套餐" placeholder="套餐" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.card_date }}" label="办卡时间" placeholder="办卡时间" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.tjr }}" label="推荐人" placeholder="推荐人" readonly />
+      </van-cell-group>
+      <van-cell-group>
+        <van-field value="{{ personalInfo.tjrPhone }}" label="推荐人手机号" placeholder="推荐人手机号" readonly />
+      </van-cell-group>
+    </view>
+  </view>
+</view>

+ 49 - 0
pages/perssonal/perssonal.wxss

@@ -0,0 +1,49 @@
+.main {
+  float: left;
+  width: 100%;
+  height: 100%;
+  /* background-image: linear-gradient(#ff0000, #ffffff); */
+  background-color: #f9fafc;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+}
+
+.main .two .twoTop {
+  float: left;
+  width: 100%;
+  text-align: center;
+  padding: 30rpx 0;
+}
+
+.main .two .twoTop text {
+  border-radius: 360rpx;
+  display: inline-block;
+  width: 150rpx;
+  height: 150rpx;
+  text-align: center;
+  line-height: 150rpx;
+  font-weight: bold;
+  color: #00FF7F;
+  background: #fff;
+  box-shadow: 0 0 5rpx #ccc;
+}
+
+.main .two .twoDown {
+  float: left;
+  width: 100%;
+}

+ 20 - 0
pages/setting/setting.js

@@ -0,0 +1,20 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+    form: {}
+  },
+  //事件处理函数
+  formSubmit: function (e) {
+    let data = e.detail.value;
+    console.log(data);
+  },
+  onLoad: function () {
+    var phone = 'form.phone'
+    this.setData({
+      [phone]: '17319450324'
+    })
+  },
+})

+ 4 - 0
pages/setting/setting.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 24 - 0
pages/setting/setting.wxml

@@ -0,0 +1,24 @@
+<view class="main">
+  <view class="one">
+    设置账号
+  </view>
+  <view class="two">
+    <form bindsubmit="formSubmit" bindreset="formReset">
+      <view class="content">
+        <text>手机号</text>
+        <input type='number' name="phone" value="{{form.phone}}" placeholder='手机号'></input>
+      </view>
+      <view class="content">
+        <text>支付宝账号</text>
+        <input type='text' name="zfb" value="{{form.zfb}}" placeholder='支付宝账号'></input>
+      </view>
+      <view class="content">
+        <text>支付宝姓名</text>
+        <input type='text' name="name" value="{{form.name}}" placeholder='支付宝姓名'></input>
+      </view>
+      <view class="save">
+        <button form-type="submit">登录</button>
+      </view>
+    </form>
+  </view>
+</view>

+ 59 - 0
pages/setting/setting.wxss

@@ -0,0 +1,59 @@
+.main {
+  float: left;
+  width: 100%;
+  height: 100%;
+  /* background-image: linear-gradient(#ff0000, #ffffff); */
+  background-color: #f9fafc;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  margin: 20rpx 0 0 0;
+}
+
+.main .two .content {
+  float: left;
+  width: 94%;
+  height: 80rpx;
+  line-height: 80rpx;
+  margin: 0 20rpx;
+  border-bottom: 1px solid #ccc;
+}
+
+
+.main .two .content text {
+  float: left;
+  width: 30%;
+  font-size: 30rpx;
+}
+
+.main .two .content input {
+  float: left;
+  width: 70%;
+  padding: 18rpx 0;
+}
+
+.main .two .save {
+  float: left;
+  width: 94%;
+  margin: 60rpx 20rpx 0 20rpx;
+}
+
+.main .two .save button {
+  border-radius: 50rpx;
+  background-color: #ff0000;
+  color: #ffffff;
+}

+ 17 - 0
pages/shareholder/shareholder.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/shareholder/shareholder.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/shareholder/shareholder.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    股东奖池
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/shareholder/shareholder.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 17 - 0
pages/team/team.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/team/team.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/team/team.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    我的团队
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/team/team.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 1 - 1
pages/test/test.wxml

@@ -1,4 +1,4 @@
 <!--index.wxml-->
 <view class="container">
-  <van-button type="primary" round>测试页面</van-button>
+  <van-button type="primary" round bindtap="bindViewTap">测试页面</van-button>
 </view>

+ 17 - 0
pages/user/user.js

@@ -0,0 +1,17 @@
+//index.js
+//获取应用实例
+const app = getApp()
+
+Page({
+  data: {
+
+  },
+  //事件处理函数
+  bindViewTap: function () {
+    wx.navigateTo({
+      url: '../index/index'
+    })
+  },
+  onLoad: function () {
+  },
+})

+ 4 - 0
pages/user/user.json

@@ -0,0 +1,4 @@
+{
+  "component": true,
+  "usingComponents": {}
+}

+ 8 - 0
pages/user/user.wxml

@@ -0,0 +1,8 @@
+<view class="main">
+  <view class="one">
+    用户列表
+  </view>
+  <view class="two">
+    内容
+  </view>
+</view>

+ 22 - 0
pages/user/user.wxss

@@ -0,0 +1,22 @@
+.main {
+  float: left;
+  width: 100%;
+}
+
+.main .one {
+  position: fixed;
+  z-index: 9999;
+  width: 100%;
+  height: 80rpx;
+  line-height: 80rpx;
+  background-color: #409eff;
+  color: #ffffff;
+  text-align: center;
+}
+
+.main .two {
+  position: absolute;
+  top: 80rpx;
+  width: 100%;
+  height: 15000px;
+}

+ 447 - 0
utils/wxValidate.js

@@ -0,0 +1,447 @@
+/**
+ * 琛ㄥ崟楠岃瘉
+ * 
+ * @param {Object} rules 验证字段的规则
+ * @param {Object} messages 验证字段的提示信息
+ * 
+ */
+class WxValidate {
+	constructor(rules = {}, messages = {}) {
+		Object.assign(this, {
+			data: {},
+			rules,
+			messages,
+		})
+		this.__init()
+	}
+
+	/**
+	 * __init
+	 */
+	__init() {
+		this.__initMethods()
+		this.__initDefaults()
+		this.__initData()
+	}
+
+	/**
+	 * 鍒濆鍖栨暟鎹�
+	 */
+	__initData() {
+		this.form = {}
+		this.errorList = []
+	}
+
+	/**
+	 * 鍒濆鍖栭粯璁ゆ彁绀轰俊鎭�
+	 */
+	__initDefaults() {
+		this.defaults = {
+			messages: {
+				required: '这是必填字段。',
+				email: '请输入有效的电子邮件地址。',
+				tel: '请输入11位的手机号码。',
+				url: '请输入有效的网址。',
+				date: '请输入有效的日期。',
+				dateISO: '请输入有效的日期(ISO),例如:2009-06-23,1998/01/22。',
+				number: '请输入有效的数字。',
+				digits: '只能输入数字。',
+				idcard: '请输入18位的有效身份证。',
+				equalTo: this.formatTpl('输入值必须和 {0} 相同。'),
+				contains: this.formatTpl('输入值必须包含 {0}。'),
+				minlength: this.formatTpl('最少要输入 {0} 个字符。'),
+				maxlength: this.formatTpl('最多可以输入 {0} 个字符。'),
+				rangelength: this.formatTpl('请输入长度在 {0} 到 {1} 之间的字符。'),
+				min: this.formatTpl('请输入不小于 {0} 的数值。'),
+				max: this.formatTpl('请输入不大于 {0} 的数值。'),
+				range: this.formatTpl('请输入范围在 {0} 到 {1} 之间的数值。'),
+			}
+		}
+	}
+
+	/**
+	 * 鍒濆鍖栭粯璁ら獙璇佹柟娉�
+	 */
+	__initMethods() {
+		const that = this
+		that.methods = {
+			/**
+			 * 这是必填字段。
+			 */
+			required(value, param) {
+				if (!that.depend(param)) {
+					return "dependency-mismatch";
+				} else if (typeof value === "number") {
+					value = value.toString();
+				} else if (typeof value === "boolean") {
+					return !0;
+				}
+
+				return value.length > 0;
+			},
+			/**
+			 * 请输入有效的电子邮件地址。
+			 */
+			email(value) {
+				return (
+					that.optional(value) ||
+					/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(
+						value
+					)
+				);
+			},
+			/**
+			 * 请输入11位的手机号码。
+			 */
+			tel(value) {
+				return that.optional(value) || /^1[34578]\d{9}$/.test(value);
+			},
+			/**
+			 * 请输入有效的网址。
+			 */
+			url(value) {
+				return (
+					that.optional(value) ||
+					/^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)(?:\.(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)*(?:\.(?:[a-z\u00a1-\uffff]{2,})).?)(?::\d{2,5})?(?:[/?#]\S*)?$/i.test(
+						value
+					)
+				);
+			},
+			/**
+			 * 请输入有效的日期。
+			 */
+			date(value) {
+				return (
+					that.optional(value) ||
+					!/Invalid|NaN/.test(new Date(value).toString())
+				);
+			},
+			/**
+			 * 请输入有效的日期(ISO),例如:2009-06-23,1998/01/22。
+			 */
+			dateISO(value) {
+				return (
+					that.optional(value) ||
+					/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$/.test(
+						value
+					)
+				);
+			},
+			/**
+			 * 请输入有效的数字。
+			 */
+			number(value) {
+				return (
+					that.optional(value) ||
+					/^(?:-?\d+|-?\d{1,3}(?:,\d{3})+)?(?:\.\d+)?$/.test(value)
+				);
+			},
+			/**
+			 * 只能输入数字。
+			 */
+			digits(value) {
+				return that.optional(value) || /^\d+$/.test(value);
+			},
+			/**
+			 * 请输入18位的有效身份证。
+			 */
+			idcard(value) {
+				return (
+					that.optional(value) ||
+					/^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X)$/.test(
+						value
+					)
+				);
+			},
+			/**
+			 * 输入值必须和 field 相同
+			 */
+			equalTo(value, param) {
+				return that.optional(value) || value === that.data[param];
+			},
+			/**
+			 * 输入值必须包含 ABC
+			 */
+			contains(value, param) {
+				return that.optional(value) || value.indexOf(param) >= 0;
+			},
+			/**
+			 * 最少要输入 5 个字符
+			 */
+			minlength(value, param) {
+				return that.optional(value) || value.length >= param;
+			},
+			/**
+			 * 最多可以输入 10 个字符
+			 */
+			maxlength(value, param) {
+				return that.optional(value) || value.length <= param;
+			},
+			/**
+			 * 请输入长度在 5 到 10 之间的字符
+			 */
+			rangelength(value, param) {
+				return (
+					that.optional(value) ||
+					(value.length >= param[0] && value.length <= param[1])
+				);
+			},
+			/**
+			 * 请输入不小于 5 的数值
+			 */
+			min(value, param) {
+				return that.optional(value) || value >= param;
+			},
+			/**
+			 * 请输入不大于 10 的数值
+			 */
+			max(value, param) {
+				return that.optional(value) || value <= param;
+			},
+			/**
+			 * 请输入范围在 5 到 10 之间的数值
+			 */
+			range(value, param) {
+				return that.optional(value) || (value >= param[0] && value <= param[1]);
+			},
+		};
+	}
+
+	/**
+	 * 娣诲姞鑷畾涔夐獙璇佹柟娉�
+	 * @param {String} name 鏂规硶鍚�
+	 * @param {Function} method 鍑芥暟浣擄紝鎺ユ敹涓や釜鍙傛暟(value, param)锛寁alue琛ㄧず鍏冪礌鐨勫€硷紝param琛ㄧず鍙傛暟
+	 * @param {String} message 鎻愮ず淇℃伅
+	 */
+	addMethod(name, method, message) {
+		this.methods[name] = method
+		this.defaults.messages[name] = message !== undefined ? message : this.defaults.messages[name]
+	}
+
+	/**
+	 * 鍒ゆ柇楠岃瘉鏂规硶鏄惁瀛樺湪
+	 */
+	isValidMethod(value) {
+		let methods = []
+		for (let method in this.methods) {
+			if (method && typeof this.methods[method] === 'function') {
+				methods.push(method)
+			}
+		}
+		return methods.indexOf(value) !== -1
+	}
+
+	/**
+	 * 鏍煎紡鍖栨彁绀轰俊鎭ā鏉�
+	 */
+	formatTpl(source, params) {
+		const that = this
+		if (arguments.length === 1) {
+			return function () {
+				let args = Array.from(arguments)
+				args.unshift(source)
+				return that.formatTpl.apply(this, args)
+			}
+		}
+		if (params === undefined) {
+			return source
+		}
+		if (arguments.length > 2 && params.constructor !== Array) {
+			params = Array.from(arguments).slice(1)
+		}
+		if (params.constructor !== Array) {
+			params = [params]
+		}
+		params.forEach(function (n, i) {
+			source = source.replace(new RegExp("\\{" + i + "\\}", "g"), function () {
+				return n
+			})
+		})
+		return source
+	}
+
+	/**
+	 * 鍒ゆ柇瑙勫垯渚濊禆鏄惁瀛樺湪
+	 */
+	depend(param) {
+		switch (typeof param) {
+			case 'boolean':
+				param = param
+				break
+			case 'string':
+				param = !!param.length
+				break
+			case 'function':
+				param = param()
+			default:
+				param = !0
+		}
+		return param
+	}
+
+	/**
+	 * 鍒ゆ柇杈撳叆鍊兼槸鍚︿负绌�
+	 */
+	optional(value) {
+		return !this.methods.required(value) && 'dependency-mismatch'
+	}
+
+	/**
+	 * 鑾峰彇鑷畾涔夊瓧娈电殑鎻愮ず淇℃伅
+	 * @param {String} param 瀛楁鍚�
+	 * @param {Object} rule 瑙勫垯
+	 */
+	customMessage(param, rule) {
+		const params = this.messages[param]
+		const isObject = typeof params === 'object'
+		if (params && isObject) return params[rule.method]
+	}
+
+	/**
+	 * 鑾峰彇鏌愪釜鎸囧畾瀛楁鐨勬彁绀轰俊鎭�
+	 * @param {String} param 瀛楁鍚�
+	 * @param {Object} rule 瑙勫垯
+	 */
+	defaultMessage(param, rule) {
+		let message = this.customMessage(param, rule) || this.defaults.messages[rule.method]
+		let type = typeof message
+
+		if (type === 'undefined') {
+			message = `Warning: No message defined for ${rule.method}.`
+		} else if (type === 'function') {
+			message = message.call(this, rule.parameters)
+		}
+
+		return message
+	}
+
+	/**
+	 * 缂撳瓨閿欒淇℃伅
+	 * @param {String} param 瀛楁鍚�
+	 * @param {Object} rule 瑙勫垯
+	 * @param {String} value 鍏冪礌鐨勫€�
+	 */
+	formatTplAndAdd(param, rule, value) {
+		let msg = this.defaultMessage(param, rule)
+
+		this.errorList.push({
+			param: param,
+			msg: msg,
+			value: value,
+		})
+	}
+
+	/**
+	 * 楠岃瘉鏌愪釜鎸囧畾瀛楁鐨勮鍒�
+	 * @param {String} param 瀛楁鍚�
+	 * @param {Object} rules 瑙勫垯
+	 * @param {Object} data 闇€瑕侀獙璇佺殑鏁版嵁瀵硅薄
+	 */
+	checkParam(param, rules, data) {
+
+		// 缂撳瓨鏁版嵁瀵硅薄
+		this.data = data
+
+		// 缂撳瓨瀛楁瀵瑰簲鐨勫€�
+		const value = data[param] !== null && data[param] !== undefined ? data[param] : ''
+
+		// 閬嶅巻鏌愪釜鎸囧畾瀛楁鐨勬墍鏈夎鍒欙紝渚濇楠岃瘉瑙勫垯锛屽惁鍒欑紦瀛橀敊璇俊鎭�
+		for (let method in rules) {
+
+			// 鍒ゆ柇楠岃瘉鏂规硶鏄惁瀛樺湪
+			if (this.isValidMethod(method)) {
+
+				// 缂撳瓨瑙勫垯鐨勫睘鎬у強鍊�
+				const rule = {
+					method: method,
+					parameters: rules[method]
+				}
+
+				// 璋冪敤楠岃瘉鏂规硶
+				const result = this.methods[method](value, rule.parameters)
+
+				// 鑻esult杩斿洖鍊间负dependency-mismatch锛屽垯璇存槑璇ュ瓧娈电殑鍊间负绌烘垨闈炲繀濉瓧娈�
+				if (result === 'dependency-mismatch') {
+					continue
+				}
+
+				this.setValue(param, method, result, value)
+
+				// 鍒ゆ柇鏄惁閫氳繃楠岃瘉锛屽惁鍒欑紦瀛橀敊璇俊鎭紝璺冲嚭寰幆
+				if (!result) {
+					this.formatTplAndAdd(param, rule, value)
+					break
+				}
+			}
+		}
+	}
+
+	/**
+	 * 璁剧疆瀛楁鐨勯粯璁ら獙璇佸€�
+	 * @param {String} param 瀛楁鍚�
+	 */
+	setView(param) {
+		this.form[param] = {
+			$name: param,
+			$valid: true,
+			$invalid: false,
+			$error: {},
+			$success: {},
+			$viewValue: ``,
+		}
+	}
+
+	/**
+	 * 璁剧疆瀛楁鐨勯獙璇佸€�
+	 * @param {String} param 瀛楁鍚�
+	 * @param {String} method 瀛楁鐨勬柟娉�
+	 * @param {Boolean} result 鏄惁閫氳繃楠岃瘉
+	 * @param {String} value 瀛楁鐨勫€�
+	 */
+	setValue(param, method, result, value) {
+		const params = this.form[param]
+		params.$valid = result
+		params.$invalid = !result
+		params.$error[method] = !result
+		params.$success[method] = result
+		params.$viewValue = value
+	}
+
+	/**
+	 * 楠岃瘉鎵€鏈夊瓧娈电殑瑙勫垯锛岃繑鍥為獙璇佹槸鍚﹂€氳繃
+	 * @param {Object} data 闇€瑕侀獙璇佹暟鎹璞�
+	 */
+	checkForm(data) {
+		this.__initData()
+
+		for (let param in this.rules) {
+			this.setView(param)
+			this.checkParam(param, this.rules[param], data)
+		}
+
+		return this.valid()
+	}
+
+	/**
+	 * 杩斿洖楠岃瘉鏄惁閫氳繃
+	 */
+	valid() {
+		return this.size() === 0
+	}
+
+	/**
+	 * 杩斿洖閿欒淇℃伅鐨勪釜鏁�
+	 */
+	size() {
+		return this.errorList.length
+	}
+
+	/**
+	 * 杩斿洖鎵€鏈夐敊璇俊鎭�
+	 */
+	validationErrors() {
+		return this.errorList
+	}
+}
+
+export default WxValidate