Pārlūkot izejas kodu

我的收入前端,整理"我的"

nnkwrik 6 gadi atpakaļ
vecāks
revīzija
dce41844de

+ 1 - 1
wx-front/app.json

@@ -11,7 +11,7 @@
     "pages/ucenter/orderDetail/orderDetail",
     "pages/ucenter/express/express",
     "pages/ucenter/feedback/feedback",
-    "pages/ucenter/coupon/coupon",
+    "pages/ucenter/income/income",
     "pages/ucenter/collect/collect",
     "pages/pay/pay",
     "pages/payResult/payResult",

+ 2 - 1
wx-front/config/api.js

@@ -41,7 +41,8 @@ module.exports = {
   PostedList: ApiRootUrl + 'goods/posted',  //发布的商品
   BoughtList: ApiRootUrl + 'goods/bought',  //买过的商品
   SoldList: ApiRootUrl + 'goods/sold',  //卖出的商品
-  
+  UserPage: ApiRootUrl + 'goods/user',  //用户主页
+  UserPageMore: ApiRootUrl + 'goods/user/more',  //用户主页
 
   CommentList: ApiRootUrl + 'comment/list',  //评论列表
   CommentCount: ApiRootUrl + 'comment/count',  //评论总数

+ 0 - 3
wx-front/pages/ucenter/coupon/coupon.json

@@ -1,3 +0,0 @@
-{
-  
-}

+ 0 - 47
wx-front/pages/ucenter/coupon/coupon.wxml

@@ -1,47 +0,0 @@
-<view class="container">
-  <view class="coupon-form">
-    <view class="input-box">
-      <input class="coupon-sn" placeholder="请输入优惠码" />
-      <image class="clear-icon" src="http://yanxuan.nosdn.127.net/hxm/yanxuan-wap/p/20161201/style/img/icon-normal/clear-fb-dd9d604f86.png"></image>
-    </view>
-    <button class="add-btn disabled">兑换</button>
-  </view>
-  <view class="help">使用说明</view>
-  <view class="coupon-list">
-    <view class="item">
-      <view class="tag">新人专享</view>
-      <view class="content">
-        <view class="left">
-          <view class="name">限时免单券</view>
-          <view class="time">2017.06.08-2017.06.11</view>
-        </view>
-        <view class="right">
-          <button class="go">去使用</button>
-        </view>
-      </view>
-      <view class="condition">
-        <text class="txt">简约陶瓷马克杯专享;小米用户福利;限时购、三石福利价、礼品卡及详情页标注不可用券特殊商品除外</text>
-        <image src="https://yanxuan.nosdn.127.net/hxm/yanxuan-wap/p/20161201/style/img/icon-normal/couponArrow-71315b4145.png" class="icon"></image>
-      </view>
-    </view>
-
-     <view class="item">
-      <view class="tag">新人专享</view>
-      <view class="content">
-        <view class="left">
-          <view class="name">限时免单券</view>
-          <view class="time">2017.06.08-2017.06.11</view>
-        </view>
-        <view class="right">
-          <button class="go">去使用</button>
-        </view>
-      </view>
-      <view class="condition">
-        <text class="txt">简约陶瓷马克杯专享;小米用户福利;限时购、三石福利价、礼品卡及详情页标注不可用券特殊商品除外</text>
-        <image src="https://yanxuan.nosdn.127.net/hxm/yanxuan-wap/p/20161201/style/img/icon-normal/couponArrow-71315b4145.png" class="icon"></image>
-      </view>
-    </view>
-  </view>
-
-
-</view>

+ 0 - 178
wx-front/pages/ucenter/coupon/coupon.wxss

@@ -1,178 +0,0 @@
-page{
-    background: #f4f4f4;
-    min-height: 100%;
-}
-
-.container{
-    background: #f4f4f4;
-    min-height: 100%;
-    padding-top: 30rpx;
-}
-
-.coupon-form{
-  height: 110rpx;
-  width: 100%;
-  background: #fff;
-  padding-left: 30rpx;
-  padding-right: 30rpx;
-  padding-top: 20rpx;
-  display: flex;
-}
-
-.input-box{
-  flex: 1;
-  height: 70rpx;
-  color: #333;
-  font-size: 24rpx;
-  background: #fff;
-  position: relative;
-  border: 1px solid rgba(0, 0, 0, 0.15);
-  border-radius: 4rpx;
-  margin-right: 30rpx;
-}
-
-.input-box .coupon-sn{
-  position: absolute;
-  top: 10rpx;
-  left: 30rpx;
-  height: 50rpx;
-  width: 100%;
-  color: #000;
-  line-height: 50rpx;
-  font-size: 24rpx;
-}
-
-.clear-icon{
-  position: absolute;
-  top: 21rpx;
-  right: 30rpx;
-  width: 28rpx;
-  height: 28rpx;
-}
-
-.add-btn{
-  height: 70rpx;
-  border:none;
-  width: 168rpx;
-  background: #b4282d;
-  border-radius: 0;
-  line-height: 70rpx;
-  color: #fff;
-  font-size: 28rpx;
-}
-
-.add-btn.disabled{
-  background: #ccc;
-}
-
-.help{
-  height: 72rpx;
-  line-height: 72rpx;
-  text-align: right;
-  padding-right: 30rpx;
-  background: url(https://yanxuan.nosdn.127.net/hxm/yanxuan-wap/p/20161201/style/img/icon-normal/couponHelp-4768607555.png) 590rpx center no-repeat;
-  background-size: 28rpx;
-  color: #999;
-  font-size: 24rpx;
-}
-
-.coupon-list{
-  width: 100%;
-  height: auto;
-  overflow: hidden;
-  padding-left: 30rpx;
-  padding-right: 30rpx;
-}
-
-.item{
-  position: relative;
-  height: 290rpx;
-  width: 100%;
-  background: linear-gradient(to right,#cfa568,#e3bf79);
-  margin-bottom: 30rpx;
-  padding-top: 52rpx;
-}
-
-.tag{
-  height: 32rpx;
-  background: #A48143;
-  padding-left: 16rpx;
-  padding-right: 16rpx;
-  position: absolute;
-  left: 20rpx;
-  color: #fff;
-  top: 20rpx;
-  font-size: 20rpx;
-  text-align: center;
-  line-height: 32rpx;
-}
-
-
-.content{
-  margin-top: 24rpx;
-  margin-left: 40rpx;
-  display: flex;
-  margin-right: 40rpx;
-  flex-direction: row;
-  align-items: center;
-}
-
-.content .left{
-  flex: 1;
-}
-
-.name{
-  font-size: 44rpx;
-  color: #fff;
-  margin-bottom: 14rpx;
-}
-
-.time{
-  font-size: 24rpx;
-  color: rgba(255,255,255, 0.8);
-  line-height: 30rpx;
-}
-
-.content .right{
-  width: 162rpx;
-}
-
-.go{
-  height: 48rpx;
-  border:none;
-  width: 162rpx;
-  background: rgba(255,255,255, 0.8);
-  border-radius: 4rpx;
-  line-height: 48rpx;
-  color: #b69150;
-  font-size: 24rpx;
-}
-
-.condition{
-  position: absolute;
-  width: 100%;
-  bottom: 0;
-  left:0;
-  height: 78rpx;
-  background: rgba(0,0,0,.08);
-  padding: 24rpx 40rpx;
-  display: flex;
-  flex-direction: row;
-}
-
-.condition .txt{
-  display: block;
-  height: 30rpx;
-  flex: 1;
-  overflow: hidden;
-  font-size: 24rpx;
-  line-height: 30rpx;
-  color: #fff;
-}
-
-
-.condition .icon{
-  margin-left: 30rpx;
-  width: 24rpx;
-  height: 24rpx;
-}

+ 0 - 0
wx-front/pages/ucenter/coupon/coupon.js → wx-front/pages/ucenter/income/income.js


+ 3 - 0
wx-front/pages/ucenter/income/income.json

@@ -0,0 +1,3 @@
+{
+  "navigationBarTitleText": "我的收入"
+}

+ 32 - 0
wx-front/pages/ucenter/income/income.wxml

@@ -0,0 +1,32 @@
+<view class="container">
+
+
+  <view class="income-list">
+
+    <view class="item all">
+      <view class="tag">总收入</view>
+      <view class="content">
+        <view class="left">
+          <view class="name">¥ 0</view>
+        </view>
+        <view class="right">
+          <button class="go">查看历史</button>
+        </view>
+      </view>
+    </view>
+
+     <view class="item change">
+      <view class="tag change-tag">零钱包</view>
+      <view class="content">
+        <view class="left">
+          <view class="name">¥ 0</view>
+        </view>
+        <view class="right">
+          <button class="go">提现</button>
+        </view>
+      </view>
+    </view>
+  </view>
+<view class="help">提现说明</view>
+
+</view>

+ 111 - 0
wx-front/pages/ucenter/income/income.wxss

@@ -0,0 +1,111 @@
+page{
+    background: #f4f4f4;
+    min-height: 100%;
+}
+
+.container{
+    background: #f4f4f4;
+    min-height: 100%;
+    padding-top:50px;
+
+}
+
+
+
+.help{
+  height: 72rpx;
+  line-height: 72rpx;
+  text-align: right;
+  padding-right: 30rpx;
+  background: url(https://yanxuan.nosdn.127.net/hxm/yanxuan-wap/p/20161201/style/img/icon-normal/couponHelp-4768607555.png) 590rpx center no-repeat;
+  background-size: 28rpx;
+  color: #999;
+  font-size: 24rpx;
+}
+
+.income-list{
+  width: 100%;
+  height: auto;
+  overflow: hidden;
+  padding-left: 30rpx;
+  padding-right: 30rpx;
+}
+
+.item{
+  position: relative;
+  height:250rpx;
+  width: 100%;
+  background: linear-gradient(to right,#cfa568,#e3bf79);
+  margin-bottom: 30rpx;
+  padding-top: 52rpx;
+  border-radius:20rpx;
+
+}
+.all{
+  background: #facc5d;
+}
+.change{
+  background: #95cdb4;
+}
+
+
+
+.tag{
+  height: 32rpx;
+  background: #A48143;
+  padding-left: 16rpx;
+  padding-right: 16rpx;
+  position: absolute;
+  left:30rpx;
+  color: #fff;
+  top: 20rpx;
+  /* font-size: 20rpx; */
+  text-align: center;
+  line-height: 32rpx;
+  margin-top:40rpx;
+}
+.change-tag{
+ background: #739c8a;
+}
+
+
+.content{
+  margin-top:50rpx;
+
+  margin-left: 40rpx;
+  display: flex;
+  margin-right: 40rpx;
+  flex-direction: row;
+  align-items: center;
+}
+
+.content .left{
+  flex: 1;
+}
+
+.name{
+font-size:60rpx;
+color:#fff;
+margin-bottom:14rpx;
+margin-left:10rpx;
+margin-top:20rpx;
+
+
+}
+
+
+
+.content .right{
+  width: 162rpx;
+}
+
+.go{
+  height: 48rpx;
+  border:none;
+  width: 162rpx;
+  background: rgba(255,255,255, 0.8);
+  border-radius: 4rpx;
+  line-height: 48rpx;
+  color: #b69150;
+  font-size: 24rpx;
+}

+ 17 - 27
wx-front/pages/ucenter/index/index.wxml

@@ -5,18 +5,21 @@
     <view class="info">
       <text class="name">{{userInfo.nickName}}</text>
 
-      <text  wx:if="{{isLogin}}" class="level">点击查看个人主页</text>
-      <text wx:else  class="level">马上授权登录</text>
+      <text wx:if="{{isLogin}}" class="level">点击查看个人主页</text>
+      <text wx:else class="level">马上授权登录</text>
     </view>
   </view>
 
   <view class="user-menu">
+
     <view class="item">
-      <navigator url="/pages/ucenter/order/order" class="a">
+      <navigator url="{{isLogin?'/pages/ucenter/income/income':'/pages/auth/auth'}}" class="a">
         <text class="icon coin"></text>
-        <text class="txt">我的订单</text>
+        <text class="txt">我的收入</text>
       </navigator>
     </view>
+
+
     <view class="item">
       <navigator url="{{isLogin?'/pages/ucenter/posted/posted':'/pages/auth/auth'}}" class="a">
         <text class="icon publish"></text>
@@ -42,42 +45,29 @@
         <text class="txt">我的收藏</text>
       </navigator>
     </view>
-    <view class="item no-border">
-      <navigator url="url" class="a">
-        <text class="icon support"></text>
-        <text class="txt">会员福利</text>
-      </navigator>
-    </view>
+
     <view class="item">
       <navigator url="../address/address" class="a">
-        <text class="icon donation"></text>
-        <text class="txt">地址管理</text>
-      </navigator>
-    </view>
-    <view class="item">
-      <navigator url="url" class="a">
         <text class="icon map"></text>
-        <text class="txt">账号安全</text>
+        <text class="txt">地址管理</text>
       </navigator>
     </view>
-    <view class="item no-border">
-      <navigator url="url" class="a">
-        <text class="icon question"></text>
-        <text class="txt">联系客服</text>
+
+    <view class="item item-bottom">
+      <navigator url="/pages/ucenter/order/order" class="a">
+        <text class="icon order"></text>
+        <text class="txt">我订单</text>
       </navigator>
     </view>
+
+
     <view class="item item-bottom">
       <navigator url="/pages/ucenter/about/about" class="a">
         <text class="icon embarrass"></text>
         <text class="txt">关于作者</text>
       </navigator>
     </view>
-    <view class="item item-bottom">
-      <navigator url="/pages/ucenter/feedback/feedback" class="a">
-        <text class="icon feedback"></text>
-        <text class="txt">意见反馈</text>
-      </navigator>
-    </view>
+
   </view>
 
   <!--<view class="logout" bindtap="exitLogin">退出登录</view>-->

+ 5 - 0
wx-front/pages/ucenter/index/index.wxss

@@ -171,6 +171,11 @@ page{
     background-size: 52.803rpx;
 }
 
+.user-menu .icon.order{
+    background: url(https://i.postimg.cc/nhZR16xn/order.png);
+    background-size: 52.803rpx;
+}
+
 
 
 .user-menu .txt{

BIN
wx-front/static/images/delete.png


BIN
wx-front/static/images/loading.png


BIN
wx-front/static/images/plus.png


BIN
wx-front/static/images/refreshing.png