Bladeren bron

Merge branch 'master' of http://git.cc-lotus.info/ball-court/ball-applet

guhongwei 2 jaren geleden
bovenliggende
commit
e2444db9db

+ 2 - 1
pagesMatch/matchAdmin/address/list.js

@@ -108,7 +108,8 @@ Page({
      * 生命周期函数--监听页面卸载
      */
     onUnload: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 3 - 7
pagesMatch/matchAdmin/mtgroup/auto.js

@@ -121,7 +121,7 @@ Page({
             that.setData({ memberList: mem });
             wx.showToast({ title: `小组赛维护信息完成`, icon: 'success', duration: 2000 });
             that.toClose();
-            that.searchOther(list);
+            that.setData({ list });
         }
     },
     //自动生成
@@ -131,7 +131,7 @@ Page({
         const arr = await app.$post(`/matchTeamGroup/auto`, params, 'race');
         if (arr.errcode == '0') {
             that.toClose();
-            that.searchOther(arr.data);
+            that.setData({ list: arr.data });
         }
         else wx.showToast({ title: `${arr.errmsg}`, icon: 'none', duration: 2000 })
     },
@@ -177,10 +177,6 @@ Page({
         // 监听用户是否登录
         that.watchLogin();
     },
-    searchOther: async function (e) {
-        const that = this;
-        that.setData({ list: e });
-    },
     // 监听用户是否登录
     watchLogin: async function () {
         const that = this;
@@ -203,7 +199,7 @@ Page({
     /**
      * 生命周期函数--监听页面显示
      */
-    onShow: async function () {},
+    onShow: async function () { },
     /**
      * 页面上拉触底事件的处理函数
      */

+ 2 - 1
pagesMatch/matchAdmin/mtgroup/list.js

@@ -114,7 +114,8 @@ Page({
      * 生命周期函数--监听页面隐藏
      */
     onHide: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 1 - 1
pagesMatch/matchAdmin/mtschedule/add.js

@@ -1,7 +1,7 @@
 const app = getApp();
 Page({
     data: {
-        frameStyle: { useTop: true, name: '基本页面', leftArrow: true, useBar: false },
+        frameStyle: { useTop: true, name: '赛程信息', leftArrow: true, useBar: false },
     },
     // 返回
     back: function () { wx.navigateBack({ delta: 1 }) },

+ 3 - 2
pagesMatch/matchAdmin/mtschedule/list.js

@@ -1,7 +1,7 @@
 const app = getApp();
 Page({
     data: {
-        frameStyle: { useTop: true, name: '基本页面', leftArrow: true, useBar: false },
+        frameStyle: { useTop: true, name: '赛程设置', leftArrow: true, useBar: false },
     },
     // 返回
     back: function () { wx.navigateBack({ delta: 1 }) },
@@ -47,7 +47,8 @@ Page({
      * 生命周期函数--监听页面卸载
      */
     onUnload: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 67 - 1
pagesMatch/matchAdmin/mtschedule/list.less

@@ -5,7 +5,73 @@
     background-color: var(--mainColor);
 
     .one {
-        width: 100vw;
+        display: flex;
+        flex-direction: row;
+        padding: 2vw;
+        border-bottom: 1px solid var(--f1Color);
+
+        .one_1 {
+            flex-grow: 1;
+
+            input {
+                padding: 1vw 0 2vw 2vw;
+                background-color: var(--f1Color);
+                border-radius: 5px;
+            }
+        }
+
+        .one_2 {
+            width: 20vw;
+
+            button {
+                width: 100%;
+                padding: 2vw;
+                font-size: var(--font14Size);
+            }
+        }
+    }
+
+    .two {
+        position: relative;
+        flex-grow: 1;
+        background-color: var(--whiteColor);
+        padding: 0 2vw;
+
+        .list {
+            background-color: var(--f9Color);
+            margin: 0 0 2vw 0;
+            padding: 2vw;
+            margin: 0 2vw 2vw 2vw;
+            border-radius: 5px;
+
+            .name {
+                font-size: var(--font16Szie);
+                font-weight: bold;
+                margin: 0 0 1vw 0;
+            }
+
+            .other {
+                margin: 0 0 1vw 0;
+
+                .other_1 {
+                    margin: 0 0 1vw 0;
+                    font-size: var(--font14Size);
+
+                    text:first-child {
+                        color: var(--f85Color);
+                    }
+                }
+            }
+
+            .btn {
+                text-align: center;
+
+                button {
+                    margin: 0 2vw;
+                    font-size: var(--font14Size);
+                }
+            }
+        }
     }
 }
 

+ 41 - 1
pagesMatch/matchAdmin/mtschedule/list.wxml

@@ -1,7 +1,47 @@
 <mobile-main frameStyle="{{frameStyle}}" bind:back="back">
     <view slot="info" class="container main">
         <view class="one">
-            基本页面
+            <view class="one_1">
+                <input type="text" placeholder="请输入关键词" />
+            </view>
+            <view class="one_2">
+                <button type="primary" bindtap="toCommon" data-route="match/add">添加</button>
+            </view>
+        </view>
+        <view class="two">
+            <scroll-view scroll-y="true" class="scroll-view" bindscrolltolower="toPage">
+                <view class="list-scroll-view">
+                    <view class="list" wx:for="{{list}}" wx:key="item">
+                        <view class="name">{{item.name||'暂无'}}</view>
+                        <view class="other">
+                            <view class="other_1">
+                                <text>赛事类别:</text>
+                                <text>{{item.zhtype}}</text>
+                            </view>
+                            <view class="other_1">
+                                <text>比赛时间:</text>
+                                <text>{{item.start_time}}至{{item.end_time}}</text>
+                            </view>
+                            <view class="other_1">
+                                <text>报名截止时间:</text>
+                                <text>{{item.sign_time}}</text>
+                            </view>
+                            <view class="other_1">
+                                <text>报名费用:</text>
+                                <text>{{item.money}}</text>
+                            </view>
+                            <view class="other_1">
+                                <text>比赛状态:</text>
+                                <text>{{item.zhstatus}}</text>
+                            </view>
+                        </view>
+                        <view class="btn">
+                            <button type="primary" size="mini" bindtap="toEdit" data-item="{{item}}">信息维护</button>
+                            <button type="warn" size="mini" bindtap="toDel" data-item="{{item}}">赛事删除</button>
+                        </view>
+                    </view>
+                </view>
+            </scroll-view>
         </view>
     </view>
 </mobile-main>

+ 55 - 1
pagesMatch/matchAdmin/mtschedule/list.wxss

@@ -4,7 +4,61 @@
   background-color: var(--mainColor);
 }
 .main .one {
-  width: 100vw;
+  display: flex;
+  flex-direction: row;
+  padding: 2vw;
+  border-bottom: 1px solid var(--f1Color);
+}
+.main .one .one_1 {
+  flex-grow: 1;
+}
+.main .one .one_1 input {
+  padding: 1vw 0 2vw 2vw;
+  background-color: var(--f1Color);
+  border-radius: 5px;
+}
+.main .one .one_2 {
+  width: 20vw;
+}
+.main .one .one_2 button {
+  width: 100%;
+  padding: 2vw;
+  font-size: var(--font14Size);
+}
+.main .two {
+  position: relative;
+  flex-grow: 1;
+  background-color: var(--whiteColor);
+  padding: 0 2vw;
+}
+.main .two .list {
+  background-color: var(--f9Color);
+  margin: 0 0 2vw 0;
+  padding: 2vw;
+  margin: 0 2vw 2vw 2vw;
+  border-radius: 5px;
+}
+.main .two .list .name {
+  font-size: var(--font16Szie);
+  font-weight: bold;
+  margin: 0 0 1vw 0;
+}
+.main .two .list .other {
+  margin: 0 0 1vw 0;
+}
+.main .two .list .other .other_1 {
+  margin: 0 0 1vw 0;
+  font-size: var(--font14Size);
+}
+.main .two .list .other .other_1 text:first-child {
+  color: var(--f85Color);
+}
+.main .two .list .btn {
+  text-align: center;
+}
+.main .two .list .btn button {
+  margin: 0 2vw;
+  font-size: var(--font14Size);
 }
 .scroll-view {
   position: absolute;

+ 2 - 1
pagesMatch/matchAdmin/profit/list.js

@@ -87,7 +87,8 @@ Page({
      * 生命周期函数--监听页面隐藏
      */
     onHide: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 2 - 1
pagesMatch/matchAdmin/referee/list.js

@@ -198,7 +198,8 @@ Page({
      * 生命周期函数--监听页面卸载
      */
     onUnload: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 2 - 1
pagesMatch/matchAdmin/refund/list.js

@@ -124,7 +124,8 @@ Page({
      * 生命周期函数--监听页面卸载
      */
     onUnload: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 2 - 1
pagesMatch/matchAdmin/sign/list.js

@@ -121,7 +121,8 @@ Page({
      * 生命周期函数--监听页面隐藏
      */
     onHide: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**

+ 2 - 1
pagesMatch/matchAdmin/teamapply/list.js

@@ -143,7 +143,8 @@ Page({
      * 生命周期函数--监听页面隐藏
      */
     onHide: function () {
-
+        const that = this;
+        that.setData({ skip: 0, page: 0, list: [] })
     },
 
     /**