lmj 2 years ago
parent
commit
9265570762
6 changed files with 129 additions and 7 deletions
  1. 12 7
      app.json
  2. 66 0
      pages/logon/logon.js
  3. 3 0
      pages/logon/logon.json
  4. 21 0
      pages/logon/logon.wxml
  5. 14 0
      pages/logon/logon.wxss
  6. 13 0
      project.private.config.json

+ 12 - 7
app.json

@@ -1,16 +1,21 @@
 {
-  "pages":[
+  "pages": [
+    "pages/logon/logon",
     "pages/index/index",
     "pages/logs/logs"
+    
   ],
-  "window":{
-    "backgroundTextStyle":"light",
+  "window": {
+    "backgroundTextStyle": "light",
     "navigationBarBackgroundColor": "#fff",
-    "navigationBarTitleText": "Weixin",
-    "navigationBarTextStyle":"black"
+    "navigationBarTitleText": "登录",
+    "navigationBarTextStyle": "black"
   },
   "sitemapLocation": "sitemap.json",
   "usingComponents": {
-    "van-button": "@vant/weapp/button/index"
+    "van-button": "@vant/weapp/button/index",
+    "van-icon": "@vant/weapp/icon/index",
+    "van-field": "@vant/weapp/field/index",
+    "van-image": "@vant/weapp/image/index"
   }
-}
+}

+ 66 - 0
pages/logon/logon.js

@@ -0,0 +1,66 @@
+// pages/logon/logon.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad(options) {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面初次渲染完成
+   */
+  onReady() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面显示
+   */
+  onShow() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面隐藏
+   */
+  onHide() {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面卸载
+   */
+  onUnload() {
+
+  },
+
+  /**
+   * 页面相关事件处理函数--监听用户下拉动作
+   */
+  onPullDownRefresh() {
+
+  },
+
+  /**
+   * 页面上拉触底事件的处理函数
+   */
+  onReachBottom() {
+
+  },
+
+  /**
+   * 用户点击右上角分享
+   */
+  onShareAppMessage() {
+
+  }
+})

+ 3 - 0
pages/logon/logon.json

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

+ 21 - 0
pages/logon/logon.wxml

@@ -0,0 +1,21 @@
+<van-icon class="logon" size="100px" name="https://b.yzcdn.cn/vant/icon-demo-1126.png" />
+<van-cell-group class="logon-info">
+  <van-field
+    value="{{ value }}"
+    placeholder="请输入你的账号"
+    border="{{ true }}"
+  />
+  <van-cell-group>
+  <van-field
+     value="{{ value }}"
+    placeholder="请输入新密码"
+    border="{{ true }}"
+  />
+</van-cell-group>
+</van-cell-group>
+<van-button class="button" type="info" size="normal">登录</van-button>
+
+
+
+
+

+ 14 - 0
pages/logon/logon.wxss

@@ -0,0 +1,14 @@
+.logon{
+  margin: 110px;
+  margin-top: 25px;
+}
+.logon-info{
+  display: block;
+  margin-left: 50px;
+  margin-top: -10px;
+}
+.button{
+  display: block;
+  margin-left:125px ;
+  margin-top:50px ;
+}

+ 13 - 0
project.private.config.json

@@ -3,5 +3,18 @@
   "projectname": "delivery-business",
   "setting": {
     "compileHotReLoad": true
+  },
+  "condition": {
+    "miniprogram": {
+      "list": [
+        {
+          "name": "登录页面",
+          "pathName": "pages/logon/logon",
+          "query": "logon",
+          "launchMode": "default",
+          "scene": null
+        }
+      ]
+    }
   }
 }