Переглянути джерело

'完成订单提现页面'

machinecat520 2 роки тому
батько
коміт
1e21c2b9b7

+ 4 - 1
app.json

@@ -1,12 +1,15 @@
 
 
 {
 {
     "pages": [
     "pages": [
-        "pages/writeSuggestion/writeSuggestion",
+        "pages/recommend/recommend",
+        "pages/recommendOrderDetail/recommendOrderDetail",
+        "pages/recommendList/recommendList",
         "pages/complaintList/complaintList",
         "pages/complaintList/complaintList",
         "pages/complaintDetail/complaintDetail",
         "pages/complaintDetail/complaintDetail",
         "pages/writeComplaint/writeComplaint",
         "pages/writeComplaint/writeComplaint",
         "pages/suggestList/suggestList",
         "pages/suggestList/suggestList",
         "pages/suggestDetail/suggestDetail",
         "pages/suggestDetail/suggestDetail",
+        "pages/writeSuggestion/writeSuggestion",
         "pages/myCollectTeacher/myCollectTeacher",
         "pages/myCollectTeacher/myCollectTeacher",
         "pages/findTeacher/findTeacher",
         "pages/findTeacher/findTeacher",
         "pages/orderDetail/orderDetail",
         "pages/orderDetail/orderDetail",

+ 41 - 13
pages/myInfo/myInfo.js

@@ -15,38 +15,66 @@ Page({
 
 
     },
     },
 
 
+    // 跳转到推荐分享页面
+    toRecommend(){
+        wx.navigateTo({
+          url: '/pages/recommend/recommend',
+        })
+    },
+
+    // 跳转到订单页面
+    toMyOrder(){
+        wx.navigateTo({
+          url: '/pages/myOrder/myOrder',
+        })
+    },
+
     //跳转到我发出的邀请详情
     //跳转到我发出的邀请详情
-    sendInvitation(){
-       wx.navigateTo({
-         url: '/pages/sendInvitation/sendInvitation',
-       })
+    sendInvitation() {
+        wx.navigateTo({
+            url: '/pages/sendInvitation/sendInvitation',
+        })
     },
     },
 
 
     //跳转到我收到的邀请详情
     //跳转到我收到的邀请详情
-    receivedInvitation(){
+    receivedInvitation() {
         wx.navigateTo({
         wx.navigateTo({
             url: '/pages/receivedInvitation/receivedInvitation',
             url: '/pages/receivedInvitation/receivedInvitation',
-          })
+        })
     },
     },
 
 
     //跳转到老师认证
     //跳转到老师认证
-    teacherAuthentication(){
-        wx.navigateTo({       
-          url: '/pages/teachAuthentication/teachAuthentication',
+    teacherAuthentication() {
+        wx.navigateTo({
+            url: '/pages/teachAuthentication/teachAuthentication',
         })
         })
     },
     },
 
 
     // 跳转到发布新的课程页面
     // 跳转到发布新的课程页面
-    toCoursePublish(){
+    toCoursePublish() {
         wx.navigateTo({
         wx.navigateTo({
-          url: '/pages/coursePublish/coursePublish',
+            url: '/pages/coursePublish/coursePublish',
         })
         })
     },
     },
 
 
     //跳转到发布新的需求页面
     //跳转到发布新的需求页面
-    toNeedPublis(){
+    toNeedPublis() {
+        wx.navigateTo({
+            url: '/pages/stuNeed/stuNeed',
+        })
+    },
+
+    // 跳转到我的建议页面
+    toMySuggestion() {
+        wx.navigateTo({
+            url: '/pages/suggestList/suggestList',
+        })
+    },
+
+    // 跳转到我的投诉页面
+    toMyComplaint() {
         wx.navigateTo({
         wx.navigateTo({
-          url: '/pages/stuNeed/stuNeed',
+            url: '/pages/complaintList/complaintList',
         })
         })
     },
     },
 
 

+ 4 - 4
pages/myInfo/myInfo.wxml

@@ -11,12 +11,12 @@
         <image class="rightArrow" src="../../images/right.png"></image>
         <image class="rightArrow" src="../../images/right.png"></image>
     </view>
     </view>
     <!-- 推荐分享 -->
     <!-- 推荐分享 -->
-    <view class="recommend">
+    <view class="recommend" bindtap="toRecommend">
         <view>推荐分享</view>
         <view>推荐分享</view>
         <image class="rightArrow" src="../../images/right.png"></image>
         <image class="rightArrow" src="../../images/right.png"></image>
     </view>
     </view>
     <!-- 订单 -->
     <!-- 订单 -->
-    <view class="orderList">
+    <view class="orderList" bindtap="toMyOrder">
         <view>订单</view>
         <view>订单</view>
         <image class="rightArrow" src="../../images/right.png"></image>
         <image class="rightArrow" src="../../images/right.png"></image>
     </view>
     </view>
@@ -70,11 +70,11 @@
     </view>
     </view>
     <!-- 建议和投诉 -->
     <!-- 建议和投诉 -->
     <view class="suggest">
     <view class="suggest">
-        <view class="suggestDetail">
+        <view class="suggestDetail" bindtap="toMySuggestion">
             <view>我的建议</view>
             <view>我的建议</view>
             <image class="rightArrow" src="../../images/right.png"></image>
             <image class="rightArrow" src="../../images/right.png"></image>
         </view>
         </view>
-        <view class="suggestDetail">
+        <view class="suggestDetail" bindtap="toMyComplaint">
             <view>我的投诉</view>
             <view>我的投诉</view>
             <image class="rightArrow" src="../../images/right.png"></image>
             <image class="rightArrow" src="../../images/right.png"></image>
         </view>
         </view>

+ 73 - 0
pages/recommend/recommend.js

@@ -0,0 +1,73 @@
+// pages/recommend/recommend.js
+Page({
+
+    /**
+     * 页面的初始数据
+     */
+    data: {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad(options) {
+
+    },
+
+    // 跳转到推荐订单详情页
+    toRecommendList(){
+        wx.navigateTo({
+          url: '/pages/recommendList/recommendList',
+        })
+    },
+
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload() {
+
+    },
+
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh() {
+
+    },
+
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom() {
+
+    },
+
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage() {
+
+    }
+})

+ 4 - 0
pages/recommend/recommend.json

@@ -0,0 +1,4 @@
+{
+    "usingComponents": {},
+    "navigationBarTitleText": "推荐分享"
+}

+ 20 - 0
pages/recommend/recommend.wxml

@@ -0,0 +1,20 @@
+<!--pages/recommend/recommend.wxml-->
+
+<view class="recommendResult">
+    <view class="recommendEnroll">
+        <text class="recommendEnrollTitle">注册数</text>
+        <text class="recommendNum">100</text>
+    </view>
+    <view class="recommendEnroll">
+        <text class="recommendEnrollTitle">成交数</text>
+        <text class="recommendNum">10</text>
+    </view>
+</view>
+<view class="withdraw" bindtap="toRecommendList">
+    <text class="withdrawTitle">可提现金额</text>
+    <text class="withdrawNum">1000</text>
+    <image class="rightArrow" src="../../images/right.png"></image>
+</view>
+<view class="toRecommend">
+    <text class="toRecommendTitle">开始分享</text>
+</view>

+ 79 - 0
pages/recommend/recommend.wxss

@@ -0,0 +1,79 @@
+/* pages/recommend/recommend.wxss */
+
+/* 设置页面背景 */
+page{
+    padding: 20rpx;
+    background-color: #E2F0D9;
+    height: 100%;
+}
+
+/* 注册数、成交数 */
+.recommendResult{
+    border-radius: 30rpx;
+    background-color: #FFF2CC;
+    width: 95%;
+    margin-right: 20rpx;
+    padding: 20rpx 0;    
+    font-weight: bold;
+}
+
+/* 注册数、成交数内边距 */
+.recommendEnroll{
+    padding: 20rpx 0;
+}
+
+/* 注册数、成交数标题 */
+.recommendEnrollTitle{
+    margin-left: 120rpx;
+}
+/* 注册数量、成交数量 */
+.recommendNum{
+    margin-left: calc(45vw - 120rpx);
+    color: red;
+}
+
+/* 提现 */
+.withdraw{
+    display: flex;
+    position: relative;
+    border-radius: 20rpx;
+    background-color: #FFF2CC;
+    width: 95%;
+    margin: 20rpx 0;
+    padding: 20rpx 0;
+    font-weight: bold;
+    align-items: center;
+}
+/* 提现标题 */
+.withdrawTitle{
+    margin-left: 120rpx;
+}
+/* 提现金额 */
+.withdrawNum{
+    margin-left: calc(45vw - 180rpx);
+    color: red;
+}
+
+/* 右箭头 */
+.rightArrow{
+    position: absolute;
+    right: 40rpx;
+    width: 30rpx;
+    height: 30rpx;
+}
+
+/* 推荐分享 */
+.toRecommend{
+    display: flex;
+    justify-content: center;
+}
+.toRecommendTitle{
+    /* border: 1rpx solid gray; */
+    padding: 10rpx 30rpx;
+    background-color: #8FAADC;
+    color: white;
+    font-size: 36rpx;
+    border-radius: 40rpx;
+    position: absolute;
+    bottom: 200rpx;
+}

+ 73 - 0
pages/recommendList/recommendList.js

@@ -0,0 +1,73 @@
+// pages/recommendList/recommendList.js
+Page({
+
+    /**
+     * 页面的初始数据
+     */
+    data: {
+
+    },
+
+    // 跳转到推荐订单详情页
+    toRecommendOrderDetail(){
+        wx.navigateTo({
+          url: '/pages/recommendOrderDetail/recommendOrderDetail',
+        })
+    },
+
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad(options) {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload() {
+
+    },
+
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh() {
+
+    },
+
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom() {
+
+    },
+
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage() {
+
+    }
+})

+ 4 - 0
pages/recommendList/recommendList.json

@@ -0,0 +1,4 @@
+{
+    "usingComponents": {},
+    "navigationBarTitleText": "推荐成交订单"
+}

+ 20 - 0
pages/recommendList/recommendList.wxml

@@ -0,0 +1,20 @@
+<!--pages/recommendList/recommendList.wxml-->
+
+<view>
+    <view class="recommendOrder" bindtap="toRecommendOrderDetail">
+        <view class="order">
+            <text>订单号</text>
+            <text class="orderNum">xxx</text>
+        </view>
+        <view class="withdrawWrapper">
+            <view>
+                <text>订单日期</text>
+                <text class="withdrawDate">2022-12-22</text>
+            </view>
+            <view class="withdrawDeposit">
+                <text>提现状态</text>
+                <text class="withdrawStatus">已提现</text>
+            </view>
+        </view>
+    </view>
+</view>

+ 47 - 0
pages/recommendList/recommendList.wxss

@@ -0,0 +1,47 @@
+/* pages/recommendList/recommendList.wxss */
+
+page{
+    background-color: #E2F0D9;
+    padding: 20rpx;
+}
+
+/* 单条订单背景 */
+.recommendOrder{
+    display: flex;
+    flex-direction: column;
+    background-color: #FFF2CC;
+    padding: 20rpx 0;
+    width: 95%;
+    border-radius: 30rpx;
+    font-size: 28rpx;
+    margin-bottom: 20rpx;
+}
+
+/* 订单号 */
+.order{
+    margin-left: 20rpx;
+}
+/* 订单号详情、提现日期详情 */
+.orderNum,
+.withdrawDate{
+    margin-left: 20rpx;
+    font-weight: bold;
+}
+
+/* 订单日期及提现状态 */
+.withdrawWrapper{
+    display: flex;
+    margin: 20rpx 0 0 20rpx;
+    position: relative;
+}
+
+/* 提现状态 */
+.withdrawDeposit{
+    position: absolute;
+    left: 62%;
+}
+.withdrawStatus{
+    margin-left: 20rpx;
+    font-weight: bold;
+    color: red;
+}

+ 86 - 0
pages/recommendOrderDetail/recommendOrderDetail.js

@@ -0,0 +1,86 @@
+// pages/recommendOrderDetail/recommendOrderDetail.js
+Page({
+
+    /**
+     * 页面的初始数据
+     */
+    data: {
+        days: '6',
+        withdrawStatus: '未申请'
+    },
+
+    /**
+     * 生命周期函数--监听页面加载
+     */
+    onLoad(options) {
+
+    },
+
+    // 申请提现按钮功能
+    toApplyWithdraw() {
+        let days = this.data.days
+        let withdrawStatus = this.data.withdrawStatus
+        if (days > 5) {
+            if (withdrawStatus == "未申请") {
+                wx.showModal({
+                    title: '提现申请成功',
+                    content: '您的提现申请已提交,请等待处理'
+                })
+            }
+        } else {
+            wx.showModal({
+                title: '不能提现',
+                content: '该订单生成时间不足5天,暂不能申请提现'
+            })
+        }
+    },
+
+    /**
+     * 生命周期函数--监听页面初次渲染完成
+     */
+    onReady() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面显示
+     */
+    onShow() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面隐藏
+     */
+    onHide() {
+
+    },
+
+    /**
+     * 生命周期函数--监听页面卸载
+     */
+    onUnload() {
+
+    },
+
+    /**
+     * 页面相关事件处理函数--监听用户下拉动作
+     */
+    onPullDownRefresh() {
+
+    },
+
+    /**
+     * 页面上拉触底事件的处理函数
+     */
+    onReachBottom() {
+
+    },
+
+    /**
+     * 用户点击右上角分享
+     */
+    onShareAppMessage() {
+
+    }
+})

+ 4 - 0
pages/recommendOrderDetail/recommendOrderDetail.json

@@ -0,0 +1,4 @@
+{
+    "usingComponents": {},
+    "navigationBarTitleText": "提现详情"
+}

+ 50 - 0
pages/recommendOrderDetail/recommendOrderDetail.wxml

@@ -0,0 +1,50 @@
+<!--pages/recommendOrderDetail/recommendOrderDetail.wxml-->
+
+<!-- 顶部订单号和头像 -->
+<view class="headWrapper">
+    <view>
+        <text>订单号</text>
+        <text class="orderNumDetail">xxxx</text>
+    </view>
+    <image class="headImg" src="../../images/zly.jpeg"></image>
+</view>
+<!-- 需求信息 -->
+<view>
+    <view class="need">
+        <text>需求号</text>
+        <text class="needDetail">xxx</text>
+    </view>
+    <view class="need">
+        <text>课程号</text>
+        <text class="needDetail">xxx</text>
+    </view>
+    <view class="need">
+        <text>需求金额</text>
+        <text class="needMoney">xxx</text>
+    </view>
+</view>
+<!-- 订单信息 -->
+<view>
+    <view class="orderContent">
+        <text class="orderContentTitle">订单内容</text>
+        <text class="orderDetail">xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</text>
+    </view>
+    <view class="order">
+        <text>下单日期</text>
+        <text class="orderDate">2022-12-22</text>
+    </view>
+</view>
+<!-- 推荐人佣金及提现状态 -->
+<view>
+    <view class="commission">
+        <text>推荐人佣金</text>
+        <text class="commissionNum">xxx</text>
+    </view>
+    <view class="withdraw">
+        <text>提现状态</text>
+        <text class="withdrawStatus">{{withdrawStatus}}</text>
+    </view>
+</view>
+<view wx:if="{{withdrawStatus == '未申请'}}" class="apply" bindtap="toApplyWithdraw">
+    <text class="applyWithdraw">申请提现</text>
+</view>

+ 114 - 0
pages/recommendOrderDetail/recommendOrderDetail.wxss

@@ -0,0 +1,114 @@
+/* pages/recommendOrderDetail/recommendOrderDetail.wxss */
+
+/* 设置背景 */
+page {
+    background-color: #FFF2CC;
+    padding: 20rpx;
+}
+
+/* 顶部区域 */
+.headWrapper {
+    display: flex;
+    position: relative;
+    height: 200rpx;
+    /* background-color: #fff; */
+}
+
+/* 订单号详情 */
+.orderNumDetail {
+    margin-left: 20rpx;
+    font-weight: bold;
+}
+
+/* 头像 */
+.headImg {
+    width: 160rpx;
+    height: 160rpx;
+    border-radius: 30rpx;
+    position: absolute;
+    right: 30rpx;
+}
+
+/* 需求信息 */
+.need {
+    margin-top: 20rpx;
+}
+
+.needDetail,
+.needMoney {
+    margin-left: 10rpx;
+    font-weight: bold;
+}
+
+/* 需求号、课程号详情 */
+.needDetail {
+    text-decoration: underline;
+    color: #00B0F0;
+}
+
+/* 订单信息 */
+.orderContent,
+.order {
+    margin-top: 40rpx;
+    display: flex;
+}
+
+/* 订单内容标题 */
+.orderContentTitle {
+    /* width: 25%; */
+    width: 140rpx;
+}
+
+.orderDetail,
+.orderDate {
+    margin-left: 20rpx;
+}
+
+/* 订单内容详情 */
+.orderDetail {
+    display: block;
+    width: 60%;
+    white-space: nowrap;
+    overflow: hidden;
+    text-overflow: ellipsis;
+}
+
+/* 下单日期 */
+.orderDate {
+    font-weight: bold;
+}
+
+/* 推荐人佣金 */
+.commission {
+    margin-top: 40rpx;
+}
+
+/* 佣金金额、提现状态详情 */
+.commissionNum,
+.withdrawStatus {
+    margin-left: 20rpx;
+    font-weight: bold;
+}
+
+/* 提现状态 */
+.withdraw {
+    margin-top: 30rpx;
+}
+
+/* 提现状态详情 */
+.withdrawStatus {
+    color: red;
+}
+
+/* 申请提现按钮 */
+.apply {
+    display: flex;
+    margin-top: 200rpx;
+    justify-content: center;
+}
+.applyWithdraw{
+    padding: 10rpx 20rpx;
+    border-radius: 30rpx;
+    background-color: #8FAADC;
+    color: white;
+}