Ver Fonte

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

zs há 3 anos atrás
pai
commit
ace71db6d2

+ 2 - 2
app.json

@@ -1,9 +1,9 @@
 {
   "pages": [
-    "pages/login/index",
-    "pages/home/index",
     "pages/index/index",
+    "pages/login/index",
     "pages/register/index",
+    "pages/home/index",
     "pages/search/index",
     "pages/administration/index",
     "pages/administration/detail",

BIN
image/jianshao.png


+ 1 - 1
pages/index/index.js

@@ -40,7 +40,7 @@ Page({
     wx.getStorage({
       key: 'token',
       success: res => {
-        // if (res.data) wx.redirectTo({ url: '/pages/home/index', })
+        if (res.data) wx.redirectTo({ url: '/pages/home/index', })
       },
       fail: res => {
         wx.redirectTo({ url: '/pages/login/index', })

+ 2 - 3
pages/me/index.js

@@ -22,10 +22,9 @@ Page({
     },
     //个人信息详情
     item1: {},
-    //团队创建人-团队列表
+    //团队列表
     list: [],
-    //个人用户-所在团队列表
-    // list2: [],
+
     //头像
     icon: '',
     showModal: false,

+ 2 - 2
pages/me/index.wxml

@@ -85,7 +85,7 @@
         <image src="{{src4}}" class="zan"></image>
       </view>
     </view>
-    <!-- 团队创建人-团队列表 -->
+    <!--团队列表 -->
     <view class="five">
       <view class="listtuan">
         <view class="onther">
@@ -99,7 +99,7 @@
               <view class="dui-left1">
                 <image src="{{item.logo[0].url}}" class="dui-image"></image>
               </view>
-              <view class="dui-right1 textOver">
+              <view class="dui-right1 ">
                 <text class="group" bindtap="ToDetails" data-id="{{item._id}}">{{item.name}}</text>
               </view>
               <button class="ball" size="mini" wx:if="{{item.type=='0'}}" style="background-color:rgb(63, 127, 245);">乒乓球</button>

+ 3 - 2
pages/me/index.wxss

@@ -337,9 +337,10 @@
 }
 
 .dui-image {
+  border-radius: 50%;
   margin-top: 2px;
   margin-left: 2px;
-  width: 37px;
+  width: 30px;
   height: 30px;
   overflow: hidden;
 }
@@ -359,7 +360,7 @@
   margin-top: 12px;
   margin-left: 3px;
   float: left;
-  width: 35%;
+  width: 55%;
 }
 
 .date {

+ 74 - 42
pages/team/apply.wxss

@@ -2,6 +2,7 @@
   position: relative;
   width: 100%;
 }
+
 .back {
   width: 40rpx;
   height: 40rpx;
@@ -9,91 +10,119 @@
   width: 40rpx;
   height: 40rpx;
 }
-.onea{
+
+.onea {
   font-weight: 600;
   position: absolute;
   top: 5%;
   left: 2%;
 }
-.ones{
+
+.ones {
   font-weight: 600;
   position: absolute;
   top: 5%;
   left: 42%;
   color: #ffffff;
 }
-.one-2{
+
+.one-2 {
   position: absolute;
   margin-top: -42%;
   margin-left: 42%;
   width: 18%;
   height: 63.78px;
-  border-radius: 50%; 
+  border-radius: 50%;
 }
-.one-3{
+
+.one-3 {
   position: absolute;
-  margin-top: -25%;
+  margin-top: -22%;
   margin-left: 40%;
+  width: 38%;
+  height: 63.78px;
 }
-.imgs{
+
+.imgs {
+  border-radius: 50%;
   margin-top: 4px;
   margin-left: 2px;
-  width: 95%;
-  height: 51.58px; 
+  width: 70px;
+  height: 70px;
+}
+
+.person {
+  margin-left: 21%;
+  font-size: 13px;
+  color: #ffffff;
+  font-weight: 300;
 }
-.two-1{
+
+.two-1 {
   margin-top: -4px;
   background-color: #ffffff;
   font-size: 15px;
   margin-bottom: 6%;
 }
-.two{
+
+.two {
   background-color: #ffffff;
 }
-.two1{
+
+.two1 {
   padding-top: 30px;
   padding-bottom: 10px;
 }
-.two2{
+
+.two2 {
   padding-bottom: 20px;
 }
-.two-left1{
+
+.two-left1 {
   float: left;
   margin-top: -3px;
   width: 10%;
 }
-.two-left2{
+
+.two-left2 {
   margin-top: -3px;
   float: left;
   width: 10%;
 }
-.zi{
+
+.zi {
   color: #9e9e9e;
 }
-.date{
+
+.date {
   margin-right: 2%;
 }
-.thr{
+
+.thr {
   padding-top: 15px;
   background-color: #ffffff;
 }
+
 .tuan {
   margin-left: 11px;
   font-size: 16px;
   font-weight: 500;
   margin-right: 10px;
 }
-.thr-left{
+
+.thr-left {
   width: 79%;
   height: 49px;
   background-color: #eeeeee;
   border-radius: 24.5px;
 }
-.img{
+
+.img {
   width: 100%;
-  height: 49px; 
+  height: 49px;
 }
-.thr-1{
+
+.thr-1 {
   padding-top: 10px;
   padding-left: 10px;
   float: left;
@@ -101,10 +130,12 @@
   background-color: #ffffff;
   padding-bottom: 5px;
 }
-.thr1{
+
+.thr1 {
   background-color: #ffffff;
 }
-.thr-2{
+
+.thr-2 {
   padding-top: 10px;
   padding-left: 8px;
   float: left;
@@ -113,50 +144,51 @@
   background-color: #ffffff;
   /* border: 1px solid red; */
 }
-.thr2{
+
+.thr2 {
   float: left;
   width: 50px;
   height: 50px;
   border: 2px solid #dddcdc;
 }
-.name{
+
+.name {
   font-size: 13px;
   color: #727272;
 }
-.thr3{
+
+.thr3 {
   margin-top: 22%;
   margin-left: 23%;
 }
-.four{
+
+.four {
   background-color: white;
   padding-top: 80px;
   padding-bottom: 20px;
 }
+
 .image {
   width: 100%;
   height: 240px;
   background-color: #eeeeee;
 }
-.button{
+
+.button {
   margin-top: 5px !important;
   width: 300px !important;
   height: 35px;
-  background-color: rgba(243, 32, 162,0.5);
-  background-image: linear-gradient(to right, rgb(247, 59, 69) , rgb(223, 41, 247));
-  border-radius: 30px; 
-  color:#ffffff; 
+  background-color: rgba(243, 32, 162, 0.5);
+  background-image: linear-gradient(to right, rgb(247, 59, 69), rgb(223, 41, 247));
+  border-radius: 30px;
+  color: #ffffff;
   font-size: 13px;
 }
-.group{
+
+.group {
   width: 100%;
   color: #ffffff;
-  margin-top: 20%;
-  margin-left: 2%;
+  margin-top: 20px;
+  margin-left: 2px;
   margin-bottom: 10%;
-}
-.person{
-  margin-left: 18%;
-  font-size: 13px;
-  color: #ffffff;
-  font-weight: 300;
 }

+ 1 - 1
pages/team/examine.wxml

@@ -14,7 +14,7 @@
         <image class="imgs" src="{{list.logo[0].url}}"></image>
       </view>
       <view class="one-3">
-      <view class="group textOver">{{list.name}}</view>
+      <view class="group ">{{list.name}}</view>
       <view class="person">共{{list.members.length||0}}人</view>
     </view>
     </view>

+ 11 - 9
pages/team/examine.wxss

@@ -38,15 +38,22 @@
   position: absolute;
   margin-top: -22%;
   margin-left: 40%;
-  width: 23%;
+  width: 40%;
   height: 63.78px;
 }
 
 .imgs {
+  border-radius: 50%;
   margin-top: 4px;
   margin-left: 2px;
-  width: 95%;
-  height: 51.58px;
+  width: 70px;
+  height: 70px;
+}
+.person {
+  margin-left: 21%;
+  font-size: 13px;
+  color: #ffffff;
+  font-weight: 300;
 }
 
 .two-1 {
@@ -170,12 +177,7 @@
   margin-bottom: 10%;
 }
 
-.person {
-  margin-left: 30%;
-  font-size: 13px;
-  color: #ffffff;
-  font-weight: 300;
-}
+
 
 .buttonend {
   background-color: rgb(136, 136, 136);

+ 10 - 31
pages/teamDetails/detail.js

@@ -28,6 +28,8 @@ Page({
   delList: function (e) {
     var that = this;
     var members = that.data.list.members;
+    var list = that.data.list;
+    var ids = that.data.list.id;
     wx.showModal({
       title: '是否删除该名队员',
       success(res) {
@@ -39,41 +41,18 @@ Page({
             }
           }
           that.setData({ ['list.members']: members })
-
+          wx.request({
+            url: `${app.globalData.publicUrl}/courtAdmin/api/team/${ids}`, //接口地址
+            method: "post",
+            data: list,
+            header: {},
+            success: res => {
+            },
+          })
         } else if (res.cancel) { }
       }
     })
   },
-  //保存
-  preservation: function (e) {
-    var that = this;
-    var id = that.data.list.id;
-    var list = that.data.list;
-    wx.request({
-      url: `${app.globalData.publicUrl}/courtAdmin/api/team/${id}`, //接口地址
-      method: "post",
-      data: list,
-      header: {},
-      success: res => {
-        if (res.data.errcode == 0) {
-          wx.showToast({
-            title: '保存成功',
-            icon: 'success',
-            duration: 4000//延迟两秒
-          })
-          return wx.redirectTo({ url: '/pages/me/index' })// 跳转页面
-        } else {
-          wx.showToast({
-            title: '保存失败',
-            icon: 'success',
-            duration: 2000
-          })
-        }
-
-      },
-    })
-  },
-
   /**
    * 生命周期函数--监听页面加载
    */

+ 3 - 4
pages/teamDetails/detail.wxml

@@ -14,7 +14,7 @@
         <image class="imgs" src="{{list.logo[0].url}}"></image>
       </view>
       <view class="one-3">
-        <view class="group textOver">{{list.name}}</view>
+        <view class="group ">{{list.name}}</view>
         <view class="person">共{{list.members.length||0}}人</view>
       </view>
     </view>
@@ -38,20 +38,19 @@
         </view>
       </view>
     </view>
-    <view class="thr" style="height:{{infoHeight-390}}px;">
+    <view class="thr" style="height:{{infoHeight-350}}px;">
       <view><text class="tuan">队员信息</text></view>
       <view class="thr-1" wx:key="item" wx:for="{{list.members}}">
         <view class="thr1">
           <view class="thr-left">
             <image class="img" src="{{item.icon[0].url}}"></image>
-            <image bindtap='delList' data-id="{{item.id}}" class="two_jian" src="/image/jian.png"></image>
+            <image bindtap='delList' data-id="{{item.id}}" class="two_jian" src="/image/jianshao.png"></image>
           </view>
           <view class="thr-right"><text class="name textOver">{{item.nickname}}</text> </view>
         </view>
       </view>
     </view>
     <view class="four">
-      <button class="button" bindtap='preservation' >保存</button>
     </view>
   </view>
 </mobile-main>

+ 17 - 13
pages/teamDetails/detail.wxss

@@ -34,19 +34,21 @@
   height: 63.78px;
   border-radius: 50%;
 }
-.one-3{
+
+.one-3 {
   position: absolute;
   top: 29%;
   left: 37.5%;
-  width: 23%;
+  width: 43%;
   height: 63.78px;
 }
 
 .imgs {
+  border-radius: 50%;
   margin-top: 4px;
   margin-left: 2px;
-  width: 95%;
-  height: 51.58px;
+  width: 70px;
+  height: 70px;
 }
 
 .two-1 {
@@ -109,7 +111,8 @@
   background-color: #eeeeee;
   border-radius: 24.5px;
 }
-.thr-right{
+
+.thr-right {
   margin-left: 3px;
 }
 
@@ -176,25 +179,26 @@
 }
 
 .person {
-  margin-left: 30%;
+  margin-left: 20%;
   font-size: 13px;
   color: #ffffff;
   font-weight: 300;
 }
 
 
-.button{
+.button {
   margin-top: 5px !important;
   width: 300px !important;
   height: 35px;
-  background-color: rgba(243, 32, 162,0.5);
-  background-image: linear-gradient(to right, rgb(247, 59, 69) , rgb(223, 41, 247));
-  border-radius: 30px; 
-  color:#ffffff; 
+  background-color: rgba(243, 32, 162, 0.5);
+  background-image: linear-gradient(to right, rgb(247, 59, 69), rgb(223, 41, 247));
+  border-radius: 30px;
+  color: #ffffff;
   font-size: 13px;
 }
-.four{
+
+.four {
   background-color: white;
   padding-top: 200px;
   padding-bottom: 20px;
-}
+}

+ 1 - 1
pages/teamDetails/index.wxml

@@ -14,7 +14,7 @@
         <image class="imgs" src="{{list.logo[0].url}}"></image>
       </view>
       <view class="one-3">
-        <view class="group textOver">{{list.name}}</view>
+        <view class="group">{{list.name}}</view>
         <view class="person">共{{list.members.length||0}}人</view>
       </view>
     </view>

+ 205 - 201
pages/teamDetails/index.wxss

@@ -1,202 +1,206 @@
 .main {
-    position: relative;
-    width: 100%;
-  }
-  
-  .back {
-    width: 40rpx;
-    height: 40rpx;
-    left: 15px;
-    width: 40rpx;
-    height: 40rpx;
-  }
-  
-  .onea {
-    font-weight: 600;
-    position: absolute;
-    top: 5%;
-    left: 2%;
-  }
-  
-  .ones {
-    font-weight: 600;
-    position: absolute;
-    top: 5%;
-    left: 42%;
-    color: #ffffff;
-  }
-  
-  .one-2 {
-    position: absolute;
-    top: 18%;
-    left: 41%;
-    width: 18%;
-    height: 63.78px;
-    border-radius: 50%;
-  }
-  .one-3{
-    position: absolute;
-    top: 29%;
-    left: 37.5%;
-    width: 23%;
-    height: 63.78px;
-  }
-  
-  .imgs {
-    margin-top: 4px;
-    margin-left: 2px;
-    width: 95%;
-    height: 51.58px;
-  }
-  
-  .two-1 {
-    margin-top: -4px;
-    background-color: #ffffff;
-    font-size: 15px;
-    margin-bottom: 6%;
-  }
-  
-  .two {
-    background-color: #ffffff;
-  }
-  
-  .two1 {
-    padding-top: 30px;
-    padding-bottom: 10px;
-  }
-  
-  .two2 {
-    padding-bottom: 20px;
-  }
-  
-  .two-left1 {
-    float: left;
-    margin-top: -3px;
-    width: 10%;
-  }
-  
-  .two-left2 {
-    margin-top: -3px;
-    float: left;
-    width: 10%;
-  }
-  
-  .zi {
-    color: #9e9e9e;
-  }
-  
-  .date {
-    margin-right: 2%;
-  }
-  
-  .thr {
-    float: left;
-    width: 100%;
-    padding-top: 15px;
-    background-color: #ffffff;
-  }
-  
-  .tuan {
-    margin-left: 11px;
-    font-size: 16px;
-    font-weight: 550;
-    margin-right: 10px;
-  }
-  
-  .thr-left {
-    width: 49px;
-    height: 49px;
-    background-color: #eeeeee;
-    border-radius: 24.5px;
-  }
-  .thr-right{
-    margin-left: 3px;
-  }
-  
-  .img {
-    border-radius: 50%;
-    width: 49px;
-    height: 49px;
-  }
-  
-  .two_jian {
-    position: relative;
-    top: -20px;
-    left: 35px;
-    width: 20px;
-    height: 20px;
-  }
-  
-  
-  .thr-1 {
-    padding-top: 10px;
-    padding-left: 10px;
-    float: left;
-    width: 18%;
-    background-color: #ffffff;
-    padding-bottom: 5px;
-  }
-  
-  .thr1 {
-    background-color: #ffffff;
-  }
-  
-  .thr-2 {
-    padding-top: 10px;
-    padding-left: 8px;
-    float: left;
-    width: 18%;
-    height: 75px;
-    background-color: #ffffff;
-    /* border: 1px solid red; */
-  }
-  
-  .thr2 {
-    float: left;
-    width: 50px;
-    height: 50px;
-    border: 2px solid #dddcdc;
-  }
-  
-  .name {
-    text-align: center;
-    font-size: 13px;
-    color: #727272;
-  }
-  
-  .thr3 {
-    margin-top: 22%;
-    margin-left: 23%;
-  }
-  
-  .group {
-    color: #ffffff;
-    margin-top: 20%;
-    margin-left: 21%;
-    margin-bottom: 10%;
-  }
-  
-  .person {
-    margin-left: 30%;
-    font-size: 13px;
-    color: #ffffff;
-    font-weight: 300;
-  }
-  
-  
-  .button{
-    margin-top: 5px !important;
-    width: 300px !important;
-    height: 35px;
-    background-color: rgba(243, 32, 162,0.5);
-    background-image: linear-gradient(to right, rgb(247, 59, 69) , rgb(223, 41, 247));
-    border-radius: 30px; 
-    color:#ffffff; 
-    font-size: 13px;
-  }
-  .four{
-    background-color: white;
-    padding-top: 200px;
-    padding-bottom: 20px;
-  }
-  
+  position: relative;
+  width: 100%;
+}
+
+.back {
+  width: 40rpx;
+  height: 40rpx;
+  left: 15px;
+  width: 40rpx;
+  height: 40rpx;
+}
+
+.onea {
+  font-weight: 600;
+  position: absolute;
+  top: 5%;
+  left: 2%;
+}
+
+.ones {
+  font-weight: 600;
+  position: absolute;
+  top: 5%;
+  left: 42%;
+  color: #ffffff;
+}
+
+.one-2 {
+  position: absolute;
+  top: 18%;
+  left: 41%;
+  width: 18%;
+  height: 63.78px;
+  border-radius: 50%;
+}
+
+.one-3 {
+  position: absolute;
+  top: 29%;
+  left: 30%;
+  width: 43%;
+  height: 63.78px;
+}
+
+.imgs {
+  border-radius: 50%;
+  margin-top: 4px;
+  margin-left: 2px;
+  width: 70px;
+  height: 70px;
+}
+
+.two-1 {
+  margin-top: -4px;
+  background-color: #ffffff;
+  font-size: 15px;
+  margin-bottom: 6%;
+}
+
+.two {
+  background-color: #ffffff;
+}
+
+.two1 {
+  padding-top: 30px;
+  padding-bottom: 10px;
+}
+
+.two2 {
+  padding-bottom: 20px;
+}
+
+.two-left1 {
+  float: left;
+  margin-top: -3px;
+  width: 10%;
+}
+
+.two-left2 {
+  margin-top: -3px;
+  float: left;
+  width: 10%;
+}
+
+.zi {
+  color: #9e9e9e;
+}
+
+.date {
+  margin-right: 2%;
+}
+
+.thr {
+  float: left;
+  width: 100%;
+  padding-top: 15px;
+  background-color: #ffffff;
+}
+
+.tuan {
+  margin-left: 11px;
+  font-size: 16px;
+  font-weight: 550;
+  margin-right: 10px;
+}
+
+.thr-left {
+  width: 49px;
+  height: 49px;
+  background-color: #eeeeee;
+  border-radius: 24.5px;
+}
+
+.thr-right {
+  margin-left: 3px;
+}
+
+.img {
+  border-radius: 50%;
+  width: 49px;
+  height: 49px;
+}
+
+.two_jian {
+  position: relative;
+  top: -20px;
+  left: 35px;
+  width: 20px;
+  height: 20px;
+}
+
+
+.thr-1 {
+  padding-top: 10px;
+  padding-left: 10px;
+  float: left;
+  width: 18%;
+  background-color: #ffffff;
+  padding-bottom: 5px;
+}
+
+.thr1 {
+  background-color: #ffffff;
+}
+
+.thr-2 {
+  padding-top: 10px;
+  padding-left: 8px;
+  float: left;
+  width: 18%;
+  height: 75px;
+  background-color: #ffffff;
+  /* border: 1px solid red; */
+}
+
+.thr2 {
+  float: left;
+  width: 50px;
+  height: 50px;
+  border: 2px solid #dddcdc;
+}
+
+.name {
+  text-align: center;
+  font-size: 13px;
+  color: #727272;
+}
+
+.thr3 {
+  margin-top: 22%;
+  margin-left: 23%;
+}
+
+.group {
+  color: #ffffff;
+  margin-top: 20%;
+  margin-left: 19%;
+  margin-bottom: 10%;
+}
+
+.person {
+  margin-left: 37%;
+  font-size: 13px;
+  color: #ffffff;
+  font-weight: 300;
+}
+
+
+
+.button {
+  margin-top: 5px !important;
+  width: 300px !important;
+  height: 35px;
+  background-color: rgba(243, 32, 162, 0.5);
+  background-image: linear-gradient(to right, rgb(247, 59, 69), rgb(223, 41, 247));
+  border-radius: 30px;
+  color: #ffffff;
+  font-size: 13px;
+}
+
+.four {
+  background-color: white;
+  padding-top: 200px;
+  padding-bottom: 20px;
+}

+ 3 - 2
pages/test/index.js

@@ -25,8 +25,9 @@ Page({
   searchHeight: function () {
     let frameStyle = this.data.frameStyle;
     let client = app.globalData.client;
-    // 减去状态栏
-    let infoHeight = client.windowHeight - (client.statusBarHeight + client.getMenu.height + (client.getMenu.top - client.statusBarHeight) * 2);
+    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 })