guhongwei 2 年 前
コミット
e29c073101
55 ファイル変更892 行追加372 行削除
  1. 17 16
      app.json
  2. 4 2
      pages/administration/index.js
  3. 54 54
      pages/administration/index.wxml
  4. 15 30
      pages/editBasic/index.js
  5. 0 0
      pages/basic/index.json
  6. 0 0
      pages/basic/index.wxml
  7. 0 0
      pages/basic/index.wxss
  8. 15 12
      pages/home/index.js
  9. 30 19
      pages/home/index.wxml
  10. 106 43
      pages/home/index.wxss
  11. 3 46
      pages/match/info.js
  12. 84 0
      pages/match/schedule.js
  13. 0 0
      pages/match/schedule.json
  14. 5 0
      pages/match/schedule.wxml
  15. 4 0
      pages/match/schedule.wxss
  16. 3 3
      pages/addmatch/index.js
  17. 6 0
      pages/matchAdd/index.json
  18. 0 0
      pages/matchAdd/index.wxml
  19. 0 0
      pages/matchAdd/index.wxss
  20. 0 0
      pages/matchTeampm/index.js
  21. 0 0
      pages/matchTeampm/index.json
  22. 0 0
      pages/matchTeampm/index.wxml
  23. 0 0
      pages/matchTeampm/index.wxss
  24. 0 0
      pages/matchTeamsh/index.js
  25. 0 0
      pages/matchTeamsh/index.json
  26. 0 0
      pages/matchTeamsh/index.wxml
  27. 0 0
      pages/matchTeamsh/index.wxss
  28. 3 3
      pages/matchadmin/index.wxml
  29. 4 0
      pages/matchadmin/layoutInfo.js
  30. 4 4
      pages/matchadmin/layoutInfo.wxml
  31. 7 2
      pages/matchteam/index.js
  32. 3 0
      pages/matchteam/index.wxml
  33. 84 0
      pages/matchteam/layout.js
  34. 6 0
      pages/matchteam/layout.json
  35. 5 0
      pages/matchteam/layout.wxml
  36. 4 0
      pages/matchteam/layout.wxss
  37. 44 53
      pages/me/index.js
  38. 2 2
      pages/me/index.wxml
  39. 0 2
      pages/search/index.js
  40. 0 0
      pages/teamDissolution/index.js
  41. 0 0
      pages/teamDissolution/index.json
  42. 0 0
      pages/teamDissolution/index.wxml
  43. 0 0
      pages/teamDissolution/index.wxss
  44. 0 3
      pages/teamInfo/index.wxml
  45. 181 0
      pages/teamMembers/index.js
  46. 7 0
      pages/teamMembers/index.json
  47. 63 0
      pages/teamMembers/index.wxml
  48. 125 0
      pages/teamMembers/index.wxss
  49. 2 2
      pages/teamapply/index.json
  50. 0 66
      pages/uploadScore/index.js
  51. 0 3
      pages/uploadScore/index.json
  52. 0 2
      pages/uploadScore/index.wxml
  53. 0 1
      pages/uploadScore/index.wxss
  54. 0 2
      pages/uploadimg/index.js
  55. 2 2
      utils/dict.js

+ 17 - 16
app.json

@@ -4,30 +4,31 @@
         "pages/login/index",
         "pages/register/index",
         "pages/home/index",
+        "pages/match/info",
+        "pages/match/schedule",
         "pages/search/index",
-        "pages/teamrank/index",
-        "pages/teamexam/index",
-        "pages/team/index",
-        "pages/teamInfo/index",
+        "pages/administration/index",
+        "pages/matchAdd/index",
+        "pages/matchTeampm/index",
+        "pages/matchTeamsh/index",
         "pages/teamInfo/info",
+        "pages/team/index",
         "pages/me/index",
-        "pages/match/info",
+        "pages/basic/index",
+        "pages/user/index",
+        "pages/user/detail",
         "pages/matchadmin/index",
-        "pages/addmatch/index",
         "pages/matchadmin/layoutInfo",
         "pages/matchadmin/layout",
-        "pages/editBasic/index",
-        "pages/uploadimg/index",
-        "pages/uploadScore/index",
-        "pages/updatepd/index",
-        "pages/exammembers/index",
-        "pages/teamapply/index",
+        "pages/teamInfo/index",
         "pages/matchteam/index",
         "pages/matchteam/detail",
-        "pages/administration/index",
-        "pages/teamdismissteam/index",
-        "pages/user/index",
-        "pages/user/detail",
+        "pages/matchteam/layout",
+        "pages/teamMembers/index",
+        "pages/teamDissolution/index",
+        "pages/teamapply/index",
+        "pages/uploadimg/index",
+        "pages/updatepd/index",
         "pages/test/index",
         "pages/logs/logs"
     ],

+ 4 - 2
pages/administration/index.js

@@ -36,15 +36,17 @@ Page({
     tabsChange: function (e) {
         const that = this;
         that.setData({ 'tabs.active': e.detail.name })
+        that.watchLogin();
     },
     // 公共路由跳转方法
     toCommon: function (e) {
         const { route } = e.currentTarget.dataset;
         wx.navigateTo({ url: `/pages/${route}/index` })
     },
-    // 查看详情
+    // 查看比赛信息
     toView: function (e) {
-        console.log(e);
+        const { id } = e.currentTarget.dataset;
+        wx.navigateTo({ url: `/pages/match/info?id=${id}` })
     },
     /**
      * 生命周期函数--监听页面加载

+ 54 - 54
pages/administration/index.wxml

@@ -1,62 +1,62 @@
 <mobile-main frameStyle="{{frameStyle}}" bind:back="back" bind:tabPath="tabPath">
-  <view slot="info" class="main" style="height:{{infoHeight}}px;">
-    <view class="one">
-      <image src="{{bg_1}}"></image>
-    </view>
-    <view class="two">
-      <view class="two_1" bindtap="toCommon" data-route="addmatch">
-        <image src="{{bg_2}}"></image>
-        <view><text>创建比赛</text></view>
-      </view>
-      <view class="two_2">
-        <view class="two_2_1" bindtap="toCommon" data-route="teamrank">
-          <image class="image" src="{{bg_3}}"></image>
-          <view class="txt">
-            <text>团队排名</text>
-            <image src="{{pm_1}}"></image>
-          </view>
-        </view>
-        <view class="two_2_1" bindtap="toCommon" data-route="teamexam">
-          <image class="image" src="{{bg_3}}"></image>
-          <view class="txt">
-            <text>团队审批</text>
-            <image src="{{sp_1}}"></image>
-          </view>
+    <view slot="info" class="main" style="height:{{infoHeight}}px;">
+        <view class="one">
+            <image src="{{bg_1}}"></image>
         </view>
-      </view>
-      <view class="two_3">
-        <e-tabs tabs="{{tabs}}" bind:tabsChange="tabsChange"></e-tabs>
-        <view wx:if="{{tabs.active=='3'}}" class="a">
-          <view class="list" wx:for="{{list}}" wx:key="item">
-            <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
-              <text>{{item.name}}</text>
-              <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+        <view class="two">
+            <view class="two_1" bindtap="toCommon" data-route="matchAdd">
+                <image src="{{bg_2}}"></image>
+                <view><text>创建比赛</text></view>
             </view>
-            <view class="list_2 textOver">{{item.match_time}}</view>
-            <view class="list_3 textOver">{{item.address}}</view>
-          </view>
-        </view>
-        <view wx:if="{{tabs.active=='0'}}" class="a">
-          <view class="list" wx:for="{{list}}" wx:key="item">
-            <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
-              <text>{{item.name}}</text>
-              <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+            <view class="two_2">
+                <view class="two_2_1" bindtap="toCommon" data-route="matchTeampm">
+                    <image class="image" src="{{bg_3}}"></image>
+                    <view class="txt">
+                        <text>团队排名</text>
+                        <image src="{{pm_1}}"></image>
+                    </view>
+                </view>
+                <view class="two_2_1" bindtap="toCommon" data-route="matchTeamsh">
+                    <image class="image" src="{{bg_3}}"></image>
+                    <view class="txt">
+                        <text>团队审批</text>
+                        <image src="{{sp_1}}"></image>
+                    </view>
+                </view>
             </view>
-            <view class="list_2 textOver">{{item.match_time}}</view>
-            <view class="list_3 textOver">{{item.address}}</view>
-          </view>
-        </view>
-        <view wx:if="{{tabs.active=='4'}}" class="a">
-          <view class="list" wx:for="{{list}}" wx:key="item">
-            <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
-              <text>{{item.name}}</text>
-              <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+            <view class="two_3">
+                <e-tabs tabs="{{tabs}}" bind:tabsChange="tabsChange"></e-tabs>
+                <view wx:if="{{tabs.active=='3'}}" class="a">
+                    <view class="list" wx:for="{{list}}" wx:key="item">
+                        <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
+                            <text>{{item.name}}</text>
+                            <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+                        </view>
+                        <view class="list_2 textOver">{{item.match_time}}</view>
+                        <view class="list_3 textOver">{{item.address}}</view>
+                    </view>
+                </view>
+                <view wx:if="{{tabs.active=='0'}}" class="a">
+                    <view class="list" wx:for="{{list}}" wx:key="item">
+                        <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
+                            <text>{{item.name}}</text>
+                            <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+                        </view>
+                        <view class="list_2 textOver">{{item.match_time}}</view>
+                        <view class="list_3 textOver">{{item.address}}</view>
+                    </view>
+                </view>
+                <view wx:if="{{tabs.active=='4'}}" class="a">
+                    <view class="list" wx:for="{{list}}" wx:key="item">
+                        <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
+                            <text>{{item.name}}</text>
+                            <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+                        </view>
+                        <view class="list_2 textOver">{{item.match_time}}</view>
+                        <view class="list_3 textOver">{{item.address}}</view>
+                    </view>
+                </view>
             </view>
-            <view class="list_2 textOver">{{item.match_time}}</view>
-            <view class="list_3 textOver">{{item.address}}</view>
-          </view>
         </view>
-      </view>
     </view>
-  </view>
 </mobile-main>

+ 15 - 30
pages/editBasic/index.js

@@ -58,26 +58,19 @@ Page({
         } else {
             wx.getStorage({
                 key: 'token',
-                success: res => {
-                    wx.request({
-                        url: `${app.globalData.publicUrl}/courtAdmin/api/user/${res.data.id}`, //接口地址
-                        method: 'post',
-                        data: { ...params, icon: that.data.icon },
-                        success(res) {
-                            if (res.data.errcode == 0) {
-                                wx.showToast({ title: '维护信息成功', duration: 2000, icon: 'success' })
-                                that.watchLogin()
-                            } else {
-                                wx.showToast({ title: res.data.errmsg, icon: 'error', duration: 2000 })
-                            }
-                        }
-                    })
+                success: async res => {
+                    const arr = app.$post(`/courtAdmin/api/user/${res.data._id}`, { ...params, icon: that.data.icon });
+                    if (arr.errcode == '0') {
+                        wx.showToast({ title: '维护信息成功', duration: 2000, icon: 'success' })
+                        that.watchLogin()
+                    } else {
+                        wx.showToast({ title: arr.errmsg, icon: 'error', duration: 2000 })
+                    }
                 },
                 fail: res => {
                     wx.redirectTo({ url: '/pages/index/index', })
                 }
             })
-
         }
     },
     /**
@@ -96,21 +89,13 @@ Page({
         const that = this;
         wx.getStorage({
             key: 'token',
-            success: res => {
-                wx.request({
-                    url: `${app.globalData.publicUrl}/courtAdmin/api/user/${res.data.id}`, //接口地址
-                    method: 'get',
-                    data: {},
-                    success(res) {
-                        if (res.data.errcode == 0) {
-                            let form = res.data.data;
-                            that.setData({ form: form });
-                            that.setData({ icon: form.icon });
-                        } else {
-                            wx.showToast({ title: res.data.errmsg, icon: 'error', duration: 2000 })
-                        }
-                    }
-                })
+            success: async res => {
+                const arr = await app.$get(`/courtAdmin/api/user/${res.data._id}`);
+                if (arr.errcode == '0') {
+                    let form = arr.data;
+                    that.setData({ form: form });
+                    that.setData({ icon: form.icon });
+                }
             },
             fail: res => {
                 wx.redirectTo({ url: '/pages/index/index', })

pages/editBasic/index.json → pages/basic/index.json


pages/editBasic/index.wxml → pages/basic/index.wxml


pages/editBasic/index.wxss → pages/basic/index.wxss


+ 15 - 12
pages/home/index.js

@@ -20,11 +20,16 @@ Page({
         let { route } = e.detail.detail;
         if (route) wx.redirectTo({ url: `/${route}` })
     },
-    // 查看比赛详情
+    // 查看比赛信息
     toView: function (e) {
         const { id } = e.currentTarget.dataset;
         wx.navigateTo({ url: `/pages/match/info?id=${id}` })
     },
+    // 查看比赛信息
+    scheduleView: function (e) {
+        const { id } = e.currentTarget.dataset;
+        wx.navigateTo({ url: `/pages/match/schedule?id=${id}` })
+    },
     /**
      * 生命周期函数--监听页面加载
      */
@@ -39,19 +44,17 @@ Page({
         const that = this;
         wx.getStorage({
             key: 'token',
-            success: res => {
-                wx.request({
-                    url: `${app.globalData.publicUrl}/courtAdmin/api/match`, //接口地址
-                    method: 'get',
-                    data: {},
-                    success(res) {
-                        if (res.data.errcode == 0) {
-                            that.setData({ list: res.data.data })
-                        } else {
-                            wx.showToast({ title: res.data.errmsg, icon: 'error', duration: 2000 })
+            success: async res => {
+                const arr = await app.$get(`/courtAdmin/api/match`);
+                if (arr.errcode == '0') {
+                    for (const val of arr.data) {
+                        if (val.status == '3') {
+                            const aee = await app.$get('/courtAdmin/api/schedule', { match_id: val._id });
+                            if (aee.errcode == '0') val.schedulelist = aee.data;
                         }
                     }
-                })
+                    that.setData({ list: arr.data })
+                }
             },
             fail: res => {
                 wx.redirectTo({ url: '/pages/index/index', })

+ 30 - 19
pages/home/index.wxml

@@ -1,23 +1,34 @@
 <mobile-main frameStyle="{{frameStyle}}" bind:back="back" bind:tabPath="tabPath">
-  <view slot="info" class="main" style="height:{{infoHeight}}px;">
-    <view class="one">
-      <image src="{{homeBg}}"></image>
-    </view>
-    <view class="two">
-      <view class="list" wx:for="{{list}}" wx:key="item">
-        <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
-          <text>{{item.name}}</text>
-          <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+    <view slot="info" class="main" style="height:{{infoHeight}}px;">
+        <view class="one">
+            <image src="{{homeBg}}"></image>
+        </view>
+        <view class="two">
+            <view class="list" wx:for="{{list}}" wx:key="item">
+                <view class="list_1 textOver" bindtap="toView" data-id="{{item._id}}">
+                    <text>{{item.name}}</text>
+                    <text class="color{{item.status}}">{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text>
+                </view>
+                <view class="list_2 textOver">{{item.match_time}}</view>
+                <view class="list_3 textOver">{{item.address}}</view>
+                <view class="schedule">
+                    <view class="schedulelist" wx:for="{{item.schedulelist}}" wx:key="tag" bindtap="scheduleView" data-id="{{item._id}}">
+                        <view class="schedule_1">
+                            <image src="{{item.red_logo[0].url}}"></image>
+                            <text class="textOver">{{item.red_name}}</text>
+                        </view>
+                        <view class="schedule_2">
+                            <text>{{item.red_branch||0}}</text>
+                            <text>:</text>
+                            <text>{{item.blue_branch||0}}</text>
+                        </view>
+                        <view class="schedule_1">
+                            <text class="textOver">{{item.blue_name||'暂无'}}</text>
+                            <image src="{{item.blue_logo[0].url}}"></image>
+                        </view>
+                    </view>
+                </view>
+            </view>
         </view>
-        <view class="list_2 textOver">{{item.match_time}}</view>
-        <view class="list_3 textOver">{{item.address}}</view>
-        <!-- <view>
-          <view wx:for="{{item.matchList}}" wx:key="tag">
-            <view>循环赛第一组</view>
-            <view>比赛信息</view>
-          </view>
-        </view> -->
-      </view>
     </view>
-  </view>
 </mobile-main>

+ 106 - 43
pages/home/index.wxss

@@ -1,82 +1,145 @@
 .main {
-  position: relative;
-  width: 100%;
+    position: relative;
+    width: 100%;
 }
 
 .main .one {
-  float: left;
-  width: 100%;
+    float: left;
+    width: 100%;
 }
 
 .main .one image {
-  width: 100%;
-  height: 240px;
-  overflow: hidden;
+    width: 100%;
+    height: 240px;
+    overflow: hidden;
 }
 
 .main .two {
-  float: left;
-  width: 95%;
-  margin: 0 10px;
-  position: relative;
-  top: -40px;
+    float: left;
+    width: 95%;
+    margin: 0 10px;
+    position: relative;
+    top: -40px;
 }
 
 .main .two .list {
-  float: left;
-  width: 95%;
-  border-radius: 5px;
-  background-color: #ffffff;
-  margin: 0 0 10px 0;
-  padding: 10px;
+    float: left;
+    width: 95%;
+    border-radius: 5px;
+    background-color: #ffffff;
+    margin: 0 0 10px 0;
+    padding: 10px;
 }
 
 .main .two .list .list_1 {
-  float: left;
-  width: 100%;
-  margin: 0 0 5px 0;
+    float: left;
+    width: 100%;
+    margin: 0 0 5px 0;
 }
 
 .main .two .list .list_1 text:nth-child(1) {
-  font-size: 16px;
-  font-weight: bold;
-  color: #263fa3;
+    font-size: 16px;
+    font-weight: bold;
+    color: #263fa3;
 }
 
 .main .two .list .list_1 text:nth-child(2) {
-  display: inline-block;
-  background-color: #7b7b7b;
-  color: #fff;
-  padding: 3px 6px;
-  border-radius: 90px;
-  font-size: 12px;
-  margin: 0 0 0 10px;
+    display: inline-block;
+    background-color: #7b7b7b;
+    color: #fff;
+    padding: 3px 6px;
+    border-radius: 90px;
+    font-size: 12px;
+    margin: 0 0 0 10px;
 }
 
 .main .two .list .list_1 .color1 {
-  background-color: #57cd00 !important;
+    background-color: #57cd00 !important;
 }
 
 .main .two .list .list_1 .color2 {
-  background-color: #ff5a00 !important;
+    background-color: #ff5a00 !important;
 }
 
 .main .two .list .list_1 .color3 {
-  background-color: #ffa200 !important;
+    background-color: #ffa200 !important;
 }
 
 .main .two .list .list_2 {
-  float: left;
-  width: 100%;
-  font-size: 14px;
-  color: #666;
-  margin: 0 0 5px 0;
+    float: left;
+    width: 100%;
+    font-size: 14px;
+    color: #666;
+    margin: 0 0 5px 0;
 
 }
 
 .main .two .list .list_3 {
-  float: left;
-  width: 100%;
-  font-size: 14px;
-  color: #666;
+    float: left;
+    width: 100%;
+    font-size: 14px;
+    color: #666;
+    margin: 0 0 10px 0;
+}
+
+.main .two .list .schedule {
+    float: left;
+    width: 100%;
+}
+
+.main .two .list .schedule .schedulelist {
+    float: left;
+    width: 100%;
+    background-color: #e9e9e9;
+    margin: 0 0 5px 0;
+    border-radius: 5px;
+    padding: 5px 0;
+}
+
+.main .two .list .schedule .schedulelist .schedule_1 {
+    float: left;
+    width: 39%;
+    text-align: center;
+}
+
+.main .two .list .schedule .schedulelist .schedule_1 image {
+    width: 50px;
+    height: 50px;
+    border-radius: 90px;
+}
+
+.main .two .list .schedule .schedulelist .schedule_1 text {
+    float: right;
+    font-size: 14px;
+    padding: 15px 0;
+}
+
+.main .two .list .schedule .schedulelist .schedule_1:nth-child(3) text {
+    float: left;
+}
+
+.main .two .list .schedule .schedulelist .schedule_2 {
+    float: left;
+    width: 22%;
+    text-align: center;
+    padding: 10px 0;
+}
+
+.main .two .list .schedule .schedulelist .schedule_2 text {
+    background-color: rgb(228, 226, 226);
+    text-align: center;
+    color: #ff0000;
+    font-size: 20px;
+    font-weight: bold;
+    text-decoration: line-through;
+    text-decoration-color: #fff;
+    padding: 0 2px;
+}
+
+.main .two .list .schedule .schedulelist .schedule_2 text:nth-child(2) {
+    color: #000000;
+}
+
+.main .two .list .schedule .schedulelist .schedule_2 text:nth-child(3) {
+    color: #00427b;
 }

+ 3 - 46
pages/match/info.js

@@ -1,8 +1,5 @@
-// pages/login/login.js
-import WxValidate from '../../utils/wxValidate'
 const app = getApp();
 import { match_status } from '../../utils/dict';
-
 Page({
 
     /**
@@ -30,53 +27,13 @@ Page({
                 sheng: '10',
                 fu: '10',
                 jf: '111'
-            },
-            {
-                pm: '1',
-                logo: [{ url: '/image/team_1.jpg' }],
-                team_name: '测试战队',
-                sheng: '10',
-                fu: '10',
-                jf: '111'
-            },
-            {
-                pm: '1',
-                logo: [{ url: '/image/team_1.jpg' }],
-                team_name: '测试战队',
-                sheng: '10',
-                fu: '10',
-                jf: '111'
-            },
-            {
-                pm: '1',
-                logo: [{ url: '/image/team_1.jpg' }],
-                team_name: '测试战队',
-                sheng: '10',
-                fu: '10',
-                jf: '111'
-            },
-            {
-                pm: '1',
-                logo: [{ url: '/image/team_1.jpg' }],
-                team_name: '测试战队',
-                sheng: '10',
-                fu: '10',
-                jf: '111'
-            },
-            {
-                pm: '1',
-                logo: [{ url: '/image/team_1.jpg' }],
-                team_name: '测试战队',
-                sheng: '10',
-                fu: '10',
-                jf: '111'
-            },
+            }
         ],
         // 状态
         statusList: match_status,
         // 选项卡
         tabs: {
-            active: 'd',
+            active: 'a',
             list: [{ title: '赛制信息', name: 'a' }, { title: '参赛队伍', name: 'b' }, { title: '赛程列表', name: 'c' }, { title: '队伍榜单', name: 'd' }],
         },
     },
@@ -93,7 +50,7 @@ Page({
      */
     onLoad: function (options) {
         const that = this;
-        that.setData({ match_id: options.id || '629eb5de78fa03648c0535d9' });
+        that.setData({ match_id: options.id || '' });
         // 计算高度
         that.searchHeight()
         // 监听用户是否登录

+ 84 - 0
pages/match/schedule.js

@@ -0,0 +1,84 @@
+// pages/login/login.js
+import WxValidate from '../../utils/wxValidate'
+const app = getApp()
+Page({
+
+    /**
+     * 页面的初始数据
+     */
+    data: {
+        frameStyle: { useTop: true, name: '比赛信息', leftArrow: true, useBar: false },
+        // 主体高度
+        infoHeight: '',
+    },
+    back: function () {
+        wx.navigateBack({ delta: 1 })
+    },
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad: function (options) {
+        // 计算高度
+        this.searchHeight()
+    },
+    // 计算高度
+    searchHeight: function () {
+        let frameStyle = this.data.frameStyle;
+        let client = app.globalData.client;
+        let infoHeight = client.windowHeight;
+        // 是否去掉状态栏
+        if (frameStyle.useTop) infoHeight = infoHeight - (client.statusBarHeight + client.getMenu.height + (client.getMenu.top - client.statusBarHeight) * 2);
+        // 是否减去底部菜单
+        if (frameStyle.useBar) infoHeight = infoHeight - 50;
+        if (infoHeight) this.setData({ infoHeight: infoHeight })
+    },
+
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload: function () {
+
+    },
+
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh: function () {
+
+    },
+
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom: function () {
+
+    },
+
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage: function () {
+
+    }
+})

pages/addmatch/index.json → pages/match/schedule.json


+ 5 - 0
pages/match/schedule.wxml

@@ -0,0 +1,5 @@
+<mobile-main frameStyle="{{frameStyle}}" bind:back="back">
+  <view slot="info" class="main" style="height:{{infoHeight}}px;">
+    模板
+  </view>
+</mobile-main>

+ 4 - 0
pages/match/schedule.wxss

@@ -0,0 +1,4 @@
+.main {
+    position: relative;
+    width: 100%;
+}

+ 3 - 3
pages/addmatch/index.js

@@ -95,11 +95,11 @@ Page({
         const that = this;
         if (options && options.id) that.setData({ id: options.id })
         //验证规则函数
-        this.initValidate();
+        that.initValidate();
         // 计算高度
-        this.searchHeight();
+        that.searchHeight();
         // 监听用户是否登录
-        this.watchLogin();
+        that.watchLogin();
     },
     // 监听用户是否登录
     watchLogin: async function () {

+ 6 - 0
pages/matchAdd/index.json

@@ -0,0 +1,6 @@
+{
+    "component": true,
+    "usingComponents": {
+      "mobile-main": "/commpents/mobile-frame/mobile-main"
+    }
+  }

pages/addmatch/index.wxml → pages/matchAdd/index.wxml


pages/addmatch/index.wxss → pages/matchAdd/index.wxss


pages/teamrank/index.js → pages/matchTeampm/index.js


pages/teamrank/index.json → pages/matchTeampm/index.json


pages/teamrank/index.wxml → pages/matchTeampm/index.wxml


pages/teamrank/index.wxss → pages/matchTeampm/index.wxss


pages/teamexam/index.js → pages/matchTeamsh/index.js


pages/teamexam/index.json → pages/matchTeamsh/index.json


pages/teamexam/index.wxml → pages/matchTeamsh/index.wxml


pages/teamexam/index.wxss → pages/matchTeamsh/index.wxss


+ 3 - 3
pages/matchadmin/index.wxml

@@ -8,9 +8,9 @@
                     <view class="otherInfo"><text>地点:</text><text>{{item.address}}</text></view>
                     <view class="otherInfo"><text>状态:</text><text>{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text></view>
                 </view>
-                <view class="btn" wx:if="{{item.status=='0'||item.status=='1'||item.status=='2'}}">
-                    <button type="default" size="mini" bindtap="toEdit" data-id="{{item._id}}" data-route="addmatch">修改</button>
-                    <button type="warn" size="mini" bindtap="toCommon" data-id="{{item._id}}" data-route="layoutInfo">编排</button>
+                <view class="btn">
+                    <button type="default" size="mini" bindtap="toEdit" data-id="{{item._id}}" data-route="matchAdd" wx:if="{{item.status=='0'||item.status=='1'||item.status=='2'||item.status=='3'}}">修改</button>
+                    <button type="warn" size="mini" bindtap="toCommon" data-id="{{item._id}}" data-route="layoutInfo" wx:if="{{item.status=='1'||item.status=='2'||item.status=='3'}}">编排</button>
                 </view>
             </view>
         </view>

+ 4 - 0
pages/matchadmin/layoutInfo.js

@@ -12,6 +12,7 @@ Page({
         infoHeight: '',
         // 比赛信息
         match_id: '629eb5de78fa03648c0535d9',
+        matchInfo: {},
         list: [],
         // 弹框
         dialog: { title: '详细信息', show: false, type: '1' },
@@ -61,6 +62,9 @@ Page({
             key: 'token',
             success: async res => {
                 let arr;
+                // 查询比赛信息
+                arr = await app.$get(`/courtAdmin/api/match/${that.data.match_id}`,);
+                if (arr.errcode == '0') that.setData({ matchInfo: arr.data });
                 // 查询赛制信息
                 arr = await app.$get(`/courtAdmin/api/schedule`, { match_id: that.data.match_id });
                 if (arr.errcode == '0') that.setData({ list: arr.data });

+ 4 - 4
pages/matchadmin/layoutInfo.wxml

@@ -7,10 +7,10 @@
             <view class="list" wx:for="{{list}}" wx:key="item">
                 <view class="name textOver">{{item.match_name}}</view>
                 <view class="other">
-                    <view class="otherInfo"><text>红方队伍: </text><text>{{item.red_name}}</text></view>
-                    <view class="otherInfo"><text>红方比分:</text><text>{{item.red_branch}}</text></view>
-                    <view class="otherInfo"><text>蓝方队伍: </text><text>{{item.blue_name}}</text></view>
-                    <view class="otherInfo"><text>蓝方比分: </text><text>{{item.blue_branch}}</text></view>
+                    <view class="otherInfo"><text>红方队伍: </text><text>{{item.red_name||'暂无'}}</text></view>
+                    <view class="otherInfo"><text>红方比分:</text><text>{{item.red_branch||'0'}}</text></view>
+                    <view class="otherInfo"><text>蓝方队伍: </text><text>{{item.blue_name||'暂无'}}</text></view>
+                    <view class="otherInfo"><text>蓝方比分: </text><text>{{item.blue_branch||'0'}}</text></view>
                     <view class="otherInfo"><text>状态:</text><text>{{item.status=='0'?'未开始':item.status=='1'?'报名中':item.status=='2'?'待比赛':item.status=='3'?'进行中':'已结束'}}</text></view>
                 </view>
                 <view class="btn">

+ 7 - 2
pages/matchteam/index.js

@@ -8,7 +8,7 @@ Page({
      * 页面的初始数据
      */
     data: {
-        frameStyle: { useTop: true, name: '查询比赛', leftArrow: true, useBar: true },
+        frameStyle: { useTop: true, name: '查询比赛', leftArrow: true, useBar: false },
         // 主体高度
         infoHeight: '',
         // 选项卡
@@ -36,11 +36,16 @@ Page({
         const { id } = e.currentTarget.dataset;
         wx.navigateTo({ url: `/pages/match/info?id=${id}` })
     },
-    // 加入
+    // 报名
     toJoin: function (e) {
         const { id } = e.currentTarget.dataset;
         wx.navigateTo({ url: `/pages/matchteam/detail?id=${id}` })
     },
+    // 编排信息
+    toLayout: function (e) {
+        const { id } = e.currentTarget.dataset;
+        wx.navigateTo({ url: `/pages/matchteam/layout?id=${id}` })
+    },
     /**
      * 生命周期函数--监听页面加载
      */

+ 3 - 0
pages/matchteam/index.wxml

@@ -23,6 +23,9 @@
                         <view class="otherInfo">申请时间:<text>{{item.apply_time}}</text></view>
                         <view class="otherInfo">状态:<text>{{cstatusList[item.status].value}}</text></view>
                     </view>
+                    <view class="btn">
+                        <button type="default" size="mini" bindtap="toLayout" data-id="{{item._id}}">编排信息</button>
+                    </view>
                 </view>
             </view>
         </view>

+ 84 - 0
pages/matchteam/layout.js

@@ -0,0 +1,84 @@
+// pages/login/login.js
+import WxValidate from '../../utils/wxValidate'
+const app = getApp()
+Page({
+
+    /**
+     * 页面的初始数据
+     */
+    data: {
+        frameStyle: { useTop: true, name: '编排信息', leftArrow: true, useBar: false },
+        // 主体高度
+        infoHeight: '',
+    },
+    back: function () {
+        wx.navigateBack({ url: '/pages/matchteam/index' })
+    },
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad: function (options) {
+        // 计算高度
+        this.searchHeight()
+    },
+    // 计算高度
+    searchHeight: function () {
+        let frameStyle = this.data.frameStyle;
+        let client = app.globalData.client;
+        let infoHeight = client.windowHeight;
+        // 是否去掉状态栏
+        if (frameStyle.useTop) infoHeight = infoHeight - (client.statusBarHeight + client.getMenu.height + (client.getMenu.top - client.statusBarHeight) * 2);
+        // 是否减去底部菜单
+        if (frameStyle.useBar) infoHeight = infoHeight - 50;
+        if (infoHeight) this.setData({ infoHeight: infoHeight })
+    },
+
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload: function () {
+
+    },
+
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh: function () {
+
+    },
+
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom: function () {
+
+    },
+
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage: function () {
+
+    }
+})

+ 6 - 0
pages/matchteam/layout.json

@@ -0,0 +1,6 @@
+{
+    "component": true,
+    "usingComponents": {
+      "mobile-main": "/commpents/mobile-frame/mobile-main"
+    }
+  }

+ 5 - 0
pages/matchteam/layout.wxml

@@ -0,0 +1,5 @@
+<mobile-main frameStyle="{{frameStyle}}" bind:back="back">
+  <view slot="info" class="main" style="height:{{infoHeight}}px;">
+    模板
+  </view>
+</mobile-main>

+ 4 - 0
pages/matchteam/layout.wxss

@@ -0,0 +1,4 @@
+.main {
+    position: relative;
+    width: 100%;
+}

+ 44 - 53
pages/me/index.js

@@ -10,6 +10,7 @@ Page({
         // 主体高度
         infoHeight: '',
         bg: '/image/me_1.jpg',
+        ismatch_url: '/image/me_2.png',
         // 用户信息
         userInfo: {},
         // 正在比赛
@@ -35,7 +36,6 @@ Page({
                 }],
             },
         ],
-        ismatch_url: '/image/me_2.png',
         // 我的团队
         teamList: [],
         // 我的服务
@@ -70,14 +70,7 @@ Page({
                 title: '提示',
                 content: '是否确认退出登录',
                 success(res) {
-                    if (res.confirm) {
-                        wx.removeStorage({
-                            key: 'token',
-                            success(res) {
-                                return wx.redirectTo({ url: '/pages/index/index', })
-                            }
-                        })
-                    }
+                    if (res.confirm) wx.removeStorage({ key: 'token', success(res) { return wx.redirectTo({ url: '/pages/index/index', }) } })
                 }
             })
         } else {
@@ -96,8 +89,8 @@ Page({
     onLoad: function (options) {
         // 计算高度
         this.searchHeight();
-        // 监听用户是否登录
-        this.watchLogin();
+        // // 监听用户是否登录
+        // this.watchLogin();
     },
     // 监听用户是否登录
     watchLogin: function () {
@@ -105,49 +98,47 @@ Page({
         wx.getStorage({
             key: 'token',
             success: async res => {
-                wx.request({
-                    url: `${app.globalData.publicUrl}/courtAdmin/api/user/${res.data.id}`, //接口地址
-                    method: 'get',
-                    data: {},
-                    async success(res) {
-                        if (res.data.errcode == 0) {
-                            let user = res.data.data;
-                            // 头像
-                            user.icons = user.icon[0] ? user.icon[0].url : '';
-                            // 我的服务,判断不同用户显示不同功能按钮
-                            let menu = btn.filter((i) => i.type.includes(user.type));
-                            if (menu) that.setData({ btnList: menu });
-                            // 团队信息,所在团队信息
-                            if (user.type == '0') {
-                                that.setData({ userInfo: user })
-                            } else if (user.type == '1') {
-                                let arr = await app.$get(`/courtAdmin/api/team`, { create_id: user._id, status: '1' });
-                                if (arr.errcode == '0') {
-                                    let team = arr.data;
-                                    that.setData({ teamList: team });
-                                    if (arr.total > 0) {
-                                        let teamInfo = team[0] ? team[0] : { name: '' };
-                                        user.team_name = teamInfo.name;
-                                    }
-                                    that.setData({ userInfo: user })
-                                } else wx.showToast({ title: `${error.msg}`, icon: 'error', duration: 2000 })
-                            } else if (user.type == '2') {
-                                const arr = await app.$get(`/courtAdmin/api/team/userteams`, { user_id: user._id });
-                                if (arr.errcode == '0') {
-                                    let team = arr.data;
-                                    that.setData({ teamList: team });
-                                    let teamInfo = team[0] ? team[0] : { name: '' };
-                                    user.team_name = teamInfo.name;
-                                    that.setData({ userInfo: user })
-                                } else {
-                                    wx.showToast({ title: arr.data.errmsg, icon: 'error', duration: 2000 })
-                                }
-                            }
-                        } else {
-                            wx.showToast({ title: res.data.errmsg, icon: 'error', duration: 2000 })
-                        }
+                let arr;
+                arr = await app.$get(`/courtAdmin/api/user/${res.data._id}`)
+                if (arr.errcode == '0') {
+                    let user = arr.data;
+                    // 头像
+                    user.icons = user.icon[0] ? user.icon[0].url : '';
+                    // 我的服务,判断不同用户显示不同功能按钮
+                    let menu = btn.filter((i) => i.type.includes(user.type));
+                    if (menu) that.setData({ btnList: menu });
+                    // 团队信息,所在团队信息
+                    if (user.type == '0') {
+                        that.setData({ userInfo: user })
+                    } else if (user.type == '1') {
+                        let team = []
+                        arr = await app.$get(`/courtAdmin/api/team`, { create_id: user._id, status: '1' });
+                        if (arr.errcode == '0') {
+                            team = arr.data;
+                            that.setData({ teamList: team });
+                            if (arr.total > 0) { let teamInfo = team[0] ? team[0] : { name: '' }; user.team_name = teamInfo.name; }
+                            that.setData({ userInfo: user })
+                        } else { wx.showToast({ title: `${err.errmsg}`, icon: 'error', duration: 2000 }) }
+                        // 查询正在比赛的赛事
+                        let ismatchList = [];
+                        // 红方
+                        arr = await app.$get(`/courtAdmin/api/schedule`, { red_id: team[0]._id });
+                        if (arr.errcode == '0') ismatchList.push(...arr.data);
+                        // 蓝方
+                        arr = await app.$get(`/courtAdmin/api/schedule`, { blue_id: team[0]._id });
+                        if (arr.errcode == '0') ismatchList.push(...arr.data);
+                        that.setData({ ismatchList: ismatchList })
+                    } else if (user.type == '2') {
+                        arr = await app.$get(`/courtAdmin/api/team/userteams`, { user_id: user._id });
+                        if (arr.errcode == '0') {
+                            let team = arr.data;
+                            that.setData({ teamList: team });
+                            let teamInfo = team[0] ? team[0] : { name: '' };
+                            user.team_name = teamInfo.name;
+                            that.setData({ userInfo: user })
+                        } else wx.showToast({ title: arr.data.errmsg, icon: 'error', duration: 2000 })
                     }
-                })
+                } else { wx.showToast({ title: arr.errmsg, icon: 'error', duration: 2000 }) }
             },
             fail: res => {
                 wx.redirectTo({ url: '/pages/index/index', })

+ 2 - 2
pages/me/index.wxml

@@ -19,7 +19,7 @@
                         <text class=" icon iconfont icon-qi"></text>
                         <text style="margin: 0 0 0 5px;">{{userInfo.team_name||'暂无'}}</text>
                     </view>
-                    <view class="one_2u_r" bindtap="toCommon" data-route="editBasic">
+                    <view class="one_2u_r" bindtap="toCommon" data-route="basic">
                         <van-icon name="arrow" />
                     </view>
                 </view>
@@ -43,7 +43,7 @@
                             </view>
                             <view class="ismatch_2_2">
                                 <text class="name ismatchname textOver">{{item.red_name}}</text>
-                                <text class="name"><text>{{item.red_branch}}</text>:<text>{{item.blue_branch}}</text></text>
+                                <text class="name"><text>{{item.red_branch||0}}</text>:<text>{{item.blue_branch||0}}</text></text>
                                 <text class="name ismatchname textOver">{{item.blue_name}}</text>
                             </view>
                             <view class="ismatch_2_1">

+ 0 - 2
pages/search/index.js

@@ -1,5 +1,3 @@
-// pages/login/login.js
-import WxValidate from '../../utils/wxValidate';
 import { match_status } from '../../utils/dict';
 const app = getApp()
 Page({

pages/teamdismissteam/index.js → pages/teamDissolution/index.js


pages/teamdismissteam/index.json → pages/teamDissolution/index.json


pages/teamdismissteam/index.wxml → pages/teamDissolution/index.wxml


pages/teamdismissteam/index.wxss → pages/teamDissolution/index.wxss


+ 0 - 3
pages/teamInfo/index.wxml

@@ -74,9 +74,6 @@
                     </label>
                 </view>
             </checkbox-group>
-            <!-- <view class="btn">
-                <button type="primary" size="mini" bindtap="memSubmit">提交保存</button>
-            </view> -->
         </view>
     </view>
 </e-dialog>

+ 181 - 0
pages/teamMembers/index.js

@@ -0,0 +1,181 @@
+// pages/login/login.js
+import WxValidate from '../../utils/wxValidate'
+const app = getApp()
+Page({
+
+    /**
+     * 页面的初始数据
+     */
+    data: {
+        frameStyle: { useTop: true, name: '审核队员', leftArrow: true, useBar: false },
+        // 主体高度
+        infoHeight: '',
+        list: [],
+        // 团队信息
+        teamInfo: {},
+        // 弹框
+        dialog: { title: '详细信息', show: false, type: '1' },
+        form: {},
+        statusList: [{ label: '待审核', value: '0' }, { label: '审核通过', value: '1' }, { label: '审核拒绝', value: '-1' }],
+
+    },
+    initValidate() {
+        const rules = { status: { required: true } }
+        // 验证字段的提示信息,若不传则调用默认的信息
+        const messages = { status: { required: '请选择状态', } };
+        this.WxValidate = new WxValidate(rules, messages)
+    },
+    back: function () {
+        wx.navigateBack({ url: '/pages/me/index' })
+    },
+    // 查看
+    toView: async function (e) {
+        const that = this;
+        let { id } = e.currentTarget.dataset;
+        const arr = await app.$get(`/courtAdmin/api/user/${id}`);
+        if (arr.errcode == '0') {
+            that.setData({ form: arr.data })
+            that.setData({ dialog: { title: '详细信息', show: true, type: '1' } })
+        }
+    },
+    // 审核
+    toCheck: async function (e) {
+        const that = this;
+        let { id } = e.currentTarget.dataset;
+        const arr = await app.$get(`/courtAdmin/api/joinapply/${id}`);
+        if (arr.errcode == '0') {
+            that.setData({ form: arr.data })
+            that.setData({ dialog: { title: '信息审核', show: true, type: '2' } })
+        }
+    },
+    // 选择状态
+    statusChange: function (e) {
+        const that = this;
+        const { value } = e.detail;
+        that.setData({ 'form.status': value })
+    },
+    // 提交审核
+    onSubmit: async function (e) {
+        const that = this;
+        const data = that.data.form;
+        const teamInfo = that.data.teamInfo;
+        const params = e.detail.value;
+        if (!this.WxValidate.checkForm(params)) {
+            const error = this.WxValidate.errorList[0];
+            wx.showToast({ title: `${error.msg}`, icon: 'error', duration: 2000 })
+            return false
+        } else {
+            let arr;
+            arr = await app.$post(`/courtAdmin/api/joinapply/${data.id}`, params);
+            if (arr.errcode == '0') {
+                if (params.status == '1') {
+                    arr = await app.$get(`/courtAdmin/api/user/${data.apply_id}`);
+                    if (arr.errcode == '0') {
+                        teamInfo.members.push({ user_id: arr.data.id, nickname: arr.data.nickname, icon: arr.data.icon })
+                        arr = await app.$post(`/courtAdmin/api/team/${teamInfo._id}`, teamInfo);
+                        if (arr.errcode == '0') {
+                            wx.showToast({ title: `审核信息成功`, icon: 'error', duration: 2000 });
+                            that.toClose();
+                            that.watchLogin();
+                        } else wx.showToast({ title: `${arr.errmsg}`, icon: 'error', duration: 2000 })
+                    }
+                }
+            } else wx.showToast({ title: `${arr.errmsg}`, icon: 'error', duration: 2000 })
+        }
+    },
+    // 关闭弹框
+    toClose: function () {
+        this.setData({ dialog: { title: '详细信息', show: false, type: '1' } })
+    },
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad: function (options) {
+        //验证规则函数
+        this.initValidate();
+        // 计算高度
+        this.searchHeight();
+        // 监听用户是否登录
+        this.watchLogin();
+    },
+    // 监听用户是否登录
+    watchLogin: function () {
+        const that = this;
+        wx.getStorage({
+            key: 'token',
+            success: async res => {
+                let arr;
+                arr = await app.$get(`/courtAdmin/api/team`, { create_id: res.data._id });
+                if (arr.errcode == '0') {
+                    let teamInfo = arr.data[0];
+                    that.setData({ teamInfo: teamInfo })
+                    arr = await app.$get(`/courtAdmin/api/joinapply`, { team_id: teamInfo._id });
+                    if (arr.errcode == '0') that.setData({ list: arr.data })
+                }
+            },
+            fail: res => {
+                wx.redirectTo({ url: '/pages/login/index', })
+            }
+        })
+    },
+    // 计算高度
+    searchHeight: function () {
+        let frameStyle = this.data.frameStyle;
+        let client = app.globalData.client;
+        let infoHeight = client.windowHeight;
+        // 是否去掉状态栏
+        if (frameStyle.useTop) infoHeight = infoHeight - (client.statusBarHeight + client.getMenu.height + (client.getMenu.top - client.statusBarHeight) * 2);
+        // 是否减去底部菜单
+        if (frameStyle.useBar) infoHeight = infoHeight - 50;
+        if (infoHeight) this.setData({ infoHeight: infoHeight })
+    },
+
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide: function () {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload: function () {
+
+    },
+
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh: function () {
+
+    },
+
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom: function () {
+
+    },
+
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage: function () {
+
+    }
+})

+ 7 - 0
pages/teamMembers/index.json

@@ -0,0 +1,7 @@
+{
+    "component": true,
+    "usingComponents": {
+        "mobile-main": "/commpents/mobile-frame/mobile-main",
+        "e-dialog": "/commpents/dialog/index"
+    }
+}

+ 63 - 0
pages/teamMembers/index.wxml

@@ -0,0 +1,63 @@
+<mobile-main frameStyle="{{frameStyle}}" bind:back="back">
+    <view slot="info" class="main" style="height:{{infoHeight}}px;">
+        <view class="one">
+            <view class="list" wx:for="{{list}}" wx:key="item">
+                <view class="name">{{item.status=='0'?'待审中':item.status=='1'?'审核通过':'审核拒绝'}}</view>
+                <view class="other">
+                    <view class="otherInfo">申请团队:<text>{{item.team_name}}</text></view>
+                    <view class="otherInfo"> 申请人:<text>{{item.apply_user }}</text></view>
+                    <view class="otherInfo"> 申请时间:<text>{{item.apply_time }}</text></view>
+                </view>
+                <view class="btn">
+                    <button size="mini" type="default" bindtap="toView" data-id="{{item.apply_id}}">详情</button>
+                    <button size="mini" type="default" bindtap="toCheck" data-id="{{item._id}}" wx:if="{{item.status=='0'}}">审核</button>
+                </view>
+            </view>
+        </view>
+    </view>
+</mobile-main>
+<e-dialog dialog="{{dialog}}" bind:toClose="toClose">
+    <view slot="info">
+        <view class="dialog_one" wx:if="{{dialog.type=='1'}}">
+            <view class="one_1">
+                <text>头像:</text>
+                <image src="{{form.icon[0].url}}"></image>
+            </view>
+            <view class="one_1">
+                <text class="text">名称:</text>
+                <text class="text1">{{form.nickname||'暂无昵称'}}</text>
+            </view>
+            <view class="one_1">
+                <text class="text">电话:</text>
+                <text class="text1">{{form.phone||'暂无'}}</text>
+            </view>
+            <view class="one_1">
+                <text class="text">性别:</text>
+                <text class="text1">{{form.gender||'暂无'}}</text>
+            </view>
+            <view class="one_1">
+                <text class="text">岗位:</text>
+                <text class="text1">{{form.work||'暂无'}}</text>
+            </view>
+            <view class="one_1">
+                <text class="text">邮箱:</text>
+                <text class="text1">{{form.email||'暂无'}}</text>
+            </view>
+        </view>
+        <view class="dialog_two" wx:elif="{{dialog.type=='2'}}">
+            <form bindsubmit="onSubmit">
+                <view class="content">
+                    <view class="label textOver">状态</view>
+                    <view class="value">
+                        <picker mode="selector" bindchange="statusChange" name="status" value="{{form.status}}" range-key="label" range="{{statusList}}">
+                            <view class="input">{{form.status=='0'?'待审中':form.status=='1'?'审核通过':'审核拒绝'}}</view>
+                        </picker>
+                    </view>
+                </view>
+                <view class="btn">
+                    <button type="primary" size="mini" formType="submit">提交审核</button>
+                </view>
+            </form>
+        </view>
+    </view>
+</e-dialog>

+ 125 - 0
pages/teamMembers/index.wxss

@@ -0,0 +1,125 @@
+.main {
+    position: relative;
+    width: 100%;
+}
+
+.main .one {
+    float: left;
+    width: 95%;
+    padding: 0 10px;
+    overflow-x: hidden;
+    margin: 10px 0 0 0;
+}
+
+.main .one .list {
+    float: left;
+    width: 95%;
+    background-color: #fff;
+    border-radius: 5px;
+    padding: 10px;
+    margin: 0 0 10px 0;
+}
+
+.main .one .list .name {
+    float: left;
+    width: 100%;
+    font-size: 14px;
+    font-weight: bold;
+    margin: 0 0 5px 0;
+}
+
+.main .one .list .other {
+    float: left;
+    width: 100%;
+    margin: 0 0 5px 0;
+}
+
+.main .one .list .other .otherInfo {
+    float: left;
+    width: 100%;
+    font-size: 12px;
+    margin: 0 0 5px 0;
+}
+
+.main .one .list .other .otherInfo text:nth-child(1) {
+    color: #666;
+}
+
+.main .one .list .btn {
+    float: left;
+    width: 100%;
+    text-align: center;
+}
+
+.main .one .list .btn button {
+    margin: 0 5px;
+    padding: 0 20px;
+    font-size: 14px;
+}
+
+.dialog_one {
+    float: left;
+    width: 100%;
+    margin: 10px 0 0 0;
+}
+
+.dialog_one .one_1 {
+    float: left;
+    width: 91%;
+    border: 1px solid #ccc;
+    border-radius: 5px;
+    margin: 0 0 10px 0;
+    padding: 10px;
+
+}
+
+.dialog_one .one_1 text {
+    color: #666;
+    font-size: 14px;
+}
+
+.dialog_one .one_1 text:nth-child(2) {
+    float: right;
+    color: #000;
+}
+
+.dialog_one .one_1 image {
+    float: right;
+    width: 60px;
+    height: 60px;
+}
+
+.dialog_two {
+    float: left;
+    width: 100%;
+}
+
+.dialog_two .content {
+    float: left;
+    width: 100%;
+    border-bottom: 1px solid #ccc;
+    padding: 10px 0;
+    margin: 0 0 10px 0;
+    font-size: 14px;
+}
+
+.dialog_two .content .label {
+    float: left;
+    width: 20%;
+}
+
+.dialog_two .content .value {
+    float: left;
+    width: 80%;
+    text-align: right;
+}
+
+.dialog_two .btn {
+    float: left;
+    width: 100%;
+    text-align: center;
+}
+
+.dialog_two .btn button {
+    font-size: 14px;
+}

+ 2 - 2
pages/teamapply/index.json

@@ -1,6 +1,6 @@
 {
     "component": true,
     "usingComponents": {
-      "mobile-main": "/commpents/mobile-frame/mobile-main"
+        "mobile-main": "/commpents/mobile-frame/mobile-main"
     }
-  }
+}

+ 0 - 66
pages/uploadScore/index.js

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

+ 0 - 3
pages/uploadScore/index.json

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

+ 0 - 2
pages/uploadScore/index.wxml

@@ -1,2 +0,0 @@
-<!--pages/uploadScore/index.wxml-->
-<text>pages/uploadScore/index.wxml</text>

+ 0 - 1
pages/uploadScore/index.wxss

@@ -1 +0,0 @@
-/* pages/uploadScore/index.wxss */

+ 0 - 2
pages/uploadimg/index.js

@@ -1,5 +1,3 @@
-// pages/login/login.js
-import WxValidate from '../../utils/wxValidate'
 const app = getApp()
 Page({
 

+ 2 - 2
utils/dict.js

@@ -12,8 +12,8 @@ export const btn = [
     { title: '用户管理', icon: 'icon-shenhe', route: 'user', type: '0' },
     { title: '比赛管理', icon: 'icon-bisaiguanli', route: 'matchadmin', type: '0' },
     { title: '比赛管理', icon: 'icon-bisaiguanli', route: 'matchteam', type: '1' },
-    { title: '审核队员', icon: 'icon-shenhe', route: 'exammembers', type: '1' },
-    { title: '解散团队', icon: 'icon-ren_jiesantuandui_line', route: 'teamdismissteam', type: '1' },
+    { title: '审核队员', icon: 'icon-shenhe', route: 'teamMembers', type: '1' },
+    { title: '解散团队', icon: 'icon-ren_jiesantuandui_line', route: 'teamDissolution', type: '1' },
     { title: '团队申请', icon: 'icon-ren_jiesantuandui_line', route: 'teamapply', type: '2' },
     { title: '修改密码', icon: 'icon-xiugaimima', route: 'updatepd', type: '0|1|2' },
     { title: '退出登录', icon: 'icon-tuichudenglu', route: '', type: '0|1|2', method: 'signout' },